| 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_HTTP_HTTP_RESPONSE_HEADERS_H_ | 5 #ifndef NET_HTTP_HTTP_RESPONSE_HEADERS_H_ | 
| 6 #define NET_HTTP_HTTP_RESPONSE_HEADERS_H_ | 6 #define NET_HTTP_HTTP_RESPONSE_HEADERS_H_ | 
| 7 | 7 | 
| 8 #include <string> | 8 #include <string> | 
| 9 #include <vector> | 9 #include <vector> | 
| 10 | 10 | 
| (...skipping 268 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 279   // |*instance_length| = size in bytes of the object requested | 279   // |*instance_length| = size in bytes of the object requested | 
| 280   // If any of the above values is unknown, its value will be -1. | 280   // If any of the above values is unknown, its value will be -1. | 
| 281   bool GetContentRange(int64* first_byte_position, | 281   bool GetContentRange(int64* first_byte_position, | 
| 282                        int64* last_byte_position, | 282                        int64* last_byte_position, | 
| 283                        int64* instance_length) const; | 283                        int64* instance_length) const; | 
| 284 | 284 | 
| 285   // Returns true if the response is chunk-encoded. | 285   // Returns true if the response is chunk-encoded. | 
| 286   bool IsChunkEncoded() const; | 286   bool IsChunkEncoded() const; | 
| 287 | 287 | 
| 288   // Creates a Value for use with the NetLog containing the response headers. | 288   // Creates a Value for use with the NetLog containing the response headers. | 
| 289   base::Value* NetLogCallback(NetLogCaptureMode capture_mode) const; | 289   scoped_ptr<base::Value> NetLogCallback(NetLogCaptureMode capture_mode) const; | 
| 290 | 290 | 
| 291   // Takes in a Value created by the above function, and attempts to create a | 291   // Takes in a Value created by the above function, and attempts to create a | 
| 292   // copy of the original headers.  Returns true on success.  On failure, | 292   // copy of the original headers.  Returns true on success.  On failure, | 
| 293   // clears |http_response_headers|. | 293   // clears |http_response_headers|. | 
| 294   // TODO(mmenke):  Long term, we want to remove this, and migrate external | 294   // TODO(mmenke):  Long term, we want to remove this, and migrate external | 
| 295   //                consumers to be NetworkDelegates. | 295   //                consumers to be NetworkDelegates. | 
| 296   static bool FromNetLogParam( | 296   static bool FromNetLogParam( | 
| 297       const base::Value* event_param, | 297       const base::Value* event_param, | 
| 298       scoped_refptr<HttpResponseHeaders>* http_response_headers); | 298       scoped_refptr<HttpResponseHeaders>* http_response_headers); | 
| 299 | 299 | 
| (...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 409 | 409 | 
| 410   // The parsed http version number (not normalized). | 410   // The parsed http version number (not normalized). | 
| 411   HttpVersion parsed_http_version_; | 411   HttpVersion parsed_http_version_; | 
| 412 | 412 | 
| 413   DISALLOW_COPY_AND_ASSIGN(HttpResponseHeaders); | 413   DISALLOW_COPY_AND_ASSIGN(HttpResponseHeaders); | 
| 414 }; | 414 }; | 
| 415 | 415 | 
| 416 }  // namespace net | 416 }  // namespace net | 
| 417 | 417 | 
| 418 #endif  // NET_HTTP_HTTP_RESPONSE_HEADERS_H_ | 418 #endif  // NET_HTTP_HTTP_RESPONSE_HEADERS_H_ | 
| OLD | NEW | 
|---|