30 return !*
x && !*
y ?
true : (*
x == *
y && same(
x + 1,
y + 1));
35 return !entries->label ? entries->value
36 : same(entries->label,
label) ? entries->value
37 : keyToValue(
label, entries + 1);
42 return !entries->label ? entries->label
43 : entries->value ==
value ? entries->label
44 : valueToKey(
value, entries + 1);
46 constexpr entry<L1GtBoardType> l1GtBoardTypeStringToEnumMap[] = {{
"GTFE",
GTFE},
55 constexpr entry<L1GtPsbQuad> l1GtPsbQuadStringToEnumMap[] = {{
"Free",
Free},
84 constexpr entry<L1GtConditionType> l1GtConditionTypeStringToEnumMap[] = {{
"TypeNull",
TypeNull},
104 constexpr entry<L1GtConditionCategory> l1GtConditionCategoryStringToEnumMap[] = {
123 edm::LogInfo(
"L1GtDefinitions") <<
"\n '" <<
label <<
"' is not a recognized L1GtBoardType. \n Return BoardNull.";
128 edm::LogInfo(
"L1GtDefinitions") <<
"\n BoardNull means no valid board type defined!";
135 char const*
result = valueToKey(boardType, l1GtBoardTypeStringToEnumMap);
137 edm::LogInfo(
"L1GtDefinitions") <<
"\n BoardNull means no valid board type defined!";
140 edm::LogInfo(
"L1GtDefinitions") <<
"\n '" << boardType <<
"' is not a recognized L1GtBoardType. " 141 <<
"\n Return BoardNull, which means no valid board type defined!";
154 edm::LogInfo(
"L1GtDefinitions") <<
"\n '" <<
label <<
"' is not a recognized L1GtPsbQuad. \n Return PsbQuadNull.";
159 edm::LogInfo(
"L1GtDefinitions") <<
"\n PsbQuadNull means no valid PSB quadruplet defined!";
166 char const*
result = valueToKey(psbQuad, l1GtPsbQuadStringToEnumMap);
168 edm::LogInfo(
"L1GtDefinitions") <<
"\n PsbQuadNull means no valid PSB quadruplet defined!";
171 edm::LogInfo(
"L1GtDefinitions") <<
"\n '" << psbQuad <<
"' is not a recognized L1GtPsbQuad. " 172 <<
"\n Return PsbQuadNull, which means no valid PSB quadruplet defined!";
185 <<
"' is not a recognized L1GtConditionType. \n Return TypeNull.";
191 edm::LogInfo(
"L1GtDefinitions") <<
"\n TypeNull means no valid condition type defined!";
198 const char*
result = valueToKey(conditionType, l1GtConditionTypeStringToEnumMap);
200 edm::LogInfo(
"L1GtDefinitions") <<
"\n Return TypeNull, which means no valid condition type defined!";
203 edm::LogInfo(
"L1GtDefinitions") <<
"\n '" << conditionType <<
"' is not a recognized L1GtConditionType. " 204 <<
"\n Return TypeNull, which means no valid condition type defined!";
215 <<
"' is not a recognized L1GtConditionCategory. \n Return CondNull.";
221 edm::LogInfo(
"L1GtDefinitions") <<
"\n CondNull means no valid condition category defined!";
228 char const*
result = valueToKey(conditionCategory, l1GtConditionCategoryStringToEnumMap);
230 edm::LogInfo(
"L1GtDefinitions") <<
"\n Return CondNull, which means no valid condition category defined!";
234 edm::LogInfo(
"L1GtDefinitions") <<
"\n '" << conditionCategory <<
"' is not a recognized L1GtConditionCategory. " 235 <<
"\n Return CondNull, which means no valid condition category defined!";
L1GtConditionType l1GtConditionTypeStringToEnum(const std::string &label)
std::string l1GtConditionTypeEnumToString(const L1GtConditionType &conditionType)
std::string l1GtBoardTypeEnumToString(const L1GtBoardType &boardType)
L1GtPsbQuad l1GtPsbQuadStringToEnum(const std::string &label)
std::string l1GtConditionCategoryEnumToString(const L1GtConditionCategory &conditionCategory)
Log< level::Info, false > LogInfo
L1GtBoardType l1GtBoardTypeStringToEnum(const std::string &label)
std::string l1GtPsbQuadEnumToString(const L1GtPsbQuad &psbQuad)
L1GtConditionCategory l1GtConditionCategoryStringToEnum(const std::string &label)