authentik-rust 0.0.1

Making authentication simple.
Documentation
/*
 * authentik
 *
 * Making authentication simple.
 *
 * The version of the OpenAPI document: 2024.2.1
 * Contact: hello@goauthentik.io
 * Generated by: https://openapi-generator.tech
 */

use crate::models;

/// DeviceClassesEnum : * `static` - Static * `totp` - TOTP * `webauthn` - WebAuthn * `duo` - Duo * `sms` - SMS
/// * `static` - Static * `totp` - TOTP * `webauthn` - WebAuthn * `duo` - Duo * `sms` - SMS
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum DeviceClassesEnum {
    #[serde(rename = "static")]
    Static,
    #[serde(rename = "totp")]
    Totp,
    #[serde(rename = "webauthn")]
    Webauthn,
    #[serde(rename = "duo")]
    Duo,
    #[serde(rename = "sms")]
    Sms,

}

impl ToString for DeviceClassesEnum {
    fn to_string(&self) -> String {
        match self {
            Self::Static => String::from("static"),
            Self::Totp => String::from("totp"),
            Self::Webauthn => String::from("webauthn"),
            Self::Duo => String::from("duo"),
            Self::Sms => String::from("sms"),
        }
    }
}

impl Default for DeviceClassesEnum {
    fn default() -> DeviceClassesEnum {
        Self::Static
    }
}