#[repr(u32)]pub enum Role {
Source = 1,
Sink = 2,
}Expand description
Enum corresponding to the A2DP SRC/SNK roles as defined in the A2DP v1.3.2 profile specification, section 2.2.
Variants§
Source = 1
Act as a source of digital audio streams, sending audio to peers.
Sink = 2
Act as a sink of digital audio streams and play audio sent from peers.
Implementations§
Trait Implementations§
Source§impl<D> Decode<Role, D> for Rolewhere
D: ResourceDialect,
impl<D> Decode<Role, D> for Rolewhere
D: ResourceDialect,
Source§impl Ord for Role
impl Ord for Role
Source§impl PartialOrd for Role
impl PartialOrd for Role
Source§impl TypeMarker for Role
impl TypeMarker for Role
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 Role
impl ValueTypeMarker for Role
Source§type Borrowed<'a> = Role
type Borrowed<'a> = Role
The Rust type to use for encoding. This is a particular
Encode<Self>
type cheaply obtainable from &Self::Owned. There are three cases: Read moreSource§fn borrow(
value: &<Role as TypeMarker>::Owned,
) -> <Role as ValueTypeMarker>::Borrowed<'_>
fn borrow( value: &<Role as TypeMarker>::Owned, ) -> <Role as ValueTypeMarker>::Borrowed<'_>
Cheaply converts from
&Self::Owned to Self::Borrowed.impl Copy for Role
impl Eq for Role
impl StructuralPartialEq for Role
Auto Trait Implementations§
impl Freeze for Role
impl RefUnwindSafe for Role
impl Send for Role
impl Sync for Role
impl Unpin for Role
impl UnwindSafe for Role
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