| 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 #ifndef NET_SPDY_SPDY_SESSION_H_ | 5 #ifndef NET_SPDY_SPDY_SESSION_H_ |
| 6 #define NET_SPDY_SPDY_SESSION_H_ | 6 #define NET_SPDY_SPDY_SESSION_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 24 matching lines...) Expand all Loading... |
| 35 #include "net/spdy/http2_priority_dependencies.h" | 35 #include "net/spdy/http2_priority_dependencies.h" |
| 36 #include "net/spdy/spdy_buffer.h" | 36 #include "net/spdy/spdy_buffer.h" |
| 37 #include "net/spdy/spdy_framer.h" | 37 #include "net/spdy/spdy_framer.h" |
| 38 #include "net/spdy/spdy_header_block.h" | 38 #include "net/spdy/spdy_header_block.h" |
| 39 #include "net/spdy/spdy_protocol.h" | 39 #include "net/spdy/spdy_protocol.h" |
| 40 #include "net/spdy/spdy_session_pool.h" | 40 #include "net/spdy/spdy_session_pool.h" |
| 41 #include "net/spdy/spdy_stream.h" | 41 #include "net/spdy/spdy_stream.h" |
| 42 #include "net/spdy/spdy_write_queue.h" | 42 #include "net/spdy/spdy_write_queue.h" |
| 43 #include "net/ssl/ssl_config_service.h" | 43 #include "net/ssl/ssl_config_service.h" |
| 44 #include "url/gurl.h" | 44 #include "url/gurl.h" |
| 45 #include "url/scheme_host_port.h" |
| 45 | 46 |
| 46 namespace net { | 47 namespace net { |
| 47 | 48 |
| 48 namespace test { | 49 namespace test { |
| 49 class SpdyStreamTest; | 50 class SpdyStreamTest; |
| 50 } | 51 } |
| 51 | 52 |
| 52 // This is somewhat arbitrary and not really fixed, but it will always work | 53 // This is somewhat arbitrary and not really fixed, but it will always work |
| 53 // reasonably with ethernet. Chop the world into 2-packet chunks. This is | 54 // reasonably with ethernet. Chop the world into 2-packet chunks. This is |
| 54 // somewhat arbitrary, but is reasonably small and ensures that we elicit | 55 // somewhat arbitrary, but is reasonably small and ensures that we elicit |
| (...skipping 342 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 397 SpdyRstStreamStatus status, | 398 SpdyRstStreamStatus status, |
| 398 const std::string& description); | 399 const std::string& description); |
| 399 | 400 |
| 400 // Check if a stream is active. | 401 // Check if a stream is active. |
| 401 bool IsStreamActive(SpdyStreamId stream_id) const; | 402 bool IsStreamActive(SpdyStreamId stream_id) const; |
| 402 | 403 |
| 403 // The LoadState is used for informing the user of the current network | 404 // The LoadState is used for informing the user of the current network |
| 404 // status, such as "resolving host", "connecting", etc. | 405 // status, such as "resolving host", "connecting", etc. |
| 405 LoadState GetLoadState() const; | 406 LoadState GetLoadState() const; |
| 406 | 407 |
| 408 // Returns server infomation in the form of (scheme/host/port). |
| 409 url::SchemeHostPort GetServer(); |
| 410 |
| 407 // Fills SSL info in |ssl_info| and returns true when SSL is in use. | 411 // Fills SSL info in |ssl_info| and returns true when SSL is in use. |
| 408 bool GetSSLInfo(SSLInfo* ssl_info, | 412 bool GetSSLInfo(SSLInfo* ssl_info, |
| 409 bool* was_npn_negotiated, | 413 bool* was_npn_negotiated, |
| 410 NextProto* protocol_negotiated); | 414 NextProto* protocol_negotiated); |
| 411 | 415 |
| 412 // Signs the EKM value for Token Binding from the TLS layer using |*key| and | 416 // Signs the EKM value for Token Binding from the TLS layer using |*key| and |
| 413 // puts the result in |*out|. Returns OK or ERR_FAILED. | 417 // puts the result in |*out|. Returns OK or ERR_FAILED. |
| 414 Error GetSignedEKMForTokenBinding(crypto::ECPrivateKey* key, | 418 Error GetSignedEKMForTokenBinding(crypto::ECPrivateKey* key, |
| 415 std::vector<uint8_t>* out); | 419 std::vector<uint8_t>* out); |
| 416 | 420 |
| (...skipping 810 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1227 // Used for posting asynchronous IO tasks. We use this even though | 1231 // Used for posting asynchronous IO tasks. We use this even though |
| 1228 // SpdySession is refcounted because we don't need to keep the SpdySession | 1232 // SpdySession is refcounted because we don't need to keep the SpdySession |
| 1229 // alive if the last reference is within a RunnableMethod. Just revoke the | 1233 // alive if the last reference is within a RunnableMethod. Just revoke the |
| 1230 // method. | 1234 // method. |
| 1231 base::WeakPtrFactory<SpdySession> weak_factory_; | 1235 base::WeakPtrFactory<SpdySession> weak_factory_; |
| 1232 }; | 1236 }; |
| 1233 | 1237 |
| 1234 } // namespace net | 1238 } // namespace net |
| 1235 | 1239 |
| 1236 #endif // NET_SPDY_SPDY_SESSION_H_ | 1240 #endif // NET_SPDY_SPDY_SESSION_H_ |
| OLD | NEW |