azisaba-graph 0.1.0-rc.3

An API for connecting and sharing data across Azisaba Network.
Documentation
/*
 * Azisaba Graph API
 *
 * An API for connecting and sharing data across Azisaba Network.
 *
 * The version of the OpenAPI document: 0.0.1
 * 
 * Generated by: https://openapi-generator.tech
 */

use crate::models;
use serde::{Deserialize, Serialize};

/// 
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum PunishmentType {
    #[serde(rename = "ban")]
    Ban,
    #[serde(rename = "tempBan")]
    TempBan,
    #[serde(rename = "ipBan")]
    IpBan,
    #[serde(rename = "tempIpBan")]
    TempIpBan,
    #[serde(rename = "mute")]
    Mute,
    #[serde(rename = "tempMute")]
    TempMute,
    #[serde(rename = "ipMute")]
    IpMute,
    #[serde(rename = "tempIpMute")]
    TempIpMute,
    #[serde(rename = "warning")]
    Warning,
    #[serde(rename = "caution")]
    Caution,
    #[serde(rename = "kick")]
    Kick,
    #[serde(rename = "note")]
    Note,

}

impl std::fmt::Display for PunishmentType {
    fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result {
        match self {
            Self::Ban => write!(f, "ban"),
            Self::TempBan => write!(f, "tempBan"),
            Self::IpBan => write!(f, "ipBan"),
            Self::TempIpBan => write!(f, "tempIpBan"),
            Self::Mute => write!(f, "mute"),
            Self::TempMute => write!(f, "tempMute"),
            Self::IpMute => write!(f, "ipMute"),
            Self::TempIpMute => write!(f, "tempIpMute"),
            Self::Warning => write!(f, "warning"),
            Self::Caution => write!(f, "caution"),
            Self::Kick => write!(f, "kick"),
            Self::Note => write!(f, "note"),
        }
    }
}

impl Default for PunishmentType {
    fn default() -> PunishmentType {
        Self::Ban
    }
}