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

Side by Side Diff: content/browser/loader/resource_dispatcher_host_impl.h

Issue 1355063004: Template methods on Timer classes instead of the classes themselves. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: timer: fixcaller Created 5 years, 3 months 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 // This is the browser side of the resource dispatcher, it receives requests 5 // This is the browser side of the resource dispatcher, it receives requests
6 // from the child process (i.e. [Renderer, Plugin, Worker]ProcessHost), and 6 // from the child process (i.e. [Renderer, Plugin, Worker]ProcessHost), and
7 // dispatches them to URLRequests. It then forwards the messages from the 7 // dispatches them to URLRequests. It then forwards the messages from the
8 // URLRequests back to the correct process for handling. 8 // URLRequests back to the correct process for handling.
9 // 9 //
10 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc e-loading 10 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc e-loading
(...skipping 504 matching lines...) Expand 10 before | Expand all | Expand 10 after
515 // the download_to_file mechanism. We avoid deleting them until 515 // the download_to_file mechanism. We avoid deleting them until
516 // the client no longer needs them. 516 // the client no longer needs them.
517 typedef std::map<int, scoped_refptr<storage::ShareableFileReference> > 517 typedef std::map<int, scoped_refptr<storage::ShareableFileReference> >
518 DeletableFilesMap; // key is request id 518 DeletableFilesMap; // key is request id
519 typedef std::map<int, DeletableFilesMap> 519 typedef std::map<int, DeletableFilesMap>
520 RegisteredTempFiles; // key is child process id 520 RegisteredTempFiles; // key is child process id
521 RegisteredTempFiles registered_temp_files_; 521 RegisteredTempFiles registered_temp_files_;
522 522
523 // A timer that periodically calls UpdateLoadInfo while pending_loaders_ is 523 // A timer that periodically calls UpdateLoadInfo while pending_loaders_ is
524 // not empty and at least one RenderViewHost is loading. 524 // not empty and at least one RenderViewHost is loading.
525 scoped_ptr<base::RepeatingTimer<ResourceDispatcherHostImpl> > 525 scoped_ptr<base::RepeatingTimer> update_load_states_timer_;
526 update_load_states_timer_;
527 526
528 // We own the save file manager. 527 // We own the save file manager.
529 scoped_refptr<SaveFileManager> save_file_manager_; 528 scoped_refptr<SaveFileManager> save_file_manager_;
530 529
531 // Request ID for browser initiated requests. request_ids generated by 530 // Request ID for browser initiated requests. request_ids generated by
532 // child processes are counted up from 0, while browser created requests 531 // child processes are counted up from 0, while browser created requests
533 // start at -2 and go down from there. (We need to start at -2 because -1 is 532 // start at -2 and go down from there. (We need to start at -2 because -1 is
534 // used as a special value all over the resource_dispatcher_host for 533 // used as a special value all over the resource_dispatcher_host for
535 // uninitialized variables.) This way, we no longer have the unlikely (but 534 // uninitialized variables.) This way, we no longer have the unlikely (but
536 // observed in the real world!) event where we have two requests with the same 535 // observed in the real world!) event where we have two requests with the same
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
596 DelegateMap delegate_map_; 595 DelegateMap delegate_map_;
597 596
598 scoped_ptr<ResourceScheduler> scheduler_; 597 scoped_ptr<ResourceScheduler> scheduler_;
599 598
600 DISALLOW_COPY_AND_ASSIGN(ResourceDispatcherHostImpl); 599 DISALLOW_COPY_AND_ASSIGN(ResourceDispatcherHostImpl);
601 }; 600 };
602 601
603 } // namespace content 602 } // namespace content
604 603
605 #endif // CONTENT_BROWSER_LOADER_RESOURCE_DISPATCHER_HOST_IMPL_H_ 604 #endif // CONTENT_BROWSER_LOADER_RESOURCE_DISPATCHER_HOST_IMPL_H_
OLDNEW
« no previous file with comments | « content/browser/loader/power_save_block_resource_throttle.h ('k') | content/browser/loader/resource_dispatcher_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698