Struct ProfileManagerProxy
pub struct ProfileManagerProxy<'p>(Proxy<'p>);Expand description
Client for the connection profiles of a modem.
If you use profiles, avoid connecting without a profile_id. A connection
without it can change a profile silently, because modems have a fixed
number of them.
Added in ModemManager 1.18.
Upstream documentation: https://www.freedesktop.org/software/ModemManager/api/latest/gdbus-org.freedesktop.ModemManager1.Modem.Modem3gpp.ProfileManager.html.
Tuple Fields§
§0: Proxy<'p>Implementations§
§impl<'p> ProfileManagerProxy<'p>
impl<'p> ProfileManagerProxy<'p>
pub async fn new<P>(
conn: &Connection,
path: P,
) -> Result<ProfileManagerProxy<'p>>
pub async fn new<P>( conn: &Connection, path: P, ) -> Result<ProfileManagerProxy<'p>>
Creates a new proxy with the given path, and the default destination.
pub fn builder(conn: &Connection) -> Builder<'p, Self>
pub fn builder(conn: &Connection) -> Builder<'p, Self>
Returns a customizable builder for this proxy.
pub fn into_inner(self) -> Proxy<'p>
pub fn into_inner(self) -> Proxy<'p>
Consumes self, returning the underlying zbus::Proxy.
pub fn inner(&self) -> &Proxy<'p>
pub fn inner(&self) -> &Proxy<'p>
The reference to the underlying zbus::Proxy.
pub fn inner_mut(&mut self) -> &mut Proxy<'p>
pub fn inner_mut(&mut self) -> &mut Proxy<'p>
The mutable reference to the underlying zbus::Proxy.
pub async fn list(&self) -> Result<Vec<BearerProperties>>
pub async fn list(&self) -> Result<Vec<BearerProperties>>
Lists the profiles of the modem.
The initial EPS bearer can show up with the initial apn_type flag.
pub async fn set(
&self,
properties: &BearerProperties,
) -> Result<BearerProperties>
pub async fn set( &self, properties: &BearerProperties, ) -> Result<BearerProperties>
Creates or updates a profile.
The call creates a profile if the index field is missing and updates the profile with that index otherwise. It returns the stored settings. The call fails if bearers of the profile are connected or if the profile is the initial EPS bearer.
pub async fn delete(&self, properties: &BearerProperties) -> Result<()>
pub async fn delete(&self, properties: &BearerProperties) -> Result<()>
Deletes the profile with the index in the properties.
The service ignores other settings. A modem that cannot remove profiles resets the profile instead.
pub async fn receive_updated(&self) -> Result<UpdatedStream>
pub async fn receive_updated(&self) -> Result<UpdatedStream>
Create a stream that receives Updated signals.
This a convenient wrapper around zbus::Proxy::receive_signal.
Sent when the network changed the profiles.
The daemon does not send it for calls through this interface. It can
miss changes. Call list again to compare.
pub async fn index_field(&self) -> Result<ProfileIndexField>
pub async fn index_field(&self) -> Result<ProfileIndexField>
The field that identifies a profile.
Added in ModemManager 1.20.
pub fn cached_index_field(
&self,
) -> Result<Option<<Result<ProfileIndexField> as ResultAdapter>::Ok>, <Result<ProfileIndexField> as ResultAdapter>::Err>
pub fn cached_index_field( &self, ) -> Result<Option<<Result<ProfileIndexField> as ResultAdapter>::Ok>, <Result<ProfileIndexField> as ResultAdapter>::Err>
The field that identifies a profile.
Added in ModemManager 1.20.
Get the cached value of the IndexField property, or None if the property is not cached.
pub async fn receive_index_field_changed(
&self,
) -> PropertyStream<'p, <Result<ProfileIndexField> as ResultAdapter>::Ok>
pub async fn receive_index_field_changed( &self, ) -> PropertyStream<'p, <Result<ProfileIndexField> as ResultAdapter>::Ok>
The field that identifies a profile.
Added in ModemManager 1.20.
Create a stream for the IndexField property changes. This is a convenient wrapper around [zbus::Proxy::receive_property_changed].
Trait Implementations§
§impl<'p> AsMut<Proxy<'p>> for ProfileManagerProxy<'p>
impl<'p> AsMut<Proxy<'p>> for ProfileManagerProxy<'p>
§impl<'p> AsRef<Proxy<'p>> for ProfileManagerProxy<'p>
impl<'p> AsRef<Proxy<'p>> for ProfileManagerProxy<'p>
§impl<'p> Clone for ProfileManagerProxy<'p>
impl<'p> Clone for ProfileManagerProxy<'p>
§fn clone(&self) -> ProfileManagerProxy<'p>
fn clone(&self) -> ProfileManagerProxy<'p>
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more