#[repr(u32)]pub enum ContentType {
Other = 1,
Audio = 2,
Video = 3,
Music = 4,
TvShow = 5,
Movie = 6,
}
Expand description
The type of content playing back, which should be set to the largest applicable value.
Variants§
Other = 1
Content does not qualify for any of the other values.
Audio = 2
Audio-only content that does not qualify as music.
Video = 3
Video-only or audio-video content that does not qualify as a TV show or a movie.
Music = 4
Audio-only content generally recognized as music.
TvShow = 5
Audio-video content that is part of a television or streaming series.
Movie = 6
Audio-video content consisting of a feature film.
Implementations§
Source§impl ContentType
impl ContentType
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 ContentType
impl Clone for ContentType
Source§fn clone(&self) -> ContentType
fn clone(&self) -> ContentType
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 ContentType
impl Debug for ContentType
Source§impl<D: ResourceDialect> Decode<ContentType, D> for ContentType
impl<D: ResourceDialect> Decode<ContentType, D> for ContentType
Source§impl<D: ResourceDialect> Encode<ContentType, D> for ContentType
impl<D: ResourceDialect> Encode<ContentType, D> for ContentType
Source§impl Hash for ContentType
impl Hash for ContentType
Source§impl Ord for ContentType
impl Ord for ContentType
Source§fn cmp(&self, other: &ContentType) -> Ordering
fn cmp(&self, other: &ContentType) -> 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 ContentType
impl PartialEq for ContentType
Source§impl PartialOrd for ContentType
impl PartialOrd for ContentType
Source§impl TypeMarker for ContentType
impl TypeMarker for ContentType
Source§type Owned = ContentType
type Owned = ContentType
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 ContentType
impl ValueTypeMarker for ContentType
Source§type Borrowed<'a> = ContentType
type Borrowed<'a> = ContentType
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 ContentType
impl Eq for ContentType
impl StructuralPartialEq for ContentType
Auto Trait Implementations§
impl Freeze for ContentType
impl RefUnwindSafe for ContentType
impl Send for ContentType
impl Sync for ContentType
impl Unpin for ContentType
impl UnwindSafe for ContentType
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)