space_traders/models/
faction_symbols.rs

1//! Generated by: <https://openapi-generator.tech>
2//!
3//! Version of specification: `2.0.0`
4
5use serde::{Deserialize, Serialize};
6
7/// The symbol of the faction.
8#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
9pub enum FactionSymbols {
10    #[serde(rename = "COSMIC")]
11    Cosmic,
12    #[serde(rename = "VOID")]
13    Void,
14    #[serde(rename = "GALACTIC")]
15    Galactic,
16    #[serde(rename = "QUANTUM")]
17    Quantum,
18    #[serde(rename = "DOMINION")]
19    Dominion,
20    #[serde(rename = "ASTRO")]
21    Astro,
22    #[serde(rename = "CORSAIRS")]
23    Corsairs,
24    #[serde(rename = "OBSIDIAN")]
25    Obsidian,
26    #[serde(rename = "AEGIS")]
27    Aegis,
28    #[serde(rename = "UNITED")]
29    United,
30    #[serde(rename = "SOLITARY")]
31    Solitary,
32    #[serde(rename = "COBALT")]
33    Cobalt,
34    #[serde(rename = "OMEGA")]
35    Omega,
36    #[serde(rename = "ECHO")]
37    Echo,
38    #[serde(rename = "LORDS")]
39    Lords,
40    #[serde(rename = "CULT")]
41    Cult,
42    #[serde(rename = "ANCIENTS")]
43    Ancients,
44    #[serde(rename = "SHADOW")]
45    Shadow,
46    #[serde(rename = "ETHEREAL")]
47    Ethereal,
48}
49
50impl ToString for FactionSymbols {
51    fn to_string(&self) -> String {
52        match self {
53            Self::Cosmic => String::from("COSMIC"),
54            Self::Void => String::from("VOID"),
55            Self::Galactic => String::from("GALACTIC"),
56            Self::Quantum => String::from("QUANTUM"),
57            Self::Dominion => String::from("DOMINION"),
58            Self::Astro => String::from("ASTRO"),
59            Self::Corsairs => String::from("CORSAIRS"),
60            Self::Obsidian => String::from("OBSIDIAN"),
61            Self::Aegis => String::from("AEGIS"),
62            Self::United => String::from("UNITED"),
63            Self::Solitary => String::from("SOLITARY"),
64            Self::Cobalt => String::from("COBALT"),
65            Self::Omega => String::from("OMEGA"),
66            Self::Echo => String::from("ECHO"),
67            Self::Lords => String::from("LORDS"),
68            Self::Cult => String::from("CULT"),
69            Self::Ancients => String::from("ANCIENTS"),
70            Self::Shadow => String::from("SHADOW"),
71            Self::Ethereal => String::from("ETHEREAL"),
72        }
73    }
74}