[][src]Struct sonor::Snapshot

pub struct Snapshot { /* fields omitted */ }

A Snapshot of the state the speaker is in right now. Useful for announcing some clip at a lower volume, then later resume where you left off. The struct is obtained by calling the snapshot-method on a speaker and applied using Speaker::apply.

Implementations

impl Snapshot[src]

pub fn set_volume(&mut self, volume: u16) -> &mut Self[src]

Sets the volume of the snapshot

pub fn set_is_playing(&mut self, is_playing: bool) -> &mut Self[src]

Sets whether the speaker is playing

pub fn set_track_info(&mut self, track_info: TrackInfo) -> &mut Self[src]

Specifies the current track info

pub fn set_transport_uri(
    &mut self,
    transport_uri: impl Into<String>
) -> &mut Self
[src]

Specifies the current track info

Trait Implementations

impl Debug for Snapshot[src]

impl Default for Snapshot[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.