xref: /openbmc/bmcweb/features/redfish/include/generated/enums/attribute_registry.hpp (revision 0ec8b83db7e8629c721c0e632de702bf1018f58f)
1*0ec8b83dSEd Tanous #pragma once
2*0ec8b83dSEd Tanous #include <nlohmann/json.hpp>
3*0ec8b83dSEd Tanous 
4*0ec8b83dSEd Tanous namespace attribute_registry
5*0ec8b83dSEd Tanous {
6*0ec8b83dSEd Tanous // clang-format off
7*0ec8b83dSEd Tanous 
8*0ec8b83dSEd Tanous enum class AttributeType{
9*0ec8b83dSEd Tanous     Invalid,
10*0ec8b83dSEd Tanous     Enumeration,
11*0ec8b83dSEd Tanous     String,
12*0ec8b83dSEd Tanous     Integer,
13*0ec8b83dSEd Tanous     Boolean,
14*0ec8b83dSEd Tanous     Password,
15*0ec8b83dSEd Tanous };
16*0ec8b83dSEd Tanous 
17*0ec8b83dSEd Tanous enum class DependencyType{
18*0ec8b83dSEd Tanous     Invalid,
19*0ec8b83dSEd Tanous     Map,
20*0ec8b83dSEd Tanous };
21*0ec8b83dSEd Tanous 
22*0ec8b83dSEd Tanous enum class MapFromCondition{
23*0ec8b83dSEd Tanous     Invalid,
24*0ec8b83dSEd Tanous     EQU,
25*0ec8b83dSEd Tanous     NEQ,
26*0ec8b83dSEd Tanous     GTR,
27*0ec8b83dSEd Tanous     GEQ,
28*0ec8b83dSEd Tanous     LSS,
29*0ec8b83dSEd Tanous     LEQ,
30*0ec8b83dSEd Tanous };
31*0ec8b83dSEd Tanous 
32*0ec8b83dSEd Tanous enum class MapFromProperty{
33*0ec8b83dSEd Tanous     Invalid,
34*0ec8b83dSEd Tanous     CurrentValue,
35*0ec8b83dSEd Tanous     DefaultValue,
36*0ec8b83dSEd Tanous     ReadOnly,
37*0ec8b83dSEd Tanous     WriteOnly,
38*0ec8b83dSEd Tanous     GrayOut,
39*0ec8b83dSEd Tanous     Hidden,
40*0ec8b83dSEd Tanous     LowerBound,
41*0ec8b83dSEd Tanous     UpperBound,
42*0ec8b83dSEd Tanous     MinLength,
43*0ec8b83dSEd Tanous     MaxLength,
44*0ec8b83dSEd Tanous     ScalarIncrement,
45*0ec8b83dSEd Tanous };
46*0ec8b83dSEd Tanous 
47*0ec8b83dSEd Tanous enum class MapTerms{
48*0ec8b83dSEd Tanous     Invalid,
49*0ec8b83dSEd Tanous     AND,
50*0ec8b83dSEd Tanous     OR,
51*0ec8b83dSEd Tanous };
52*0ec8b83dSEd Tanous 
53*0ec8b83dSEd Tanous enum class MapToProperty{
54*0ec8b83dSEd Tanous     Invalid,
55*0ec8b83dSEd Tanous     CurrentValue,
56*0ec8b83dSEd Tanous     DefaultValue,
57*0ec8b83dSEd Tanous     ReadOnly,
58*0ec8b83dSEd Tanous     WriteOnly,
59*0ec8b83dSEd Tanous     GrayOut,
60*0ec8b83dSEd Tanous     Hidden,
61*0ec8b83dSEd Tanous     Immutable,
62*0ec8b83dSEd Tanous     HelpText,
63*0ec8b83dSEd Tanous     WarningText,
64*0ec8b83dSEd Tanous     DisplayName,
65*0ec8b83dSEd Tanous     DisplayOrder,
66*0ec8b83dSEd Tanous     LowerBound,
67*0ec8b83dSEd Tanous     UpperBound,
68*0ec8b83dSEd Tanous     MinLength,
69*0ec8b83dSEd Tanous     MaxLength,
70*0ec8b83dSEd Tanous     ScalarIncrement,
71*0ec8b83dSEd Tanous     ValueExpression,
72*0ec8b83dSEd Tanous };
73*0ec8b83dSEd Tanous 
74*0ec8b83dSEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(AttributeType, {
75*0ec8b83dSEd Tanous     {AttributeType::Invalid, "Invalid"},
76*0ec8b83dSEd Tanous     {AttributeType::Enumeration, "Enumeration"},
77*0ec8b83dSEd Tanous     {AttributeType::String, "String"},
78*0ec8b83dSEd Tanous     {AttributeType::Integer, "Integer"},
79*0ec8b83dSEd Tanous     {AttributeType::Boolean, "Boolean"},
80*0ec8b83dSEd Tanous     {AttributeType::Password, "Password"},
81*0ec8b83dSEd Tanous });
82*0ec8b83dSEd Tanous 
83*0ec8b83dSEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(DependencyType, {
84*0ec8b83dSEd Tanous     {DependencyType::Invalid, "Invalid"},
85*0ec8b83dSEd Tanous     {DependencyType::Map, "Map"},
86*0ec8b83dSEd Tanous });
87*0ec8b83dSEd Tanous 
88*0ec8b83dSEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(MapFromCondition, {
89*0ec8b83dSEd Tanous     {MapFromCondition::Invalid, "Invalid"},
90*0ec8b83dSEd Tanous     {MapFromCondition::EQU, "EQU"},
91*0ec8b83dSEd Tanous     {MapFromCondition::NEQ, "NEQ"},
92*0ec8b83dSEd Tanous     {MapFromCondition::GTR, "GTR"},
93*0ec8b83dSEd Tanous     {MapFromCondition::GEQ, "GEQ"},
94*0ec8b83dSEd Tanous     {MapFromCondition::LSS, "LSS"},
95*0ec8b83dSEd Tanous     {MapFromCondition::LEQ, "LEQ"},
96*0ec8b83dSEd Tanous });
97*0ec8b83dSEd Tanous 
98*0ec8b83dSEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(MapFromProperty, {
99*0ec8b83dSEd Tanous     {MapFromProperty::Invalid, "Invalid"},
100*0ec8b83dSEd Tanous     {MapFromProperty::CurrentValue, "CurrentValue"},
101*0ec8b83dSEd Tanous     {MapFromProperty::DefaultValue, "DefaultValue"},
102*0ec8b83dSEd Tanous     {MapFromProperty::ReadOnly, "ReadOnly"},
103*0ec8b83dSEd Tanous     {MapFromProperty::WriteOnly, "WriteOnly"},
104*0ec8b83dSEd Tanous     {MapFromProperty::GrayOut, "GrayOut"},
105*0ec8b83dSEd Tanous     {MapFromProperty::Hidden, "Hidden"},
106*0ec8b83dSEd Tanous     {MapFromProperty::LowerBound, "LowerBound"},
107*0ec8b83dSEd Tanous     {MapFromProperty::UpperBound, "UpperBound"},
108*0ec8b83dSEd Tanous     {MapFromProperty::MinLength, "MinLength"},
109*0ec8b83dSEd Tanous     {MapFromProperty::MaxLength, "MaxLength"},
110*0ec8b83dSEd Tanous     {MapFromProperty::ScalarIncrement, "ScalarIncrement"},
111*0ec8b83dSEd Tanous });
112*0ec8b83dSEd Tanous 
113*0ec8b83dSEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(MapTerms, {
114*0ec8b83dSEd Tanous     {MapTerms::Invalid, "Invalid"},
115*0ec8b83dSEd Tanous     {MapTerms::AND, "AND"},
116*0ec8b83dSEd Tanous     {MapTerms::OR, "OR"},
117*0ec8b83dSEd Tanous });
118*0ec8b83dSEd Tanous 
119*0ec8b83dSEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(MapToProperty, {
120*0ec8b83dSEd Tanous     {MapToProperty::Invalid, "Invalid"},
121*0ec8b83dSEd Tanous     {MapToProperty::CurrentValue, "CurrentValue"},
122*0ec8b83dSEd Tanous     {MapToProperty::DefaultValue, "DefaultValue"},
123*0ec8b83dSEd Tanous     {MapToProperty::ReadOnly, "ReadOnly"},
124*0ec8b83dSEd Tanous     {MapToProperty::WriteOnly, "WriteOnly"},
125*0ec8b83dSEd Tanous     {MapToProperty::GrayOut, "GrayOut"},
126*0ec8b83dSEd Tanous     {MapToProperty::Hidden, "Hidden"},
127*0ec8b83dSEd Tanous     {MapToProperty::Immutable, "Immutable"},
128*0ec8b83dSEd Tanous     {MapToProperty::HelpText, "HelpText"},
129*0ec8b83dSEd Tanous     {MapToProperty::WarningText, "WarningText"},
130*0ec8b83dSEd Tanous     {MapToProperty::DisplayName, "DisplayName"},
131*0ec8b83dSEd Tanous     {MapToProperty::DisplayOrder, "DisplayOrder"},
132*0ec8b83dSEd Tanous     {MapToProperty::LowerBound, "LowerBound"},
133*0ec8b83dSEd Tanous     {MapToProperty::UpperBound, "UpperBound"},
134*0ec8b83dSEd Tanous     {MapToProperty::MinLength, "MinLength"},
135*0ec8b83dSEd Tanous     {MapToProperty::MaxLength, "MaxLength"},
136*0ec8b83dSEd Tanous     {MapToProperty::ScalarIncrement, "ScalarIncrement"},
137*0ec8b83dSEd Tanous     {MapToProperty::ValueExpression, "ValueExpression"},
138*0ec8b83dSEd Tanous });
139*0ec8b83dSEd Tanous 
140*0ec8b83dSEd Tanous }
141*0ec8b83dSEd Tanous // clang-format on
142