authentik_rust/models/
protocol_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/// ProtocolEnum : * `rdp` - Rdp * `vnc` - Vnc * `ssh` - Ssh
14/// * `rdp` - Rdp * `vnc` - Vnc * `ssh` - Ssh
15#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
16pub enum ProtocolEnum {
17    #[serde(rename = "rdp")]
18    Rdp,
19    #[serde(rename = "vnc")]
20    Vnc,
21    #[serde(rename = "ssh")]
22    Ssh,
23
24}
25
26impl ToString for ProtocolEnum {
27    fn to_string(&self) -> String {
28        match self {
29            Self::Rdp => String::from("rdp"),
30            Self::Vnc => String::from("vnc"),
31            Self::Ssh => String::from("ssh"),
32        }
33    }
34}
35
36impl Default for ProtocolEnum {
37    fn default() -> ProtocolEnum {
38        Self::Rdp
39    }
40}
41