pub struct ControllerProxy { /* private fields */ }
Implementations§
Source§impl ControllerProxy
impl ControllerProxy
Sourcepub fn new(channel: AsyncChannel) -> Self
pub fn new(channel: AsyncChannel) -> Self
Create a new Proxy for fuchsia.blackout.test/Controller.
Sourcepub fn take_event_stream(&self) -> ControllerEventStream
pub fn take_event_stream(&self) -> ControllerEventStream
Get a Stream of events from the remote end of the protocol.
§Panics
Panics if the event stream was already taken.
Sourcepub fn setup(
&self,
device_label: &str,
device_path: Option<&str>,
seed: u64,
) -> QueryResponseFut<ControllerSetupResult, DefaultFuchsiaResourceDialect>
pub fn setup( &self, device_label: &str, device_path: Option<&str>, seed: u64, ) -> QueryResponseFut<ControllerSetupResult, DefaultFuchsiaResourceDialect>
Run the setup step for this test. Often, this involves formatting the filesystem of choice onto the block device, and perhaps setting up a base of files to work with.
Sourcepub fn test(
&self,
device_label: &str,
device_path: Option<&str>,
seed: u64,
duration: u64,
) -> QueryResponseFut<ControllerTestResult, DefaultFuchsiaResourceDialect>
pub fn test( &self, device_label: &str, device_path: Option<&str>, seed: u64, duration: u64, ) -> QueryResponseFut<ControllerTestResult, DefaultFuchsiaResourceDialect>
Run the test step for this test. This kicks off the load generation algorithm for this test, which will run indefinitely. It’s expected that this load will be interrupted by a power cycle. If the provided duration is non-zero, this protocol will return after approximately that amount of time, but the load will continue to run. If the duration provided is zero, then the test will return when it’s done, which for a lot of normal blackout tests might be never.
Sourcepub fn verify(
&self,
device_label: &str,
device_path: Option<&str>,
seed: u64,
) -> QueryResponseFut<ControllerVerifyResult, DefaultFuchsiaResourceDialect>
pub fn verify( &self, device_label: &str, device_path: Option<&str>, seed: u64, ) -> QueryResponseFut<ControllerVerifyResult, DefaultFuchsiaResourceDialect>
Run the verify step for this test. Most of the time it involves running fsck on the block device and returning the result.
Trait Implementations§
Source§impl Clone for ControllerProxy
impl Clone for ControllerProxy
Source§fn clone(&self) -> ControllerProxy
fn clone(&self) -> ControllerProxy
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl ControllerProxyInterface for ControllerProxy
impl ControllerProxyInterface for ControllerProxy
type SetupResponseFut = QueryResponseFut<Result<(), i32>>
type TestResponseFut = QueryResponseFut<Result<(), i32>>
type VerifyResponseFut = QueryResponseFut<Result<(), i32>>
fn setup( &self, device_label: &str, device_path: Option<&str>, seed: u64, ) -> Self::SetupResponseFut
fn test( &self, device_label: &str, device_path: Option<&str>, seed: u64, duration: u64, ) -> Self::TestResponseFut
fn verify( &self, device_label: &str, device_path: Option<&str>, seed: u64, ) -> Self::VerifyResponseFut
Source§impl Debug for ControllerProxy
impl Debug for ControllerProxy
Source§impl Proxy for ControllerProxy
impl Proxy for ControllerProxy
Source§type Protocol = ControllerMarker
type Protocol = ControllerMarker
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
Auto Trait Implementations§
impl Freeze for ControllerProxy
impl !RefUnwindSafe for ControllerProxy
impl Send for ControllerProxy
impl Sync for ControllerProxy
impl Unpin for ControllerProxy
impl !UnwindSafe for ControllerProxy
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
)