#[non_exhaustive]pub enum SandboxState {
Created,
Running,
Paused,
Stopped,
Destroyed,
}Expand description
Sandbox lifecycle state.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Created
Created but not yet started.
Running
Running and accepting exec calls.
Paused
Paused (checkpointed).
Stopped
Stopped — no further execution possible.
Destroyed
Destroyed — resources released.
Implementations§
Source§impl SandboxState
impl SandboxState
Sourcepub fn valid_transition(&self, to: &SandboxState) -> bool
pub fn valid_transition(&self, to: &SandboxState) -> bool
Check whether transitioning from this state to to is valid.
Trait Implementations§
Source§impl Clone for SandboxState
impl Clone for SandboxState
Source§fn clone(&self) -> SandboxState
fn clone(&self) -> SandboxState
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SandboxState
impl Debug for SandboxState
Source§impl<'de> Deserialize<'de> for SandboxState
impl<'de> Deserialize<'de> for SandboxState
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for SandboxState
impl Display for SandboxState
Source§impl PartialEq for SandboxState
impl PartialEq for SandboxState
Source§impl Serialize for SandboxState
impl Serialize for SandboxState
impl Copy for SandboxState
impl Eq for SandboxState
impl StructuralPartialEq for SandboxState
Auto Trait Implementations§
impl Freeze for SandboxState
impl RefUnwindSafe for SandboxState
impl Send for SandboxState
impl Sync for SandboxState
impl Unpin for SandboxState
impl UnsafeUnpin for SandboxState
impl UnwindSafe for SandboxState
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