pub struct AccountListenerProxy { /* private fields */ }
Implementations§
source§impl AccountListenerProxy
impl AccountListenerProxy
sourcepub fn take_event_stream(&self) -> AccountListenerEventStream
pub fn take_event_stream(&self) -> AccountListenerEventStream
Get a Stream of events from the remote end of the AccountListener protocol
Panics
Panics if the event stream was already taken.
sourcepub fn on_initialize(
&self,
account_states: &mut dyn ExactSizeIterator<Item = &mut AccountAuthState>
) -> QueryResponseFut<()>
pub fn on_initialize( &self, account_states: &mut dyn ExactSizeIterator<Item = &mut AccountAuthState> ) -> QueryResponseFut<()>
A method that is called to communicate the initial set of accounts and their authentication states. OnInitialize is called exactly once if and only if AccountListenerOptions.initial_state was set when creating the AccountListener. When called, it will always be the first call on the channel. If no accounts are present on the device the vector will be empty.
account_states
The set of initial states.
sourcepub fn on_account_added(
&self,
account_state: &mut AccountAuthState
) -> QueryResponseFut<()>
pub fn on_account_added( &self, account_state: &mut AccountAuthState ) -> QueryResponseFut<()>
A method that is called when a new account is added to the device. This method is only called if AccountListenerOptions.add_account was set when creating the AccountListener.
account_state
The initial state for the newly added account.
sourcepub fn on_account_removed(&self, account_id: u64) -> QueryResponseFut<()>
pub fn on_account_removed(&self, account_id: u64) -> QueryResponseFut<()>
A method that is called when a provisioned account is removed. This method is only called if AccountListenerOptions.remove_account was set when creating the AccountListener.
sourcepub fn on_auth_state_changed(
&self,
account_auth_state: &mut AccountAuthState
) -> QueryResponseFut<()>
pub fn on_auth_state_changed( &self, account_auth_state: &mut AccountAuthState ) -> QueryResponseFut<()>
A method that is called when the authentication state of any provisioned account changes.
Trait Implementations§
source§impl AccountListenerProxyInterface for AccountListenerProxy
impl AccountListenerProxyInterface for AccountListenerProxy
type OnInitializeResponseFut = QueryResponseFut<()>
fn on_initialize( &self, account_states: &mut dyn ExactSizeIterator<Item = &mut AccountAuthState> ) -> Self::OnInitializeResponseFut
type OnAccountAddedResponseFut = QueryResponseFut<()>
fn on_account_added( &self, account_state: &mut AccountAuthState ) -> Self::OnAccountAddedResponseFut
type OnAccountRemovedResponseFut = QueryResponseFut<()>
fn on_account_removed( &self, account_id: u64 ) -> Self::OnAccountRemovedResponseFut
type OnAuthStateChangedResponseFut = QueryResponseFut<()>
fn on_auth_state_changed( &self, account_auth_state: &mut AccountAuthState ) -> Self::OnAuthStateChangedResponseFut
source§impl Clone for AccountListenerProxy
impl Clone for AccountListenerProxy
source§fn clone(&self) -> AccountListenerProxy
fn clone(&self) -> AccountListenerProxy
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for AccountListenerProxy
impl Debug for AccountListenerProxy
source§impl Proxy for AccountListenerProxy
impl Proxy for AccountListenerProxy
§type Protocol = AccountListenerMarker
type Protocol = AccountListenerMarker
Proxy
controls.