Struct SimpleProxy
pub struct SimpleProxy<'p>(Proxy<'p>);Expand description
Client for the simple connection interface of a modem.
The interface appears once the modem can register. A 3GPP modem needs an unlocked SIM first.
Upstream documentation: https://www.freedesktop.org/software/ModemManager/api/latest/gdbus-org.freedesktop.ModemManager1.Modem.Simple.html.
Tuple Fields§
§0: Proxy<'p>Implementations§
§impl<'p> SimpleProxy<'p>
impl<'p> SimpleProxy<'p>
pub async fn new<P>(conn: &Connection, path: P) -> Result<SimpleProxy<'p>>
pub async fn new<P>(conn: &Connection, path: P) -> Result<SimpleProxy<'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 connect(
&self,
properties: &SimpleConnectProperties,
) -> Result<OwnedObjectPath>
pub async fn connect( &self, properties: &SimpleConnectProperties, ) -> Result<OwnedObjectPath>
Connects the modem and returns the bearer.
The call finds a matching bearer or creates one and connects it. It can also unlock the SIM and register with a network. It returns the path of the bearer.
pub async fn disconnect(&self, path: &ObjectPath<'_>) -> Result<()>
pub async fn disconnect(&self, path: &ObjectPath<'_>) -> Result<()>
Disconnects a bearer.
Pass the path / to disconnect all bearers.
pub async fn get_status(&self) -> Result<SimpleStatus>
pub async fn get_status(&self) -> Result<SimpleStatus>
Returns the general status of the modem.
Trait Implementations§
§impl<'p> AsMut<Proxy<'p>> for SimpleProxy<'p>
impl<'p> AsMut<Proxy<'p>> for SimpleProxy<'p>
§impl<'p> AsRef<Proxy<'p>> for SimpleProxy<'p>
impl<'p> AsRef<Proxy<'p>> for SimpleProxy<'p>
§impl<'p> Clone for SimpleProxy<'p>
impl<'p> Clone for SimpleProxy<'p>
§fn clone(&self) -> SimpleProxy<'p>
fn clone(&self) -> SimpleProxy<'p>
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more