summaryrefslogtreecommitdiff
path: root/src/components/policy/policy_regular/src/policy_table/enums.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/policy/policy_regular/src/policy_table/enums.cc')
-rw-r--r--src/components/policy/policy_regular/src/policy_table/enums.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/components/policy/policy_regular/src/policy_table/enums.cc b/src/components/policy/policy_regular/src/policy_table/enums.cc
index e0f77be989..34d12420d8 100644
--- a/src/components/policy/policy_regular/src/policy_table/enums.cc
+++ b/src/components/policy/policy_regular/src/policy_table/enums.cc
@@ -161,6 +161,8 @@ bool IsValidEnum(Parameter val) {
return true;
case P_ECALLINFO:
return true;
+ case P_EMPTY:
+ return true;
default:
return false;
}
@@ -217,10 +219,13 @@ const char* EnumToJsonString(Parameter val) {
return "emergencyEvent";
case P_ECALLINFO:
return "eCallInfo";
+ case P_EMPTY:
+ return "EMPTY";
default:
return "";
}
}
+
bool EnumFromJsonString(const std::string& literal, Parameter* result) {
if ("gps" == literal) {
*result = P_GPS;
@@ -297,6 +302,9 @@ bool EnumFromJsonString(const std::string& literal, Parameter* result) {
} else if ("eCallInfo" == literal) {
*result = P_ECALLINFO;
return true;
+ } else if ("EMPTY" == literal) {
+ *result = P_EMPTY;
+ return true;
} else {
return false;
}