Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_URL_REQUEST_URL_REQUEST_H_ | 5 #ifndef NET_URL_REQUEST_URL_REQUEST_H_ |
| 6 #define NET_URL_REQUEST_URL_REQUEST_H_ | 6 #define NET_URL_REQUEST_URL_REQUEST_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <map> | 9 #include <map> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 312 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 323 | 323 |
| 324 // Indicates that the request body should be sent using chunked transfer | 324 // Indicates that the request body should be sent using chunked transfer |
| 325 // encoding. This method may only be called before Start() is called. | 325 // encoding. This method may only be called before Start() is called. |
| 326 void EnableChunkedUpload(); | 326 void EnableChunkedUpload(); |
| 327 | 327 |
| 328 // Appends the given bytes to the request's upload data to be sent | 328 // Appends the given bytes to the request's upload data to be sent |
| 329 // immediately via chunked transfer encoding. When all data has been sent, | 329 // immediately via chunked transfer encoding. When all data has been sent, |
| 330 // call MarkEndOfChunks() to indicate the end of upload data. | 330 // call MarkEndOfChunks() to indicate the end of upload data. |
| 331 // | 331 // |
| 332 // This method may be called only after calling EnableChunkedUpload(). | 332 // This method may be called only after calling EnableChunkedUpload(). |
| 333 void AppendChunkToUpload(const char* bytes, int bytes_len); | 333 void AppendChunkToUpload(const char* bytes, int bytes_len, |
| 334 | 334 bool is_last_chunk); |
|
willchan no longer on Chromium
2011/03/03 19:47:48
http://dev.chromium.org/developers/coding-style#Co
| |
| 335 // Indicates the end of a chunked transfer encoded request body. | |
| 336 void MarkEndOfChunks(); | |
| 337 | 335 |
| 338 // Set the upload data directly. | 336 // Set the upload data directly. |
| 339 void set_upload(net::UploadData* upload); | 337 void set_upload(net::UploadData* upload); |
| 340 | 338 |
| 341 // Get the upload data directly. | 339 // Get the upload data directly. |
| 342 net::UploadData* get_upload(); | 340 net::UploadData* get_upload(); |
| 343 | 341 |
| 344 // Returns true if the request has a non-empty message body to upload. | 342 // Returns true if the request has a non-empty message body to upload. |
| 345 bool has_upload() const; | 343 bool has_upload() const; |
| 346 | 344 |
| (...skipping 317 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 664 const uint64 identifier_; | 662 const uint64 identifier_; |
| 665 | 663 |
| 666 base::debug::LeakTracker<URLRequest> leak_tracker_; | 664 base::debug::LeakTracker<URLRequest> leak_tracker_; |
| 667 | 665 |
| 668 DISALLOW_COPY_AND_ASSIGN(URLRequest); | 666 DISALLOW_COPY_AND_ASSIGN(URLRequest); |
| 669 }; | 667 }; |
| 670 | 668 |
| 671 } // namespace net | 669 } // namespace net |
| 672 | 670 |
| 673 #endif // NET_URL_REQUEST_URL_REQUEST_H_ | 671 #endif // NET_URL_REQUEST_URL_REQUEST_H_ |
| OLD | NEW |