yandex_music.search.search_result#
- class yandex_music.search.search_result.SearchResult(type: str, total: int, per_page: int, order: int, results: List[Union[Track, Artist, Album, Playlist, Video]], client: Optional[Client] = None)#
Bases:
YandexMusicObject
Класс, представляющий результаты поиска.
Note
Значения поля type: track, artist, playlist, album, video.
- type#
Тип результата.
- Type
str
- total#
Количество результатов.
- Type
int
- per_page#
Максимальное количество результатов на странице.
- Type
int
- order#
Позиция блока.
- Type
int
- results#
Результаты поиска.
- Type
list
изyandex_music.Track
|yandex_music.Artist
|yandex_music.Album
|yandex_music.Playlist
|yandex_music.Video
- client#
Клиент Yandex Music.
- Type
yandex_music.Client
, optional
- classmethod de_json(data: dict, client: Client, type_: str = None) Optional[SearchResult] #
Десериализация объекта.
- Parameters
data (
dict
) – Поля и значения десериализуемого объекта.type (
str
, optional) – Тип результата.client (
yandex_music.Client
, optional) – Клиент Yandex Music.
- Returns
Результаты поиска.
- Return type
yandex_music.SearchResult
- order: int#
- per_page: int#
- total: int#
- type: str#