| 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 CHROME_BROWSER_NACL_HOST_NACL_BROKER_SERVICE_WIN_H_ | 5 #ifndef COMPONENTS_NACL_BROWSER_NACL_BROKER_SERVICE_WIN_H_ |
| 6 #define CHROME_BROWSER_NACL_HOST_NACL_BROKER_SERVICE_WIN_H_ | 6 #define COMPONENTS_NACL_BROWSER_NACL_BROKER_SERVICE_WIN_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| 11 #include "base/memory/singleton.h" | 11 #include "base/memory/singleton.h" |
| 12 #include "base/memory/weak_ptr.h" | 12 #include "base/memory/weak_ptr.h" |
| 13 #include "chrome/browser/nacl_host/nacl_broker_host_win.h" | 13 #include "components/nacl/browser/nacl_broker_host_win.h" |
| 14 |
| 15 namespace nacl { |
| 14 | 16 |
| 15 class NaClProcessHost; | 17 class NaClProcessHost; |
| 16 | 18 |
| 17 class NaClBrokerService { | 19 class NaClBrokerService { |
| 18 public: | 20 public: |
| 19 // Returns the NaClBrokerService singleton. | 21 // Returns the NaClBrokerService singleton. |
| 20 static NaClBrokerService* GetInstance(); | 22 static NaClBrokerService* GetInstance(); |
| 21 | 23 |
| 22 // Can be called several times, must be called before LaunchLoader. | 24 // Can be called several times, must be called before LaunchLoader. |
| 23 bool StartBroker(); | 25 bool StartBroker(); |
| (...skipping 23 matching lines...) Expand all Loading... |
| 47 typedef std::map<std::string, base::WeakPtr<NaClProcessHost> > | 49 typedef std::map<std::string, base::WeakPtr<NaClProcessHost> > |
| 48 PendingLaunchesMap; | 50 PendingLaunchesMap; |
| 49 typedef std::map<int, base::WeakPtr<NaClProcessHost> > | 51 typedef std::map<int, base::WeakPtr<NaClProcessHost> > |
| 50 PendingDebugExceptionHandlersMap; | 52 PendingDebugExceptionHandlersMap; |
| 51 | 53 |
| 52 friend struct DefaultSingletonTraits<NaClBrokerService>; | 54 friend struct DefaultSingletonTraits<NaClBrokerService>; |
| 53 | 55 |
| 54 NaClBrokerService(); | 56 NaClBrokerService(); |
| 55 ~NaClBrokerService() {} | 57 ~NaClBrokerService() {} |
| 56 | 58 |
| 57 NaClBrokerHost* GetBrokerHost(); | 59 nacl::NaClBrokerHost* GetBrokerHost(); |
| 58 | 60 |
| 59 int loaders_running_; | 61 int loaders_running_; |
| 60 PendingLaunchesMap pending_launches_; | 62 PendingLaunchesMap pending_launches_; |
| 61 PendingDebugExceptionHandlersMap pending_debuggers_; | 63 PendingDebugExceptionHandlersMap pending_debuggers_; |
| 62 | 64 |
| 63 DISALLOW_COPY_AND_ASSIGN(NaClBrokerService); | 65 DISALLOW_COPY_AND_ASSIGN(NaClBrokerService); |
| 64 }; | 66 }; |
| 65 | 67 |
| 66 #endif // CHROME_BROWSER_NACL_HOST_NACL_BROKER_SERVICE_WIN_H_ | 68 } // namespace nacl |
| 69 |
| 70 #endif // COMPONENTS_NACL_BROWSER_NACL_BROKER_SERVICE_WIN_H_ |
| OLD | NEW |