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_HTTP_HTTP_TRANSACTION_H_ | 5 #ifndef NET_HTTP_HTTP_TRANSACTION_H_ |
| 6 #define NET_HTTP_HTTP_TRANSACTION_H_ | 6 #define NET_HTTP_HTTP_TRANSACTION_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include "net/base/completion_callback.h" | 10 #include "net/base/completion_callback.h" |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 65 // Regardless of the return value, the caller is expected to keep the | 65 // Regardless of the return value, the caller is expected to keep the |
| 66 // request_info object alive until Destroy is called on the transaction. | 66 // request_info object alive until Destroy is called on the transaction. |
| 67 // | 67 // |
| 68 // NOTE: The transaction is not responsible for deleting the callback object. | 68 // NOTE: The transaction is not responsible for deleting the callback object. |
| 69 // | 69 // |
| 70 // Profiling information for the request is saved to |net_log| if non-NULL. | 70 // Profiling information for the request is saved to |net_log| if non-NULL. |
| 71 virtual int Start(const HttpRequestInfo* request_info, | 71 virtual int Start(const HttpRequestInfo* request_info, |
| 72 const CompletionCallback& callback, | 72 const CompletionCallback& callback, |
| 73 const NetLogWithSource& net_log) = 0; | 73 const NetLogWithSource& net_log) = 0; |
| 74 | 74 |
| 75 // Ownership of the transaction is transferred from the consumer to the | |
|
jkarlin
2016/12/06 18:08:18
s/from the consumer to the transaction/to the tran
shivanisha
2016/12/06 21:53:35
done.
| |
| 76 // transaction. It can be either reset in the method or reset can be deferred | |
| 77 // if some asynchronous operation is in progress. | |
| 78 virtual void Orphan(std::unique_ptr<HttpTransaction> trans) = 0; | |
|
jkarlin
2016/12/06 18:08:18
Let's move this method to the bottom of the public
shivanisha
2016/12/06 21:53:35
done.
| |
| 79 | |
| 75 // Restarts the HTTP transaction, ignoring the last error. This call can | 80 // Restarts the HTTP transaction, ignoring the last error. This call can |
| 76 // only be made after a call to Start (or RestartIgnoringLastError) failed. | 81 // only be made after a call to Start (or RestartIgnoringLastError) failed. |
| 77 // Once Read has been called, this method cannot be called. This method is | 82 // Once Read has been called, this method cannot be called. This method is |
| 78 // used, for example, to continue past various SSL related errors. | 83 // used, for example, to continue past various SSL related errors. |
| 79 // | 84 // |
| 80 // Not all errors can be ignored using this method. See error code | 85 // Not all errors can be ignored using this method. See error code |
| 81 // descriptions for details about errors that can be ignored. | 86 // descriptions for details about errors that can be ignored. |
| 82 // | 87 // |
| 83 // NOTE: The transaction is not responsible for deleting the callback object. | 88 // NOTE: The transaction is not responsible for deleting the callback object. |
| 84 // | 89 // |
| (...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 192 | 197 |
| 193 // Resumes the transaction after being deferred. | 198 // Resumes the transaction after being deferred. |
| 194 virtual int ResumeNetworkStart() = 0; | 199 virtual int ResumeNetworkStart() = 0; |
| 195 | 200 |
| 196 virtual void GetConnectionAttempts(ConnectionAttempts* out) const = 0; | 201 virtual void GetConnectionAttempts(ConnectionAttempts* out) const = 0; |
| 197 }; | 202 }; |
| 198 | 203 |
| 199 } // namespace net | 204 } // namespace net |
| 200 | 205 |
| 201 #endif // NET_HTTP_HTTP_TRANSACTION_H_ | 206 #endif // NET_HTTP_HTTP_TRANSACTION_H_ |
| OLD | NEW |