/*
 * MOTIS API
 *
 * This is the MOTIS routing API.
 *
 * The version of the OpenAPI document: v1
 * Contact: felix@triptix.tech
 * 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 AbsoluteDirection {
    #[serde(rename = "NORTH")]
    North,
    #[serde(rename = "NORTHEAST")]
    Northeast,
    #[serde(rename = "EAST")]
    East,
    #[serde(rename = "SOUTHEAST")]
    Southeast,
    #[serde(rename = "SOUTH")]
    South,
    #[serde(rename = "SOUTHWEST")]
    Southwest,
    #[serde(rename = "WEST")]
    West,
    #[serde(rename = "NORTHWEST")]
    Northwest,

}

impl std::fmt::Display for AbsoluteDirection {
    fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result {
        match self {
            Self::North => write!(f, "NORTH"),
            Self::Northeast => write!(f, "NORTHEAST"),
            Self::East => write!(f, "EAST"),
            Self::Southeast => write!(f, "SOUTHEAST"),
            Self::South => write!(f, "SOUTH"),
            Self::Southwest => write!(f, "SOUTHWEST"),
            Self::West => write!(f, "WEST"),
            Self::Northwest => write!(f, "NORTHWEST"),
        }
    }
}

impl Default for AbsoluteDirection {
    fn default() -> AbsoluteDirection {
        Self::North
    }
}

