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

Side by Side Diff: sync/notifier/registration_manager.cc

Issue 10698014: [Sync] Rename csync namespace to syncer (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address comments Created 8 years, 5 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
« no previous file with comments | « sync/notifier/registration_manager.h ('k') | sync/notifier/registration_manager_unittest.cc » ('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 #include "sync/notifier/registration_manager.h" 5 #include "sync/notifier/registration_manager.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <cstddef> 8 #include <cstddef>
9 #include <iterator> 9 #include <iterator>
10 #include <string> 10 #include <string>
11 #include <utility> 11 #include <utility>
12 12
13 #include "base/rand_util.h" 13 #include "base/rand_util.h"
14 #include "base/stl_util.h" 14 #include "base/stl_util.h"
15 #include "google/cacheinvalidation/include/invalidation-client.h" 15 #include "google/cacheinvalidation/include/invalidation-client.h"
16 #include "google/cacheinvalidation/include/types.h" 16 #include "google/cacheinvalidation/include/types.h"
17 #include "sync/notifier/invalidation_util.h" 17 #include "sync/notifier/invalidation_util.h"
18 18
19 namespace csync { 19 namespace syncer {
20 20
21 RegistrationManager::PendingRegistrationInfo::PendingRegistrationInfo() {} 21 RegistrationManager::PendingRegistrationInfo::PendingRegistrationInfo() {}
22 22
23 RegistrationManager::RegistrationStatus::RegistrationStatus( 23 RegistrationManager::RegistrationStatus::RegistrationStatus(
24 const invalidation::ObjectId& id, RegistrationManager* manager) 24 const invalidation::ObjectId& id, RegistrationManager* manager)
25 : id(id), 25 : id(id),
26 registration_manager(manager), 26 registration_manager(manager),
27 enabled(true), 27 enabled(true),
28 state(invalidation::InvalidationListener::UNREGISTERED) { 28 state(invalidation::InvalidationListener::UNREGISTERED) {
29 DCHECK(registration_manager); 29 DCHECK(registration_manager);
(...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after
293 293
294 bool RegistrationManager::IsIdRegistered( 294 bool RegistrationManager::IsIdRegistered(
295 const invalidation::ObjectId& id) const { 295 const invalidation::ObjectId& id) const {
296 DCHECK(CalledOnValidThread()); 296 DCHECK(CalledOnValidThread());
297 RegistrationStatusMap::const_iterator it = 297 RegistrationStatusMap::const_iterator it =
298 registration_statuses_.find(id); 298 registration_statuses_.find(id);
299 return it != registration_statuses_.end() && 299 return it != registration_statuses_.end() &&
300 it->second->state == invalidation::InvalidationListener::REGISTERED; 300 it->second->state == invalidation::InvalidationListener::REGISTERED;
301 } 301 }
302 302
303 } // namespace csync 303 } // namespace syncer
OLDNEW
« no previous file with comments | « sync/notifier/registration_manager.h ('k') | sync/notifier/registration_manager_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698