OLD | NEW |
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 #ifndef CONTENT_BROWSER_BROWSER_THREAD_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_BROWSER_THREAD_IMPL_H_ |
6 #define CONTENT_BROWSER_BROWSER_THREAD_IMPL_H_ | 6 #define CONTENT_BROWSER_BROWSER_THREAD_IMPL_H_ |
7 | 7 |
8 #include "base/callback.h" | 8 #include "base/callback.h" |
9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
10 #include "base/single_thread_task_runner.h" | 10 #include "base/single_thread_task_runner.h" |
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
80 void UIThreadRun(base::RunLoop* run_loop); | 80 void UIThreadRun(base::RunLoop* run_loop); |
81 void DBThreadRun(base::RunLoop* run_loop); | 81 void DBThreadRun(base::RunLoop* run_loop); |
82 void FileThreadRun(base::RunLoop* run_loop); | 82 void FileThreadRun(base::RunLoop* run_loop); |
83 void FileUserBlockingThreadRun(base::RunLoop* run_loop); | 83 void FileUserBlockingThreadRun(base::RunLoop* run_loop); |
84 void ProcessLauncherThreadRun(base::RunLoop* run_loop); | 84 void ProcessLauncherThreadRun(base::RunLoop* run_loop); |
85 void CacheThreadRun(base::RunLoop* run_loop); | 85 void CacheThreadRun(base::RunLoop* run_loop); |
86 void IOThreadRun(base::RunLoop* run_loop); | 86 void IOThreadRun(base::RunLoop* run_loop); |
87 | 87 |
88 static bool PostTaskHelper(BrowserThread::ID identifier, | 88 static bool PostTaskHelper(BrowserThread::ID identifier, |
89 const tracked_objects::Location& from_here, | 89 const tracked_objects::Location& from_here, |
90 base::Closure task, | 90 base::OnceClosure task, |
91 base::TimeDelta delay, | 91 base::TimeDelta delay, |
92 bool nestable); | 92 bool nestable); |
93 | 93 |
94 // Common initialization code for the constructors. | 94 // Common initialization code for the constructors. |
95 void Initialize(); | 95 void Initialize(); |
96 | 96 |
97 // For testing. | 97 // For testing. |
98 friend class ContentTestSuiteBaseListener; | 98 friend class ContentTestSuiteBaseListener; |
99 friend class TestBrowserThreadBundle; | 99 friend class TestBrowserThreadBundle; |
100 static void FlushThreadPoolHelperForTesting(); | 100 static void FlushThreadPoolHelperForTesting(); |
101 | 101 |
102 // The identifier of this thread. Only one thread can exist with a given | 102 // The identifier of this thread. Only one thread can exist with a given |
103 // identifier at a given time. | 103 // identifier at a given time. |
104 ID identifier_; | 104 ID identifier_; |
105 }; | 105 }; |
106 | 106 |
107 } // namespace content | 107 } // namespace content |
108 | 108 |
109 #endif // CONTENT_BROWSER_BROWSER_THREAD_IMPL_H_ | 109 #endif // CONTENT_BROWSER_BROWSER_THREAD_IMPL_H_ |
OLD | NEW |