Struct mpris_server::LocalServer
source · pub struct LocalServer<T>where
T: LocalPlayerInterface + 'static,{ /* private fields */ }Expand description
Implementations§
source§impl<T> LocalServer<T>where
T: LocalPlayerInterface + 'static,
impl<T> LocalServer<T>where T: LocalPlayerInterface + 'static,
pub fn new(bus_name_suffix: &str, imp: T) -> Result<Self>
sourcepub async fn connection(&self) -> Result<&Connection>
pub async fn connection(&self) -> Result<&Connection>
Returns a reference to the inner Connection.
If you needed to call this, consider filing an issue.
sourcepub async fn init_and_run(&self) -> Result<()>
pub async fn init_and_run(&self) -> Result<()>
Initialize the connection and run the server. This method will continually run until the server is dropped.
This is no-op if the server is already running.
pub async fn seeked(&self, position: Time) -> Result<()>
pub async fn properties_changed( &self, properties: impl Into<BitFlags<Property>> ) -> Result<()>
source§impl<T> LocalServer<T>where
T: LocalTrackListInterface + 'static,
impl<T> LocalServer<T>where T: LocalTrackListInterface + 'static,
pub fn new_with_track_list(bus_name_suffix: &str, imp: T) -> Result<Self>
pub async fn track_list_replaced( &self, tracks: Vec<TrackId>, current_track: TrackId ) -> Result<()>
pub async fn track_added( &self, metadata: Metadata, after_track: TrackId ) -> Result<()>
pub async fn track_removed(&self, track_id: TrackId) -> Result<()>
pub async fn track_metadata_changed( &self, track_id: TrackId, metadata: Metadata ) -> Result<()>
pub async fn track_list_properties_changed( &self, properties: impl Into<BitFlags<TrackListProperty>> ) -> Result<()>
source§impl<T> LocalServer<T>where
T: LocalPlaylistsInterface + 'static,
impl<T> LocalServer<T>where T: LocalPlaylistsInterface + 'static,
pub fn new_with_playlists(bus_name_suffix: &str, imp: T) -> Result<Self>
pub async fn playlist_changed(&self, playlist: Playlist) -> Result<()>
pub async fn playlists_properties_changed( &self, properties: impl Into<BitFlags<PlaylistsProperty>> ) -> Result<()>
source§impl<T> LocalServer<T>where
T: LocalTrackListInterface + LocalPlaylistsInterface + 'static,
impl<T> LocalServer<T>where T: LocalTrackListInterface + LocalPlaylistsInterface + 'static,
pub fn new_with_all(bus_name_suffix: &str, imp: T) -> Result<Self>
Trait Implementations§
Auto Trait Implementations§
impl<T> !RefUnwindSafe for LocalServer<T>
impl<T> !Send for LocalServer<T>
impl<T> !Sync for LocalServer<T>
impl<T> Unpin for LocalServer<T>
impl<T> !UnwindSafe for LocalServer<T>
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