Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 // Interface of a host that receives commands from a Chromoting client. | 5 // Interface of a host that receives commands from a Chromoting client. |
| 6 // | 6 // |
| 7 // This interface handles control messages defined in contro.proto. | 7 // This interface handles control messages defined in contro.proto. |
| 8 | 8 |
| 9 #ifndef REMOTING_PROTOCOL_HOST_STUB_H_ | 9 #ifndef REMOTING_PROTOCOL_HOST_STUB_H_ |
| 10 #define REMOTING_PROTOCOL_HOST_STUB_H_ | 10 #define REMOTING_PROTOCOL_HOST_STUB_H_ |
| 11 | 11 |
| 12 #include "base/basictypes.h" | 12 #include "base/basictypes.h" |
| 13 | 13 |
| 14 class Task; | 14 class Task; |
| 15 | 15 |
| 16 namespace remoting { | 16 namespace remoting { |
| 17 namespace protocol { | 17 namespace protocol { |
| 18 | 18 |
| 19 class ConnectionToClient; | |
| 20 class LocalLoginCredentials; | |
| 19 class SuggestResolutionRequest; | 21 class SuggestResolutionRequest; |
| 20 class LocalLoginCredentials; | |
| 21 | 22 |
| 22 class HostStub { | 23 class HostStub { |
| 23 public: | 24 public: |
| 24 HostStub(); | 25 HostStub(); |
| 25 virtual ~HostStub(); | 26 virtual ~HostStub(); |
| 26 | 27 |
| 27 virtual void SuggestResolution( | 28 virtual void SuggestResolution( |
| 28 const SuggestResolutionRequest* msg, Task* done) = 0; | 29 const SuggestResolutionRequest* msg, Task* done) = 0; |
| 29 virtual void BeginSessionRequest( | 30 virtual void BeginSessionRequest( |
| 31 ConnectionToClient* connection, | |
|
Sergey Ulanov
2011/03/18 18:12:21
Can we avoid adding this parameter? HostStub is su
simonmorris
2011/03/22 13:09:10
Done.
| |
| 30 const LocalLoginCredentials* credentials, Task* done) = 0; | 32 const LocalLoginCredentials* credentials, Task* done) = 0; |
| 31 | 33 |
| 32 // TODO(lambroslambrou): Remove OnAuthenticated() and OnClosed() when stubs | 34 // TODO(lambroslambrou): Remove OnAuthenticated() and OnClosed() when stubs |
| 33 // are refactored not to store authentication state. | 35 // are refactored not to store authentication state. |
| 34 | 36 |
| 35 // Called when the client has authenticated with the host to enable the | 37 // Called when the client has authenticated with the host to enable the |
| 36 // client->host control channel. | 38 // client->host control channel. |
| 37 // Before this is called, only a limited set of control messages will be | 39 // Before this is called, only a limited set of control messages will be |
| 38 // processed. | 40 // processed. |
| 39 void OnAuthenticated(); | 41 void OnAuthenticated(); |
| (...skipping 10 matching lines...) Expand all Loading... | |
| 50 // the host. | 52 // the host. |
| 51 bool authenticated_; | 53 bool authenticated_; |
| 52 | 54 |
| 53 DISALLOW_COPY_AND_ASSIGN(HostStub); | 55 DISALLOW_COPY_AND_ASSIGN(HostStub); |
| 54 }; | 56 }; |
| 55 | 57 |
| 56 } // namespace protocol | 58 } // namespace protocol |
| 57 } // namespace remoting | 59 } // namespace remoting |
| 58 | 60 |
| 59 #endif // REMOTING_PROTOCOL_HOST_STUB_H_ | 61 #endif // REMOTING_PROTOCOL_HOST_STUB_H_ |
| OLD | NEW |