yandex_music.queue.queue_item#

class yandex_music.queue.queue_item.QueueItem(id: str, context: Optional[Context], modified: str, client: Optional[Client] = None)#

Bases: YandexMusicObject

Класс, представляющий очередь треков в списке очередей устройств.

id#

Уникальный идентификатор очереди.

Type

str

context#

Объект по которому построена очередь.

Type

yandex_music.Context | None

modified#

Дата последнего изменения.

Type

str

client#

Клиент Yandex Music.

Type

yandex_music.Client, optional

client: Optional[Client] = None#
context: Optional[Context]#
classmethod de_json(data: dict, client: Client) Optional[QueueItem]#

Десериализация объекта.

Parameters
  • data (dict) – Поля и значения десериализуемого объекта.

  • client (yandex_music.Client, optional) – Клиент Yandex Music.

Returns

Очередь в списке.

Return type

yandex_music.QueueItem

classmethod de_list(data: dict, client: Client) List[QueueItem]#

Десериализация списка объектов.

Parameters
  • data (list) – Список словарей с полями и значениями десериализуемого объекта.

  • client (yandex_music.Client, optional) – Клиент Yandex Music.

Returns

Список очередей всех устройств.

Return type

list из yandex_music.QueueItem

fetchQueue(*args, **kwargs) Optional[Queue]#

Псевдоним для fetch_queue

async fetchQueueAsync(*args, **kwargs) Optional[Queue]#

Псевдоним для fetch_queue_async

fetch_queue(*args, **kwargs) Optional[Queue]#

Сокращение для:

client.queue(id, *args, **kwargs)

async fetch_queue_async(*args, **kwargs) Optional[Queue]#

Сокращение для:

await client.queue(id, *args, **kwargs)

id: str#
modified: str#