Index: chrome/browser/sync/glue/bridged_invalidator.h |
diff --git a/chrome/browser/sync/glue/bridged_sync_notifier.h b/chrome/browser/sync/glue/bridged_invalidator.h |
similarity index 46% |
rename from chrome/browser/sync/glue/bridged_sync_notifier.h |
rename to chrome/browser/sync/glue/bridged_invalidator.h |
index 616e16da9d984c8232b83cb88efec792296b0847..73b1c0c85137d122f921ed06c57752d83916ac62 100644 |
--- a/chrome/browser/sync/glue/bridged_sync_notifier.h |
+++ b/chrome/browser/sync/glue/bridged_invalidator.h |
@@ -2,39 +2,38 @@ |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
-#ifndef CHROME_BROWSER_SYNC_GLUE_BRIDGED_SYNC_NOTIFIER_H_ |
-#define CHROME_BROWSER_SYNC_GLUE_BRIDGED_SYNC_NOTIFIER_H_ |
+#ifndef CHROME_BROWSER_SYNC_GLUE_BRIDGED_INVALIDATOR_H_ |
+#define CHROME_BROWSER_SYNC_GLUE_BRIDGED_INVALIDATOR_H_ |
#include "base/compiler_specific.h" |
#include "base/memory/scoped_ptr.h" |
-#include "sync/notifier/sync_notifier.h" |
+#include "sync/notifier/invalidator.h" |
namespace browser_sync { |
class ChromeSyncNotificationBridge; |
-// A SyncNotifier implementation that wraps a ChromeSyncNotificationBridge |
-// and optionally a SyncNotifier delegate (which it takes ownership of). |
-// All SyncNotifier calls are passed straight through to the delegate, |
-// with the exception of AddObserver/RemoveObserver, which also result in |
-// the observer being registered/deregistered with the |
-// ChromeSyncNotificationBridge. |
-class BridgedSyncNotifier : public syncer::SyncNotifier { |
+// An Invalidator implementation that wraps a ChromeSyncNotificationBridge |
+// and optionally an Invalidator delegate (which it takes ownership of). |
+// All Invalidator calls are passed straight through to the delegate, |
+// with the exception of RegisterHandler, UpdateRegisteredIds, and |
+// UnregisterHandler, which result in the handler being registered, updated, |
+// and unregistered with the ChromeSyncNotificationBridge, respectively. |
+class BridgedInvalidator : public syncer::Invalidator { |
public: |
// Does not take ownership of |bridge|. Takes ownership of |delegate|. |
// |delegate| may be NULL. |
- BridgedSyncNotifier(ChromeSyncNotificationBridge* bridge, |
- syncer::SyncNotifier* delegate); |
- virtual ~BridgedSyncNotifier(); |
+ BridgedInvalidator(ChromeSyncNotificationBridge* bridge, |
+ syncer::Invalidator* delegate); |
+ virtual ~BridgedInvalidator(); |
- // SyncNotifier implementation. Passes through all calls to the delegate. |
- // RegisterHandler, UnregisterHandler, and UpdateRegisteredIds calls will |
+ // Invalidator implementation. Passes through all calls to the delegate. |
+ // RegisterHandler, UpdateRegisteredIds, and UnregisterHandler calls will |
// also be forwarded to the bridge. |
- virtual void RegisterHandler(syncer::SyncNotifierObserver* handler) OVERRIDE; |
- virtual void UpdateRegisteredIds(syncer::SyncNotifierObserver* handler, |
+ virtual void RegisterHandler(syncer::InvalidationHandler* handler) OVERRIDE; |
+ virtual void UpdateRegisteredIds(syncer::InvalidationHandler * handler, |
const syncer::ObjectIdSet& ids) OVERRIDE; |
- virtual void UnregisterHandler( |
- syncer::SyncNotifierObserver* handler) OVERRIDE; |
+ virtual void UnregisterHandler(syncer::InvalidationHandler* handler) OVERRIDE; |
virtual void SetUniqueId(const std::string& unique_id) OVERRIDE; |
virtual void SetStateDeprecated(const std::string& state) OVERRIDE; |
virtual void UpdateCredentials( |
@@ -47,9 +46,9 @@ class BridgedSyncNotifier : public syncer::SyncNotifier { |
ChromeSyncNotificationBridge* bridge_; |
// The delegate we are wrapping. |
- scoped_ptr<syncer::SyncNotifier> delegate_; |
+ scoped_ptr<syncer::Invalidator> delegate_; |
}; |
} // namespace browser_sync |
-#endif // CHROME_BROWSER_SYNC_GLUE_BRIDGED_SYNC_NOTIFIER_H_ |
+#endif // CHROME_BROWSER_SYNC_GLUE_BRIDGED_INVALIDATOR_H_ |