appwrite_openapi 1.0.0

AUTO-GENERATED client for Appwrite. For full API documentation and tutorials go to [https://appwrite.io/docs](https://appwrite.io/docs)
Documentation
/*
 * Appwrite
 *
 * Appwrite backend as a service cuts up to 70% of the time and costs required for building a modern application. We abstract and simplify common development tasks behind a REST APIs, to help you develop your app in a fast and secure way. For full API documentation and tutorials go to [https://appwrite.io/docs](https://appwrite.io/docs)
 *
 * The version of the OpenAPI document: 1.4.9
 * Contact: team@appwrite.io
 * Generated by: https://openapi-generator.tech
 */

/// Locale : Locale



#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
pub struct Locale {
    /// User IP address.
    #[serde(rename = "ip")]
    pub ip: String,
    /// Country code in [ISO 3166-1](http://en.wikipedia.org/wiki/ISO_3166-1) two-character format
    #[serde(rename = "countryCode")]
    pub country_code: String,
    /// Country name. This field support localization.
    #[serde(rename = "country")]
    pub country: String,
    /// Continent code. A two character continent code \"AF\" for Africa, \"AN\" for Antarctica, \"AS\" for Asia, \"EU\" for Europe, \"NA\" for North America, \"OC\" for Oceania, and \"SA\" for South America.
    #[serde(rename = "continentCode")]
    pub continent_code: String,
    /// Continent name. This field support localization.
    #[serde(rename = "continent")]
    pub continent: String,
    /// True if country is part of the European Union.
    #[serde(rename = "eu")]
    pub eu: bool,
    /// Currency code in [ISO 4217-1](http://en.wikipedia.org/wiki/ISO_4217) three-character format
    #[serde(rename = "currency")]
    pub currency: String,
}

impl Locale {
    /// Locale
    pub fn new(ip: String, country_code: String, country: String, continent_code: String, continent: String, eu: bool, currency: String) -> Locale {
        Locale {
            ip,
            country_code,
            country,
            continent_code,
            continent,
            eu,
            currency,
        }
    }
}