pub enum ElementRunnerRequest {
SetLevel {
level: u8,
responder: ElementRunnerSetLevelResponder,
},
_UnknownMethod {
ordinal: u64,
control_handle: ElementRunnerControlHandle,
method_type: MethodType,
},
}
Expand description
The runner or operator of an element. This should be implemented by all element owners. The client end is passed to Power Broker via ElementSchema.element_runner. Power Broker calls SetLevel initially, and then whenever the required level of the element changes.
Variants§
SetLevel
Sets the level of the power element.
The server blocks while making the level transition. It returns once the transition to the new required level is complete. If the element cannot transition to the new required level and it cannot retry, the channel will be closed.
_UnknownMethod
An interaction was received which does not match any known method.
Fields
This variant is marked as non-exhaustive
Non-exhaustive enum variants could have additional fields added in future. Therefore, non-exhaustive enum variants cannot be constructed in external crates and cannot be matched against.
§
control_handle: ElementRunnerControlHandle
§
method_type: MethodType
Implementations§
Source§impl ElementRunnerRequest
impl ElementRunnerRequest
pub fn into_set_level(self) -> Option<(u8, ElementRunnerSetLevelResponder)>
Sourcepub fn method_name(&self) -> &'static str
pub fn method_name(&self) -> &'static str
Name of the method defined in FIDL
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ElementRunnerRequest
impl !RefUnwindSafe for ElementRunnerRequest
impl Send for ElementRunnerRequest
impl Sync for ElementRunnerRequest
impl Unpin for ElementRunnerRequest
impl !UnwindSafe for ElementRunnerRequest
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
Mutably borrows from an owned value. Read more