tidalv2 0.3.0

Rust client library for TIDAL's v2 JSON:API - type-safe access to TIDAL's music catalog and streaming services
Documentation
/*
 * TIDAL API - Beta
 *
 * TIDAL API is a [JSON:API](https://jsonapi.org/) Web API that gives access to TIDAL functionality and data.
 *
 * The version of the OpenAPI document: 0.1.76
 *
 * Generated by: https://openapi-generator.tech
 */

use crate::models::*;
use serde::{Deserialize, Serialize};

/// ArtworkFile : Artwork files
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct ArtworkFile {
    /// Artwork file href
    #[serde(rename = "href")]
    pub href: String,
    #[serde(rename = "meta", skip_serializing_if = "Option::is_none")]
    pub meta: Option<ArtworkFileMeta>,
}

impl ArtworkFile {
    /// Artwork files
    pub fn new(href: String) -> ArtworkFile {
        ArtworkFile { href, meta: None }
    }
}

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct ArtworkFileMeta {
    /// Height (in pixels)
    #[serde(rename = "height")]
    pub height: i32,
    /// Width (in pixels)
    #[serde(rename = "width")]
    pub width: i32,
}