#[repr(u32)]pub enum MetricsLoggerError {
NoDrivers = 1,
InvalidSamplingInterval = 2,
AlreadyLogging = 3,
DuplicatedMetric = 4,
TooManyActiveClients = 5,
InvalidStatisticsInterval = 6,
Internal = 7,
}
Expand description
Errors associated with MetricsLogger methods. If the request contains any of the following errors, it will fail without affecting the existing logging tasks.
Variants§
NoDrivers = 1
Indicates that no driver is found for requested metric logging.
InvalidSamplingInterval = 2
Indicates that an invalid sampling interval was provided.
AlreadyLogging = 3
Requests to start logging will fail if logging is already active for a given client.
DuplicatedMetric = 4
Indicates that the logging request contains duplicated metric type.
TooManyActiveClients = 5
Indicates that the total number of active clients has reached the
allowed maxium (defined by MAX_CONCURRENT_CLIENTS = 20
in
the MetricsLogger to keep memory use bounded).
InvalidStatisticsInterval = 6
Indicates that statistics is enabled and an invalid statistics interval is provided.
Internal = 7
Indicates that the request failed due to an internal error.
Implementations§
source§impl MetricsLoggerError
impl MetricsLoggerError
pub fn from_primitive(prim: u32) -> Option<Self>
pub const fn into_primitive(self) -> u32
pub fn is_unknown(&self) -> bool
👎Deprecated: Strict enums should not use
is_unknown
Trait Implementations§
source§impl Clone for MetricsLoggerError
impl Clone for MetricsLoggerError
source§fn clone(&self) -> MetricsLoggerError
fn clone(&self) -> MetricsLoggerError
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 moresource§impl Debug for MetricsLoggerError
impl Debug for MetricsLoggerError
source§impl Decode<MetricsLoggerError> for MetricsLoggerError
impl Decode<MetricsLoggerError> for MetricsLoggerError
source§impl Hash for MetricsLoggerError
impl Hash for MetricsLoggerError
source§impl Ord for MetricsLoggerError
impl Ord for MetricsLoggerError
source§fn cmp(&self, other: &MetricsLoggerError) -> Ordering
fn cmp(&self, other: &MetricsLoggerError) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq for MetricsLoggerError
impl PartialEq for MetricsLoggerError
source§fn eq(&self, other: &MetricsLoggerError) -> bool
fn eq(&self, other: &MetricsLoggerError) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for MetricsLoggerError
impl PartialOrd for MetricsLoggerError
source§fn partial_cmp(&self, other: &MetricsLoggerError) -> Option<Ordering>
fn partial_cmp(&self, other: &MetricsLoggerError) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl TypeMarker for MetricsLoggerError
impl TypeMarker for MetricsLoggerError
§type Owned = MetricsLoggerError
type Owned = MetricsLoggerError
The owned Rust type which this FIDL type decodes into.
source§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.
source§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
.source§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 moresource§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.source§impl ValueTypeMarker for MetricsLoggerError
impl ValueTypeMarker for MetricsLoggerError
§type Borrowed<'a> = MetricsLoggerError
type Borrowed<'a> = MetricsLoggerError
The Rust type to use for encoding. This is a particular
Encode<Self>
type cheaply obtainable from &Self::Owned
. There are three cases: Read moreimpl Copy for MetricsLoggerError
impl Eq for MetricsLoggerError
impl StructuralEq for MetricsLoggerError
impl StructuralPartialEq for MetricsLoggerError
Auto Trait Implementations§
impl RefUnwindSafe for MetricsLoggerError
impl Send for MetricsLoggerError
impl Sync for MetricsLoggerError
impl Unpin for MetricsLoggerError
impl UnwindSafe for MetricsLoggerError
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