use serde::{Deserialize, Serialize};
use strum::{Display, EnumString, IntoStaticStr};
#[derive(Clone, Serialize, Deserialize, Copy, PartialEq, Eq, Debug, IntoStaticStr)]
pub enum CopyrightType {
#[strum(serialize = "P")]
#[serde(rename = "P")]
Performance,
#[strum(serialize = "C")]
#[serde(rename = "C")]
Copyright,
}
#[derive(Clone, Serialize, Deserialize, Copy, PartialEq, Eq, Debug, IntoStaticStr)]
#[serde(rename_all = "snake_case")]
#[strum(serialize_all = "snake_case")]
pub enum AlbumType {
Album,
Single,
AppearsOn,
Compilation,
}
#[derive(
Clone, Serialize, Deserialize, Copy, PartialEq, Eq, Debug, Display, EnumString, IntoStaticStr,
)]
#[serde(rename_all = "snake_case")]
#[strum(serialize_all = "snake_case")]
pub enum Type {
Artist,
Album,
Track,
Playlist,
User,
Show,
Episode,
Collection,
Collectionyourepisodes, }
#[derive(Clone, Serialize, Deserialize, Copy, PartialEq, Eq, Debug, IntoStaticStr)]
#[serde(rename_all = "snake_case")]
#[strum(serialize_all = "snake_case")]
pub enum AdditionalType {
Track,
Episode,
}
#[derive(Clone, Serialize, Deserialize, Copy, PartialEq, Eq, Debug, IntoStaticStr)]
#[serde(rename_all = "snake_case")]
#[strum(serialize_all = "snake_case")]
pub enum CurrentlyPlayingType {
Track,
Episode,
#[strum(serialize = "ad")]
#[serde(rename = "ad")]
Advertisement,
Unknown,
}
#[derive(Clone, Serialize, Deserialize, Copy, PartialEq, Eq, Debug, IntoStaticStr)]
#[serde(rename_all = "snake_case")]
#[strum(serialize_all = "snake_case")]
pub enum SearchType {
Artist,
Album,
Track,
Playlist,
Show,
Episode,
}
#[derive(Clone, Serialize, Deserialize, Copy, PartialEq, Eq, Debug, IntoStaticStr)]
#[serde(rename_all = "snake_case")]
#[strum(serialize_all = "snake_case")]
pub enum SubscriptionLevel {
Premium,
#[serde(alias = "open")]
Free,
}
#[derive(Clone, Debug, Serialize, Deserialize, PartialEq, Eq, IntoStaticStr)]
#[strum(serialize_all = "snake_case")]
pub enum DeviceType {
Computer,
Tablet,
Smartphone,
Smartwatch,
Speaker,
#[serde(alias = "TV")]
Tv,
#[serde(alias = "AVR")]
Avr,
#[serde(alias = "STB")]
Stb,
AudioDongle,
GameConsole,
CastVideo,
CastAudio,
Automobile,
Unknown,
}
#[derive(Clone, Debug, Serialize, Deserialize, PartialEq, Eq, IntoStaticStr)]
#[serde(rename_all = "UPPERCASE")]
pub enum RecommendationsSeedType {
Artist,
Track,
Genre,
}