pub struct Kinds {
pub movies: bool,
pub episodes: bool,
pub tracks: bool,
}Expand description
The kinds of item a playlist may hold, ticked when it is made. They can change later only to allow more.
Fields§
§movies: bool§episodes: bool§tracks: boolImplementations§
Source§impl Kinds
impl Kinds
Sourcepub fn allows(self, kind: MediaKind) -> bool
pub fn allows(self, kind: MediaKind) -> bool
Whether an item of kind may be added. A season or show adds its
episodes, an album or artist its tracks: they are allowed when
those are.
Sourcepub fn widen_only(self, to: Kinds) -> bool
pub fn widen_only(self, to: Kinds) -> bool
Whether to keeps every kind these allow: the only change a
playlist’s kinds may make.
Trait Implementations§
impl Copy for Kinds
Source§impl<'de> Deserialize<'de> for Kinds
impl<'de> Deserialize<'de> for Kinds
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for Kinds
impl StructuralPartialEq for Kinds
Auto Trait Implementations§
impl Freeze for Kinds
impl RefUnwindSafe for Kinds
impl Send for Kinds
impl Sync for Kinds
impl Unpin for Kinds
impl UnsafeUnpin for Kinds
impl UnwindSafe for Kinds
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