Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(38)

Side by Side Diff: ipc/ipc_channel_mojo.h

Issue 2069803003: Fold //ipc/mojo into //ipc. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@mojo-ipc-deps
Patch Set: rebase Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ipc/ipc.mojom ('k') | ipc/ipc_channel_mojo.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 IPC_IPC_CHANNEL_MOJO_H_ 5 #ifndef IPC_IPC_CHANNEL_MOJO_H_
6 #define IPC_IPC_CHANNEL_MOJO_H_ 6 #define IPC_IPC_CHANNEL_MOJO_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
11 #include <vector> 11 #include <vector>
12 12
13 #include "base/macros.h" 13 #include "base/macros.h"
14 #include "base/memory/ref_counted.h" 14 #include "base/memory/ref_counted.h"
15 #include "base/memory/scoped_vector.h" 15 #include "base/memory/scoped_vector.h"
16 #include "base/memory/weak_ptr.h" 16 #include "base/memory/weak_ptr.h"
17 #include "base/synchronization/lock.h" 17 #include "base/synchronization/lock.h"
18 #include "base/task_runner.h" 18 #include "base/task_runner.h"
19 #include "build/build_config.h" 19 #include "build/build_config.h"
20 #include "ipc/ipc_channel.h" 20 #include "ipc/ipc_channel.h"
21 #include "ipc/ipc_channel_factory.h" 21 #include "ipc/ipc_channel_factory.h"
22 #include "ipc/ipc_export.h" 22 #include "ipc/ipc_export.h"
23 #include "ipc/mojo/ipc_message_pipe_reader.h" 23 #include "ipc/ipc_message_pipe_reader.h"
24 #include "ipc/mojo/ipc_mojo_bootstrap.h" 24 #include "ipc/ipc_mojo_bootstrap.h"
25 #include "mojo/public/cpp/system/core.h" 25 #include "mojo/public/cpp/system/core.h"
26 26
27 namespace IPC { 27 namespace IPC {
28 28
29 // Mojo-based IPC::Channel implementation over a Mojo message pipe. 29 // Mojo-based IPC::Channel implementation over a Mojo message pipe.
30 // 30 //
31 // ChannelMojo builds a Mojo MessagePipe using the provided message pipe 31 // ChannelMojo builds a Mojo MessagePipe using the provided message pipe
32 // |handle| and builds an associated interface for each direction on the 32 // |handle| and builds an associated interface for each direction on the
33 // channel. 33 // channel.
34 // 34 //
35 // TODO(morrita): Add APIs to create extra MessagePipes to let 35 // TODO(morrita): Add APIs to create extra MessagePipes to let
36 // Mojo-based objects talk over this Channel. 36 // Mojo-based objects talk over this Channel.
37 // 37 //
38 class IPC_MOJO_EXPORT ChannelMojo 38 class IPC_EXPORT ChannelMojo
39 : public Channel, 39 : public Channel,
40 public MojoBootstrap::Delegate, 40 public MojoBootstrap::Delegate,
41 public NON_EXPORTED_BASE(internal::MessagePipeReader::Delegate) { 41 public NON_EXPORTED_BASE(internal::MessagePipeReader::Delegate) {
42 public: 42 public:
43 // Creates a ChannelMojo. 43 // Creates a ChannelMojo.
44 static std::unique_ptr<ChannelMojo> 44 static std::unique_ptr<ChannelMojo>
45 Create(mojo::ScopedMessagePipeHandle handle, Mode mode, Listener* listener); 45 Create(mojo::ScopedMessagePipeHandle handle, Mode mode, Listener* listener);
46 46
47 // Create a factory object for ChannelMojo. 47 // Create a factory object for ChannelMojo.
48 // The factory is used to create Mojo-based ChannelProxy family. 48 // The factory is used to create Mojo-based ChannelProxy family.
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
115 bool waiting_connect_; 115 bool waiting_connect_;
116 116
117 base::WeakPtrFactory<ChannelMojo> weak_factory_; 117 base::WeakPtrFactory<ChannelMojo> weak_factory_;
118 118
119 DISALLOW_COPY_AND_ASSIGN(ChannelMojo); 119 DISALLOW_COPY_AND_ASSIGN(ChannelMojo);
120 }; 120 };
121 121
122 } // namespace IPC 122 } // namespace IPC
123 123
124 #endif // IPC_IPC_CHANNEL_MOJO_H_ 124 #endif // IPC_IPC_CHANNEL_MOJO_H_
OLDNEW
« no previous file with comments | « ipc/ipc.mojom ('k') | ipc/ipc_channel_mojo.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698