| 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 client specific QuicSession subclass. This class owns the underlying | 5 // A client specific QuicSession subclass. This class owns the underlying |
| 6 // QuicConnection and QuicConnectionHelper objects. The connection stores | 6 // QuicConnection and QuicConnectionHelper objects. The connection stores |
| 7 // a non-owning pointer to the helper so this session needs to ensure that | 7 // a non-owning pointer to the helper so this session needs to ensure that |
| 8 // the helper outlives the connection. | 8 // the helper outlives the connection. |
| 9 | 9 |
| 10 #ifndef NET_QUIC_QUIC_CLIENT_SESSION_H_ | 10 #ifndef NET_QUIC_QUIC_CLIENT_SESSION_H_ |
| (...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 162 | 162 |
| 163 // Resumes a crypto handshake with the server after a timeout. | 163 // Resumes a crypto handshake with the server after a timeout. |
| 164 int ResumeCryptoConnect(const CompletionCallback& callback); | 164 int ResumeCryptoConnect(const CompletionCallback& callback); |
| 165 | 165 |
| 166 // Causes the QuicConnectionHelper to start reading from the socket | 166 // Causes the QuicConnectionHelper to start reading from the socket |
| 167 // and passing the data along to the QuicConnection. | 167 // and passing the data along to the QuicConnection. |
| 168 void StartReading(); | 168 void StartReading(); |
| 169 | 169 |
| 170 // Close the session because of |error| and notifies the factory | 170 // Close the session because of |error| and notifies the factory |
| 171 // that this session has been closed, which will delete the session. | 171 // that this session has been closed, which will delete the session. |
| 172 void CloseSessionOnError(int error); | 172 void CloseSessionOnError(int error, QuicErrorCode quic_error); |
| 173 | 173 |
| 174 base::Value* GetInfoAsValue(const std::set<HostPortPair>& aliases); | 174 base::Value* GetInfoAsValue(const std::set<HostPortPair>& aliases); |
| 175 | 175 |
| 176 const BoundNetLog& net_log() const { return net_log_; } | 176 const BoundNetLog& net_log() const { return net_log_; } |
| 177 | 177 |
| 178 base::WeakPtr<QuicClientSession> GetWeakPtr(); | 178 base::WeakPtr<QuicClientSession> GetWeakPtr(); |
| 179 | 179 |
| 180 // Returns the number of client hello messages that have been sent on the | 180 // Returns the number of client hello messages that have been sent on the |
| 181 // crypto stream. If the handshake has completed then this is one greater | 181 // crypto stream. If the handshake has completed then this is one greater |
| 182 // than the number of round-trips needed for the handshake. | 182 // than the number of round-trips needed for the handshake. |
| (...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 254 // on this session. Existing stream will continue to be processed. | 254 // on this session. Existing stream will continue to be processed. |
| 255 bool going_away_; | 255 bool going_away_; |
| 256 base::WeakPtrFactory<QuicClientSession> weak_factory_; | 256 base::WeakPtrFactory<QuicClientSession> weak_factory_; |
| 257 | 257 |
| 258 DISALLOW_COPY_AND_ASSIGN(QuicClientSession); | 258 DISALLOW_COPY_AND_ASSIGN(QuicClientSession); |
| 259 }; | 259 }; |
| 260 | 260 |
| 261 } // namespace net | 261 } // namespace net |
| 262 | 262 |
| 263 #endif // NET_QUIC_QUIC_CLIENT_SESSION_H_ | 263 #endif // NET_QUIC_QUIC_CLIENT_SESSION_H_ |
| OLD | NEW |