| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_EDK_SYSTEM_CHANNEL_H_ | 5 #ifndef MOJO_EDK_SYSTEM_CHANNEL_H_ |
| 6 #define MOJO_EDK_SYSTEM_CHANNEL_H_ | 6 #define MOJO_EDK_SYSTEM_CHANNEL_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include "base/containers/hash_tables.h" | 10 #include "base/containers/hash_tables.h" |
| (...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 132 friend class base::RefCountedThreadSafe<Channel>; | 132 friend class base::RefCountedThreadSafe<Channel>; |
| 133 ~Channel() override; | 133 ~Channel() override; |
| 134 | 134 |
| 135 // |RawChannel::Delegate| implementation (only called on the creation thread): | 135 // |RawChannel::Delegate| implementation (only called on the creation thread): |
| 136 void OnReadMessage( | 136 void OnReadMessage( |
| 137 const MessageInTransit::View& message_view, | 137 const MessageInTransit::View& message_view, |
| 138 embedder::ScopedPlatformHandleVectorPtr platform_handles) override; | 138 embedder::ScopedPlatformHandleVectorPtr platform_handles) override; |
| 139 void OnError(Error error) override; | 139 void OnError(Error error) override; |
| 140 | 140 |
| 141 // Helpers for |OnReadMessage| (only called on the creation thread): | 141 // Helpers for |OnReadMessage| (only called on the creation thread): |
| 142 void OnReadMessageForDownstream( | 142 void OnReadMessageForEndpoint( |
| 143 const MessageInTransit::View& message_view, | 143 const MessageInTransit::View& message_view, |
| 144 embedder::ScopedPlatformHandleVectorPtr platform_handles); | 144 embedder::ScopedPlatformHandleVectorPtr platform_handles); |
| 145 void OnReadMessageForChannel( | 145 void OnReadMessageForChannel( |
| 146 const MessageInTransit::View& message_view, | 146 const MessageInTransit::View& message_view, |
| 147 embedder::ScopedPlatformHandleVectorPtr platform_handles); | 147 embedder::ScopedPlatformHandleVectorPtr platform_handles); |
| 148 | 148 |
| 149 // Handles "attach and run endpoint" messages. | 149 // Handles "attach and run endpoint" messages. |
| 150 bool OnAttachAndRunEndpoint(ChannelEndpointId local_id, | 150 bool OnAttachAndRunEndpoint(ChannelEndpointId local_id, |
| 151 ChannelEndpointId remote_id); | 151 ChannelEndpointId remote_id); |
| 152 // Handles "remove message pipe endpoint" messages. | 152 // Handles "remove message pipe endpoint" messages. |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 210 // if/when we wrap). | 210 // if/when we wrap). |
| 211 RemoteChannelEndpointIdGenerator remote_id_generator_; | 211 RemoteChannelEndpointIdGenerator remote_id_generator_; |
| 212 | 212 |
| 213 DISALLOW_COPY_AND_ASSIGN(Channel); | 213 DISALLOW_COPY_AND_ASSIGN(Channel); |
| 214 }; | 214 }; |
| 215 | 215 |
| 216 } // namespace system | 216 } // namespace system |
| 217 } // namespace mojo | 217 } // namespace mojo |
| 218 | 218 |
| 219 #endif // MOJO_EDK_SYSTEM_CHANNEL_H_ | 219 #endif // MOJO_EDK_SYSTEM_CHANNEL_H_ |
| OLD | NEW |