ModemManager.Bearer¶
- Subclasses:
None
Methods¶
- Inherited:
ModemManager.GdbusBearerProxy (6), Gio.DBusProxy (25), GObject.Object (37), Gio.AsyncInitable (4), Gio.DBusInterface (3), Gio.Initable (2), ModemManager.GdbusBearer (10)
- Structs:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Virtual Methods¶
Properties¶
- Inherited:
Signals¶
Fields¶
Name |
Type |
Access |
Description |
---|---|---|---|
parent |
r |
Class Details¶
- class ModemManager.Bearer(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
The
ModemManager.Bearer
structure contains private data and should only be accessed using the provided API.- connect(cancellable, callback, *user_data)¶
- Parameters:
cancellable (
Gio.Cancellable
orNone
) – AGio.Cancellable
orNone
.callback (
Gio.AsyncReadyCallback
orNone
) – AGio.AsyncReadyCallback
to call when the request is satisfied orNone
.
Asynchronously requests activation of a packet data connection with the network using this
ModemManager.Bearer
properties.When the operation is finished, callback will be invoked in the
thread-default main loop
of the thread you are calling this method from. You can then callModemManager.Bearer.connect_finish
() to get the result of the operation.See
ModemManager.Bearer.connect_sync
() for the synchronous, blocking version of this method.New in version 1.0.
- connect_finish(res)¶
- Parameters:
res (
Gio.AsyncResult
) – TheGio.AsyncResult
obtained from theGio.AsyncReadyCallback
passed toModemManager.Bearer.connect
().- Raises:
- Returns:
- Return type:
Finishes an operation started with
ModemManager.Bearer.connect
().New in version 1.0.
- connect_sync(cancellable)¶
- Parameters:
cancellable (
Gio.Cancellable
orNone
) – AGio.Cancellable
orNone
.- Raises:
- Returns:
- Return type:
Synchronously requests activation of a packet data connection with the network using this
ModemManager.Bearer
properties.The calling thread is blocked until a reply is received. See
ModemManager.Bearer.connect
() for the asynchronous version of this method.New in version 1.0.
- disconnect(cancellable, callback, *user_data)¶
- Parameters:
cancellable (
Gio.Cancellable
orNone
) – AGio.Cancellable
orNone
.callback (
Gio.AsyncReadyCallback
orNone
) – AGio.AsyncReadyCallback
to call when the request is satisfied orNone
.
Synchronously requests disconnection and deactivation of the packet data connection.
When the operation is finished, callback will be invoked in the
thread-default main loop
of the thread you are calling this method from. You can then callModemManager.Bearer.disconnect_finish
() to get the result of the operation.See
ModemManager.Bearer.disconnect_sync
() for the synchronous, blocking version of this method.New in version 1.0.
- disconnect_finish(res)¶
- Parameters:
res (
Gio.AsyncResult
) – TheGio.AsyncResult
obtained from theGio.AsyncReadyCallback
passed toModemManager.Bearer.disconnect
().- Raises:
- Returns:
- Return type:
Finishes an operation started with
ModemManager.Bearer.disconnect
().New in version 1.0.
- disconnect_sync(cancellable)¶
- Parameters:
cancellable (
Gio.Cancellable
orNone
) – AGio.Cancellable
orNone
.- Raises:
- Returns:
- Return type:
Synchronously requests disconnection and deactivation of the packet data connection.
The calling thread is blocked until a reply is received. See
ModemManager.Bearer.disconnect
() for the asynchronous version of this method.New in version 1.0.
- dup_interface()¶
- Returns:
The name of the interface, or
None
if it couldn’t be retrieved. The returned value should be freed withGLib.free
().- Return type:
Gets a copy of the operating system name for the network data interface that provides packet data using this
ModemManager.Bearer
. This will only be available once theModemManager.Bearer
is in connected state.New in version 1.0.
- dup_path()¶
- Returns:
The DBus path of the
ModemManager.Bearer
object. The returned value should be freed withGLib.free
().- Return type:
Gets a copy of the DBus path of the
ModemManager.Bearer
object.New in version 1.0.
- get_bearer_type()¶
- Returns:
- Return type:
Gets the type of bearer.
New in version 1.0.
- get_connected()¶
- Returns:
True
if theModemManager.Bearer
is connected,False
otherwise.- Return type:
Checks whether or not the
ModemManager.Bearer
is connected and thus whether packet data communication is possible.New in version 1.0.
- get_connection_error()¶
- Returns:
A
GLib.Error
that must be freed withGLib.Error.free
() orNone
if none.- Return type:
Gets a
GLib.Error
specifying the connection error details, if any.The values reported by self are not updated when the values in the interface change. Instead, the client is expected to call
ModemManager.Bearer.get_connection_error
() again to get a newGLib.Error
with the new values.New in version 1.18.
- get_interface()¶
-
Gets the operating system name for the network data interface that provides packet data using this
ModemManager.Bearer
. This will only be available once theModemManager.Bearer
is in connected state.The returned value is only valid until the property changes so it is only safe to use this function on the thread where self was constructed. Use
ModemManager.Bearer.dup_interface
() if on another thread.New in version 1.0.
- get_ip_timeout()¶
- Returns:
The IP timeout, or 0 if no specific one given.
- Return type:
Gets the maximum time to wait for the bearer to retrieve a valid IP address.
New in version 1.0.
- get_ipv4_config()¶
- Returns:
A
ModemManager.BearerIpConfig
that must be freed withGObject.Object.unref
() orNone
if unknown.- Return type:
Gets a
ModemManager.BearerIpConfig
object specifying the IPv4 configuration to use in the bearer.The values reported by self are not updated when the values in the interface change. Instead, the client is expected to call
ModemManager.Bearer.get_ipv4_config
() again to get a newModemManager.BearerIpConfig
with the new values.New in version 1.0.
- get_ipv6_config()¶
- Returns:
A
ModemManager.BearerIpConfig
that must be freed withGObject.Object.unref
() orNone
if unknown.- Return type:
Gets a
ModemManager.BearerIpConfig
object specifying the IPv6 configuration to use in the bearer.The values reported by self are not updated when the values in the interface change. Instead, the client is expected to call
ModemManager.Bearer.get_ipv6_config
() again to get a newModemManager.BearerIpConfig
with the new values.New in version 1.0.
- get_multiplexed()¶
- Returns:
True
if packet data service is connected via a multiplexed network link in theModemManager.Bearer
,False
otherwise.- Return type:
Checks whether or not the
ModemManager.Bearer
is connected through a multiplexed network likn.New in version 1.18.
- get_path()¶
- Returns:
The DBus path of the
ModemManager.Bearer
object.- Return type:
Gets the DBus path of the
ModemManager.Bearer
object.New in version 1.0.
- get_profile_id()¶
- Returns:
a profile id.
- Return type:
Gets profile ID associated to the bearer connection, if known.
If the bearer is disconnected or the modem doesn’t support profile management features,
ModemManager._3GPP_PROFILE_ID_UNKNOWN
.New in version 1.18.
- get_properties()¶
- Returns:
A
ModemManager.BearerProperties
that must be freed withGObject.Object.unref
() orNone
if unknown.- Return type:
Gets a
ModemManager.BearerProperties
object specifying the properties which were used to create the bearer.The values reported by self are not updated when the values in the interface change. Instead, the client is expected to call
ModemManager.Bearer.get_properties
() again to get a newModemManager.BearerProperties
with the new values.New in version 1.0.
- get_reload_stats_supported()¶
- Returns:
True
if theModemManager.Bearer
supports these stats,False
otherwise.- Return type:
Checks whether or not the
ModemManager.Bearer
supporting stats reload (to have RX and TX bytes of the ongoing connection).New in version 1.20.
- get_stats()¶
- Returns:
A
ModemManager.BearerStats
that must be freed withGObject.Object.unref
() orNone
if unknown.- Return type:
Gets a
ModemManager.BearerStats
object specifying the statistics of the current bearer connection.The values reported by self are not updated when the values in the interface change. Instead, the client is expected to call
ModemManager.Bearer.get_stats
() again to get a newModemManager.BearerStats
with the new values.New in version 1.6.
- get_suspended()¶
- Returns:
True
if packet data service is suspended in theModemManager.Bearer
,False
otherwise.- Return type:
Checks whether or not the
ModemManager.Bearer
is suspended (but not deactivated) while the device is handling other communications, like a voice call.New in version 1.0.
- peek_connection_error()¶
- Returns:
A
GLib.Error
, orNone
if none. Do not free the returned value, it belongs to self.- Return type:
Gets a
GLib.Error
specifying the connection error details, if any.The returned value is only valid until the property changes so it is only safe to use this function on the thread where self was constructed. Use
ModemManager.Bearer.get_connection_error
() if on another thread.New in version 1.18.
- peek_ipv4_config()¶
- Returns:
A
ModemManager.BearerIpConfig
. Do not free the returned value, it belongs to self.- Return type:
Gets a
ModemManager.BearerIpConfig
object specifying the IPv4 configuration to use in the bearer.The returned value is only valid until the property changes so it is only safe to use this function on the thread where self was constructed. Use
ModemManager.Bearer.get_ipv4_config
() if on another thread.New in version 1.0.
- peek_ipv6_config()¶
- Returns:
A
ModemManager.BearerIpConfig
. Do not free the returned value, it belongs to self.- Return type:
Gets a
ModemManager.BearerIpConfig
object specifying the IPv6 configuration to use in the bearer.The returned value is only valid until the property changes so it is only safe to use this function on the thread where self was constructed. Use
ModemManager.Bearer.get_ipv6_config
() if on another thread.New in version 1.0.
- peek_properties()¶
- Returns:
A
ModemManager.BearerProperties
. Do not free the returned value, it belongs to self.- Return type:
Gets a
ModemManager.BearerProperties
object specifying the properties which were used to create the bearer.The returned value is only valid until the property changes so it is only safe to use this function on the thread where self was constructed. Use
ModemManager.Bearer.get_properties
() if on another thread.New in version 1.0.
- peek_stats()¶
- Returns:
A
ModemManager.BearerStats
. Do not free the returned value, it belongs to self.- Return type:
Gets a
ModemManager.BearerStats
object specifying the statistics of the current bearer connection.The returned value is only valid until the property changes so it is only safe to use this function on the thread where self was constructed. Use
ModemManager.Bearer.get_stats
() if on another thread.New in version 1.6.