| 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 188 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 199 virtual QuicTimeWaitListManager* CreateQuicTimeWaitListManager(); | 199 virtual QuicTimeWaitListManager* CreateQuicTimeWaitListManager(); |
| 200 | 200 |
| 201 // Called when |connection_id| doesn't have an open connection yet, to buffer | 201 // Called when |connection_id| doesn't have an open connection yet, to buffer |
| 202 // |current_packet_| until it can be delivered to the connection. | 202 // |current_packet_| until it can be delivered to the connection. |
| 203 void BufferEarlyPacket(QuicConnectionId connection_id); | 203 void BufferEarlyPacket(QuicConnectionId connection_id); |
| 204 | 204 |
| 205 // Called when |current_packet_| is a CHLO packet. Creates a new connection | 205 // Called when |current_packet_| is a CHLO packet. Creates a new connection |
| 206 // and delivers any buffered packets for that connection id. | 206 // and delivers any buffered packets for that connection id. |
| 207 void ProcessChlo(); | 207 void ProcessChlo(); |
| 208 | 208 |
| 209 // Returns client address used for stateless rejector to generate and validate |
| 210 // source address token. |
| 211 virtual const QuicSocketAddress GetClientAddress() const; |
| 212 |
| 209 QuicTimeWaitListManager* time_wait_list_manager() { | 213 QuicTimeWaitListManager* time_wait_list_manager() { |
| 210 return time_wait_list_manager_.get(); | 214 return time_wait_list_manager_.get(); |
| 211 } | 215 } |
| 212 | 216 |
| 213 const QuicVersionVector& GetSupportedVersions(); | 217 const QuicVersionVector& GetSupportedVersions(); |
| 214 | 218 |
| 215 QuicConnectionId current_connection_id() { return current_connection_id_; } | 219 QuicConnectionId current_connection_id() { return current_connection_id_; } |
| 216 const QuicSocketAddress& current_server_address() { | 220 const QuicSocketAddress& current_server_address() { |
| 217 return current_server_address_; | 221 return current_server_address_; |
| 218 } | 222 } |
| (...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 390 | 394 |
| 391 // True if this dispatcher is not draining. | 395 // True if this dispatcher is not draining. |
| 392 bool accept_new_connections_; | 396 bool accept_new_connections_; |
| 393 | 397 |
| 394 DISALLOW_COPY_AND_ASSIGN(QuicDispatcher); | 398 DISALLOW_COPY_AND_ASSIGN(QuicDispatcher); |
| 395 }; | 399 }; |
| 396 | 400 |
| 397 } // namespace net | 401 } // namespace net |
| 398 | 402 |
| 399 #endif // NET_TOOLS_QUIC_QUIC_DISPATCHER_H_ | 403 #endif // NET_TOOLS_QUIC_QUIC_DISPATCHER_H_ |
| OLD | NEW |