pub struct GetQueue {
pub player_id: PlayerId,
pub range: Option<RangeInclusive<usize>>,
}Expand description
Retrieve a player’s current queue of songs.
use heos::HeosConnection;
use heos::command::player::GetQueue;
use heos::data::player::PlayerId;
use heos::data::queue::QueuedTrackInfo;
use std::time::Duration;
let heos = HeosConnection::connect_any(Duration::from_secs(1)).await?;
let queue: Vec<QueuedTrackInfo> = heos.command(GetQueue {
player_id: PlayerId::from(42),
range: None,
}).await?;Fields§
§player_id: PlayerIdID of the player to retrieve.
range: Option<RangeInclusive<usize>>Range of songs to retrieve.
Zero-indexed.
This may be omitted (None), and defaults to all songs up to a maximum of 100 records per
response.
Trait Implementations§
Source§impl Command for GetQueue
impl Command for GetQueue
Source§type Response = Vec<QueuedTrackInfo>
type Response = Vec<QueuedTrackInfo>
Type of response that is expected when the command is sent. For commands that don’t care
about the expected response,
() can be used.Auto Trait Implementations§
impl Freeze for GetQueue
impl RefUnwindSafe for GetQueue
impl Send for GetQueue
impl Sync for GetQueue
impl Unpin for GetQueue
impl UnsafeUnpin for GetQueue
impl UnwindSafe for GetQueue
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more