| Index: components/gcm_driver/gcm_driver_android.h
|
| diff --git a/components/gcm_driver/gcm_driver_android.h b/components/gcm_driver/gcm_driver_android.h
|
| index f9b44d8f98a375973e08f96b8ff4bd4327a42221..191d26f4791b35e17e23f9226830a0594daac677 100644
|
| --- a/components/gcm_driver/gcm_driver_android.h
|
| +++ b/components/gcm_driver/gcm_driver_android.h
|
| @@ -12,6 +12,7 @@
|
| #include "base/macros.h"
|
| #include "base/memory/ref_counted.h"
|
| #include "components/gcm_driver/gcm_driver.h"
|
| +#include "components/gcm_driver/gcm_stats_recorder_android.h"
|
|
|
| namespace base {
|
| class FilePath;
|
| @@ -21,7 +22,8 @@ class SequencedTaskRunner;
|
| namespace gcm {
|
|
|
| // GCMDriver implementation for Android, using Android GCM APIs.
|
| -class GCMDriverAndroid : public GCMDriver {
|
| +class GCMDriverAndroid : public GCMDriver,
|
| + public GCMStatsRecorderAndroid::Delegate {
|
| public:
|
| GCMDriverAndroid(
|
| const base::FilePath& store_path,
|
| @@ -79,6 +81,9 @@ class GCMDriverAndroid : public GCMDriver {
|
| void AddHeartbeatInterval(const std::string& scope, int interval_ms) override;
|
| void RemoveHeartbeatInterval(const std::string& scope) override;
|
|
|
| + // GCMStatsRecorder::Delegate implementation:
|
| + void OnActivityRecorded() override;
|
| +
|
| protected:
|
| // GCMDriver implementation:
|
| GCMClient::Result EnsureStarted(GCMClient::StartMode start_mode) override;
|
| @@ -94,6 +99,12 @@ class GCMDriverAndroid : public GCMDriver {
|
| private:
|
| base::android::ScopedJavaGlobalRef<jobject> java_ref_;
|
|
|
| + // Callback for GetGCMStatistics.
|
| + GetGCMStatisticsCallback get_gcm_statistics_callback_;
|
| +
|
| + // Recorder that logs GCM activities.
|
| + GCMStatsRecorderAndroid recorder_;
|
| +
|
| DISALLOW_COPY_AND_ASSIGN(GCMDriverAndroid);
|
| };
|
|
|
|
|