pub enum ManagerRequest {
SuspendContainer {
payload: ManagerSuspendContainerRequest,
responder: ManagerSuspendContainerResponder,
},
ProxyWakeChannel {
payload: ManagerProxyWakeChannelRequest,
control_handle: ManagerControlHandle,
},
AddWakeSource {
payload: ManagerAddWakeSourceRequest,
control_handle: ManagerControlHandle,
},
RemoveWakeSource {
payload: ManagerRemoveWakeSourceRequest,
control_handle: ManagerControlHandle,
},
RegisterWakeWatcher {
payload: ManagerRegisterWakeWatcherRequest,
responder: ManagerRegisterWakeWatcherResponder,
},
CreatePager {
payload: ManagerCreatePagerRequest,
control_handle: ManagerControlHandle,
},
#[non_exhaustive]
_UnknownMethod {
ordinal: u64,
control_handle: ManagerControlHandle,
method_type: MethodType,
},
}
Variants§
SuspendContainer
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.
ProxyWakeChannel
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.
AddWakeSource
Adds signals
on handle
as a way to prevent the container from suspending, or wake it
if it is already suspended.
RemoveWakeSource
Removes a wake source handle from the container_job
.
If the container is currently suspended, the handle
may still wake the container if
its signals are raised. To ensure that the wake source never wakes the container again
after this call, the client must make sure that the signals are cleared and not raised
again.
RegisterWakeWatcher
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.
CreatePager
Creates a Pager
instance with the provided backing_vmo
and block_size
.
_UnknownMethod
An interaction was received which does not match any known method.
Fields
This variant is marked as non-exhaustive
control_handle: ManagerControlHandle
method_type: MethodType
Implementations§
Source§impl ManagerRequest
impl ManagerRequest
pub fn into_suspend_container( self, ) -> Option<(ManagerSuspendContainerRequest, ManagerSuspendContainerResponder)>
pub fn into_proxy_wake_channel( self, ) -> Option<(ManagerProxyWakeChannelRequest, ManagerControlHandle)>
pub fn into_add_wake_source( self, ) -> Option<(ManagerAddWakeSourceRequest, ManagerControlHandle)>
pub fn into_remove_wake_source( self, ) -> Option<(ManagerRemoveWakeSourceRequest, ManagerControlHandle)>
pub fn into_register_wake_watcher( self, ) -> Option<(ManagerRegisterWakeWatcherRequest, ManagerRegisterWakeWatcherResponder)>
pub fn into_create_pager( self, ) -> Option<(ManagerCreatePagerRequest, ManagerControlHandle)>
Sourcepub fn method_name(&self) -> &'static str
pub fn method_name(&self) -> &'static str
Name of the method defined in FIDL