| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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_REPORT_SENDER_H_ | 5 #ifndef NET_URL_REQUEST_REPORT_SENDER_H_ |
| 6 #define NET_URL_REQUEST_REPORT_SENDER_H_ | 6 #define NET_URL_REQUEST_REPORT_SENDER_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <set> | 9 #include <set> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 61 | 61 |
| 62 // net::URLRequest::Delegate implementation. | 62 // net::URLRequest::Delegate implementation. |
| 63 void OnResponseStarted(URLRequest* request, int net_error) override; | 63 void OnResponseStarted(URLRequest* request, int net_error) override; |
| 64 void OnReadCompleted(URLRequest* request, int bytes_read) override; | 64 void OnReadCompleted(URLRequest* request, int bytes_read) override; |
| 65 | 65 |
| 66 private: | 66 private: |
| 67 net::URLRequestContext* const request_context_; | 67 net::URLRequestContext* const request_context_; |
| 68 | 68 |
| 69 CookiesPreference cookies_preference_; | 69 CookiesPreference cookies_preference_; |
| 70 | 70 |
| 71 // Owns the contained requests. | 71 std::set<std::unique_ptr<URLRequest>> inflight_requests_; |
| 72 std::set<URLRequest*> inflight_requests_; | |
| 73 | 72 |
| 74 // Called when a sent report results in an error. | 73 // Called when a sent report results in an error. |
| 75 ErrorCallback error_callback_; | 74 ErrorCallback error_callback_; |
| 76 | 75 |
| 77 DISALLOW_COPY_AND_ASSIGN(ReportSender); | 76 DISALLOW_COPY_AND_ASSIGN(ReportSender); |
| 78 }; | 77 }; |
| 79 | 78 |
| 80 } // namespace net | 79 } // namespace net |
| 81 | 80 |
| 82 #endif // NET_URL_REQUEST_REPORT_SENDER_H_ | 81 #endif // NET_URL_REQUEST_REPORT_SENDER_H_ |
| OLD | NEW |