1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
/*
* 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,
}
}
}