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

Unified Diff: components/sync/sessions/update_counters.cc

Issue 2258873003: [Sync] Move sessions/ to engine/cycle/ and rename things to match. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address comments. Created 4 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « components/sync/sessions/update_counters.h ('k') | components/sync/sessions_impl/DEPS » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/sync/sessions/update_counters.cc
diff --git a/components/sync/sessions/update_counters.cc b/components/sync/sessions/update_counters.cc
deleted file mode 100644
index a63c2c1fbb65d5d01ce946c76c6b6bb98e31ea9f..0000000000000000000000000000000000000000
--- a/components/sync/sessions/update_counters.cc
+++ /dev/null
@@ -1,53 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "components/sync/sessions/update_counters.h"
-
-#include "base/json/json_string_value_serializer.h"
-#include "base/values.h"
-
-namespace syncer {
-
-UpdateCounters::UpdateCounters()
- : num_updates_received(0),
- num_reflected_updates_received(0),
- num_tombstone_updates_received(0),
- num_updates_applied(0),
- num_hierarchy_conflict_application_failures(0),
- num_encryption_conflict_application_failures(0),
- num_server_overwrites(0),
- num_local_overwrites(0) {}
-
-UpdateCounters::~UpdateCounters() {}
-
-std::unique_ptr<base::DictionaryValue> UpdateCounters::ToValue() const {
- std::unique_ptr<base::DictionaryValue> value(new base::DictionaryValue());
-
- value->SetInteger("numUpdatesReceived", num_updates_received);
- value->SetInteger("numReflectedUpdatesReceived",
- num_reflected_updates_received);
- value->SetInteger("numTombstoneUpdatesReceived",
- num_tombstone_updates_received);
-
- value->SetInteger("numUpdatesApplied", num_updates_applied);
- value->SetInteger("numHierarchyConflictApplicationFailures",
- num_hierarchy_conflict_application_failures);
- value->SetInteger("numEncryptionConflictApplicationFailures",
- num_encryption_conflict_application_failures);
-
- value->SetInteger("numServerOverwrites", num_server_overwrites);
- value->SetInteger("numLocalOverwrites", num_local_overwrites);
-
- return value;
-}
-
-std::string UpdateCounters::ToString() const {
- std::string result;
- std::unique_ptr<base::DictionaryValue> value = ToValue();
- JSONStringValueSerializer serializer(&result);
- serializer.Serialize(*value);
- return result;
-}
-
-} // namespace syncer
« no previous file with comments | « components/sync/sessions/update_counters.h ('k') | components/sync/sessions_impl/DEPS » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698