Enum PeripheralError
#[repr(u32)]pub enum PeripheralError {
NotSupported = 1,
AdvertisingDataTooLong = 2,
ScanResponseDataTooLong = 3,
InvalidParameters = 4,
Aborted = 5,
Failed = 6,
}
Variants§
NotSupported = 1
The operation or parameters requested are not supported on the current hardware.
AdvertisingDataTooLong = 2
The provided advertising data exceeds the maximum allowed length when encoded.
ScanResponseDataTooLong = 3
The provided scan response data exceeds the maximum allowed length when encoded.
InvalidParameters = 4
The requested parameters are invalid.
Aborted = 5
The request to start advertising was aborted, for example by issuing a new request with new parameters.
Failed = 6
Advertising could not be initiated due to a hardware or system error.
Implementations§
§impl PeripheralError
impl PeripheralError
pub fn from_primitive(prim: u32) -> Option<PeripheralError>
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 PeripheralError
impl Clone for PeripheralError
§fn clone(&self) -> PeripheralError
fn clone(&self) -> PeripheralError
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 PeripheralError
impl Debug for PeripheralError
§impl<D> Decode<PeripheralError, D> for PeripheralErrorwhere
D: ResourceDialect,
impl<D> Decode<PeripheralError, D> for PeripheralErrorwhere
D: ResourceDialect,
§fn new_empty() -> PeripheralError
fn new_empty() -> PeripheralError
Creates a valid instance of
Self
. The specific value does not matter,
since it will be overwritten by decode
.§impl<D> Encode<PeripheralError, D> for PeripheralErrorwhere
D: ResourceDialect,
impl<D> Encode<PeripheralError, D> for PeripheralErrorwhere
D: ResourceDialect,
§impl Hash for PeripheralError
impl Hash for PeripheralError
§impl Ord for PeripheralError
impl Ord for PeripheralError
§impl PartialEq for PeripheralError
impl PartialEq for PeripheralError
§impl PartialOrd for PeripheralError
impl PartialOrd for PeripheralError
§impl TypeMarker for PeripheralError
impl TypeMarker for PeripheralError
§type Owned = PeripheralError
type Owned = PeripheralError
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 PeripheralError
impl ValueTypeMarker for PeripheralError
§type Borrowed<'a> = PeripheralError
type Borrowed<'a> = PeripheralError
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: &<PeripheralError as TypeMarker>::Owned,
) -> <PeripheralError as ValueTypeMarker>::Borrowed<'_>
fn borrow( value: &<PeripheralError as TypeMarker>::Owned, ) -> <PeripheralError as ValueTypeMarker>::Borrowed<'_>
Cheaply converts from
&Self::Owned
to Self::Borrowed
.impl Copy for PeripheralError
impl Eq for PeripheralError
impl StructuralPartialEq for PeripheralError
Auto Trait Implementations§
impl Freeze for PeripheralError
impl RefUnwindSafe for PeripheralError
impl Send for PeripheralError
impl Sync for PeripheralError
impl Unpin for PeripheralError
impl UnwindSafe for PeripheralError
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