naurt_api/models/final_destination_status.rs
1/*
2 * Naurt API
3 *
4 * OpenAPI specification for Naurt's APIs.
5 *
6 * The version of the OpenAPI document: 0.1.2
7 *
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// FinalDestinationStatus : The `queries` and `responses` arrays are always 1:1. If no match can be found, a 404 will NOT be returned. Instead, check this enum for `no_matches`. That indicates no error has happened, but nothing was found. `ok` when something is found.
15/// The `queries` and `responses` arrays are always 1:1. If no match can be found, a 404 will NOT be returned. Instead, check this enum for `no_matches`. That indicates no error has happened, but nothing was found. `ok` when something is found.
16#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
17pub enum FinalDestinationStatus {
18 #[serde(rename = "ok")]
19 Ok,
20 #[serde(rename = "no_matches")]
21 NoMatches,
22
23}
24
25impl std::fmt::Display for FinalDestinationStatus {
26 fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result {
27 match self {
28 Self::Ok => write!(f, "ok"),
29 Self::NoMatches => write!(f, "no_matches"),
30 }
31 }
32}
33
34impl Default for FinalDestinationStatus {
35 fn default() -> FinalDestinationStatus {
36 Self::Ok
37 }
38}
39