OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 SHELL_APPLICATION_MANAGER_APPLICATION_LOADER_H_ | 5 #ifndef SHELL_APPLICATION_MANAGER_APPLICATION_LOADER_H_ |
6 #define SHELL_APPLICATION_MANAGER_APPLICATION_LOADER_H_ | 6 #define SHELL_APPLICATION_MANAGER_APPLICATION_LOADER_H_ |
7 | 7 |
8 #include "base/callback.h" | 8 #include "base/callback.h" |
9 #include "mojo/public/cpp/system/core.h" | 9 #include "mojo/public/cpp/system/core.h" |
10 #include "mojo/shell/public/interfaces/shell.mojom.h" | 10 #include "mojo/shell/public/interfaces/shell.mojom.h" |
11 #include "mojo/shell/public/interfaces/shell_client.mojom.h" | 11 #include "mojo/shell/public/interfaces/shell_client.mojom.h" |
12 #include "url/gurl.h" | |
13 | 12 |
14 namespace mojo { | 13 namespace mojo { |
15 | |
16 class Application; | |
17 | |
18 namespace shell { | 14 namespace shell { |
19 | 15 |
20 class ApplicationManager; | 16 // Interface to implement special loading behavior for a particular name. |
21 | |
22 // Interface to implement special application loading behavior for a particular | |
23 // URL or scheme. | |
24 class ApplicationLoader { | 17 class ApplicationLoader { |
25 public: | 18 public: |
26 virtual ~ApplicationLoader() {} | 19 virtual ~ApplicationLoader() {} |
27 | 20 |
28 virtual void Load(const GURL& url, mojom::ShellClientRequest request) = 0; | 21 virtual void Load(const std::string& name, |
29 | 22 mojom::ShellClientRequest request) = 0; |
30 protected: | |
31 ApplicationLoader() {} | |
32 }; | 23 }; |
33 | 24 |
34 } // namespace shell | 25 } // namespace shell |
35 } // namespace mojo | 26 } // namespace mojo |
36 | 27 |
37 #endif // SHELL_APPLICATION_MANAGER_APPLICATION_LOADER_H_ | 28 #endif // SHELL_APPLICATION_MANAGER_APPLICATION_LOADER_H_ |
OLD | NEW |