Enum ScoSampleRate
pub enum ScoSampleRate {
Khz8,
Khz16,
// some variants omitted
}
Variants§
Implementations§
§impl ScoSampleRate
impl ScoSampleRate
pub fn from_primitive(prim: u8) -> Option<ScoSampleRate>
pub fn from_primitive_allow_unknown(prim: u8) -> ScoSampleRate
pub fn unknown() -> ScoSampleRate
pub const fn into_primitive(self) -> u8
pub fn is_unknown(&self) -> bool
Trait Implementations§
§impl Clone for ScoSampleRate
impl Clone for ScoSampleRate
§fn clone(&self) -> ScoSampleRate
fn clone(&self) -> ScoSampleRate
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 ScoSampleRate
impl Debug for ScoSampleRate
§impl<D> Decode<ScoSampleRate, D> for ScoSampleRatewhere
D: ResourceDialect,
impl<D> Decode<ScoSampleRate, D> for ScoSampleRatewhere
D: ResourceDialect,
§fn new_empty() -> ScoSampleRate
fn new_empty() -> ScoSampleRate
Creates a valid instance of
Self
. The specific value does not matter,
since it will be overwritten by decode
.§impl<D> Encode<ScoSampleRate, D> for ScoSampleRatewhere
D: ResourceDialect,
impl<D> Encode<ScoSampleRate, D> for ScoSampleRatewhere
D: ResourceDialect,
§impl Hash for ScoSampleRate
impl Hash for ScoSampleRate
§impl Ord for ScoSampleRate
impl Ord for ScoSampleRate
§impl PartialEq for ScoSampleRate
impl PartialEq for ScoSampleRate
§impl PartialOrd for ScoSampleRate
impl PartialOrd for ScoSampleRate
§impl TypeMarker for ScoSampleRate
impl TypeMarker for ScoSampleRate
§type Owned = ScoSampleRate
type Owned = ScoSampleRate
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 ScoSampleRate
impl ValueTypeMarker for ScoSampleRate
§type Borrowed<'a> = ScoSampleRate
type Borrowed<'a> = ScoSampleRate
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: &<ScoSampleRate as TypeMarker>::Owned,
) -> <ScoSampleRate as ValueTypeMarker>::Borrowed<'_>
fn borrow( value: &<ScoSampleRate as TypeMarker>::Owned, ) -> <ScoSampleRate as ValueTypeMarker>::Borrowed<'_>
Cheaply converts from
&Self::Owned
to Self::Borrowed
.impl Copy for ScoSampleRate
impl Eq for ScoSampleRate
impl StructuralPartialEq for ScoSampleRate
Auto Trait Implementations§
impl Freeze for ScoSampleRate
impl RefUnwindSafe for ScoSampleRate
impl Send for ScoSampleRate
impl Sync for ScoSampleRate
impl Unpin for ScoSampleRate
impl UnwindSafe for ScoSampleRate
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