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

Side by Side Diff: base/values.cc

Issue 925783002: Split ValueSerializer into separate Serializer and Deserializer classes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed cpplint warnings. Created 5 years, 9 months 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
« no previous file with comments | « base/values.h ('k') | chrome/browser/chromeos/app_mode/kiosk_external_updater.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/values.h" 5 #include "base/values.h"
6 6
7 #include <string.h> 7 #include <string.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <ostream> 10 #include <ostream>
(...skipping 1125 matching lines...) Expand 10 before | Expand all | Expand 10 after
1136 } 1136 }
1137 if (lhs_it != end() || rhs_it != other_list->end()) 1137 if (lhs_it != end() || rhs_it != other_list->end())
1138 return false; 1138 return false;
1139 1139
1140 return true; 1140 return true;
1141 } 1141 }
1142 1142
1143 ValueSerializer::~ValueSerializer() { 1143 ValueSerializer::~ValueSerializer() {
1144 } 1144 }
1145 1145
1146 ValueDeserializer::~ValueDeserializer() {
1147 }
1148
1146 std::ostream& operator<<(std::ostream& out, const Value& value) { 1149 std::ostream& operator<<(std::ostream& out, const Value& value) {
1147 std::string json; 1150 std::string json;
1148 JSONWriter::WriteWithOptions(&value, 1151 JSONWriter::WriteWithOptions(&value,
1149 JSONWriter::OPTIONS_PRETTY_PRINT, 1152 JSONWriter::OPTIONS_PRETTY_PRINT,
1150 &json); 1153 &json);
1151 return out << json; 1154 return out << json;
1152 } 1155 }
1153 1156
1154 } // namespace base 1157 } // namespace base
OLDNEW
« no previous file with comments | « base/values.h ('k') | chrome/browser/chromeos/app_mode/kiosk_external_updater.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698