| 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_PUBLIC_BROWSER_BROWSER_THREAD_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_BROWSER_THREAD_H_ |
| 6 #define CONTENT_PUBLIC_BROWSER_BROWSER_THREAD_H_ | 6 #define CONTENT_PUBLIC_BROWSER_BROWSER_THREAD_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/callback.h" | 10 #include "base/callback.h" |
| (...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 190 // prior to browser shutdown. | 190 // prior to browser shutdown. |
| 191 // Note: see related ContentBrowserClient::PostAfterStartupTask. | 191 // Note: see related ContentBrowserClient::PostAfterStartupTask. |
| 192 static void PostAfterStartupTask( | 192 static void PostAfterStartupTask( |
| 193 const tracked_objects::Location& from_here, | 193 const tracked_objects::Location& from_here, |
| 194 const scoped_refptr<base::TaskRunner>& task_runner, | 194 const scoped_refptr<base::TaskRunner>& task_runner, |
| 195 const base::Closure& task); | 195 const base::Closure& task); |
| 196 | 196 |
| 197 // Returns the thread pool used for blocking file I/O. Use this object to | 197 // Returns the thread pool used for blocking file I/O. Use this object to |
| 198 // perform random blocking operations such as file writes or querying the | 198 // perform random blocking operations such as file writes or querying the |
| 199 // Windows registry. | 199 // Windows registry. |
| 200 static base::SequencedWorkerPool* GetBlockingPool() WARN_UNUSED_RESULT; | 200 static base::SequencedWorkerPool* GetBlockingPool(); |
| 201 | 201 |
| 202 // Callable on any thread. Returns whether the given well-known thread is | 202 // Callable on any thread. Returns whether the given well-known thread is |
| 203 // initialized. | 203 // initialized. |
| 204 static bool IsThreadInitialized(ID identifier) WARN_UNUSED_RESULT; | 204 static bool IsThreadInitialized(ID identifier) WARN_UNUSED_RESULT; |
| 205 | 205 |
| 206 // Callable on any thread. Returns whether you're currently on a particular | 206 // Callable on any thread. Returns whether you're currently on a particular |
| 207 // thread. To DCHECK this, use the DCHECK_CURRENTLY_ON() macro above. | 207 // thread. To DCHECK this, use the DCHECK_CURRENTLY_ON() macro above. |
| 208 static bool CurrentlyOn(ID identifier) WARN_UNUSED_RESULT; | 208 static bool CurrentlyOn(ID identifier) WARN_UNUSED_RESULT; |
| 209 | 209 |
| 210 // Callable on any thread. Returns whether the threads message loop is valid. | 210 // Callable on any thread. Returns whether the threads message loop is valid. |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 297 private: | 297 private: |
| 298 friend class BrowserThreadImpl; | 298 friend class BrowserThreadImpl; |
| 299 | 299 |
| 300 BrowserThread() {} | 300 BrowserThread() {} |
| 301 DISALLOW_COPY_AND_ASSIGN(BrowserThread); | 301 DISALLOW_COPY_AND_ASSIGN(BrowserThread); |
| 302 }; | 302 }; |
| 303 | 303 |
| 304 } // namespace content | 304 } // namespace content |
| 305 | 305 |
| 306 #endif // CONTENT_PUBLIC_BROWSER_BROWSER_THREAD_H_ | 306 #endif // CONTENT_PUBLIC_BROWSER_BROWSER_THREAD_H_ |
| OLD | NEW |