Enum RebootReason
#[repr(u32)]pub enum RebootReason {
UserRequest = 1,
SystemUpdate = 2,
RetrySystemUpdate = 8,
HighTemperature = 3,
FactoryDataReset = 6,
SessionFailure = 4,
SysmgrFailure = 5,
CriticalComponentFailure = 7,
ZbiSwap = 9,
OutOfMemory = 10,
}
Expand description
Why the system reboots.
Replaced by RebootReason2
.
Variants§
UserRequest = 1
SystemUpdate = 2
A new system update has been downloaded.
RetrySystemUpdate = 8
Applying the system update has failed.
HighTemperature = 3
FactoryDataReset = 6
SessionFailure = 4
Sessionmgr has failed.
SysmgrFailure = 5
sysmgr crashed.
CriticalComponentFailure = 7
A critical system component has failed.
ZbiSwap = 9
A boot partition change was effected.
OutOfMemory = 10
The system hit a critical low threshold of available memory.
Implementations§
§impl RebootReason
impl RebootReason
pub fn from_primitive(prim: u32) -> Option<RebootReason>
pub const fn into_primitive(self) -> u32
pub fn is_unknown(&self) -> bool
👎Deprecated: Strict enums should not use
is_unknown
Trait Implementations§
§impl Clone for RebootReason
impl Clone for RebootReason
§fn clone(&self) -> RebootReason
fn clone(&self) -> RebootReason
Returns a copy 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 more§impl Debug for RebootReason
impl Debug for RebootReason
§impl<D> Decode<RebootReason, D> for RebootReasonwhere
D: ResourceDialect,
impl<D> Decode<RebootReason, D> for RebootReasonwhere
D: ResourceDialect,
§fn new_empty() -> RebootReason
fn new_empty() -> RebootReason
Creates a valid instance of
Self
. The specific value does not matter,
since it will be overwritten by decode
.§impl<D> Encode<RebootReason, D> for RebootReasonwhere
D: ResourceDialect,
impl<D> Encode<RebootReason, D> for RebootReasonwhere
D: ResourceDialect,
§impl Hash for RebootReason
impl Hash for RebootReason
§impl Ord for RebootReason
impl Ord for RebootReason
§impl PartialEq for RebootReason
impl PartialEq for RebootReason
§impl PartialOrd for RebootReason
impl PartialOrd for RebootReason
§impl TypeMarker for RebootReason
impl TypeMarker for RebootReason
§type Owned = RebootReason
type Owned = RebootReason
The owned Rust type which this FIDL type decodes into.
§fn inline_align(_context: Context) -> usize
fn inline_align(_context: Context) -> usize
Returns the minimum required alignment of the inline portion of the
encoded object. It must be a (nonzero) power of two.
§fn inline_size(_context: Context) -> usize
fn inline_size(_context: Context) -> usize
Returns the size of the inline portion of the encoded object, including
padding for alignment. Must be a multiple of
inline_align
.§fn encode_is_copy() -> bool
fn encode_is_copy() -> bool
Returns true if the memory layout of
Self::Owned
matches the FIDL wire
format and encoding requires no validation. When true, we can optimize
encoding arrays and vectors of Self::Owned
to a single memcpy. Read more§fn decode_is_copy() -> bool
fn decode_is_copy() -> bool
Returns true if the memory layout of
Self::Owned
matches the FIDL wire
format and decoding requires no validation. When true, we can optimize
decoding arrays and vectors of Self::Owned
to a single memcpy.§impl ValueTypeMarker for RebootReason
impl ValueTypeMarker for RebootReason
§type Borrowed<'a> = RebootReason
type Borrowed<'a> = RebootReason
The Rust type to use for encoding. This is a particular
Encode<Self>
type cheaply obtainable from &Self::Owned
. There are three cases: Read more§fn borrow(
value: &<RebootReason as TypeMarker>::Owned,
) -> <RebootReason as ValueTypeMarker>::Borrowed<'_>
fn borrow( value: &<RebootReason as TypeMarker>::Owned, ) -> <RebootReason as ValueTypeMarker>::Borrowed<'_>
Cheaply converts from
&Self::Owned
to Self::Borrowed
.impl Copy for RebootReason
impl Eq for RebootReason
impl StructuralPartialEq for RebootReason
Auto Trait Implementations§
impl Freeze for RebootReason
impl RefUnwindSafe for RebootReason
impl Send for RebootReason
impl Sync for RebootReason
impl Unpin for RebootReason
impl UnwindSafe for RebootReason
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