| 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_DISPATCHER_H_ | 5 #ifndef MOJO_EDK_SYSTEM_DISPATCHER_H_ |
| 6 #define MOJO_EDK_SYSTEM_DISPATCHER_H_ | 6 #define MOJO_EDK_SYSTEM_DISPATCHER_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 219 | 219 |
| 220 Dispatcher(); | 220 Dispatcher(); |
| 221 virtual ~Dispatcher(); | 221 virtual ~Dispatcher(); |
| 222 | 222 |
| 223 // These are to be overridden by subclasses (if necessary). They are called | 223 // These are to be overridden by subclasses (if necessary). They are called |
| 224 // exactly once -- first |CancelAllWaitersNoLock()|, then |CloseImplNoLock()|, | 224 // exactly once -- first |CancelAllWaitersNoLock()|, then |CloseImplNoLock()|, |
| 225 // when the dispatcher is being closed. They are called under |lock_|. | 225 // when the dispatcher is being closed. They are called under |lock_|. |
| 226 virtual void CancelAllWaitersNoLock(); | 226 virtual void CancelAllWaitersNoLock(); |
| 227 virtual void CloseImplNoLock(); | 227 virtual void CloseImplNoLock(); |
| 228 virtual scoped_refptr<Dispatcher> | 228 virtual scoped_refptr<Dispatcher> |
| 229 CreateEquivalentDispatcherAndCloseImplNoLock() = 0; | 229 CreateEquivalentDispatcherAndCloseImplNoLock() = 0; |
| 230 | 230 |
| 231 // These are to be overridden by subclasses (if necessary). They are never | 231 // These are to be overridden by subclasses (if necessary). They are never |
| 232 // called after the dispatcher has been closed. They are called under |lock_|. | 232 // called after the dispatcher has been closed. They are called under |lock_|. |
| 233 // See the descriptions of the methods without the "ImplNoLock" for more | 233 // See the descriptions of the methods without the "ImplNoLock" for more |
| 234 // information. | 234 // information. |
| 235 virtual MojoResult WriteMessageImplNoLock( | 235 virtual MojoResult WriteMessageImplNoLock( |
| 236 UserPointer<const void> bytes, | 236 UserPointer<const void> bytes, |
| 237 uint32_t num_bytes, | 237 uint32_t num_bytes, |
| 238 std::vector<DispatcherTransport>* transports, | 238 std::vector<DispatcherTransport>* transports, |
| 239 MojoWriteMessageFlags flags); | 239 MojoWriteMessageFlags flags); |
| (...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 396 | 396 |
| 397 Dispatcher* dispatcher_; | 397 Dispatcher* dispatcher_; |
| 398 | 398 |
| 399 // Copy and assign allowed. | 399 // Copy and assign allowed. |
| 400 }; | 400 }; |
| 401 | 401 |
| 402 } // namespace system | 402 } // namespace system |
| 403 } // namespace mojo | 403 } // namespace mojo |
| 404 | 404 |
| 405 #endif // MOJO_EDK_SYSTEM_DISPATCHER_H_ | 405 #endif // MOJO_EDK_SYSTEM_DISPATCHER_H_ |
| OLD | NEW |