DBusObjectManagerClient

Added in version 2.30.

class DBusObjectManagerClient(**properties: Any)

Superclasses: Object

Implemented Interfaces: AsyncInitable, DBusObjectManager, Initable

Constructors:

DBusObjectManagerClient(**properties)
new_finish(res:Gio.AsyncResult) -> Gio.DBusObjectManagerClient
new_for_bus_finish(res:Gio.AsyncResult) -> Gio.DBusObjectManagerClient
new_for_bus_sync(bus_type:Gio.BusType, flags:Gio.DBusObjectManagerClientFlags, name:str, object_path:str, get_proxy_type_func:Gio.DBusProxyTypeFunc=None, get_proxy_type_user_data=None, cancellable:Gio.Cancellable=None) -> Gio.DBusObjectManagerClient
new_sync(connection:Gio.DBusConnection, flags:Gio.DBusObjectManagerClientFlags, name:str=None, object_path:str, get_proxy_type_func:Gio.DBusProxyTypeFunc=None, get_proxy_type_user_data=None, cancellable:Gio.Cancellable=None) -> Gio.DBusObjectManagerClient

Constructors

class DBusObjectManagerClient
classmethod new_finish(res: AsyncResult) DBusObjectManagerClient

Finishes an operation started with new().

Added in version 2.30.

Parameters:

res – A AsyncResult obtained from the AsyncReadyCallback passed to new().

classmethod new_for_bus_finish(res: AsyncResult) DBusObjectManagerClient

Finishes an operation started with new_for_bus().

Added in version 2.30.

Parameters:

res – A AsyncResult obtained from the AsyncReadyCallback passed to new_for_bus().

classmethod new_for_bus_sync(bus_type: BusType, flags: DBusObjectManagerClientFlags, name: str, object_path: str, get_proxy_type_func: Callable[[...], type] | None = None, cancellable: Cancellable | None = None, *get_proxy_type_user_data: Any) DBusObjectManagerClient

Like new_sync() but takes a BusType instead of a DBusConnection.

This is a synchronous failable constructor - the calling thread is blocked until a reply is received. See new_for_bus() for the asynchronous version.

Added in version 2.30.

Parameters:
  • bus_type – A BusType.

  • flags – Zero or more flags from the DBusObjectManagerClientFlags enumeration.

  • name – The owner of the control object (unique or well-known name).

  • object_path – The object path of the control object.

  • get_proxy_type_func – A DBusProxyTypeFunc function or None to always construct DBusProxy proxies.

  • cancellable – A Cancellable or None

  • get_proxy_type_user_data – User data to pass to get_proxy_type_func.

classmethod new_sync(connection: DBusConnection, flags: DBusObjectManagerClientFlags, name: str | None, object_path: str, get_proxy_type_func: Callable[[...], type] | None = None, cancellable: Cancellable | None = None, *get_proxy_type_user_data: Any) DBusObjectManagerClient

Creates a new DBusObjectManagerClient object.

This is a synchronous failable constructor - the calling thread is blocked until a reply is received. See new() for the asynchronous version.

Added in version 2.30.

Parameters:
  • connection – A DBusConnection.

  • flags – Zero or more flags from the DBusObjectManagerClientFlags enumeration.

  • name – The owner of the control object (unique or well-known name), or None when not using a message bus connection.

  • object_path – The object path of the control object.

  • get_proxy_type_func – A DBusProxyTypeFunc function or None to always construct DBusProxy proxies.

  • cancellable – A Cancellable or None

  • get_proxy_type_user_data – User data to pass to get_proxy_type_func.

Methods

class DBusObjectManagerClient
get_connection() DBusConnection

Gets the DBusConnection used by manager.

Added in version 2.30.

get_flags() DBusObjectManagerClientFlags

Gets the flags that manager was constructed with.

Added in version 2.30.

get_name() str

Gets the name that manager is for, or None if not a message bus connection.

Added in version 2.30.

get_name_owner() str | None

The unique name that owns the name that manager is for or None if no-one currently owns that name. You can connect to the Object::notify signal to track changes to the DBusObjectManagerClient:name-owner property.

Added in version 2.30.

new(connection: DBusConnection, flags: DBusObjectManagerClientFlags, name: str, object_path: str, get_proxy_type_func: Callable[[...], type] | None = None, cancellable: Cancellable | None = None, callback: Callable[[...], None] | None = None, *user_data: Any) None

Asynchronously creates a new DBusObjectManagerClient object.

This is an asynchronous failable constructor. When the result is ready, callback will be invoked in the [thread-default main context][g-main-context-push-thread-default] of the thread you are calling this method from. You can then call new_finish() to get the result. See new_sync() for the synchronous version.

Added in version 2.30.

Parameters:
  • connection – A DBusConnection.

  • flags – Zero or more flags from the DBusObjectManagerClientFlags enumeration.

  • name – The owner of the control object (unique or well-known name).

  • object_path – The object path of the control object.

  • get_proxy_type_func – A DBusProxyTypeFunc function or None to always construct DBusProxy proxies.

  • cancellable – A Cancellable or None

  • callback – A AsyncReadyCallback to call when the request is satisfied.

  • user_data – The data to pass to callback.

new_for_bus(bus_type: BusType, flags: DBusObjectManagerClientFlags, name: str, object_path: str, get_proxy_type_func: Callable[[...], type] | None = None, cancellable: Cancellable | None = None, callback: Callable[[...], None] | None = None, *user_data: Any) None

Like new() but takes a BusType instead of a DBusConnection.

This is an asynchronous failable constructor. When the result is ready, callback will be invoked in the [thread-default main loop][g-main-context-push-thread-default] of the thread you are calling this method from. You can then call new_for_bus_finish() to get the result. See new_for_bus_sync() for the synchronous version.

Added in version 2.30.

Parameters:
  • bus_type – A BusType.

  • flags – Zero or more flags from the DBusObjectManagerClientFlags enumeration.

  • name – The owner of the control object (unique or well-known name).

  • object_path – The object path of the control object.

  • get_proxy_type_func – A DBusProxyTypeFunc function or None to always construct DBusProxy proxies.

  • cancellable – A Cancellable or None

  • callback – A AsyncReadyCallback to call when the request is satisfied.

  • user_data – The data to pass to callback.

Properties

class DBusObjectManagerClient
props.bus_type: BusType

If this property is not NONE, then DBusObjectManagerClient:connection must be None and will be set to the DBusConnection obtained by calling bus_get() with the value of this property.

Added in version 2.30.

props.connection: DBusConnection

The DBusConnection to use.

Added in version 2.30.

props.flags: DBusObjectManagerClientFlags

Flags from the DBusObjectManagerClientFlags enumeration.

Added in version 2.30.

props.get_proxy_type_destroy_notify: None

A DestroyNotify for the gpointer user_data in DBusObjectManagerClient:get-proxy-type-user-data.

Added in version 2.30.

props.get_proxy_type_func: None

The DBusProxyTypeFunc to use when determining what Type to use for interface proxies or None.

Added in version 2.30.

props.get_proxy_type_user_data: None

The gpointer user_data to pass to DBusObjectManagerClient:get-proxy-type-func.

Added in version 2.30.

props.name: str

The well-known name or unique name that the manager is for.

Added in version 2.30.

props.name_owner: str

The unique name that owns DBusObjectManagerClient:name or None if no-one is currently owning the name. Connect to the Object::notify signal to track changes to this property.

Added in version 2.30.

props.object_path: str

The object path the manager is for.

Added in version 2.30.

Signals

class DBusObjectManagerClient.signals
interface_proxy_properties_changed(object_proxy: DBusObjectProxy, interface_proxy: DBusProxy, changed_properties: Variant, invalidated_properties: Sequence[str]) None

Emitted when one or more D-Bus properties on proxy changes. The local cache has already been updated when this signal fires. Note that both changed_properties and invalidated_properties are guaranteed to never be None (either may be empty though).

This signal exists purely as a convenience to avoid having to connect signals to all interface proxies managed by manager.

This signal is emitted in the [thread-default main context][g-main-context-push-thread-default] that manager was constructed in.

Added in version 2.30.

Parameters:
  • object_proxy – The DBusObjectProxy on which an interface has properties that are changing.

  • interface_proxy – The DBusProxy that has properties that are changing.

  • changed_properties – A Variant containing the properties that changed (type: a{sv}).

  • invalidated_properties – A None terminated array of properties that were invalidated.

interface_proxy_signal(object_proxy: DBusObjectProxy, interface_proxy: DBusProxy, sender_name: str, signal_name: str, parameters: Variant) None

Emitted when a D-Bus signal is received on interface_proxy.

This signal exists purely as a convenience to avoid having to connect signals to all interface proxies managed by manager.

This signal is emitted in the [thread-default main context][g-main-context-push-thread-default] that manager was constructed in.

Added in version 2.30.

Parameters:
  • object_proxy – The DBusObjectProxy on which an interface is emitting a D-Bus signal.

  • interface_proxy – The DBusProxy that is emitting a D-Bus signal.

  • sender_name – The sender of the signal or NULL if the connection is not a bus connection.

  • signal_name – The signal name.

  • parameters – A Variant tuple with parameters for the signal.

Virtual Methods

class DBusObjectManagerClient
do_interface_proxy_properties_changed(object_proxy: DBusObjectProxy, interface_proxy: DBusProxy, changed_properties: Variant, invalidated_properties: str) None

Signal class handler for the DBusObjectManagerClient::interface-proxy-properties-changed signal.

Parameters:
  • object_proxy

  • interface_proxy

  • changed_properties

  • invalidated_properties

do_interface_proxy_signal(object_proxy: DBusObjectProxy, interface_proxy: DBusProxy, sender_name: str, signal_name: str, parameters: Variant) None

Signal class handler for the DBusObjectManagerClient::interface-proxy-signal signal.

Parameters:
  • object_proxy

  • interface_proxy

  • sender_name

  • signal_name

  • parameters

Fields

class DBusObjectManagerClient
parent_instance
priv