InnerSong

Struct InnerSong 

pub struct InnerSong {
Show 21 fields pub id: Option<String>, pub path: Option<String>, pub size: Option<f64>, pub title: Option<String>, pub date: Option<String>, pub year: Option<String>, pub lyrics: Option<String>, pub release_type: Option<String>, pub bitrate: Option<f64>, pub codec: Option<String>, pub container: Option<String>, pub duration: Option<Duration>, pub sample_rate: Option<f64>, pub hash: Option<String>, pub type: i32, pub url: Option<String>, pub song_cover_path_high: Option<String>, pub playback_url: Option<String>, pub song_cover_path_low: Option<String>, pub date_added: Option<i64>, pub track_no: Option<f64>,
}

Fields§

§id: Option<String>

_id

§path: Option<String>§size: Option<f64>§title: Option<String>§date: Option<String>§year: Option<String>§lyrics: Option<String>§release_type: Option<String>§bitrate: Option<f64>§codec: Option<String>§container: Option<String>§duration: Option<Duration>§sample_rate: Option<f64>§hash: Option<String>§type: i32§url: Option<String>§song_cover_path_high: Option<String>§playback_url: Option<String>§song_cover_path_low: Option<String>§date_added: Option<i64>§track_no: Option<f64>

Implementations§

§

impl InnerSong

pub fn id(&self) -> &str

Returns the value of id, or the default value if id is unset.

pub fn path(&self) -> &str

Returns the value of path, or the default value if path is unset.

pub fn size(&self) -> f64

Returns the value of size, or the default value if size is unset.

pub fn title(&self) -> &str

Returns the value of title, or the default value if title is unset.

pub fn date(&self) -> &str

Returns the value of date, or the default value if date is unset.

pub fn year(&self) -> &str

Returns the value of year, or the default value if year is unset.

pub fn lyrics(&self) -> &str

Returns the value of lyrics, or the default value if lyrics is unset.

pub fn release_type(&self) -> &str

Returns the value of release_type, or the default value if release_type is unset.

pub fn bitrate(&self) -> f64

Returns the value of bitrate, or the default value if bitrate is unset.

pub fn codec(&self) -> &str

Returns the value of codec, or the default value if codec is unset.

pub fn container(&self) -> &str

Returns the value of container, or the default value if container is unset.

pub fn sample_rate(&self) -> f64

Returns the value of sample_rate, or the default value if sample_rate is unset.

pub fn hash(&self) -> &str

Returns the value of hash, or the default value if hash is unset.

pub fn type(&self) -> SongType

Returns the enum value of type, or the default if the field is set to an invalid enum value.

pub fn set_type(&mut self, value: SongType)

Sets type to the provided enum value.

pub fn url(&self) -> &str

Returns the value of url, or the default value if url is unset.

pub fn song_cover_path_high(&self) -> &str

Returns the value of song_cover_path_high, or the default value if song_cover_path_high is unset.

pub fn playback_url(&self) -> &str

Returns the value of playback_url, or the default value if playback_url is unset.

pub fn song_cover_path_low(&self) -> &str

Returns the value of song_cover_path_low, or the default value if song_cover_path_low is unset.

pub fn date_added(&self) -> i64

Returns the value of date_added, or the default value if date_added is unset.

pub fn track_no(&self) -> f64

Returns the value of track_no, or the default value if track_no is unset.

Trait Implementations§

§

impl Clone for InnerSong

§

fn clone(&self) -> InnerSong

Returns a duplicate of the value. Read more
1.0.0§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
§

impl Debug for InnerSong

§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
§

impl Default for InnerSong

§

fn default() -> InnerSong

Returns the “default value” for a type. Read more
§

impl Message for InnerSong

§

fn encoded_len(&self) -> usize

Returns the encoded length of the message without a length delimiter.
§

fn clear(&mut self)

Clears the message, resetting all fields to their default.
§

fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>
where Self: Sized,

Encodes the message to a buffer. Read more
§

fn encode_to_vec(&self) -> Vec<u8>
where Self: Sized,

Encodes the message to a newly allocated buffer.
§

fn encode_length_delimited( &self, buf: &mut impl BufMut, ) -> Result<(), EncodeError>
where Self: Sized,

Encodes the message with a length-delimiter to a buffer. Read more
§

fn encode_length_delimited_to_vec(&self) -> Vec<u8>
where Self: Sized,

Encodes the message with a length-delimiter to a newly allocated buffer.
§

fn decode(buf: impl Buf) -> Result<Self, DecodeError>
where Self: Default,

Decodes an instance of the message from a buffer. Read more
§

fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>
where Self: Default,

Decodes a length-delimited instance of the message from the buffer.
§

fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>
where Self: Sized,

Decodes an instance of the message from a buffer, and merges it into self. Read more
§

fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>
where Self: Sized,

Decodes a length-delimited instance of the message from buffer, and merges it into self.
§

impl PartialEq for InnerSong

§

fn eq(&self, other: &InnerSong) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
§

impl StructuralPartialEq for InnerSong

Auto Trait Implementations§

Blanket Implementations§

§

impl<T> Any for T
where T: 'static + ?Sized,

§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<T> Borrow<T> for T
where T: ?Sized,

§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
§

impl<T> BorrowMut<T> for T
where T: ?Sized,

§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<T> CloneToUninit for T
where T: Clone,

§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
§

impl<T> From<T> for T

§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
§

impl<T, U> Into<U> for T
where U: From<T>,

§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more