| Index: content/browser/mojo/mojo_child_connection.h
|
| diff --git a/content/browser/mojo/mojo_child_connection.h b/content/browser/mojo/mojo_child_connection.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..2270ce72c34d30ab948e7d82223591037f317c2d
|
| --- /dev/null
|
| +++ b/content/browser/mojo/mojo_child_connection.h
|
| @@ -0,0 +1,36 @@
|
| +// Copyright 2016 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 CONTENT_BROWSER_MOJO_MOJO_CHILD_CONNECTION_H_
|
| +#define CONTENT_BROWSER_MOJO_MOJO_CHILD_CONNECTION_H_
|
| +
|
| +#include <string>
|
| +
|
| +#include "base/process/process_handle.h"
|
| +#include "mojo/shell/public/interfaces/shell.mojom.h"
|
| +
|
| +namespace mojo {
|
| +class Connection;
|
| +}
|
| +
|
| +namespace content {
|
| +
|
| +class RenderProcessHost;
|
| +
|
| +// Establish a mojo::Connection to the child process, using a pipe created for
|
| +// that purpose. Returns a token that should be passed to the child process and
|
| +// exchanged for a pipe there. That pipe can in turn be passed to
|
| +// MojoShellConnectionImpl::BindToMessagePipe() to initialize the child's
|
| +// shell connection.
|
| +std::string MojoConnectToChild(int child_process_id,
|
| + int instance_id,
|
| + RenderProcessHost* render_process_host);
|
| +
|
| +// Returns a mojo connection to the provided render process host. This
|
| +// connection was opened when MojoConnectToChild() was called.
|
| +mojo::Connection* GetMojoConnection(RenderProcessHost* render_process_host);
|
| +
|
| +} // namespace content
|
| +
|
| +#endif // CONTENT_BROWSER_MOJO_MOJO_CHILD_CONNECTION_H_
|
|
|