mirror of
https://github.com/librespot-org/librespot.git
synced 2024-12-28 17:21:52 +00:00
0e2686863a
* Expose all fields of recent protobufs * Add support for user-scoped playlists, user root playlists and playlist annotations * Convert messages with the Rust type system * Attempt to adhere to embargos (tracks and episodes scheduled for future release) * Return `Result`s with meaningful errors instead of panicking on `unwrap`s * Add foundation for future playlist editing * Up version in connection handshake to get all version-gated features
21 lines
459 B
Rust
21 lines
459 B
Rust
use std::fmt::Debug;
|
|
use std::ops::Deref;
|
|
|
|
use crate::util::from_repeated_message;
|
|
|
|
use librespot_core::spotify_id::FileId;
|
|
use librespot_protocol as protocol;
|
|
|
|
use protocol::metadata::VideoFile as VideoFileMessage;
|
|
|
|
#[derive(Debug, Clone)]
|
|
pub struct VideoFiles(pub Vec<FileId>);
|
|
|
|
impl Deref for VideoFiles {
|
|
type Target = Vec<FileId>;
|
|
fn deref(&self) -> &Self::Target {
|
|
&self.0
|
|
}
|
|
}
|
|
|
|
from_repeated_message!(VideoFileMessage, VideoFiles);
|