| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 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 COMPONENTS_COPRESENCE_PUBLIC_COPRESENCE_DELEGATE_H_ | 5 #ifndef COMPONENTS_COPRESENCE_PUBLIC_COPRESENCE_DELEGATE_H_ |
| 6 #define COMPONENTS_COPRESENCE_PUBLIC_COPRESENCE_DELEGATE_H_ | 6 #define COMPONENTS_COPRESENCE_PUBLIC_COPRESENCE_DELEGATE_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| 11 #include "base/callback_forward.h" | 11 #include "base/callback_forward.h" |
| 12 | 12 |
| 13 namespace gcm { |
| 14 class GCMDriver; |
| 15 } |
| 16 |
| 13 namespace net { | 17 namespace net { |
| 14 class URLRequestContextGetter; | 18 class URLRequestContextGetter; |
| 15 } | 19 } |
| 16 | 20 |
| 17 namespace copresence { | 21 namespace copresence { |
| 18 | 22 |
| 19 class Message; | 23 class Message; |
| 20 class WhispernetClient; | 24 class WhispernetClient; |
| 21 | 25 |
| 22 // AUDIO_FAIL indicates that we weren't able to hear the audio token that | 26 // AUDIO_FAIL indicates that we weren't able to hear the audio token that |
| (...skipping 19 matching lines...) Expand all Loading... |
| 42 | 46 |
| 43 // Thw URLRequestContextGetter must outlive the CopresenceManager. | 47 // Thw URLRequestContextGetter must outlive the CopresenceManager. |
| 44 virtual net::URLRequestContextGetter* GetRequestContext() const = 0; | 48 virtual net::URLRequestContextGetter* GetRequestContext() const = 0; |
| 45 | 49 |
| 46 virtual const std::string GetPlatformVersionString() const = 0; | 50 virtual const std::string GetPlatformVersionString() const = 0; |
| 47 | 51 |
| 48 virtual const std::string GetAPIKey(const std::string& app_id) const = 0; | 52 virtual const std::string GetAPIKey(const std::string& app_id) const = 0; |
| 49 | 53 |
| 50 // Thw WhispernetClient must outlive the CopresenceManager. | 54 // Thw WhispernetClient must outlive the CopresenceManager. |
| 51 virtual WhispernetClient* GetWhispernetClient() = 0; | 55 virtual WhispernetClient* GetWhispernetClient() = 0; |
| 56 |
| 57 // Clients may optionally provide a GCMDriver to receive messages from. |
| 58 // If no driver is available, this can return null. |
| 59 virtual gcm::GCMDriver* GetGCMDriver() = 0; |
| 52 }; | 60 }; |
| 53 | 61 |
| 54 } // namespace copresence | 62 } // namespace copresence |
| 55 | 63 |
| 56 #endif // COMPONENTS_COPRESENCE_PUBLIC_COPRESENCE_DELEGATE_H_ | 64 #endif // COMPONENTS_COPRESENCE_PUBLIC_COPRESENCE_DELEGATE_H_ |
| OLD | NEW |