diff options
author | dmazzoni@chromium.org <dmazzoni@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-07-12 19:15:03 +0000 |
---|---|---|
committer | dmazzoni@chromium.org <dmazzoni@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-07-12 19:15:03 +0000 |
commit | f3a1c64a4d81c412273ed567536f23c2c14813a2 (patch) | |
tree | f0ced21805b18546e879413e4f808dd4f683c534 /base | |
parent | 2338319a9acbaecba44243740b3f01b5c408a78a (diff) | |
download | chromium_src-f3a1c64a4d81c412273ed567536f23c2c14813a2.zip chromium_src-f3a1c64a4d81c412273ed567536f23c2c14813a2.tar.gz chromium_src-f3a1c64a4d81c412273ed567536f23c2c14813a2.tar.bz2 |
Move base/values.h into the base namespace. This includes a cros DEPS roll
with a minor change to that code since libcros also uses base/values.h.
BUG=88666
TEST=none
Review URL: http://codereview.chromium.org/7259019
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@92208 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base')
-rw-r--r-- | base/json/json_reader.h | 4 | ||||
-rw-r--r-- | base/json/json_writer.h | 4 | ||||
-rw-r--r-- | base/value_conversions.h | 5 | ||||
-rw-r--r-- | base/values.h | 20 |
4 files changed, 27 insertions, 6 deletions
diff --git a/base/json/json_reader.h b/base/json/json_reader.h index 4f83492..46e450c 100644 --- a/base/json/json_reader.h +++ b/base/json/json_reader.h @@ -43,10 +43,10 @@ #define FRIEND_TEST(test_case_name, test_name)\ friend class test_case_name##_##test_name##_Test -class Value; - namespace base { +class Value; + class BASE_API JSONReader { public: // A struct to hold a JS token. diff --git a/base/json/json_writer.h b/base/json/json_writer.h index c019e87..36331bb 100644 --- a/base/json/json_writer.h +++ b/base/json/json_writer.h @@ -11,10 +11,10 @@ #include "base/base_api.h" #include "base/basictypes.h" -class Value; - namespace base { +class Value; + class BASE_API JSONWriter { public: // Given a root node, generates a JSON string and puts it into |json|. diff --git a/base/value_conversions.h b/base/value_conversions.h index 75246d1..5ed7550c 100644 --- a/base/value_conversions.h +++ b/base/value_conversions.h @@ -11,11 +11,12 @@ #include "base/base_api.h" class FilePath; -class StringValue; -class Value; namespace base { +class StringValue; +class Value; + // The caller takes ownership of the returned value. BASE_API StringValue* CreateFilePathValue(const FilePath& in_value); BASE_API bool GetValueAsFilePath(const Value& value, FilePath* file_path); diff --git a/base/values.h b/base/values.h index a00a17c..21ddfce 100644 --- a/base/values.h +++ b/base/values.h @@ -32,6 +32,13 @@ #include "base/string16.h" #include "build/build_config.h" +// This file declares "using base::Value", etc. at the bottom, so that +// current code can use these classes without the base namespace. In +// new code, please always use base::Value, etc. or add your own +// "using" declaration. +// http://crbug.com/88666 +namespace base { + class BinaryValue; class DictionaryValue; class FundamentalValue; @@ -455,4 +462,17 @@ class BASE_API ValueSerializer { virtual Value* Deserialize(int* error_code, std::string* error_str) = 0; }; +} // namespace base + +// http://crbug.com/88666 +using base::BinaryValue; +using base::DictionaryValue; +using base::FundamentalValue; +using base::ListValue; +using base::StringValue; +using base::Value; +using base::ValueMap; +using base::ValueSerializer; +using base::ValueVector; + #endif // BASE_VALUES_H_ |