diff options
Diffstat (limited to 'ipc/ipc_sync_message.h')
-rw-r--r-- | ipc/ipc_sync_message.h | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/ipc/ipc_sync_message.h b/ipc/ipc_sync_message.h index 48e9f99..ea6387a4 100644 --- a/ipc/ipc_sync_message.h +++ b/ipc/ipc_sync_message.h @@ -1,4 +1,4 @@ -// Copyright (c) 2009 The Chromium Authors. All rights reserved. +// Copyright (c) 2010 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. @@ -77,8 +77,6 @@ class SyncMessage : public Message { MessageReplyDeserializer* deserializer_; base::WaitableEvent* pump_messages_event_; - - static uint32 next_id_; // for generation of unique ids }; // Used to deserialize parameters from a reply to a synchronous message @@ -92,6 +90,19 @@ class MessageReplyDeserializer { virtual bool SerializeOutputParameters(const Message& msg, void* iter) = 0; }; +// When sending a synchronous message, this structure contains an object +// that knows how to deserialize the response. +struct PendingSyncMsg { + PendingSyncMsg(int id, + MessageReplyDeserializer* d, + base::WaitableEvent* e) + : id(id), deserializer(d), done_event(e), send_result(false) { } + int id; + MessageReplyDeserializer* deserializer; + base::WaitableEvent* done_event; + bool send_result; +}; + } // namespace IPC #endif // IPC_IPC_SYNC_MESSAGE_H_ |