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

Unified Diff: google_apis/gcm/gcm_client_impl.h

Issue 317723004: [GCM] Add ConnectionListener support, and hook up to debug page (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 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: google_apis/gcm/gcm_client_impl.h
diff --git a/google_apis/gcm/gcm_client_impl.h b/google_apis/gcm/gcm_client_impl.h
index e543d73bc4facde4555e3f6a951a80cc51640a3c..847d67d0d093aa0a38bed97c86c16a68c225506e 100644
--- a/google_apis/gcm/gcm_client_impl.h
+++ b/google_apis/gcm/gcm_client_impl.h
@@ -74,12 +74,13 @@ class GCM_EXPORT GCMInternalsBuilder {
// Checkins. It also allows for registering user delegates that host
// applications that send and receive messages.
class GCM_EXPORT GCMClientImpl
- : public GCMClient, public GCMStatsRecorder::Delegate {
+ : public GCMClient, public GCMStatsRecorder::Delegate,
+ public ConnectionFactory::ConnectionListener {
public:
explicit GCMClientImpl(scoped_ptr<GCMInternalsBuilder> internals_builder);
virtual ~GCMClientImpl();
- // Overridden from GCMClient:
+ // GCMClient implementation.
virtual void Initialize(
const ChromeBuildInfo& chrome_build_info,
const base::FilePath& store_path,
@@ -101,8 +102,15 @@ class GCM_EXPORT GCMClientImpl
virtual void SetRecording(bool recording) OVERRIDE;
virtual void ClearActivityLogs() OVERRIDE;
virtual GCMStatistics GetStatistics() const OVERRIDE;
+
+ // GCMStatsRecorder::Delegate implemenation.
virtual void OnActivityRecorded() OVERRIDE;
+ // ConnectionFactory::ConnectionListener implementation.
+ virtual void OnConnected(const GURL& current_endpoint,
+ const net::IPEndPoint& socket_ip) OVERRIDE;
+ virtual void OnDisconnected() OVERRIDE;
+
private:
// State representation of the GCMClient.
// Any change made to this enum should have corresponding change in the

Powered by Google App Engine
This is Rietveld 408576698