OLD | NEW |
(Empty) | |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef COMPONENTS_GCM_GCM_DRIVER_ANDROID_H_ |
| 6 #define COMPONENTS_GCM_GCM_DRIVER_ANDROID_H_ |
| 7 |
| 8 #include "components/gcm/gcm_driver.h" |
| 9 |
| 10 namespace gcm { |
| 11 |
| 12 // GCMDriver implementation for Android. |
| 13 class GCMDriverAndroid : public GCMDriver { |
| 14 public: |
| 15 GCMDriverAndroid(const scoped_refptr<base::MessageLoopProxy>& ui_thread); |
| 16 virtual ~GCMDriverAndroid(); |
| 17 |
| 18 // GCMDriver implementation. |
| 19 virtual void Enable() OVERRIDE; |
| 20 virtual void Disable() OVERRIDE; |
| 21 virtual void Register(const std::string& app_id, |
| 22 const std::vector<std::string>& sender_ids, |
| 23 const RegisterCallback& callback) OVERRIDE; |
| 24 virtual void Unregister(const std::string& app_id, |
| 25 const UnregisterCallback& callback) OVERRIDE; |
| 26 virtual void Send(const std::string& app_id, |
| 27 const std::string& receiver_id, |
| 28 const GCMClient::OutgoingMessage& message, |
| 29 const SendCallback& callback) OVERRIDE; |
| 30 virtual GCMClient* GetGCMClientForTesting() const OVERRIDE; |
| 31 virtual bool IsStarted() const OVERRIDE; |
| 32 virtual bool IsGCMClientReady() const OVERRIDE; |
| 33 virtual std::string SignedInUserName() const OVERRIDE; |
| 34 virtual void GetGCMStatistics(GetGCMStatisticsCallback callback, |
| 35 bool clear_logs) OVERRIDE; |
| 36 virtual void SetGCMRecording(GetGCMStatisticsCallback callback, |
| 37 bool recording) OVERRIDE; |
| 38 |
| 39 private: |
| 40 DISALLOW_COPY_AND_ASSIGN(GCMDriverAndroid); |
| 41 }; |
| 42 |
| 43 } // namespace gcm |
| 44 |
| 45 #endif // COMPONENTS_GCM_GCM_DRIVER_ANDROID_H_ |
OLD | NEW |