/ohos5.0/base/update/updater/utils/json/ |
H A D | json_node.cpp | 34 JsonNode::JsonNode() : type_ {NodeType::UNKNOWN} in JsonNode() function in Updater::JsonNode 38 JsonNode::JsonNode(const std::string &str, bool needDelete) : JsonNode(cJSON_Parse(str.c_str()), ne… in JsonNode() function in Updater::JsonNode 42 JsonNode::JsonNode(const Fs::path &path) in JsonNode() function in Updater::JsonNode 67 JsonNode::JsonNode(const cJSON *root, bool needDelete) in JsonNode() function in Updater::JsonNode 141 JsonNode::~JsonNode() = default; 143 JsonNode &JsonNode::operator[](int idx) in operator []() 148 JsonNode &JsonNode::operator[](const std::string &key) in operator []() 153 const JsonNode &JsonNode::operator[](int idx) const 158 const JsonNode &JsonNode::operator[](const std::string &key) const 163 std::list<std::reference_wrapper<JsonNode>>::const_iterator JsonNode::begin() const [all …]
|
H A D | json_node.h | 35 class JsonNode; variable 40 using NodeVec = std::vector<std::unique_ptr<JsonNode>>; 46 class JsonNode { 47 DISALLOW_COPY_MOVE(JsonNode); 49 JsonNode(); 50 explicit JsonNode(const Fs::path &path); 53 ~JsonNode(); 55 const JsonNode &operator[](int idx) const; 57 JsonNode &operator[](int idx); 58 JsonNode &operator[](const std::string &key); [all …]
|
H A D | json_visitor.h | 47 …static bool VisitStruct(const JsonNode &node, const JsonNode &defaultNode, T &t, std::index_sequen… in VisitStruct() 69 …static bool VisitMember(const JsonNode &node, const JsonNode &defaultNode, T &obj, const char *key) 89 …static auto VisitMember(const JsonNode &node, const JsonNode &defaultNode, T &obj, const char *key) 117 …static bool VisitMember(const JsonNode &node, const JsonNode &defaultNode, T &obj, const char *key) 126 bool Visit(const JsonNode &node, T &obj) 133 bool Visit(const JsonNode &node, const JsonNode &defaultNode, T &obj) 142 bool Visit(const JsonNode &node, T &obj)
|
/ohos5.0/base/update/updater/test/unittest/utils/json/ |
H A D | utils_json_test.cpp | 71 JsonNode node(str); 78 JsonNode node(str); 86 JsonNode node(str); 94 JsonNode node(str); 102 JsonNode node(str); 113 JsonNode node(str); 121 JsonNode node(str); 128 JsonNode node(str); 152 JsonNode node(str); 169 JsonNode node(str); [all …]
|
H A D | utils_json_visitor_test.cpp | 95 JsonNode node {newJsonStr}; in TestInvalidCases() 103 JsonNode node {newJsonStr}; in TestInvalidCases() 145 JsonNode node {dJson}; 172 JsonNode node {eJson}; 208 JsonNode node {hJson}; 241 JsonNode node {iJson}; 292 JsonNode node {kJson}; 294 EXPECT_EQ(Visit<SETVAL>(node["KNonDefault0"], JsonNode {"{"s}, k), false); 295 EXPECT_EQ(Visit<SETVAL>(JsonNode {"{"s}, node["KNonDefault0"], k), false); 310 JsonNode node {lJson}; [all …]
|
/ohos5.0/base/update/updater/test/fuzztest/updaterutils_fuzzer/ |
H A D | updater_utils_fuzzer.cpp | 154 JsonNode node(str); in TestJsonNodeKey() 161 JsonNode node(str); in TestJsonNodeValueTypeStr() 169 JsonNode node(str); in TestJsonNodeValueTypeInt() 177 JsonNode node(str); in TestJsonNodeValueTypeBool() 185 JsonNode node(str); in TestJsonNodeValueTypeArray() 196 JsonNode node(str); in TestJsonNodeValueTypeObject() 204 JsonNode node(str); in TestJsonNodeValueTypeNull() 211 JsonNode node(str); in TestJsonNodeValueTypeUnknow() 235 JsonNode node(str); in TestJsonNodeValueTypeJsonNode() 252 JsonNode node(str); in TestJsonNodeKey1Type() [all …]
|
/ohos5.0/base/update/updater/services/ui/ |
H A D | updater_ui_config.cpp | 70 std::string SelectConfig(const JsonNode &node) in SelectConfig() 74 const JsonNode &subCfgPathNode = iter.get(); in SelectConfig() 81 const JsonNode &subCfg = JsonNode { Fs::path { subConfigPath }}; in SelectConfig() 104 JsonNode node { Fs::path { UI_CFG_FILE }}; in Init() 105 const JsonNode &cfgNode = node[UI_CFG_KEY]; in Init() 113 JsonNode realNode { Fs::path { *optString }}; in Init() 131 bool UpdaterUiConfig::Init(const JsonNode &node) in Init() 149 bool UpdaterUiConfig::LoadPages(const JsonNode &node) in LoadPages() 174 bool UpdaterUiConfig::LoadLangRes(const JsonNode &node) in LoadLangRes() 179 bool UpdaterUiConfig::LoadStrategy(const JsonNode &node) in LoadStrategy() [all …]
|
H A D | updater_ui_config.h | 32 static bool Init(const JsonNode &node); 33 static bool LoadStrategy(const JsonNode &node); 34 static bool LoadPages(const JsonNode &node); 35 static bool LoadLangRes(const JsonNode &node); 36 static bool LoadCallbacks(const JsonNode &node); 37 static bool LoadFocusCfg(const JsonNode &node);
|
/ohos5.0/base/update/updater/test/unittest/updater_ui_test/lang/ |
H A D | ui_language_unittest.cpp | 91 EXPECT_EQ(LanguageUI::GetInstance().LoadLangRes(JsonNode {}), false); 97 EXPECT_EQ(LanguageUI::GetInstance().LoadLangRes(JsonNode {GetTestJson(langRes)}), false); 101 EXPECT_EQ(LanguageUI::GetInstance().LoadLangRes(JsonNode {GetTestJson(langRes)}), false); 105 EXPECT_EQ(LanguageUI::GetInstance().LoadLangRes(JsonNode {GetTestJson(langRes)}), false); 114 EXPECT_EQ(LanguageUI::GetInstance().LoadLangRes(JsonNode {GetTestJson(langRes)}), false); 135 EXPECT_EQ(LanguageUI::GetInstance().LoadLangRes(JsonNode {GetTestJson(langRes)}), false); 146 EXPECT_EQ(LanguageUI::GetInstance().LoadLangRes(JsonNode {GetTestJson(langRes)}), false); 170 EXPECT_EQ(LanguageUI::GetInstance().LoadLangRes(JsonNode {GetTestJson(langRes)}), true); 194 EXPECT_EQ(LanguageUI::GetInstance().LoadLangRes(JsonNode {GetTestJson(langRes)}), true); 201 EXPECT_EQ(LanguageUI::GetInstance().LoadLangRes(JsonNode {GetTestJson(langRes)}), true); [all …]
|
/ohos5.0/base/update/updater/services/ui/view/layout/ |
H A D | layout_parser.cpp | 53 JsonNode node {std::filesystem::path {filename}}; in LoadLayout() 70 bool ParseViewInfo(const JsonNode &root, std::vector<UxViewInfo> &vec) const in ParseViewInfo() 74 const JsonNode &defaultNode = root[DEFAULT_MODULE]; in ParseViewInfo() 75 const JsonNode &componentNodes = root[COMPONENT_MODULE]; in ParseViewInfo() 81 const JsonNode &comNode = componentNode.get(); in ParseViewInfo() 87 const JsonNode &commonDefault = defaultNode[COMMON_LABEL]; in ParseViewInfo() 100 … const JsonNode &defaultComNode = defaultNode[Traits<std::decay_t<decltype(args)>>::STRUCT_KEY]; in ParseViewInfo()
|
H A D | layout_interface.h | 23 virtual void SetJsonLocation(JsonNode &root) = 0;
|
H A D | auto_layout.h | 25 void SetJsonLocation(JsonNode &root);
|
H A D | auto_layout.cpp | 40 void AutoLayout::SetJsonLocation(JsonNode &root) in SetJsonLocation()
|
/ohos5.0/base/update/sys_installer/services/module_update/util/src/ |
H A D | module_update_verify.cpp | 35 bool GetHmpType(const JsonNode &root, std::string &type) in GetHmpType() 37 const JsonNode &typeJson = root["type"]; in GetHmpType() 75 bool GetPackInfoVer(const JsonNode &root, const std::string &key, std::string &version) in GetPackInfoVer() 77 const JsonNode &package = root["package"]; in GetPackInfoVer() 92 JsonNode root(packInfo); in CheckPackInfoVer()
|
H A D | module_file.cpp | 114 bool ParseHmpVersionInfo(const JsonNode &package, ModulePackageInfo &versionInfo) in ParseHmpVersionInfo() 171 bool ParseSaList(const JsonNode &package, ModulePackageInfo &versionInfo) in ParseSaList() 196 bool ParseBundleList(const JsonNode &package, ModulePackageInfo &versionInfo) in ParseBundleList() 220 JsonNode root(packInfo); in ParseModuleInfo() 221 const JsonNode &type = root["type"]; in ParseModuleInfo() 229 const JsonNode &package = root["package"]; in ParseModuleInfo()
|
/ohos5.0/base/global/i18n_lite/tools/i18n-dat-tool/src/main/java/ohos/global/i18n/ |
H A D | ResourceConfiguration.java | 19 import org.codehaus.jackson.JsonNode; 50 JsonNode jsonNode = mapper.readTree(json); in parse() 51 Iterator<JsonNode> jsonNodes = jsonNode.getElements(); in parse() 54 JsonNode node = jsonNodes.next(); in parse()
|
/ohos5.0/base/update/updater/services/ui/strategy/ |
H A D | ui_strategy.cpp | 73 bool UiStrategy::LoadStrategy(const JsonNode &node, const std::string &mode) in LoadStrategy() 79 const JsonNode &defaultNode = node[Traits<UiStrategyCfg>::STRUCT_KEY][DEFAULT_KEY]; in LoadStrategy() 80 const JsonNode &specificNode = node[Traits<UiStrategyCfg>::STRUCT_KEY][*it]; in LoadStrategy() 89 bool UiStrategy::LoadStrategy(const JsonNode &node) in LoadStrategy()
|
H A D | ui_strategy.h | 33 static bool LoadStrategy(const JsonNode &node); 36 static bool LoadStrategy(const JsonNode &node, const std::string &mode);
|
/ohos5.0/base/update/updater/services/ui/language/ |
H A D | language_ui.cpp | 95 JsonNode root {std::filesystem::path { file }}; in ParseJson() 112 const JsonNode &strNode = node.get(); in ParseJson() 150 bool LanguageUI::LoadLangRes(const JsonNode &node) in LoadLangRes()
|
H A D | language_ui.h | 41 [[nodiscard]] bool LoadLangRes(const JsonNode &node);
|
/ohos5.0/base/update/updater/services/ui/control/ |
H A D | callback_manager.cpp | 33 bool CallbackManager::LoadCallbacks(const JsonNode &node) in LoadCallbacks() 35 const JsonNode &cbNodes = node[CB_FIELD]; in LoadCallbacks()
|
H A D | callback_manager.h | 32 static bool LoadCallbacks(const JsonNode &node);
|
/ohos5.0/base/update/updater/test/unittest/updater_ui_test/strategy/ |
H A D | ui_strategy_unittest.cpp | 60 …EXPECT_FALSE(UiStrategy::LoadStrategy(JsonNode {Fs::path {"/data/updater/ui/strategy/strategy_inva… 66 …EXPECT_TRUE(UiStrategy::LoadStrategy(JsonNode {Fs::path {"/data/updater/ui/strategy/strategy_valid…
|
/ohos5.0/base/update/updater/test/unittest/updater_ui_test/view/ |
H A D | ui_view_api_unittest.cpp | 69 EXPECT_EQ(LanguageUI::GetInstance().LoadLangRes(JsonNode {jsonStr}), true);
|
/ohos5.0/base/update/sys_installer/services/module_update/service/src/ |
H A D | module_update_main.cpp | 442 JsonNode root(packInfo); in GetHmpVersion() 443 const JsonNode &package = root["package"]; in GetHmpVersion() 456 const JsonNode &laneInfoNode = package["laneInfo"]; in GetHmpVersion()
|