pub struct ManagerProxy { /* private fields */ }
Implementations§
Source§impl ManagerProxy
impl ManagerProxy
Sourcepub fn new(channel: AsyncChannel) -> Self
pub fn new(channel: AsyncChannel) -> Self
Create a new Proxy for fuchsia.starnix.runner/Manager.
Sourcepub fn take_event_stream(&self) -> ManagerEventStream
pub fn take_event_stream(&self) -> ManagerEventStream
Get a Stream of events from the remote end of the protocol.
§Panics
Panics if the event stream was already taken.
Sourcepub fn suspend_container(
&self,
payload: ManagerSuspendContainerRequest,
) -> QueryResponseFut<ManagerSuspendContainerResult, DefaultFuchsiaResourceDialect>
pub fn suspend_container( &self, payload: ManagerSuspendContainerRequest, ) -> QueryResponseFut<ManagerSuspendContainerResult, DefaultFuchsiaResourceDialect>
Suspends the container running in job
.
The call will return successfully when wake_event
has been signaled. Returns
an error if wake_locks
is signaled at the end of suspension, or an error is
encountered when suspending the container’s processes.
Sourcepub fn proxy_wake_channel(
&self,
payload: ManagerProxyWakeChannelRequest,
) -> Result<(), Error>
pub fn proxy_wake_channel( &self, payload: ManagerProxyWakeChannelRequest, ) -> Result<(), Error>
Creates a pass-through proxy that forwards messages between the container_channel
and the
remote_channel
.
If any messages arrive on remote_channel
while the container is suspended via
SuspendContainer
, the container will be resumed and counter
will be incremented.
Once that message is handled by the container, and it’s ok to suspend the container again (relative to that message), the counter is expected to be decremented.
Sourcepub fn register_wake_watcher(
&self,
payload: ManagerRegisterWakeWatcherRequest,
) -> QueryResponseFut<(), DefaultFuchsiaResourceDialect>
pub fn register_wake_watcher( &self, payload: ManagerRegisterWakeWatcherRequest, ) -> QueryResponseFut<(), DefaultFuchsiaResourceDialect>
Registers an eventpair that will be signaled when the container is suspended or resumed. The signals are ASLEEP(USER_1) and AWAKE(USER_0).
The kernel returns AWAKE upon initial registration of the eventpair.
Trait Implementations§
Source§impl Clone for ManagerProxy
impl Clone for ManagerProxy
Source§fn clone(&self) -> ManagerProxy
fn clone(&self) -> ManagerProxy
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for ManagerProxy
impl Debug for ManagerProxy
Source§impl ManagerProxyInterface for ManagerProxy
impl ManagerProxyInterface for ManagerProxy
type SuspendContainerResponseFut = QueryResponseFut<Result<ManagerSuspendContainerResponse, SuspendError>>
type RegisterWakeWatcherResponseFut = QueryResponseFut<()>
fn suspend_container( &self, payload: ManagerSuspendContainerRequest, ) -> Self::SuspendContainerResponseFut
fn proxy_wake_channel( &self, payload: ManagerProxyWakeChannelRequest, ) -> Result<(), Error>
fn register_wake_watcher( &self, payload: ManagerRegisterWakeWatcherRequest, ) -> Self::RegisterWakeWatcherResponseFut
Source§impl Proxy for ManagerProxy
impl Proxy for ManagerProxy
Source§type Protocol = ManagerMarker
type Protocol = ManagerMarker
Proxy
controls.