Home
last modified time | relevance | path

Searched refs:jsonValue (Results 1 – 25 of 120) sorted by relevance

12345

/ohos5.0/foundation/resourceschedule/device_standby/services/test/unittest/
H A Dstandby_utils_unit_test.cpp57 nlohmann::json jsonValue {}; variable
62 JsonUtils::GetInt32FromJsonValue(jsonValue, "", value);
79 nlohmann::json jsonValue {}; variable
84 JsonUtils::GetBoolFromJsonValue(jsonValue, "", value);
101 nlohmann::json jsonValue {}; variable
122 nlohmann::json jsonValue {}; variable
127 JsonUtils::GetObjFromJsonValue(jsonValue, "", value);
143 nlohmann::json jsonValue {}; variable
148 JsonUtils::GetArrayFromJsonValue(jsonValue, "", value);
164 nlohmann::json jsonValue {}; variable
[all …]
/ohos5.0/foundation/arkui/ace_engine/test/unittest/base/
H A Djson_util_test.cpp350 JsonValue jsonValue; variable
394 JsonValue jsonValue; variable
416 JsonValue jsonValue; variable
460 JsonValue jsonValue; variable
493 JsonValue jsonValue; variable
514 JsonValue jsonValue; variable
733 JsonValue jsonValue; variable
838 JsonValue jsonValue; variable
859 JsonValue jsonValue; variable
880 JsonValue jsonValue; variable
[all …]
/ohos5.0/foundation/resourceschedule/device_standby/utils/policy/src/
H A Djson_utils.cpp40 if (jsonValue.is_discarded()) { in LoadJsonValueFromContent()
44 if (!jsonValue.is_object()) { in LoadJsonValueFromContent()
63 if (jsonValue.is_discarded()) { in LoadJsonValueFromFile()
67 if (!jsonValue.is_object()) { in LoadJsonValueFromFile()
121 if (jsonValue.contains(key) == 0 || !jsonValue.at(key).is_number_integer()) { in GetInt32FromJsonValue()
133 if (jsonValue.contains(key) == 0 || !jsonValue.at(key).is_boolean()) { in GetBoolFromJsonValue()
145 if (jsonValue.contains(key) == 0 || !jsonValue.at(key).is_string()) { in GetStringFromJsonValue()
157 if (jsonValue.contains(key) == 0 || !jsonValue.at(key).is_object()) { in GetObjFromJsonValue()
160 value = jsonValue.at(key); in GetObjFromJsonValue()
169 if (jsonValue.contains(key) == 0 || !jsonValue.at(key).is_array()) { in GetArrayFromJsonValue()
[all …]
/ohos5.0/base/hiviewdfx/hiappevent/frameworks/cj/ffi/src/
H A Dappevent_watcher_impl.cpp221 retValue.size = jsonValue.size(); in CreatArr()
244 retInt[0] = jsonValue.asInt(); in CreatElmInt()
257 retBool[0] = jsonValue.asBool(); in CreatElmBool()
270 retF[0] = jsonValue.asDouble(); in CreatElmDou()
292 if (jsonValue.isArray()) { in CreateValueByJson()
293 CreatArr(retValue, jsonValue); in CreateValueByJson()
294 } else if (jsonValue.isInt()) { in CreateValueByJson()
296 } else if (jsonValue.isBool()) { in CreateValueByJson()
298 } else if (jsonValue.isDouble()) { in CreateValueByJson()
300 } else if (jsonValue.isString()) { in CreateValueByJson()
[all …]
/ohos5.0/foundation/arkui/ace_engine/frameworks/core/components/common/properties/
H A Dtext_style.cpp89 auto jsonValue = JsonUtil::Create(true); in ToString() local
99 JSON_STRING_PUT_INT(jsonValue, fontWeight_); in ToString()
100 JSON_STRING_PUT_INT(jsonValue, fontStyle_); in ToString()
101 JSON_STRING_PUT_INT(jsonValue, textBaseline_); in ToString()
102 JSON_STRING_PUT_INT(jsonValue, textOverflow_); in ToString()
104 JSON_STRING_PUT_INT(jsonValue, textAlign_); in ToString()
107 JSON_STRING_PUT_INT(jsonValue, whiteSpace_); in ToString()
108 JSON_STRING_PUT_INT(jsonValue, wordBreak_); in ToString()
109 JSON_STRING_PUT_INT(jsonValue, textCase_); in ToString()
110 JSON_STRING_PUT_INT(jsonValue, ellipsisMode_); in ToString()
[all …]
/ohos5.0/foundation/arkui/ace_engine/frameworks/core/components_v2/inspector/
H A Dutils.cpp22 auto jsonValue = JsonUtil::Create(true); in GetTextStyleInJson() local
26 jsonValue->Put("weight", "100"); in GetTextStyleInJson()
28 jsonValue->Put("weight", "200"); in GetTextStyleInJson()
30 jsonValue->Put("weight", "300"); in GetTextStyleInJson()
32 jsonValue->Put("weight", "400"); in GetTextStyleInJson()
34 jsonValue->Put("weight", "500"); in GetTextStyleInJson()
36 jsonValue->Put("weight", "600"); in GetTextStyleInJson()
38 jsonValue->Put("weight", "700"); in GetTextStyleInJson()
40 jsonValue->Put("weight", "800"); in GetTextStyleInJson()
42 jsonValue->Put("weight", "900"); in GetTextStyleInJson()
[all …]
H A Dinspector_composed_element.cpp472 return jsonValue; in GetSize()
632 return jsonValue; in GetUnifyBorder()
655 return jsonValue; in GetPosition()
675 return jsonValue; in GetMarkAnchor()
698 return jsonValue; in GetOffset()
1041 return jsonValue; in GetRotate()
1062 return jsonValue; in GetScale()
1085 return jsonValue; in GetTransform()
1104 return jsonValue; in GetTranslate()
1196 jsonValue->Put( in GetWindowBlur()
[all …]
H A Dlist_item_group_composed_element.cpp55 auto jsonValue = JsonUtil::Create(true); in GetDivider() local
78 jsonValue->Put("strokeWidth", divider->strokeWidth.ToString().c_str()); in GetDivider()
79 jsonValue->Put("color", ConvertColorToString(divider->color).c_str()); in GetDivider()
80 jsonValue->Put("startMargin", divider->startMargin.ToString().c_str()); in GetDivider()
81 jsonValue->Put("endMargin", divider->endMargin.ToString().c_str()); in GetDivider()
82 return jsonValue; in GetDivider()
84 jsonValue->Put("strokeWidth", "0.0vp"); in GetDivider()
85 jsonValue->Put("color", "#FFFFFFFF"); in GetDivider()
86 jsonValue->Put("startMargin", "0.0vp"); in GetDivider()
87 jsonValue->Put("endMargin", "0.0vp"); in GetDivider()
[all …]
H A Dtextarea_composed_element.cpp100 auto jsonValue = JsonUtil::Create(true); in GetPlaceholderFont() local
106 jsonValue->Put("weight", "100"); in GetPlaceholderFont()
108 jsonValue->Put("weight", "200"); in GetPlaceholderFont()
110 jsonValue->Put("weight", "300"); in GetPlaceholderFont()
112 jsonValue->Put("weight", "400"); in GetPlaceholderFont()
114 jsonValue->Put("weight", "500"); in GetPlaceholderFont()
116 jsonValue->Put("weight", "600"); in GetPlaceholderFont()
118 jsonValue->Put("weight", "700"); in GetPlaceholderFont()
120 jsonValue->Put("weight", "800"); in GetPlaceholderFont()
122 jsonValue->Put("weight", "900"); in GetPlaceholderFont()
[all …]
H A Dbadge_composed_element.cpp90 auto jsonValue = JsonUtil::Create(true); in GetBadgePosition() local
93 jsonValue->Put("x", badgeComponent->GetBadgePositionX().ToString().c_str()); in GetBadgePosition()
94 jsonValue->Put("y", badgeComponent->GetBadgePositionY().ToString().c_str()); in GetBadgePosition()
97 return jsonValue->ToString(); in GetBadgePosition()
121 auto jsonValue = JsonUtil::Create(true); in GetStyle() local
125 jsonValue->Put("color", ConvertColorToString(style->GetBadgeTextColor()).c_str()); in GetStyle()
126 jsonValue->Put("fontSize", style->GetBadgeFontSize().ToString().c_str()); in GetStyle()
127 jsonValue->Put("badgeColor", ConvertColorToString(style->GetBadgeColor()).c_str()); in GetStyle()
128 jsonValue->Put("badgeSize", style->GetBadgeCircleSize().ToString().c_str()); in GetStyle()
131 return jsonValue->ToString(); in GetStyle()
H A Dtextinput_composed_element.cpp104 auto jsonValue = JsonUtil::Create(true); in GetPlaceholderFont() local
110 jsonValue->Put("weight", "100"); in GetPlaceholderFont()
112 jsonValue->Put("weight", "200"); in GetPlaceholderFont()
114 jsonValue->Put("weight", "300"); in GetPlaceholderFont()
116 jsonValue->Put("weight", "400"); in GetPlaceholderFont()
118 jsonValue->Put("weight", "500"); in GetPlaceholderFont()
120 jsonValue->Put("weight", "600"); in GetPlaceholderFont()
122 jsonValue->Put("weight", "700"); in GetPlaceholderFont()
124 jsonValue->Put("weight", "800"); in GetPlaceholderFont()
126 jsonValue->Put("weight", "900"); in GetPlaceholderFont()
[all …]
H A Dslider_composed_element.cpp72 auto jsonValue = JsonUtil::Create(true); in GetConstructor() local
73 jsonValue->Put("direction", GetSliderDirection().c_str()); in GetConstructor()
74 jsonValue->Put("value", GetValue().c_str()); in GetConstructor()
75 jsonValue->Put("max", GetMax().c_str()); in GetConstructor()
76 jsonValue->Put("min", GetMin().c_str()); in GetConstructor()
77 jsonValue->Put("step", GetStep().c_str()); in GetConstructor()
78 jsonValue->Put("style", GetStyle().c_str()); in GetConstructor()
79 jsonValue->Put("reverse", GetReverse().c_str()); in GetConstructor()
80 jsonValue->Put("trackThickness", GetThickness().c_str()); in GetConstructor()
81 return jsonValue; in GetConstructor()
/ohos5.0/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/rich_editor/
H A Drich_editor_model.h153 auto jsonValue = JsonUtil::Create(true); in ToString() local
171 return jsonValue->ToString(); in ToString()
190 auto jsonValue = JsonUtil::Create(true); in ToString() local
195 return jsonValue->ToString(); in ToString()
224 auto jsonValue = JsonUtil::Create(true); in ToString() local
231 return jsonValue->ToString(); in ToString()
243 auto jsonValue = JsonUtil::Create(true); in ToString() local
247 return jsonValue->ToString(); in ToString()
261 auto jsonValue = JsonUtil::Create(true); in ToString() local
267 return jsonValue->ToString(); in ToString()
[all …]
/ohos5.0/foundation/arkui/ace_engine/test/unittest/core/render/
H A Drender_property_test_ng.cpp503 auto jsonValue = JsonUtil::Create(true); variable
533 auto jsonValue = JsonUtil::Create(true); variable
574 auto jsonValue = JsonUtil::Create(true); variable
608 auto jsonValue = JsonUtil::Create(true); variable
637 auto jsonValue = JsonUtil::Create(true); variable
667 auto jsonValue = JsonUtil::Create(true); variable
677 EXPECT_EQ(jsonValue->GetString("clip"), "{}");
680 EXPECT_EQ(jsonValue->GetString("clip"), "{}");
695 auto jsonValue = JsonUtil::Create(true); variable
723 auto jsonValue = JsonUtil::Create(true); variable
[all …]
/ohos5.0/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/select_overlay/
H A Dselect_overlay_property.h114 auto jsonValue = JsonUtil::Create(true); in ToString() local
115 JSON_STRING_PUT_BOOL(jsonValue, isShow); in ToString()
116 JSON_STRING_PUT_BOOL(jsonValue, needLayout); in ToString()
118 return jsonValue->ToString(); in ToString()
195 auto jsonValue = JsonUtil::Create(true); in ToString() local
199 JSON_STRING_PUT_BOOL(jsonValue, showCopy); in ToString()
200 JSON_STRING_PUT_BOOL(jsonValue, showPaste); in ToString()
202 JSON_STRING_PUT_BOOL(jsonValue, showCut); in ToString()
204 return jsonValue->ToString(); in ToString()
323 auto jsonValue = JsonUtil::Create(true); in ToString() local
[all …]
/ohos5.0/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/text/
H A Dtext_styles.h79 auto jsonValue = JsonUtil::Create(true); in ToString() local
82 return jsonValue->ToString(); in ToString()
103 auto jsonValue = JsonUtil::Create(true); in ToString() local
109 return jsonValue->ToString(); in ToString()
120 auto jsonValue = JsonUtil::Create(true); in ToString() local
121 JSON_STRING_PUT_OPTIONAL_INT(jsonValue, offset); in ToString()
122 return jsonValue->ToString(); in ToString()
136 auto jsonValue = JsonUtil::Create(true); in ToString() local
137 JSON_STRING_PUT_OPTIONAL_INT(jsonValue, offset); in ToString()
138 JSON_STRING_PUT_OPTIONAL_STRING(jsonValue, image); in ToString()
[all …]
/ohos5.0/foundation/graphic/graphic_3d/lume/LumeRender/api/render/nodecontext/
H A Dintf_render_node_parser_util.h40 …virtual uint64_t GetUintValue(const CORE_NS::json::value& jsonValue, const BASE_NS::string_view na… in RENDER_BEGIN_NAMESPACE()
45 …virtual int64_t GetIntValue(const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name… in RENDER_BEGIN_NAMESPACE()
50 …virtual float GetFloatValue(const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name… in RENDER_BEGIN_NAMESPACE()
56 const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name) const = 0; in RENDER_BEGIN_NAMESPACE()
63 const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name) const = 0; in RENDER_BEGIN_NAMESPACE()
70 const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name) const = 0; in RENDER_BEGIN_NAMESPACE()
77 const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name) const = 0; in RENDER_BEGIN_NAMESPACE()
84 const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name) const = 0; in RENDER_BEGIN_NAMESPACE()
91 const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name) const = 0; in RENDER_BEGIN_NAMESPACE()
98 const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name) const = 0; in RENDER_BEGIN_NAMESPACE()
[all …]
/ohos5.0/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/badge/
H A Dbadge_layout_property.cpp55 auto jsonValue = JsonUtil::Create(true); in ToJsonValue() local
56 jsonValue->Put("x", GetBadgePositionX().value_or(DEFAULT_POSITION_SIZE).ToString().c_str()); in ToJsonValue()
57 jsonValue->Put("y", GetBadgePositionY().value_or(DEFAULT_POSITION_SIZE).ToString().c_str()); in ToJsonValue()
59jsonValue->Put("color", GetBadgeTextColor().value_or(DEFAULT_TEXT_COLOR).ColorToString().c_str()); in ToJsonValue()
60 jsonValue->Put("fontSize", GetBadgeFontSize().value_or(DEFAULT_FONT_SIZE).ToString().c_str()); in ToJsonValue()
61jsonValue->Put("badgeColor", GetBadgeColor().value_or(DEFAULT_BADGE_COLOR).ColorToString().c_str()… in ToJsonValue()
62jsonValue->Put("badgeSize", GetBadgeCircleSize().value_or(DEFAULT_CIRCLE_SIZE).ToString().c_str()); in ToJsonValue()
63 jsonValue->Put( in ToJsonValue()
65jsonValue->Put("borderWidth", GetBadgeBorderWidth().value_or(badgeTheme->GetBadgeBorderWidth()).To… in ToJsonValue()
66 jsonValue->Put( in ToJsonValue()
[all …]
/ohos5.0/foundation/graphic/graphic_3d/lume/LumeRender/src/nodecontext/
H A Drender_node_parser_util.h38 …uint64_t GetUintValue(const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name) cons… in RENDER_BEGIN_NAMESPACE()
39 …int64_t GetIntValue(const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name) const … in RENDER_BEGIN_NAMESPACE()
40 …float GetFloatValue(const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name) const … in RENDER_BEGIN_NAMESPACE()
42 const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name) const override; in RENDER_BEGIN_NAMESPACE()
45 const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name) const override; in RENDER_BEGIN_NAMESPACE()
47 const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name) const override; in RENDER_BEGIN_NAMESPACE()
49 const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name) const override; in RENDER_BEGIN_NAMESPACE()
52 const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name) const override; in RENDER_BEGIN_NAMESPACE()
54 const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name) const override; in RENDER_BEGIN_NAMESPACE()
57 const CORE_NS::json::value& jsonValue, const BASE_NS::string_view name) const override; in RENDER_BEGIN_NAMESPACE()
[all …]
/ohos5.0/foundation/resourceschedule/device_standby/utils/policy/include/
H A Djson_utils.h37 static bool LoadJsonValueFromFile(nlohmann::json& jsonValue, const std::string& filePath);
46 static bool LoadJsonValueFromContent(nlohmann::json& jsonValue, const std::string& content);
55 static bool DumpJsonValueToFile(const nlohmann::json& jsonValue, const std::string& filePath);
65 …static bool GetInt32FromJsonValue(const nlohmann::json& jsonValue, const std::string& key, int32_t…
75 …static bool GetBoolFromJsonValue(const nlohmann::json& jsonValue, const std::string& key, bool& va…
85 …static bool GetStringFromJsonValue(const nlohmann::json& jsonValue, const std::string& key, std::s…
95 …static bool GetObjFromJsonValue(const nlohmann::json& jsonValue, const std::string& key, nlohmann:…
105 …static bool GetArrayFromJsonValue(const nlohmann::json& jsonValue, const std::string& key, nlohman…
115 static bool GetStrArrFromJsonValue(const nlohmann::json& jsonValue, const std::string& key,
/ohos5.0/base/notification/distributed_notification_service/frameworks/ans/test/unittest/
H A Dreminder_request_test.cpp1858 std::string jsonValue = ""; variable
1862 jsonValue = "{}";
1866 jsonValue = R"({"pkgName":1})";
1920 std::string jsonValue = ""; variable
1928 jsonValue = R"(})";
1932 jsonValue = R"({})";
1995 std::string jsonValue = ""; variable
2000 jsonValue = R"({})";
2004 jsonValue = R"({"type":1})";
2008 jsonValue = R"({"type":"a"})";
[all …]
/ohos5.0/foundation/arkui/ace_engine/frameworks/core/components_ng/render/
H A Drender_property.cpp229 auto jsonValue = JsonUtil::Create(true); in ToJsonValue() local
230 jsonValue->Put("x", 0.0); in ToJsonValue()
231 jsonValue->Put("y", 0.0); in ToJsonValue()
339 auto jsonValue = JsonUtil::Create(true); in ToJsonValue() local
345 jsonValue->Put("centerX", center.GetX().ToString().c_str()); in ToJsonValue()
346 jsonValue->Put("centerY", center.GetY().ToString().c_str()); in ToJsonValue()
352 json->PutExtAttr("rotate", jsonValue, filter); in ToJsonValue()
358 auto jsonValue = JsonUtil::Create(true); in ToJsonValue() local
363 json->PutExtAttr("scale", jsonValue, filter); in ToJsonValue()
369 auto jsonValue = JsonUtil::Create(true); in ToJsonValue() local
[all …]
/ohos5.0/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/swiper/
H A Dswiper_helper.cpp378 auto jsonValue = JsonUtil::Create(true); in GetDotIndicatorStyle() local
387 jsonValue->Put( in GetDotIndicatorStyle()
391 jsonValue->Put( in GetDotIndicatorStyle()
393 return jsonValue->ToString(); in GetDotIndicatorStyle()
408 jsonValue->Put( in GetDigitIndicatorStyle()
410 jsonValue->Put("fontColor", in GetDigitIndicatorStyle()
412 jsonValue->Put( in GetDigitIndicatorStyle()
414 jsonValue->Put("selectedFontSize", in GetDigitIndicatorStyle()
416 jsonValue->Put( in GetDigitIndicatorStyle()
420 jsonValue->Put("selectedFontWeight", in GetDigitIndicatorStyle()
[all …]
/ohos5.0/foundation/arkui/ace_engine/frameworks/base/log/
H A Dlog_wrapper.h94 #define JSON_STRING_PUT_INT(jsonValue, var) (jsonValue)->Put(#var, static_cast<int64_t>(var)) argument
95 #define JSON_STRING_PUT_BOOL(jsonValue, var) (jsonValue)->Put(#var, (var)) argument
96 #define JSON_STRING_PUT_STRING(jsonValue, var) (jsonValue)->Put(#var, (var).c_str()) argument
97 #define JSON_STRING_PUT_STRINGABLE(jsonValue, var) (jsonValue)->Put(#var, (var).ToString().c_str()) argument
99 #define JSON_STRING_PUT_OPTIONAL_INT(jsonValue, var) \ argument
102 (jsonValue)->Put(#var, static_cast<int64_t>(*(var))); \
106 #define JSON_STRING_PUT_OPTIONAL_STRING(jsonValue, var) \ argument
109 (jsonValue)->Put(#var, (var)->c_str()); \
114 #define JSON_STRING_PUT_OPTIONAL_STRINGABLE(jsonValue, var) \ argument
117 (jsonValue)->Put(#var, (var)->ToString().c_str()); \
/ohos5.0/base/security/appverify/interfaces/innerkits/appverify/src/init/
H A Djson_parser_utils.cpp60 cJSON* jsonValue = cJSON_GetObjectItemCaseSensitive(json, key.c_str()); in GetJsonString() local
61 if (jsonValue != NULL && cJSON_IsString(jsonValue)) { in GetJsonString()
62 value = jsonValue->valuestring; in GetJsonString()
72 cJSON* jsonValue = cJSON_GetObjectItemCaseSensitive(json, key.c_str()); in GetJsonInt() local
73 if (jsonValue != NULL && cJSON_IsNumber(jsonValue)) { in GetJsonInt()
74 value = jsonValue->valueint; in GetJsonInt()

12345