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

Side by Side Diff: mojo/shell/task_runners.h

Issue 323593002: Mojo: Use network service to load non-local Mojo Apps. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 6 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « mojo/shell/switches.cc ('k') | mojo/shell/task_runners.cc » ('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 MOJO_SHELL_TASK_RUNNERS_H_ 5 #ifndef MOJO_SHELL_TASK_RUNNERS_H_
6 #define MOJO_SHELL_TASK_RUNNERS_H_ 6 #define MOJO_SHELL_TASK_RUNNERS_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 15 matching lines...) Expand all
26 ~TaskRunners(); 26 ~TaskRunners();
27 27
28 base::SingleThreadTaskRunner* ui_runner() const { 28 base::SingleThreadTaskRunner* ui_runner() const {
29 return ui_runner_.get(); 29 return ui_runner_.get();
30 } 30 }
31 31
32 base::SingleThreadTaskRunner* io_runner() const { 32 base::SingleThreadTaskRunner* io_runner() const {
33 return io_thread_->message_loop_proxy(); 33 return io_thread_->message_loop_proxy();
34 } 34 }
35 35
36 base::SingleThreadTaskRunner* file_runner() const {
37 return file_thread_->message_loop_proxy();
38 }
39
40 base::MessageLoopProxy* cache_runner() const {
41 return cache_thread_->message_loop_proxy();
42 }
43
44 base::SequencedWorkerPool* blocking_pool() const { 36 base::SequencedWorkerPool* blocking_pool() const {
45 return blocking_pool_.get(); 37 return blocking_pool_.get();
46 } 38 }
47 39
48 private: 40 private:
49 // TODO(beng): should this be named shell_runner_? 41 // TODO(beng): should this be named shell_runner_?
50 scoped_refptr<base::SingleThreadTaskRunner> ui_runner_; 42 scoped_refptr<base::SingleThreadTaskRunner> ui_runner_;
51 scoped_ptr<base::Thread> cache_thread_;
52 scoped_ptr<base::Thread> io_thread_; 43 scoped_ptr<base::Thread> io_thread_;
53 scoped_ptr<base::Thread> file_thread_;
54 44
55 scoped_refptr<base::SequencedWorkerPool> blocking_pool_; 45 scoped_refptr<base::SequencedWorkerPool> blocking_pool_;
56 46
57 DISALLOW_COPY_AND_ASSIGN(TaskRunners); 47 DISALLOW_COPY_AND_ASSIGN(TaskRunners);
58 }; 48 };
59 49
60 } // namespace shell 50 } // namespace shell
61 } // namespace mojo 51 } // namespace mojo
62 52
63 #endif // MOJO_SHELL_TASK_RUNNERS_H_ 53 #endif // MOJO_SHELL_TASK_RUNNERS_H_
OLDNEW
« no previous file with comments | « mojo/shell/switches.cc ('k') | mojo/shell/task_runners.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698