| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 // A server side dispatcher which dispatches a given client's data to their | 5 // A server side dispatcher which dispatches a given client's data to their |
| 6 // stream. | 6 // stream. |
| 7 | 7 |
| 8 #ifndef NET_TOOLS_QUIC_QUIC_DISPATCHER_H_ | 8 #ifndef NET_TOOLS_QUIC_QUIC_DISPATCHER_H_ |
| 9 #define NET_TOOLS_QUIC_QUIC_DISPATCHER_H_ | 9 #define NET_TOOLS_QUIC_QUIC_DISPATCHER_H_ |
| 10 | 10 |
| (...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 137 QuicTimeWaitListManager* time_wait_list_manager() { | 137 QuicTimeWaitListManager* time_wait_list_manager() { |
| 138 return time_wait_list_manager_.get(); | 138 return time_wait_list_manager_.get(); |
| 139 } | 139 } |
| 140 | 140 |
| 141 EpollServer* epoll_server() { return epoll_server_; } | 141 EpollServer* epoll_server() { return epoll_server_; } |
| 142 | 142 |
| 143 const QuicVersionVector& supported_versions() const { | 143 const QuicVersionVector& supported_versions() const { |
| 144 return supported_versions_; | 144 return supported_versions_; |
| 145 } | 145 } |
| 146 | 146 |
| 147 const QuicVersionVector& supported_versions_no_connection_flow_control() | |
| 148 const { | |
| 149 return supported_versions_no_connection_flow_control_; | |
| 150 } | |
| 151 | |
| 152 const IPEndPoint& current_server_address() { | 147 const IPEndPoint& current_server_address() { |
| 153 return current_server_address_; | 148 return current_server_address_; |
| 154 } | 149 } |
| 155 const IPEndPoint& current_client_address() { | 150 const IPEndPoint& current_client_address() { |
| 156 return current_client_address_; | 151 return current_client_address_; |
| 157 } | 152 } |
| 158 const QuicEncryptedPacket& current_packet() { | 153 const QuicEncryptedPacket& current_packet() { |
| 159 return *current_packet_; | 154 return *current_packet_; |
| 160 } | 155 } |
| 161 | 156 |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 208 | 203 |
| 209 // The writer to write to the socket with. | 204 // The writer to write to the socket with. |
| 210 scoped_ptr<QuicPacketWriter> writer_; | 205 scoped_ptr<QuicPacketWriter> writer_; |
| 211 | 206 |
| 212 // This vector contains QUIC versions which we currently support. | 207 // This vector contains QUIC versions which we currently support. |
| 213 // This should be ordered such that the highest supported version is the first | 208 // This should be ordered such that the highest supported version is the first |
| 214 // element, with subsequent elements in descending order (versions can be | 209 // element, with subsequent elements in descending order (versions can be |
| 215 // skipped as necessary). | 210 // skipped as necessary). |
| 216 const QuicVersionVector supported_versions_; | 211 const QuicVersionVector supported_versions_; |
| 217 | 212 |
| 218 // Versions which do not support *connection* flow control (introduced in | |
| 219 // QUIC_VERSION_19). | |
| 220 // This is used to construct new QuicConnections when connection flow control | |
| 221 // is disabled via flag. | |
| 222 // TODO(rjshade): Remove this when | |
| 223 // FLAGS_enable_quic_connection_flow_control_2 is removed. | |
| 224 QuicVersionVector supported_versions_no_connection_flow_control_; | |
| 225 | |
| 226 // Information about the packet currently being handled. | 213 // Information about the packet currently being handled. |
| 227 IPEndPoint current_client_address_; | 214 IPEndPoint current_client_address_; |
| 228 IPEndPoint current_server_address_; | 215 IPEndPoint current_server_address_; |
| 229 const QuicEncryptedPacket* current_packet_; | 216 const QuicEncryptedPacket* current_packet_; |
| 230 | 217 |
| 231 QuicFramer framer_; | 218 QuicFramer framer_; |
| 232 scoped_ptr<QuicFramerVisitor> framer_visitor_; | 219 scoped_ptr<QuicFramerVisitor> framer_visitor_; |
| 233 | 220 |
| 234 DISALLOW_COPY_AND_ASSIGN(QuicDispatcher); | 221 DISALLOW_COPY_AND_ASSIGN(QuicDispatcher); |
| 235 }; | 222 }; |
| 236 | 223 |
| 237 } // namespace tools | 224 } // namespace tools |
| 238 } // namespace net | 225 } // namespace net |
| 239 | 226 |
| 240 #endif // NET_TOOLS_QUIC_QUIC_DISPATCHER_H_ | 227 #endif // NET_TOOLS_QUIC_QUIC_DISPATCHER_H_ |
| OLD | NEW |