/openbmc/bmcweb/redfish-core/include/ |
H A D | error_messages.hpp | 36 nlohmann::json success(); 48 nlohmann::json generalError(); 58 nlohmann::json created(); 69 nlohmann::json noOperation(); 80 nlohmann::json propertyDuplicate(std::string_view arg1); 92 nlohmann::json propertyUnknown(std::string_view arg1); 105 nlohmann::json propertyValueTypeError(const nlohmann::json& arg1, 108 void propertyValueTypeError(crow::Response& res, const nlohmann::json& arg1, 120 nlohmann::json propertyValueFormatError(const nlohmann::json& arg1, 123 void propertyValueFormatError(crow::Response& res, const nlohmann::json& arg1, [all …]
|
H A D | resource_messages.hpp | 30 nlohmann::json resourceCreated(); 32 nlohmann::json resourceRemoved(); 34 nlohmann::json resourceErrorsDetected(std::string_view arg1, 37 nlohmann::json resourceErrorsCorrected(std::string_view arg1, 40 nlohmann::json resourceErrorThresholdExceeded(std::string_view arg1, 43 nlohmann::json resourceErrorThresholdCleared(std::string_view arg1, 46 nlohmann::json resourceWarningThresholdExceeded(std::string_view arg1, 49 nlohmann::json resourceWarningThresholdCleared(std::string_view arg1, 52 nlohmann::json resourceStatusChangedOK(std::string_view arg1, 55 nlohmann::json resourceStatusChangedWarning(std::string_view arg1, [all …]
|
H A D | task_messages.hpp | 30 nlohmann::json taskStarted(std::string_view arg1); 32 nlohmann::json taskCompletedOK(std::string_view arg1); 34 nlohmann::json taskCompletedWarning(std::string_view arg1); 36 nlohmann::json taskAborted(std::string_view arg1); 38 nlohmann::json taskCancelled(std::string_view arg1); 40 nlohmann::json taskRemoved(std::string_view arg1); 42 nlohmann::json taskPaused(std::string_view arg1); 44 nlohmann::json taskResumed(std::string_view arg1); 46 nlohmann::json taskProgressChanged(std::string_view arg1, uint64_t arg2);
|
H A D | error_message_utils.hpp | 15 void moveErrorsToErrorJson(nlohmann::json& target, nlohmann::json& source); 16 void addMessageToJsonRoot(nlohmann::json& target, 17 const nlohmann::json& message); 19 void addMessageToJson(nlohmann::json& target, const nlohmann::json& message, 22 void addMessageToErrorJson(nlohmann::json& target, 23 const nlohmann::json& message);
|
/openbmc/phosphor-power/phosphor-regulators/src/ |
H A D | config_file_parser.hpp | 94 inline const nlohmann::json& getRequiredProperty(const nlohmann::json& element, in getRequiredProperty() 116 std::unique_ptr<Action> parseAction(const nlohmann::json& element); 129 const nlohmann::json& element); 141 std::unique_ptr<AndAction> parseAnd(const nlohmann::json& element); 153 inline uint8_t parseBitPosition(const nlohmann::json& element) in parseBitPosition() 178 inline uint8_t parseBitValue(const nlohmann::json& element) in parseBitValue() 203 inline bool parseBoolean(const nlohmann::json& element) in parseBoolean() 223 std::unique_ptr<Chassis> parseChassis(const nlohmann::json& element); 236 const nlohmann::json& element); 249 const nlohmann::json& element); [all …]
|
/openbmc/entity-manager/test/ |
H A D | test_entity-manager.cpp | 14 nlohmann::json j = {{"foo", "$bus"}}; in TEST() 21 nlohmann::json expected = 23; in TEST() 27 nlohmann::json j = {{"foo", "$TEST"}}; in TEST() 34 nlohmann::json expected = "Test"; in TEST() 40 nlohmann::json j = {{"foo", "the $TEST"}}; in TEST() 47 nlohmann::json expected = "the Test"; in TEST() 53 nlohmann::json j = {{"foo", "the $TEST worked"}}; in TEST() 60 nlohmann::json expected = "the Test worked"; in TEST() 66 nlohmann::json j = {{"foo", "the Test $TEST"}}; in TEST() 73 nlohmann::json expected = "the Test 23"; in TEST() [all …]
|
/openbmc/bmcweb/redfish-core/src/ |
H A D | resource_messages.cpp | 34 static nlohmann::json getLog(redfish::registries::resource_event::Index name, in getLog() 54 nlohmann::json resourceCreated() in resourceCreated() 67 nlohmann::json resourceRemoved() in resourceRemoved() 80 nlohmann::json resourceErrorsDetected(std::string_view arg1, in resourceErrorsDetected() 95 nlohmann::json resourceErrorsCorrected(std::string_view arg1, in resourceErrorsCorrected() 110 nlohmann::json resourceErrorThresholdExceeded(std::string_view arg1, in resourceErrorThresholdExceeded() 125 nlohmann::json resourceErrorThresholdCleared(std::string_view arg1, in resourceErrorThresholdCleared() 140 nlohmann::json resourceWarningThresholdExceeded(std::string_view arg1, in resourceWarningThresholdExceeded() 155 nlohmann::json resourceWarningThresholdCleared(std::string_view arg1, in resourceWarningThresholdCleared() 170 nlohmann::json resourceStatusChangedOK(std::string_view arg1, in resourceStatusChangedOK() [all …]
|
H A D | error_message_utils.cpp | 16 void addMessageToErrorJson(nlohmann::json& target, in addMessageToErrorJson() 17 const nlohmann::json& message) in addMessageToErrorJson() 56 extendedInfo = nlohmann::json::array(); in addMessageToErrorJson() 62 void moveErrorsToErrorJson(nlohmann::json& target, nlohmann::json& source) in moveErrorsToErrorJson() 81 const nlohmann::json::array_t* extendedInfo = in moveErrorsToErrorJson() 82 (*extendedInfoIt).get_ptr<const nlohmann::json::array_t*>(); in moveErrorsToErrorJson() 88 for (const nlohmann::json& message : *extendedInfo) in moveErrorsToErrorJson() 95 void addMessageToJsonRoot(nlohmann::json& target, const nlohmann::json& message) in addMessageToJsonRoot() 100 target[messages::messageAnnotation] = nlohmann::json::array(); in addMessageToJsonRoot() 106 void addMessageToJson(nlohmann::json& target, const nlohmann::json& message, in addMessageToJson() [all …]
|
H A D | error_messages.cpp | 43 static nlohmann::json getLog(redfish::registries::base::Index name, in getLog() 62 nlohmann::json success() in success() 79 nlohmann::json generalError() in generalError() 97 nlohmann::json created() in created() 115 nlohmann::json noOperation() in noOperation() 133 nlohmann::json propertyDuplicate(std::string_view arg1) in propertyDuplicate() 152 nlohmann::json propertyUnknown(std::string_view arg1) in propertyUnknown() 171 nlohmann::json propertyValueTypeError(const nlohmann::json& arg1, in propertyValueTypeError() 175 arg1.dump(-1, ' ', true, nlohmann::json::error_handler_t::replace); in propertyValueTypeError() 180 void propertyValueTypeError(crow::Response& res, const nlohmann::json& arg1, in propertyValueTypeError() [all …]
|
H A D | task_messages.cpp | 36 static nlohmann::json getLog(redfish::registries::task_event::Index name, in getLog() 56 nlohmann::json taskStarted(std::string_view arg1) in taskStarted() 69 nlohmann::json taskCompletedOK(std::string_view arg1) in taskCompletedOK() 82 nlohmann::json taskCompletedWarning(std::string_view arg1) in taskCompletedWarning() 95 nlohmann::json taskAborted(std::string_view arg1) in taskAborted() 108 nlohmann::json taskCancelled(std::string_view arg1) in taskCancelled() 121 nlohmann::json taskRemoved(std::string_view arg1) in taskRemoved() 134 nlohmann::json taskPaused(std::string_view arg1) in taskPaused() 147 nlohmann::json taskResumed(std::string_view arg1) in taskResumed() 160 nlohmann::json taskProgressChanged(std::string_view arg1, uint64_t arg2) in taskProgressChanged()
|
/openbmc/bmcweb/redfish-core/include/utils/ |
H A D | json_utils.hpp | 54 nlohmann::json& reqJson); 134 UnpackErrorCode unpackValueWithErrorCode(nlohmann::json& jsonValue, 138 UnpackErrorCode unpackValueVariant(nlohmann::json& j, std::string_view key, in unpackValueVariant() 157 UnpackErrorCode unpackValueWithErrorCode(nlohmann::json& jsonValue, in unpackValueWithErrorCode() 216 else if constexpr (std::is_same_v<nlohmann::json, Type>) in unpackValueWithErrorCode() 229 nlohmann::json::object_t* obj = in unpackValueWithErrorCode() 230 jsonValue.get_ptr<nlohmann::json::object_t*>(); in unpackValueWithErrorCode() 260 bool unpackValue(nlohmann::json& jsonValue, std::string_view key, in unpackValue() 274 nlohmann::json::array_t* arr = in unpackValue() 275 jsonValue.get_ptr<nlohmann::json::array_t*>(); in unpackValue() [all …]
|
H A D | query_param.hpp | 541 nlohmann::json::json_pointer location; 551 ExpandType eType, nlohmann::json::array_t& array, 552 const nlohmann::json::json_pointer& jsonPtr, int depth, int skipDepth, 556 ExpandType eType, nlohmann::json::object_t& obj, 557 const nlohmann::json::json_pointer& jsonPtr, int depth, int skipDepth, 567 ExpandType eType, nlohmann::json& jsonResponse, in findNavigationReferencesRecursive() 568 const nlohmann::json::json_pointer& jsonPtr, int depth, int skipDepth, in findNavigationReferencesRecursive() 577 nlohmann::json::array_t* array = in findNavigationReferencesRecursive() 578 jsonResponse.get_ptr<nlohmann::json::array_t*>(); in findNavigationReferencesRecursive() 584 nlohmann::json::object_t* obj = in findNavigationReferencesRecursive() [all …]
|
/openbmc/phosphor-power/phosphor-power-sequencer/src/ |
H A D | config_file_parser.hpp | 92 inline const nlohmann::json& getRequiredProperty(const nlohmann::json& element, in getRequiredProperty() 114 inline bool parseBoolean(const nlohmann::json& element) in parseBoolean() 134 GPIO parseGPIO(const nlohmann::json& element); 146 std::unique_ptr<Rail> parseRail(const nlohmann::json& element); 159 const nlohmann::json& element); 171 std::vector<std::unique_ptr<Rail>> parseRoot(const nlohmann::json& element); 184 inline std::string parseString(const nlohmann::json& element, in parseString() 209 inline uint8_t parseUint8(const nlohmann::json& element) in parseUint8() 234 inline unsigned int parseUnsignedInteger(const nlohmann::json& element) in parseUnsignedInteger() 251 inline void verifyIsArray(const nlohmann::json& element) in verifyIsArray() [all …]
|
/openbmc/openpower-vpd-parser/vpd-manager/include/utility/ |
H A D | json_utility.hpp | 22 bool processSystemCmdTag(const nlohmann::json& i_parsedConfigJson, 29 const nlohmann::json& i_parsedConfigJson, const std::string& i_vpdFilePath, 33 bool procesSetGpioTag(const nlohmann::json& i_parsedConfigJson, 40 const nlohmann::json& i_parsedConfigJson, const std::string& i_vpdFilePath, 55 inline size_t getVPDOffset(const nlohmann::json& i_sysCfgJsonObj, in getVPDOffset() 69 const nlohmann::json& l_fruList = in getVPDOffset() 70 i_sysCfgJsonObj["frus"].get_ref<const nlohmann::json::object_t&>(); in getVPDOffset() 96 inline nlohmann::json getParsedJson(const std::string& pathToJson) noexcept in getParsedJson() 118 return nlohmann::json::parse(l_jsonFile); in getParsedJson() 126 return nlohmann::json{}; in getParsedJson() [all …]
|
/openbmc/entity-manager/src/ |
H A D | entity_manager.cpp | 79 nlohmann::json lastJson; 145 bool writeJsonFiles(const nlohmann::json& systemConfiguration) in writeJsonFiles() 160 nlohmann::json& systemConfiguration) in setJsonFromPointer() 164 nlohmann::json::json_pointer ptr(ptrStr); in setJsonFromPointer() 165 nlohmann::json& ref = systemConfiguration[ptr]; in setJsonFromPointer() 177 void addArrayToDbus(const std::string& name, const nlohmann::json& array, in addArrayToDbus() 180 nlohmann::json& systemConfiguration, in addArrayToDbus() 225 nlohmann::json& systemConfiguration, in addProperty() 259 nlohmann::json& systemConfiguration) in createDeleteObjectMethod() 273 nlohmann::json::json_pointer ptr(jsonPointerPath); in createDeleteObjectMethod() [all …]
|
H A D | perform_scan.cpp | 30 extern nlohmann::json lastJson; 32 nlohmann::json& systemConfiguration, 86 static void registerCallback(nlohmann::json& systemConfiguration, in registerCallback() 209 auto device = nlohmann::json::array(); in getRecordName() 224 PerformScan::PerformScan(nlohmann::json& systemConfiguration, in PerformScan() 225 nlohmann::json& missingConfigurations, in PerformScan() 226 std::list<nlohmann::json>& configurations, in PerformScan() 235 static void pruneRecordExposes(nlohmann::json& record) in pruneRecordExposes() 243 auto copy = nlohmann::json::array(); in pruneRecordExposes() 255 std::set<nlohmann::json>& usedNames, std::list<size_t>& indexes, in recordDiscoveredIdentifiers() [all …]
|
H A D | entity_manager.hpp | 66 PerformScan(nlohmann::json& systemConfiguration, 67 nlohmann::json& missingConfigurations, 68 std::list<nlohmann::json>& configurations, 71 void updateSystemConfiguration(const nlohmann::json& recordRef, 76 nlohmann::json& _systemConfiguration; 77 nlohmann::json& _missingConfigurations; 78 std::list<nlohmann::json> _configurations; 89 PerformProbe(nlohmann::json& recordRef, 94 nlohmann::json& recordRef; 100 inline void logDeviceAdded(const nlohmann::json& record) in logDeviceAdded() [all …]
|
/openbmc/openpower-vpd-parser/vpd-tool/include/ |
H A D | vpd_tool.hpp | 43 nlohmann::json getFruProperties(const std::string& i_objectPath) const; 57 nlohmann::json& io_fruJsonObject, 75 nlohmann::json& io_fruJsonObject) const; 95 nlohmann::json getInventoryPropertyJson( 112 nlohmann::json getFruTypeProperty( 139 nlohmann::json getBackupRestoreCfgJsonObj() const noexcept; 163 bool fetchKeywordInfo(nlohmann::json& io_parsedJsonObj) const noexcept; 173 void printSystemVpd(const nlohmann::json& i_parsedJsonObj) const noexcept; 191 int updateAllKeywords(const nlohmann::json& i_parsedJsonObj, 201 int handleMoreOption(const nlohmann::json& i_parsedJsonObj) const noexcept;
|
/openbmc/telemetry/src/utils/ |
H A D | labeled_tuple.hpp | 19 inline void from_json(const nlohmann::json& j, in from_json() 25 inline void from_json(const nlohmann::json& j, in from_json() 29 for (const nlohmann::json& item : j) in from_json() 35 inline void to_json(nlohmann::json& j, const double& val) in to_json() 55 inline void from_json(const nlohmann::json& j, double& val) in from_json() 94 decltype(utils::from_json(ref<const nlohmann::json>(), ref<U>()))*); 113 static std::true_type check(decltype(utils::to_json(ref<nlohmann::json>(), 160 nlohmann::json to_json() const in to_json() 162 nlohmann::json j; in to_json() 172 void from_json(const nlohmann::json& j) in from_json() [all …]
|
/openbmc/bmcweb/test/redfish-core/include/ |
H A D | redfish_aggregator_test.cpp | 59 nlohmann::json jsonRequest; in TEST() 102 nlohmann::json jsonRequest; in TEST() 136 nlohmann::json jsonRequest; in TEST() 162 nlohmann::json parameter; in TEST() 173 nlohmann::json array = nlohmann::json::parse(R"( in TEST() 198 nlohmann::json objWithArray = nlohmann::json::parse(R"( in TEST() 219 nlohmann::json& array = objWithArray["Status"]["Conditions"]; in TEST() 229 nlohmann::json taskResp = R"( in TEST() 242 nlohmann::json taskResp = nlohmann::json::parse(R"(
|
/openbmc/bmcweb/include/ |
H A D | persistent_data.hpp | 68 auto data = nlohmann::json::parse(persistentFile, nullptr, false); in readData() 75 const nlohmann::json::object_t* obj = in readData() 76 data.get_ptr<nlohmann::json::object_t*>(); in readData() 153 const nlohmann::json::object_t* esobj = in readData() 155 .get_ptr<const nlohmann::json::object_t*>(); in readData() 261 nlohmann::json::object_t data; in writeData() 262 nlohmann::json& authConfig = data["auth_config"]; in writeData() 273 nlohmann::json& eventserviceConfig = data["eventservice_config"]; in writeData() 284 nlohmann::json& sessions = data["sessions"]; in writeData() 285 sessions = nlohmann::json::array(); in writeData() [all …]
|
/openbmc/libcper/tests/ |
H A D | test-utils.cpp | 33 nlohmann::json loadJson(const char *filePath) in loadJson() 39 nlohmann::json out = nlohmann::json::parse(file, nullptr, false); in loadJson() 66 void iterate_make_required_props(nlohmann::json &jsonSchema, in iterate_make_required_props() 104 nlohmann::json &propertyFields = *it_prop; in iterate_make_required_props() 105 nlohmann::json::array_t property_list; in iterate_make_required_props() 124 const nlohmann::json *documentLoader(const std::string &uri) in documentLoader() 127 nlohmann::json *ref_schema = new nlohmann::json; in documentLoader() 143 void documentRelease(const nlohmann [all...] |
/openbmc/telemetry/tests/src/ |
H A D | test_persistent_json_storage.cpp | 43 nlohmann::json data = nlohmann::json::object(); in TEST_F() 60 nlohmann::json("data-1a")); in TEST_F() 62 nlohmann::json("data-2a")); in TEST_F() 64 nlohmann::json("data-2b")); in TEST_F() 66 nlohmann::json("data-3a")); in TEST_F() 79 nlohmann::json("data-1a")); in TEST_F() 81 nlohmann::json("data-2a")); in TEST_F() 83 nlohmann::json("data-2b")); in TEST_F() 85 nlohmann::json("data-3a")); in TEST_F() 97 nlohmann::json data = nlohmann::json::object(); in TEST_F() [all …]
|
/openbmc/bmcweb/test/redfish-core/lib/ |
H A D | ethernet_test.cpp | 23 std::vector<std::variant<nlohmann::json::object_t, std::nullptr_t>> addr; in TEST() 39 std::vector<std::variant<nlohmann::json::object_t, std::nullptr_t>> addr; in TEST() 40 nlohmann::json::object_t eth; in TEST() 65 std::vector<std::variant<nlohmann::json::object_t, std::nullptr_t>> addr; in TEST() 66 nlohmann::json::object_t eth; in TEST() 90 std::vector<std::variant<nlohmann::json::object_t, std::nullptr_t>> addr; in TEST() 91 nlohmann::json::object_t eth; in TEST() 111 std::vector<std::variant<nlohmann::json::object_t, std::nullptr_t>> addr; in TEST() 112 nlohmann::json::object_t eth; in TEST() 135 std::vector<std::variant<nlohmann::json::object_t, std::nullptr_t>> addr; in TEST() [all …]
|
/openbmc/bmcweb/redfish-core/src/utils/ |
H A D | json_utils.cpp | 23 nlohmann::json& reqJson) in processJsonFromRequest() 31 reqJson = nlohmann::json::parse(req.body(), nullptr, false); in processJsonFromRequest() 42 uint64_t getEstimatedJsonSize(const nlohmann::json& root) in getEstimatedJsonSize() 65 const nlohmann::json::array_t* arr = in getEstimatedJsonSize() 66 root.get_ptr<const nlohmann::json::array_t*>(); in getEstimatedJsonSize() 76 const nlohmann::json::object_t* object = in getEstimatedJsonSize() 77 root.get_ptr<const nlohmann::json::object_t*>(); in getEstimatedJsonSize()
|