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

Unified Diff: chrome/browser/services/gcm/gcm_service.h

Issue 270873002: Extract GCMClient data types into separate gcm_types.h (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Reupload Created 6 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/services/gcm/gcm_service.h
diff --git a/chrome/browser/services/gcm/gcm_service.h b/chrome/browser/services/gcm/gcm_service.h
index 321be2ea31d133921c56a15f03322ff9f4b66663..d62600a80e568475368e20ca95cc99b70c116c5d 100644
--- a/chrome/browser/services/gcm/gcm_service.h
+++ b/chrome/browser/services/gcm/gcm_service.h
@@ -19,6 +19,7 @@
#include "chrome/browser/services/gcm/default_gcm_app_handler.h"
#include "google_apis/gaia/identity_provider.h"
#include "google_apis/gcm/gcm_client.h"
+#include "google_apis/gcm/public/gcm_types.h"
namespace extensions {
class ExtensionGCMAppHandlerTest;
@@ -37,10 +38,10 @@ class GCMClientFactory;
class GCMService : public IdentityProvider::Observer {
public:
typedef base::Callback<void(const std::string& registration_id,
- GCMClient::Result result)> RegisterCallback;
+ Result result)> RegisterCallback;
typedef base::Callback<void(const std::string& message_id,
- GCMClient::Result result)> SendCallback;
- typedef base::Callback<void(GCMClient::Result result)> UnregisterCallback;
+ Result result)> SendCallback;
+ typedef base::Callback<void(Result result)> UnregisterCallback;
typedef base::Callback<void(const GCMClient::GCMStatistics& stats)>
GetGCMStatisticsCallback;
@@ -87,7 +88,7 @@ class GCMService : public IdentityProvider::Observer {
// |callback|: to be called once the asynchronous operation is done.
virtual void Send(const std::string& app_id,
const std::string& receiver_id,
- const GCMClient::OutgoingMessage& message,
+ const OutgoingMessage& message,
SendCallback callback);
// For testing purpose.
@@ -141,7 +142,7 @@ class GCMService : public IdentityProvider::Observer {
void CheckOut();
// Ensures that the app is ready for GCM functions and events.
- GCMClient::Result EnsureAppReady(const std::string& app_id);
+ Result EnsureAppReady(const std::string& app_id);
// Should be called when an app with |app_id| is trying to un/register.
// Checks whether another un/registration is in progress.
@@ -152,21 +153,21 @@ class GCMService : public IdentityProvider::Observer {
void DoUnregister(const std::string& app_id);
void DoSend(const std::string& app_id,
const std::string& receiver_id,
- const GCMClient::OutgoingMessage& message);
+ const OutgoingMessage& message);
// Callbacks posted from IO thread to UI thread.
void RegisterFinished(const std::string& app_id,
const std::string& registration_id,
- GCMClient::Result result);
- void UnregisterFinished(const std::string& app_id, GCMClient::Result result);
+ Result result);
+ void UnregisterFinished(const std::string& app_id, Result result);
void SendFinished(const std::string& app_id,
const std::string& message_id,
- GCMClient::Result result);
+ Result result);
void MessageReceived(const std::string& app_id,
- GCMClient::IncomingMessage message);
+ IncomingMessage message);
void MessagesDeleted(const std::string& app_id);
void MessageSendError(const std::string& app_id,
- const GCMClient::SendErrorDetails& send_error_details);
+ const SendErrorDetails& send_error_details);
void GCMClientReady();
// Returns the handler for the given app.
« no previous file with comments | « chrome/browser/services/gcm/gcm_profile_service_unittest.cc ('k') | chrome/browser/services/gcm/gcm_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698