OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_SYNC_SENDER_H__ | 5 #ifndef IPC_IPC_SYNC_SENDER_H__ |
6 #define IPC_IPC_SYNC_SENDER_H__ | 6 #define IPC_IPC_SYNC_SENDER_H__ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 #include <deque> | 10 #include <deque> |
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
99 } | 99 } |
100 | 100 |
101 private: | 101 private: |
102 ~SyncContext(); | 102 ~SyncContext(); |
103 // ChannelProxy methods that we override. | 103 // ChannelProxy methods that we override. |
104 | 104 |
105 // Called on the listener thread. | 105 // Called on the listener thread. |
106 virtual void Clear(); | 106 virtual void Clear(); |
107 | 107 |
108 // Called on the IPC thread. | 108 // Called on the IPC thread. |
109 virtual void OnMessageReceived(const Message& msg); | 109 virtual bool OnMessageReceived(const Message& msg); |
110 virtual void OnChannelError(); | 110 virtual void OnChannelError(); |
111 virtual void OnChannelOpened(); | 111 virtual void OnChannelOpened(); |
112 virtual void OnChannelClosed(); | 112 virtual void OnChannelClosed(); |
113 | 113 |
114 // Cancels all pending Send calls. | 114 // Cancels all pending Send calls. |
115 void CancelPendingSends(); | 115 void CancelPendingSends(); |
116 | 116 |
117 // WaitableEventWatcher::Delegate implementation. | 117 // WaitableEventWatcher::Delegate implementation. |
118 virtual void OnWaitableEventSignaled(base::WaitableEvent* arg); | 118 virtual void OnWaitableEventSignaled(base::WaitableEvent* arg); |
119 | 119 |
(...skipping 28 matching lines...) Expand all Loading... |
148 | 148 |
149 // Used to signal events between the IPC and listener threads. | 149 // Used to signal events between the IPC and listener threads. |
150 base::WaitableEventWatcher dispatch_watcher_; | 150 base::WaitableEventWatcher dispatch_watcher_; |
151 | 151 |
152 DISALLOW_COPY_AND_ASSIGN(SyncChannel); | 152 DISALLOW_COPY_AND_ASSIGN(SyncChannel); |
153 }; | 153 }; |
154 | 154 |
155 } // namespace IPC | 155 } // namespace IPC |
156 | 156 |
157 #endif // IPC_IPC_SYNC_SENDER_H__ | 157 #endif // IPC_IPC_SYNC_SENDER_H__ |
OLD | NEW |