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

Unified Diff: sync/tools/sync_listen_notifications.cc

Issue 10837214: Refactor ModelTypePayloadMap and ObjectIdPayloadMap to StateMaps. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix unit test Created 8 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 | « sync/test/engine/syncer_command_test.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sync/tools/sync_listen_notifications.cc
diff --git a/sync/tools/sync_listen_notifications.cc b/sync/tools/sync_listen_notifications.cc
index 6d8adb0fba856a1537bdbef84ecb61ec2a7c6c11..ef5ef1909fda182cbea0b429ec3898263539b9ac 100644
--- a/sync/tools/sync_listen_notifications.cc
+++ b/sync/tools/sync_listen_notifications.cc
@@ -24,7 +24,7 @@
#include "net/base/transport_security_state.h"
#include "net/url_request/url_request_test_util.h"
#include "sync/internal_api/public/base/model_type.h"
-#include "sync/internal_api/public/base/model_type_payload_map.h"
+#include "sync/internal_api/public/base/model_type_state_map.h"
#include "sync/notifier/invalidation_state_tracker.h"
#include "sync/notifier/invalidation_util.h"
#include "sync/notifier/sync_notifier.h"
@@ -65,16 +65,16 @@ class NotificationPrinter : public SyncNotifierObserver {
}
virtual void OnIncomingNotification(
- const ObjectIdPayloadMap& id_payloads,
+ const ObjectIdStateMap& id_state_map,
IncomingNotificationSource source) OVERRIDE {
- const ModelTypePayloadMap& type_payloads =
- ObjectIdPayloadMapToModelTypePayloadMap(id_payloads);
- for (ModelTypePayloadMap::const_iterator it =
- type_payloads.begin(); it != type_payloads.end(); ++it) {
+ const ModelTypeStateMap& type_state_map =
+ ObjectIdStateMapToModelTypeStateMap(id_state_map);
+ for (ModelTypeStateMap::const_iterator it = type_state_map.begin();
+ it != type_state_map.end(); ++it) {
LOG(INFO) << (source == REMOTE_NOTIFICATION ? "Remote" : "Local")
<< " Notification: type = "
<< ModelTypeToString(it->first)
- << ", payload = " << it->second;
+ << ", payload = " << it->second.payload;
}
}
« no previous file with comments | « sync/test/engine/syncer_command_test.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698