| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 module mojo.shell.test.mojom; | 5 module mojo.shell.test.mojom; |
| 6 | 6 |
| 7 import "services/shell/public/interfaces/connector.mojom"; | 7 import "services/shell/public/interfaces/connector.mojom"; |
| 8 | 8 |
| 9 interface ConnectTestService { | 9 interface ConnectTestService { |
| 10 GetTitle() => (string title); | 10 GetTitle() => (string title); |
| 11 GetInstance() => (string instance); | 11 GetInstance() => (string instance); |
| 12 }; | 12 }; |
| 13 | 13 |
| 14 interface ClassInterface { | 14 interface ClassInterface { |
| 15 Ping() => (string response); | 15 Ping() => (string response); |
| 16 }; | 16 }; |
| 17 | 17 |
| 18 // Interface implemented by a standalone (non-package) app, | 18 // Interface implemented by a standalone (non-package) app, |
| 19 // mojo:connect_test_app. | 19 // mojo:connect_test_app. |
| 20 interface StandaloneApp { | 20 interface StandaloneApp { |
| 21 // Attempts to connect to an application whose name is explicitly allowed by | 21 // Attempts to connect to an application whose name is explicitly allowed by |
| 22 // the standalone app's CapabilitySpec, but whose enclosing package is not. | 22 // the standalone app's CapabilitySpec, but whose enclosing package is not. |
| 23 // The connection should be blocked and title should be "uninitialized". | 23 // The connection should succeed anyway. |
| 24 ConnectToAllowedAppInBlockedPackage() => (string title); | 24 ConnectToAllowedAppInBlockedPackage() => (string title); |
| 25 | 25 |
| 26 // Connects to mojo:connect_test_class_app & requests ClassInterface from it. | 26 // Connects to mojo:connect_test_class_app & requests ClassInterface from it. |
| 27 // This should be permitted because mojo:connect_test_app requests class | 27 // This should be permitted because mojo:connect_test_app requests class |
| 28 // "class" from mojo:connect_test_class_app, which mojo:connect_test_class_app | 28 // "class" from mojo:connect_test_class_app, which mojo:connect_test_class_app |
| 29 // defines as including ClassInterface. | 29 // defines as including ClassInterface. |
| 30 // The response contains the response from ClassInterface::Ping() and | 30 // The response contains the response from ClassInterface::Ping() and |
| 31 // ConnectTestService::GetTitle(). | 31 // ConnectTestService::GetTitle(). |
| 32 ConnectToClassInterface() => (string class_interface_response, string title); | 32 ConnectToClassInterface() => (string class_interface_response, string title); |
| 33 }; | 33 }; |
| (...skipping 25 matching lines...) Expand all Loading... |
| 59 uint32 initialize_id; | 59 uint32 initialize_id; |
| 60 }; | 60 }; |
| 61 | 61 |
| 62 interface ExposedInterface { | 62 interface ExposedInterface { |
| 63 ConnectionAccepted(ConnectionState state); | 63 ConnectionAccepted(ConnectionState state); |
| 64 }; | 64 }; |
| 65 | 65 |
| 66 interface BlockedInterface { | 66 interface BlockedInterface { |
| 67 GetTitleBlocked() => (string blocked_title); | 67 GetTitleBlocked() => (string blocked_title); |
| 68 }; | 68 }; |
| OLD | NEW |