Skip to main content

orvanta_api/models/
licence_mode.rs

1/*
2 * Orvanta API
3 *
4 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5 *
6 * The version of the OpenAPI document: 6.3.0
7 * Contact: contact@orvanta.cloud
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// LicenceMode : how licences are held (#1750). `not_loaded`: the mode is not known yet, or the host licence no longer qualifies for managed mode; every workspace then resolves as Trial.
15/// how licences are held (#1750). `not_loaded`: the mode is not known yet, or the host licence no longer qualifies for managed mode; every workspace then resolves as Trial.
16#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
17pub enum LicenceMode {
18    #[serde(rename = "instance")]
19    Instance,
20    #[serde(rename = "managed")]
21    Managed,
22    #[serde(rename = "not_loaded")]
23    NotLoaded,
24
25}
26
27impl std::fmt::Display for LicenceMode {
28    fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result {
29        match self {
30            Self::Instance => write!(f, "instance"),
31            Self::Managed => write!(f, "managed"),
32            Self::NotLoaded => write!(f, "not_loaded"),
33        }
34    }
35}
36
37impl Default for LicenceMode {
38    fn default() -> LicenceMode {
39        Self::Instance
40    }
41}
42