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 // This file declares HttpCache::Transaction, a private class of HttpCache so | 5 // This file declares HttpCache::Transaction, a private class of HttpCache so |
6 // it should only be included by http_cache.cc | 6 // it should only be included by http_cache.cc |
7 | 7 |
8 #ifndef NET_HTTP_HTTP_CACHE_TRANSACTION_H_ | 8 #ifndef NET_HTTP_HTTP_CACHE_TRANSACTION_H_ |
9 #define NET_HTTP_HTTP_CACHE_TRANSACTION_H_ | 9 #define NET_HTTP_HTTP_CACHE_TRANSACTION_H_ |
10 | 10 |
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
124 virtual int64 GetTotalReceivedBytes() const OVERRIDE; | 124 virtual int64 GetTotalReceivedBytes() const OVERRIDE; |
125 virtual void DoneReading() OVERRIDE; | 125 virtual void DoneReading() OVERRIDE; |
126 virtual const HttpResponseInfo* GetResponseInfo() const OVERRIDE; | 126 virtual const HttpResponseInfo* GetResponseInfo() const OVERRIDE; |
127 virtual LoadState GetLoadState() const OVERRIDE; | 127 virtual LoadState GetLoadState() const OVERRIDE; |
128 virtual UploadProgress GetUploadProgress(void) const OVERRIDE; | 128 virtual UploadProgress GetUploadProgress(void) const OVERRIDE; |
129 virtual bool GetLoadTimingInfo( | 129 virtual bool GetLoadTimingInfo( |
130 LoadTimingInfo* load_timing_info) const OVERRIDE; | 130 LoadTimingInfo* load_timing_info) const OVERRIDE; |
131 virtual void SetPriority(RequestPriority priority) OVERRIDE; | 131 virtual void SetPriority(RequestPriority priority) OVERRIDE; |
132 virtual void SetWebSocketHandshakeStreamCreateHelper( | 132 virtual void SetWebSocketHandshakeStreamCreateHelper( |
133 net::WebSocketHandshakeStreamBase::CreateHelper* create_helper) OVERRIDE; | 133 net::WebSocketHandshakeStreamBase::CreateHelper* create_helper) OVERRIDE; |
| 134 virtual void SetBeforeNetworkStartCallback( |
| 135 const BeforeNetworkStartCallback& callback) OVERRIDE; |
| 136 virtual int ResumeNetworkStart() OVERRIDE; |
134 | 137 |
135 private: | 138 private: |
136 static const size_t kNumValidationHeaders = 2; | 139 static const size_t kNumValidationHeaders = 2; |
137 // Helper struct to pair a header name with its value, for | 140 // Helper struct to pair a header name with its value, for |
138 // headers used to validate cache entries. | 141 // headers used to validate cache entries. |
139 struct ValidationHeaders { | 142 struct ValidationHeaders { |
140 ValidationHeaders() : initialized(false) {} | 143 ValidationHeaders() : initialized(false) {} |
141 | 144 |
142 std::string values[kNumValidationHeaders]; | 145 std::string values[kNumValidationHeaders]; |
143 bool initialized; | 146 bool initialized; |
(...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
431 // before the caller requests load timing information. | 434 // before the caller requests load timing information. |
432 scoped_ptr<LoadTimingInfo> old_network_trans_load_timing_; | 435 scoped_ptr<LoadTimingInfo> old_network_trans_load_timing_; |
433 | 436 |
434 // The helper object to use to create WebSocketHandshakeStreamBase | 437 // The helper object to use to create WebSocketHandshakeStreamBase |
435 // objects. Only relevant when establishing a WebSocket connection. | 438 // objects. Only relevant when establishing a WebSocket connection. |
436 // This is passed to the underlying network transaction. It is stored here in | 439 // This is passed to the underlying network transaction. It is stored here in |
437 // case the transaction does not exist yet. | 440 // case the transaction does not exist yet. |
438 WebSocketHandshakeStreamBase::CreateHelper* | 441 WebSocketHandshakeStreamBase::CreateHelper* |
439 websocket_handshake_stream_base_create_helper_; | 442 websocket_handshake_stream_base_create_helper_; |
440 | 443 |
| 444 BeforeNetworkStartCallback before_network_start_callback_; |
| 445 |
441 DISALLOW_COPY_AND_ASSIGN(Transaction); | 446 DISALLOW_COPY_AND_ASSIGN(Transaction); |
442 }; | 447 }; |
443 | 448 |
444 } // namespace net | 449 } // namespace net |
445 | 450 |
446 #endif // NET_HTTP_HTTP_CACHE_TRANSACTION_H_ | 451 #endif // NET_HTTP_HTTP_CACHE_TRANSACTION_H_ |
OLD | NEW |