OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 // Chromium settings and storage represent user-selected preferences and | 5 // Chromium settings and storage represent user-selected preferences and |
6 // information and MUST not be extracted, overwritten or modified except | 6 // information and MUST not be extracted, overwritten or modified except |
7 // through Chromium defined APIs. | 7 // through Chromium defined APIs. |
8 | 8 |
9 #ifndef COMPONENTS_WEBDATA_COMMON_WEB_DATA_REQUEST_MANAGER_H__ | 9 #ifndef COMPONENTS_WEBDATA_COMMON_WEB_DATA_REQUEST_MANAGER_H__ |
10 #define COMPONENTS_WEBDATA_COMMON_WEB_DATA_REQUEST_MANAGER_H__ | 10 #define COMPONENTS_WEBDATA_COMMON_WEB_DATA_REQUEST_MANAGER_H__ |
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
120 // This will notify the consumer in whatever thread was used to create this | 120 // This will notify the consumer in whatever thread was used to create this |
121 // request. | 121 // request. |
122 void RequestCompletedOnThread(std::unique_ptr<WebDataRequest> request); | 122 void RequestCompletedOnThread(std::unique_ptr<WebDataRequest> request); |
123 | 123 |
124 // A lock to protect pending requests and next request handle. | 124 // A lock to protect pending requests and next request handle. |
125 base::Lock pending_lock_; | 125 base::Lock pending_lock_; |
126 | 126 |
127 // Next handle to be used for requests. Incremented for each use. | 127 // Next handle to be used for requests. Incremented for each use. |
128 WebDataServiceBase::Handle next_request_handle_; | 128 WebDataServiceBase::Handle next_request_handle_; |
129 | 129 |
130 typedef std::map<WebDataServiceBase::Handle, WebDataRequest*> RequestMap; | 130 std::map<WebDataServiceBase::Handle, WebDataRequest*> pending_requests_; |
131 RequestMap pending_requests_; | |
132 | 131 |
133 DISALLOW_COPY_AND_ASSIGN(WebDataRequestManager); | 132 DISALLOW_COPY_AND_ASSIGN(WebDataRequestManager); |
134 }; | 133 }; |
135 | 134 |
136 #endif // COMPONENTS_WEBDATA_COMMON_WEB_DATA_REQUEST_MANAGER_H__ | 135 #endif // COMPONENTS_WEBDATA_COMMON_WEB_DATA_REQUEST_MANAGER_H__ |
OLD | NEW |