Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(322)

Side by Side Diff: storage/browser/fileapi/file_system_operation_runner.h

Issue 2496653002: Part 2 of base::IDMap refactor to eliminate IDMapOwnPointer/IDMapExternalPointer modes (Closed)
Patch Set: typedefs => using statements, update comments in base/id_map.h Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ipc/message_router.h ('k') | ui/ozone/platform/headless/headless_window_manager.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 STORAGE_BROWSER_FILEAPI_FILE_SYSTEM_OPERATION_RUNNER_H_ 5 #ifndef STORAGE_BROWSER_FILEAPI_FILE_SYSTEM_OPERATION_RUNNER_H_
6 #define STORAGE_BROWSER_FILEAPI_FILE_SYSTEM_OPERATION_RUNNER_H_ 6 #define STORAGE_BROWSER_FILEAPI_FILE_SYSTEM_OPERATION_RUNNER_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <map> 10 #include <map>
(...skipping 289 matching lines...) Expand 10 before | Expand all | Expand 10 after
300 void PrepareForRead(OperationID id, const FileSystemURL& url); 300 void PrepareForRead(OperationID id, const FileSystemURL& url);
301 301
302 // These must be called at the beginning and end of any async operations. 302 // These must be called at the beginning and end of any async operations.
303 OperationHandle BeginOperation(std::unique_ptr<FileSystemOperation> operation, 303 OperationHandle BeginOperation(std::unique_ptr<FileSystemOperation> operation,
304 base::WeakPtr<BeginOperationScoper> scope); 304 base::WeakPtr<BeginOperationScoper> scope);
305 void FinishOperation(OperationID id); 305 void FinishOperation(OperationID id);
306 306
307 // Not owned; file_system_context owns this. 307 // Not owned; file_system_context owns this.
308 FileSystemContext* file_system_context_; 308 FileSystemContext* file_system_context_;
309 309
310 // IDMap<FileSystemOperation, IDMapOwnPointer> operations_; 310 // IDMap<std::unique_ptr<FileSystemOperation>> operations_;
311 IDMap<FileSystemOperation, IDMapOwnPointer> operations_; 311 IDMap<std::unique_ptr<FileSystemOperation>> operations_;
312 312
313 // We keep track of the file to be modified by each operation so that 313 // We keep track of the file to be modified by each operation so that
314 // we can notify observers when we're done. 314 // we can notify observers when we're done.
315 typedef std::map<OperationID, FileSystemURLSet> OperationToURLSet; 315 typedef std::map<OperationID, FileSystemURLSet> OperationToURLSet;
316 OperationToURLSet write_target_urls_; 316 OperationToURLSet write_target_urls_;
317 317
318 // Operations that are finished but not yet fire their callbacks. 318 // Operations that are finished but not yet fire their callbacks.
319 std::set<OperationID> finished_operations_; 319 std::set<OperationID> finished_operations_;
320 320
321 // Callbacks for stray cancels whose target operation is already finished. 321 // Callbacks for stray cancels whose target operation is already finished.
322 std::map<OperationID, StatusCallback> stray_cancel_callbacks_; 322 std::map<OperationID, StatusCallback> stray_cancel_callbacks_;
323 323
324 DISALLOW_COPY_AND_ASSIGN(FileSystemOperationRunner); 324 DISALLOW_COPY_AND_ASSIGN(FileSystemOperationRunner);
325 }; 325 };
326 326
327 } // namespace storage 327 } // namespace storage
328 328
329 #endif // STORAGE_BROWSER_FILEAPI_FILE_SYSTEM_OPERATION_RUNNER_H_ 329 #endif // STORAGE_BROWSER_FILEAPI_FILE_SYSTEM_OPERATION_RUNNER_H_
OLDNEW
« no previous file with comments | « ipc/message_router.h ('k') | ui/ozone/platform/headless/headless_window_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698