OLD | NEW |
1 // Copyright (c) 2011 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 #ifndef REMOTING_PROTOCOL_CONNECTION_TO_HOST_H_ | 5 #ifndef REMOTING_PROTOCOL_CONNECTION_TO_HOST_H_ |
6 #define REMOTING_PROTOCOL_CONNECTION_TO_HOST_H_ | 6 #define REMOTING_PROTOCOL_CONNECTION_TO_HOST_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
(...skipping 27 matching lines...) Expand all Loading... |
38 class InputStub; | 38 class InputStub; |
39 class SessionConfig; | 39 class SessionConfig; |
40 class VideoReader; | 40 class VideoReader; |
41 class VideoStub; | 41 class VideoStub; |
42 | 42 |
43 class ConnectionToHost : public SignalStrategy::StatusObserver, | 43 class ConnectionToHost : public SignalStrategy::StatusObserver, |
44 public SessionManager::Listener { | 44 public SessionManager::Listener { |
45 public: | 45 public: |
46 enum State { | 46 enum State { |
47 CONNECTING, | 47 CONNECTING, |
48 // TODO(sergeyu): Currently CONNECTED state is not used and state | |
49 // is set to AUTHENTICATED after we are connected. Remove it and | |
50 // renamed AUTHENTICATED to CONNECTED? | |
51 CONNECTED, | 48 CONNECTED, |
52 AUTHENTICATED, | |
53 FAILED, | 49 FAILED, |
54 CLOSED, | 50 CLOSED, |
55 }; | 51 }; |
56 | 52 |
57 enum Error { | 53 enum Error { |
58 OK, | 54 OK, |
59 HOST_IS_OFFLINE, | 55 HOST_IS_OFFLINE, |
60 SESSION_REJECTED, | 56 SESSION_REJECTED, |
61 INCOMPATIBLE_PROTOCOL, | 57 INCOMPATIBLE_PROTOCOL, |
62 NETWORK_FAILURE, | 58 NETWORK_FAILURE, |
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
160 Error error_; | 156 Error error_; |
161 | 157 |
162 private: | 158 private: |
163 DISALLOW_COPY_AND_ASSIGN(ConnectionToHost); | 159 DISALLOW_COPY_AND_ASSIGN(ConnectionToHost); |
164 }; | 160 }; |
165 | 161 |
166 } // namespace protocol | 162 } // namespace protocol |
167 } // namespace remoting | 163 } // namespace remoting |
168 | 164 |
169 #endif // REMOTING_PROTOCOL_CONNECTION_TO_HOST_H_ | 165 #endif // REMOTING_PROTOCOL_CONNECTION_TO_HOST_H_ |
OLD | NEW |