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

Side by Side Diff: ipc/ipc_message.h

Issue 1659003003: IPC::Message -> base::Pickle (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: one more mac fix Created 4 years, 10 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_channel_proxy_unittest_messages.h ('k') | ipc/ipc_message.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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_MESSAGE_H_ 5 #ifndef IPC_IPC_MESSAGE_H_
6 #define IPC_IPC_MESSAGE_H_ 6 #define IPC_IPC_MESSAGE_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after
214 const char* range_end, 214 const char* range_end,
215 NextMessageInfo* info); 215 NextMessageInfo* info);
216 216
217 // Adds a placeholder brokerable attachment that must be replaced before the 217 // Adds a placeholder brokerable attachment that must be replaced before the
218 // message can be dispatched. 218 // message can be dispatched.
219 bool AddPlaceholderBrokerableAttachmentWithId( 219 bool AddPlaceholderBrokerableAttachmentWithId(
220 BrokerableAttachment::AttachmentId id); 220 BrokerableAttachment::AttachmentId id);
221 221
222 // WriteAttachment appends |attachment| to the end of the set. It returns 222 // WriteAttachment appends |attachment| to the end of the set. It returns
223 // false iff the set is full. 223 // false iff the set is full.
224 bool WriteAttachment(scoped_refptr<MessageAttachment> attachment); 224 bool WriteAttachment(
225 scoped_refptr<base::Pickle::Attachment> attachment) override;
225 // ReadAttachment parses an attachment given the parsing state |iter| and 226 // ReadAttachment parses an attachment given the parsing state |iter| and
226 // writes it to |*attachment|. It returns true on success. 227 // writes it to |*attachment|. It returns true on success.
227 bool ReadAttachment(base::PickleIterator* iter, 228 bool ReadAttachment(
228 scoped_refptr<MessageAttachment>* attachment) const; 229 base::PickleIterator* iter,
230 scoped_refptr<base::Pickle::Attachment>* attachment) const override;
229 // Returns true if there are any attachment in this message. 231 // Returns true if there are any attachment in this message.
230 bool HasAttachments() const; 232 bool HasAttachments() const override;
231 // Returns true if there are any MojoHandleAttachments in this message. 233 // Returns true if there are any MojoHandleAttachments in this message.
232 bool HasMojoHandles() const; 234 bool HasMojoHandles() const;
233 // Whether the message has any brokerable attachments. 235 // Whether the message has any brokerable attachments.
234 bool HasBrokerableAttachments() const; 236 bool HasBrokerableAttachments() const;
235 237
236 void set_sender_pid(base::ProcessId id) { sender_pid_ = id; } 238 void set_sender_pid(base::ProcessId id) { sender_pid_ = id; }
237 base::ProcessId get_sender_pid() const { return sender_pid_; } 239 base::ProcessId get_sender_pid() const { return sender_pid_; }
238 240
239 #ifdef IPC_MESSAGE_LOG_ENABLED 241 #ifdef IPC_MESSAGE_LOG_ENABLED
240 // Adds the outgoing time from Time::Now() at the end of the message and sets 242 // Adds the outgoing time from Time::Now() at the end of the message and sets
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
335 MSG_ROUTING_NONE = -2, 337 MSG_ROUTING_NONE = -2,
336 338
337 // indicates a general message not sent to a particular tab. 339 // indicates a general message not sent to a particular tab.
338 MSG_ROUTING_CONTROL = INT32_MAX, 340 MSG_ROUTING_CONTROL = INT32_MAX,
339 }; 341 };
340 342
341 #define IPC_REPLY_ID 0xFFFFFFF0 // Special message id for replies 343 #define IPC_REPLY_ID 0xFFFFFFF0 // Special message id for replies
342 #define IPC_LOGGING_ID 0xFFFFFFF1 // Special message id for logging 344 #define IPC_LOGGING_ID 0xFFFFFFF1 // Special message id for logging
343 345
344 #endif // IPC_IPC_MESSAGE_H_ 346 #endif // IPC_IPC_MESSAGE_H_
OLDNEW
« no previous file with comments | « ipc/ipc_channel_proxy_unittest_messages.h ('k') | ipc/ipc_message.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698