pub struct DeviceProxy { /* private fields */ }Expand description
Complete authenticated client composition for a LazyCat device API.
Implementations§
Source§impl DeviceProxy
impl DeviceProxy
Sourcepub async fn connect(
api_url: &str,
credentials: ClientCredentials,
) -> Result<Self, Error>
pub async fn connect( api_url: &str, credentials: ClientCredentials, ) -> Result<Self, Error>
Connect all device clients over one authenticated mTLS channel.
§Errors
Returns an error when the device URL or mTLS connection is invalid.
Sourcepub async fn get_auth_token(&self) -> Result<Arc<AuthToken>, Error>
pub async fn get_auth_token(&self) -> Result<Arc<AuthToken>, Error>
Return the current cached token, refreshing it when necessary.
§Errors
Returns an error when token signing or acquisition fails.
pub fn config(&self) -> UserConfigClient<AuthenticatedService<Channel>>
pub fn device(&self) -> DeviceServiceClient<AuthenticatedService<Channel>>
pub fn dialog(&self) -> DialogManagerClient<AuthenticatedService<Channel>>
pub fn photo_library(&self) -> PhotoLibraryClient<AuthenticatedService<Channel>>
pub fn network(&self) -> NetworkManagerClient<AuthenticatedService<Channel>>
pub fn permission( &self, ) -> PermissionManagerClient<AuthenticatedService<Channel>>
pub fn file_handler(&self) -> FileHandlerClient<AuthenticatedService<Channel>>
pub fn rim(&self) -> RimClient<AuthenticatedService<Channel>>
pub fn remote_control( &self, ) -> RemoteControlClient<AuthenticatedService<Channel>>
pub fn contacts(&self) -> ContactsManagerClient<AuthenticatedService<Channel>>
pub fn status(&self) -> DeviceProxyStatus
Trait Implementations§
Source§impl Clone for DeviceProxy
impl Clone for DeviceProxy
Auto Trait Implementations§
impl !RefUnwindSafe for DeviceProxy
impl !UnwindSafe for DeviceProxy
impl Freeze for DeviceProxy
impl Send for DeviceProxy
impl Sync for DeviceProxy
impl Unpin for DeviceProxy
impl UnsafeUnpin for DeviceProxy
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request