openfga 1.0.2

Rust SDK for OpenFGA — the open-source authorization system
Documentation
/*
 * OpenFGA
 *
 * A high performance and flexible authorization/permission engine built for developers and inspired by Google Zanzibar.
 *
 * The version of the OpenAPI document: 1.x
 * Contact: community@openfga.dev
 * Generated by: https://openapi-generator.tech
 */

use serde::{Deserialize, Serialize};

#[derive(
    Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize, Default,
)]
pub enum NotFoundErrorCode {
    #[serde(rename = "no_not_found_error")]
    #[default]
    NoNotFoundError,
    #[serde(rename = "undefined_endpoint")]
    UndefinedEndpoint,
    #[serde(rename = "store_id_not_found")]
    StoreIdNotFound,
    #[serde(rename = "unimplemented")]
    Unimplemented,
}

impl std::fmt::Display for NotFoundErrorCode {
    fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result {
        match self {
            Self::NoNotFoundError => write!(f, "no_not_found_error"),
            Self::UndefinedEndpoint => write!(f, "undefined_endpoint"),
            Self::StoreIdNotFound => write!(f, "store_id_not_found"),
            Self::Unimplemented => write!(f, "unimplemented"),
        }
    }
}