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

Side by Side Diff: chrome/browser/sync/notifier/sync_notifier_observer.h

Issue 9699057: [Sync] Move 'sync' target to sync/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address Tim's comments Created 8 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 | Annotate | Revision Log
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 #ifndef CHROME_BROWSER_SYNC_NOTIFIER_SYNC_NOTIFIER_OBSERVER_H_ 5 #ifndef CHROME_BROWSER_SYNC_NOTIFIER_SYNC_NOTIFIER_OBSERVER_H_
6 #define CHROME_BROWSER_SYNC_NOTIFIER_SYNC_NOTIFIER_OBSERVER_H_ 6 #define CHROME_BROWSER_SYNC_NOTIFIER_SYNC_NOTIFIER_OBSERVER_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 10
11 #include "chrome/browser/sync/syncable/model_type_payload_map.h" 11 #include "sync/syncable/model_type_payload_map.h"
12 12
13 namespace sync_notifier { 13 namespace sync_notifier {
14 14
15 enum IncomingNotificationSource { 15 enum IncomingNotificationSource {
16 // The server is notifying us that one or more datatypes have stale data. 16 // The server is notifying us that one or more datatypes have stale data.
17 REMOTE_NOTIFICATION, 17 REMOTE_NOTIFICATION,
18 // A chrome datatype is requesting an optimistic refresh of its data. 18 // A chrome datatype is requesting an optimistic refresh of its data.
19 LOCAL_NOTIFICATION, 19 LOCAL_NOTIFICATION,
20 }; 20 };
21 21
22 class SyncNotifierObserver { 22 class SyncNotifierObserver {
23 public: 23 public:
24 SyncNotifierObserver() {} 24 SyncNotifierObserver() {}
25 virtual ~SyncNotifierObserver() {} 25 virtual ~SyncNotifierObserver() {}
26 26
27 virtual void OnIncomingNotification( 27 virtual void OnIncomingNotification(
28 const syncable::ModelTypePayloadMap& type_payloads, 28 const syncable::ModelTypePayloadMap& type_payloads,
29 IncomingNotificationSource source) = 0; 29 IncomingNotificationSource source) = 0;
30 virtual void OnNotificationStateChange(bool notifications_enabled) = 0; 30 virtual void OnNotificationStateChange(bool notifications_enabled) = 0;
31 31
32 // TODO(nileshagrawal): Find a way to hide state handling inside the 32 // TODO(nileshagrawal): Find a way to hide state handling inside the
33 // sync notifier implementation. 33 // sync notifier implementation.
34 virtual void StoreState(const std::string& state) = 0; 34 virtual void StoreState(const std::string& state) = 0;
35 }; 35 };
36 36
37 } // namespace sync_notifier 37 } // namespace sync_notifier
38 38
39 #endif // CHROME_BROWSER_SYNC_NOTIFIER_SYNC_NOTIFIER_OBSERVER_H_ 39 #endif // CHROME_BROWSER_SYNC_NOTIFIER_SYNC_NOTIFIER_OBSERVER_H_
OLDNEW
« no previous file with comments | « chrome/browser/sync/notifier/sync_notifier_factory_unittest.cc ('k') | chrome/browser/sync/profile_sync_components_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698