Home
last modified time | relevance | path

Searched refs:JSONReader (Results 1 – 25 of 211) sorted by relevance

123456789

/external/chromium/base/json/
Djson_reader_unittest.cc18 root.reset(JSONReader().JsonToValue(" null ", false, false)); in TEST()
23 root.reset(JSONReader().JsonToValue("nu", false, false)); in TEST()
27 root.reset(JSONReader().JsonToValue("true ", false, false)); in TEST()
32 root.reset(JSONReader().JsonToValue("/* comment */null", false, false)); in TEST()
35 root.reset(JSONReader().JsonToValue("40 /* comment */", false, false)); in TEST()
38 root.reset(JSONReader().JsonToValue("true // comment", false, false)); in TEST()
41 root.reset(JSONReader().JsonToValue("/* comment */\"sample string\"", in TEST()
50 root.reset(JSONReader().JsonToValue("43", false, false)); in TEST()
58 root.reset(JSONReader().JsonToValue("043", false, false)); in TEST()
60 root.reset(JSONReader().JsonToValue("0x43", false, false)); in TEST()
[all …]
Djson_reader.cc17 static const JSONReader::Token kInvalidToken(JSONReader::Token::INVALID_TOKEN,
26 bool ReadInt(JSONReader::Token& token, bool can_have_leading_zeros) { in ReadInt()
50 bool ReadHexDigits(JSONReader::Token& token, int digits) { in ReadHexDigits()
67 const char* JSONReader::kBadRootElementType =
69 const char* JSONReader::kInvalidEscape =
71 const char* JSONReader::kSyntaxError =
73 const char* JSONReader::kTrailingComma =
75 const char* JSONReader::kTooMuchNesting =
77 const char* JSONReader::kUnexpectedDataAfterRoot =
79 const char* JSONReader::kUnsupportedEncoding =
[all …]
Djson_reader.h50 class BASE_API JSONReader {
110 JSONReader();
216 DISALLOW_COPY_AND_ASSIGN(JSONReader);
/external/chromium_org/base/json/
Djson_reader.cc13 COMPILE_ASSERT(JSONReader::JSON_PARSE_ERROR_COUNT < 1000,
16 const char* JSONReader::kInvalidEscape =
18 const char* JSONReader::kSyntaxError =
20 const char* JSONReader::kUnexpectedToken =
22 const char* JSONReader::kTrailingComma =
24 const char* JSONReader::kTooMuchNesting =
26 const char* JSONReader::kUnexpectedDataAfterRoot =
28 const char* JSONReader::kUnsupportedEncoding =
30 const char* JSONReader::kUnquotedDictionaryKey =
33 JSONReader::JSONReader() in JSONReader() function in base::JSONReader
[all …]
Djson_reader_unittest.cc23 root.reset(JSONReader().ReadToValue(" null ")); in TEST()
28 root.reset(JSONReader().ReadToValue("nu")); in TEST()
32 root.reset(JSONReader().ReadToValue("true ")); in TEST()
37 root.reset(JSONReader().ReadToValue("/* comment */null")); in TEST()
40 root.reset(JSONReader().ReadToValue("40 /* comment */")); in TEST()
43 root.reset(JSONReader().ReadToValue("true // comment")); in TEST()
46 root.reset(JSONReader().ReadToValue("/* comment */\"sample string\"")); in TEST()
52 root.reset(JSONReader().ReadToValue("[1, /* comment, 2 ] */ \n 3]")); in TEST()
61 root.reset(JSONReader().ReadToValue("[1, /*a*/2, 3]")); in TEST()
65 root.reset(JSONReader().ReadToValue("/* comment **/42")); in TEST()
[all …]
Djson_parser_unittest.cc207 root.reset(JSONReader::ReadAndReturnError("[42]", JSON_PARSE_RFC, in TEST_F()
215 root.reset(JSONReader::ReadAndReturnError(big_json, JSON_PARSE_RFC, in TEST_F()
218 EXPECT_EQ(JSONParser::FormatErrorMessage(5, 10, JSONReader::kSyntaxError), in TEST_F()
220 EXPECT_EQ(JSONReader::JSON_SYNTAX_ERROR, error_code); in TEST_F()
228 root.reset(JSONReader::ReadAndReturnError(big_json_crlf, JSON_PARSE_RFC, in TEST_F()
231 EXPECT_EQ(JSONParser::FormatErrorMessage(5, 10, JSONReader::kSyntaxError), in TEST_F()
233 EXPECT_EQ(JSONReader::JSON_SYNTAX_ERROR, error_code); in TEST_F()
236 root.reset(JSONReader::ReadAndReturnError("{},{}", JSON_PARSE_RFC, in TEST_F()
240 JSONReader::kUnexpectedDataAfterRoot), error_message); in TEST_F()
241 EXPECT_EQ(JSONReader::JSON_UNEXPECTED_DATA_AFTER_ROOT, error_code); in TEST_F()
[all …]
Djson_parser.cc196 error_code_(JSONReader::JSON_NO_ERROR), in JSONParser()
221 error_code_ = JSONReader::JSON_NO_ERROR; in Parse()
243 ReportError(JSONReader::JSON_UNEXPECTED_DATA_AFTER_ROOT, 1); in Parse()
267 JSONReader::JsonParseError JSONParser::error_code() const { in error_code()
273 JSONReader::ErrorCodeToString(error_code_)); in GetErrorMessage()
475 ReportError(JSONReader::JSON_UNEXPECTED_TOKEN, 1); in ParseToken()
482 ReportError(JSONReader::JSON_UNEXPECTED_TOKEN, 1); in ConsumeDictionary()
488 ReportError(JSONReader::JSON_TOO_MUCH_NESTING, 1); in ConsumeDictionary()
498 ReportError(JSONReader::JSON_UNQUOTED_DICTIONARY_KEY, 1); in ConsumeDictionary()
512 ReportError(JSONReader::JSON_SYNTAX_ERROR, 1); in ConsumeDictionary()
[all …]
Djson_reader.h63 class BASE_EXPORT JSONReader {
90 JSONReader();
93 explicit JSONReader(int options);
95 ~JSONReader();
Djson_value_converter_unittest.cc109 scoped_ptr<Value> value(base::JSONReader::Read(normal_data)); in TEST()
151 scoped_ptr<Value> value(base::JSONReader::Read(normal_data)); in TEST()
193 scoped_ptr<Value> value(base::JSONReader::Read(normal_data)); in TEST()
209 scoped_ptr<Value> value(base::JSONReader::Read(normal_data)); in TEST()
232 scoped_ptr<Value> value(base::JSONReader::Read(normal_data)); in TEST()
249 scoped_ptr<Value> value(base::JSONReader::Read(normal_data)); in TEST()
Djson_parser.h70 JSONReader::JsonParseError error_code() const;
219 void ReportError(JSONReader::JsonParseError code, int column_adjust);
252 JSONReader::JsonParseError error_code_;
Djson_value_serializer_unittest.cc63 scoped_ptr<Value> root(JSONReader::Read(json)); in ValidateJsonList()
109 ASSERT_EQ(JSONReader::JSON_TRAILING_COMMA, error_code); in TEST()
163 ASSERT_EQ(JSONReader::JSON_TRAILING_COMMA, error_code); in TEST()
355 root.reset(JSONReader::Read("[\"// ok\\n /* foo */ \"]")); in TEST()
366 root.reset(JSONReader::Read("/* /* inner */ outer */ [ 1 ]")); in TEST()
370 root.reset(JSONReader::Read("/ * * / [1]")); in TEST()
/external/chromium_org/components/policy/core/common/
Dconfig_dir_policy_loader.cc41 case base::JSONReader::JSON_INVALID_ESCAPE: in JsonErrorToPolicyLoadStatus()
42 case base::JSONReader::JSON_SYNTAX_ERROR: in JsonErrorToPolicyLoadStatus()
43 case base::JSONReader::JSON_UNEXPECTED_TOKEN: in JsonErrorToPolicyLoadStatus()
44 case base::JSONReader::JSON_TRAILING_COMMA: in JsonErrorToPolicyLoadStatus()
45 case base::JSONReader::JSON_TOO_MUCH_NESTING: in JsonErrorToPolicyLoadStatus()
46 case base::JSONReader::JSON_UNEXPECTED_DATA_AFTER_ROOT: in JsonErrorToPolicyLoadStatus()
47 case base::JSONReader::JSON_UNSUPPORTED_ENCODING: in JsonErrorToPolicyLoadStatus()
48 case base::JSONReader::JSON_UNQUOTED_DICTIONARY_KEY: in JsonErrorToPolicyLoadStatus()
50 case base::JSONReader::JSON_NO_ERROR: in JsonErrorToPolicyLoadStatus()
/external/chromium/chrome/browser/web_resource/
Dpromo_resource_service_unittest.cc51 base::JSONReader::Read(json, false))); in TEST_F()
82 base::JSONReader::Read(json, false))); in TEST_F()
101 base::JSONReader::Read(json, false))); in TEST_F()
144 base::JSONReader::Read(json, false))); in TEST_F()
216 base::JSONReader::Read(json, false))); in TEST_F()
/external/chromium_org/chrome/test/chromedriver/chrome/
Ddom_tracker_unittest.cc63 params.Set("nodes", base::JSONReader::Read(nodes)); in TEST()
82 params.Set("node", base::JSONReader::Read("{\"nodeId\":1}")); in TEST()
89 params.Set("node", base::JSONReader::Read( in TEST()
Dframe_tracker_unittest.cc23 params.Set("context", base::JSONReader::Read(context)); in TEST()
51 params.Set("context", base::JSONReader::Read(context)); in TEST()
/external/chromium_org/net/base/
Dnet_log_logger_unittest.cc40 base::JSONReader reader; in TEST_F()
72 base::JSONReader reader; in TEST_F()
107 base::JSONReader reader; in TEST_F()
/external/chromium_org/cloud_print/gcp20/prototype/
Dcloud_print_response_parser.cc62 scoped_ptr<base::Value> json(base::JSONReader::Read(response)); in ParseRegisterStartResponse()
130 scoped_ptr<base::Value> json(base::JSONReader::Read(response)); in ParseRegisterCompleteResponse()
165 scoped_ptr<base::Value> json(base::JSONReader::Read(response)); in ParseFetchResponse()
217 scoped_ptr<base::Value> json(base::JSONReader::Read(response)); in ParseLocalSettingsResponse()
Dprinter_unittest.cc18 base::JSONReader::ReadAndReturnError(printer.GetRawCdd(), 0, in TEST()
/external/chromium_org/remoting/host/native_messaging/
Dnative_messaging_writer_unittest.cc67 scoped_ptr<base::Value> written_message(base::JSONReader::Read(content)); in TEST_F()
102 scoped_ptr<base::Value> written_message2(base::JSONReader::Read(content)); in TEST_F()
/external/chromium_org/chrome/browser/devtools/
Ddevtools_protocol.cc68 scoped_ptr<base::Value> value(base::JSONReader::Read(json)); in ParseNotification()
86 scoped_ptr<base::Value> value(base::JSONReader::Read(json)); in ParseResponse()
/external/chromium/chrome/browser/ui/webui/options/
Dsync_setup_handler.cc44 scoped_ptr<Value> parsed_value(base::JSONReader::Read(json, false)); in GetAuthData()
59 scoped_ptr<Value> parsed_value(base::JSONReader::Read(json, false)); in GetConfiguration()
134 scoped_ptr<Value> parsed_value(base::JSONReader::Read(json, false)); in GetPassphrase()
145 scoped_ptr<Value> parsed_value(base::JSONReader::Read(json, false)); in GetFirstPassphrase()
/external/chromium/chrome/common/
Djson_value_serializer_unittest.cc197 scoped_ptr<Value> root(base::JSONReader::Read(json, false)); in ValidateJsonList()
221 root.reset(base::JSONReader::Read("[\"// ok\\n /* foo */ \"]", false)); in TEST()
232 root.reset(base::JSONReader::Read("/* /* inner */ outer */ [ 1 ]", false)); in TEST()
236 root.reset(base::JSONReader::Read("/ * * / [1]", false)); in TEST()
/external/chromium_org/chrome/test/chromedriver/
Dchrome_launcher_unittest.cc91 scoped_ptr<base::Value> manifest(base::JSONReader::Read(manifest_txt)); in TEST()
181 scoped_ptr<base::Value> prefs_value(base::JSONReader::Read(prefs_str)); in TEST()
191 base::JSONReader::Read(local_state_str)); in TEST()
/external/chromium/chrome/browser/extensions/
Dchrome_app_api_browsertest.cc93 base::JSONReader::Read(result, false /* allow trailing comma */))); in IN_PROC_BROWSER_TEST_F()
169 base::JSONReader::Read(json, false /* allow trailing comma */))); in IN_PROC_BROWSER_TEST_F()
/external/chromium/chrome/common/web_resource/
Dweb_resource_unpacker.cc29 value.reset(base::JSONReader::Read(resource_data_, false)); in Run()

123456789