Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(7)

Side by Side Diff: third_party/libaddressinput/chromium/util/json.h

Issue 68323005: Build libaddressinput in Chrome for requestAutocomplete(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4 //
5 // This class provides the same interface as ../src/cpp/src/util/json.h but with
6 // a Chromium-specific JSON parser. This is because it didn't make much sense to
7 // have 2 JSON parsers in Chrome's code base, and the standalone library opted
8 // to use rapidjson instead of jsoncpp. See the other file for an explanation of
9 // what this class does.
10
11 #ifndef THIRD_PARTY_LIBADDRESSINPUT_CHROMIUM_UTIL_JSON_H_
12 #define THIRD_PARTY_LIBADDRESSINPUT_CHROMIUM_UTIL_JSON_H_
13
14 #include <string>
15
16 #include "base/basictypes.h"
17 #include "base/memory/scoped_ptr.h"
18 #include "base/values.h"
19
20 namespace i18n {
21 namespace addressinput {
22
23 class Json {
24 public:
25 Json();
26 ~Json();
27
28 bool ParseObject(const std::string& json);
29 bool HasStringValueForKey(const std::string& key) const;
30 std::string GetStringValueForKey(const std::string& key) const;
31
32 private:
33 scoped_ptr<base::DictionaryValue> dict_;
34
35 DISALLOW_COPY_AND_ASSIGN(Json);
36 };
37
38 } // namespace addressinput
39 } // namespace i18n
40
41 #endif // THIRD_PARTY_LIBADDRESSINPUT_CHROMIUM_UTIL_JSON_H_
OLDNEW
« no previous file with comments | « third_party/libaddressinput/README.chromium ('k') | third_party/libaddressinput/chromium/util/json.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698