authentik_rust/models/
protocol_enum.rs1use crate::models;
12
13#[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