| 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_CLIENT_H_ | 5 #ifndef REMOTING_PROTOCOL_CONNECTION_TO_CLIENT_H_ |
| 6 #define REMOTING_PROTOCOL_CONNECTION_TO_CLIENT_H_ | 6 #define REMOTING_PROTOCOL_CONNECTION_TO_CLIENT_H_ |
| 7 | 7 |
| 8 #include <deque> | 8 #include <deque> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 59 ConnectionToClient(base::MessageLoopProxy* message_loop, Session* session); | 59 ConnectionToClient(base::MessageLoopProxy* message_loop, Session* session); |
| 60 | 60 |
| 61 // Set |event_handler| for connection events. |event_handler| is | 61 // Set |event_handler| for connection events. |event_handler| is |
| 62 // guaranteed to be used only on the network thread. Must be called | 62 // guaranteed to be used only on the network thread. Must be called |
| 63 // once when this object is created. | 63 // once when this object is created. |
| 64 void SetEventHandler(EventHandler* event_handler); | 64 void SetEventHandler(EventHandler* event_handler); |
| 65 | 65 |
| 66 // Returns the connection in use. | 66 // Returns the connection in use. |
| 67 virtual Session* session(); | 67 virtual Session* session(); |
| 68 | 68 |
| 69 // Disconnect the client connection. This method is allowed to be called | 69 // Disconnect the client connection. |
| 70 // more than once and calls after the first one will be ignored. | |
| 71 // | |
| 72 // After this method is called all the send method calls will be ignored. | |
| 73 virtual void Disconnect(); | 70 virtual void Disconnect(); |
| 74 | 71 |
| 75 // Update the sequence number when received from the client. EventHandler | 72 // Update the sequence number when received from the client. EventHandler |
| 76 // will be called. | 73 // will be called. |
| 77 virtual void UpdateSequenceNumber(int64 sequence_number); | 74 virtual void UpdateSequenceNumber(int64 sequence_number); |
| 78 | 75 |
| 79 // Send encoded update stream data to the viewer. | 76 // Send encoded update stream data to the viewer. |
| 80 virtual VideoStub* video_stub(); | 77 virtual VideoStub* video_stub(); |
| 81 | 78 |
| 82 // Return pointer to ClientStub. | 79 // Return pointer to ClientStub. |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 129 bool input_connected_; | 126 bool input_connected_; |
| 130 bool video_connected_; | 127 bool video_connected_; |
| 131 | 128 |
| 132 DISALLOW_COPY_AND_ASSIGN(ConnectionToClient); | 129 DISALLOW_COPY_AND_ASSIGN(ConnectionToClient); |
| 133 }; | 130 }; |
| 134 | 131 |
| 135 } // namespace protocol | 132 } // namespace protocol |
| 136 } // namespace remoting | 133 } // namespace remoting |
| 137 | 134 |
| 138 #endif // REMOTING_PROTOCOL_CONNECTION_TO_CLIENT_H_ | 135 #endif // REMOTING_PROTOCOL_CONNECTION_TO_CLIENT_H_ |
| OLD | NEW |