| 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_DEVTOOLS_DISCOVERY_DEVTOOLS_DISCOVERY_MANAGER_H_ | 5 #ifndef COMPONENTS_DEVTOOLS_DISCOVERY_DEVTOOLS_DISCOVERY_MANAGER_H_ |
| 6 #define COMPONENTS_DEVTOOLS_DISCOVERY_DEVTOOLS_DISCOVERY_MANAGER_H_ | 6 #define COMPONENTS_DEVTOOLS_DISCOVERY_DEVTOOLS_DISCOVERY_MANAGER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 static DevToolsDiscoveryManager* GetInstance(); | 31 static DevToolsDiscoveryManager* GetInstance(); |
| 32 | 32 |
| 33 void AddProvider(scoped_ptr<Provider> provider); | 33 void AddProvider(scoped_ptr<Provider> provider); |
| 34 void SetCreateCallback(const CreateCallback& callback); | 34 void SetCreateCallback(const CreateCallback& callback); |
| 35 | 35 |
| 36 // Caller takes ownership of created descriptors. | 36 // Caller takes ownership of created descriptors. |
| 37 DevToolsTargetDescriptor::List GetDescriptors(); | 37 DevToolsTargetDescriptor::List GetDescriptors(); |
| 38 scoped_ptr<DevToolsTargetDescriptor> CreateNew(const GURL& url); | 38 scoped_ptr<DevToolsTargetDescriptor> CreateNew(const GURL& url); |
| 39 | 39 |
| 40 private: | 40 private: |
| 41 friend struct DefaultSingletonTraits<DevToolsDiscoveryManager>; | 41 friend struct base::DefaultSingletonTraits<DevToolsDiscoveryManager>; |
| 42 | 42 |
| 43 DevToolsDiscoveryManager(); | 43 DevToolsDiscoveryManager(); |
| 44 ~DevToolsDiscoveryManager(); | 44 ~DevToolsDiscoveryManager(); |
| 45 DevToolsTargetDescriptor::List GetDescriptorsFromProviders(); | 45 DevToolsTargetDescriptor::List GetDescriptorsFromProviders(); |
| 46 | 46 |
| 47 std::vector<Provider*> providers_; | 47 std::vector<Provider*> providers_; |
| 48 CreateCallback create_callback_; | 48 CreateCallback create_callback_; |
| 49 | 49 |
| 50 DISALLOW_COPY_AND_ASSIGN(DevToolsDiscoveryManager); | 50 DISALLOW_COPY_AND_ASSIGN(DevToolsDiscoveryManager); |
| 51 }; | 51 }; |
| 52 | 52 |
| 53 } // namespace devtools_discovery | 53 } // namespace devtools_discovery |
| 54 | 54 |
| 55 #endif // COMPONENTS_DEVTOOLS_DISCOVERY_DEVTOOLS_DISCOVERY_MANAGER_H_ | 55 #endif // COMPONENTS_DEVTOOLS_DISCOVERY_DEVTOOLS_DISCOVERY_MANAGER_H_ |
| OLD | NEW |