/*
 * Zernio API
 *
 * API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api
 *
 * The version of the OpenAPI document: 1.0.1
 * Contact: support@zernio.com
 * Generated by: https://openapi-generator.tech
 */

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

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct ListGoogleBusinessMedia200ResponseMediaItemsInner {
    /// Resource name
    #[serde(rename = "name", skip_serializing_if = "Option::is_none")]
    pub name: Option<String>,
    #[serde(rename = "mediaFormat", skip_serializing_if = "Option::is_none")]
    pub media_format: Option<MediaFormat>,
    #[serde(rename = "sourceUrl", skip_serializing_if = "Option::is_none")]
    pub source_url: Option<String>,
    /// Google-hosted URL
    #[serde(rename = "googleUrl", skip_serializing_if = "Option::is_none")]
    pub google_url: Option<String>,
    #[serde(rename = "thumbnailUrl", skip_serializing_if = "Option::is_none")]
    pub thumbnail_url: Option<String>,
    #[serde(rename = "description", skip_serializing_if = "Option::is_none")]
    pub description: Option<String>,
    #[serde(rename = "createTime", skip_serializing_if = "Option::is_none")]
    pub create_time: Option<String>,
    #[serde(
        rename = "locationAssociation",
        skip_serializing_if = "Option::is_none"
    )]
    pub location_association:
        Option<Box<models::ListGoogleBusinessMedia200ResponseMediaItemsInnerLocationAssociation>>,
}

impl ListGoogleBusinessMedia200ResponseMediaItemsInner {
    pub fn new() -> ListGoogleBusinessMedia200ResponseMediaItemsInner {
        ListGoogleBusinessMedia200ResponseMediaItemsInner {
            name: None,
            media_format: None,
            source_url: None,
            google_url: None,
            thumbnail_url: None,
            description: None,
            create_time: None,
            location_association: None,
        }
    }
}
///
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum MediaFormat {
    #[serde(rename = "PHOTO")]
    Photo,
    #[serde(rename = "VIDEO")]
    Video,
}

impl Default for MediaFormat {
    fn default() -> MediaFormat {
        Self::Photo
    }
}
