dodopayments_rust 2.2.2

Rust SDK for Dodo Payments API
Documentation
/*
 * public
 *
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: 1.87.0
 * 
 * Generated by: https://openapi-generator.tech
 */

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

/// TaxCategory : Represents the different categories of taxation applicable to various products and services.
/// Represents the different categories of taxation applicable to various products and services.
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum TaxCategory {
    #[serde(rename = "digital_products")]
    DigitalProducts,
    #[serde(rename = "saas")]
    Saas,
    #[serde(rename = "e_book")]
    EBook,
    #[serde(rename = "edtech")]
    Edtech,

}

impl std::fmt::Display for TaxCategory {
    fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result {
        match self {
            Self::DigitalProducts => write!(f, "digital_products"),
            Self::Saas => write!(f, "saas"),
            Self::EBook => write!(f, "e_book"),
            Self::Edtech => write!(f, "edtech"),
        }
    }
}

impl Default for TaxCategory {
    fn default() -> TaxCategory {
        Self::DigitalProducts
    }
}