diff options
| author | Gunnar Mills <gmills@us.ibm.com> | 2026-09-24 06:43:31 +0300 |
|---|---|---|
| committer | Gunnar Mills <gmills@us.ibm.com> | 2026-10-22 03:08:08 +0300 |
| commit | 0128851e733fa2cdc8af2c20ba90ef272d96422a (patch) | |
| tree | 26c24b6bd43f13964e68b2f47adc85a1500684f6 /redfish-core/include/generated/enums/policy.hpp | |
| parent | e44732f264b7f81dabff30a5a5c316eda4264ce7 (diff) | |
| download | bmcweb-master.tar.xz | |
Like we do, one line change and rerun the script.
2026.2 includes new properties and schemas.
The overview is at [1].
[1]: https://www.dmtf.org/sites/default/files/Redfish_Release_2026.2_Overview.pdf
Tested: Inspection only.
Change-Id: I860c142a3685b5aa98dfe27b2c718f16b04bece7
Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
Diffstat (limited to 'redfish-core/include/generated/enums/policy.hpp')
| -rw-r--r-- | redfish-core/include/generated/enums/policy.hpp | 87 |
1 files changed, 87 insertions, 0 deletions
diff --git a/redfish-core/include/generated/enums/policy.hpp b/redfish-core/include/generated/enums/policy.hpp new file mode 100644 index 0000000000..063791e8f3 --- /dev/null +++ b/redfish-core/include/generated/enums/policy.hpp @@ -0,0 +1,87 @@ +// SPDX-License-Identifier: Apache-2.0 +// SPDX-FileCopyrightText: Copyright OpenBMC Authors +#pragma once +#include <nlohmann/json.hpp> + +namespace policy +{ +// clang-format off + +enum class ConditionType{ + Invalid, + And, + Or, + Compare, + Read, + Sum, + Average, + Event, +}; + +enum class ResponseAction{ + Invalid, + Recheck, + Event, + Reset, + HTTP, + OEM, +}; + +enum class Operator{ + Invalid, + Equal, + NotEqual, + GreaterThan, + LessThan, + GreaterThanOrEqual, + LessThanOrEqual, +}; + +enum class HTTPVerb{ + Invalid, + GET, + PATCH, + POST, + DELETE, +}; + +NLOHMANN_JSON_SERIALIZE_ENUM(ConditionType, { + {ConditionType::Invalid, "Invalid"}, + {ConditionType::And, "And"}, + {ConditionType::Or, "Or"}, + {ConditionType::Compare, "Compare"}, + {ConditionType::Read, "Read"}, + {ConditionType::Sum, "Sum"}, + {ConditionType::Average, "Average"}, + {ConditionType::Event, "Event"}, +}); + +NLOHMANN_JSON_SERIALIZE_ENUM(ResponseAction, { + {ResponseAction::Invalid, "Invalid"}, + {ResponseAction::Recheck, "Recheck"}, + {ResponseAction::Event, "Event"}, + {ResponseAction::Reset, "Reset"}, + {ResponseAction::HTTP, "HTTP"}, + {ResponseAction::OEM, "OEM"}, +}); + +NLOHMANN_JSON_SERIALIZE_ENUM(Operator, { + {Operator::Invalid, "Invalid"}, + {Operator::Equal, "Equal"}, + {Operator::NotEqual, "NotEqual"}, + {Operator::GreaterThan, "GreaterThan"}, + {Operator::LessThan, "LessThan"}, + {Operator::GreaterThanOrEqual, "GreaterThanOrEqual"}, + {Operator::LessThanOrEqual, "LessThanOrEqual"}, +}); + +NLOHMANN_JSON_SERIALIZE_ENUM(HTTPVerb, { + {HTTPVerb::Invalid, "Invalid"}, + {HTTPVerb::GET, "GET"}, + {HTTPVerb::PATCH, "PATCH"}, + {HTTPVerb::POST, "POST"}, + {HTTPVerb::DELETE, "DELETE"}, +}); + +// clang-format on +} // namespace policy |
