| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 CONTENT_PUBLIC_COMMON_MOJO_SHELL_CONNECTION_H_ | 5 #ifndef CONTENT_PUBLIC_COMMON_MOJO_SHELL_CONNECTION_H_ |
| 6 #define CONTENT_PUBLIC_COMMON_MOJO_SHELL_CONNECTION_H_ | 6 #define CONTENT_PUBLIC_COMMON_MOJO_SHELL_CONNECTION_H_ |
| 7 | 7 |
| 8 #include "content/common/content_export.h" | 8 #include "content/common/content_export.h" |
| 9 | 9 |
| 10 namespace mojo { | 10 namespace mojo { |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 static MojoShellConnection* Get(); | 38 static MojoShellConnection* Get(); |
| 39 | 39 |
| 40 // Destroys the connection. Must be called on the thread the connection was | 40 // Destroys the connection. Must be called on the thread the connection was |
| 41 // created on. | 41 // created on. |
| 42 static void Destroy(); | 42 static void Destroy(); |
| 43 | 43 |
| 44 // Returns an Initialized() Shell. | 44 // Returns an Initialized() Shell. |
| 45 virtual mojo::Shell* GetShell() = 0; | 45 virtual mojo::Shell* GetShell() = 0; |
| 46 | 46 |
| 47 // [De]Register an impl of Listener that will be consulted when the wrapped | 47 // [De]Register an impl of Listener that will be consulted when the wrapped |
| 48 // ApplicationImpl exposes services to inbound connections. | 48 // ShellConnection exposes services to inbound connections. |
| 49 // Registered listeners are owned by this MojoShellConnection. | 49 // Registered listeners are owned by this MojoShellConnection. |
| 50 virtual void AddListener(Listener* listener) = 0; | 50 virtual void AddListener(Listener* listener) = 0; |
| 51 virtual void RemoveListener(Listener* listener) = 0; | 51 virtual void RemoveListener(Listener* listener) = 0; |
| 52 | 52 |
| 53 protected: | 53 protected: |
| 54 virtual ~MojoShellConnection(); | 54 virtual ~MojoShellConnection(); |
| 55 }; | 55 }; |
| 56 | 56 |
| 57 } // namespace content | 57 } // namespace content |
| 58 | 58 |
| 59 #endif // CONTENT_PUBLIC_COMMON_MOJO_SHELL_CONNECTION_H_ | 59 #endif // CONTENT_PUBLIC_COMMON_MOJO_SHELL_CONNECTION_H_ |
| OLD | NEW |