| 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 MOJO_SHELL_PUBLIC_CPP_SHELL_CONNECTION_H_ | 5 #ifndef MOJO_SHELL_PUBLIC_CPP_SHELL_CONNECTION_H_ |
| 6 #define MOJO_SHELL_PUBLIC_CPP_SHELL_CONNECTION_H_ | 6 #define MOJO_SHELL_PUBLIC_CPP_SHELL_CONNECTION_H_ |
| 7 | 7 |
| 8 #include <utility> | 8 #include <utility> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 59 private: | 59 private: |
| 60 // shell::mojom::ShellClient: | 60 // shell::mojom::ShellClient: |
| 61 void Initialize(shell::mojom::ConnectorPtr connector, | 61 void Initialize(shell::mojom::ConnectorPtr connector, |
| 62 shell::mojom::IdentityPtr identity, | 62 shell::mojom::IdentityPtr identity, |
| 63 uint32_t id) override; | 63 uint32_t id) override; |
| 64 void AcceptConnection( | 64 void AcceptConnection( |
| 65 shell::mojom::IdentityPtr source, | 65 shell::mojom::IdentityPtr source, |
| 66 uint32_t source_id, | 66 uint32_t source_id, |
| 67 shell::mojom::InterfaceProviderRequest remote_interfaces, | 67 shell::mojom::InterfaceProviderRequest remote_interfaces, |
| 68 shell::mojom::InterfaceProviderPtr local_interfaces, | 68 shell::mojom::InterfaceProviderPtr local_interfaces, |
| 69 Array<String> allowed_interfaces, | 69 shell::mojom::CapabilityRequestPtr allowed_capabilities, |
| 70 const String& name) override; | 70 const String& name) override; |
| 71 | 71 |
| 72 void OnConnectionError(); | 72 void OnConnectionError(); |
| 73 | 73 |
| 74 // We track the lifetime of incoming connection registries as it more | 74 // We track the lifetime of incoming connection registries as it more |
| 75 // convenient for the client. | 75 // convenient for the client. |
| 76 ScopedVector<Connection> incoming_connections_; | 76 ScopedVector<Connection> incoming_connections_; |
| 77 mojo::ShellClient* client_; | 77 mojo::ShellClient* client_; |
| 78 Binding<shell::mojom::ShellClient> binding_; | 78 Binding<shell::mojom::ShellClient> binding_; |
| 79 scoped_ptr<Connector> connector_; | 79 scoped_ptr<Connector> connector_; |
| 80 base::WeakPtrFactory<ShellConnection> weak_factory_; | 80 base::WeakPtrFactory<ShellConnection> weak_factory_; |
| 81 | 81 |
| 82 DISALLOW_COPY_AND_ASSIGN(ShellConnection); | 82 DISALLOW_COPY_AND_ASSIGN(ShellConnection); |
| 83 }; | 83 }; |
| 84 | 84 |
| 85 } // namespace mojo | 85 } // namespace mojo |
| 86 | 86 |
| 87 #endif // MOJO_SHELL_PUBLIC_CPP_SHELL_CONNECTION_H_ | 87 #endif // MOJO_SHELL_PUBLIC_CPP_SHELL_CONNECTION_H_ |
| OLD | NEW |