mirror of
https://github.com/librespot-org/librespot.git
synced 2024-12-18 17:11:53 +00:00
Fix examples
This commit is contained in:
parent
0e2686863a
commit
87f6a78d3e
2 changed files with 9 additions and 2 deletions
|
@ -30,7 +30,7 @@ async fn main() {
|
||||||
|
|
||||||
let plist = Playlist::get(&session, plist_uri).await.unwrap();
|
let plist = Playlist::get(&session, plist_uri).await.unwrap();
|
||||||
println!("{:?}", plist);
|
println!("{:?}", plist);
|
||||||
for track_id in plist.tracks {
|
for track_id in plist.tracks() {
|
||||||
let plist_track = Track::get(&session, track_id).await.unwrap();
|
let plist_track = Track::get(&session, track_id).await.unwrap();
|
||||||
println!("track: {} ", plist_track.name);
|
println!("track: {} ", plist_track.name);
|
||||||
}
|
}
|
||||||
|
|
|
@ -29,9 +29,16 @@ pub mod track;
|
||||||
mod util;
|
mod util;
|
||||||
pub mod video;
|
pub mod video;
|
||||||
|
|
||||||
use error::MetadataError;
|
pub use error::MetadataError;
|
||||||
use request::RequestResult;
|
use request::RequestResult;
|
||||||
|
|
||||||
|
pub use album::Album;
|
||||||
|
pub use artist::Artist;
|
||||||
|
pub use episode::Episode;
|
||||||
|
pub use playlist::Playlist;
|
||||||
|
pub use show::Show;
|
||||||
|
pub use track::Track;
|
||||||
|
|
||||||
#[async_trait]
|
#[async_trait]
|
||||||
pub trait Metadata: Send + Sized + 'static {
|
pub trait Metadata: Send + Sized + 'static {
|
||||||
type Message: protobuf::Message;
|
type Message: protobuf::Message;
|
||||||
|
|
Loading…
Reference in a new issue