/external/libchrome/base/json/ |
D | json_reader_unittest.cc | 25 std::unique_ptr<Value> root = JSONReader().ReadToValue(" null "); in TEST() 31 EXPECT_FALSE(JSONReader().ReadToValue("nu")); in TEST() 35 std::unique_ptr<Value> root = JSONReader().ReadToValue("true "); in TEST() 41 std::unique_ptr<Value> root = JSONReader().ReadToValue("/* comment */null"); in TEST() 44 root = JSONReader().ReadToValue("40 /* comment */"); in TEST() 47 root = JSONReader().ReadToValue("true // comment"); in TEST() 50 root = JSONReader().ReadToValue("/* comment */\"sample string\""); in TEST() 57 ListValue::From(JSONReader().ReadToValue("[1, /* comment, 2 ] */ \n 3]")); in TEST() 65 list = ListValue::From(JSONReader().ReadToValue("[1, /*a*/2, 3]")); in TEST() 68 root = JSONReader().ReadToValue("/* comment **/42"); in TEST() [all …]
|
D | json_reader.cc | 19 const int JSONReader::kStackMaxDepth = 200; 22 static_assert(JSONReader::JSON_PARSE_ERROR_COUNT < 1000, 25 const char JSONReader::kInvalidEscape[] = 27 const char JSONReader::kSyntaxError[] = 29 const char JSONReader::kUnexpectedToken[] = 31 const char JSONReader::kTrailingComma[] = 33 const char JSONReader::kTooMuchNesting[] = 35 const char JSONReader::kUnexpectedDataAfterRoot[] = 37 const char JSONReader::kUnsupportedEncoding[] = 39 const char JSONReader::kUnquotedDictionaryKey[] = [all …]
|
D | json_parser_unittest.cc | 228 std::unique_ptr<Value> root = JSONReader::ReadAndReturnError( in TEST_F() 236 root = JSONReader::ReadAndReturnError(big_json, JSON_PARSE_RFC, &error_code, in TEST_F() 239 EXPECT_EQ(JSONParser::FormatErrorMessage(5, 10, JSONReader::kSyntaxError), in TEST_F() 241 EXPECT_EQ(JSONReader::JSON_SYNTAX_ERROR, error_code); in TEST_F() 249 root = JSONReader::ReadAndReturnError(big_json_crlf, JSON_PARSE_RFC, in TEST_F() 252 EXPECT_EQ(JSONParser::FormatErrorMessage(5, 10, JSONReader::kSyntaxError), in TEST_F() 254 EXPECT_EQ(JSONReader::JSON_SYNTAX_ERROR, error_code); in TEST_F() 257 root = JSONReader::ReadAndReturnError("{},{}", JSON_PARSE_RFC, &error_code, in TEST_F() 261 JSONReader::kUnexpectedDataAfterRoot), error_message); in TEST_F() 262 EXPECT_EQ(JSONReader::JSON_UNEXPECTED_DATA_AFTER_ROOT, error_code); in TEST_F() [all …]
|
D | json_parser.cc | 65 error_code_(JSONReader::JSON_NO_ERROR), in JSONParser() 68 CHECK_LE(max_depth, JSONReader::kStackMaxDepth); in JSONParser() 79 error_code_ = JSONReader::JSON_NO_ERROR; in Parse() 86 ReportError(JSONReader::JSON_TOO_LARGE, 0); in Parse() 102 ReportError(JSONReader::JSON_UNEXPECTED_DATA_AFTER_ROOT, 1); in Parse() 109 JSONReader::JsonParseError JSONParser::error_code() const { in error_code() 115 JSONReader::ErrorCodeToString(error_code_)); in GetErrorMessage() 323 ReportError(JSONReader::JSON_UNEXPECTED_TOKEN, 1); in ParseToken() 330 ReportError(JSONReader::JSON_UNEXPECTED_TOKEN, 1); in ConsumeDictionary() 336 ReportError(JSONReader::JSON_TOO_MUCH_NESTING, 0); in ConsumeDictionary() [all …]
|
D | json_parser.h | 46 JSONParser(int options, int max_depth = JSONReader::kStackMaxDepth); 56 JSONReader::JsonParseError error_code() const; 207 void ReportError(JSONReader::JsonParseError code, int column_adjust); 236 JSONReader::JsonParseError error_code_;
|
D | json_value_converter_unittest.cc | 108 std::unique_ptr<Value> value = base::JSONReader::Read(normal_data); in TEST() 150 std::unique_ptr<Value> value = base::JSONReader::Read(normal_data); in TEST() 192 std::unique_ptr<Value> value = base::JSONReader::Read(normal_data); in TEST() 208 std::unique_ptr<Value> value = base::JSONReader::Read(normal_data); in TEST() 231 std::unique_ptr<Value> value = base::JSONReader::Read(normal_data); in TEST() 248 std::unique_ptr<Value> value = base::JSONReader::Read(normal_data); in TEST()
|
D | json_reader.h | 59 class BASE_EXPORT JSONReader { 90 JSONReader(int options = JSON_PARSE_RFC, int max_depth = kStackMaxDepth); 92 ~JSONReader();
|
D | json_correctness_fuzzer.cc | 38 auto parsed_value = base::JSONReader::ReadAndReturnError( in LLVMFuzzerTestOneInput() 48 auto double_parsed_value = base::JSONReader::ReadAndReturnError( in LLVMFuzzerTestOneInput()
|
D | json_value_serializer_unittest.cc | 79 std::unique_ptr<ListValue> list = ListValue::From(JSONReader::Read(json)); in ValidateJsonList() 142 ASSERT_EQ(JSONReader::JSON_TRAILING_COMMA, error_code); in TEST() 196 ASSERT_EQ(JSONReader::JSON_TRAILING_COMMA, error_code); in TEST() 382 ListValue::From(JSONReader::Read("[\"// ok\\n /* foo */ \"]")); in TEST() 392 ASSERT_FALSE(JSONReader::Read("/* /* inner */ outer */ [ 1 ]")); in TEST() 395 ASSERT_FALSE(JSONReader::Read("/ * * / [1]")); in TEST()
|
D | json_reader_fuzzer.cc | 24 base::JSONReader::ReadAndReturnError(input_string, options, &error_code, in LLVMFuzzerTestOneInput()
|
D | json_string_value_serializer.cc | 53 return base::JSONReader::ReadAndReturnError(json_string_, options_, in Deserialize()
|
/external/libchrome/base/metrics/ |
D | statistics_recorder_unittest.cc | 362 std::unique_ptr<Value> root = JSONReader::Read(json); in TEST_P() 389 root = JSONReader::Read(json); in TEST_P()
|
/external/libbrillo/brillo/http/ |
D | http_transport_fake.cc | 183 auto value = base::JSONReader::Read(GetDataAsString()); in GetDataAsJson()
|
D | http_utils.cc | 399 auto value = base::JSONReader::ReadAndReturnError(json, base::JSON_PARSE_RFC, in ParseJsonResponse()
|
/external/libbrillo/brillo/ |
D | value_conversion_unittest.cc | 34 auto value = base::JSONReader::ReadAndReturnError(json, base::JSON_PARSE_RFC, in ParseValue()
|
/external/libchrome/components/policy/core/common/ |
D | registry_dict.cc | 129 base::JSONReader::Read(string_value); in ConvertRegistryValue()
|
/external/libbrillo/policy/ |
D | device_policy_impl.cc | 152 base::JSONReader::ReadAndReturnError(json_string, in DecodeListValueFromJSON()
|
/external/libchrome/components/json_schema/ |
D | json_schema_validator.cc | 418 std::unique_ptr<base::Value> json = base::JSONReader::ReadAndReturnError( in IsValidSchema()
|