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

Side by Side Diff: chrome/browser/services/gcm/gcm_profile_service.h

Issue 162233002: [GCM] Remove all persisted data and close connections when signing out of a profile (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Patch to land Created 6 years, 10 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 | « no previous file | chrome/browser/services/gcm/gcm_profile_service.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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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_SERVICES_GCM_GCM_PROFILE_SERVICE_H_ 5 #ifndef CHROME_BROWSER_SERVICES_GCM_GCM_PROFILE_SERVICE_H_
6 #define CHROME_BROWSER_SERVICES_GCM_GCM_PROFILE_SERVICE_H_ 6 #define CHROME_BROWSER_SERVICES_GCM_GCM_PROFILE_SERVICE_H_
7 7
8 #include <map> 8 #include <map>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 void MessagesDeleted(const std::string& app_id); 154 void MessagesDeleted(const std::string& app_id);
155 void MessageSendError(const std::string& app_id, 155 void MessageSendError(const std::string& app_id,
156 const std::string& message_id, 156 const std::string& message_id,
157 GCMClient::Result result); 157 GCMClient::Result result);
158 void FinishInitializationOnUI(bool ready); 158 void FinishInitializationOnUI(bool ready);
159 void GCMClientReady(); 159 void GCMClientReady();
160 160
161 // Returns the event router to fire the event for the given app. 161 // Returns the event router to fire the event for the given app.
162 GCMEventRouter* GetEventRouter(const std::string& app_id) const; 162 GCMEventRouter* GetEventRouter(const std::string& app_id) const;
163 163
164 // Used to persist the IDs of registered apps.
165 void ReadRegisteredAppIDs();
166 void WriteRegisteredAppIDs();
167
164 // Used to persist registration info into the app's state store. 168 // Used to persist registration info into the app's state store.
165 void DeleteRegistrationInfo(const std::string& app_id); 169 void DeleteRegistrationInfo(const std::string& app_id);
166 void WriteRegistrationInfo(const std::string& app_id); 170 void WriteRegistrationInfo(const std::string& app_id);
167 void ReadRegistrationInfo(const std::string& app_id); 171 void ReadRegistrationInfo(const std::string& app_id);
168 void ReadRegistrationInfoFinished(const std::string& app_id, 172 void ReadRegistrationInfoFinished(const std::string& app_id,
169 scoped_ptr<base::Value> value); 173 scoped_ptr<base::Value> value);
170 bool ParsePersistedRegistrationInfo(scoped_ptr<base::Value> value, 174 bool ParsePersistedRegistrationInfo(scoped_ptr<base::Value> value,
171 RegistrationInfo* registration_info); 175 RegistrationInfo* registration_info);
172 176
173 // Returns the key used to identify the registration info saved into the 177 // Returns the key used to identify the registration info saved into the
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
213 217
214 // Used to pass a weak pointer to the IO worker. 218 // Used to pass a weak pointer to the IO worker.
215 base::WeakPtrFactory<GCMProfileService> weak_ptr_factory_; 219 base::WeakPtrFactory<GCMProfileService> weak_ptr_factory_;
216 220
217 DISALLOW_COPY_AND_ASSIGN(GCMProfileService); 221 DISALLOW_COPY_AND_ASSIGN(GCMProfileService);
218 }; 222 };
219 223
220 } // namespace gcm 224 } // namespace gcm
221 225
222 #endif // CHROME_BROWSER_SERVICES_GCM_GCM_PROFILE_SERVICE_H_ 226 #endif // CHROME_BROWSER_SERVICES_GCM_GCM_PROFILE_SERVICE_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/services/gcm/gcm_profile_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698