OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 COMPONENTS_ARC_ARC_BRIDGE_SERVICE_H_ | 5 #ifndef COMPONENTS_ARC_ARC_BRIDGE_SERVICE_H_ |
6 #define COMPONENTS_ARC_ARC_BRIDGE_SERVICE_H_ | 6 #define COMPONENTS_ARC_ARC_BRIDGE_SERVICE_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
60 virtual ~ArcBridgeService(); | 60 virtual ~ArcBridgeService(); |
61 | 61 |
62 // Gets the global instance of the ARC Bridge Service. This can only be | 62 // Gets the global instance of the ARC Bridge Service. This can only be |
63 // called on the thread that this class was created on. | 63 // called on the thread that this class was created on. |
64 static ArcBridgeService* Get(); | 64 static ArcBridgeService* Get(); |
65 | 65 |
66 // Return true if ARC has been enabled through a commandline | 66 // Return true if ARC has been enabled through a commandline |
67 // switch. | 67 // switch. |
68 static bool GetEnabled(const base::CommandLine* command_line); | 68 static bool GetEnabled(const base::CommandLine* command_line); |
69 | 69 |
| 70 // Return true if ARC is available on the current board. |
| 71 static bool GetAvailable(const base::CommandLine* command_line); |
| 72 |
70 // HandleStartup() should be called upon profile startup. This will only | 73 // HandleStartup() should be called upon profile startup. This will only |
71 // launch an instance if the instance is enabled. | 74 // launch an instance if the instance is enabled. |
72 // This can only be called on the thread that this class was created on. | 75 // This can only be called on the thread that this class was created on. |
73 virtual void HandleStartup() = 0; | 76 virtual void HandleStartup() = 0; |
74 | 77 |
75 // Shutdown() should be called when the browser is shutting down. This can | 78 // Shutdown() should be called when the browser is shutting down. This can |
76 // only be called on the thread that this class was created on. | 79 // only be called on the thread that this class was created on. |
77 virtual void Shutdown() = 0; | 80 virtual void Shutdown() = 0; |
78 | 81 |
79 // Adds or removes observers. This can only be called on the thread that this | 82 // Adds or removes observers. This can only be called on the thread that this |
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
221 | 224 |
222 // WeakPtrFactory to use callbacks. | 225 // WeakPtrFactory to use callbacks. |
223 base::WeakPtrFactory<ArcBridgeService> weak_factory_; | 226 base::WeakPtrFactory<ArcBridgeService> weak_factory_; |
224 | 227 |
225 DISALLOW_COPY_AND_ASSIGN(ArcBridgeService); | 228 DISALLOW_COPY_AND_ASSIGN(ArcBridgeService); |
226 }; | 229 }; |
227 | 230 |
228 } // namespace arc | 231 } // namespace arc |
229 | 232 |
230 #endif // COMPONENTS_ARC_ARC_BRIDGE_SERVICE_H_ | 233 #endif // COMPONENTS_ARC_ARC_BRIDGE_SERVICE_H_ |
OLD | NEW |