From b88908d35d688d547c35be798d6a447a6aabf7d9 Mon Sep 17 00:00:00 2001 From: SeaDve Date: Wed, 13 Sep 2023 11:38:15 +0000 Subject: [PATCH] deploy: 750b5068778f4073139f2678a5ee0032bbbcfc3a --- implementors/core/clone/trait.Clone.js | 2 +- implementors/core/cmp/trait.Eq.js | 2 +- implementors/core/cmp/trait.Ord.js | 3 + implementors/core/cmp/trait.PartialEq.js | 2 +- implementors/core/cmp/trait.PartialOrd.js | 3 + implementors/core/convert/trait.From.js | 2 +- implementors/core/convert/trait.TryFrom.js | 2 +- implementors/core/default/trait.Default.js | 2 +- implementors/core/fmt/trait.Debug.js | 2 +- implementors/core/fmt/trait.Display.js | 2 +- implementors/core/hash/trait.Hash.js | 2 +- implementors/core/marker/trait.Copy.js | 2 +- implementors/core/marker/trait.Freeze.js | 2 +- implementors/core/marker/trait.Send.js | 2 +- .../core/marker/trait.StructuralEq.js | 2 +- .../core/marker/trait.StructuralPartialEq.js | 2 +- implementors/core/marker/trait.Sync.js | 2 +- implementors/core/marker/trait.Unpin.js | 2 +- implementors/core/ops/arith/trait.Add.js | 3 + .../core/ops/arith/trait.AddAssign.js | 3 + implementors/core/ops/arith/trait.Sub.js | 3 + .../core/ops/arith/trait.SubAssign.js | 3 + implementors/core/ops/bit/trait.BitXor.js | 2 +- implementors/core/ops/bit/trait.Not.js | 2 +- .../panic/unwind_safe/trait.RefUnwindSafe.js | 2 +- .../panic/unwind_safe/trait.UnwindSafe.js | 2 +- .../enumflags2/_internal/trait.RawBitFlags.js | 2 +- implementors/enumflags2/trait.BitFlag.js | 2 +- implementors/serde/de/trait.Deserialize.js | 2 +- implementors/serde/ser/trait.Serialize.js | 2 +- implementors/zvariant/type/trait.Type.js | 2 +- mpris_server/all.html | 2 +- mpris_server/builder/index.html | 5 +- .../builder/struct.MetadataBuilder.html | 17 +- .../builder/struct.PlayerBuilder.html | 8 +- mpris_server/enum.LoopStatus.html | 5 +- mpris_server/enum.PlaybackStatus.html | 3 +- mpris_server/enum.PlaylistOrdering.html | 5 +- mpris_server/enum.PlaylistsProperty.html | 2 +- mpris_server/enum.Property.html | 2 +- mpris_server/enum.TrackListProperty.html | 2 +- mpris_server/export/index.html | 3 +- mpris_server/index.html | 169 ++---- mpris_server/sidebar-items.js | 2 +- mpris_server/struct.LocalServer.html | 31 +- mpris_server/struct.MaybePlaylist.html | 16 +- mpris_server/struct.Metadata.html | 62 +- mpris_server/struct.Player.html | 18 +- mpris_server/struct.Playlist.html | 2 +- mpris_server/struct.Server.html | 39 +- mpris_server/struct.Time.html | 122 ++++ mpris_server/struct.TrackId.html | 12 +- mpris_server/time/struct.Time.html | 11 + mpris_server/trait.LocalPlayerInterface.html | 70 +-- .../trait.LocalPlaylistsInterface.html | 12 +- mpris_server/trait.LocalRootInterface.html | 26 +- .../trait.LocalTrackListInterface.html | 14 +- mpris_server/trait.PlayerInterface.html | 70 +-- mpris_server/trait.PlaylistsInterface.html | 18 +- mpris_server/trait.RootInterface.html | 26 +- mpris_server/trait.TrackListInterface.html | 29 +- mpris_server/type.DateTime.html | 3 +- mpris_server/type.PlaybackRate.html | 2 +- mpris_server/type.PlaylistId.html | 2 +- mpris_server/type.TimeInUs.html | 2 - mpris_server/type.Uri.html | 2 +- mpris_server/type.Volume.html | 2 +- search-index.js | 2 +- source-files.js | 2 +- src/mpris_server/lib.rs.html | 66 ++- src/mpris_server/local_server.rs.html | 72 ++- src/mpris_server/loop_status.rs.html | 4 +- src/mpris_server/metadata.rs.html | 26 +- src/mpris_server/playback_status.rs.html | 4 +- src/mpris_server/player.rs.html | 40 +- src/mpris_server/playlist.rs.html | 50 +- src/mpris_server/playlist_ordering.rs.html | 4 +- src/mpris_server/server.rs.html | 128 ++-- src/mpris_server/time.rs.html | 559 ++++++++++++++++++ src/mpris_server/track_id.rs.html | 16 +- 80 files changed, 1294 insertions(+), 563 deletions(-) create mode 100644 implementors/core/cmp/trait.Ord.js create mode 100644 implementors/core/cmp/trait.PartialOrd.js create mode 100644 implementors/core/ops/arith/trait.Add.js create mode 100644 implementors/core/ops/arith/trait.AddAssign.js create mode 100644 implementors/core/ops/arith/trait.Sub.js create mode 100644 implementors/core/ops/arith/trait.SubAssign.js create mode 100644 mpris_server/struct.Time.html create mode 100644 mpris_server/time/struct.Time.html delete mode 100644 mpris_server/type.TimeInUs.html create mode 100644 src/mpris_server/time.rs.html diff --git a/implementors/core/clone/trait.Clone.js b/implementors/core/clone/trait.Clone.js index 9d26f15..60827ac 100644 --- a/implementors/core/clone/trait.Clone.js +++ b/implementors/core/clone/trait.Clone.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl Clone for LoopStatus"],["impl Clone for PlaylistsProperty"],["impl Clone for PlaybackStatus"],["impl Clone for TrackId"],["impl Clone for Playlist"],["impl Clone for MetadataBuilder"],["impl Clone for Metadata"],["impl Clone for TrackListProperty"],["impl Clone for PlaylistOrdering"],["impl Clone for Property"],["impl Clone for MaybePlaylist"]] +"mpris_server":[["impl Clone for MetadataBuilder"],["impl Clone for LoopStatus"],["impl Clone for Time"],["impl Clone for MaybePlaylist"],["impl Clone for TrackId"],["impl Clone for Playlist"],["impl Clone for Metadata"],["impl Clone for Property"],["impl Clone for PlaylistsProperty"],["impl Clone for PlaybackStatus"],["impl Clone for PlaylistOrdering"],["impl Clone for TrackListProperty"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/cmp/trait.Eq.js b/implementors/core/cmp/trait.Eq.js index 713ea97..941f48f 100644 --- a/implementors/core/cmp/trait.Eq.js +++ b/implementors/core/cmp/trait.Eq.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl Eq for Playlist"],["impl Eq for LoopStatus"],["impl Eq for PlaylistsProperty"],["impl Eq for PlaylistOrdering"],["impl Eq for TrackId"],["impl Eq for PlaybackStatus"],["impl Eq for MaybePlaylist"],["impl Eq for TrackListProperty"],["impl Eq for Property"]] +"mpris_server":[["impl Eq for Property"],["impl Eq for Playlist"],["impl Eq for PlaylistOrdering"],["impl Eq for PlaybackStatus"],["impl Eq for TrackId"],["impl Eq for Time"],["impl Eq for TrackListProperty"],["impl Eq for PlaylistsProperty"],["impl Eq for LoopStatus"],["impl Eq for MaybePlaylist"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/cmp/trait.Ord.js b/implementors/core/cmp/trait.Ord.js new file mode 100644 index 0000000..e2421bc --- /dev/null +++ b/implementors/core/cmp/trait.Ord.js @@ -0,0 +1,3 @@ +(function() {var implementors = { +"mpris_server":[["impl Ord for Time"]] +};if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/cmp/trait.PartialEq.js b/implementors/core/cmp/trait.PartialEq.js index 441fbb1..b60d667 100644 --- a/implementors/core/cmp/trait.PartialEq.js +++ b/implementors/core/cmp/trait.PartialEq.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl PartialEq<PlaylistOrdering> for PlaylistOrdering"],["impl PartialEq<MaybePlaylist> for MaybePlaylist"],["impl PartialEq<TrackId> for TrackId"],["impl PartialEq<Metadata> for Metadata"],["impl PartialEq<Playlist> for Playlist"],["impl PartialEq<PlaybackStatus> for PlaybackStatus"],["impl PartialEq<TrackListProperty> for TrackListProperty"],["impl PartialEq<PlaylistsProperty> for PlaylistsProperty"],["impl PartialEq<LoopStatus> for LoopStatus"],["impl PartialEq<Property> for Property"]] +"mpris_server":[["impl PartialEq<Time> for Time"],["impl PartialEq<TrackId> for TrackId"],["impl PartialEq<LoopStatus> for LoopStatus"],["impl PartialEq<MaybePlaylist> for MaybePlaylist"],["impl PartialEq<PlaylistOrdering> for PlaylistOrdering"],["impl PartialEq<PlaylistsProperty> for PlaylistsProperty"],["impl PartialEq<Property> for Property"],["impl PartialEq<Playlist> for Playlist"],["impl PartialEq<PlaybackStatus> for PlaybackStatus"],["impl PartialEq<Metadata> for Metadata"],["impl PartialEq<TrackListProperty> for TrackListProperty"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/cmp/trait.PartialOrd.js b/implementors/core/cmp/trait.PartialOrd.js new file mode 100644 index 0000000..0437c28 --- /dev/null +++ b/implementors/core/cmp/trait.PartialOrd.js @@ -0,0 +1,3 @@ +(function() {var implementors = { +"mpris_server":[["impl PartialOrd<Time> for Time"]] +};if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/convert/trait.From.js b/implementors/core/convert/trait.From.js index c09499f..ee3dace 100644 --- a/implementors/core/convert/trait.From.js +++ b/implementors/core/convert/trait.From.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl<'a> From<LoopStatus> for Value<'a>"],["impl From<Playlist> for MaybePlaylist"],["impl<'a> From<MaybePlaylist> for Value<'a>"],["impl<'a> From<PlaybackStatus> for Value<'a>"],["impl From<TrackId> for Value<'static>"],["impl<'a> From<PlaylistOrdering> for Value<'a>"],["impl<'a> From<Metadata> for Value<'a>"],["impl<'a> From<Playlist> for Value<'a>"],["impl<'unowned, 'owned: 'unowned> From<&'owned TrackId> for ObjectPath<'unowned>"],["impl<'a> From<ObjectPath<'a>> for TrackId"],["impl From<TrackId> for ObjectPath<'static>"],["impl From<Option<Playlist>> for MaybePlaylist"]] +"mpris_server":[["impl<'a> From<Metadata> for Value<'a>"],["impl<'unowned, 'owned: 'unowned> From<&'owned TrackId> for ObjectPath<'unowned>"],["impl<'a> From<MaybePlaylist> for Value<'a>"],["impl From<MaybePlaylist> for Option<Playlist>"],["impl From<TrackId> for ObjectPath<'static>"],["impl From<TrackId> for Value<'static>"],["impl<'a> From<PlaylistOrdering> for Value<'a>"],["impl<'a> From<ObjectPath<'a>> for TrackId"],["impl From<Option<Playlist>> for MaybePlaylist"],["impl<'a> From<Playlist> for Value<'a>"],["impl<'a> From<LoopStatus> for Value<'a>"],["impl<'a> From<PlaybackStatus> for Value<'a>"],["impl<'a> From<Time> for Value<'a>"],["impl From<Playlist> for MaybePlaylist"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/convert/trait.TryFrom.js b/implementors/core/convert/trait.TryFrom.js index a93ce12..7dccb7e 100644 --- a/implementors/core/convert/trait.TryFrom.js +++ b/implementors/core/convert/trait.TryFrom.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl TryFrom<&str> for TrackId"],["impl<'a> TryFrom<Value<'a>> for LoopStatus"],["impl TryFrom<String> for TrackId"]] +"mpris_server":[["impl<'a> TryFrom<Value<'a>> for LoopStatus"],["impl TryFrom<String> for TrackId"],["impl TryFrom<&str> for TrackId"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/default/trait.Default.js b/implementors/core/default/trait.Default.js index cbee857..6d7ba38 100644 --- a/implementors/core/default/trait.Default.js +++ b/implementors/core/default/trait.Default.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl Default for TrackId"],["impl Default for Metadata"],["impl Default for MetadataBuilder"]] +"mpris_server":[["impl Default for TrackId"],["impl Default for MetadataBuilder"],["impl Default for Time"],["impl Default for Metadata"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/fmt/trait.Debug.js b/implementors/core/fmt/trait.Debug.js index c47e840..79acdaf 100644 --- a/implementors/core/fmt/trait.Debug.js +++ b/implementors/core/fmt/trait.Debug.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl Debug for PlaybackStatus"],["impl Debug for MetadataBuilder"],["impl Debug for LoopStatus"],["impl<T> Debug for Server<T>where\n T: PlayerInterface + Send + Sync + 'static,"],["impl Debug for PlaylistsProperty"],["impl Debug for MaybePlaylist"],["impl Debug for Property"],["impl<T> Debug for LocalServer<T>where\n T: LocalPlayerInterface + 'static,"],["impl Debug for PlaylistOrdering"],["impl Debug for Player"],["impl Debug for Playlist"],["impl Debug for TrackId"],["impl Debug for Metadata"],["impl Debug for TrackListProperty"]] +"mpris_server":[["impl<T> Debug for Server<T>where\n T: PlayerInterface + 'static,"],["impl Debug for LoopStatus"],["impl Debug for MetadataBuilder"],["impl Debug for TrackId"],["impl Debug for Player"],["impl Debug for PlaylistsProperty"],["impl Debug for Time"],["impl Debug for Metadata"],["impl Debug for PlaybackStatus"],["impl<T> Debug for LocalServer<T>where\n T: LocalPlayerInterface + 'static,"],["impl Debug for PlaylistOrdering"],["impl Debug for TrackListProperty"],["impl Debug for Property"],["impl Debug for MaybePlaylist"],["impl Debug for Playlist"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/fmt/trait.Display.js b/implementors/core/fmt/trait.Display.js index 2c97060..efa7529 100644 --- a/implementors/core/fmt/trait.Display.js +++ b/implementors/core/fmt/trait.Display.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl Display for PlaylistOrdering"],["impl Display for PlaybackStatus"],["impl Display for TrackId"],["impl Display for LoopStatus"]] +"mpris_server":[["impl Display for LoopStatus"],["impl Display for PlaylistOrdering"],["impl Display for PlaybackStatus"],["impl Display for TrackId"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/hash/trait.Hash.js b/implementors/core/hash/trait.Hash.js index 7e89ad8..30e5013 100644 --- a/implementors/core/hash/trait.Hash.js +++ b/implementors/core/hash/trait.Hash.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl Hash for TrackId"]] +"mpris_server":[["impl Hash for Time"],["impl Hash for TrackId"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/marker/trait.Copy.js b/implementors/core/marker/trait.Copy.js index ea34492..7220dbe 100644 --- a/implementors/core/marker/trait.Copy.js +++ b/implementors/core/marker/trait.Copy.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl Copy for PlaylistsProperty"],["impl Copy for TrackListProperty"],["impl Copy for PlaybackStatus"],["impl Copy for LoopStatus"],["impl Copy for Property"],["impl Copy for PlaylistOrdering"]] +"mpris_server":[["impl Copy for LoopStatus"],["impl Copy for PlaylistsProperty"],["impl Copy for PlaylistOrdering"],["impl Copy for Property"],["impl Copy for Time"],["impl Copy for PlaybackStatus"],["impl Copy for TrackListProperty"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/marker/trait.Freeze.js b/implementors/core/marker/trait.Freeze.js index 61e92ca..e437dd9 100644 --- a/implementors/core/marker/trait.Freeze.js +++ b/implementors/core/marker/trait.Freeze.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl<T> !Freeze for LocalServer<T>",1,["mpris_server::local_server::LocalServer"]],["impl Freeze for LoopStatus",1,["mpris_server::loop_status::LoopStatus"]],["impl Freeze for Metadata",1,["mpris_server::metadata::Metadata"]],["impl Freeze for MetadataBuilder",1,["mpris_server::metadata::MetadataBuilder"]],["impl Freeze for PlaybackStatus",1,["mpris_server::playback_status::PlaybackStatus"]],["impl !Freeze for Player",1,["mpris_server::player::Player"]],["impl Freeze for PlayerBuilder",1,["mpris_server::player::PlayerBuilder"]],["impl Freeze for Playlist",1,["mpris_server::playlist::Playlist"]],["impl Freeze for MaybePlaylist",1,["mpris_server::playlist::MaybePlaylist"]],["impl Freeze for PlaylistOrdering",1,["mpris_server::playlist_ordering::PlaylistOrdering"]],["impl Freeze for Property",1,["mpris_server::property::Property"]],["impl Freeze for TrackListProperty",1,["mpris_server::property::TrackListProperty"]],["impl Freeze for PlaylistsProperty",1,["mpris_server::property::PlaylistsProperty"]],["impl<T> !Freeze for Server<T>",1,["mpris_server::server::Server"]],["impl Freeze for TrackId",1,["mpris_server::track_id::TrackId"]]] +"mpris_server":[["impl<T> !Freeze for LocalServer<T>",1,["mpris_server::local_server::LocalServer"]],["impl Freeze for LoopStatus",1,["mpris_server::loop_status::LoopStatus"]],["impl Freeze for Metadata",1,["mpris_server::metadata::Metadata"]],["impl Freeze for MetadataBuilder",1,["mpris_server::metadata::MetadataBuilder"]],["impl Freeze for PlaybackStatus",1,["mpris_server::playback_status::PlaybackStatus"]],["impl !Freeze for Player",1,["mpris_server::player::Player"]],["impl Freeze for PlayerBuilder",1,["mpris_server::player::PlayerBuilder"]],["impl Freeze for Playlist",1,["mpris_server::playlist::Playlist"]],["impl Freeze for MaybePlaylist",1,["mpris_server::playlist::MaybePlaylist"]],["impl Freeze for PlaylistOrdering",1,["mpris_server::playlist_ordering::PlaylistOrdering"]],["impl Freeze for Property",1,["mpris_server::property::Property"]],["impl Freeze for TrackListProperty",1,["mpris_server::property::TrackListProperty"]],["impl Freeze for PlaylistsProperty",1,["mpris_server::property::PlaylistsProperty"]],["impl<T> !Freeze for Server<T>",1,["mpris_server::server::Server"]],["impl Freeze for Time",1,["mpris_server::time::Time"]],["impl Freeze for TrackId",1,["mpris_server::track_id::TrackId"]]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/marker/trait.Send.js b/implementors/core/marker/trait.Send.js index 17b66da..a5d4e9c 100644 --- a/implementors/core/marker/trait.Send.js +++ b/implementors/core/marker/trait.Send.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl<T> !Send for LocalServer<T>",1,["mpris_server::local_server::LocalServer"]],["impl Send for LoopStatus",1,["mpris_server::loop_status::LoopStatus"]],["impl Send for Metadata",1,["mpris_server::metadata::Metadata"]],["impl Send for MetadataBuilder",1,["mpris_server::metadata::MetadataBuilder"]],["impl Send for PlaybackStatus",1,["mpris_server::playback_status::PlaybackStatus"]],["impl !Send for Player",1,["mpris_server::player::Player"]],["impl Send for PlayerBuilder",1,["mpris_server::player::PlayerBuilder"]],["impl Send for Playlist",1,["mpris_server::playlist::Playlist"]],["impl Send for MaybePlaylist",1,["mpris_server::playlist::MaybePlaylist"]],["impl Send for PlaylistOrdering",1,["mpris_server::playlist_ordering::PlaylistOrdering"]],["impl Send for Property",1,["mpris_server::property::Property"]],["impl Send for TrackListProperty",1,["mpris_server::property::TrackListProperty"]],["impl Send for PlaylistsProperty",1,["mpris_server::property::PlaylistsProperty"]],["impl<T> Send for Server<T>",1,["mpris_server::server::Server"]],["impl Send for TrackId",1,["mpris_server::track_id::TrackId"]]] +"mpris_server":[["impl<T> !Send for LocalServer<T>",1,["mpris_server::local_server::LocalServer"]],["impl Send for LoopStatus",1,["mpris_server::loop_status::LoopStatus"]],["impl Send for Metadata",1,["mpris_server::metadata::Metadata"]],["impl Send for MetadataBuilder",1,["mpris_server::metadata::MetadataBuilder"]],["impl Send for PlaybackStatus",1,["mpris_server::playback_status::PlaybackStatus"]],["impl !Send for Player",1,["mpris_server::player::Player"]],["impl Send for PlayerBuilder",1,["mpris_server::player::PlayerBuilder"]],["impl Send for Playlist",1,["mpris_server::playlist::Playlist"]],["impl Send for MaybePlaylist",1,["mpris_server::playlist::MaybePlaylist"]],["impl Send for PlaylistOrdering",1,["mpris_server::playlist_ordering::PlaylistOrdering"]],["impl Send for Property",1,["mpris_server::property::Property"]],["impl Send for TrackListProperty",1,["mpris_server::property::TrackListProperty"]],["impl Send for PlaylistsProperty",1,["mpris_server::property::PlaylistsProperty"]],["impl<T> Send for Server<T>",1,["mpris_server::server::Server"]],["impl Send for Time",1,["mpris_server::time::Time"]],["impl Send for TrackId",1,["mpris_server::track_id::TrackId"]]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/marker/trait.StructuralEq.js b/implementors/core/marker/trait.StructuralEq.js index 3d0fa65..b1b085b 100644 --- a/implementors/core/marker/trait.StructuralEq.js +++ b/implementors/core/marker/trait.StructuralEq.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl StructuralEq for TrackId"],["impl StructuralEq for PlaybackStatus"],["impl StructuralEq for LoopStatus"],["impl StructuralEq for PlaylistsProperty"],["impl StructuralEq for MaybePlaylist"],["impl StructuralEq for Property"],["impl StructuralEq for TrackListProperty"],["impl StructuralEq for Playlist"],["impl StructuralEq for PlaylistOrdering"]] +"mpris_server":[["impl StructuralEq for Time"],["impl StructuralEq for TrackListProperty"],["impl StructuralEq for PlaylistOrdering"],["impl StructuralEq for Property"],["impl StructuralEq for LoopStatus"],["impl StructuralEq for MaybePlaylist"],["impl StructuralEq for PlaybackStatus"],["impl StructuralEq for TrackId"],["impl StructuralEq for PlaylistsProperty"],["impl StructuralEq for Playlist"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/marker/trait.StructuralPartialEq.js b/implementors/core/marker/trait.StructuralPartialEq.js index d6a3a7b..51a062e 100644 --- a/implementors/core/marker/trait.StructuralPartialEq.js +++ b/implementors/core/marker/trait.StructuralPartialEq.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl StructuralPartialEq for PlaybackStatus"],["impl StructuralPartialEq for PlaylistOrdering"],["impl StructuralPartialEq for Metadata"],["impl StructuralPartialEq for TrackId"],["impl StructuralPartialEq for PlaylistsProperty"],["impl StructuralPartialEq for MaybePlaylist"],["impl StructuralPartialEq for TrackListProperty"],["impl StructuralPartialEq for Property"],["impl StructuralPartialEq for Playlist"],["impl StructuralPartialEq for LoopStatus"]] +"mpris_server":[["impl StructuralPartialEq for Metadata"],["impl StructuralPartialEq for TrackId"],["impl StructuralPartialEq for Playlist"],["impl StructuralPartialEq for PlaylistOrdering"],["impl StructuralPartialEq for MaybePlaylist"],["impl StructuralPartialEq for Time"],["impl StructuralPartialEq for LoopStatus"],["impl StructuralPartialEq for Property"],["impl StructuralPartialEq for TrackListProperty"],["impl StructuralPartialEq for PlaylistsProperty"],["impl StructuralPartialEq for PlaybackStatus"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/marker/trait.Sync.js b/implementors/core/marker/trait.Sync.js index 096c17a..8b95db5 100644 --- a/implementors/core/marker/trait.Sync.js +++ b/implementors/core/marker/trait.Sync.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl<T> !Sync for LocalServer<T>",1,["mpris_server::local_server::LocalServer"]],["impl Sync for LoopStatus",1,["mpris_server::loop_status::LoopStatus"]],["impl Sync for Metadata",1,["mpris_server::metadata::Metadata"]],["impl Sync for MetadataBuilder",1,["mpris_server::metadata::MetadataBuilder"]],["impl Sync for PlaybackStatus",1,["mpris_server::playback_status::PlaybackStatus"]],["impl !Sync for Player",1,["mpris_server::player::Player"]],["impl Sync for PlayerBuilder",1,["mpris_server::player::PlayerBuilder"]],["impl Sync for Playlist",1,["mpris_server::playlist::Playlist"]],["impl Sync for MaybePlaylist",1,["mpris_server::playlist::MaybePlaylist"]],["impl Sync for PlaylistOrdering",1,["mpris_server::playlist_ordering::PlaylistOrdering"]],["impl Sync for Property",1,["mpris_server::property::Property"]],["impl Sync for TrackListProperty",1,["mpris_server::property::TrackListProperty"]],["impl Sync for PlaylistsProperty",1,["mpris_server::property::PlaylistsProperty"]],["impl<T> Sync for Server<T>",1,["mpris_server::server::Server"]],["impl Sync for TrackId",1,["mpris_server::track_id::TrackId"]]] +"mpris_server":[["impl<T> !Sync for LocalServer<T>",1,["mpris_server::local_server::LocalServer"]],["impl Sync for LoopStatus",1,["mpris_server::loop_status::LoopStatus"]],["impl Sync for Metadata",1,["mpris_server::metadata::Metadata"]],["impl Sync for MetadataBuilder",1,["mpris_server::metadata::MetadataBuilder"]],["impl Sync for PlaybackStatus",1,["mpris_server::playback_status::PlaybackStatus"]],["impl !Sync for Player",1,["mpris_server::player::Player"]],["impl Sync for PlayerBuilder",1,["mpris_server::player::PlayerBuilder"]],["impl Sync for Playlist",1,["mpris_server::playlist::Playlist"]],["impl Sync for MaybePlaylist",1,["mpris_server::playlist::MaybePlaylist"]],["impl Sync for PlaylistOrdering",1,["mpris_server::playlist_ordering::PlaylistOrdering"]],["impl Sync for Property",1,["mpris_server::property::Property"]],["impl Sync for TrackListProperty",1,["mpris_server::property::TrackListProperty"]],["impl Sync for PlaylistsProperty",1,["mpris_server::property::PlaylistsProperty"]],["impl<T> Sync for Server<T>",1,["mpris_server::server::Server"]],["impl Sync for Time",1,["mpris_server::time::Time"]],["impl Sync for TrackId",1,["mpris_server::track_id::TrackId"]]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/marker/trait.Unpin.js b/implementors/core/marker/trait.Unpin.js index c36b207..05ccedf 100644 --- a/implementors/core/marker/trait.Unpin.js +++ b/implementors/core/marker/trait.Unpin.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl<T> Unpin for LocalServer<T>",1,["mpris_server::local_server::LocalServer"]],["impl Unpin for LoopStatus",1,["mpris_server::loop_status::LoopStatus"]],["impl Unpin for Metadata",1,["mpris_server::metadata::Metadata"]],["impl Unpin for MetadataBuilder",1,["mpris_server::metadata::MetadataBuilder"]],["impl Unpin for PlaybackStatus",1,["mpris_server::playback_status::PlaybackStatus"]],["impl Unpin for Player",1,["mpris_server::player::Player"]],["impl Unpin for PlayerBuilder",1,["mpris_server::player::PlayerBuilder"]],["impl Unpin for Playlist",1,["mpris_server::playlist::Playlist"]],["impl Unpin for MaybePlaylist",1,["mpris_server::playlist::MaybePlaylist"]],["impl Unpin for PlaylistOrdering",1,["mpris_server::playlist_ordering::PlaylistOrdering"]],["impl Unpin for Property",1,["mpris_server::property::Property"]],["impl Unpin for TrackListProperty",1,["mpris_server::property::TrackListProperty"]],["impl Unpin for PlaylistsProperty",1,["mpris_server::property::PlaylistsProperty"]],["impl<T> Unpin for Server<T>",1,["mpris_server::server::Server"]],["impl Unpin for TrackId",1,["mpris_server::track_id::TrackId"]]] +"mpris_server":[["impl<T> Unpin for LocalServer<T>",1,["mpris_server::local_server::LocalServer"]],["impl Unpin for LoopStatus",1,["mpris_server::loop_status::LoopStatus"]],["impl Unpin for Metadata",1,["mpris_server::metadata::Metadata"]],["impl Unpin for MetadataBuilder",1,["mpris_server::metadata::MetadataBuilder"]],["impl Unpin for PlaybackStatus",1,["mpris_server::playback_status::PlaybackStatus"]],["impl Unpin for Player",1,["mpris_server::player::Player"]],["impl Unpin for PlayerBuilder",1,["mpris_server::player::PlayerBuilder"]],["impl Unpin for Playlist",1,["mpris_server::playlist::Playlist"]],["impl Unpin for MaybePlaylist",1,["mpris_server::playlist::MaybePlaylist"]],["impl Unpin for PlaylistOrdering",1,["mpris_server::playlist_ordering::PlaylistOrdering"]],["impl Unpin for Property",1,["mpris_server::property::Property"]],["impl Unpin for TrackListProperty",1,["mpris_server::property::TrackListProperty"]],["impl Unpin for PlaylistsProperty",1,["mpris_server::property::PlaylistsProperty"]],["impl<T> Unpin for Server<T>",1,["mpris_server::server::Server"]],["impl Unpin for Time",1,["mpris_server::time::Time"]],["impl Unpin for TrackId",1,["mpris_server::track_id::TrackId"]]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/ops/arith/trait.Add.js b/implementors/core/ops/arith/trait.Add.js new file mode 100644 index 0000000..34bff69 --- /dev/null +++ b/implementors/core/ops/arith/trait.Add.js @@ -0,0 +1,3 @@ +(function() {var implementors = { +"mpris_server":[["impl Add<Time> for Time"]] +};if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/ops/arith/trait.AddAssign.js b/implementors/core/ops/arith/trait.AddAssign.js new file mode 100644 index 0000000..4005e39 --- /dev/null +++ b/implementors/core/ops/arith/trait.AddAssign.js @@ -0,0 +1,3 @@ +(function() {var implementors = { +"mpris_server":[["impl AddAssign<Time> for Time"]] +};if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/ops/arith/trait.Sub.js b/implementors/core/ops/arith/trait.Sub.js new file mode 100644 index 0000000..f64283f --- /dev/null +++ b/implementors/core/ops/arith/trait.Sub.js @@ -0,0 +1,3 @@ +(function() {var implementors = { +"mpris_server":[["impl Sub<Time> for Time"]] +};if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/ops/arith/trait.SubAssign.js b/implementors/core/ops/arith/trait.SubAssign.js new file mode 100644 index 0000000..26392da --- /dev/null +++ b/implementors/core/ops/arith/trait.SubAssign.js @@ -0,0 +1,3 @@ +(function() {var implementors = { +"mpris_server":[["impl SubAssign<Time> for Time"]] +};if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/ops/bit/trait.BitXor.js b/implementors/core/ops/bit/trait.BitXor.js index 4310af2..261b5be 100644 --- a/implementors/core/ops/bit/trait.BitXor.js +++ b/implementors/core/ops/bit/trait.BitXor.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl BitXor<TrackListProperty> for TrackListProperty"],["impl BitXor<Property> for Property"],["impl BitXor<PlaylistsProperty> for PlaylistsProperty"]] +"mpris_server":[["impl BitXor<PlaylistsProperty> for PlaylistsProperty"],["impl BitXor<Property> for Property"],["impl BitXor<TrackListProperty> for TrackListProperty"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/ops/bit/trait.Not.js b/implementors/core/ops/bit/trait.Not.js index 556bc15..2843d27 100644 --- a/implementors/core/ops/bit/trait.Not.js +++ b/implementors/core/ops/bit/trait.Not.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl Not for Property"],["impl Not for TrackListProperty"],["impl Not for PlaylistsProperty"]] +"mpris_server":[["impl Not for Property"],["impl Not for PlaylistsProperty"],["impl Not for TrackListProperty"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/panic/unwind_safe/trait.RefUnwindSafe.js b/implementors/core/panic/unwind_safe/trait.RefUnwindSafe.js index 47d675c..3aa8f93 100644 --- a/implementors/core/panic/unwind_safe/trait.RefUnwindSafe.js +++ b/implementors/core/panic/unwind_safe/trait.RefUnwindSafe.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl<T> !RefUnwindSafe for LocalServer<T>",1,["mpris_server::local_server::LocalServer"]],["impl RefUnwindSafe for LoopStatus",1,["mpris_server::loop_status::LoopStatus"]],["impl RefUnwindSafe for Metadata",1,["mpris_server::metadata::Metadata"]],["impl RefUnwindSafe for MetadataBuilder",1,["mpris_server::metadata::MetadataBuilder"]],["impl RefUnwindSafe for PlaybackStatus",1,["mpris_server::playback_status::PlaybackStatus"]],["impl !RefUnwindSafe for Player",1,["mpris_server::player::Player"]],["impl RefUnwindSafe for PlayerBuilder",1,["mpris_server::player::PlayerBuilder"]],["impl RefUnwindSafe for Playlist",1,["mpris_server::playlist::Playlist"]],["impl RefUnwindSafe for MaybePlaylist",1,["mpris_server::playlist::MaybePlaylist"]],["impl RefUnwindSafe for PlaylistOrdering",1,["mpris_server::playlist_ordering::PlaylistOrdering"]],["impl RefUnwindSafe for Property",1,["mpris_server::property::Property"]],["impl RefUnwindSafe for TrackListProperty",1,["mpris_server::property::TrackListProperty"]],["impl RefUnwindSafe for PlaylistsProperty",1,["mpris_server::property::PlaylistsProperty"]],["impl<T> !RefUnwindSafe for Server<T>",1,["mpris_server::server::Server"]],["impl RefUnwindSafe for TrackId",1,["mpris_server::track_id::TrackId"]]] +"mpris_server":[["impl<T> !RefUnwindSafe for LocalServer<T>",1,["mpris_server::local_server::LocalServer"]],["impl RefUnwindSafe for LoopStatus",1,["mpris_server::loop_status::LoopStatus"]],["impl RefUnwindSafe for Metadata",1,["mpris_server::metadata::Metadata"]],["impl RefUnwindSafe for MetadataBuilder",1,["mpris_server::metadata::MetadataBuilder"]],["impl RefUnwindSafe for PlaybackStatus",1,["mpris_server::playback_status::PlaybackStatus"]],["impl !RefUnwindSafe for Player",1,["mpris_server::player::Player"]],["impl RefUnwindSafe for PlayerBuilder",1,["mpris_server::player::PlayerBuilder"]],["impl RefUnwindSafe for Playlist",1,["mpris_server::playlist::Playlist"]],["impl RefUnwindSafe for MaybePlaylist",1,["mpris_server::playlist::MaybePlaylist"]],["impl RefUnwindSafe for PlaylistOrdering",1,["mpris_server::playlist_ordering::PlaylistOrdering"]],["impl RefUnwindSafe for Property",1,["mpris_server::property::Property"]],["impl RefUnwindSafe for TrackListProperty",1,["mpris_server::property::TrackListProperty"]],["impl RefUnwindSafe for PlaylistsProperty",1,["mpris_server::property::PlaylistsProperty"]],["impl<T> !RefUnwindSafe for Server<T>",1,["mpris_server::server::Server"]],["impl RefUnwindSafe for Time",1,["mpris_server::time::Time"]],["impl RefUnwindSafe for TrackId",1,["mpris_server::track_id::TrackId"]]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/core/panic/unwind_safe/trait.UnwindSafe.js b/implementors/core/panic/unwind_safe/trait.UnwindSafe.js index dfe1e5a..68abcdf 100644 --- a/implementors/core/panic/unwind_safe/trait.UnwindSafe.js +++ b/implementors/core/panic/unwind_safe/trait.UnwindSafe.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl<T> !UnwindSafe for LocalServer<T>",1,["mpris_server::local_server::LocalServer"]],["impl UnwindSafe for LoopStatus",1,["mpris_server::loop_status::LoopStatus"]],["impl UnwindSafe for Metadata",1,["mpris_server::metadata::Metadata"]],["impl UnwindSafe for MetadataBuilder",1,["mpris_server::metadata::MetadataBuilder"]],["impl UnwindSafe for PlaybackStatus",1,["mpris_server::playback_status::PlaybackStatus"]],["impl !UnwindSafe for Player",1,["mpris_server::player::Player"]],["impl UnwindSafe for PlayerBuilder",1,["mpris_server::player::PlayerBuilder"]],["impl UnwindSafe for Playlist",1,["mpris_server::playlist::Playlist"]],["impl UnwindSafe for MaybePlaylist",1,["mpris_server::playlist::MaybePlaylist"]],["impl UnwindSafe for PlaylistOrdering",1,["mpris_server::playlist_ordering::PlaylistOrdering"]],["impl UnwindSafe for Property",1,["mpris_server::property::Property"]],["impl UnwindSafe for TrackListProperty",1,["mpris_server::property::TrackListProperty"]],["impl UnwindSafe for PlaylistsProperty",1,["mpris_server::property::PlaylistsProperty"]],["impl<T> !UnwindSafe for Server<T>",1,["mpris_server::server::Server"]],["impl UnwindSafe for TrackId",1,["mpris_server::track_id::TrackId"]]] +"mpris_server":[["impl<T> !UnwindSafe for LocalServer<T>",1,["mpris_server::local_server::LocalServer"]],["impl UnwindSafe for LoopStatus",1,["mpris_server::loop_status::LoopStatus"]],["impl UnwindSafe for Metadata",1,["mpris_server::metadata::Metadata"]],["impl UnwindSafe for MetadataBuilder",1,["mpris_server::metadata::MetadataBuilder"]],["impl UnwindSafe for PlaybackStatus",1,["mpris_server::playback_status::PlaybackStatus"]],["impl !UnwindSafe for Player",1,["mpris_server::player::Player"]],["impl UnwindSafe for PlayerBuilder",1,["mpris_server::player::PlayerBuilder"]],["impl UnwindSafe for Playlist",1,["mpris_server::playlist::Playlist"]],["impl UnwindSafe for MaybePlaylist",1,["mpris_server::playlist::MaybePlaylist"]],["impl UnwindSafe for PlaylistOrdering",1,["mpris_server::playlist_ordering::PlaylistOrdering"]],["impl UnwindSafe for Property",1,["mpris_server::property::Property"]],["impl UnwindSafe for TrackListProperty",1,["mpris_server::property::TrackListProperty"]],["impl UnwindSafe for PlaylistsProperty",1,["mpris_server::property::PlaylistsProperty"]],["impl<T> !UnwindSafe for Server<T>",1,["mpris_server::server::Server"]],["impl UnwindSafe for Time",1,["mpris_server::time::Time"]],["impl UnwindSafe for TrackId",1,["mpris_server::track_id::TrackId"]]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/enumflags2/_internal/trait.RawBitFlags.js b/implementors/enumflags2/_internal/trait.RawBitFlags.js index e79d53d..bbe029a 100644 --- a/implementors/enumflags2/_internal/trait.RawBitFlags.js +++ b/implementors/enumflags2/_internal/trait.RawBitFlags.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl RawBitFlags for PlaylistsProperty"],["impl RawBitFlags for TrackListProperty"],["impl RawBitFlags for Property"]] +"mpris_server":[["impl RawBitFlags for TrackListProperty"],["impl RawBitFlags for PlaylistsProperty"],["impl RawBitFlags for Property"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/enumflags2/trait.BitFlag.js b/implementors/enumflags2/trait.BitFlag.js index 6c3ba92..79d8434 100644 --- a/implementors/enumflags2/trait.BitFlag.js +++ b/implementors/enumflags2/trait.BitFlag.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl BitFlag for PlaylistsProperty"],["impl BitFlag for TrackListProperty"],["impl BitFlag for Property"]] +"mpris_server":[["impl BitFlag for Property"],["impl BitFlag for TrackListProperty"],["impl BitFlag for PlaylistsProperty"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/serde/de/trait.Deserialize.js b/implementors/serde/de/trait.Deserialize.js index 32ad865..74612da 100644 --- a/implementors/serde/de/trait.Deserialize.js +++ b/implementors/serde/de/trait.Deserialize.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl<'de> Deserialize<'de> for TrackId"],["impl<'de> Deserialize<'de> for PlaylistOrdering"]] +"mpris_server":[["impl<'de> Deserialize<'de> for Time"],["impl<'de> Deserialize<'de> for TrackId"],["impl<'de> Deserialize<'de> for PlaylistOrdering"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/serde/ser/trait.Serialize.js b/implementors/serde/ser/trait.Serialize.js index 947060b..697b737 100644 --- a/implementors/serde/ser/trait.Serialize.js +++ b/implementors/serde/ser/trait.Serialize.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl Serialize for MaybePlaylist"],["impl Serialize for Metadata"],["impl Serialize for TrackId"],["impl Serialize for Playlist"]] +"mpris_server":[["impl Serialize for MaybePlaylist"],["impl Serialize for Time"],["impl Serialize for Metadata"],["impl Serialize for TrackId"],["impl Serialize for Playlist"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/implementors/zvariant/type/trait.Type.js b/implementors/zvariant/type/trait.Type.js index 502ce46..9fbaf70 100644 --- a/implementors/zvariant/type/trait.Type.js +++ b/implementors/zvariant/type/trait.Type.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"mpris_server":[["impl Type for Playlist"],["impl Type for PlaylistOrdering"],["impl Type for TrackId"],["impl Type for Metadata"],["impl Type for MaybePlaylist"],["impl Type for LoopStatus"],["impl Type for PlaybackStatus"]] +"mpris_server":[["impl Type for PlaybackStatus"],["impl Type for Time"],["impl Type for TrackId"],["impl Type for LoopStatus"],["impl Type for Playlist"],["impl Type for MaybePlaylist"],["impl Type for PlaylistOrdering"],["impl Type for Metadata"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/mpris_server/all.html b/mpris_server/all.html index 66c4857..b8063d5 100644 --- a/mpris_server/all.html +++ b/mpris_server/all.html @@ -1 +1 @@ -List of all items in this crate
\ No newline at end of file +List of all items in this crate
\ No newline at end of file diff --git a/mpris_server/builder/index.html b/mpris_server/builder/index.html index d8909df..ceee729 100644 --- a/mpris_server/builder/index.html +++ b/mpris_server/builder/index.html @@ -1 +1,4 @@ -mpris_server::builder - Rust

Module mpris_server::builder

source ·

Structs

\ No newline at end of file +mpris_server::builder - Rust

Module mpris_server::builder

source ·
Expand description

This contains the definitions of builder-pattern structs.

+

The builder methods on the objects must be used instead to construct +these builder-pattern structs.

+

Structs

\ No newline at end of file diff --git a/mpris_server/builder/struct.MetadataBuilder.html b/mpris_server/builder/struct.MetadataBuilder.html index 20eab86..cf35963 100644 --- a/mpris_server/builder/struct.MetadataBuilder.html +++ b/mpris_server/builder/struct.MetadataBuilder.html @@ -1,17 +1,22 @@ -MetadataBuilder in mpris_server::builder - Rust
pub struct MetadataBuilder { /* private fields */ }
Expand description

A builder used to create Metadata.

-

Implementations§

source§

impl MetadataBuilder

source

pub fn trackid(self, trackid: impl Into<OwnedObjectPath>) -> Self

source

pub fn length(self, length: TimeInUs) -> Self

source

pub fn art_url(self, art_url: impl Into<Uri>) -> Self

source

pub fn album(self, album: impl Into<String>) -> Self

source

pub fn album_artist( +MetadataBuilder in mpris_server::builder - Rust
pub struct MetadataBuilder { /* private fields */ }
Expand description

A builder used to create Metadata.

+

Implementations§

source§

impl MetadataBuilder

source

pub fn other( + self, + key: impl Into<String>, + value: impl Into<Value<'static>> +) -> Self

Insert a new key-value pair into the metadata.

+
source

pub fn trackid(self, trackid: impl Into<OwnedObjectPath>) -> Self

source

pub fn length(self, length: Time) -> Self

source

pub fn art_url(self, art_url: impl Into<Uri>) -> Self

source

pub fn album(self, album: impl Into<String>) -> Self

source

pub fn album_artist( self, album_artist: impl IntoIterator<Item = impl Into<String>> -) -> Self

source

pub fn artist(self, artist: impl IntoIterator<Item = impl Into<String>>) -> Self

source

pub fn lyrics(self, lyrics: impl Into<String>) -> Self

source

pub fn audio_bpm(self, audio_bpm: i32) -> Self

source

pub fn auto_rating(self, auto_rating: f64) -> Self

source

pub fn comment( +) -> Self

source

pub fn artist(self, artist: impl IntoIterator<Item = impl Into<String>>) -> Self

source

pub fn lyrics(self, lyrics: impl Into<String>) -> Self

source

pub fn audio_bpm(self, audio_bpm: i32) -> Self

source

pub fn auto_rating(self, auto_rating: f64) -> Self

source

pub fn comment( self, comment: impl IntoIterator<Item = impl Into<String>> -) -> Self

source

pub fn composer( +) -> Self

source

pub fn composer( self, composer: impl IntoIterator<Item = impl Into<String>> -) -> Self

source

pub fn content_created(self, content_created: impl Into<DateTime>) -> Self

source

pub fn disc_number(self, disc_number: i32) -> Self

source

pub fn first_used(self, first_used: impl Into<DateTime>) -> Self

source

pub fn genre(self, genre: impl IntoIterator<Item = impl Into<String>>) -> Self

source

pub fn last_used(self, last_used: impl Into<DateTime>) -> Self

source

pub fn lyricist( +) -> Self

source

pub fn content_created(self, content_created: impl Into<DateTime>) -> Self

source

pub fn disc_number(self, disc_number: i32) -> Self

source

pub fn first_used(self, first_used: impl Into<DateTime>) -> Self

source

pub fn genre(self, genre: impl IntoIterator<Item = impl Into<String>>) -> Self

source

pub fn last_used(self, last_used: impl Into<DateTime>) -> Self

source

pub fn lyricist( self, lyricist: impl IntoIterator<Item = impl Into<String>> -) -> Self

source

pub fn title(self, title: impl Into<String>) -> Self

source

pub fn track_number(self, track_number: i32) -> Self

source

pub fn url(self, url: impl Into<Uri>) -> Self

source

pub fn use_count(self, use_count: i32) -> Self

source

pub fn user_rating(self, user_rating: f64) -> Self

source

pub fn build(self) -> Metadata

Trait Implementations§

source§

impl Clone for MetadataBuilder

source§

fn clone(&self) -> MetadataBuilder

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for MetadataBuilder

source§

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

Formats the value using the given formatter. Read more
source§

impl Default for MetadataBuilder

source§

fn default() -> MetadataBuilder

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

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere +) -> Self

source

pub fn title(self, title: impl Into<String>) -> Self

source

pub fn track_number(self, track_number: i32) -> Self

source

pub fn url(self, url: impl Into<Uri>) -> Self

source

pub fn use_count(self, use_count: i32) -> Self

source

pub fn user_rating(self, user_rating: f64) -> Self

source

pub fn build(self) -> Metadata

Trait Implementations§

source§

impl Clone for MetadataBuilder

source§

fn clone(&self) -> MetadataBuilder

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for MetadataBuilder

source§

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

Formats the value using the given formatter. Read more
source§

impl Default for MetadataBuilder

source§

fn default() -> MetadataBuilder

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

Auto Trait Implementations§

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

source§

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

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

diff --git a/mpris_server/builder/struct.PlayerBuilder.html b/mpris_server/builder/struct.PlayerBuilder.html index d6f8ed5..fd5fcdd 100644 --- a/mpris_server/builder/struct.PlayerBuilder.html +++ b/mpris_server/builder/struct.PlayerBuilder.html @@ -1,11 +1,11 @@ -PlayerBuilder in mpris_server::builder - Rust
pub struct PlayerBuilder { /* private fields */ }
Expand description

A builder used to create Player.

-

Implementations§

source§

impl PlayerBuilder

source

pub fn can_quit(self, can_quit: bool) -> Self

source

pub fn fullscreen(self, fullscreen: bool) -> Self

source

pub fn can_set_fullscreen(self, can_set_fullscreen: bool) -> Self

source

pub fn can_raise(self, can_raise: bool) -> Self

source

pub fn has_track_list(self, has_track_list: bool) -> Self

source

pub fn identity(self, identity: impl Into<String>) -> Self

source

pub fn desktop_entry(self, desktop_entry: impl Into<String>) -> Self

source

pub fn supported_uri_schemes( +PlayerBuilder in mpris_server::builder - Rust
pub struct PlayerBuilder { /* private fields */ }
Expand description

A builder used to create Player.

+

Implementations§

source§

impl PlayerBuilder

source

pub fn can_quit(self, can_quit: bool) -> Self

source

pub fn fullscreen(self, fullscreen: bool) -> Self

source

pub fn can_set_fullscreen(self, can_set_fullscreen: bool) -> Self

source

pub fn can_raise(self, can_raise: bool) -> Self

source

pub fn has_track_list(self, has_track_list: bool) -> Self

source

pub fn identity(self, identity: impl Into<String>) -> Self

source

pub fn desktop_entry(self, desktop_entry: impl Into<String>) -> Self

source

pub fn supported_uri_schemes( self, supported_uri_schemes: impl IntoIterator<Item = impl Into<String>> -) -> Self

source

pub fn supported_mime_types( +) -> Self

source

pub fn supported_mime_types( self, supported_mime_types: impl IntoIterator<Item = impl Into<String>> -) -> Self

source

pub fn playback_status(self, playback_status: PlaybackStatus) -> Self

source

pub fn loop_status(self, loop_status: LoopStatus) -> Self

source

pub fn rate(self, rate: PlaybackRate) -> Self

source

pub fn shuffle(self, shuffle: bool) -> Self

source

pub fn metadata(self, metadata: Metadata) -> Self

source

pub fn volume(self, volume: Volume) -> Self

source

pub fn position(self, position: TimeInUs) -> Self

source

pub fn minimum_rate(self, minimum_rate: PlaybackRate) -> Self

source

pub fn maximum_rate(self, maximum_rate: PlaybackRate) -> Self

source

pub fn can_go_next(self, can_go_next: bool) -> Self

source

pub fn can_go_previous(self, can_go_previous: bool) -> Self

source

pub fn can_play(self, can_play: bool) -> Self

source

pub fn can_pause(self, can_pause: bool) -> Self

source

pub fn can_seek(self, can_seek: bool) -> Self

source

pub fn can_control(self, can_control: bool) -> Self

source

pub fn build(self) -> Result<Player>

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere +) -> Self

source

pub fn playback_status(self, playback_status: PlaybackStatus) -> Self

source

pub fn loop_status(self, loop_status: LoopStatus) -> Self

source

pub fn rate(self, rate: PlaybackRate) -> Self

source

pub fn shuffle(self, shuffle: bool) -> Self

source

pub fn metadata(self, metadata: Metadata) -> Self

source

pub fn volume(self, volume: Volume) -> Self

source

pub fn position(self, position: Time) -> Self

source

pub fn minimum_rate(self, minimum_rate: PlaybackRate) -> Self

source

pub fn maximum_rate(self, maximum_rate: PlaybackRate) -> Self

source

pub fn can_go_next(self, can_go_next: bool) -> Self

source

pub fn can_go_previous(self, can_go_previous: bool) -> Self

source

pub fn can_play(self, can_play: bool) -> Self

source

pub fn can_pause(self, can_pause: bool) -> Self

source

pub fn can_seek(self, can_seek: bool) -> Self

source

pub fn can_control(self, can_control: bool) -> Self

source

pub fn build(self) -> Result<Player>

Auto Trait Implementations§

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

source§

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

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

diff --git a/mpris_server/enum.LoopStatus.html b/mpris_server/enum.LoopStatus.html index e80f6ac..9fbe973 100644 --- a/mpris_server/enum.LoopStatus.html +++ b/mpris_server/enum.LoopStatus.html @@ -7,9 +7,10 @@
§

Track

The current track will start again from the beginning once it has finished playing.

§

Playlist

The playback loops through a list of tracks.

-

Implementations§

source§

impl LoopStatus

source

pub fn as_str(&self) -> &'static str

Trait Implementations§

source§

impl Clone for LoopStatus

source§

fn clone(&self) -> LoopStatus

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for LoopStatus

source§

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

Formats the value using the given formatter. Read more
source§

impl Display for LoopStatus

source§

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

Formats the value using the given formatter. Read more
source§

impl<'a> From<LoopStatus> for Value<'a>

source§

fn from(status: LoopStatus) -> Self

Converts to this type from the input type.
source§

impl PartialEq<LoopStatus> for LoopStatus

source§

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

This method tests for self and other values to be equal, and is used +

Implementations§

source§

impl LoopStatus

source

pub fn as_str(&self) -> &'static str

Returns the string representation of this loop status.

+

Trait Implementations§

source§

impl Clone for LoopStatus

source§

fn clone(&self) -> LoopStatus

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for LoopStatus

source§

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

Formats the value using the given formatter. Read more
source§

impl Display for LoopStatus

source§

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

Formats the value using the given formatter. Read more
source§

impl<'a> From<LoopStatus> for Value<'a>

source§

fn from(status: LoopStatus) -> Self

Converts to this type from the input type.
source§

impl PartialEq<LoopStatus> for LoopStatus

source§

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

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

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

This method tests for !=. The default implementation is almost always -sufficient, and should not be overridden without very good reason.
source§

impl<'a> TryFrom<Value<'a>> for LoopStatus

§

type Error = Error

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

fn try_from(value: Value<'a>) -> Result<Self, Self::Error>

Performs the conversion.
source§

impl Type for LoopStatus

source§

fn signature() -> Signature<'static>

Get the signature for the implementing type. Read more
source§

impl Copy for LoopStatus

source§

impl Eq for LoopStatus

source§

impl StructuralEq for LoopStatus

source§

impl StructuralPartialEq for LoopStatus

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere +sufficient, and should not be overridden without very good reason.

source§

impl<'a> TryFrom<Value<'a>> for LoopStatus

§

type Error = Error

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

fn try_from(value: Value<'a>) -> Result<Self, Self::Error>

Performs the conversion.
source§

impl Type for LoopStatus

source§

fn signature() -> Signature<'static>

Get the signature for the implementing type. Read more
source§

impl Copy for LoopStatus

source§

impl Eq for LoopStatus

source§

impl StructuralEq for LoopStatus

source§

impl StructuralPartialEq for LoopStatus

Auto Trait Implementations§

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

source§

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

Mutably borrows from an owned value. Read more
§

impl<T> DynamicType for Twhere diff --git a/mpris_server/enum.PlaybackStatus.html b/mpris_server/enum.PlaybackStatus.html index cbd2a79..1ef90f0 100644 --- a/mpris_server/enum.PlaybackStatus.html +++ b/mpris_server/enum.PlaybackStatus.html @@ -6,7 +6,8 @@

Variants§

§

Playing

A track is currently playing.

§

Paused

A track is currently paused.

§

Stopped

There is no track currently playing.

-

Implementations§

source§

impl PlaybackStatus

source

pub fn as_str(&self) -> &'static str

Trait Implementations§

source§

impl Clone for PlaybackStatus

source§

fn clone(&self) -> PlaybackStatus

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for PlaybackStatus

source§

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

Formats the value using the given formatter. Read more
source§

impl Display for PlaybackStatus

source§

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

Formats the value using the given formatter. Read more
source§

impl<'a> From<PlaybackStatus> for Value<'a>

source§

fn from(status: PlaybackStatus) -> Self

Converts to this type from the input type.
source§

impl PartialEq<PlaybackStatus> for PlaybackStatus

source§

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

This method tests for self and other values to be equal, and is used +

Implementations§

source§

impl PlaybackStatus

source

pub fn as_str(&self) -> &'static str

Returns the string representation of this playback status.

+

Trait Implementations§

source§

impl Clone for PlaybackStatus

source§

fn clone(&self) -> PlaybackStatus

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for PlaybackStatus

source§

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

Formats the value using the given formatter. Read more
source§

impl Display for PlaybackStatus

source§

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

Formats the value using the given formatter. Read more
source§

impl<'a> From<PlaybackStatus> for Value<'a>

source§

fn from(status: PlaybackStatus) -> Self

Converts to this type from the input type.
source§

impl PartialEq<PlaybackStatus> for PlaybackStatus

source§

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

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

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

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

impl Type for PlaybackStatus

source§

fn signature() -> Signature<'static>

Get the signature for the implementing type. Read more
source§

impl Copy for PlaybackStatus

source§

impl Eq for PlaybackStatus

source§

impl StructuralEq for PlaybackStatus

source§

impl StructuralPartialEq for PlaybackStatus

Auto Trait Implementations§

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere diff --git a/mpris_server/enum.PlaylistOrdering.html b/mpris_server/enum.PlaylistOrdering.html index 2bfcdfd..75623aa 100644 --- a/mpris_server/enum.PlaylistOrdering.html +++ b/mpris_server/enum.PlaylistOrdering.html @@ -14,8 +14,9 @@

Rationale

§

ModifiedDate

Ordering by last modified date, oldest first.

§

LastPlayDate

Ordering by date of last playback, oldest first.

§

UserDefined

A user-defined ordering.

-

Implementations§

source§

impl PlaylistOrdering

source

pub fn as_str(&self) -> &'static str

Trait Implementations§

source§

impl Clone for PlaylistOrdering

source§

fn clone(&self) -> PlaylistOrdering

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for PlaylistOrdering

source§

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

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for PlaylistOrdering

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for PlaylistOrdering

source§

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

Formats the value using the given formatter. Read more
source§

impl<'a> From<PlaylistOrdering> for Value<'a>

source§

fn from(status: PlaylistOrdering) -> Self

Converts to this type from the input type.
source§

impl PartialEq<PlaylistOrdering> for PlaylistOrdering

source§

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

This method tests for self and other values to be equal, and is used +

Implementations§

source§

impl PlaylistOrdering

source

pub fn as_str(&self) -> &'static str

Returns the string representation of this playlist ordering.

+

Trait Implementations§

source§

impl Clone for PlaylistOrdering

source§

fn clone(&self) -> PlaylistOrdering

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for PlaylistOrdering

source§

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

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for PlaylistOrdering

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for PlaylistOrdering

source§

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

Formats the value using the given formatter. Read more
source§

impl<'a> From<PlaylistOrdering> for Value<'a>

source§

fn from(status: PlaylistOrdering) -> Self

Converts to this type from the input type.
source§

impl PartialEq<PlaylistOrdering> for PlaylistOrdering

source§

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

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

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

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

impl Type for PlaylistOrdering

source§

fn signature() -> Signature<'static>

Get the signature for the implementing type. Read more
source§

impl Copy for PlaylistOrdering

source§

impl Eq for PlaylistOrdering

source§

impl StructuralEq for PlaylistOrdering

source§

impl StructuralPartialEq for PlaylistOrdering

Auto Trait Implementations§

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere diff --git a/mpris_server/enum.PlaylistsProperty.html b/mpris_server/enum.PlaylistsProperty.html index 3cf3fae..5b27d8a 100644 --- a/mpris_server/enum.PlaylistsProperty.html +++ b/mpris_server/enum.PlaylistsProperty.html @@ -5,7 +5,7 @@ }
Expand description

Used for emitting PropertiesChanged signals on Server<T> via Server::playlists_properties_changed, if T implements PlaylistsInterface.

-

Variants§

§

PlaylistCount

§

Orderings

§

ActivePlaylist

Trait Implementations§

source§

impl BitAnd<PlaylistsProperty> for PlaylistsProperty

§

type Output = BitFlags<PlaylistsProperty, <PlaylistsProperty as RawBitFlags>::Numeric>

The resulting type after applying the & operator.
source§

fn bitand(self, other: Self) -> Self::Output

Performs the & operation. Read more
source§

impl BitFlag for PlaylistsProperty

§

fn empty() -> BitFlags<Self, Self::Numeric>

Create a BitFlags with no flags set (in other words, with a value of 0). Read more
§

fn all() -> BitFlags<Self, Self::Numeric>

Create a BitFlags with all flags set. Read more
source§

impl BitOr<PlaylistsProperty> for PlaylistsProperty

§

type Output = BitFlags<PlaylistsProperty, <PlaylistsProperty as RawBitFlags>::Numeric>

The resulting type after applying the | operator.
source§

fn bitor(self, other: Self) -> Self::Output

Performs the | operation. Read more
source§

impl BitXor<PlaylistsProperty> for PlaylistsProperty

§

type Output = BitFlags<PlaylistsProperty, <PlaylistsProperty as RawBitFlags>::Numeric>

The resulting type after applying the ^ operator.
source§

fn bitxor(self, other: Self) -> Self::Output

Performs the ^ operation. Read more
source§

impl Clone for PlaylistsProperty

source§

fn clone(&self) -> PlaylistsProperty

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for PlaylistsProperty

source§

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

Formats the value using the given formatter. Read more
source§

impl Not for PlaylistsProperty

§

type Output = BitFlags<PlaylistsProperty, <PlaylistsProperty as RawBitFlags>::Numeric>

The resulting type after applying the ! operator.
source§

fn not(self) -> Self::Output

Performs the unary ! operation. Read more
source§

impl PartialEq<PlaylistsProperty> for PlaylistsProperty

source§

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

This method tests for self and other values to be equal, and is used +

Variants§

§

PlaylistCount

§

Orderings

§

ActivePlaylist

Trait Implementations§

source§

impl BitAnd<PlaylistsProperty> for PlaylistsProperty

§

type Output = BitFlags<PlaylistsProperty, <PlaylistsProperty as RawBitFlags>::Numeric>

The resulting type after applying the & operator.
source§

fn bitand(self, other: Self) -> Self::Output

Performs the & operation. Read more
source§

impl BitFlag for PlaylistsProperty

§

fn empty() -> BitFlags<Self, Self::Numeric>

Create a BitFlags with no flags set (in other words, with a value of 0). Read more
§

fn all() -> BitFlags<Self, Self::Numeric>

Create a BitFlags with all flags set. Read more
source§

impl BitOr<PlaylistsProperty> for PlaylistsProperty

§

type Output = BitFlags<PlaylistsProperty, <PlaylistsProperty as RawBitFlags>::Numeric>

The resulting type after applying the | operator.
source§

fn bitor(self, other: Self) -> Self::Output

Performs the | operation. Read more
source§

impl BitXor<PlaylistsProperty> for PlaylistsProperty

§

type Output = BitFlags<PlaylistsProperty, <PlaylistsProperty as RawBitFlags>::Numeric>

The resulting type after applying the ^ operator.
source§

fn bitxor(self, other: Self) -> Self::Output

Performs the ^ operation. Read more
source§

impl Clone for PlaylistsProperty

source§

fn clone(&self) -> PlaylistsProperty

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for PlaylistsProperty

source§

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

Formats the value using the given formatter. Read more
source§

impl Not for PlaylistsProperty

§

type Output = BitFlags<PlaylistsProperty, <PlaylistsProperty as RawBitFlags>::Numeric>

The resulting type after applying the ! operator.
source§

fn not(self) -> Self::Output

Performs the unary ! operation. Read more
source§

impl PartialEq<PlaylistsProperty> for PlaylistsProperty

source§

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

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

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

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

impl RawBitFlags for PlaylistsProperty

§

type Numeric = u32

The underlying integer type.
source§

const EMPTY: Self::Numeric = {transmute(0x00000000): <property::PlaylistsProperty as enumflags2::_internal::RawBitFlags>::Numeric}

A value with no bits set.
source§

const DEFAULT: Self::Numeric = {transmute(0x00000000): <property::PlaylistsProperty as enumflags2::_internal::RawBitFlags>::Numeric}

The value used by the Default implementation. Equivalent to EMPTY, unless customized.
source§

const ALL_BITS: Self::Numeric = {transmute(0x00000007): <property::PlaylistsProperty as enumflags2::_internal::RawBitFlags>::Numeric}

A value with all flag bits set.
source§

const BITFLAGS_TYPE_NAME: &'static str = _

The name of the type for debug formatting purposes. Read more
source§

fn bits(self) -> Self::Numeric

Return the bits as a number type.
source§

impl Copy for PlaylistsProperty

source§

impl Eq for PlaylistsProperty

source§

impl StructuralEq for PlaylistsProperty

source§

impl StructuralPartialEq for PlaylistsProperty

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere diff --git a/mpris_server/enum.Property.html b/mpris_server/enum.Property.html index 4d1ffe2..d56ad94 100644 --- a/mpris_server/enum.Property.html +++ b/mpris_server/enum.Property.html @@ -25,7 +25,7 @@ CanControl,

}
Expand description

Used for emitting PropertiesChanged signals on Server<T> via Server::properties_changed.

-

Variants§

§

CanQuit

§

Fullscreen

§

CanSetFullscreen

§

CanRaise

§

HasTrackList

§

Identity

§

DesktopEntry

§

SupportedUriSchemes

§

SupportedMimeTypes

§

PlaybackStatus

§

LoopStatus

§

Rate

§

Shuffle

§

Metadata

§

Volume

§

Position

§

MinimumRate

§

MaximumRate

§

CanGoNext

§

CanGoPrevious

§

CanPlay

§

CanPause

§

CanSeek

§

CanControl

Trait Implementations§

source§

impl BitAnd<Property> for Property

§

type Output = BitFlags<Property, <Property as RawBitFlags>::Numeric>

The resulting type after applying the & operator.
source§

fn bitand(self, other: Self) -> Self::Output

Performs the & operation. Read more
source§

impl BitFlag for Property

§

fn empty() -> BitFlags<Self, Self::Numeric>

Create a BitFlags with no flags set (in other words, with a value of 0). Read more
§

fn all() -> BitFlags<Self, Self::Numeric>

Create a BitFlags with all flags set. Read more
source§

impl BitOr<Property> for Property

§

type Output = BitFlags<Property, <Property as RawBitFlags>::Numeric>

The resulting type after applying the | operator.
source§

fn bitor(self, other: Self) -> Self::Output

Performs the | operation. Read more
source§

impl BitXor<Property> for Property

§

type Output = BitFlags<Property, <Property as RawBitFlags>::Numeric>

The resulting type after applying the ^ operator.
source§

fn bitxor(self, other: Self) -> Self::Output

Performs the ^ operation. Read more
source§

impl Clone for Property

source§

fn clone(&self) -> Property

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for Property

source§

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

Formats the value using the given formatter. Read more
source§

impl Not for Property

§

type Output = BitFlags<Property, <Property as RawBitFlags>::Numeric>

The resulting type after applying the ! operator.
source§

fn not(self) -> Self::Output

Performs the unary ! operation. Read more
source§

impl PartialEq<Property> for Property

source§

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

This method tests for self and other values to be equal, and is used +

Variants§

§

CanQuit

§

Fullscreen

§

CanSetFullscreen

§

CanRaise

§

HasTrackList

§

Identity

§

DesktopEntry

§

SupportedUriSchemes

§

SupportedMimeTypes

§

PlaybackStatus

§

LoopStatus

§

Rate

§

Shuffle

§

Metadata

§

Volume

§

Position

§

MinimumRate

§

MaximumRate

§

CanGoNext

§

CanGoPrevious

§

CanPlay

§

CanPause

§

CanSeek

§

CanControl

Trait Implementations§

source§

impl BitAnd<Property> for Property

§

type Output = BitFlags<Property, <Property as RawBitFlags>::Numeric>

The resulting type after applying the & operator.
source§

fn bitand(self, other: Self) -> Self::Output

Performs the & operation. Read more
source§

impl BitFlag for Property

§

fn empty() -> BitFlags<Self, Self::Numeric>

Create a BitFlags with no flags set (in other words, with a value of 0). Read more
§

fn all() -> BitFlags<Self, Self::Numeric>

Create a BitFlags with all flags set. Read more
source§

impl BitOr<Property> for Property

§

type Output = BitFlags<Property, <Property as RawBitFlags>::Numeric>

The resulting type after applying the | operator.
source§

fn bitor(self, other: Self) -> Self::Output

Performs the | operation. Read more
source§

impl BitXor<Property> for Property

§

type Output = BitFlags<Property, <Property as RawBitFlags>::Numeric>

The resulting type after applying the ^ operator.
source§

fn bitxor(self, other: Self) -> Self::Output

Performs the ^ operation. Read more
source§

impl Clone for Property

source§

fn clone(&self) -> Property

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for Property

source§

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

Formats the value using the given formatter. Read more
source§

impl Not for Property

§

type Output = BitFlags<Property, <Property as RawBitFlags>::Numeric>

The resulting type after applying the ! operator.
source§

fn not(self) -> Self::Output

Performs the unary ! operation. Read more
source§

impl PartialEq<Property> for Property

source§

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

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

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

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

impl RawBitFlags for Property

§

type Numeric = u32

The underlying integer type.
source§

const EMPTY: Self::Numeric = {transmute(0x00000000): <property::Property as enumflags2::_internal::RawBitFlags>::Numeric}

A value with no bits set.
source§

const DEFAULT: Self::Numeric = {transmute(0x00000000): <property::Property as enumflags2::_internal::RawBitFlags>::Numeric}

The value used by the Default implementation. Equivalent to EMPTY, unless customized.
source§

const ALL_BITS: Self::Numeric = {transmute(0x00ffffff): <property::Property as enumflags2::_internal::RawBitFlags>::Numeric}

A value with all flag bits set.
source§

const BITFLAGS_TYPE_NAME: &'static str = _

The name of the type for debug formatting purposes. Read more
source§

fn bits(self) -> Self::Numeric

Return the bits as a number type.
source§

impl Copy for Property

source§

impl Eq for Property

source§

impl StructuralEq for Property

source§

impl StructuralPartialEq for Property

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere diff --git a/mpris_server/enum.TrackListProperty.html b/mpris_server/enum.TrackListProperty.html index 46e3a72..48ae0f9 100644 --- a/mpris_server/enum.TrackListProperty.html +++ b/mpris_server/enum.TrackListProperty.html @@ -4,7 +4,7 @@ }
Expand description

Used for emitting PropertiesChanged signals on Server<T> via Server::track_list_properties_changed, if T implements TrackListInterface.

-

Variants§

§

Tracks

§

CanEditTracks

Trait Implementations§

source§

impl BitAnd<TrackListProperty> for TrackListProperty

§

type Output = BitFlags<TrackListProperty, <TrackListProperty as RawBitFlags>::Numeric>

The resulting type after applying the & operator.
source§

fn bitand(self, other: Self) -> Self::Output

Performs the & operation. Read more
source§

impl BitFlag for TrackListProperty

§

fn empty() -> BitFlags<Self, Self::Numeric>

Create a BitFlags with no flags set (in other words, with a value of 0). Read more
§

fn all() -> BitFlags<Self, Self::Numeric>

Create a BitFlags with all flags set. Read more
source§

impl BitOr<TrackListProperty> for TrackListProperty

§

type Output = BitFlags<TrackListProperty, <TrackListProperty as RawBitFlags>::Numeric>

The resulting type after applying the | operator.
source§

fn bitor(self, other: Self) -> Self::Output

Performs the | operation. Read more
source§

impl BitXor<TrackListProperty> for TrackListProperty

§

type Output = BitFlags<TrackListProperty, <TrackListProperty as RawBitFlags>::Numeric>

The resulting type after applying the ^ operator.
source§

fn bitxor(self, other: Self) -> Self::Output

Performs the ^ operation. Read more
source§

impl Clone for TrackListProperty

source§

fn clone(&self) -> TrackListProperty

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for TrackListProperty

source§

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

Formats the value using the given formatter. Read more
source§

impl Not for TrackListProperty

§

type Output = BitFlags<TrackListProperty, <TrackListProperty as RawBitFlags>::Numeric>

The resulting type after applying the ! operator.
source§

fn not(self) -> Self::Output

Performs the unary ! operation. Read more
source§

impl PartialEq<TrackListProperty> for TrackListProperty

source§

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

This method tests for self and other values to be equal, and is used +

Variants§

§

Tracks

§

CanEditTracks

Trait Implementations§

source§

impl BitAnd<TrackListProperty> for TrackListProperty

§

type Output = BitFlags<TrackListProperty, <TrackListProperty as RawBitFlags>::Numeric>

The resulting type after applying the & operator.
source§

fn bitand(self, other: Self) -> Self::Output

Performs the & operation. Read more
source§

impl BitFlag for TrackListProperty

§

fn empty() -> BitFlags<Self, Self::Numeric>

Create a BitFlags with no flags set (in other words, with a value of 0). Read more
§

fn all() -> BitFlags<Self, Self::Numeric>

Create a BitFlags with all flags set. Read more
source§

impl BitOr<TrackListProperty> for TrackListProperty

§

type Output = BitFlags<TrackListProperty, <TrackListProperty as RawBitFlags>::Numeric>

The resulting type after applying the | operator.
source§

fn bitor(self, other: Self) -> Self::Output

Performs the | operation. Read more
source§

impl BitXor<TrackListProperty> for TrackListProperty

§

type Output = BitFlags<TrackListProperty, <TrackListProperty as RawBitFlags>::Numeric>

The resulting type after applying the ^ operator.
source§

fn bitxor(self, other: Self) -> Self::Output

Performs the ^ operation. Read more
source§

impl Clone for TrackListProperty

source§

fn clone(&self) -> TrackListProperty

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for TrackListProperty

source§

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

Formats the value using the given formatter. Read more
source§

impl Not for TrackListProperty

§

type Output = BitFlags<TrackListProperty, <TrackListProperty as RawBitFlags>::Numeric>

The resulting type after applying the ! operator.
source§

fn not(self) -> Self::Output

Performs the unary ! operation. Read more
source§

impl PartialEq<TrackListProperty> for TrackListProperty

source§

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

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

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

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

impl RawBitFlags for TrackListProperty

§

type Numeric = u32

The underlying integer type.
source§

const EMPTY: Self::Numeric = {transmute(0x00000000): <property::TrackListProperty as enumflags2::_internal::RawBitFlags>::Numeric}

A value with no bits set.
source§

const DEFAULT: Self::Numeric = {transmute(0x00000000): <property::TrackListProperty as enumflags2::_internal::RawBitFlags>::Numeric}

The value used by the Default implementation. Equivalent to EMPTY, unless customized.
source§

const ALL_BITS: Self::Numeric = {transmute(0x00000003): <property::TrackListProperty as enumflags2::_internal::RawBitFlags>::Numeric}

A value with all flag bits set.
source§

const BITFLAGS_TYPE_NAME: &'static str = _

The name of the type for debug formatting purposes. Read more
source§

fn bits(self) -> Self::Numeric

Return the bits as a number type.
source§

impl Copy for TrackListProperty

source§

impl Eq for TrackListProperty

source§

impl StructuralEq for TrackListProperty

source§

impl StructuralPartialEq for TrackListProperty

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere diff --git a/mpris_server/export/index.html b/mpris_server/export/index.html index 5a40856..92746a6 100644 --- a/mpris_server/export/index.html +++ b/mpris_server/export/index.html @@ -1 +1,2 @@ -mpris_server::export - Rust

Module mpris_server::export

source ·

Re-exports

\ No newline at end of file +mpris_server::export - Rust

Module mpris_server::export

source ·
Expand description

This contains libraries that are used alongside with this crate.

+

Re-exports

\ No newline at end of file diff --git a/mpris_server/index.html b/mpris_server/index.html index f842d58..3780d51 100644 --- a/mpris_server/index.html +++ b/mpris_server/index.html @@ -1,148 +1,84 @@ -mpris_server - Rust

Crate mpris_server

source ·
Expand description
-

Warning -The API is still unstable. Expect breaking changes.

-
-

MPRIS Server

+mpris_server - Rust

Crate mpris_server

source ·
Expand description

MPRIS Server

docs crates.io CI

-

Create MPRIS MediaPlayer2 server

-

To implement a server, this crate provides two flavors: you can either create a custom struct that implements RootInterface and PlayerInterface, or you can use the premade mutable Player struct.

-

Player Usage

-

If you want to create a simple player without having to implement the interfaces, you can use the premade Player struct that implements those interfaces internally. This struct is mutable, automatically emits properties changed signal, and allows you to connect to method calls.

- -
use mpris_server::Player;
-
-#[async_std::main]
-async fn main() {
-    let player = Player::builder("com.me.Application")
-        .can_play(true)
-        .can_pause(true)
-        .build()
-        .unwrap();
-
-    player.connect_play_pause(|| {
-        println!("PlayPause");
-    });
-
-    player.run().await.unwrap();
-}
-

Supported Interfaces

-

This library supports all interfaces defined in the MPRIS2 specification. However, the premade Player struct currently only supports the more commonly used org.mpris.MediaPlayer2 and org.mpris.MediaPlayer2.Player interfaces.

-

org.mpris.MediaPlayer2 and org.mpris.MediaPlayer2.Player

-
use mpris_server::{export::async_trait, Server};
+

Implement MPRIS D-Bus interface in your application.

+

By implementing the MPRIS D-Bus interface, your application can be controlled by other applications that support MPRIS, such as GNOME Shell, KDE Plasma, and other media controllers.

+

This library supports all the following interfaces as defined in the MPRIS D-Bus Interface Specification v2:

+ +

To implement the MPRIS D-Bus Interface, this crate provides two flavors: you can either create a custom struct that implements RootInterface and PlayerInterface, or you can use the ready-to-use mutable Player struct.

+

Examples

Manual Implementation (via Server or LocalServer)

+
use mpris_server::{
+    export::{async_trait::async_trait, zbus::fdo},
+    Metadata, PlayerInterface, Property, RootInterface, Server, Time, TrackId,
+};
 
 pub struct MyPlayer;
 
 #[async_trait]
 impl RootInterface for MyPlayer {
-    ...
-}
-
-#[async_trait]
-impl PlayerInterface for MyPlayer {
-    ...
-}
-
-#[async_std::main]
-async fn main() {
-    let server = Server::new("com.me.Application", MyPlayer).unwrap();
-    server.run().await.unwrap();
-}
-

org.mpris.MediaPlayer2.TrackList

-
use mpris_server::{export::async_trait, Server};
-
-pub struct MyPlayer;
+    async fn identity(&self) -> fdo::Result<String> {
+        unimplemented!()
+    }
 
-#[async_trait]
-impl RootInterface for MyPlayer {
     ...
 }
 
 #[async_trait]
 impl PlayerInterface for MyPlayer {
-    ...
-}
+    async fn set_position(&self, track_id: TrackId, position: Time) -> fdo::Result<()> {
+        unimplemented!()
+    }
+
+    async fn metadata(&self) -> fdo::Result<Metadata> {
+        unimplemented!()
+    }
 
-#[async_trait]
-impl TracklistInterface for MyPlayer {
     ...
 }
 
 #[async_std::main]
 async fn main() {
     let server = Server::new("com.me.Application", MyPlayer).unwrap();
-    server.run_with_track_list().await.unwrap();
+    server.init().await.unwrap();
+    server.properties_changed(Property::Position | Property::Metadata).await.unwrap();
+    server.seeked(Time::from_micros(124)).await.unwrap();
 }
-

org.mpris.MediaPlayer2.Playlists

-
use mpris_server::{export::async_trait, Server};
-
-pub struct MyPlayer;
-
-#[async_trait]
-impl RootInterface for MyPlayer {
-    ...
-}
-
-#[async_trait]
-impl PlayerInterface for MyPlayer {
-    ...
-}
+

For more examples, see the examples directory.

+

Ready-to-use Implementation (via Player)

+

If you want to create a simple player without having to implement the interfaces, you can use the ready-to-use Player struct that implements those interfaces internally. This struct is mutable, automatically emits properties changed signal, and allows you to connect to method and property setter calls.

+

However, Player currently only supports the more commonly used org.mpris.MediaPlayer2 and org.mpris.MediaPlayer2.Player interfaces.

-#[async_trait] -impl PlaylistsInterface for MyPlayer { - ... -} +
use mpris_server::Player;
 
 #[async_std::main]
 async fn main() {
-    let server = Server::new("com.me.Application", MyPlayer).unwrap();
-    server.run_with_playlists().await.unwrap();
-}
-

org.mpris.MediaPlayer2.TrackList and org.mpris.MediaPlayer2.Playlists

-
use mpris_server::{export::async_trait, Server};
-
-pub struct MyPlayer;
-
-#[async_trait]
-impl RootInterface for MyPlayer {
-    ...
-}
-
-#[async_trait]
-impl PlayerInterface for MyPlayer {
-    ...
-}
-
-#[async_trait]
-impl PlaylistsInterface for MyPlayer {
-    ...
-}
+    let player = Player::builder("com.me.Application")
+        .can_play(true)
+        .can_pause(true)
+        .build()
+        .unwrap();
 
-#[async_trait]
-impl TracklistInterface for MyPlayer {
-    ...
-}
+    player.connect_play_pause(|| {
+        println!("PlayPause");
+    });
 
-#[async_std::main]
-async fn main() {
-    let server = Server::new("com.me.Application", MyPlayer).unwrap();
-    server.run_with_all().await.unwrap();
+    player.run().await.unwrap();
 }
-

For more examples, see the examples directory.

-

TODO

-
    -
  • Document public interface
  • -
  • Replace TimeInUs, DateTime, and Uri with proper types
  • -
  • Add getter on Metadata
  • -
  • Profile if inlining is worth it
  • -
-

Modules

Structs

  • Local version of Server that doesn’t require T to be Send and -Sync.
  • A data structure describing a playlist, or nothing.
  • A mapping from metadata attribute names to values.
  • Ready-made mutable object that internally implements LocalRootInterface -and LocalPlayerInterface.
  • A data structure describing a playlist.
  • Thin wrapper around [zbus::Connection] that calls to T’s implementation +

    License

    +

    Copyright 2023 Dave Patrick Caberto

    +

    This software is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at this site.

    +

Modules

  • This contains the definitions of builder-pattern structs.
  • This contains libraries that are used alongside with this crate.

Structs

Enums

Enums

Type Definitions

  • Date/time fields should be sent as strings in ISO 8601 extended -format (eg: 2007-04-29T14:35:51). If the timezone is known (eg: for -xesam:lastPlayed), the internet profile format of ISO 8601, as specified in -RFC 3339, should be used (eg: 2007-04-29T14:35:51+02:00).
  • A playback rate.
  • Unique playlist identifier.
  • Time in microseconds.
  • A unique resource identifier.
  • Audio volume level.
\ No newline at end of file +player’s playlist.

Type Definitions

\ No newline at end of file diff --git a/mpris_server/sidebar-items.js b/mpris_server/sidebar-items.js index 7f985d9..dcd7aa3 100644 --- a/mpris_server/sidebar-items.js +++ b/mpris_server/sidebar-items.js @@ -1 +1 @@ -window.SIDEBAR_ITEMS = {"enum":["LoopStatus","PlaybackStatus","PlaylistOrdering","PlaylistsProperty","Property","TrackListProperty"],"mod":["builder","export"],"struct":["LocalServer","MaybePlaylist","Metadata","Player","Playlist","Server","TrackId"],"trait":["LocalPlayerInterface","LocalPlaylistsInterface","LocalRootInterface","LocalTrackListInterface","PlayerInterface","PlaylistsInterface","RootInterface","TrackListInterface"],"type":["DateTime","PlaybackRate","PlaylistId","TimeInUs","Uri","Volume"]}; \ No newline at end of file +window.SIDEBAR_ITEMS = {"enum":["LoopStatus","PlaybackStatus","PlaylistOrdering","PlaylistsProperty","Property","TrackListProperty"],"mod":["builder","export"],"struct":["LocalServer","MaybePlaylist","Metadata","Player","Playlist","Server","Time","TrackId"],"trait":["LocalPlayerInterface","LocalPlaylistsInterface","LocalRootInterface","LocalTrackListInterface","PlayerInterface","PlaylistsInterface","RootInterface","TrackListInterface"],"type":["DateTime","PlaybackRate","PlaylistId","Uri","Volume"]}; \ No newline at end of file diff --git a/mpris_server/struct.LocalServer.html b/mpris_server/struct.LocalServer.html index 1207bfa..a1871bb 100644 --- a/mpris_server/struct.LocalServer.html +++ b/mpris_server/struct.LocalServer.html @@ -1,34 +1,39 @@ -LocalServer in mpris_server - Rust
pub struct LocalServer<T>where
+LocalServer in mpris_server - Rust
pub struct LocalServer<T>where
     T: LocalPlayerInterface + 'static,{ /* private fields */ }
Expand description

Local version of Server that doesn’t require T to be Send and Sync.

For more information, see Server documentations.

-

Implementations§

source§

impl<T> LocalServer<T>where - T: LocalPlayerInterface + 'static,

source

pub fn new(bus_name_suffix: &str, imp: T) -> Result<Self>

source

pub fn imp(&self) -> &T

source

pub async fn run(&self) -> Result<()>

source

pub async fn seeked(&self, position: TimeInUs) -> Result<()>

source

pub async fn properties_changed( +

Implementations§

source§

impl<T> LocalServer<T>where + T: LocalPlayerInterface + 'static,

source

pub fn new(bus_name_suffix: &str, imp: T) -> Result<Self>

source

pub fn imp(&self) -> &T

Returns a reference to the inner implementation.

+
source

pub async fn run(&self) -> Result<()>

Run the server. This method will continually run until the server is +dropped.

+

This is no-op and returns Ok immediately if the server is already +running.

+
source

pub async fn seeked(&self, position: Time) -> Result<()>

source

pub async fn properties_changed( &self, properties: impl Into<BitFlags<Property>> -) -> Result<()>

source§

impl<T> LocalServer<T>where - T: LocalTrackListInterface + 'static,

source

pub fn new_with_track_list(bus_name_suffix: &str, imp: T) -> Result<Self>

source

pub async fn track_list_replaced( +) -> Result<()>

source§

impl<T> LocalServer<T>where + T: LocalTrackListInterface + 'static,

source

pub fn new_with_track_list(bus_name_suffix: &str, imp: T) -> Result<Self>

source

pub async fn track_list_replaced( &self, tracks: Vec<TrackId>, current_track: TrackId -) -> Result<()>

source

pub async fn track_added( +) -> Result<()>

source

pub async fn track_added( &self, metadata: Metadata, after_track: TrackId -) -> Result<()>

source

pub async fn track_removed(&self, track_id: TrackId) -> Result<()>

source

pub async fn track_metadata_changed( +) -> Result<()>

source

pub async fn track_removed(&self, track_id: TrackId) -> Result<()>

source

pub async fn track_metadata_changed( &self, track_id: TrackId, metadata: Metadata -) -> Result<()>

source

pub async fn track_list_properties_changed( +) -> Result<()>

source

pub async fn track_list_properties_changed( &self, properties: impl Into<BitFlags<TrackListProperty>> -) -> Result<()>

source§

impl<T> LocalServer<T>where - T: LocalPlaylistsInterface + 'static,

source

pub fn new_with_playlists(bus_name_suffix: &str, imp: T) -> Result<Self>

source

pub async fn playlist_changed(&self, playlist: Playlist) -> Result<()>

source

pub async fn playlists_properties_changed( +) -> Result<()>

source§

impl<T> LocalServer<T>where + T: LocalPlaylistsInterface + 'static,

source

pub fn new_with_playlists(bus_name_suffix: &str, imp: T) -> Result<Self>

source

pub async fn playlist_changed(&self, playlist: Playlist) -> Result<()>

source

pub async fn playlists_properties_changed( &self, properties: impl Into<BitFlags<PlaylistsProperty>> -) -> Result<()>

source§

impl<T> LocalServer<T>where - T: LocalTrackListInterface + LocalPlaylistsInterface + 'static,

source

pub fn new_with_all(bus_name_suffix: &str, imp: T) -> Result<Self>

Trait Implementations§

source§

impl<T> Debug for LocalServer<T>where - T: LocalPlayerInterface + 'static,

source§

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

Formats the value using the given formatter. Read more

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> Any for Twhere +) -> Result<()>

source§

impl<T> LocalServer<T>where + T: LocalTrackListInterface + LocalPlaylistsInterface + 'static,

source

pub fn new_with_all(bus_name_suffix: &str, imp: T) -> Result<Self>

Trait Implementations§

source§

impl<T> Debug for LocalServer<T>where + T: LocalPlayerInterface + 'static,

source§

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

Formats the value using the given formatter. Read more

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> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

source§

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

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

diff --git a/mpris_server/struct.MaybePlaylist.html b/mpris_server/struct.MaybePlaylist.html index 3eb308e..4aa2f01 100644 --- a/mpris_server/struct.MaybePlaylist.html +++ b/mpris_server/struct.MaybePlaylist.html @@ -1,18 +1,20 @@ -MaybePlaylist in mpris_server - Rust
pub struct MaybePlaylist { /* private fields */ }
Expand description

A data structure describing a playlist, or nothing.

+MaybePlaylist in mpris_server - Rust
pub struct MaybePlaylist { /* private fields */ }
Expand description

A data structure describing a playlist, or nothing.

Rationale

D-Bus does not (at the time of writing) support a MAYBE type, so we are forced to invent our own.

-

Implementations§

source§

impl MaybePlaylist

source

pub fn some(playlist: Playlist) -> Self

Construct a valid MaybePlaylist from the given playlist.

-
source

pub fn none() -> Self

Construct a MaybePlaylist that contains invalid/no playlist.

+

Implementations§

source§

impl MaybePlaylist

source

pub fn just(playlist: Playlist) -> Self

Construct a valid MaybePlaylist from the given playlist.

+
source

pub fn nothing() -> Self

Construct a MaybePlaylist that contains invalid/no playlist.

The playlist ID will be set to “/”, and the name and icon will be empty.

-

Trait Implementations§

source§

impl Clone for MaybePlaylist

source§

fn clone(&self) -> MaybePlaylist

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for MaybePlaylist

source§

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

Formats the value using the given formatter. Read more
source§

impl<'a> From<MaybePlaylist> for Value<'a>

source§

fn from(mp: MaybePlaylist) -> Self

Converts to this type from the input type.
source§

impl From<Option<Playlist>> for MaybePlaylist

source§

fn from(opt: Option<Playlist>) -> Self

Converts to this type from the input type.
source§

impl From<Playlist> for MaybePlaylist

source§

fn from(playlist: Playlist) -> Self

Converts to this type from the input type.
source§

impl PartialEq<MaybePlaylist> for MaybePlaylist

source§

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

This method tests for self and other values to be equal, and is used +
source

pub fn get(&self) -> Option<&Playlist>

Returns Some if this structure contains a valid playlist, otherwise +None.

+

Trait Implementations§

source§

impl Clone for MaybePlaylist

source§

fn clone(&self) -> MaybePlaylist

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for MaybePlaylist

source§

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

Formats the value using the given formatter. Read more
source§

impl From<MaybePlaylist> for Option<Playlist>

source§

fn from(mp: MaybePlaylist) -> Self

Converts to this type from the input type.
source§

impl<'a> From<MaybePlaylist> for Value<'a>

source§

fn from(mp: MaybePlaylist) -> Self

Converts to this type from the input type.
source§

impl From<Option<Playlist>> for MaybePlaylist

source§

fn from(opt: Option<Playlist>) -> Self

Converts to this type from the input type.
source§

impl From<Playlist> for MaybePlaylist

source§

fn from(playlist: Playlist) -> Self

Converts to this type from the input type.
source§

impl PartialEq<MaybePlaylist> for MaybePlaylist

source§

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

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

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

This method tests for !=. The default implementation is almost always -sufficient, and should not be overridden without very good reason.
source§

impl Serialize for MaybePlaylist

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>where - __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Type for MaybePlaylist

source§

fn signature() -> Signature<'static>

Get the signature for the implementing type. Read more
source§

impl Eq for MaybePlaylist

source§

impl StructuralEq for MaybePlaylist

source§

impl StructuralPartialEq for MaybePlaylist

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere +sufficient, and should not be overridden without very good reason.

source§

impl Serialize for MaybePlaylist

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>where + __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Type for MaybePlaylist

source§

fn signature() -> Signature<'static>

Get the signature for the implementing type. Read more
source§

impl Eq for MaybePlaylist

source§

impl StructuralEq for MaybePlaylist

source§

impl StructuralPartialEq for MaybePlaylist

Auto Trait Implementations§

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

source§

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

Mutably borrows from an owned value. Read more
§

impl<T> DynamicType for Twhere - T: Type + ?Sized,

§

fn dynamic_signature(&self) -> Signature<'_>

Get the signature for the implementing type. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

+ T: Type + ?Sized,
§

fn dynamic_signature(&self) -> Signature<'_>

Get the signature for the implementing type. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T> Instrument for T

source§

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

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

fn in_current_span(self) -> Instrumented<Self>

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

impl<T, U> Into<U> for Twhere diff --git a/mpris_server/struct.Metadata.html b/mpris_server/struct.Metadata.html index bbde975..7bd2748 100644 --- a/mpris_server/struct.Metadata.html +++ b/mpris_server/struct.Metadata.html @@ -1,72 +1,72 @@ -Metadata in mpris_server - Rust

Struct mpris_server::Metadata

source ·
pub struct Metadata(_);
Expand description

A mapping from metadata attribute names to values.

+Metadata in mpris_server - Rust

Struct mpris_server::Metadata

source ·
pub struct Metadata(_);
Expand description

A mapping from metadata attribute names to values.

The mpris:trackid attribute must always be present.

If the length of the track is known, it should be provided in the metadata property with the mpris:length key.

If there is an image associated with the track, a URL for it may be provided using the mpris:artUrl key.

-

Implementations§

source§

impl Metadata

source

pub fn new() -> Self

Create an empty Metadata.

-
source

pub fn builder() -> MetadataBuilder

Creates a new builder-pattern struct instance to construct Metadata.

-
source

pub fn insert( +

Implementations§

source§

impl Metadata

source

pub fn new() -> Self

Create an empty Metadata.

+
source

pub fn builder() -> MetadataBuilder

Creates a new builder-pattern struct instance to construct Metadata.

+
source

pub fn insert( &mut self, key: impl Into<String>, value: impl Into<Value<'static>> ) -> Option<Value<'static>>

Insert a new key-value pair into the metadata.

This will overwrite any existing value for the given key and will return the old value, if any.

-
source

pub fn get<'v, V>(&'v self, key: &str) -> Option<Result<&'v V>>where +

source

pub fn get<'v, V>(&'v self, key: &str) -> Option<Result<&'v V>>where &'v V: TryFrom<&'v Value<'v>>,

Get the value of the given key and convert it to V, if it exists.

-
source

pub fn get_value(&self, key: &str) -> Option<&Value<'_>>

Get the value of the given key, if it exists.

-
source

pub fn set_trackid(&mut self, trackid: impl Into<OwnedObjectPath>)

A unique identity for this track within the context of an +

source

pub fn get_value(&self, key: &str) -> Option<&Value<'_>>

Get the value of the given key, if it exists.

+
source

pub fn set_trackid(&mut self, trackid: impl Into<OwnedObjectPath>)

A unique identity for this track within the context of an MPRIS object (eg: tracklist).

This contains a D-Bus path that uniquely identifies the track within the scope of the playlist. There may or may not be an actual D-Bus object at that path; this specification says nothing about what interfaces such an object may implement.

-
source

pub fn set_length(&mut self, length: TimeInUs)

The duration of the track in microseconds.

-
source

pub fn set_art_url(&mut self, art_url: impl Into<Uri>)

The location of an image representing the track or album.

+
source

pub fn set_length(&mut self, length: Time)

The duration of the track in microseconds.

+
source

pub fn set_art_url(&mut self, art_url: impl Into<Uri>)

The location of an image representing the track or album.

Clients should not assume this will continue to exist when the media player stops giving out the URL.

-
source

pub fn set_album(&mut self, album: impl Into<String>)

The album name.

-
source

pub fn set_album_artist( +

source

pub fn set_album(&mut self, album: impl Into<String>)

The album name.

+
source

pub fn set_album_artist( &mut self, album_artist: impl IntoIterator<Item = impl Into<String>> )

The album artist(s).

-
source

pub fn set_artist( +

source

pub fn set_artist( &mut self, artist: impl IntoIterator<Item = impl Into<String>> )

The track artist(s).

-
source

pub fn set_lyrics(&mut self, lyrics: impl Into<String>)

The track lyrics.

-
source

pub fn set_audio_bpm(&mut self, audio_bpm: i32)

The speed of the music, in beats per minute.

-
source

pub fn set_auto_rating(&mut self, auto_rating: f64)

An automatically-generated rating, based on things such +

source

pub fn set_lyrics(&mut self, lyrics: impl Into<String>)

The track lyrics.

+
source

pub fn set_audio_bpm(&mut self, audio_bpm: i32)

The speed of the music, in beats per minute.

+
source

pub fn set_auto_rating(&mut self, auto_rating: f64)

An automatically-generated rating, based on things such as how often it has been played. This should be in the range 0.0 to 1.0.

-
source

pub fn set_comment( +

source

pub fn set_comment( &mut self, comment: impl IntoIterator<Item = impl Into<String>> )

A (list of) freeform comment(s).

-
source

pub fn set_composer( +

source

pub fn set_composer( &mut self, composer: impl IntoIterator<Item = impl Into<String>> )

The composer(s) of the track.

-
source

pub fn set_content_created(&mut self, content_created: impl Into<DateTime>)

When the track was created. Usually only the year component +

source

pub fn set_content_created(&mut self, content_created: impl Into<DateTime>)

When the track was created. Usually only the year component will be useful.

-
source

pub fn set_disc_number(&mut self, disc_number: i32)

The disc number on the album that this track is from.

-
source

pub fn set_first_used(&mut self, first_used: impl Into<DateTime>)

When the track was first played.

-
source

pub fn set_genre(&mut self, genre: impl IntoIterator<Item = impl Into<String>>)

The genre(s) of the track.

-
source

pub fn set_last_used(&mut self, last_used: impl Into<DateTime>)

When the track was last played.

-
source

pub fn set_lyricist( +

source

pub fn set_disc_number(&mut self, disc_number: i32)

The disc number on the album that this track is from.

+
source

pub fn set_first_used(&mut self, first_used: impl Into<DateTime>)

When the track was first played.

+
source

pub fn set_genre(&mut self, genre: impl IntoIterator<Item = impl Into<String>>)

The genre(s) of the track.

+
source

pub fn set_last_used(&mut self, last_used: impl Into<DateTime>)

When the track was last played.

+
source

pub fn set_lyricist( &mut self, lyricist: impl IntoIterator<Item = impl Into<String>> )

The lyricist(s) of the track.

-
source

pub fn set_title(&mut self, title: impl Into<String>)

The track title.

-
source

pub fn set_track_number(&mut self, track_number: i32)

The track number on the album disc.

-
source

pub fn set_url(&mut self, url: impl Into<Uri>)

The location of the media file.

-
source

pub fn set_use_count(&mut self, use_count: i32)

The number of times the track has been played.

-
source

pub fn set_user_rating(&mut self, user_rating: f64)

A user-specified rating. This should be in the range 0.0 to 1.0.

-

Trait Implementations§

source§

impl Clone for Metadata

source§

fn clone(&self) -> Metadata

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for Metadata

source§

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

Formats the value using the given formatter. Read more
source§

impl Default for Metadata

source§

fn default() -> Self

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

impl<'a> From<Metadata> for Value<'a>

source§

fn from(metainfo: Metadata) -> Self

Converts to this type from the input type.
source§

impl PartialEq<Metadata> for Metadata

source§

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

This method tests for self and other values to be equal, and is used +
source

pub fn set_title(&mut self, title: impl Into<String>)

The track title.

+
source

pub fn set_track_number(&mut self, track_number: i32)

The track number on the album disc.

+
source

pub fn set_url(&mut self, url: impl Into<Uri>)

The location of the media file.

+
source

pub fn set_use_count(&mut self, use_count: i32)

The number of times the track has been played.

+
source

pub fn set_user_rating(&mut self, user_rating: f64)

A user-specified rating. This should be in the range 0.0 to 1.0.

+

Trait Implementations§

source§

impl Clone for Metadata

source§

fn clone(&self) -> Metadata

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for Metadata

source§

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

Formats the value using the given formatter. Read more
source§

impl Default for Metadata

source§

fn default() -> Self

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

impl<'a> From<Metadata> for Value<'a>

source§

fn from(metainfo: Metadata) -> Self

Converts to this type from the input type.
source§

impl PartialEq<Metadata> for Metadata

source§

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

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

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

This method tests for !=. The default implementation is almost always -sufficient, and should not be overridden without very good reason.
source§

impl Serialize for Metadata

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>where - __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Type for Metadata

source§

fn signature() -> Signature<'static>

Get the signature for the implementing type. Read more
source§

impl StructuralPartialEq for Metadata

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere +sufficient, and should not be overridden without very good reason.

source§

impl Serialize for Metadata

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>where + __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Type for Metadata

source§

fn signature() -> Signature<'static>

Get the signature for the implementing type. Read more
source§

impl StructuralPartialEq for Metadata

Auto Trait Implementations§

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

source§

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

Mutably borrows from an owned value. Read more
§

impl<T> DynamicType for Twhere diff --git a/mpris_server/struct.Player.html b/mpris_server/struct.Player.html index eea511b..2cd0ab4 100644 --- a/mpris_server/struct.Player.html +++ b/mpris_server/struct.Player.html @@ -1,21 +1,23 @@ -Player in mpris_server - Rust

Struct mpris_server::Player

source ·
pub struct Player { /* private fields */ }
Expand description

Ready-made mutable object that internally implements LocalRootInterface -and LocalPlayerInterface.

-

Implementations§

source§

impl Player

source

pub fn builder(bus_name_suffix: &str) -> PlayerBuilder

source

pub async fn run(&self) -> Result<()>

source

pub fn connect_raise(&self, cb: impl Fn() + 'static)

source

pub fn connect_quit(&self, cb: impl Fn() + 'static)

source

pub fn connect_set_fullscreen(&self, cb: impl Fn(bool) + 'static)

source

pub fn can_quit(&self) -> bool

source

pub async fn set_can_quit(&self, can_quit: bool) -> Result<()>

source

pub fn fullscreen(&self) -> bool

source

pub async fn set_fullscreen(&self, fullscreen: bool) -> Result<()>

source

pub fn can_set_fullscreen(&self) -> bool

source

pub async fn set_can_set_fullscreen( +Player in mpris_server - Rust

Struct mpris_server::Player

source ·
pub struct Player { /* private fields */ }
Expand description

Ready-to-use mutable object that internally implements +LocalRootInterface and LocalPlayerInterface.

+

This automatically emits properties changed signal and allows you to connect +to method and property setter calls.

+

Implementations§

source§

impl Player

source

pub fn builder(bus_name_suffix: &str) -> PlayerBuilder

source

pub async fn run(&self) -> Result<()>

source

pub fn connect_raise(&self, cb: impl Fn() + 'static)

source

pub fn connect_quit(&self, cb: impl Fn() + 'static)

source

pub fn connect_set_fullscreen(&self, cb: impl Fn(bool) + 'static)

source

pub fn can_quit(&self) -> bool

source

pub async fn set_can_quit(&self, can_quit: bool) -> Result<()>

source

pub fn fullscreen(&self) -> bool

source

pub async fn set_fullscreen(&self, fullscreen: bool) -> Result<()>

source

pub fn can_set_fullscreen(&self) -> bool

source

pub async fn set_can_set_fullscreen( &self, can_set_fullscreen: bool -) -> Result<()>

source

pub fn can_raise(&self) -> bool

source

pub async fn set_can_raise(&self, can_raise: bool) -> Result<()>

source

pub fn has_track_list(&self) -> bool

source

pub async fn set_has_track_list(&self, has_track_list: bool) -> Result<()>

source

pub fn identity(&self) -> Ref<'_, String>

source

pub async fn set_identity(&self, identity: impl Into<String>) -> Result<()>

source

pub fn desktop_entry(&self) -> Ref<'_, String>

source

pub async fn set_desktop_entry( +) -> Result<()>

source

pub fn can_raise(&self) -> bool

source

pub async fn set_can_raise(&self, can_raise: bool) -> Result<()>

source

pub fn has_track_list(&self) -> bool

source

pub async fn set_has_track_list(&self, has_track_list: bool) -> Result<()>

source

pub fn identity(&self) -> Ref<'_, String>

source

pub async fn set_identity(&self, identity: impl Into<String>) -> Result<()>

source

pub fn desktop_entry(&self) -> Ref<'_, String>

source

pub async fn set_desktop_entry( &self, desktop_entry: impl Into<String> -) -> Result<()>

source

pub fn supported_uri_schemes(&self) -> Ref<'_, Vec<String>>

source

pub async fn set_supported_uri_schemes( +) -> Result<()>

source

pub fn supported_uri_schemes(&self) -> Ref<'_, Vec<String>>

source

pub async fn set_supported_uri_schemes( &self, supported_uri_schemes: impl IntoIterator<Item = impl Into<String>> -) -> Result<()>

source

pub fn supported_mime_types(&self) -> Ref<'_, Vec<String>>

source

pub async fn set_supported_mime_types( +) -> Result<()>

source

pub fn supported_mime_types(&self) -> Ref<'_, Vec<String>>

source

pub async fn set_supported_mime_types( &self, supported_mime_types: impl IntoIterator<Item = impl Into<String>> -) -> Result<()>

source

pub fn connect_next(&self, cb: impl Fn() + 'static)

source

pub fn connect_previous(&self, cb: impl Fn() + 'static)

source

pub fn connect_pause(&self, cb: impl Fn() + 'static)

source

pub fn connect_play_pause(&self, cb: impl Fn() + 'static)

source

pub fn connect_stop(&self, cb: impl Fn() + 'static)

source

pub fn connect_play(&self, cb: impl Fn() + 'static)

source

pub fn connect_seek(&self, cb: impl Fn(TimeInUs) + 'static)

source

pub fn connect_set_position(&self, cb: impl Fn(&TrackId, TimeInUs) + 'static)

source

pub fn connect_open_uri(&self, cb: impl Fn(&str) + 'static)

source

pub fn connect_set_loop_status(&self, cb: impl Fn(LoopStatus) + 'static)

source

pub fn connect_set_rate(&self, cb: impl Fn(PlaybackRate) + 'static)

source

pub fn connect_set_shuffle(&self, cb: impl Fn(bool) + 'static)

source

pub fn connect_set_volume(&self, cb: impl Fn(Volume) + 'static)

source

pub async fn emit_seeked(&self, position: TimeInUs) -> Result<()>

source

pub fn playback_status(&self) -> PlaybackStatus

source

pub async fn set_playback_status( +) -> Result<()>

source

pub fn connect_next(&self, cb: impl Fn() + 'static)

source

pub fn connect_previous(&self, cb: impl Fn() + 'static)

source

pub fn connect_pause(&self, cb: impl Fn() + 'static)

source

pub fn connect_play_pause(&self, cb: impl Fn() + 'static)

source

pub fn connect_stop(&self, cb: impl Fn() + 'static)

source

pub fn connect_play(&self, cb: impl Fn() + 'static)

source

pub fn connect_seek(&self, cb: impl Fn(Time) + 'static)

source

pub fn connect_set_position(&self, cb: impl Fn(&TrackId, Time) + 'static)

source

pub fn connect_open_uri(&self, cb: impl Fn(&str) + 'static)

source

pub fn connect_set_loop_status(&self, cb: impl Fn(LoopStatus) + 'static)

source

pub fn connect_set_rate(&self, cb: impl Fn(PlaybackRate) + 'static)

source

pub fn connect_set_shuffle(&self, cb: impl Fn(bool) + 'static)

source

pub fn connect_set_volume(&self, cb: impl Fn(Volume) + 'static)

source

pub async fn emit_seeked(&self, position: Time) -> Result<()>

source

pub fn playback_status(&self) -> PlaybackStatus

source

pub async fn set_playback_status( &self, playback_status: PlaybackStatus -) -> Result<()>

source

pub fn loop_status(&self) -> LoopStatus

source

pub async fn set_loop_status(&self, loop_status: LoopStatus) -> Result<()>

source

pub fn rate(&self) -> PlaybackRate

source

pub async fn set_rate(&self, rate: PlaybackRate) -> Result<()>

source

pub fn shuffle(&self) -> bool

source

pub async fn set_shuffle(&self, shuffle: bool) -> Result<()>

source

pub fn metadata(&self) -> Ref<'_, Metadata>

source

pub async fn set_metadata(&self, metadata: Metadata) -> Result<()>

source

pub fn volume(&self) -> Volume

source

pub async fn set_volume(&self, volume: Volume) -> Result<()>

source

pub fn position(&self) -> TimeInUs

source

pub async fn set_position(&self, position: TimeInUs) -> Result<()>

source

pub fn minimum_rate(&self) -> PlaybackRate

source

pub async fn set_minimum_rate(&self, minimum_rate: PlaybackRate) -> Result<()>

source

pub fn maximum_rate(&self) -> PlaybackRate

source

pub async fn set_maximum_rate(&self, maximum_rate: PlaybackRate) -> Result<()>

source

pub fn can_go_next(&self) -> bool

source

pub async fn set_can_go_next(&self, can_go_next: bool) -> Result<()>

source

pub fn can_go_previous(&self) -> bool

source

pub async fn set_can_go_previous(&self, can_go_previous: bool) -> Result<()>

source

pub fn can_play(&self) -> bool

source

pub async fn set_can_play(&self, can_play: bool) -> Result<()>

source

pub fn can_pause(&self) -> bool

source

pub async fn set_can_pause(&self, can_pause: bool) -> Result<()>

source

pub fn can_seek(&self) -> bool

source

pub async fn set_can_seek(&self, can_seek: bool) -> Result<()>

source

pub fn can_control(&self) -> bool

source

pub async fn set_can_control(&self, can_control: bool) -> Result<()>

Trait Implementations§

source§

impl Debug for Player

source§

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

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl !RefUnwindSafe for Player

§

impl !Send for Player

§

impl !Sync for Player

§

impl Unpin for Player

§

impl !UnwindSafe for Player

Blanket Implementations§

source§

impl<T> Any for Twhere +) -> Result<()>

source

pub fn loop_status(&self) -> LoopStatus

source

pub async fn set_loop_status(&self, loop_status: LoopStatus) -> Result<()>

source

pub fn rate(&self) -> PlaybackRate

source

pub async fn set_rate(&self, rate: PlaybackRate) -> Result<()>

source

pub fn shuffle(&self) -> bool

source

pub async fn set_shuffle(&self, shuffle: bool) -> Result<()>

source

pub fn metadata(&self) -> Ref<'_, Metadata>

source

pub async fn set_metadata(&self, metadata: Metadata) -> Result<()>

source

pub fn volume(&self) -> Volume

source

pub async fn set_volume(&self, volume: Volume) -> Result<()>

source

pub fn position(&self) -> Time

source

pub async fn set_position(&self, position: Time) -> Result<()>

source

pub fn minimum_rate(&self) -> PlaybackRate

source

pub async fn set_minimum_rate(&self, minimum_rate: PlaybackRate) -> Result<()>

source

pub fn maximum_rate(&self) -> PlaybackRate

source

pub async fn set_maximum_rate(&self, maximum_rate: PlaybackRate) -> Result<()>

source

pub fn can_go_next(&self) -> bool

source

pub async fn set_can_go_next(&self, can_go_next: bool) -> Result<()>

source

pub fn can_go_previous(&self) -> bool

source

pub async fn set_can_go_previous(&self, can_go_previous: bool) -> Result<()>

source

pub fn can_play(&self) -> bool

source

pub async fn set_can_play(&self, can_play: bool) -> Result<()>

source

pub fn can_pause(&self) -> bool

source

pub async fn set_can_pause(&self, can_pause: bool) -> Result<()>

source

pub fn can_seek(&self) -> bool

source

pub async fn set_can_seek(&self, can_seek: bool) -> Result<()>

source

pub fn can_control(&self) -> bool

source

pub async fn set_can_control(&self, can_control: bool) -> Result<()>

Trait Implementations§

source§

impl Debug for Player

source§

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

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl !RefUnwindSafe for Player

§

impl !Send for Player

§

impl !Sync for Player

§

impl Unpin for Player

§

impl !UnwindSafe for Player

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

source§

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

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

diff --git a/mpris_server/struct.Playlist.html b/mpris_server/struct.Playlist.html index f810981..061aefb 100644 --- a/mpris_server/struct.Playlist.html +++ b/mpris_server/struct.Playlist.html @@ -7,7 +7,7 @@

This should remain the same if the playlist is renamed.

§name: String

The name of the playlist, typically given by the user.

§icon: Uri

The URI of an (optional) icon.

-

Trait Implementations§

source§

impl Clone for Playlist

source§

fn clone(&self) -> Playlist

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for Playlist

source§

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

Formats the value using the given formatter. Read more
source§

impl From<Playlist> for MaybePlaylist

source§

fn from(playlist: Playlist) -> Self

Converts to this type from the input type.
source§

impl<'a> From<Playlist> for Value<'a>

source§

fn from(p: Playlist) -> Self

Converts to this type from the input type.
source§

impl PartialEq<Playlist> for Playlist

source§

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

This method tests for self and other values to be equal, and is used +

Trait Implementations§

source§

impl Clone for Playlist

source§

fn clone(&self) -> Playlist

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for Playlist

source§

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

Formats the value using the given formatter. Read more
source§

impl From<Playlist> for MaybePlaylist

source§

fn from(playlist: Playlist) -> Self

Converts to this type from the input type.
source§

impl<'a> From<Playlist> for Value<'a>

source§

fn from(p: Playlist) -> Self

Converts to this type from the input type.
source§

impl PartialEq<Playlist> for Playlist

source§

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

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

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

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

impl Serialize for Playlist

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Type for Playlist

source§

fn signature() -> Signature<'static>

Get the signature for the implementing type. Read more
source§

impl Eq for Playlist

source§

impl StructuralEq for Playlist

source§

impl StructuralPartialEq for Playlist

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere diff --git a/mpris_server/struct.Server.html b/mpris_server/struct.Server.html index c0d2acc..79625ba 100644 --- a/mpris_server/struct.Server.html +++ b/mpris_server/struct.Server.html @@ -1,5 +1,5 @@ Server in mpris_server - Rust

Struct mpris_server::Server

source ·
pub struct Server<T>where
-    T: PlayerInterface + Send + Sync + 'static,{ /* private fields */ }
Expand description

Thin wrapper around [zbus::Connection] that calls to T’s implementation + T: PlayerInterface + 'static,{ /* private fields */ }

Expand description

Thin wrapper around [zbus::Connection] that calls to T’s implementation of RootInterface, PlayerInterface, TrackListInterface, and PlaylistsInterface to implement org.mpris.MediaPlayer2 and its sub-interfaces.

@@ -8,10 +8,11 @@ manually using Server::properties_changed, Server::track_list_properties_changed, or Server::playlists_properties_changed.

-

Implementations§

source§

impl<T> Server<T>where - T: PlayerInterface + Send + Sync + 'static,

source

pub fn new(bus_name_suffix: &str, imp: T) -> Result<Self>

Creates a new Server with the given bus name suffix and +

Implementations§

source§

impl<T> Server<T>where + T: PlayerInterface + 'static,

source

pub fn new(bus_name_suffix: &str, imp: T) -> Result<Self>

Creates a new Server with the given bus name suffix and implementation, which must implement RootInterface and PlayerInterface.

+

To start the connection, Server::init must be called.

The resulting bus name will be org.mpris.MediaPlayer2.<bus_name_suffix>, where <bus_name_suffix>must be a unique identifier, such as one based on a @@ -22,49 +23,53 @@

Note: According to the D-Bus specification, the unique identifier “must only contain the ASCII characters [A-Z][a-z][0-9]_-” and “must not begin with a digit”.

-
source

pub async fn init(&self) -> Result<()>

source

pub fn imp(&self) -> &T

Returns a reference to the underlying implementation.

-
source

pub async fn seeked(&self, position: TimeInUs) -> Result<()>

source

pub async fn properties_changed( +

source

pub async fn init(&self) -> Result<()>

Initializes the connection.

+

This is a no-op if the connection has already been initialized.

+

This is also called automatically when emitting signals and properties +changed.

+
source

pub fn imp(&self) -> &T

Returns a reference to the underlying implementation.

+
source

pub async fn seeked(&self, position: Time) -> Result<()>

source

pub async fn properties_changed( &self, properties: impl Into<BitFlags<Property>> ) -> Result<()>

Emits the PropertiesChanged signal for the given properties.

-
source§

impl<T> Server<T>where - T: TrackListInterface + Send + Sync + 'static,

source

pub fn new_with_track_list(bus_name_suffix: &str, imp: T) -> Result<Self>

Creates a new Server with the given bus name suffix and +

source§

impl<T> Server<T>where + T: TrackListInterface + 'static,

source

pub fn new_with_track_list(bus_name_suffix: &str, imp: T) -> Result<Self>

Creates a new Server with the given bus name suffix and implementation, which must implement TrackListInterface in addition to RootInterface and PlayerInterface.

See also Server::new.

-
source

pub async fn track_list_replaced( +

source

pub async fn track_list_replaced( &self, tracks: Vec<TrackId>, current_track: TrackId -) -> Result<()>

source

pub async fn track_added( +) -> Result<()>

source

pub async fn track_added( &self, metadata: Metadata, after_track: TrackId -) -> Result<()>

source

pub async fn track_removed(&self, track_id: TrackId) -> Result<()>

source

pub async fn track_metadata_changed( +) -> Result<()>

source

pub async fn track_removed(&self, track_id: TrackId) -> Result<()>

source

pub async fn track_metadata_changed( &self, track_id: TrackId, metadata: Metadata -) -> Result<()>

source

pub async fn track_list_properties_changed( +) -> Result<()>

source

pub async fn track_list_properties_changed( &self, properties: impl Into<BitFlags<TrackListProperty>> ) -> Result<()>

Emits the PropertiesChanged signal for the given properties.

-
source§

impl<T> Server<T>where - T: PlaylistsInterface + Send + Sync + 'static,

source

pub fn new_with_playlists(bus_name_suffix: &str, imp: T) -> Result<Self>

Creates a new Server with the given bus name suffix and +

source§

impl<T> Server<T>where + T: PlaylistsInterface + 'static,

source

pub fn new_with_playlists(bus_name_suffix: &str, imp: T) -> Result<Self>

Creates a new Server with the given bus name suffix and implementation, which must implement PlaylistsInterface in addition to RootInterface and PlayerInterface.

See also Server::new.

-
source

pub async fn playlist_changed(&self, playlist: Playlist) -> Result<()>

source

pub async fn playlists_properties_changed( +

source

pub async fn playlist_changed(&self, playlist: Playlist) -> Result<()>

source

pub async fn playlists_properties_changed( &self, properties: impl Into<BitFlags<PlaylistsProperty>> ) -> Result<()>

Emits the PropertiesChanged signal for the given properties.

-

source§

impl<T> Server<T>where - T: TrackListInterface + PlaylistsInterface + Send + Sync + 'static,

source

pub fn new_with_all(bus_name_suffix: &str, imp: T) -> Result<Self>

Creates a new Server with the given bus name suffix and +

source§

impl<T> Server<T>where + T: TrackListInterface + PlaylistsInterface + 'static,

source

pub fn new_with_all(bus_name_suffix: &str, imp: T) -> Result<Self>

Creates a new Server with the given bus name suffix and implementation, which must implement TrackListInterface and PlaylistsInterface in addition to RootInterface and PlayerInterface.

See also Server::new.

Trait Implementations§

source§

impl<T> Debug for Server<T>where - T: PlayerInterface + Send + Sync + 'static,

source§

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

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<T> !RefUnwindSafe for Server<T>

§

impl<T> Send for Server<T>

§

impl<T> Sync for Server<T>

§

impl<T> Unpin for Server<T>

§

impl<T> !UnwindSafe for Server<T>

Blanket Implementations§

source§

impl<T> Any for Twhere + T: PlayerInterface + 'static,

source§

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

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<T> !RefUnwindSafe for Server<T>

§

impl<T> Send for Server<T>

§

impl<T> Sync for Server<T>

§

impl<T> Unpin for Server<T>

§

impl<T> !UnwindSafe for Server<T>

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

source§

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

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

diff --git a/mpris_server/struct.Time.html b/mpris_server/struct.Time.html new file mode 100644 index 0000000..ce23983 --- /dev/null +++ b/mpris_server/struct.Time.html @@ -0,0 +1,122 @@ +Time in mpris_server - Rust

Struct mpris_server::Time

source ·
pub struct Time(_);
Expand description

A time which can be negative.

+

Implementations§

source§

impl Time

source

pub const ZERO: Self = _

A time of zero.

+
Examples
+
use mpris_server::Time;
+
+let time = Time::ZERO;
+assert!(time.is_zero());
+assert_eq!(time.as_micros(), 0);
+
source

pub const MIN: Self = _

The minimum time.

+
source

pub const MAX: Self = _

The maximum time.

+
source

pub const fn from_secs(secs: i64) -> Self

Creates a new Time from the specified number of whole seconds.

+
source

pub const fn from_millis(millis: i64) -> Self

Creates a new Time from the specified number of whole milliseconds.

+
source

pub const fn from_micros(micros: i64) -> Self

Creates a new Time from the specified number of whole microseconds.

+
source

pub const fn from_nanos(nanos: i64) -> Self

Creates a new Time from the specified number of whole nanoseconds.

+
source

pub const fn as_secs(&self) -> i64

Returns the number of whole seconds contained by this Time.

+
source

pub const fn as_millis(&self) -> i64

Returns the number of whole milliseconds contained by this Time.

+
source

pub const fn as_micros(&self) -> i64

Returns the number of whole microseconds contained by this Time.

+
source

pub const fn as_nanos(&self) -> i64

Returns the number of whole nanoseconds contained by this Time.

+
source

pub const fn is_zero(&self) -> bool

Returns true if this Time is zero.

+
Examples
+
use mpris_server::Time;
+
+assert_eq!(Time::ZERO.is_zero(), true);
+assert_eq!(Time::from_micros(1).is_zero(), false);
+
source

pub const fn is_negative(&self) -> bool

Returns true if this Time is negative.

+
Examples
+
use mpris_server::Time;
+
+assert_eq!(Time::ZERO.is_negative(), false);
+assert_eq!(Time::from_micros(-1).is_negative(), true);
+assert_eq!(Time::from_micros(1).is_negative(), false);
+
source

pub const fn is_positive(&self) -> bool

Returns true if this Time is positive.

+
Examples
+
use mpris_server::Time;
+
+assert_eq!(Time::ZERO.is_positive(), false);
+assert_eq!(Time::from_micros(1).is_positive(), true);
+assert_eq!(Time::from_micros(-1).is_positive(), false);
+
source

pub const fn abs(&self) -> Self

Returns the time as an absolute (non-negative) value.

+
Examples
+
use mpris_server::Time;
+
+assert_eq!(Time::ZERO.abs(), Time::ZERO);
+assert_eq!(Time::from_micros(-1).abs(), Time::from_micros(1));
+assert_eq!(Time::from_micros(1).abs(), Time::from_micros(1));
+
source

pub const fn checked_add(self, other: Self) -> Option<Self>

Checked Time addition. Computes self + other, returning None +if overflow occurred.

+
Examples
+
use mpris_server::Time;
+
+assert_eq!(
+    Time::from_micros(1).checked_add(Time::from_micros(1)),
+    Some(Time::from_micros(2))
+);
+assert_eq!(Time::MAX.checked_add(Time::from_micros(1)), None);
+
source

pub const fn checked_sub(self, other: Self) -> Option<Self>

Checked Time subtraction. Computes self - other, returning None +if overflow occurred.

+
Examples
+
use mpris_server::Time;
+
+assert_eq!(
+    Time::from_micros(2).checked_sub(Time::from_micros(1)),
+    Some(Time::from_micros(1))
+);
+assert_eq!(Time::MIN.checked_sub(Time::from_micros(1)), None);
+
source

pub const fn saturating_add(self, other: Self) -> Self

Saturating Time addition. Computes self + other, returning +Time::MAX if overflow occurred.

+
Examples
+
use mpris_server::Time;
+
+assert_eq!(
+    Time::from_micros(1).saturating_add(Time::from_micros(1)),
+    Time::from_micros(2)
+);
+assert_eq!(Time::MAX.saturating_add(Time::from_micros(1)), Time::MAX);
+
source

pub const fn saturating_sub(self, other: Self) -> Self

Saturating Time subtraction. Computes self - other, returning +Time::MIN if overflow occurred.

+
Examples
+
use mpris_server::Time;
+
+assert_eq!(
+    Time::from_micros(2).saturating_sub(Time::from_micros(1)),
+    Time::from_micros(1)
+);
+assert_eq!(Time::MIN.saturating_sub(Time::from_micros(1)), Time::MIN);
+

Trait Implementations§

source§

impl Add<Time> for Time

§

type Output = Time

The resulting type after applying the + operator.
source§

fn add(self, other: Self) -> Self

Performs the + operation. Read more
source§

impl AddAssign<Time> for Time

source§

fn add_assign(&mut self, rhs: Self)

Performs the += operation. Read more
source§

impl Clone for Time

source§

fn clone(&self) -> Time

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for Time

source§

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

Formats the value using the given formatter. Read more
source§

impl Default for Time

source§

fn default() -> Time

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

impl<'de> Deserialize<'de> for Time

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl<'a> From<Time> for Value<'a>

source§

fn from(time: Time) -> Self

Converts to this type from the input type.
source§

impl Hash for Time

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)where + H: Hasher, + Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl Ord for Time

source§

fn cmp(&self, other: &Time) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · source§

fn max(self, other: Self) -> Selfwhere + Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · source§

fn min(self, other: Self) -> Selfwhere + Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 · source§

fn clamp(self, min: Self, max: Self) -> Selfwhere + Self: Sized + PartialOrd<Self>,

Restrict a value to a certain interval. Read more
source§

impl PartialEq<Time> for Time

source§

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

This method tests for self and other values to be equal, and is used +by ==.
1.0.0 · source§

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

This method tests for !=. The default implementation is almost always +sufficient, and should not be overridden without very good reason.
source§

impl PartialOrd<Time> for Time

source§

fn partial_cmp(&self, other: &Time) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

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

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

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

This method tests less than or equal to (for self and other) and is used by the <= +operator. Read more
1.0.0 · source§

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

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

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

This method tests greater than or equal to (for self and other) and is used by the >= +operator. Read more
source§

impl Serialize for Time

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>where + __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Sub<Time> for Time

§

type Output = Time

The resulting type after applying the - operator.
source§

fn sub(self, other: Self) -> Self

Performs the - operation. Read more
source§

impl SubAssign<Time> for Time

source§

fn sub_assign(&mut self, rhs: Self)

Performs the -= operation. Read more
source§

impl Type for Time

source§

fn signature() -> Signature<'static>

Get the signature for the implementing type. Read more
source§

impl Copy for Time

source§

impl Eq for Time

source§

impl StructuralEq for Time

source§

impl StructuralPartialEq for Time

Auto Trait Implementations§

§

impl RefUnwindSafe for Time

§

impl Send for Time

§

impl Sync for Time

§

impl Unpin for Time

§

impl UnwindSafe for Time

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere + T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere + T: ?Sized,

source§

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

Mutably borrows from an owned value. Read more
§

impl<'de, T> DynamicDeserialize<'de> for Twhere + T: Type + Deserialize<'de> + ?Sized,

§

type Deserializer = PhantomData<T>

A DeserializeSeed implementation for this type.
§

fn deserializer_for_signature<S>( + signature: S +) -> Result<<T as DynamicDeserialize<'de>>::Deserializer, Error>where + S: TryInto<Signature<'de>>, + <S as TryInto<Signature<'de>>>::Error: Into<Error>,

Get a deserializer compatible with this signature.
§

impl<T> DynamicType for Twhere + T: Type + ?Sized,

§

fn dynamic_signature(&self) -> Signature<'_>

Get the signature for the implementing type. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

+
source§

impl<T> Instrument for T

source§

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

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

fn in_current_span(self) -> Instrumented<Self>

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

impl<T, U> Into<U> for Twhere + U: From<T>,

source§

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> NoneValue for Twhere + T: Default,

§

type NoneType = T

§

fn null_value() -> T

The none-equivalent value.
source§

impl<T> Same<T> for T

§

type Output = T

Should always be Self
source§

impl<T> ToOwned for Twhere + T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

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

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

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

impl<T, U> TryFrom<U> for Twhere + U: Into<T>,

§

type Error = Infallible

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

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

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere + U: TryFrom<T>,

§

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

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

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

Performs the conversion.
§

impl<V, T> VZip<V> for Twhere + V: MultiLane<T>,

§

fn vzip(self) -> V

source§

impl<T> WithSubscriber for T

source§

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
source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a +WithDispatch wrapper. Read more
source§

impl<T> DeserializeOwned for Twhere + T: for<'de> Deserialize<'de>,

\ No newline at end of file diff --git a/mpris_server/struct.TrackId.html b/mpris_server/struct.TrackId.html index 039e1ca..7681505 100644 --- a/mpris_server/struct.TrackId.html +++ b/mpris_server/struct.TrackId.html @@ -1,4 +1,4 @@ -TrackId in mpris_server - Rust

Struct mpris_server::TrackId

source ·
pub struct TrackId(_);
Expand description

Unique track identifier.

+TrackId in mpris_server - Rust

Struct mpris_server::TrackId

source ·
pub struct TrackId(_);
Expand description

Unique track identifier.

If the media player implements the TrackList interface and allows the same track to appear multiple times in the tracklist, this must be unique within the scope of the tracklist.

@@ -14,8 +14,8 @@

Rationale

identifiers on D-Bus. It also allows for future optional expansions to the specification where tracks are exported to D-Bus with an interface similar to org.gnome.UPnP.MediaItem2.

-

Implementations§

source§

impl TrackId

source

pub const NO_TRACK: &'static str = "/org/mpris/MediaPlayer2/TrackList/NoTrack"

A special track ID to indicate “no track”.

-
source

pub fn into_inner(self) -> ObjectPath<'static>

Returns the track ID as an [ObjectPath].

+

Implementations§

source§

impl TrackId

source

pub const NO_TRACK: &'static str = "/org/mpris/MediaPlayer2/TrackList/NoTrack"

A special track ID to indicate “no track”.

+
source

pub fn into_inner(self) -> ObjectPath<'static>

Returns the track ID as an [ObjectPath].

Methods from Deref<Target = ObjectPath<'static>>§

pub fn as_ref(&self) -> ObjectPath<'_>

A borrowed clone (this never allocates, unlike clone).

pub fn as_str(&self) -> &str

The object path as a string.

pub fn as_bytes(&self) -> &[u8]

The object path as bytes.

@@ -1189,13 +1189,13 @@
Examples
let s = "Grüße, Jürgen ❤";
 
 assert_eq!("grüße, jürgen ❤", s.to_ascii_lowercase());
-

Trait Implementations§

source§

impl Clone for TrackId

source§

fn clone(&self) -> TrackId

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for TrackId

source§

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

Formats the value using the given formatter. Read more
source§

impl Default for TrackId

source§

fn default() -> TrackId

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

impl Deref for TrackId

§

type Target = ObjectPath<'static>

The resulting type after dereferencing.
source§

fn deref(&self) -> &Self::Target

Dereferences the value.
source§

impl<'de> Deserialize<'de> for TrackId

source§

fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where - D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for TrackId

source§

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

Formats the value using the given formatter. Read more
source§

impl<'unowned, 'owned: 'unowned> From<&'owned TrackId> for ObjectPath<'unowned>

source§

fn from(o: &'owned TrackId) -> Self

Converts to this type from the input type.
source§

impl<'a> From<ObjectPath<'a>> for TrackId

source§

fn from(o: ObjectPath<'a>) -> Self

Converts to this type from the input type.
source§

impl From<TrackId> for ObjectPath<'static>

source§

fn from(o: TrackId) -> Self

Converts to this type from the input type.
source§

impl From<TrackId> for Value<'static>

source§

fn from(o: TrackId) -> Self

Converts to this type from the input type.
source§

impl Hash for TrackId

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)where +

Trait Implementations§

source§

impl Clone for TrackId

source§

fn clone(&self) -> TrackId

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for TrackId

source§

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

Formats the value using the given formatter. Read more
source§

impl Default for TrackId

source§

fn default() -> TrackId

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

impl Deref for TrackId

§

type Target = ObjectPath<'static>

The resulting type after dereferencing.
source§

fn deref(&self) -> &Self::Target

Dereferences the value.
source§

impl<'de> Deserialize<'de> for TrackId

source§

fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where + D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for TrackId

source§

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

Formats the value using the given formatter. Read more
source§

impl<'unowned, 'owned: 'unowned> From<&'owned TrackId> for ObjectPath<'unowned>

source§

fn from(o: &'owned TrackId) -> Self

Converts to this type from the input type.
source§

impl<'a> From<ObjectPath<'a>> for TrackId

source§

fn from(o: ObjectPath<'a>) -> Self

Converts to this type from the input type.
source§

impl From<TrackId> for ObjectPath<'static>

source§

fn from(o: TrackId) -> Self

Converts to this type from the input type.
source§

impl From<TrackId> for Value<'static>

source§

fn from(o: TrackId) -> Self

Converts to this type from the input type.
source§

impl Hash for TrackId

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl PartialEq<TrackId> for TrackId

source§

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

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

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

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

impl Serialize for TrackId

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>where - __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl TryFrom<&str> for TrackId

§

type Error = Error

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

fn try_from(value: &str) -> Result<Self>

Performs the conversion.
source§

impl TryFrom<String> for TrackId

§

type Error = Error

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

fn try_from(value: String) -> Result<Self>

Performs the conversion.
source§

impl Type for TrackId

source§

fn signature() -> Signature<'static>

Get the signature for the implementing type. Read more
source§

impl Eq for TrackId

source§

impl StructuralEq for TrackId

source§

impl StructuralPartialEq for TrackId

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere + __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl TryFrom<&str> for TrackId

§

type Error = Error

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

fn try_from(value: &str) -> Result<Self>

Performs the conversion.
source§

impl TryFrom<String> for TrackId

§

type Error = Error

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

fn try_from(value: String) -> Result<Self>

Performs the conversion.
source§

impl Type for TrackId

source§

fn signature() -> Signature<'static>

Get the signature for the implementing type. Read more
source§

impl Eq for TrackId

source§

impl StructuralEq for TrackId

source§

impl StructuralPartialEq for TrackId

Auto Trait Implementations§

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

source§

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

Mutably borrows from an owned value. Read more
§

impl<'de, T> DynamicDeserialize<'de> for Twhere diff --git a/mpris_server/time/struct.Time.html b/mpris_server/time/struct.Time.html new file mode 100644 index 0000000..c95ad72 --- /dev/null +++ b/mpris_server/time/struct.Time.html @@ -0,0 +1,11 @@ + + + + + Redirection + + +

Redirecting to ../../mpris_server/struct.Time.html...

+ + + \ No newline at end of file diff --git a/mpris_server/trait.LocalPlayerInterface.html b/mpris_server/trait.LocalPlayerInterface.html index d25db27..575f4a1 100644 --- a/mpris_server/trait.LocalPlayerInterface.html +++ b/mpris_server/trait.LocalPlayerInterface.html @@ -1,4 +1,4 @@ -LocalPlayerInterface in mpris_server - Rust
pub trait LocalPlayerInterface: LocalRootInterface {
+LocalPlayerInterface in mpris_server - Rust
pub trait LocalPlayerInterface: LocalRootInterface {
 
Show 28 methods // Required methods fn next<'life0, 'async_trait>( &'life0 self @@ -32,14 +32,14 @@ 'life0: 'async_trait; fn seek<'life0, 'async_trait>( &'life0 self, - offset: TimeInUs + offset: Time ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn set_position<'life0, 'async_trait>( &'life0 self, track_id: TrackId, - position: TimeInUs + position: Time ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; @@ -105,7 +105,7 @@ 'life0: 'async_trait; fn position<'life0, 'async_trait>( &'life0 self - ) -> Pin<Box<dyn Future<Output = Result<TimeInUs>> + 'async_trait>> + ) -> Pin<Box<dyn Future<Output = Result<Time>> + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn minimum_rate<'life0, 'async_trait>( @@ -149,123 +149,123 @@ where Self: 'async_trait, 'life0: 'async_trait;
}
Expand description

Used to implement org.mpris.MediaPlayer2.Player interface.

-

Required Methods§

source

fn next<'life0, 'async_trait>( +

Required Methods§

source

fn next<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn previous<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn previous<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn pause<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn pause<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn play_pause<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn play_pause<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn stop<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn stop<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn play<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn play<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn seek<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn seek<'life0, 'async_trait>( &'life0 self, - offset: TimeInUs + offset: Time ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn set_position<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn set_position<'life0, 'async_trait>( &'life0 self, track_id: TrackId, - position: TimeInUs + position: Time ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn open_uri<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn open_uri<'life0, 'async_trait>( &'life0 self, uri: String ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn playback_status<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn playback_status<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<PlaybackStatus>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn loop_status<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn loop_status<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<LoopStatus>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn set_loop_status<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn set_loop_status<'life0, 'async_trait>( &'life0 self, loop_status: LoopStatus ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn rate<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn rate<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<PlaybackRate>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn set_rate<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn set_rate<'life0, 'async_trait>( &'life0 self, rate: PlaybackRate ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn shuffle<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn shuffle<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn set_shuffle<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn set_shuffle<'life0, 'async_trait>( &'life0 self, shuffle: bool ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn metadata<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn metadata<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<Metadata>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn volume<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn volume<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<Volume>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn set_volume<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn set_volume<'life0, 'async_trait>( &'life0 self, volume: Volume ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn position<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn position<'life0, 'async_trait>( &'life0 self -) -> Pin<Box<dyn Future<Output = Result<TimeInUs>> + 'async_trait>>where +) -> Pin<Box<dyn Future<Output = Result<Time>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn minimum_rate<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn minimum_rate<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<PlaybackRate>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn maximum_rate<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn maximum_rate<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<PlaybackRate>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn can_go_next<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn can_go_next<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn can_go_previous<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn can_go_previous<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn can_play<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn can_play<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn can_pause<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn can_pause<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn can_seek<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn can_seek<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn can_control<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn can_control<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + 'async_trait>>where Self: 'async_trait, diff --git a/mpris_server/trait.LocalPlaylistsInterface.html b/mpris_server/trait.LocalPlaylistsInterface.html index 1aa900c..b4e0bbb 100644 --- a/mpris_server/trait.LocalPlaylistsInterface.html +++ b/mpris_server/trait.LocalPlaylistsInterface.html @@ -1,4 +1,4 @@ -LocalPlaylistsInterface in mpris_server - Rust
pub trait LocalPlaylistsInterface: LocalPlayerInterface {
+LocalPlaylistsInterface in mpris_server - Rust
pub trait LocalPlaylistsInterface: LocalPlayerInterface {
     // Required methods
     fn activate_playlist<'life0, 'async_trait>(
         &'life0 self,
@@ -31,12 +31,12 @@
        where Self: 'async_trait,
              'life0: 'async_trait;
 }
Expand description

Used to implement org.mpris.MediaPlayer2.Playlists interface.

-

Required Methods§

source

fn activate_playlist<'life0, 'async_trait>( +

Required Methods§

source

fn activate_playlist<'life0, 'async_trait>( &'life0 self, playlist_id: PlaylistId ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn get_playlists<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn get_playlists<'life0, 'async_trait>( &'life0 self, index: u32, max_count: u32, @@ -44,15 +44,15 @@ reverse_order: bool ) -> Pin<Box<dyn Future<Output = Result<Vec<Playlist>>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn playlist_count<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn playlist_count<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<u32>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn orderings<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn orderings<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<Vec<PlaylistOrdering>>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn active_playlist<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn active_playlist<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<MaybePlaylist>> + 'async_trait>>where Self: 'async_trait, diff --git a/mpris_server/trait.LocalRootInterface.html b/mpris_server/trait.LocalRootInterface.html index 81152e8..cd8b4ef 100644 --- a/mpris_server/trait.LocalRootInterface.html +++ b/mpris_server/trait.LocalRootInterface.html @@ -1,4 +1,4 @@ -LocalRootInterface in mpris_server - Rust
pub trait LocalRootInterface {
+LocalRootInterface in mpris_server - Rust
pub trait LocalRootInterface {
     // Required methods
     fn raise<'life0, 'async_trait>(
         &'life0 self
@@ -62,7 +62,7 @@
        where Self: 'async_trait,
              'life0: 'async_trait;
 }
Expand description

Used to implement org.mpris.MediaPlayer2 interface.

-

Required Methods§

source

fn raise<'life0, 'async_trait>( +

Required Methods§

source

fn raise<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, @@ -72,7 +72,7 @@ interface is displayed, or it may not have a graphical user interface at all. In this case, the CanRaise property is false and this method does nothing.

-

source

fn quit<'life0, 'async_trait>( +

source

fn quit<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, @@ -87,7 +87,7 @@ Otherwise, it should not be needed.

If the media player does not have a UI, this should be implemented.

-

source

fn can_quit<'life0, 'async_trait>( +

source

fn can_quit<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + 'async_trait>>where Self: 'async_trait, @@ -95,7 +95,7 @@ NotSupported error. If true, calling Quit will cause the media application to attempt to quit (although it may still be prevented from quitting by the user, for example).

-

source

fn fullscreen<'life0, 'async_trait>( +

source

fn fullscreen<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + 'async_trait>>where Self: 'async_trait, @@ -112,36 +112,36 @@ be unable to fulfil the request, in which case attempting to set this property will have no effect (but should not raise an error).

-

source

fn set_fullscreen<'life0, 'async_trait>( +
source

fn set_fullscreen<'life0, 'async_trait>( &'life0 self, fullscreen: bool ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn can_set_fullscreen<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn can_set_fullscreen<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn can_raise<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn can_raise<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn has_track_list<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn has_track_list<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn identity<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn identity<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<String>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn desktop_entry<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn desktop_entry<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<String>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn supported_uri_schemes<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn supported_uri_schemes<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<Vec<String>>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn supported_mime_types<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn supported_mime_types<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<Vec<String>>> + 'async_trait>>where Self: 'async_trait, diff --git a/mpris_server/trait.LocalTrackListInterface.html b/mpris_server/trait.LocalTrackListInterface.html index ea56e6c..a3affcf 100644 --- a/mpris_server/trait.LocalTrackListInterface.html +++ b/mpris_server/trait.LocalTrackListInterface.html @@ -1,4 +1,4 @@ -LocalTrackListInterface in mpris_server - Rust
pub trait LocalTrackListInterface: LocalPlayerInterface {
+LocalTrackListInterface in mpris_server - Rust
pub trait LocalTrackListInterface: LocalPlayerInterface {
     // Required methods
     fn get_tracks_metadata<'life0, 'async_trait>(
         &'life0 self,
@@ -37,33 +37,33 @@
        where Self: 'async_trait,
              'life0: 'async_trait;
 }
Expand description

Used to implement org.mpris.MediaPlayer2.TrackList interface.

-

Required Methods§

source

fn get_tracks_metadata<'life0, 'async_trait>( +

Required Methods§

source

fn get_tracks_metadata<'life0, 'async_trait>( &'life0 self, track_ids: Vec<TrackId> ) -> Pin<Box<dyn Future<Output = Result<Vec<Metadata>>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn add_track<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn add_track<'life0, 'async_trait>( &'life0 self, uri: Uri, after_track: TrackId, set_as_current: bool ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn remove_track<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn remove_track<'life0, 'async_trait>( &'life0 self, track_id: TrackId ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn go_to<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn go_to<'life0, 'async_trait>( &'life0 self, track_id: TrackId ) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn tracks<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn tracks<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<Vec<TrackId>>> + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn can_edit_tracks<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn can_edit_tracks<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + 'async_trait>>where Self: 'async_trait, diff --git a/mpris_server/trait.PlayerInterface.html b/mpris_server/trait.PlayerInterface.html index 4a71824..ea028b2 100644 --- a/mpris_server/trait.PlayerInterface.html +++ b/mpris_server/trait.PlayerInterface.html @@ -1,4 +1,4 @@ -PlayerInterface in mpris_server - Rust
pub trait PlayerInterface: RootInterface {
+PlayerInterface in mpris_server - Rust
pub trait PlayerInterface: RootInterface {
 
Show 28 methods // Required methods fn next<'life0, 'async_trait>( &'life0 self @@ -32,14 +32,14 @@ 'life0: 'async_trait; fn seek<'life0, 'async_trait>( &'life0 self, - offset: TimeInUs + offset: Time ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn set_position<'life0, 'async_trait>( &'life0 self, track_id: TrackId, - position: TimeInUs + position: Time ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; @@ -105,7 +105,7 @@ 'life0: 'async_trait; fn position<'life0, 'async_trait>( &'life0 self - ) -> Pin<Box<dyn Future<Output = Result<TimeInUs>> + Send + 'async_trait>> + ) -> Pin<Box<dyn Future<Output = Result<Time>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn minimum_rate<'life0, 'async_trait>( @@ -148,123 +148,123 @@ ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; -
}

Required Methods§

source

fn next<'life0, 'async_trait>( +}

Required Methods§

source

fn next<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn previous<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn previous<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn pause<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn pause<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn play_pause<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn play_pause<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn stop<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn stop<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn play<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn play<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn seek<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn seek<'life0, 'async_trait>( &'life0 self, - offset: TimeInUs + offset: Time ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn set_position<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn set_position<'life0, 'async_trait>( &'life0 self, track_id: TrackId, - position: TimeInUs + position: Time ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn open_uri<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn open_uri<'life0, 'async_trait>( &'life0 self, uri: String ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn playback_status<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn playback_status<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<PlaybackStatus>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn loop_status<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn loop_status<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<LoopStatus>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn set_loop_status<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn set_loop_status<'life0, 'async_trait>( &'life0 self, loop_status: LoopStatus ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn rate<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn rate<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<PlaybackRate>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn set_rate<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn set_rate<'life0, 'async_trait>( &'life0 self, rate: PlaybackRate ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn shuffle<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn shuffle<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn set_shuffle<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn set_shuffle<'life0, 'async_trait>( &'life0 self, shuffle: bool ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn metadata<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn metadata<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<Metadata>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn volume<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn volume<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<Volume>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn set_volume<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn set_volume<'life0, 'async_trait>( &'life0 self, volume: Volume ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn position<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn position<'life0, 'async_trait>( &'life0 self -) -> Pin<Box<dyn Future<Output = Result<TimeInUs>> + Send + 'async_trait>>where +) -> Pin<Box<dyn Future<Output = Result<Time>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn minimum_rate<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn minimum_rate<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<PlaybackRate>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn maximum_rate<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn maximum_rate<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<PlaybackRate>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn can_go_next<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn can_go_next<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn can_go_previous<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn can_go_previous<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn can_play<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn can_play<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn can_pause<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn can_pause<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn can_seek<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn can_seek<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn can_control<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn can_control<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where Self: 'async_trait, diff --git a/mpris_server/trait.PlaylistsInterface.html b/mpris_server/trait.PlaylistsInterface.html index 07b71c3..56d6d8d 100644 --- a/mpris_server/trait.PlaylistsInterface.html +++ b/mpris_server/trait.PlaylistsInterface.html @@ -1,4 +1,4 @@ -PlaylistsInterface in mpris_server - Rust
pub trait PlaylistsInterface: PlayerInterface {
+PlaylistsInterface in mpris_server - Rust
pub trait PlaylistsInterface: PlayerInterface {
     // Required methods
     fn activate_playlist<'life0, 'async_trait>(
         &'life0 self,
@@ -35,7 +35,7 @@
 

Since D-Bus does not provide an easy way to check for what interfaces are exported on an object, clients should attempt to get one of the properties on this interface to see if it is implemented.

-

Required Methods§

source

fn activate_playlist<'life0, 'async_trait>( +

Required Methods§

source

fn activate_playlist<'life0, 'async_trait>( &'life0 self, playlist_id: PlaylistId ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where @@ -53,7 +53,7 @@
Parameters
and the first track starts. For example, if the media player is operating in a “jukebox” mode, it may just append the playlist to the list of upcoming tracks, and skip to the first track in the playlist.

-

source

fn get_playlists<'life0, 'async_trait>( +

source

fn get_playlists<'life0, 'async_trait>( &'life0 self, index: u32, max_count: u32, @@ -79,17 +79,17 @@

Rationale
orderings. For example, creation times are not available on UNIX filesystems (don’t let the ctime fool you!). On the other hand, clients should have some way to get the “most recent” playlists.

-

source

fn playlist_count<'life0, 'async_trait>( +

source

fn playlist_count<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<u32>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait,

The number of playlists available.

-
source

fn orderings<'life0, 'async_trait>( +

source

fn orderings<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<Vec<PlaylistOrdering>>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait,

The available orderings. At least one must be offered.

-
source

fn active_playlist<'life0, 'async_trait>( +

source

fn active_playlist<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<MaybePlaylist>> + Send + 'async_trait>>where Self: 'async_trait, @@ -97,7 +97,7 @@
Rationale

If there is no currently-active playlist, the structure’s Valid field will be false, and the Playlist details are undefined.

Note that this may not have a value even after ActivatePlaylist is -called with a valid playlist id as ActivatePlaylist implementations have -the option of simply inserting the contents of the playlist into the -current tracklist.

+called with a valid playlist id as ActivatePlaylist implementations +have the option of simply inserting the contents of the playlist +into the current tracklist.

Implementors§

\ No newline at end of file diff --git a/mpris_server/trait.RootInterface.html b/mpris_server/trait.RootInterface.html index 2b5f8f0..984cc79 100644 --- a/mpris_server/trait.RootInterface.html +++ b/mpris_server/trait.RootInterface.html @@ -1,4 +1,4 @@ -RootInterface in mpris_server - Rust
pub trait RootInterface {
+RootInterface in mpris_server - Rust
pub trait RootInterface: Send + Sync {
     // Required methods
     fn raise<'life0, 'async_trait>(
         &'life0 self
@@ -62,7 +62,7 @@
        where Self: 'async_trait,
              'life0: 'async_trait;
 }
Expand description

Used to implement org.mpris.MediaPlayer2 interface.

-

Required Methods§

source

fn raise<'life0, 'async_trait>( +

Required Methods§

source

fn raise<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, @@ -71,7 +71,7 @@

The media player may be unable to control how its user interface is displayed, or it may not have a graphical user interface at all. In this case, the CanRaise property is false and this method does nothing.

-

source

fn quit<'life0, 'async_trait>( +

source

fn quit<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, @@ -83,44 +83,44 @@ interface or a notification area icon for example) should allow clients to use this method. Otherwise, it should not be needed.

If the media player does not have a UI, this should be implemented.

-

source

fn can_quit<'life0, 'async_trait>( +
source

fn can_quit<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn fullscreen<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn fullscreen<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn set_fullscreen<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn set_fullscreen<'life0, 'async_trait>( &'life0 self, fullscreen: bool ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn can_set_fullscreen<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn can_set_fullscreen<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn can_raise<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn can_raise<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn has_track_list<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn has_track_list<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn identity<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn identity<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn desktop_entry<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn desktop_entry<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn supported_uri_schemes<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn supported_uri_schemes<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<Vec<String>>> + Send + 'async_trait>>where Self: 'async_trait, - 'life0: 'async_trait,

source

fn supported_mime_types<'life0, 'async_trait>( + 'life0: 'async_trait,

source

fn supported_mime_types<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<Vec<String>>> + Send + 'async_trait>>where Self: 'async_trait, diff --git a/mpris_server/trait.TrackListInterface.html b/mpris_server/trait.TrackListInterface.html index af5b8f0..5216e3f 100644 --- a/mpris_server/trait.TrackListInterface.html +++ b/mpris_server/trait.TrackListInterface.html @@ -1,4 +1,4 @@ -TrackListInterface in mpris_server - Rust
pub trait TrackListInterface: PlayerInterface {
+TrackListInterface in mpris_server - Rust
pub trait TrackListInterface: PlayerInterface {
     // Required methods
     fn get_tracks_metadata<'life0, 'async_trait>(
         &'life0 self,
@@ -60,7 +60,7 @@
 recommended practice as the tracklist interface is not designed to enable
 browsing through a large list of tracks, but rather to provide clients with
 context about the currently playing track.

-

Required Methods§

source

fn get_tracks_metadata<'life0, 'async_trait>( +

Required Methods§

source

fn get_tracks_metadata<'life0, 'async_trait>( &'life0 self, track_ids: Vec<TrackId> ) -> Pin<Box<dyn Future<Output = Result<Vec<Metadata>>> + Send + 'async_trait>>where @@ -77,7 +77,7 @@
Returns

Each set of metadata must have a mpris:trackid entry at the very least, which contains a string that uniquely identifies this track within the scope of the tracklist.

-

source

fn add_track<'life0, 'async_trait>( +

source

fn add_track<'life0, 'async_trait>( &'life0 self, uri: Uri, after_track: TrackId, @@ -103,7 +103,7 @@

Parameters

Note: Clients should not assume that the track has been added at the time when this method returns. They should wait for a TrackAdded (or TrackListReplaced) signal.

-
source

fn remove_track<'life0, 'async_trait>( +

source

fn remove_track<'life0, 'async_trait>( &'life0 self, track_id: TrackId ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where @@ -118,9 +118,9 @@
Parameters

If the track is not part of this tracklist, this has no effect.

If the CanEditTracks property is false, this has no effect.

Note: Clients should not assume that the track has been removed at the -time when this method returns. They should wait for a TrackRemoved (or -TrackListReplaced) signal.

-

source

fn go_to<'life0, 'async_trait>( +time when this method returns. They should wait for a TrackRemoved +(or TrackListReplaced) signal.

+

source

fn go_to<'life0, 'async_trait>( &'life0 self, track_id: TrackId ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where @@ -137,18 +137,19 @@
Parameters
tracks should be replaced with the contents of this TrackList, and the TrackListReplaced signal should be fired from /org/mpris/MediaPlayer2.

-

source

fn tracks<'life0, 'async_trait>( +

source

fn tracks<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<Vec<TrackId>>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait,

An array which contains the identifier of each track in the tracklist, in order.

-

The org.freedesktop.DBus.Properties.PropertiesChanged signal is emitted -every time this property changes, but the signal message does not -contain the new value. Client implementations should rather rely on the -TrackAdded, TrackRemoved and TrackListReplaced signals to -keep their representation of the tracklist up to date.

-
source

fn can_edit_tracks<'life0, 'async_trait>( +

The org.freedesktop.DBus.Properties.PropertiesChanged signal is +emitted every time this property changes, but the signal message +does not contain the new value. Client implementations should rather +rely on the TrackAdded, TrackRemoved and +TrackListReplaced signals to keep their representation of the +tracklist up to date.

+

source

fn can_edit_tracks<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where Self: 'async_trait, diff --git a/mpris_server/type.DateTime.html b/mpris_server/type.DateTime.html index 63524c3..082d959 100644 --- a/mpris_server/type.DateTime.html +++ b/mpris_server/type.DateTime.html @@ -1,4 +1,5 @@ -DateTime in mpris_server - Rust

Type Definition mpris_server::DateTime

source ·
pub type DateTime = String;
Expand description

Date/time fields should be sent as strings in ISO 8601 extended +DateTime in mpris_server - Rust

Type Definition mpris_server::DateTime

source ·
pub type DateTime = String;
Expand description

Combined date and time.

+

This should be sent as strings in ISO 8601 extended format (eg: 2007-04-29T14:35:51). If the timezone is known (eg: for xesam:lastPlayed), the internet profile format of ISO 8601, as specified in RFC 3339, should be used (eg: 2007-04-29T14:35:51+02:00).

diff --git a/mpris_server/type.PlaybackRate.html b/mpris_server/type.PlaybackRate.html index 376faa5..f4658e0 100644 --- a/mpris_server/type.PlaybackRate.html +++ b/mpris_server/type.PlaybackRate.html @@ -1,4 +1,4 @@ -PlaybackRate in mpris_server - Rust

Type Definition mpris_server::PlaybackRate

source ·
pub type PlaybackRate = f64;
Expand description

A playback rate.

+PlaybackRate in mpris_server - Rust

Type Definition mpris_server::PlaybackRate

source ·
pub type PlaybackRate = f64;
Expand description

A playback rate.

This is a multiplier, so a value of 0.5 indicates that playback is happening at half speed, while 1.5 means that 1.5 seconds of “track time” is consumed every second.

diff --git a/mpris_server/type.PlaylistId.html b/mpris_server/type.PlaylistId.html index de0a67f..44b1244 100644 --- a/mpris_server/type.PlaylistId.html +++ b/mpris_server/type.PlaylistId.html @@ -1,4 +1,4 @@ -PlaylistId in mpris_server - Rust

Type Definition mpris_server::PlaylistId

source ·
pub type PlaylistId = OwnedObjectPath;
Expand description

Unique playlist identifier.

+PlaylistId in mpris_server - Rust

Type Definition mpris_server::PlaylistId

source ·
pub type PlaylistId = OwnedObjectPath;
Expand description

Unique playlist identifier.

Rationale

Multiple playlists may have the same name.

This is a D-Bus object id as that is the definitive way to have unique diff --git a/mpris_server/type.TimeInUs.html b/mpris_server/type.TimeInUs.html deleted file mode 100644 index abf7d30..0000000 --- a/mpris_server/type.TimeInUs.html +++ /dev/null @@ -1,2 +0,0 @@ -TimeInUs in mpris_server - Rust

Type Definition mpris_server::TimeInUs

source ·
pub type TimeInUs = i64;
Expand description

Time in microseconds.

-
\ No newline at end of file diff --git a/mpris_server/type.Uri.html b/mpris_server/type.Uri.html index ed5ad51..470bf7f 100644 --- a/mpris_server/type.Uri.html +++ b/mpris_server/type.Uri.html @@ -1,4 +1,4 @@ -Uri in mpris_server - Rust

Type Definition mpris_server::Uri

source ·
pub type Uri = String;
Expand description

A unique resource identifier.

+Uri in mpris_server - Rust

Type Definition mpris_server::Uri

source ·
pub type Uri = String;
Expand description

A unique resource identifier.

URIs should be sent as (UTF-8) strings. Local files should use the “file://” schema.

\ No newline at end of file diff --git a/mpris_server/type.Volume.html b/mpris_server/type.Volume.html index 880a3bb..0fd8576 100644 --- a/mpris_server/type.Volume.html +++ b/mpris_server/type.Volume.html @@ -1,4 +1,4 @@ -Volume in mpris_server - Rust

Type Definition mpris_server::Volume

source ·
pub type Volume = f64;
Expand description

Audio volume level.

+Volume in mpris_server - Rust

Type Definition mpris_server::Volume

source ·
pub type Volume = f64;
Expand description

Audio volume level.

  • 0.0 means mute.
  • 1.0 is a sensible maximum volume level (ex: 0dB).
  • diff --git a/search-index.js b/search-index.js index d7e90b2..7cb794a 100644 --- a/search-index.js +++ b/search-index.js @@ -1,5 +1,5 @@ var searchIndex = JSON.parse('{\ -"mpris_server":{"doc":"Warning The API is still unstable. Expect breaking changes.","t":"NNNNNNNNNNNNNGNNNNNIIIDIENNDDNNNSNNNGENDINDNNGEIENENIDNNNNGNDIENGNGNKKKKKKLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLALLKKLKKKKLKKLKKLKKLKKLKKLKKLKKLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLKKLLLLLLLLLLLLLLLLLLLLLLLLLLLLALLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLKKLLKKKKLKKKKLLMMKKLLLLLLLLLLLLLLLLLLLKKLKKLKKLKKLMLLLLLLLLLKKLLLLLLKKKKKKKKKKKKLLLKKLLKKLKKLLKKKKKKLKKLLKKLLLLLLLLLLLLLLLLLLLLLLLLLLLKKLLLLLLKKLLLLLLLKKLKKLKKLLLLLLLLLKKLKKLLLLLLLLLKKKKLKKLLLLLLLLLLLLLLLLLLLLLLLLLKKLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLKKLLLLLLLLLLLLLLDDLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLCC","n":["ActivePlaylist","Alphabetical","CanControl","CanEditTracks","CanGoNext","CanGoPrevious","CanPause","CanPlay","CanQuit","CanRaise","CanSeek","CanSetFullscreen","CreationDate","DateTime","DesktopEntry","Fullscreen","HasTrackList","Identity","LastPlayDate","LocalPlayerInterface","LocalPlaylistsInterface","LocalRootInterface","LocalServer","LocalTrackListInterface","LoopStatus","LoopStatus","MaximumRate","MaybePlaylist","Metadata","Metadata","MinimumRate","ModifiedDate","NO_TRACK","None","Orderings","Paused","PlaybackRate","PlaybackStatus","PlaybackStatus","Player","PlayerInterface","Playing","Playlist","Playlist","PlaylistCount","PlaylistId","PlaylistOrdering","PlaylistsInterface","PlaylistsProperty","Position","Property","Rate","RootInterface","Server","Shuffle","Stopped","SupportedMimeTypes","SupportedUriSchemes","TimeInUs","Track","TrackId","TrackListInterface","TrackListProperty","Tracks","Uri","UserDefined","Volume","Volume","activate_playlist","activate_playlist","active_playlist","active_playlist","add_track","add_track","as_str","as_str","as_str","bitand","bitand","bitand","bitor","bitor","bitor","bits","bits","bits","bitxor","bitxor","bitxor","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","builder","builder","builder","can_control","can_control","can_control","can_edit_tracks","can_edit_tracks","can_go_next","can_go_next","can_go_next","can_go_previous","can_go_previous","can_go_previous","can_pause","can_pause","can_pause","can_play","can_play","can_play","can_quit","can_quit","can_quit","can_raise","can_raise","can_raise","can_seek","can_seek","can_seek","can_set_fullscreen","can_set_fullscreen","can_set_fullscreen","clone","clone","clone","clone","clone","clone","clone","clone","clone","clone","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","connect_next","connect_open_uri","connect_pause","connect_play","connect_play_pause","connect_previous","connect_quit","connect_raise","connect_seek","connect_set_fullscreen","connect_set_loop_status","connect_set_position","connect_set_rate","connect_set_shuffle","connect_set_volume","connect_stop","default","default","deref","deserialize","deserialize","deserializer_for_signature","deserializer_for_signature","desktop_entry","desktop_entry","desktop_entry","dynamic_signature","dynamic_signature","dynamic_signature","dynamic_signature","dynamic_signature","dynamic_signature","dynamic_signature","emit_seeked","eq","eq","eq","eq","eq","eq","eq","eq","eq","eq","equivalent","equivalent","equivalent","equivalent","equivalent","equivalent","equivalent","equivalent","equivalent","export","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","from","from","from","from","from","from","from","from","from","from","from","from","from","from","from","from","fullscreen","fullscreen","fullscreen","get","get_playlists","get_playlists","get_tracks_metadata","get_tracks_metadata","get_value","go_to","go_to","has_track_list","has_track_list","has_track_list","hash","icon","id","identity","identity","identity","imp","imp","init","insert","into","into","into","into","into","into","into","into","into","into","into","into","into","into_inner","loop_status","loop_status","loop_status","maximum_rate","maximum_rate","maximum_rate","metadata","metadata","metadata","minimum_rate","minimum_rate","minimum_rate","name","new","new","new","new_with_all","new_with_all","new_with_playlists","new_with_playlists","new_with_track_list","new_with_track_list","next","next","none","not","not","not","null_value","null_value","open_uri","open_uri","orderings","orderings","pause","pause","play","play","play_pause","play_pause","playback_status","playback_status","playback_status","playlist_changed","playlist_changed","playlist_count","playlist_count","playlists_properties_changed","playlists_properties_changed","position","position","position","previous","previous","properties_changed","properties_changed","quit","quit","raise","raise","rate","rate","rate","remove_track","remove_track","run","run","seek","seek","seeked","seeked","serialize","serialize","serialize","serialize","set_album","set_album_artist","set_art_url","set_artist","set_audio_bpm","set_auto_rating","set_can_control","set_can_go_next","set_can_go_previous","set_can_pause","set_can_play","set_can_quit","set_can_raise","set_can_seek","set_can_set_fullscreen","set_comment","set_composer","set_content_created","set_desktop_entry","set_disc_number","set_first_used","set_fullscreen","set_fullscreen","set_fullscreen","set_genre","set_has_track_list","set_identity","set_last_used","set_length","set_loop_status","set_loop_status","set_loop_status","set_lyricist","set_lyrics","set_maximum_rate","set_metadata","set_minimum_rate","set_playback_status","set_position","set_position","set_position","set_rate","set_rate","set_rate","set_shuffle","set_shuffle","set_shuffle","set_supported_mime_types","set_supported_uri_schemes","set_title","set_track_number","set_trackid","set_url","set_use_count","set_user_rating","set_volume","set_volume","set_volume","shuffle","shuffle","shuffle","signature","signature","signature","signature","signature","signature","signature","some","stop","stop","supported_mime_types","supported_mime_types","supported_mime_types","supported_uri_schemes","supported_uri_schemes","supported_uri_schemes","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_string","to_string","to_string","to_string","track_added","track_added","track_list_properties_changed","track_list_properties_changed","track_list_replaced","track_list_replaced","track_metadata_changed","track_metadata_changed","track_removed","track_removed","tracks","tracks","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","volume","volume","volume","vzip","vzip","vzip","vzip","vzip","vzip","vzip","vzip","vzip","vzip","vzip","vzip","vzip","MetadataBuilder","PlayerBuilder","album","album_artist","art_url","artist","audio_bpm","auto_rating","borrow","borrow","borrow_mut","borrow_mut","build","build","can_control","can_go_next","can_go_previous","can_pause","can_play","can_quit","can_raise","can_seek","can_set_fullscreen","clone","clone_into","comment","composer","content_created","default","desktop_entry","disc_number","first_used","fmt","from","from","fullscreen","genre","has_track_list","identity","into","into","last_used","length","loop_status","lyricist","lyrics","maximum_rate","metadata","minimum_rate","null_value","playback_status","position","rate","shuffle","supported_mime_types","supported_uri_schemes","title","to_owned","track_number","trackid","try_from","try_from","try_into","try_into","type_id","type_id","url","use_count","user_rating","volume","vzip","vzip","async_trait","zbus"],"q":[[0,"mpris_server"],[528,"mpris_server::builder"],[600,"mpris_server::export"]],"d":["","Alphabetical ordering by name, ascending.","","","","","","","","","","","Ordering by creation date, oldest first.","Date/time fields should be sent as strings in ISO 8601 …","","","","","Ordering by date of last playback, oldest first.","Used to implement org.mpris.MediaPlayer2.Player interface.","Used to implement org.mpris.MediaPlayer2.Playlists …","Used to implement org.mpris.MediaPlayer2 interface.","Local version of Server that doesn’t require T to be Send…","Used to implement org.mpris.MediaPlayer2.TrackList …","A repeat / loop status","","","A data structure describing a playlist, or nothing.","A mapping from metadata attribute names to values.","","","Ordering by last modified date, oldest first.","A special track ID to indicate “no track”.","The playback will stop when there are no more tracks to …","","A track is currently paused.","A playback rate.","A playback state.","","Ready-made mutable object that internally implements …","","A track is currently playing.","A data structure describing a playlist.","The playback loops through a list of tracks.","","Unique playlist identifier.","Specifies the ordering of returned playlists.","Used to implement org.mpris.MediaPlayer2.Playlists …","Used for emitting PropertiesChanged signals on Server<T> …","","Used for emitting PropertiesChanged signals on Server<T> …","","Used to implement org.mpris.MediaPlayer2 interface.","Thin wrapper around zbus::Connection that calls to T’s …","","There is no track currently playing.","","","Time in microseconds.","The current track will start again from the beginning once …","Unique track identifier.","Used to implement org.mpris.MediaPlayer2.Playlists …","Used for emitting PropertiesChanged signals on Server<T> …","","A unique resource identifier.","A user-defined ordering.","Audio volume level.","","Starts playing the given playlist.","","The currently-active playlist.","","Adds a URI in the TrackList.","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Creates a new builder-pattern struct instance to construct …","","","","","If false, calling AddTrack or RemoveTrack will have no …","","","","","","","","","","","","","","","If false, calling Quit will have no effect, and may raise a","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","","","Whether the media player is occupying the fullscreen.","","Get the value of the given key and convert it to V, if it …","Gets a set of playlists.","","Gets all the metadata available for a set of tracks.","","Get the value of the given key, if it exists.","Skip to the specified TrackId.","","","","","","The URI of an (optional) icon.","A unique identifier for the playlist.","","","","","Returns a reference to the underlying implementation.","","Insert a new key-value pair into the metadata.","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Returns the track ID as an ObjectPath.","","","","","","","","","","","","","The name of the playlist, typically given by the user.","","Creates a new Server with the given bus name suffix and …","Create an empty Metadata.","","Creates a new Server with the given bus name suffix and …","","Creates a new Server with the given bus name suffix and …","","Creates a new Server with the given bus name suffix and …","","","Construct a MaybePlaylist that contains invalid/no …","","","","","","","","The available orderings. At least one must be offered.","","","","","","","","","","","","","The number of playlists available.","","","Emits the PropertiesChanged signal for the given …","","","","","","","Emits the PropertiesChanged signal for the given …","Causes the media player to stop running.","Causes the media player to stop running.","Brings the media player’s user interface to the front …","Brings the media player’s user interface to the front …","","","","Removes an item from the TrackList.","","","","","","","","","","","","The album name.","The album artist(s).","The location of an image representing the track or album.","The track artist(s).","The speed of the music, in beats per minute.","An automatically-generated rating, based on things such as …","","","","","","","","","","A (list of) freeform comment(s).","The composer(s) of the track.","When the track was created. Usually only the year component","","The disc number on the album that this track is from.","When the track was first played.","","","","The genre(s) of the track.","","","When the track was last played.","The duration of the track in microseconds.","","","","The lyricist(s) of the track.","The track lyrics.","","","","","","","","","","","","","","","","The track title.","The track number on the album disc.","A unique identity for this track within the context of an …","The location of the media file.","The number of times the track has been played.","A user-specified rating. This should be in the range 0.0 …","","","","","","","","","","","","","","Construct a valid MaybePlaylist from the given playlist.","","","","","","","","","","","","","","","","","","","","","","","","","","Emits the PropertiesChanged signal for the given …","","","","","","","An array which contains the identifier of each track in …","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","A builder used to create Metadata.","A builder used to create Player.","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","","","","","Calls U::from(self).","Calls U::from(self).","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","",""],"i":[14,11,12,13,12,12,12,12,12,12,12,12,11,0,12,12,12,12,11,0,0,0,0,0,0,12,12,0,0,12,12,11,6,8,14,10,0,0,12,0,0,10,0,8,14,0,0,0,0,12,0,12,0,0,12,10,12,12,0,8,0,0,0,13,0,11,0,12,51,49,51,49,50,48,8,10,11,12,13,14,12,13,14,12,13,14,12,13,14,32,38,8,18,10,17,19,20,11,12,13,14,6,32,38,8,18,10,17,19,20,11,12,13,14,6,0,18,17,35,31,17,50,48,35,31,17,35,31,17,35,31,17,35,31,17,61,62,17,61,62,17,35,31,17,61,62,17,8,18,10,19,20,11,12,13,14,6,8,18,10,19,20,11,12,13,14,6,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,18,6,6,11,6,11,6,61,62,17,8,18,10,19,20,11,6,17,8,18,10,19,20,11,12,13,14,6,8,10,19,20,11,12,13,14,6,0,32,38,8,8,18,10,10,17,19,20,11,11,12,13,14,6,6,32,38,8,18,10,17,19,20,20,20,11,12,13,14,6,6,61,62,17,18,51,49,50,48,18,50,48,61,62,17,6,19,19,61,62,17,32,38,38,18,32,38,8,18,10,17,19,20,11,12,13,14,6,6,35,31,17,35,31,17,35,31,17,35,31,17,19,32,38,18,32,38,32,38,32,38,35,31,20,12,13,14,18,6,35,31,51,49,35,31,35,31,35,31,35,31,17,32,38,51,49,32,38,35,31,17,35,31,32,38,61,62,61,62,35,31,17,50,48,32,17,35,31,32,38,18,19,20,6,18,18,18,18,18,18,17,17,17,17,17,17,17,17,17,18,18,18,17,18,18,61,62,17,18,17,17,18,18,35,31,17,18,18,17,17,17,17,35,31,17,35,31,17,35,31,17,17,17,18,18,18,18,18,18,35,31,17,35,31,17,8,18,10,19,20,11,6,20,35,31,61,62,17,61,62,17,8,18,10,19,20,11,12,13,14,6,8,10,11,6,32,38,32,38,32,38,32,38,32,38,50,48,32,38,8,8,18,10,17,19,20,11,12,13,14,6,6,6,32,38,8,18,10,17,19,20,11,12,13,14,6,32,38,8,18,10,17,19,20,11,12,13,14,6,35,31,17,32,38,8,18,10,17,19,20,11,12,13,14,6,0,0,15,15,15,15,15,15,16,15,16,15,16,15,16,16,16,16,16,16,16,16,16,15,15,15,15,15,15,16,15,15,15,16,15,16,15,16,16,16,15,15,15,16,15,15,16,16,16,15,16,16,16,16,16,16,15,15,15,15,16,15,16,15,16,15,15,15,15,16,16,15,0,0],"f":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,[1,[[4,[[3,[2]]]]]],[1,[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[5,6,7],[[4,[[3,[2]]]]]],[[5,6,7],[[4,[[3,[2]]]]]],[8,9],[10,9],[11,9],[[12,12]],[[13,13]],[[14,14]],[[12,12]],[[13,13]],[[14,14]],[12],[13],[14],[[12,12]],[[13,13]],[[14,14]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],0,[[],15],[9,16],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,7],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,7],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,7],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,7],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,7],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,7],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,7],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,7],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,7],[8,8],[18,18],[10,10],[19,19],[20,20],[11,11],[12,12],[13,13],[14,14],[6,6],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[17,21]],[[17,21]],[[17,21]],[[17,21]],[[17,21]],[[17,21]],[[17,21]],[[17,21]],[[17,21]],[[17,21]],[[17,21]],[[17,21]],[[17,21]],[[17,21]],[[17,21]],[[17,21]],[[],18],[[],6],[6],[22,[[23,[11]]]],[22,[[23,[6]]]],[[[25,[24]]],[[23,[26]]]],[[[25,[24]]],[[23,[26]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,[[28,[27]]]],[[],24],[[],24],[[],24],[[],24],[[],24],[[],24],[[],24],[[17,29],30],[[8,8],7],[[18,18],7],[[10,10],7],[[19,19],7],[[20,20],7],[[11,11],7],[[12,12],7],[[13,13],7],[[14,14],7],[[6,6],7],[[],7],[[],7],[[],7],[[],7],[[],7],[[],7],[[],7],[[],7],[[],7],0,[[[32,[31]],33],34],[[[38,[[0,[35,36,37]]]],33],34],[[8,33],34],[[8,33],34],[[18,33],34],[[10,33],34],[[10,33],34],[[17,33],34],[[19,33],34],[[20,33],34],[[11,33],34],[[11,33],34],[[12,33],34],[[13,33],34],[[14,33],34],[[6,33],34],[[6,33],34],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[[39,[19]]],20],[19,20],[[]],[[]],[[]],[[]],[[]],[[]],[40,6],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,7],[[18,9],[[39,[41]]]],[[42,42,11,7],[[4,[[3,[2]]]]]],[[42,42,11,7],[[4,[[3,[2]]]]]],[[[43,[6]]],[[4,[[3,[2]]]]]],[[[43,[6]]],[[4,[[3,[2]]]]]],[[18,9],[[39,[44]]]],[6,[[4,[[3,[2]]]]]],[6,[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,7],[[6,45]],0,0,[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,[[28,[27]]]],[[[32,[31]]],31],[[[38,[[0,[35,36,37]]]]],[[0,[35,36,37]]]],[[[38,[[0,[35,36,37]]]]],30],[[18,[46,[27]],[46,[44]]],[[39,[44]]]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[6,40],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,8],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,47],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,[[28,[18]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,47],0,[[9,31],[[30,[[32,[31]]]]]],[[9,[0,[35,36,37]]],[[30,[[38,[[0,[35,36,37]]]]]]]],[[],18],[[9,[0,[48,49]]],[[30,[[32,[[0,[48,49]]]]]]]],[[9,[0,[50,51,36,37]]],[[30,[[38,[[0,[50,51,36,37]]]]]]]],[[9,49],[[30,[[32,[49]]]]]],[[9,[0,[51,36,37]]],[[30,[[38,[[0,[51,36,37]]]]]]]],[[9,48],[[30,[[32,[48]]]]]],[[9,[0,[50,36,37]]],[[30,[[38,[[0,[50,36,37]]]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],20],[12],[13],[14],[[]],[[]],[27,[[4,[[3,[2]]]]]],[27,[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,10],[[[32,[49]],19],30],[[[38,[[0,[51,36,37]]]],19],30],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[[32,[49]],[46,[[52,[14]]]]],30],[[[38,[[0,[51,36,37]]]],[46,[[52,[14]]]]],30],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,29],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[[32,[31]],[46,[[52,[12]]]]],30],[[[38,[[0,[35,36,37]]]],[46,[[52,[12]]]]],30],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,47],[6,[[4,[[3,[2]]]]]],[6,[[4,[[3,[2]]]]]],[[[32,[31]]],30],[17,30],[29,[[4,[[3,[2]]]]]],[29,[[4,[[3,[2]]]]]],[[[32,[31]],29],30],[[[38,[[0,[35,36,37]]]],29],30],[[18,53],23],[[19,53],23],[[20,53],23],[[6,53],23],[[18,[46,[27]]]],[[18,54]],[[18,[46,[5]]]],[[18,54]],[[18,55]],[[18,56]],[[17,7],30],[[17,7],30],[[17,7],30],[[17,7],30],[[17,7],30],[[17,7],30],[[17,7],30],[[17,7],30],[[17,7],30],[[18,54]],[[18,54]],[[18,[46,[57]]]],[[17,[46,[27]]],30],[[18,55]],[[18,[46,[57]]]],[7,[[4,[[3,[2]]]]]],[7,[[4,[[3,[2]]]]]],[[17,7],30],[[18,54]],[[17,7],30],[[17,[46,[27]]],30],[[18,[46,[57]]]],[[18,29]],[8,[[4,[[3,[2]]]]]],[8,[[4,[[3,[2]]]]]],[[17,8],30],[[18,54]],[[18,[46,[27]]]],[[17,47],30],[[17,18],30],[[17,47],30],[[17,10],30],[[6,29],[[4,[[3,[2]]]]]],[[6,29],[[4,[[3,[2]]]]]],[[17,29],30],[47,[[4,[[3,[2]]]]]],[47,[[4,[[3,[2]]]]]],[[17,47],30],[7,[[4,[[3,[2]]]]]],[7,[[4,[[3,[2]]]]]],[[17,7],30],[[17,54],30],[[17,54],30],[[18,[46,[27]]]],[[18,55]],[[18,[46,[58]]]],[[18,[46,[5]]]],[[18,55]],[[18,56]],[59,[[4,[[3,[2]]]]]],[59,[[4,[[3,[2]]]]]],[[17,59],30],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,7],[[],24],[[],24],[[],24],[[],24],[[],24],[[],24],[[],24],[19,20],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,[[28,[[43,[27]]]]]],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,[[28,[[43,[27]]]]]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[],27],[[],27],[[],27],[[],27],[[[32,[48]],18,6],30],[[[38,[[0,[50,36,37]]]],18,6],30],[[[32,[48]],[46,[[52,[13]]]]],30],[[[38,[[0,[50,36,37]]]],[46,[[52,[13]]]]],30],[[[32,[48]],[43,[6]],6],30],[[[38,[[0,[50,36,37]]]],[43,[6]],6],30],[[[32,[48]],6,18],30],[[[38,[[0,[50,36,37]]]],6,18],30],[[[32,[48]],6],30],[[[38,[[0,[50,36,37]]]],6],30],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[[],23],[[],23],[[],23],[44,[[23,[8]]]],[[],23],[[],23],[[],23],[[],23],[[],23],[[],23],[[],23],[[],23],[[],23],[27,[[41,[6]]]],[[],23],[9,[[41,[6]]]],[[],23],[[],23],[[],23],[[],23],[[],23],[[],23],[[],23],[[],23],[[],23],[[],23],[[],23],[[],23],[[],23],[[],60],[[],60],[[],60],[[],60],[[],60],[[],60],[[],60],[[],60],[[],60],[[],60],[[],60],[[],60],[[],60],[[],[[4,[[3,[2]]]]]],[[],[[4,[[3,[2]]]]]],[17,59],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],0,0,[[15,[46,[27]]],15],[[15,54],15],[[15,[46,[5]]],15],[[15,54],15],[[15,55],15],[[15,56],15],[[]],[[]],[[]],[[]],[16,[[30,[17]]]],[15,18],[[16,7],16],[[16,7],16],[[16,7],16],[[16,7],16],[[16,7],16],[[16,7],16],[[16,7],16],[[16,7],16],[[16,7],16],[15,15],[[]],[[15,54],15],[[15,54],15],[[15,[46,[57]]],15],[[],15],[[16,[46,[27]]],16],[[15,55],15],[[15,[46,[57]]],15],[[15,33],34],[[]],[[]],[[16,7],16],[[15,54],15],[[16,7],16],[[16,[46,[27]]],16],[[]],[[]],[[15,[46,[57]]],15],[[15,29],15],[[16,8],16],[[15,54],15],[[15,[46,[27]]],15],[[16,47],16],[[16,18],16],[[16,47],16],[[]],[[16,10],16],[[16,29],16],[[16,47],16],[[16,7],16],[[16,54],16],[[16,54],16],[[15,[46,[27]]],15],[[]],[[15,55],15],[[15,[46,[58]]],15],[[],23],[[],23],[[],23],[[],23],[[],60],[[],60],[[15,[46,[5]]],15],[[15,55],15],[[15,56],15],[[16,59],16],[[]],[[]],0,0],"c":[],"p":[[6,"PlaylistId"],[8,"Future"],[3,"Box"],[3,"Pin"],[6,"Uri"],[3,"TrackId"],[15,"bool"],[4,"LoopStatus"],[15,"str"],[4,"PlaybackStatus"],[4,"PlaylistOrdering"],[4,"Property"],[4,"TrackListProperty"],[4,"PlaylistsProperty"],[3,"MetadataBuilder"],[3,"PlayerBuilder"],[3,"Player"],[3,"Metadata"],[3,"Playlist"],[3,"MaybePlaylist"],[8,"Fn"],[8,"Deserializer"],[4,"Result"],[3,"Signature"],[8,"TryInto"],[4,"Error"],[3,"String"],[3,"Ref"],[6,"TimeInUs"],[6,"Result"],[8,"LocalPlayerInterface"],[3,"LocalServer"],[3,"Formatter"],[6,"Result"],[8,"PlayerInterface"],[8,"Send"],[8,"Sync"],[3,"Server"],[4,"Option"],[3,"ObjectPath"],[6,"Result"],[15,"u32"],[3,"Vec"],[4,"Value"],[8,"Hasher"],[8,"Into"],[6,"PlaybackRate"],[8,"LocalTrackListInterface"],[8,"LocalPlaylistsInterface"],[8,"TrackListInterface"],[8,"PlaylistsInterface"],[3,"BitFlags"],[8,"Serializer"],[8,"IntoIterator"],[15,"i32"],[15,"f64"],[6,"DateTime"],[3,"OwnedObjectPath"],[6,"Volume"],[3,"TypeId"],[8,"RootInterface"],[8,"LocalRootInterface"]],"a":{"activateplaylist":[68],"activeplaylist":[70],"addtrack":[72],"cancontrol":[118],"canedittracks":[121],"cangonext":[123],"cangoprevious":[126],"canpause":[129],"canplay":[132],"canquit":[135],"canraise":[138],"canseek":[141],"cansetfullscreen":[144],"desktopentry":[190],"fullscreen":[254,388],"getplaylists":[258],"gettracksmetadata":[260],"goto":[263],"hastracklist":[265],"identity":[271],"loop_status":[24],"loopstatus":[292,396],"maximumrate":[295],"maybe_playlist":[27],"metadata":[298],"metadata_map":[28],"minimumrate":[301],"next":[314],"openuri":[322],"orderings":[324],"org.mpris.mediaplayer2.player":[40],"org.mpris.mediaplayer2.playlists":[47],"org.mpris.mediaplayer2.tracklist":[61],"pause":[326],"play":[328],"playback_rate":[36],"playback_status":[37],"playbackstatus":[332],"playlist_id":[45],"playlist_ordering":[46],"playlistcount":[337],"playpause":[330],"position":[341],"previous":[344],"quit":[348],"raise":[350],"rate":[352,408],"removetrack":[355],"seek":[359],"setposition":[405],"shuffle":[411,425],"stop":[436],"supportedmimetypes":[438],"supportedurischemes":[441],"time_in_us":[58],"track_id":[60],"tracks":[468],"volume":[422,512]}}\ +"mpris_server":{"doc":"MPRIS Server","t":"NNNNNNNNNNNNNGNNNNNIIIDIENSSNDDNNNSNNNGENDINDNNGEIENENIDNNNNDNDIENGNGNSLKKKKLLKKLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLALLKKLKKKKLKKLKKLKKLKKLKKLKKLKKLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLKKLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLALLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLKKLLLKKKKLKKKKLLLMMKKLLLLLLLLLLLLLLLLLLLLLLLLKKLKKLKKLKKLMLLLLLLLLLKKLLLLLLLKKKKLKKKKKKKKLLLKKLLKKLKKLLKKKKKKLKKLLLLKKLLLLLLLLLLLLLLLLLLLLLLLLLLLLKKLLLLLLKKLLLLLLLKKLKKLKKLLLLLLLLLKKLKKLLLLLLLLLKKLLKKLKKLLLLLLLLLLLLLLLLLLLLLLLLLLKKLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLKKLLLLLLLLLLLLLLLDDLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLCC","n":["ActivePlaylist","Alphabetical","CanControl","CanEditTracks","CanGoNext","CanGoPrevious","CanPause","CanPlay","CanQuit","CanRaise","CanSeek","CanSetFullscreen","CreationDate","DateTime","DesktopEntry","Fullscreen","HasTrackList","Identity","LastPlayDate","LocalPlayerInterface","LocalPlaylistsInterface","LocalRootInterface","LocalServer","LocalTrackListInterface","LoopStatus","LoopStatus","MAX","MIN","MaximumRate","MaybePlaylist","Metadata","Metadata","MinimumRate","ModifiedDate","NO_TRACK","None","Orderings","Paused","PlaybackRate","PlaybackStatus","PlaybackStatus","Player","PlayerInterface","Playing","Playlist","Playlist","PlaylistCount","PlaylistId","PlaylistOrdering","PlaylistsInterface","PlaylistsProperty","Position","Property","Rate","RootInterface","Server","Shuffle","Stopped","SupportedMimeTypes","SupportedUriSchemes","Time","Track","TrackId","TrackListInterface","TrackListProperty","Tracks","Uri","UserDefined","Volume","Volume","ZERO","abs","activate_playlist","activate_playlist","active_playlist","active_playlist","add","add_assign","add_track","add_track","as_micros","as_millis","as_nanos","as_secs","as_str","as_str","as_str","bitand","bitand","bitand","bitor","bitor","bitor","bits","bits","bits","bitxor","bitxor","bitxor","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","builder","builder","builder","can_control","can_control","can_control","can_edit_tracks","can_edit_tracks","can_go_next","can_go_next","can_go_next","can_go_previous","can_go_previous","can_go_previous","can_pause","can_pause","can_pause","can_play","can_play","can_play","can_quit","can_quit","can_quit","can_raise","can_raise","can_raise","can_seek","can_seek","can_seek","can_set_fullscreen","can_set_fullscreen","can_set_fullscreen","checked_add","checked_sub","clone","clone","clone","clone","clone","clone","clone","clone","clone","clone","clone","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","cmp","connect_next","connect_open_uri","connect_pause","connect_play","connect_play_pause","connect_previous","connect_quit","connect_raise","connect_seek","connect_set_fullscreen","connect_set_loop_status","connect_set_position","connect_set_rate","connect_set_shuffle","connect_set_volume","connect_stop","default","default","default","deref","deserialize","deserialize","deserialize","deserializer_for_signature","deserializer_for_signature","deserializer_for_signature","desktop_entry","desktop_entry","desktop_entry","dynamic_signature","dynamic_signature","dynamic_signature","dynamic_signature","dynamic_signature","dynamic_signature","dynamic_signature","dynamic_signature","emit_seeked","eq","eq","eq","eq","eq","eq","eq","eq","eq","eq","eq","equivalent","equivalent","equivalent","equivalent","equivalent","equivalent","equivalent","equivalent","equivalent","equivalent","export","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","from","from","from","from","from","from","from","from","from","from","from","from","from","from","from","from","from","from_micros","from_millis","from_nanos","from_secs","fullscreen","fullscreen","fullscreen","get","get","get_playlists","get_playlists","get_tracks_metadata","get_tracks_metadata","get_value","go_to","go_to","has_track_list","has_track_list","has_track_list","hash","hash","icon","id","identity","identity","identity","imp","imp","init","insert","into","into","into","into","into","into","into","into","into","into","into","into","into","into","into_inner","is_negative","is_positive","is_zero","just","loop_status","loop_status","loop_status","maximum_rate","maximum_rate","maximum_rate","metadata","metadata","metadata","minimum_rate","minimum_rate","minimum_rate","name","new","new","new","new_with_all","new_with_all","new_with_playlists","new_with_playlists","new_with_track_list","new_with_track_list","next","next","not","not","not","nothing","null_value","null_value","null_value","open_uri","open_uri","orderings","orderings","partial_cmp","pause","pause","play","play","play_pause","play_pause","playback_status","playback_status","playback_status","playlist_changed","playlist_changed","playlist_count","playlist_count","playlists_properties_changed","playlists_properties_changed","position","position","position","previous","previous","properties_changed","properties_changed","quit","quit","raise","raise","rate","rate","rate","remove_track","remove_track","run","run","saturating_add","saturating_sub","seek","seek","seeked","seeked","serialize","serialize","serialize","serialize","serialize","set_album","set_album_artist","set_art_url","set_artist","set_audio_bpm","set_auto_rating","set_can_control","set_can_go_next","set_can_go_previous","set_can_pause","set_can_play","set_can_quit","set_can_raise","set_can_seek","set_can_set_fullscreen","set_comment","set_composer","set_content_created","set_desktop_entry","set_disc_number","set_first_used","set_fullscreen","set_fullscreen","set_fullscreen","set_genre","set_has_track_list","set_identity","set_last_used","set_length","set_loop_status","set_loop_status","set_loop_status","set_lyricist","set_lyrics","set_maximum_rate","set_metadata","set_minimum_rate","set_playback_status","set_position","set_position","set_position","set_rate","set_rate","set_rate","set_shuffle","set_shuffle","set_shuffle","set_supported_mime_types","set_supported_uri_schemes","set_title","set_track_number","set_trackid","set_url","set_use_count","set_user_rating","set_volume","set_volume","set_volume","shuffle","shuffle","shuffle","signature","signature","signature","signature","signature","signature","signature","signature","stop","stop","sub","sub_assign","supported_mime_types","supported_mime_types","supported_mime_types","supported_uri_schemes","supported_uri_schemes","supported_uri_schemes","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_string","to_string","to_string","to_string","track_added","track_added","track_list_properties_changed","track_list_properties_changed","track_list_replaced","track_list_replaced","track_metadata_changed","track_metadata_changed","track_removed","track_removed","tracks","tracks","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","volume","volume","volume","vzip","vzip","vzip","vzip","vzip","vzip","vzip","vzip","vzip","vzip","vzip","vzip","vzip","vzip","MetadataBuilder","PlayerBuilder","album","album_artist","art_url","artist","audio_bpm","auto_rating","borrow","borrow","borrow_mut","borrow_mut","build","build","can_control","can_go_next","can_go_previous","can_pause","can_play","can_quit","can_raise","can_seek","can_set_fullscreen","clone","clone_into","comment","composer","content_created","default","desktop_entry","disc_number","first_used","fmt","from","from","fullscreen","genre","has_track_list","identity","into","into","last_used","length","loop_status","lyricist","lyrics","maximum_rate","metadata","minimum_rate","null_value","other","playback_status","position","rate","shuffle","supported_mime_types","supported_uri_schemes","title","to_owned","track_number","trackid","try_from","try_from","try_into","try_into","type_id","type_id","url","use_count","user_rating","volume","vzip","vzip","async_trait","zbus"],"q":[[0,"mpris_server"],[576,"mpris_server::builder"],[649,"mpris_server::export"]],"d":["","Alphabetical ordering by name, ascending.","","","","","","","","","","","Ordering by creation date, oldest first.","Combined date and time.","","","","","Ordering by date of last playback, oldest first.","Used to implement org.mpris.MediaPlayer2.Player interface.","Used to implement org.mpris.MediaPlayer2.Playlists …","Used to implement org.mpris.MediaPlayer2 interface.","Local version of Server that doesn’t require T to be Send…","Used to implement org.mpris.MediaPlayer2.TrackList …","A repeat / loop status","","The maximum time.","The minimum time.","","A data structure describing a playlist, or nothing.","A mapping from metadata attribute names to values.","","","Ordering by last modified date, oldest first.","A special track ID to indicate “no track”.","The playback will stop when there are no more tracks to …","","A track is currently paused.","A playback rate.","A playback state.","","Ready-to-use mutable object that internally implements …","","A track is currently playing.","A data structure describing a playlist.","The playback loops through a list of tracks.","","Unique playlist identifier.","Specifies the ordering of returned playlists.","Used to implement org.mpris.MediaPlayer2.Playlists …","Used for emitting PropertiesChanged signals on Server<T> …","","Used for emitting PropertiesChanged signals on Server<T> …","","Used to implement org.mpris.MediaPlayer2 interface.","Thin wrapper around zbus::Connection that calls to T’s …","","There is no track currently playing.","","","A time which can be negative.","The current track will start again from the beginning once …","Unique track identifier.","Used to implement org.mpris.MediaPlayer2.Playlists …","Used for emitting PropertiesChanged signals on Server<T> …","","A unique resource identifier.","A user-defined ordering.","Audio volume level.","","A time of zero.","Returns the time as an absolute (non-negative) value.","Starts playing the given playlist.","","The currently-active playlist.","","","","Adds a URI in the TrackList.","","Returns the number of whole microseconds contained by this …","Returns the number of whole milliseconds contained by this …","Returns the number of whole nanoseconds contained by this …","Returns the number of whole seconds contained by this Time.","Returns the string representation of this loop status.","Returns the string representation of this playback status.","Returns the string representation of this playlist …","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","This contains the definitions of builder-pattern structs.","Creates a new builder-pattern struct instance to construct …","","","","","If false, calling AddTrack or RemoveTrack will have no …","","","","","","","","","","","","","","","If false, calling Quit will have no effect, and may raise a","","","","","","","","","","","Checked Time addition. Computes self + other, returning …","Checked Time subtraction. Computes self - other, returning …","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","This contains libraries that are used alongside with this …","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","","Returns the argument unchanged.","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","","Returns the argument unchanged.","Creates a new Time from the specified number of whole …","Creates a new Time from the specified number of whole …","Creates a new Time from the specified number of whole …","Creates a new Time from the specified number of whole …","","Whether the media player is occupying the fullscreen.","","Get the value of the given key and convert it to V, if it …","Returns Some if this structure contains a valid playlist, …","Gets a set of playlists.","","Gets all the metadata available for a set of tracks.","","Get the value of the given key, if it exists.","Skip to the specified TrackId.","","","","","","","The URI of an (optional) icon.","A unique identifier for the playlist.","","","","Returns a reference to the inner implementation.","Returns a reference to the underlying implementation.","Initializes the connection.","Insert a new key-value pair into the metadata.","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Returns the track ID as an ObjectPath.","Returns true if this Time is negative.","Returns true if this Time is positive.","Returns true if this Time is zero.","Construct a valid MaybePlaylist from the given playlist.","","","","","","","","","","","","","The name of the playlist, typically given by the user.","","Creates a new Server with the given bus name suffix and …","Create an empty Metadata.","","Creates a new Server with the given bus name suffix and …","","Creates a new Server with the given bus name suffix and …","","Creates a new Server with the given bus name suffix and …","","","","","","Construct a MaybePlaylist that contains invalid/no …","","","","","","The available orderings. At least one must be offered.","","","","","","","","","","","","","","The number of playlists available.","","","Emits the PropertiesChanged signal for the given …","","","","","","","Emits the PropertiesChanged signal for the given …","Causes the media player to stop running.","Causes the media player to stop running.","Brings the media player’s user interface to the front …","Brings the media player’s user interface to the front …","","","","Removes an item from the TrackList.","","Run the server. This method will continually run until the …","","Saturating Time addition. Computes self + other, returning …","Saturating Time subtraction. Computes self - other, …","","","","","","","","","","The album name.","The album artist(s).","The location of an image representing the track or album.","The track artist(s).","The speed of the music, in beats per minute.","An automatically-generated rating, based on things such as …","","","","","","","","","","A (list of) freeform comment(s).","The composer(s) of the track.","When the track was created. Usually only the year component","","The disc number on the album that this track is from.","When the track was first played.","","","","The genre(s) of the track.","","","When the track was last played.","The duration of the track in microseconds.","","","","The lyricist(s) of the track.","The track lyrics.","","","","","","","","","","","","","","","","The track title.","The track number on the album disc.","A unique identity for this track within the context of an …","The location of the media file.","The number of times the track has been played.","A user-specified rating. This should be in the range 0.0 …","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Emits the PropertiesChanged signal for the given …","","","","","","","An array which contains the identifier of each track in …","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","A builder used to create Metadata.","A builder used to create Player.","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","","","","","Calls U::from(self).","Calls U::from(self).","","","","","","","","","","Insert a new key-value pair into the metadata.","","","","","","","","","","","","","","","","","","","","","","","",""],"i":[16,13,14,15,14,14,14,14,14,14,14,14,13,0,14,14,14,14,13,0,0,0,0,0,0,14,1,1,14,0,0,14,14,13,7,10,16,12,0,0,14,0,0,12,0,10,16,0,0,0,0,14,0,14,0,0,14,12,14,14,0,10,0,0,0,15,0,13,0,14,1,1,51,49,51,49,1,1,50,48,1,1,1,1,10,12,13,14,15,16,14,15,16,14,15,16,14,15,16,35,39,10,21,12,19,22,23,13,14,15,16,1,7,35,39,10,21,12,19,22,23,13,14,15,16,1,7,0,21,19,38,34,19,50,48,38,34,19,38,34,19,38,34,19,38,34,19,61,62,19,61,62,19,38,34,19,61,62,19,1,1,10,21,12,22,23,13,14,15,16,1,7,10,21,12,22,23,13,14,15,16,1,7,1,19,19,19,19,19,19,19,19,19,19,19,19,19,19,19,19,21,1,7,7,13,1,7,13,1,7,61,62,19,10,21,12,22,23,13,1,7,19,10,21,12,22,23,13,14,15,16,1,7,10,12,22,23,13,14,15,16,1,7,0,35,39,10,10,21,12,12,19,22,23,13,13,14,15,16,1,7,7,35,39,10,21,12,19,22,23,23,23,13,14,15,16,1,7,7,1,1,1,1,61,62,19,21,23,51,49,50,48,21,50,48,61,62,19,1,7,22,22,61,62,19,35,39,39,21,35,39,10,21,12,19,22,23,13,14,15,16,1,7,7,1,1,1,23,38,34,19,38,34,19,38,34,19,38,34,19,22,35,39,21,35,39,35,39,35,39,38,34,14,15,16,23,21,1,7,38,34,51,49,1,38,34,38,34,38,34,38,34,19,35,39,51,49,35,39,38,34,19,38,34,35,39,61,62,61,62,38,34,19,50,48,35,19,1,1,38,34,35,39,21,22,23,1,7,21,21,21,21,21,21,19,19,19,19,19,19,19,19,19,21,21,21,19,21,21,61,62,19,21,19,19,21,21,38,34,19,21,21,19,19,19,19,38,34,19,38,34,19,38,34,19,19,19,21,21,21,21,21,21,38,34,19,38,34,19,10,21,12,22,23,13,1,7,38,34,1,1,61,62,19,61,62,19,10,21,12,22,23,13,14,15,16,1,7,10,12,13,7,35,39,35,39,35,39,35,39,35,39,50,48,35,39,10,10,21,12,19,22,23,13,14,15,16,1,7,7,7,35,39,10,21,12,19,22,23,13,14,15,16,1,7,35,39,10,21,12,19,22,23,13,14,15,16,1,7,38,34,19,35,39,10,21,12,19,22,23,13,14,15,16,1,7,0,0,17,17,17,17,17,17,18,17,18,17,18,17,18,18,18,18,18,18,18,18,18,17,17,17,17,17,17,18,17,17,17,18,17,18,17,18,18,18,17,17,17,18,17,17,18,18,18,17,17,18,18,18,18,18,18,17,17,17,17,18,17,18,17,18,17,17,17,17,18,18,17,0,0],"f":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,[1,1],[2,[[5,[[4,[3]]]]]],[2,[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[1,1],1],[[1,1]],[[6,7,8],[[5,[[4,[3]]]]]],[[6,7,8],[[5,[[4,[3]]]]]],[1,9],[1,9],[1,9],[1,9],[10,11],[12,11],[13,11],[[14,14]],[[15,15]],[[16,16]],[[14,14]],[[15,15]],[[16,16]],[14],[15],[16],[[14,14]],[[15,15]],[[16,16]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],0,[[],17],[11,18],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,8],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,8],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,8],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,8],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,8],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,8],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,8],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,8],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,8],[[1,1],[[20,[1]]]],[[1,1],[[20,[1]]]],[10,10],[21,21],[12,12],[22,22],[23,23],[13,13],[14,14],[15,15],[16,16],[1,1],[7,7],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[1,1],24],[[19,25]],[[19,25]],[[19,25]],[[19,25]],[[19,25]],[[19,25]],[[19,25]],[[19,25]],[[19,25]],[[19,25]],[[19,25]],[[19,25]],[[19,25]],[[19,25]],[[19,25]],[[19,25]],[[],21],[[],1],[[],7],[7],[26,[[27,[13]]]],[26,[[27,[1]]]],[26,[[27,[7]]]],[[[29,[28]]],[[27,[30]]]],[[[29,[28]]],[[27,[30]]]],[[[29,[28]]],[[27,[30]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,[[32,[31]]]],[[],28],[[],28],[[],28],[[],28],[[],28],[[],28],[[],28],[[],28],[[19,1],33],[[10,10],8],[[21,21],8],[[12,12],8],[[22,22],8],[[23,23],8],[[13,13],8],[[14,14],8],[[15,15],8],[[16,16],8],[[1,1],8],[[7,7],8],[[],8],[[],8],[[],8],[[],8],[[],8],[[],8],[[],8],[[],8],[[],8],[[],8],0,[[[35,[34]],36],37],[[[39,[38]],36],37],[[10,36],37],[[10,36],37],[[21,36],37],[[12,36],37],[[12,36],37],[[19,36],37],[[22,36],37],[[23,36],37],[[13,36],37],[[13,36],37],[[14,36],37],[[15,36],37],[[16,36],37],[[1,36],37],[[7,36],37],[[7,36],37],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[22,23],[[]],[[[20,[22]]],23],[[]],[[]],[[]],[[]],[[]],[40,7],[[]],[9,1],[9,1],[9,1],[9,1],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,8],[[21,11],[[20,[41]]]],[23,[[20,[22]]]],[[42,42,13,8],[[5,[[4,[3]]]]]],[[42,42,13,8],[[5,[[4,[3]]]]]],[[[43,[7]]],[[5,[[4,[3]]]]]],[[[43,[7]]],[[5,[[4,[3]]]]]],[[21,11],[[20,[44]]]],[7,[[5,[[4,[3]]]]]],[7,[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,8],[[1,45]],[[7,45]],0,0,[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,[[32,[31]]]],[[[35,[34]]],34],[[[39,[38]]],38],[[[39,[38]]],33],[[21,[46,[31]],[46,[44]]],[[20,[44]]]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[7,40],[1,8],[1,8],[1,8],[22,23],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,10],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,47],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,[[32,[21]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,47],0,[[11,34],[[33,[[35,[34]]]]]],[[11,38],[[33,[[39,[38]]]]]],[[],21],[[11,[0,[48,49]]],[[33,[[35,[[0,[48,49]]]]]]]],[[11,[0,[50,51]]],[[33,[[39,[[0,[50,51]]]]]]]],[[11,49],[[33,[[35,[49]]]]]],[[11,51],[[33,[[39,[51]]]]]],[[11,48],[[33,[[35,[48]]]]]],[[11,50],[[33,[[39,[50]]]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[14],[15],[16],[[],23],[[]],[[]],[[]],[31,[[5,[[4,[3]]]]]],[31,[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[1,1],[[20,[24]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,12],[[[35,[49]],22],33],[[[39,[51]],22],33],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[[35,[49]],[46,[[52,[16]]]]],33],[[[39,[51]],[46,[[52,[16]]]]],33],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,1],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[[35,[34]],[46,[[52,[14]]]]],33],[[[39,[38]],[46,[[52,[14]]]]],33],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,47],[7,[[5,[[4,[3]]]]]],[7,[[5,[[4,[3]]]]]],[[[35,[34]]],33],[19,33],[[1,1],1],[[1,1],1],[1,[[5,[[4,[3]]]]]],[1,[[5,[[4,[3]]]]]],[[[35,[34]],1],33],[[[39,[38]],1],33],[[21,53],27],[[22,53],27],[[23,53],27],[[1,53],27],[[7,53],27],[[21,[46,[31]]]],[[21,54]],[[21,[46,[6]]]],[[21,54]],[[21,55]],[[21,56]],[[19,8],33],[[19,8],33],[[19,8],33],[[19,8],33],[[19,8],33],[[19,8],33],[[19,8],33],[[19,8],33],[[19,8],33],[[21,54]],[[21,54]],[[21,[46,[57]]]],[[19,[46,[31]]],33],[[21,55]],[[21,[46,[57]]]],[8,[[5,[[4,[3]]]]]],[8,[[5,[[4,[3]]]]]],[[19,8],33],[[21,54]],[[19,8],33],[[19,[46,[31]]],33],[[21,[46,[57]]]],[[21,1]],[10,[[5,[[4,[3]]]]]],[10,[[5,[[4,[3]]]]]],[[19,10],33],[[21,54]],[[21,[46,[31]]]],[[19,47],33],[[19,21],33],[[19,47],33],[[19,12],33],[[7,1],[[5,[[4,[3]]]]]],[[7,1],[[5,[[4,[3]]]]]],[[19,1],33],[47,[[5,[[4,[3]]]]]],[47,[[5,[[4,[3]]]]]],[[19,47],33],[8,[[5,[[4,[3]]]]]],[8,[[5,[[4,[3]]]]]],[[19,8],33],[[19,54],33],[[19,54],33],[[21,[46,[31]]]],[[21,55]],[[21,[46,[58]]]],[[21,[46,[6]]]],[[21,55]],[[21,56]],[59,[[5,[[4,[3]]]]]],[59,[[5,[[4,[3]]]]]],[[19,59],33],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,8],[[],28],[[],28],[[],28],[[],28],[[],28],[[],28],[[],28],[[],28],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[1,1],1],[[1,1]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,[[32,[[43,[31]]]]]],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,[[32,[[43,[31]]]]]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[],31],[[],31],[[],31],[[],31],[[[35,[48]],21,7],33],[[[39,[50]],21,7],33],[[[35,[48]],[46,[[52,[15]]]]],33],[[[39,[50]],[46,[[52,[15]]]]],33],[[[35,[48]],[43,[7]],7],33],[[[39,[50]],[43,[7]],7],33],[[[35,[48]],7,21],33],[[[39,[50]],7,21],33],[[[35,[48]],7],33],[[[39,[50]],7],33],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[[],27],[[],27],[[],27],[44,[[27,[10]]]],[[],27],[[],27],[[],27],[[],27],[[],27],[[],27],[[],27],[[],27],[[],27],[[],27],[31,[[41,[7]]]],[[],27],[11,[[41,[7]]]],[[],27],[[],27],[[],27],[[],27],[[],27],[[],27],[[],27],[[],27],[[],27],[[],27],[[],27],[[],27],[[],27],[[],27],[[],60],[[],60],[[],60],[[],60],[[],60],[[],60],[[],60],[[],60],[[],60],[[],60],[[],60],[[],60],[[],60],[[],60],[[],[[5,[[4,[3]]]]]],[[],[[5,[[4,[3]]]]]],[19,59],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],0,0,[[17,[46,[31]]],17],[[17,54],17],[[17,[46,[6]]],17],[[17,54],17],[[17,55],17],[[17,56],17],[[]],[[]],[[]],[[]],[18,[[33,[19]]]],[17,21],[[18,8],18],[[18,8],18],[[18,8],18],[[18,8],18],[[18,8],18],[[18,8],18],[[18,8],18],[[18,8],18],[[18,8],18],[17,17],[[]],[[17,54],17],[[17,54],17],[[17,[46,[57]]],17],[[],17],[[18,[46,[31]]],18],[[17,55],17],[[17,[46,[57]]],17],[[17,36],37],[[]],[[]],[[18,8],18],[[17,54],17],[[18,8],18],[[18,[46,[31]]],18],[[]],[[]],[[17,[46,[57]]],17],[[17,1],17],[[18,10],18],[[17,54],17],[[17,[46,[31]]],17],[[18,47],18],[[18,21],18],[[18,47],18],[[]],[[17,[46,[31]],[46,[44]]],17],[[18,12],18],[[18,1],18],[[18,47],18],[[18,8],18],[[18,54],18],[[18,54],18],[[17,[46,[31]]],17],[[]],[[17,55],17],[[17,[46,[58]]],17],[[],27],[[],27],[[],27],[[],27],[[],60],[[],60],[[17,[46,[6]]],17],[[17,55],17],[[17,56],17],[[18,59],18],[[]],[[]],0,0],"c":[],"p":[[3,"Time"],[6,"PlaylistId"],[8,"Future"],[3,"Box"],[3,"Pin"],[6,"Uri"],[3,"TrackId"],[15,"bool"],[15,"i64"],[4,"LoopStatus"],[15,"str"],[4,"PlaybackStatus"],[4,"PlaylistOrdering"],[4,"Property"],[4,"TrackListProperty"],[4,"PlaylistsProperty"],[3,"MetadataBuilder"],[3,"PlayerBuilder"],[3,"Player"],[4,"Option"],[3,"Metadata"],[3,"Playlist"],[3,"MaybePlaylist"],[4,"Ordering"],[8,"Fn"],[8,"Deserializer"],[4,"Result"],[3,"Signature"],[8,"TryInto"],[4,"Error"],[3,"String"],[3,"Ref"],[6,"Result"],[8,"LocalPlayerInterface"],[3,"LocalServer"],[3,"Formatter"],[6,"Result"],[8,"PlayerInterface"],[3,"Server"],[3,"ObjectPath"],[6,"Result"],[15,"u32"],[3,"Vec"],[4,"Value"],[8,"Hasher"],[8,"Into"],[6,"PlaybackRate"],[8,"LocalTrackListInterface"],[8,"LocalPlaylistsInterface"],[8,"TrackListInterface"],[8,"PlaylistsInterface"],[3,"BitFlags"],[8,"Serializer"],[8,"IntoIterator"],[15,"i32"],[15,"f64"],[6,"DateTime"],[3,"OwnedObjectPath"],[6,"Volume"],[3,"TypeId"],[8,"RootInterface"],[8,"LocalRootInterface"]],"a":{"activateplaylist":[72],"activeplaylist":[74],"addtrack":[78],"cancontrol":[130],"canedittracks":[133],"cangonext":[135],"cangoprevious":[138],"canpause":[141],"canplay":[144],"canquit":[147],"canraise":[150],"canseek":[153],"cansetfullscreen":[156],"desktopentry":[210],"fullscreen":[283,429],"getplaylists":[288],"gettracksmetadata":[290],"goto":[293],"hastracklist":[295],"identity":[302],"loop_status":[24],"loopstatus":[328,437],"maximumrate":[331],"maybe_playlist":[29],"metadata":[334],"metadata_map":[30],"minimumrate":[337],"next":[350],"openuri":[359],"orderings":[361],"org.mpris.mediaplayer2.player":[42],"org.mpris.mediaplayer2.playlists":[49],"org.mpris.mediaplayer2.tracklist":[63],"pause":[364],"play":[366],"playback_rate":[38],"playback_status":[39],"playbackstatus":[370],"playlist_id":[47],"playlist_ordering":[48],"playlistcount":[375],"playpause":[368],"position":[379],"previous":[382],"quit":[386],"raise":[388],"rate":[390,449],"removetrack":[393],"seek":[399],"setposition":[446],"shuffle":[452,466],"stop":[477],"supportedmimetypes":[481],"supportedurischemes":[484],"time_in_us":[60],"track_id":[62],"tracks":[512],"volume":[463,559]}}\ }'); if (typeof window !== 'undefined' && window.initSearch) {window.initSearch(searchIndex)}; if (typeof exports !== 'undefined') {exports.searchIndex = searchIndex}; diff --git a/source-files.js b/source-files.js index e55b8c7..f6e92e3 100644 --- a/source-files.js +++ b/source-files.js @@ -1,4 +1,4 @@ var sourcesIndex = JSON.parse('{\ -"mpris_server":["",[],["lib.rs","local_server.rs","loop_status.rs","metadata.rs","playback_status.rs","player.rs","playlist.rs","playlist_ordering.rs","property.rs","server.rs","track_id.rs"]]\ +"mpris_server":["",[],["lib.rs","local_server.rs","loop_status.rs","metadata.rs","playback_status.rs","player.rs","playlist.rs","playlist_ordering.rs","property.rs","server.rs","time.rs","track_id.rs"]]\ }'); createSourceSidebar(); diff --git a/src/mpris_server/lib.rs.html b/src/mpris_server/lib.rs.html index 4446af5..fba58d6 100644 --- a/src/mpris_server/lib.rs.html +++ b/src/mpris_server/lib.rs.html @@ -649,10 +649,26 @@ 649 650 651 +652 +653 +654 +655 +656 +657 +658 +659 +660 +661
#![warn(rust_2018_idioms)]
 #![deny(rustdoc::broken_intra_doc_links)]
 #![doc = include_str!("../README.md")]
 
+// TODO:
+// * Document public interface
+// * Replace `DateTime`, and `Uri` with proper types
+// * Add getter on Metadata
+// * Profile if inlining is worth it
+
 mod local_server;
 mod loop_status;
 mod metadata;
@@ -662,6 +678,7 @@
 mod playlist_ordering;
 mod property;
 mod server;
+mod time;
 mod track_id;
 
 use async_trait::async_trait;
@@ -677,15 +694,21 @@
     playlist_ordering::PlaylistOrdering,
     property::{PlaylistsProperty, Property, TrackListProperty},
     server::Server,
+    time::Time,
     track_id::TrackId,
 };
 
-pub mod export {
+/// This contains libraries that are used alongside with this crate.
+pub mod export {
     pub use async_trait;
     pub use zbus;
 }
 
-pub mod builder {
+/// This contains the definitions of builder-pattern structs.
+///
+/// The `builder` methods on the objects must be used instead to construct
+/// these builder-pattern structs.
+pub mod builder {
     pub use crate::{metadata::MetadataBuilder, player::PlayerBuilder};
 }
 
@@ -780,9 +803,9 @@
 
             async fn play(&self) -> fdo::Result<()>;
 
-            async fn seek(&self, offset: TimeInUs) -> fdo::Result<()>;
+            async fn seek(&self, offset: Time) -> fdo::Result<()>;
 
-            async fn set_position(&self, track_id: TrackId, position: TimeInUs) -> fdo::Result<()>;
+            async fn set_position(&self, track_id: TrackId, position: Time) -> fdo::Result<()>;
 
             async fn open_uri(&self, uri: String) -> fdo::Result<()>;
 
@@ -806,7 +829,7 @@
 
             async fn set_volume(&self, volume: Volume) -> Result<()>;
 
-            async fn position(&self) -> fdo::Result<TimeInUs>;
+            async fn position(&self) -> fdo::Result<Time>;
 
             async fn minimum_rate(&self) -> fdo::Result<PlaybackRate>;
 
@@ -881,7 +904,7 @@
 
 /// Used to implement `org.mpris.MediaPlayer2` interface.
 #[async_trait]
-pub trait RootInterface {
+pub trait RootInterface: Send + Sync {
     /// Brings the media player's user interface to the front using any
     /// appropriate mechanism available.
     ///
@@ -958,10 +981,10 @@
     async fn play(&self) -> fdo::Result<()>;
 
     #[doc(alias = "Seek")]
-    async fn seek(&self, offset: TimeInUs) -> fdo::Result<()>;
+    async fn seek(&self, offset: Time) -> fdo::Result<()>;
 
     #[doc(alias = "SetPosition")]
-    async fn set_position(&self, track_id: TrackId, position: TimeInUs) -> fdo::Result<()>;
+    async fn set_position(&self, track_id: TrackId, position: Time) -> fdo::Result<()>;
 
     #[doc(alias = "OpenUri")]
     async fn open_uri(&self, uri: String) -> fdo::Result<()>;
@@ -997,7 +1020,7 @@
     async fn set_volume(&self, volume: Volume) -> Result<()>;
 
     #[doc(alias = "Position")]
-    async fn position(&self) -> fdo::Result<TimeInUs>;
+    async fn position(&self) -> fdo::Result<Time>;
 
     #[doc(alias = "MinimumRate")]
     async fn minimum_rate(&self) -> fdo::Result<PlaybackRate>;
@@ -1122,8 +1145,8 @@
     /// If the [`CanEditTracks`] property is false, this has no effect.
     ///
     /// Note: Clients should not assume that the track has been removed at the
-    /// time when this method returns. They should wait for a [`TrackRemoved`] (or
-    /// TrackListReplaced) signal.
+    /// time when this method returns. They should wait for a [`TrackRemoved`]
+    /// (or TrackListReplaced) signal.
     ///
     /// [`/org/mpris/MediaPlayer2/TrackList/NoTrack`]: TrackId::NO_TRACK
     /// [`CanEditTracks`]: Self::can_edit_tracks
@@ -1153,11 +1176,12 @@
     /// An array which contains the identifier of each track in the tracklist,
     /// in order.
     ///
-    /// The `org.freedesktop.DBus.Properties.PropertiesChanged` signal is emitted
-    /// every time this property changes, but the signal message does not
-    /// contain the new value. Client implementations should rather rely on the
-    /// [`TrackAdded`], [`TrackRemoved`] and [`TrackListReplaced`] signals to
-    /// keep their representation of the tracklist up to date.
+    /// The `org.freedesktop.DBus.Properties.PropertiesChanged` signal is
+    /// emitted every time this property changes, but the signal message
+    /// does not contain the new value. Client implementations should rather
+    /// rely on the [`TrackAdded`], [`TrackRemoved`] and
+    /// [`TrackListReplaced`] signals to keep their representation of the
+    /// tracklist up to date.
     ///
     /// [`TrackAdded`]: Server::track_added
     /// [`TrackRemoved`]: Server::track_removed
@@ -1244,9 +1268,9 @@
     /// will be false, and the Playlist details are undefined.
     ///
     /// Note that this may not have a value even after [`ActivatePlaylist`] is
-    /// called with a valid playlist id as [`ActivatePlaylist`] implementations have
-    /// the option of simply inserting the contents of the playlist into the
-    /// current tracklist.
+    /// called with a valid playlist id as [`ActivatePlaylist`] implementations
+    /// have the option of simply inserting the contents of the playlist
+    /// into the current tracklist.
     ///
     /// [`ActivatePlaylist`]: Self::activate_playlist
     #[doc(alias = "ActivePlaylist")]
@@ -1278,10 +1302,6 @@
 /// clients should not attempt to set it above 1.0.
 pub type Volume = f64;
 
-/// Time in microseconds.
-#[doc(alias = "Time_In_Us")]
-pub type TimeInUs = i64;
-
 /// Unique playlist identifier.
 ///
 /// ## Rationale
diff --git a/src/mpris_server/local_server.rs.html b/src/mpris_server/local_server.rs.html
index e326fa2..5506677 100644
--- a/src/mpris_server/local_server.rs.html
+++ b/src/mpris_server/local_server.rs.html
@@ -936,7 +936,6 @@
 936
 937
 938
-939
 
use std::{cell::RefCell, fmt, future::Future, marker::PhantomData, pin::Pin, rc::Rc};
 
 use async_trait::async_trait;
@@ -948,8 +947,8 @@
 use crate::{
     LocalPlayerInterface, LocalPlaylistsInterface, LocalTrackListInterface, LoopStatus,
     MaybePlaylist, Metadata, PlaybackRate, PlaybackStatus, PlayerInterface, Playlist, PlaylistId,
-    PlaylistOrdering, PlaylistsInterface, PlaylistsProperty, Property, RootInterface, Server,
-    TimeInUs, TrackId, TrackListInterface, TrackListProperty, Uri, Volume,
+    PlaylistOrdering, PlaylistsInterface, PlaylistsProperty, Property, RootInterface, Server, Time,
+    TrackId, TrackListInterface, TrackListProperty, Uri, Volume,
 };
 
 enum RootAction {
@@ -978,8 +977,8 @@
     PlayPause(oneshot::Sender<fdo::Result<()>>),
     Stop(oneshot::Sender<fdo::Result<()>>),
     Play(oneshot::Sender<fdo::Result<()>>),
-    Seek(TimeInUs, oneshot::Sender<fdo::Result<()>>),
-    SetPosition(TrackId, TimeInUs, oneshot::Sender<fdo::Result<()>>),
+    Seek(Time, oneshot::Sender<fdo::Result<()>>),
+    SetPosition(TrackId, Time, oneshot::Sender<fdo::Result<()>>),
     OpenUri(String, oneshot::Sender<fdo::Result<()>>),
 
     // Properties
@@ -993,7 +992,7 @@
     Metadata(oneshot::Sender<fdo::Result<Metadata>>),
     Volume(oneshot::Sender<fdo::Result<Volume>>),
     SetVolume(Volume, oneshot::Sender<Result<()>>),
-    Position(oneshot::Sender<fdo::Result<TimeInUs>>),
+    Position(oneshot::Sender<fdo::Result<Time>>),
     MinimumRate(oneshot::Sender<fdo::Result<PlaybackRate>>),
     MaximumRate(oneshot::Sender<fdo::Result<PlaybackRate>>),
     CanGoNext(oneshot::Sender<fdo::Result<bool>>),
@@ -1182,13 +1181,13 @@
         rx.await.unwrap()
     }
 
-    async fn seek(&self, offset: TimeInUs) -> fdo::Result<()> {
+    async fn seek(&self, offset: Time) -> fdo::Result<()> {
         let (tx, rx) = oneshot::channel();
         self.send_player(PlayerAction::Seek(offset, tx));
         rx.await.unwrap()
     }
 
-    async fn set_position(&self, track_id: TrackId, position: TimeInUs) -> fdo::Result<()> {
+    async fn set_position(&self, track_id: TrackId, position: Time) -> fdo::Result<()> {
         let (tx, rx) = oneshot::channel();
         self.send_player(PlayerAction::SetPosition(track_id, position, tx));
         rx.await.unwrap()
@@ -1260,7 +1259,7 @@
         rx.await.unwrap()
     }
 
-    async fn position(&self) -> fdo::Result<TimeInUs> {
+    async fn position(&self) -> fdo::Result<Time> {
         let (tx, rx) = oneshot::channel();
         self.send_player(PlayerAction::Position(tx));
         rx.await.unwrap()
@@ -1417,12 +1416,22 @@
 
 macro_rules! signal_delegate {
     ($name:ident($($arg_name:ident: $arg_ty:ty),*)) => {
-        pub async fn $name(&self, $($arg_name: $arg_ty),*) -> Result<()> {
+        #[inline]
+        pub async fn $name(&self, $($arg_name: $arg_ty),*) -> Result<()> {
             self.inner.$name($($arg_name),*).await
         }
     };
 }
 
+macro_rules! properties_changed_delegate {
+    ($name:ident, $property_ty:ty) => {
+        #[inline]
+        pub async fn $name(&self, properties: impl Into<BitFlags<$property_ty>>) -> Result<()> {
+            self.inner.$name(properties).await
+        }
+    };
+}
+
 /// Local version of [`Server`] that doesn't require `T` to be `Send` and
 /// `Sync`.
 ///
@@ -1480,29 +1489,28 @@
         })
     }
 
-    pub fn imp(&self) -> &T {
+    /// Returns a reference to the inner implementation.
+    pub fn imp(&self) -> &T {
         &self.imp
     }
 
-    pub async fn run(&self) -> Result<()> {
-        self.inner.init().await?;
-        let runner = self
-            .runner
-            .take()
-            .expect("LocalServer must not be ran twice");
-        runner.await;
+    /// Run the server. This method will continually run until the server is
+    /// dropped.
+    ///
+    /// This is no-op and returns [Ok] immediately if the server is already
+    /// running.
+    pub async fn run(&self) -> Result<()> {
+        if let Some(runner) = self.runner.take() {
+            self.inner.init().await?;
+            runner.await;
+        }
         Ok(())
     }
 
     // org.mpris.MediaPlayer2.Player
-    signal_delegate!(seeked(position: TimeInUs));
+    signal_delegate!(seeked(position: Time));
 
-    pub async fn properties_changed(
-        &self,
-        properties: impl Into<BitFlags<Property>>,
-    ) -> Result<()> {
-        self.inner.properties_changed(properties).await
-    }
+    properties_changed_delegate!(properties_changed, Property);
 
     async fn handle_root_action(imp: &T, action: RootAction) {
         match action {
@@ -1722,12 +1730,7 @@
     signal_delegate!(track_removed(track_id: TrackId));
     signal_delegate!(track_metadata_changed(track_id: TrackId, metadata: Metadata));
 
-    pub async fn track_list_properties_changed(
-        &self,
-        properties: impl Into<BitFlags<TrackListProperty>>,
-    ) -> Result<()> {
-        self.inner.track_list_properties_changed(properties).await
-    }
+    properties_changed_delegate!(track_list_properties_changed, TrackListProperty);
 
     async fn handle_track_list_action(imp: &T, action: TrackListAction) {
         match action {
@@ -1801,12 +1804,7 @@
 
     signal_delegate!(playlist_changed(playlist: Playlist));
 
-    pub async fn playlists_properties_changed(
-        &self,
-        properties: impl Into<BitFlags<PlaylistsProperty>>,
-    ) -> Result<()> {
-        self.inner.playlists_properties_changed(properties).await
-    }
+    properties_changed_delegate!(playlists_properties_changed, PlaylistsProperty);
 
     async fn handle_playlists_actions(imp: &T, action: PlaylistsAction) {
         match action {
diff --git a/src/mpris_server/loop_status.rs.html b/src/mpris_server/loop_status.rs.html
index e918d34..a1414a3 100644
--- a/src/mpris_server/loop_status.rs.html
+++ b/src/mpris_server/loop_status.rs.html
@@ -56,6 +56,7 @@
 56
 57
 58
+59
 
use std::fmt;
 
 use zbus::zvariant::{self, Type, Value};
@@ -75,7 +76,8 @@
 }
 
 impl LoopStatus {
-    pub fn as_str(&self) -> &'static str {
+    /// Returns the string representation of this loop status.
+    pub fn as_str(&self) -> &'static str {
         match self {
             Self::None => "None",
             Self::Track => "Track",
diff --git a/src/mpris_server/metadata.rs.html b/src/mpris_server/metadata.rs.html
index 662475a..ad19736 100644
--- a/src/mpris_server/metadata.rs.html
+++ b/src/mpris_server/metadata.rs.html
@@ -355,14 +355,25 @@
 355
 356
 357
+358
+359
+360
+361
+362
+363
+364
+365
+366
 
use std::{collections::HashMap, fmt};
 
 use serde::Serialize;
 use zbus::zvariant::{self, OwnedObjectPath, Type, Value};
 
-use crate::{TimeInUs, Uri};
+use crate::{Time, Uri};
 
-/// Date/time fields should be sent as strings in ISO 8601 extended
+/// Combined date and time.
+///
+/// This should be sent as strings in ISO 8601 extended
 /// format (eg: 2007-04-29T14:35:51). If the timezone is known (eg: for
 /// xesam:lastPlayed), the internet profile format of ISO 8601, as specified in
 /// RFC 3339, should be used (eg: 2007-04-29T14:35:51+02:00).
@@ -385,6 +396,7 @@
 /// [`mpris:length`]: Metadata::set_length
 /// [`mpris:artUrl`]: Metadata::set_art_url
 #[derive(Clone, PartialEq, Serialize, Type)]
+#[serde(transparent)]
 #[zvariant(signature = "a{sv}")]
 #[doc(alias = "Metadata_Map")]
 pub struct Metadata(HashMap<String, Value<'static>>);
@@ -450,7 +462,7 @@
     }
 
     /// The duration of the track in microseconds.
-    pub fn set_length(&mut self, length: TimeInUs) {
+    pub fn set_length(&mut self, length: Time) {
         self.insert("mpris:length", length);
     }
 
@@ -589,12 +601,18 @@
 }
 
 impl MetadataBuilder {
+    /// Insert a new key-value pair into the metadata.
+    pub fn other(mut self, key: impl Into<String>, value: impl Into<Value<'static>>) -> Self {
+        self.m.insert(key, value);
+        self
+    }
+
     pub fn trackid(mut self, trackid: impl Into<OwnedObjectPath>) -> Self {
         self.m.set_trackid(trackid);
         self
     }
 
-    pub fn length(mut self, length: TimeInUs) -> Self {
+    pub fn length(mut self, length: Time) -> Self {
         self.m.set_length(length);
         self
     }
diff --git a/src/mpris_server/playback_status.rs.html b/src/mpris_server/playback_status.rs.html
index 90ee245..2ce4827 100644
--- a/src/mpris_server/playback_status.rs.html
+++ b/src/mpris_server/playback_status.rs.html
@@ -36,6 +36,7 @@
 36
 37
 38
+39
 
use std::fmt;
 
 use zbus::zvariant::{Type, Value};
@@ -54,7 +55,8 @@
 }
 
 impl PlaybackStatus {
-    pub fn as_str(&self) -> &'static str {
+    /// Returns the string representation of this playback status.
+    pub fn as_str(&self) -> &'static str {
         match self {
             Self::Playing => "Playing",
             Self::Paused => "Paused",
diff --git a/src/mpris_server/player.rs.html b/src/mpris_server/player.rs.html
index 3192328..72e21b5 100644
--- a/src/mpris_server/player.rs.html
+++ b/src/mpris_server/player.rs.html
@@ -967,6 +967,9 @@
 967
 968
 969
+970
+971
+972
 
use std::cell::{Cell, Ref, RefCell};
 
 use async_trait::async_trait;
@@ -974,11 +977,14 @@
 
 use crate::{
     LocalPlayerInterface, LocalRootInterface, LocalServer, LoopStatus, Metadata, PlaybackRate,
-    PlaybackStatus, Property, TimeInUs, TrackId, Volume,
+    PlaybackStatus, Property, Time, TrackId, Volume,
 };
 
-/// Ready-made mutable object that internally implements [`LocalRootInterface`]
-/// and [`LocalPlayerInterface`].
+/// Ready-to-use mutable object that internally implements
+/// [`LocalRootInterface`] and [`LocalPlayerInterface`].
+///
+/// This automatically emits properties changed signal and allows you to connect
+/// to method and property setter calls.
 #[derive(Debug)]
 pub struct Player {
     server: LocalServer<Inner>,
@@ -1005,8 +1011,8 @@
     play_pause_cbs: RefCell<Vec<Box<dyn Fn()>>>,
     stop_cbs: RefCell<Vec<Box<dyn Fn()>>>,
     play_cbs: RefCell<Vec<Box<dyn Fn()>>>,
-    seek_cbs: RefCell<Vec<Box<dyn Fn(TimeInUs)>>>,
-    set_position_cbs: RefCell<Vec<Box<dyn Fn(&TrackId, TimeInUs)>>>,
+    seek_cbs: RefCell<Vec<Box<dyn Fn(Time)>>>,
+    set_position_cbs: RefCell<Vec<Box<dyn Fn(&TrackId, Time)>>>,
     open_uri_cbs: RefCell<Vec<Box<dyn Fn(&str)>>>,
     set_loop_status_cbs: RefCell<Vec<Box<dyn Fn(LoopStatus)>>>, // Property
     set_rate_cbs: RefCell<Vec<Box<dyn Fn(PlaybackRate)>>>,      // Property
@@ -1018,7 +1024,7 @@
     shuffle: Cell<bool>,
     metadata: RefCell<Metadata>,
     volume: Cell<Volume>,
-    position: Cell<TimeInUs>,
+    position: Cell<Time>,
     minimum_rate: Cell<PlaybackRate>,
     maximum_rate: Cell<PlaybackRate>,
     can_go_next: Cell<bool>,
@@ -1133,14 +1139,14 @@
         Ok(())
     }
 
-    async fn seek(&self, offset: TimeInUs) -> fdo::Result<()> {
+    async fn seek(&self, offset: Time) -> fdo::Result<()> {
         for cb in self.seek_cbs.borrow().iter() {
             cb(offset);
         }
         Ok(())
     }
 
-    async fn set_position(&self, track_id: TrackId, position: TimeInUs) -> fdo::Result<()> {
+    async fn set_position(&self, track_id: TrackId, position: Time) -> fdo::Result<()> {
         for cb in self.set_position_cbs.borrow().iter() {
             cb(&track_id, position);
         }
@@ -1206,7 +1212,7 @@
         Ok(())
     }
 
-    async fn position(&self) -> fdo::Result<TimeInUs> {
+    async fn position(&self) -> fdo::Result<Time> {
         Ok(self.position.get())
     }
 
@@ -1262,7 +1268,7 @@
             shuffle: false,
             metadata: Metadata::new(),
             volume: 1.0,
-            position: 0,
+            position: Time::ZERO,
             minimum_rate: 1.0,
             maximum_rate: 1.0,
             can_go_next: false,
@@ -1472,11 +1478,11 @@
         self.server.imp().play_cbs.borrow_mut().push(Box::new(cb));
     }
 
-    pub fn connect_seek(&self, cb: impl Fn(TimeInUs) + 'static) {
+    pub fn connect_seek(&self, cb: impl Fn(Time) + 'static) {
         self.server.imp().seek_cbs.borrow_mut().push(Box::new(cb));
     }
 
-    pub fn connect_set_position(&self, cb: impl Fn(&TrackId, TimeInUs) + 'static) {
+    pub fn connect_set_position(&self, cb: impl Fn(&TrackId, Time) + 'static) {
         self.server
             .imp()
             .set_position_cbs
@@ -1524,7 +1530,7 @@
             .push(Box::new(cb));
     }
 
-    pub async fn emit_seeked(&self, position: TimeInUs) -> Result<()> {
+    pub async fn emit_seeked(&self, position: Time) -> Result<()> {
         self.server.seeked(position).await
     }
 
@@ -1608,11 +1614,11 @@
         self.server.properties_changed(Property::Volume).await
     }
 
-    pub fn position(&self) -> TimeInUs {
+    pub fn position(&self) -> Time {
         self.server.imp().position.get()
     }
 
-    pub async fn set_position(&self, position: TimeInUs) -> Result<()> {
+    pub async fn set_position(&self, position: Time) -> Result<()> {
         if self.position() == position {
             return Ok(());
         }
@@ -1746,7 +1752,7 @@
     shuffle: bool,
     metadata: Metadata,
     volume: Volume,
-    position: TimeInUs,
+    position: Time,
     minimum_rate: PlaybackRate,
     maximum_rate: PlaybackRate,
     can_go_next: bool,
@@ -1842,7 +1848,7 @@
         self
     }
 
-    pub fn position(mut self, position: TimeInUs) -> Self {
+    pub fn position(mut self, position: Time) -> Self {
         self.position = position;
         self
     }
diff --git a/src/mpris_server/playlist.rs.html b/src/mpris_server/playlist.rs.html
index 662d599..c781819 100644
--- a/src/mpris_server/playlist.rs.html
+++ b/src/mpris_server/playlist.rs.html
@@ -97,6 +97,26 @@
 97
 98
 99
+100
+101
+102
+103
+104
+105
+106
+107
+108
+109
+110
+111
+112
+113
+114
+115
+116
+117
+118
+119
 
use serde::Serialize;
 use zbus::zvariant::{ObjectPath, Type, Value};
 
@@ -115,6 +135,16 @@
     pub icon: Uri,
 }
 
+impl From<MaybePlaylist> for Option<Playlist> {
+    fn from(mp: MaybePlaylist) -> Self {
+        if mp.valid {
+            Some(mp.playlist)
+        } else {
+            None
+        }
+    }
+}
+
 impl<'a> From<Playlist> for Value<'a> {
     fn from(p: Playlist) -> Self {
         Value::from((p.id, p.name, p.icon))
@@ -143,7 +173,7 @@
 
 impl MaybePlaylist {
     /// Construct a valid `MaybePlaylist` from the given playlist.
-    pub fn some(playlist: Playlist) -> Self {
+    pub fn just(playlist: Playlist) -> Self {
         Self {
             valid: true,
             playlist,
@@ -153,7 +183,7 @@
     /// Construct a `MaybePlaylist` that contains invalid/no playlist.
     ///
     /// The playlist ID will be set to "/", and the name and icon will be empty.
-    pub fn none() -> Self {
+    pub fn nothing() -> Self {
         Self {
             valid: false,
             playlist: Playlist {
@@ -163,19 +193,29 @@
             },
         }
     }
+
+    /// Returns [Some] if this structure contains a valid playlist, otherwise
+    /// [None].
+    pub fn get(&self) -> Option<&Playlist> {
+        if self.valid {
+            Some(&self.playlist)
+        } else {
+            None
+        }
+    }
 }
 
 impl From<Playlist> for MaybePlaylist {
     fn from(playlist: Playlist) -> Self {
-        Self::some(playlist)
+        Self::just(playlist)
     }
 }
 
 impl From<Option<Playlist>> for MaybePlaylist {
     fn from(opt: Option<Playlist>) -> Self {
         match opt {
-            Some(playlist) => Self::some(playlist),
-            None => Self::none(),
+            Some(playlist) => Self::just(playlist),
+            None => Self::nothing(),
         }
     }
 }
diff --git a/src/mpris_server/playlist_ordering.rs.html b/src/mpris_server/playlist_ordering.rs.html
index 14f251b..2216f95 100644
--- a/src/mpris_server/playlist_ordering.rs.html
+++ b/src/mpris_server/playlist_ordering.rs.html
@@ -49,6 +49,7 @@
 49
 50
 51
+52
 
use std::fmt;
 
 use serde::Deserialize;
@@ -78,7 +79,8 @@
 }
 
 impl PlaylistOrdering {
-    pub fn as_str(&self) -> &'static str {
+    /// Returns the string representation of this playlist ordering.
+    pub fn as_str(&self) -> &'static str {
         match self {
             Self::Alphabetical => "Alphabetical",
             Self::CreationDate => "Created",
diff --git a/src/mpris_server/server.rs.html b/src/mpris_server/server.rs.html
index f75f11a..f643499 100644
--- a/src/mpris_server/server.rs.html
+++ b/src/mpris_server/server.rs.html
@@ -918,28 +918,14 @@
 918
 919
 920
-921
-922
-923
-924
-925
-926
-927
-928
-929
-930
-931
-932
-933
-934
 
use std::{
     collections::HashMap,
     fmt,
-    sync::{Arc, OnceLock},
+    sync::{Arc, Mutex},
 };
 
+use async_lock::OnceCell;
 use enumflags2::BitFlags;
-use futures_util::lock::Mutex;
 use zbus::{
     dbus_interface, fdo,
     names::WellKnownName,
@@ -950,7 +936,7 @@
 use crate::{
     LoopStatus, MaybePlaylist, Metadata, PlaybackRate, PlaybackStatus, PlayerInterface, Playlist,
     PlaylistId, PlaylistOrdering, PlaylistsInterface, PlaylistsProperty, Property, RootInterface,
-    TimeInUs, TrackId, TrackListInterface, TrackListProperty, Uri, Volume,
+    Time, TrackId, TrackListInterface, TrackListProperty, Uri, Volume,
 };
 
 const OBJECT_PATH: ObjectPath<'static> =
@@ -963,7 +949,7 @@
 #[dbus_interface(name = "org.mpris.MediaPlayer2")]
 impl<T> RawRootInterface<T>
 where
-    T: Send + Sync + RootInterface + 'static,
+    T: RootInterface + 'static,
 {
     async fn raise(&self) -> fdo::Result<()> {
         self.imp.raise().await
@@ -1031,7 +1017,7 @@
 #[dbus_interface(name = "org.mpris.MediaPlayer2.Player")]
 impl<T> RawPlayerInterface<T>
 where
-    T: Send + Sync + PlayerInterface + 'static,
+    T: PlayerInterface + 'static,
 {
     async fn next(&self) -> fdo::Result<()> {
         self.imp.next().await
@@ -1057,11 +1043,11 @@
         self.imp.play().await
     }
 
-    async fn seek(&self, offset: TimeInUs) -> fdo::Result<()> {
+    async fn seek(&self, offset: Time) -> fdo::Result<()> {
         self.imp.seek(offset).await
     }
 
-    async fn set_position(&self, track_id: TrackId, position: TimeInUs) -> fdo::Result<()> {
+    async fn set_position(&self, track_id: TrackId, position: Time) -> fdo::Result<()> {
         self.imp.set_position(track_id, position).await
     }
 
@@ -1070,7 +1056,7 @@
     }
 
     #[dbus_interface(signal)]
-    async fn seeked(ctxt: &SignalContext<'_>, position: TimeInUs) -> Result<()>;
+    async fn seeked(ctxt: &SignalContext<'_>, position: Time) -> Result<()>;
 
     #[dbus_interface(property)]
     async fn playback_status(&self) -> fdo::Result<PlaybackStatus> {
@@ -1123,7 +1109,7 @@
     }
 
     #[dbus_interface(property)]
-    async fn position(&self) -> fdo::Result<TimeInUs> {
+    async fn position(&self) -> fdo::Result<Time> {
         self.imp.position().await
     }
 
@@ -1175,7 +1161,7 @@
 #[dbus_interface(name = "org.mpris.MediaPlayer2.TrackList")]
 impl<T> RawTrackListInterface<T>
 where
-    T: TrackListInterface + Send + Sync + 'static,
+    T: TrackListInterface + 'static,
 {
     async fn get_tracks_metadata(&self, track_ids: Vec<TrackId>) -> fdo::Result<Vec<Metadata>> {
         self.imp.get_tracks_metadata(track_ids).await
@@ -1240,7 +1226,7 @@
 #[dbus_interface(name = "org.mpris.MediaPlayer2.Playlists")]
 impl<T> RawPlaylistsInterface<T>
 where
-    T: PlaylistsInterface + Send + Sync + 'static,
+    T: PlaylistsInterface + 'static,
 {
     async fn activate_playlist(&self, playlist_id: PlaylistId) -> fdo::Result<()> {
         self.imp.activate_playlist(playlist_id).await
@@ -1289,9 +1275,9 @@
 /// [`Server::playlists_properties_changed`].
 pub struct Server<T>
 where
-    T: PlayerInterface + Send + Sync + 'static,
+    T: PlayerInterface + 'static,
 {
-    connection: OnceLock<Connection>,
+    connection: OnceCell<Connection>,
     #[allow(clippy::type_complexity)]
     connection_init:
         Mutex<Option<Box<dyn FnOnce() -> Result<ConnectionBuilder<'static>> + Send + Sync>>>,
@@ -1300,7 +1286,7 @@
 
 impl<T> fmt::Debug for Server<T>
 where
-    T: PlayerInterface + Send + Sync + 'static,
+    T: PlayerInterface + 'static,
 {
     fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
         f.debug_struct("Server").finish()
@@ -1316,9 +1302,9 @@
     };
 }
 
-macro_rules! handle_property {
-    ($property_ident:ident, $property_type:ident, $source:ident => $($map:ident, $property:ident, $getter:ident);*) => {
-        match $property_ident {
+macro_rules! insert_property {
+    ($item:ident, $property_type:ident, $source:ident => $($map:ident, $property:ident, $getter:ident);*) => {
+        match $item {
             $(
                 $property_type::$property => {
                     let value = Value::new($source.imp.$getter().await?);
@@ -1331,12 +1317,14 @@
 
 impl<T> Server<T>
 where
-    T: PlayerInterface + Send + Sync + 'static,
+    T: PlayerInterface + 'static,
 {
     /// Creates a new [`Server`] with the given bus name suffix and
     /// implementation, which must implement [`RootInterface`] and
     /// [`PlayerInterface`].
     ///
+    /// To start the connection, [`Server::init`] must be called.
+    ///
     /// The resulting bus name will be
     /// `org.mpris.MediaPlayer2.<bus_name_suffix>`, where
     /// `<bus_name_suffix>`must be a unique identifier, such as one based on a
@@ -1353,9 +1341,14 @@
         Self::new_inner(bus_name_suffix, imp, |builder, _| Ok(builder))
     }
 
-    pub async fn init(&self) -> Result<()> {
-        // Ensure the connection is initialized.
-        self.get_or_init_connection().await?;
+    /// Initializes the connection.
+    ///
+    /// This is a no-op if the connection has already been initialized.
+    ///
+    /// This is also called automatically when emitting signals and properties
+    /// changed.
+    pub async fn init(&self) -> Result<()> {
+        self.get_or_init_connection().await?;
         Ok(())
     }
 
@@ -1364,7 +1357,7 @@
         &self.imp
     }
 
-    signal_delegate!(RawPlayerInterface<T>, seeked(position: TimeInUs));
+    signal_delegate!(RawPlayerInterface<T>, seeked(position: Time));
 
     /// Emits the `PropertiesChanged` signal for the given properties.
     pub async fn properties_changed(
@@ -1374,7 +1367,7 @@
         let mut root_changed = HashMap::new();
         let mut player_changed = HashMap::new();
         for property in properties.into().iter() {
-            handle_property!(
+            insert_property!(
                 property, Property, self =>
                 root_changed, CanQuit, can_quit;
                 root_changed, Fullscreen, fullscreen;
@@ -1448,27 +1441,21 @@
         };
 
         Ok(Self {
-            connection: OnceLock::new(),
+            connection: OnceCell::new(),
             connection_init: Mutex::new(Some(Box::new(connection_init))),
             imp,
         })
     }
 
     async fn get_or_init_connection(&self) -> Result<&Connection> {
-        // Lock before checking if the connection is already initialized to
-        // prevent reading while it is being initialized.
-        let mut connection_init = self.connection_init.lock().await;
-
-        if let Some(connection) = self.connection.get() {
-            return Ok(connection);
-        }
-
-        let init_fn = connection_init.take().unwrap();
-        let connection = init_fn()?.build().await?;
-        self.connection.set(connection).unwrap();
-
-        Ok(self.connection.get().unwrap())
-    }
+        self.connection
+            .get_or_try_init(|| async {
+                let connection_init = self.connection_init.lock().unwrap().take().unwrap();
+                let connection = connection_init()?.build().await?;
+                Ok(connection)
+            })
+            .await
+    }
 
     async fn interface_ref<I: zbus::Interface>(&self) -> Result<InterfaceRef<I>> {
         self.get_or_init_connection()
@@ -1504,7 +1491,7 @@
 
 impl<T> Server<T>
 where
-    T: TrackListInterface + Send + Sync + 'static,
+    T: TrackListInterface + 'static,
 {
     /// Creates a new [`Server`] with the given bus name suffix and
     /// implementation, which must implement [`TrackListInterface`] in addition
@@ -1513,12 +1500,7 @@
     /// See also [`Server::new`].
     pub fn new_with_track_list(bus_name_suffix: &str, imp: T) -> Result<Self> {
         Self::new_inner(bus_name_suffix, imp, |builder, imp| {
-            builder.serve_at(
-                OBJECT_PATH,
-                RawTrackListInterface {
-                    imp: Arc::clone(&imp),
-                },
-            )
+            builder.serve_at(OBJECT_PATH, RawTrackListInterface { imp })
         })
     }
 
@@ -1534,7 +1516,7 @@
     ) -> Result<()> {
         let mut changed = HashMap::new();
         for property in properties.into().iter() {
-            handle_property!(
+            insert_property!(
                 property, TrackListProperty, self =>
                 changed, Tracks, tracks;
                 changed, CanEditTracks, can_edit_tracks
@@ -1552,7 +1534,7 @@
 
 impl<T> Server<T>
 where
-    T: PlaylistsInterface + Send + Sync + 'static,
+    T: PlaylistsInterface + 'static,
 {
     /// Creates a new [`Server`] with the given bus name suffix and
     /// implementation, which must implement [`PlaylistsInterface`] in addition
@@ -1561,12 +1543,7 @@
     /// See also [`Server::new`].
     pub fn new_with_playlists(bus_name_suffix: &str, imp: T) -> Result<Self> {
         Self::new_inner(bus_name_suffix, imp, |builder, imp| {
-            builder.serve_at(
-                OBJECT_PATH,
-                RawPlaylistsInterface {
-                    imp: Arc::clone(&imp),
-                },
-            )
+            builder.serve_at(OBJECT_PATH, RawPlaylistsInterface { imp })
         })
     }
 
@@ -1579,7 +1556,7 @@
     ) -> Result<()> {
         let mut changed = HashMap::new();
         for property in properties.into().iter() {
-            handle_property!(
+            insert_property!(
                 property, PlaylistsProperty, self =>
                 changed, PlaylistCount, playlist_count;
                 changed, Orderings, orderings;
@@ -1598,7 +1575,7 @@
 
 impl<T> Server<T>
 where
-    T: TrackListInterface + PlaylistsInterface + Send + Sync + 'static,
+    T: TrackListInterface + PlaylistsInterface + 'static,
 {
     /// Creates a new [`Server`] with the given bus name suffix and
     /// implementation, which must implement [`TrackListInterface`] and
@@ -1615,12 +1592,7 @@
                         imp: Arc::clone(&imp),
                     },
                 )?
-                .serve_at(
-                    OBJECT_PATH,
-                    RawPlaylistsInterface {
-                        imp: Arc::clone(&imp),
-                    },
-                )
+                .serve_at(OBJECT_PATH, RawPlaylistsInterface { imp })
         })
     }
 }
@@ -1711,11 +1683,11 @@
             unreachable!()
         }
 
-        async fn seek(&self, _offset: TimeInUs) -> fdo::Result<()> {
+        async fn seek(&self, _offset: Time) -> fdo::Result<()> {
             unreachable!()
         }
 
-        async fn set_position(&self, _track_id: TrackId, _position: TimeInUs) -> fdo::Result<()> {
+        async fn set_position(&self, _track_id: TrackId, _position: Time) -> fdo::Result<()> {
             unreachable!()
         }
 
@@ -1763,7 +1735,7 @@
             unreachable!()
         }
 
-        async fn position(&self) -> fdo::Result<TimeInUs> {
+        async fn position(&self) -> fdo::Result<Time> {
             unreachable!()
         }
 
diff --git a/src/mpris_server/time.rs.html b/src/mpris_server/time.rs.html
new file mode 100644
index 0000000..de12c86
--- /dev/null
+++ b/src/mpris_server/time.rs.html
@@ -0,0 +1,559 @@
+time.rs - source
1
+2
+3
+4
+5
+6
+7
+8
+9
+10
+11
+12
+13
+14
+15
+16
+17
+18
+19
+20
+21
+22
+23
+24
+25
+26
+27
+28
+29
+30
+31
+32
+33
+34
+35
+36
+37
+38
+39
+40
+41
+42
+43
+44
+45
+46
+47
+48
+49
+50
+51
+52
+53
+54
+55
+56
+57
+58
+59
+60
+61
+62
+63
+64
+65
+66
+67
+68
+69
+70
+71
+72
+73
+74
+75
+76
+77
+78
+79
+80
+81
+82
+83
+84
+85
+86
+87
+88
+89
+90
+91
+92
+93
+94
+95
+96
+97
+98
+99
+100
+101
+102
+103
+104
+105
+106
+107
+108
+109
+110
+111
+112
+113
+114
+115
+116
+117
+118
+119
+120
+121
+122
+123
+124
+125
+126
+127
+128
+129
+130
+131
+132
+133
+134
+135
+136
+137
+138
+139
+140
+141
+142
+143
+144
+145
+146
+147
+148
+149
+150
+151
+152
+153
+154
+155
+156
+157
+158
+159
+160
+161
+162
+163
+164
+165
+166
+167
+168
+169
+170
+171
+172
+173
+174
+175
+176
+177
+178
+179
+180
+181
+182
+183
+184
+185
+186
+187
+188
+189
+190
+191
+192
+193
+194
+195
+196
+197
+198
+199
+200
+201
+202
+203
+204
+205
+206
+207
+208
+209
+210
+211
+212
+213
+214
+215
+216
+217
+218
+219
+220
+221
+222
+223
+224
+225
+226
+227
+228
+229
+230
+231
+232
+233
+234
+235
+236
+237
+238
+239
+240
+241
+242
+243
+244
+245
+246
+247
+248
+249
+250
+251
+252
+253
+254
+255
+256
+257
+258
+259
+260
+261
+262
+263
+264
+265
+266
+267
+268
+269
+270
+271
+272
+273
+274
+275
+276
+277
+278
+279
+
use std::{
+    fmt,
+    ops::{Add, AddAssign, Sub, SubAssign},
+};
+
+use serde::{Deserialize, Serialize};
+use zbus::zvariant::{Type, Value};
+
+/// A time which can be negative.
+#[derive(
+    Default, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash, Serialize, Deserialize, Type,
+)]
+#[serde(transparent)]
+#[doc(alias = "Time_In_Us")]
+pub struct Time(i64);
+
+impl fmt::Debug for Time {
+    fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
+        write!(f, "{}µs", self.0)
+    }
+}
+
+impl Time {
+    /// A time of zero.
+    ///
+    /// # Examples
+    /// ```
+    /// use mpris_server::Time;
+    ///
+    /// let time = Time::ZERO;
+    /// assert!(time.is_zero());
+    /// assert_eq!(time.as_micros(), 0);
+    /// ```
+    pub const ZERO: Self = Self::from_micros(0);
+
+    /// The minimum time.
+    pub const MIN: Self = Self::from_micros(i64::MIN);
+
+    /// The maximum time.
+    pub const MAX: Self = Self::from_micros(i64::MAX);
+
+    /// Creates a new `Time` from the specified number of whole seconds.
+    #[inline]
+    pub const fn from_secs(secs: i64) -> Self {
+        Self::from_micros(secs * 1_000_000)
+    }
+
+    /// Creates a new `Time` from the specified number of whole milliseconds.
+    #[inline]
+    pub const fn from_millis(millis: i64) -> Self {
+        Self::from_micros(millis * 1000)
+    }
+
+    /// Creates a new `Time` from the specified number of whole microseconds.
+    #[inline]
+    pub const fn from_micros(micros: i64) -> Self {
+        Self(micros)
+    }
+
+    /// Creates a new `Time` from the specified number of whole nanoseconds.
+    #[inline]
+    pub const fn from_nanos(nanos: i64) -> Self {
+        Self::from_micros(nanos / 1000)
+    }
+
+    /// Returns the number of *whole* seconds contained by this `Time`.
+    #[inline]
+    pub const fn as_secs(&self) -> i64 {
+        self.as_micros() / 1_000_000
+    }
+
+    /// Returns the number of *whole* milliseconds contained by this `Time`.
+    #[inline]
+    pub const fn as_millis(&self) -> i64 {
+        self.as_micros() / 1000
+    }
+
+    /// Returns the number of *whole* microseconds contained by this `Time`.
+    #[inline]
+    pub const fn as_micros(&self) -> i64 {
+        self.0
+    }
+
+    /// Returns the number of *whole* nanoseconds contained by this `Time`.
+    #[inline]
+    pub const fn as_nanos(&self) -> i64 {
+        self.as_micros() * 1000
+    }
+
+    /// Returns true if this `Time` is zero.
+    ///
+    /// # Examples
+    /// ```
+    /// use mpris_server::Time;
+    ///
+    /// assert_eq!(Time::ZERO.is_zero(), true);
+    /// assert_eq!(Time::from_micros(1).is_zero(), false);
+    /// ```
+    #[inline]
+    pub const fn is_zero(&self) -> bool {
+        self.0 == 0
+    }
+
+    /// Returns true if this `Time` is negative.
+    ///
+    /// # Examples
+    /// ```
+    /// use mpris_server::Time;
+    ///
+    /// assert_eq!(Time::ZERO.is_negative(), false);
+    /// assert_eq!(Time::from_micros(-1).is_negative(), true);
+    /// assert_eq!(Time::from_micros(1).is_negative(), false);
+    /// ```
+    #[inline]
+    pub const fn is_negative(&self) -> bool {
+        self.0 < 0
+    }
+
+    /// Returns true if this `Time` is positive.
+    ///
+    /// # Examples
+    /// ```
+    /// use mpris_server::Time;
+    ///
+    /// assert_eq!(Time::ZERO.is_positive(), false);
+    /// assert_eq!(Time::from_micros(1).is_positive(), true);
+    /// assert_eq!(Time::from_micros(-1).is_positive(), false);
+    /// ```
+    #[inline]
+    pub const fn is_positive(&self) -> bool {
+        self.0 > 0
+    }
+
+    /// Returns the time as an absolute (non-negative) value.
+    ///
+    /// # Examples
+    /// ```
+    /// use mpris_server::Time;
+    ///
+    /// assert_eq!(Time::ZERO.abs(), Time::ZERO);
+    /// assert_eq!(Time::from_micros(-1).abs(), Time::from_micros(1));
+    /// assert_eq!(Time::from_micros(1).abs(), Time::from_micros(1));
+    /// ```
+    #[inline]
+    pub const fn abs(&self) -> Self {
+        Self(self.0.abs())
+    }
+
+    /// Checked `Time` addition. Computes `self + other`, returning [`None`]
+    /// if overflow occurred.
+    ///
+    /// # Examples
+    /// ```
+    /// use mpris_server::Time;
+    ///
+    /// assert_eq!(
+    ///     Time::from_micros(1).checked_add(Time::from_micros(1)),
+    ///     Some(Time::from_micros(2))
+    /// );
+    /// assert_eq!(Time::MAX.checked_add(Time::from_micros(1)), None);
+    /// ```
+    #[inline]
+    pub const fn checked_add(self, other: Self) -> Option<Self> {
+        match self.0.checked_add(other.0) {
+            Some(inner) => Some(Self(inner)),
+            None => None,
+        }
+    }
+
+    /// Checked `Time` subtraction. Computes `self - other`, returning [`None`]
+    /// if overflow occurred.
+    ///
+    /// # Examples
+    /// ```
+    /// use mpris_server::Time;
+    ///
+    /// assert_eq!(
+    ///     Time::from_micros(2).checked_sub(Time::from_micros(1)),
+    ///     Some(Time::from_micros(1))
+    /// );
+    /// assert_eq!(Time::MIN.checked_sub(Time::from_micros(1)), None);
+    /// ```
+    #[inline]
+    pub const fn checked_sub(self, other: Self) -> Option<Self> {
+        match self.0.checked_sub(other.0) {
+            Some(inner) => Some(Self(inner)),
+            None => None,
+        }
+    }
+
+    /// Saturating `Time` addition. Computes `self + other`, returning
+    /// [`Time::MAX`] if overflow occurred.
+    ///
+    /// # Examples
+    /// ```
+    /// use mpris_server::Time;
+    ///
+    /// assert_eq!(
+    ///     Time::from_micros(1).saturating_add(Time::from_micros(1)),
+    ///     Time::from_micros(2)
+    /// );
+    /// assert_eq!(Time::MAX.saturating_add(Time::from_micros(1)), Time::MAX);
+    /// ```
+    #[inline]
+    pub const fn saturating_add(self, other: Self) -> Self {
+        match self.checked_add(other) {
+            Some(inner) => inner,
+            None => Self::MAX,
+        }
+    }
+
+    /// Saturating `Time` subtraction. Computes `self - other`, returning
+    /// [`Time::MIN`] if overflow occurred.
+    ///
+    /// # Examples
+    /// ```
+    /// use mpris_server::Time;
+    ///
+    /// assert_eq!(
+    ///     Time::from_micros(2).saturating_sub(Time::from_micros(1)),
+    ///     Time::from_micros(1)
+    /// );
+    /// assert_eq!(Time::MIN.saturating_sub(Time::from_micros(1)), Time::MIN);
+    /// ```
+    #[inline]
+    pub const fn saturating_sub(self, other: Self) -> Self {
+        match self.checked_sub(other) {
+            Some(inner) => inner,
+            None => Self::MIN,
+        }
+    }
+}
+
+impl Add for Time {
+    type Output = Self;
+
+    #[inline]
+    fn add(self, other: Self) -> Self {
+        self.checked_add(other).expect("overflow when adding times")
+    }
+}
+
+impl AddAssign for Time {
+    fn add_assign(&mut self, rhs: Self) {
+        *self = *self + rhs;
+    }
+}
+
+impl Sub for Time {
+    type Output = Self;
+
+    #[inline]
+    fn sub(self, other: Self) -> Self {
+        self.checked_sub(other)
+            .expect("overflow when subtracting times")
+    }
+}
+
+impl SubAssign for Time {
+    fn sub_assign(&mut self, rhs: Self) {
+        *self = *self - rhs;
+    }
+}
+
+impl<'a> From<Time> for Value<'a> {
+    fn from(time: Time) -> Self {
+        Value::new(time.0)
+    }
+}
+
+#[cfg(test)]
+mod tests {
+    use super::*;
+
+    #[test]
+    fn valid_signature() {
+        assert_eq!(Time::signature(), "x");
+    }
+}
+
\ No newline at end of file diff --git a/src/mpris_server/track_id.rs.html b/src/mpris_server/track_id.rs.html index a01c608..7b7bed2 100644 --- a/src/mpris_server/track_id.rs.html +++ b/src/mpris_server/track_id.rs.html @@ -102,7 +102,8 @@ 102 103 104 -
use std::fmt;
+105
+
use std::{fmt, ops};
 
 use serde::{de, Deserialize, Deserializer, Serialize};
 use zbus::zvariant::{Error, ObjectPath, Result, Type, Value};
@@ -129,6 +130,7 @@
 /// to the specification where tracks are exported to D-Bus with an
 /// interface similar to org.gnome.UPnP.MediaItem2.
 #[derive(Debug, Default, Clone, PartialEq, Eq, Hash, Serialize, Type)]
+#[serde(transparent)]
 #[doc(alias = "Track_Id")]
 pub struct TrackId(ObjectPath<'static>);
 
@@ -142,7 +144,7 @@
     }
 }
 
-impl std::ops::Deref for TrackId {
+impl ops::Deref for TrackId {
     type Target = ObjectPath<'static>;
 
     fn deref(&self) -> &Self::Target {
@@ -150,13 +152,13 @@
     }
 }
 
-impl std::convert::From<TrackId> for ObjectPath<'static> {
+impl From<TrackId> for ObjectPath<'static> {
     fn from(o: TrackId) -> Self {
         o.into_inner()
     }
 }
 
-impl std::convert::From<TrackId> for Value<'static> {
+impl From<TrackId> for Value<'static> {
     fn from(o: TrackId) -> Self {
         o.into_inner().into()
     }
@@ -168,7 +170,7 @@
     }
 }
 
-impl<'a> std::convert::From<ObjectPath<'a>> for TrackId {
+impl<'a> From<ObjectPath<'a>> for TrackId {
     fn from(o: ObjectPath<'a>) -> Self {
         TrackId(o.into_owned())
     }
@@ -201,8 +203,8 @@
     }
 }
 
-impl std::fmt::Display for TrackId {
-    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
+impl fmt::Display for TrackId {
+    fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
         fmt::Display::fmt(&self.as_str(), f)
     }
 }