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

Side by Side Diff: sync/notifier/fake_invalidation_handler.h

Issue 56113003: Implement new invalidations ack tracking system (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Modify drive TODO comment + rebase Created 7 years 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
« no previous file with comments | « sync/notifier/ack_tracker_unittest.cc ('k') | sync/notifier/fake_invalidation_state_tracker.h » ('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 #ifndef SYNC_NOTIFIER_FAKE_SYNC_NOTIFIER_OBSERVER_H_ 5 #ifndef SYNC_NOTIFIER_FAKE_SYNC_NOTIFIER_OBSERVER_H_
6 #define SYNC_NOTIFIER_FAKE_SYNC_NOTIFIER_OBSERVER_H_ 6 #define SYNC_NOTIFIER_FAKE_SYNC_NOTIFIER_OBSERVER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
11 #include "base/compiler_specific.h" 11 #include "base/compiler_specific.h"
12 #include "sync/notifier/invalidation_handler.h" 12 #include "sync/notifier/invalidation_handler.h"
13 #include "sync/notifier/object_id_invalidation_map.h"
13 14
14 namespace syncer { 15 namespace syncer {
15 16
16 class FakeInvalidationHandler : public InvalidationHandler { 17 class FakeInvalidationHandler : public InvalidationHandler {
17 public: 18 public:
18 FakeInvalidationHandler(); 19 FakeInvalidationHandler();
19 virtual ~FakeInvalidationHandler(); 20 virtual ~FakeInvalidationHandler();
20 21
21 InvalidatorState GetInvalidatorState() const; 22 InvalidatorState GetInvalidatorState() const;
22 const ObjectIdInvalidationMap& GetLastInvalidationMap() const; 23 const ObjectIdInvalidationMap& GetLastInvalidationMap() const;
23 int GetInvalidationCount() const; 24 int GetInvalidationCount() const;
24 25
25 // InvalidationHandler implementation. 26 // InvalidationHandler implementation.
26 virtual void OnInvalidatorStateChange(InvalidatorState state) OVERRIDE; 27 virtual void OnInvalidatorStateChange(InvalidatorState state) OVERRIDE;
27 virtual void OnIncomingInvalidation( 28 virtual void OnIncomingInvalidation(
28 const ObjectIdInvalidationMap& invalidation_map) OVERRIDE; 29 const ObjectIdInvalidationMap& invalidation_map) OVERRIDE;
29 30
30 private: 31 private:
31 InvalidatorState state_; 32 InvalidatorState state_;
32 ObjectIdInvalidationMap last_invalidation_map_; 33 ObjectIdInvalidationMap last_invalidation_map_;
33 int invalidation_count_; 34 int invalidation_count_;
34 35
35 DISALLOW_COPY_AND_ASSIGN(FakeInvalidationHandler); 36 DISALLOW_COPY_AND_ASSIGN(FakeInvalidationHandler);
36 }; 37 };
37 38
38 } // namespace syncer 39 } // namespace syncer
39 40
40 #endif // SYNC_NOTIFIER_FAKE_SYNC_NOTIFIER_OBSERVER_H_ 41 #endif // SYNC_NOTIFIER_FAKE_SYNC_NOTIFIER_OBSERVER_H_
OLDNEW
« no previous file with comments | « sync/notifier/ack_tracker_unittest.cc ('k') | sync/notifier/fake_invalidation_state_tracker.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698