| Index: ios/web/webui/web_ui_ios_controller_factory_registry.h | 
| diff --git a/ios/web/webui/web_ui_ios_controller_factory_registry.h b/ios/web/webui/web_ui_ios_controller_factory_registry.h | 
| new file mode 100644 | 
| index 0000000000000000000000000000000000000000..3a49249639304e391f70e181b27df42249a4b1ac | 
| --- /dev/null | 
| +++ b/ios/web/webui/web_ui_ios_controller_factory_registry.h | 
| @@ -0,0 +1,36 @@ | 
| +// Copyright 2014 The Chromium Authors. All rights reserved. | 
| +// Use of this source code is governed by a BSD-style license that can be | 
| +// found in the LICENSE file. | 
| + | 
| +#ifndef IOS_WEB_WEBUI_WEB_UI_IOS_CONTROLLER_FACTORY_REGISTRY_H_ | 
| +#define IOS_WEB_WEBUI_WEB_UI_IOS_CONTROLLER_FACTORY_REGISTRY_H_ | 
| + | 
| +#include "base/memory/singleton.h" | 
| +#include "ios/public/provider/web/web_ui_ios_controller_factory.h" | 
| + | 
| +namespace web { | 
| + | 
| +// A singleton which holds on to all the registered WebUIIOSControllerFactory | 
| +// instances. | 
| +class WebUIIOSControllerFactoryRegistry : public WebUIIOSControllerFactory { | 
| + public: | 
| +  static WebUIIOSControllerFactoryRegistry* GetInstance(); | 
| + | 
| +  // WebUIIOSControllerFactory implementation. Each method loops through the | 
| +  // same method on all the factories. | 
| +  WebUIIOSController* CreateWebUIIOSControllerForURL( | 
| +      WebUIIOS* web_ui, | 
| +      const GURL& url) const override; | 
| + | 
| + private: | 
| +  friend struct DefaultSingletonTraits<WebUIIOSControllerFactoryRegistry>; | 
| + | 
| +  WebUIIOSControllerFactoryRegistry(); | 
| +  ~WebUIIOSControllerFactoryRegistry() override; | 
| + | 
| +  DISALLOW_COPY_AND_ASSIGN(WebUIIOSControllerFactoryRegistry); | 
| +}; | 
| + | 
| +}  // namespace web | 
| + | 
| +#endif  // IOS_WEB_WEBUI_WEB_UI_IOS_CONTROLLER_FACTORY_REGISTRY_H_ | 
|  |