| OLD | NEW |
| 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 SERVICES_SERVICE_MANAGER_STANDALONE_CONTEXT_H_ | 5 #ifndef SERVICES_SERVICE_MANAGER_STANDALONE_CONTEXT_H_ |
| 6 #define SERVICES_SERVICE_MANAGER_STANDALONE_CONTEXT_H_ | 6 #define SERVICES_SERVICE_MANAGER_STANDALONE_CONTEXT_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 | 9 |
| 10 #include "base/callback_forward.h" | 10 #include "base/callback_forward.h" |
| 11 #include "base/macros.h" | 11 #include "base/macros.h" |
| 12 #include "base/memory/ref_counted.h" | 12 #include "base/memory/ref_counted.h" |
| 13 #include "base/threading/thread.h" | 13 #include "base/threading/thread.h" |
| 14 #include "base/time/time.h" | 14 #include "base/time/time.h" |
| 15 #include "mojo/edk/embedder/process_delegate.h" | 15 #include "mojo/edk/embedder/process_delegate.h" |
| 16 #include "services/service_manager/service_manager.h" | 16 #include "services/service_manager/service_manager.h" |
| 17 #include "services/service_manager/standalone/tracer.h" | 17 #include "services/service_manager/standalone/tracer.h" |
| 18 #include "services/tracing/public/cpp/provider.h" |
| 18 | 19 |
| 19 namespace base { | 20 namespace base { |
| 20 class SingleThreadTaskRunner; | 21 class SingleThreadTaskRunner; |
| 21 } | 22 } |
| 22 | 23 |
| 23 namespace catalog { | 24 namespace catalog { |
| 24 class Catalog; | 25 class Catalog; |
| 25 class Store; | 26 class Store; |
| 26 } | 27 } |
| 27 | 28 |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 65 // Runs the app specified by |name|. | 66 // Runs the app specified by |name|. |
| 66 void Run(const std::string& name); | 67 void Run(const std::string& name); |
| 67 | 68 |
| 68 scoped_refptr<base::SingleThreadTaskRunner> service_manager_runner_; | 69 scoped_refptr<base::SingleThreadTaskRunner> service_manager_runner_; |
| 69 std::unique_ptr<base::Thread> io_thread_; | 70 std::unique_ptr<base::Thread> io_thread_; |
| 70 scoped_refptr<base::SequencedWorkerPool> blocking_pool_; | 71 scoped_refptr<base::SequencedWorkerPool> blocking_pool_; |
| 71 | 72 |
| 72 // Ensure this is destructed before task_runners_ since it owns a message pipe | 73 // Ensure this is destructed before task_runners_ since it owns a message pipe |
| 73 // that needs the IO thread to destruct cleanly. | 74 // that needs the IO thread to destruct cleanly. |
| 74 Tracer tracer_; | 75 Tracer tracer_; |
| 76 tracing::Provider provider_; |
| 75 std::unique_ptr<catalog::Catalog> catalog_; | 77 std::unique_ptr<catalog::Catalog> catalog_; |
| 76 std::unique_ptr<ServiceManager> service_manager_; | 78 std::unique_ptr<ServiceManager> service_manager_; |
| 77 base::Time main_entry_time_; | 79 base::Time main_entry_time_; |
| 78 bool init_edk_ = false; | 80 bool init_edk_ = false; |
| 79 | 81 |
| 80 DISALLOW_COPY_AND_ASSIGN(Context); | 82 DISALLOW_COPY_AND_ASSIGN(Context); |
| 81 }; | 83 }; |
| 82 | 84 |
| 83 } // namespace service_manager | 85 } // namespace service_manager |
| 84 | 86 |
| 85 #endif // SERVICES_SERVICE_MANAGER_STANDALONE_CONTEXT_H_ | 87 #endif // SERVICES_SERVICE_MANAGER_STANDALONE_CONTEXT_H_ |
| OLD | NEW |