1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
/*
 * Selling Partner API for Fulfillment Inbound
 *
 * The Selling Partner API for Fulfillment Inbound lets you create applications that create and update inbound shipments of inventory to Amazon's fulfillment network.
 *
 * The version of the OpenAPI document: v0
 * 
 * Generated by: https://openapi-generator.tech
 */

/// Condition : The condition of the item.

/// The condition of the item.
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum Condition {
    #[serde(rename = "NewItem")]
    NewItem,
    #[serde(rename = "NewWithWarranty")]
    NewWithWarranty,
    #[serde(rename = "NewOEM")]
    NewOEM,
    #[serde(rename = "NewOpenBox")]
    NewOpenBox,
    #[serde(rename = "UsedLikeNew")]
    UsedLikeNew,
    #[serde(rename = "UsedVeryGood")]
    UsedVeryGood,
    #[serde(rename = "UsedGood")]
    UsedGood,
    #[serde(rename = "UsedAcceptable")]
    UsedAcceptable,
    #[serde(rename = "UsedPoor")]
    UsedPoor,
    #[serde(rename = "UsedRefurbished")]
    UsedRefurbished,
    #[serde(rename = "CollectibleLikeNew")]
    CollectibleLikeNew,
    #[serde(rename = "CollectibleVeryGood")]
    CollectibleVeryGood,
    #[serde(rename = "CollectibleGood")]
    CollectibleGood,
    #[serde(rename = "CollectibleAcceptable")]
    CollectibleAcceptable,
    #[serde(rename = "CollectiblePoor")]
    CollectiblePoor,
    #[serde(rename = "RefurbishedWithWarranty")]
    RefurbishedWithWarranty,
    #[serde(rename = "Refurbished")]
    Refurbished,
    #[serde(rename = "Club")]
    Club,

}

impl ToString for Condition {
    fn to_string(&self) -> String {
        match self {
            Self::NewItem => String::from("NewItem"),
            Self::NewWithWarranty => String::from("NewWithWarranty"),
            Self::NewOEM => String::from("NewOEM"),
            Self::NewOpenBox => String::from("NewOpenBox"),
            Self::UsedLikeNew => String::from("UsedLikeNew"),
            Self::UsedVeryGood => String::from("UsedVeryGood"),
            Self::UsedGood => String::from("UsedGood"),
            Self::UsedAcceptable => String::from("UsedAcceptable"),
            Self::UsedPoor => String::from("UsedPoor"),
            Self::UsedRefurbished => String::from("UsedRefurbished"),
            Self::CollectibleLikeNew => String::from("CollectibleLikeNew"),
            Self::CollectibleVeryGood => String::from("CollectibleVeryGood"),
            Self::CollectibleGood => String::from("CollectibleGood"),
            Self::CollectibleAcceptable => String::from("CollectibleAcceptable"),
            Self::CollectiblePoor => String::from("CollectiblePoor"),
            Self::RefurbishedWithWarranty => String::from("RefurbishedWithWarranty"),
            Self::Refurbished => String::from("Refurbished"),
            Self::Club => String::from("Club"),
        }
    }
}

impl Default for Condition {
    fn default() -> Condition {
        Self::NewItem
    }
}