/*
 * Ethereal Exchange API
 *
 * Ethereal HTTP API for real-time trading, order management, and market data access.
 *
 * The version of the OpenAPI document: 0.1.0
 *
 * Generated by: https://openapi-generator.tech
 */

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

/// WithdrawFailedDtoMessageEnum : Extracted enum for WithdrawFailedDtoMessageEnum
/// Extracted enum for WithdrawFailedDtoMessageEnum
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum WithdrawFailedDtoMessageEnum {
    #[serde(rename = "AccountSuspended")]
    AccountSuspended,
    #[serde(rename = "EngineSuspended")]
    EngineSuspended,
    #[serde(rename = "InsufficientBalance")]
    InsufficientBalance,
    #[serde(rename = "InsuranceFundCannotWithdraw")]
    InsuranceFundCannotWithdraw,
}

impl std::fmt::Display for WithdrawFailedDtoMessageEnum {
    fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result {
        match self {
            Self::AccountSuspended => write!(f, "AccountSuspended"),
            Self::EngineSuspended => write!(f, "EngineSuspended"),
            Self::InsufficientBalance => write!(f, "InsufficientBalance"),
            Self::InsuranceFundCannotWithdraw => write!(f, "InsuranceFundCannotWithdraw"),
        }
    }
}

impl Default for WithdrawFailedDtoMessageEnum {
    fn default() -> WithdrawFailedDtoMessageEnum {
        Self::AccountSuspended
    }
}
