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 REMOTING_HOST_HOST_EXTENSION_SESSION_H_ | 5 #ifndef REMOTING_HOST_HOST_EXTENSION_SESSION_H_ |
6 #define REMOTING_HOST_HOST_EXTENSION_SESSION_H_ | 6 #define REMOTING_HOST_HOST_EXTENSION_SESSION_H_ |
7 | 7 |
8 namespace webrtc { | |
9 class DesktopCapturer; | |
10 } | |
11 | |
12 namespace remoting { | 8 namespace remoting { |
13 | 9 |
14 class ClientSessionDetails; | 10 class ClientSessionDetails; |
15 class VideoEncoder; | |
16 | 11 |
17 namespace protocol { | 12 namespace protocol { |
18 class ExtensionMessage; | 13 class ExtensionMessage; |
19 class ClientStub; | 14 class ClientStub; |
20 } // namespace protocol | 15 } // namespace protocol |
21 | 16 |
22 // Created by an |HostExtension| to store |ClientSession| specific state, and to | 17 // Created by an |HostExtension| to store |ClientSession| specific state, and to |
23 // handle extension messages. | 18 // handle extension messages. |
24 class HostExtensionSession { | 19 class HostExtensionSession { |
25 public: | 20 public: |
26 virtual ~HostExtensionSession() {} | 21 virtual ~HostExtensionSession() {} |
27 | 22 |
28 // Called when the host receives an |ExtensionMessage| for the |ClientSession| | 23 // Called when the host receives an |ExtensionMessage| for the |ClientSession| |
29 // associated with this |HostExtensionSession|. | 24 // associated with this |HostExtensionSession|. |
30 // It returns |true| if the message was handled, and |false| otherwise. | 25 // It returns |true| if the message was handled, and |false| otherwise. |
31 virtual bool OnExtensionMessage( | 26 virtual bool OnExtensionMessage( |
32 ClientSessionDetails* client_session_details, | 27 ClientSessionDetails* client_session_details, |
33 protocol::ClientStub* client_stub, | 28 protocol::ClientStub* client_stub, |
34 const protocol::ExtensionMessage& message) = 0; | 29 const protocol::ExtensionMessage& message) = 0; |
35 }; | 30 }; |
36 | 31 |
37 } // namespace remoting | 32 } // namespace remoting |
38 | 33 |
39 #endif // REMOTING_HOST_HOST_EXTENSION_SESSION_H_ | 34 #endif // REMOTING_HOST_HOST_EXTENSION_SESSION_H_ |
OLD | NEW |