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_state_tracker.cc

Issue 221963003: Reduce dependency of TiclInvalidationService on Profile (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix sync_listen_notifications. Created 6 years, 8 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 #include "sync/notifier/fake_invalidation_state_tracker.h" 5 #include "sync/notifier/fake_invalidation_state_tracker.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/location.h" 9 #include "base/location.h"
10 #include "base/task_runner.h" 10 #include "base/task_runner.h"
11 #include "testing/gtest/include/gtest/gtest.h" 11 #include "testing/gtest/include/gtest/gtest.h"
12 12
13 namespace syncer { 13 namespace syncer {
14 14
15 const int64 FakeInvalidationStateTracker::kMinVersion = kint64min; 15 const int64 FakeInvalidationStateTracker::kMinVersion = kint64min;
16 16
17 FakeInvalidationStateTracker::FakeInvalidationStateTracker() {} 17 FakeInvalidationStateTracker::FakeInvalidationStateTracker() {}
18 18
19 FakeInvalidationStateTracker::~FakeInvalidationStateTracker() {} 19 FakeInvalidationStateTracker::~FakeInvalidationStateTracker() {}
20 20
21 void FakeInvalidationStateTracker::SetInvalidatorClientId( 21 void FakeInvalidationStateTracker::ClearAndSetNewClientId(
22 const std::string& client_id) { 22 const std::string& client_id) {
23 Clear(); 23 Clear();
24 invalidator_client_id_ = client_id; 24 invalidator_client_id_ = client_id;
25 } 25 }
26 26
27 std::string FakeInvalidationStateTracker::GetInvalidatorClientId() const { 27 std::string FakeInvalidationStateTracker::GetInvalidatorClientId() const {
28 return invalidator_client_id_; 28 return invalidator_client_id_;
29 } 29 }
30 30
31 void FakeInvalidationStateTracker::SetBootstrapData( 31 void FakeInvalidationStateTracker::SetBootstrapData(
(...skipping 14 matching lines...) Expand all
46 FakeInvalidationStateTracker::GetSavedInvalidations() const { 46 FakeInvalidationStateTracker::GetSavedInvalidations() const {
47 return unacked_invalidations_map_; 47 return unacked_invalidations_map_;
48 } 48 }
49 49
50 void FakeInvalidationStateTracker::Clear() { 50 void FakeInvalidationStateTracker::Clear() {
51 invalidator_client_id_.clear(); 51 invalidator_client_id_.clear();
52 bootstrap_data_.clear(); 52 bootstrap_data_.clear();
53 } 53 }
54 54
55 } // namespace syncer 55 } // namespace syncer
OLDNEW
« no previous file with comments | « sync/notifier/fake_invalidation_state_tracker.h ('k') | sync/notifier/invalidation_state_tracker.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698