pub struct NamespaceControllerProxy { /* private fields */ }
Implementations§
Source§impl NamespaceControllerProxy
impl NamespaceControllerProxy
Sourcepub fn new(channel: AsyncChannel) -> Self
pub fn new(channel: AsyncChannel) -> Self
Create a new Proxy for fuchsia.net.filter/NamespaceController.
Sourcepub fn take_event_stream(&self) -> NamespaceControllerEventStream
pub fn take_event_stream(&self) -> NamespaceControllerEventStream
Get a Stream of events from the remote end of the protocol.
§Panics
Panics if the event stream was already taken.
Sourcepub fn detach(
&self,
) -> QueryResponseFut<[u8; 16], DefaultFuchsiaResourceDialect>
pub fn detach( &self, ) -> QueryResponseFut<[u8; 16], DefaultFuchsiaResourceDialect>
Detaches the client end from the controller’s lifetime.
After calling Detach
, closing this client end no longer causes the
filtering state owned by the controller to be removed. The key returned
by the method can be used once by a client to reconnect to a detached
controller. This allows clients to ensure the filtering state they
install is resilient to client-side crashes and disconnections. (Note,
however, that closing the client end of the channel will flush any
pending changes that have been pushed but not yet committed.)
Detach
can be called multiple times; the key returned by the most
recent call is valid to reconnect to the controller. Calling Detach
will always return a new key and invalidate any previous keys.
Note that, once a client has called Detach
on a controller, the
controller remains detached even after a reconnection. This means that,
for example, if a client detached, closed the client end, reconnected,
and then closed the client end again, the filtering state owned by the
controller would not be removed. After reconnection, the only reason a
client would call Detach
is to be able to reconnect again in the
future, given the key is invalidated after use.
Sourcepub fn push_changes(
&self,
changes: &[Change],
) -> QueryResponseFut<ChangeValidationResult, DefaultFuchsiaResourceDialect>
pub fn push_changes( &self, changes: &[Change], ) -> QueryResponseFut<ChangeValidationResult, DefaultFuchsiaResourceDialect>
Append a set of changes to a pending transactional update to the filtering configuration.
To apply these changes, a client must call Commit
.
Sourcepub fn commit(
&self,
payload: CommitOptions,
) -> QueryResponseFut<CommitResult, DefaultFuchsiaResourceDialect>
pub fn commit( &self, payload: CommitOptions, ) -> QueryResponseFut<CommitResult, DefaultFuchsiaResourceDialect>
Apply all pending changes. The set of changes will either be applied in its entirety or, in case of an error, not applied at all.
Trait Implementations§
Source§impl Clone for NamespaceControllerProxy
impl Clone for NamespaceControllerProxy
Source§fn clone(&self) -> NamespaceControllerProxy
fn clone(&self) -> NamespaceControllerProxy
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for NamespaceControllerProxy
impl Debug for NamespaceControllerProxy
Source§impl NamespaceControllerProxyInterface for NamespaceControllerProxy
impl NamespaceControllerProxyInterface for NamespaceControllerProxy
type DetachResponseFut = QueryResponseFut<[u8; 16]>
type PushChangesResponseFut = QueryResponseFut<ChangeValidationResult>
type CommitResponseFut = QueryResponseFut<CommitResult>
fn detach(&self) -> Self::DetachResponseFut
fn push_changes(&self, changes: &[Change]) -> Self::PushChangesResponseFut
fn commit(&self, payload: CommitOptions) -> Self::CommitResponseFut
Source§impl Proxy for NamespaceControllerProxy
impl Proxy for NamespaceControllerProxy
Source§type Protocol = NamespaceControllerMarker
type Protocol = NamespaceControllerMarker
Proxy
controls.Source§fn from_channel(inner: AsyncChannel) -> Self
fn from_channel(inner: AsyncChannel) -> Self
Source§fn into_channel(self) -> Result<AsyncChannel, Self>
fn into_channel(self) -> Result<AsyncChannel, Self>
Source§fn as_channel(&self) -> &AsyncChannel
fn as_channel(&self) -> &AsyncChannel
§fn into_client_end(self) -> Result<ClientEnd<Self::Protocol>, Self>
fn into_client_end(self) -> Result<ClientEnd<Self::Protocol>, Self>
Auto Trait Implementations§
impl Freeze for NamespaceControllerProxy
impl !RefUnwindSafe for NamespaceControllerProxy
impl Send for NamespaceControllerProxy
impl Sync for NamespaceControllerProxy
impl Unpin for NamespaceControllerProxy
impl !UnwindSafe for NamespaceControllerProxy
Blanket Implementations§
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)