authentik_rust/models/
geoip_binding_enum.rs

1/*
2 * authentik
3 *
4 * Making authentication simple.
5 *
6 * The version of the OpenAPI document: 2024.2.1
7 * Contact: hello@goauthentik.io
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12
13/// GeoipBindingEnum : * `no_binding` - No Binding * `bind_continent` - Bind Continent * `bind_continent_country` - Bind Continent Country * `bind_continent_country_city` - Bind Continent Country City
14/// * `no_binding` - No Binding * `bind_continent` - Bind Continent * `bind_continent_country` - Bind Continent Country * `bind_continent_country_city` - Bind Continent Country City
15#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
16pub enum GeoipBindingEnum {
17    #[serde(rename = "no_binding")]
18    NoBinding,
19    #[serde(rename = "bind_continent")]
20    BindContinent,
21    #[serde(rename = "bind_continent_country")]
22    BindContinentCountry,
23    #[serde(rename = "bind_continent_country_city")]
24    BindContinentCountryCity,
25
26}
27
28impl ToString for GeoipBindingEnum {
29    fn to_string(&self) -> String {
30        match self {
31            Self::NoBinding => String::from("no_binding"),
32            Self::BindContinent => String::from("bind_continent"),
33            Self::BindContinentCountry => String::from("bind_continent_country"),
34            Self::BindContinentCountryCity => String::from("bind_continent_country_city"),
35        }
36    }
37}
38
39impl Default for GeoipBindingEnum {
40    fn default() -> GeoipBindingEnum {
41        Self::NoBinding
42    }
43}
44