L4Re Operating System Framework
Interface and Usage Documentation
|
Output stream for IPC marshalling. More...
#include <ipc_stream>
Public Member Functions | |
Ostream (l4_utcb_t *utcb) | |
Create an IPC output stream using the given message buffer utcb . | |
void | reset () |
Reset the stream to empty, same state as a newly created stream. | |
l4_utcb_t * | utcb () const |
Return utcb pointer. | |
Get/Put functions. | |
These functions are basically used to implement the insertion operators (<<) and should not be called directly. | |
template<typename T > | |
bool | put (T *buf, unsigned long size) |
Put an array with size elements of type T into the stream. | |
template<typename T > | |
bool | put (T const &v) |
Insert an element of type T into the stream. | |
l4_msgtag_t | tag () const |
Extract the L4 message tag from the stream. | |
l4_msgtag_t & | tag () |
Extract a reference to the L4 message tag from the stream. | |
IPC operations. | |
l4_msgtag_t | send (l4_cap_idx_t dst, long proto=0, unsigned flags=0) |
Send the message via IPC to the given receiver. | |
Output stream for IPC marshalling.
Ipc::Ostream is part of the dynamic IPC marshalling infrastructure, as well as Ipc::Istream and Ipc::Iostream.
Ipc::Ostream is an output stream supporting insertion of values into an IPC message buffer. A IPC message can be marshalled using the usual insertion operator <<, see IPC stream operators .
There exist some special wrapper classes to insert arrays (see Ipc::Buf_cp_out) and indirect strings (see Msg_out_buffer and Msg_io_buffer).
Definition at line 634 of file ipc_stream.
|
inline |
Put an array with size
elements of type T
into the stream.
buf | A pointer to the array to insert into the buffer. |
size | The number of elements in the array. |
Definition at line 671 of file ipc_stream.
Referenced by operator<<(), operator<<(), and operator<<().
|
inline |
Insert an element of type T
into the stream.
v | The element to insert. |
Definition at line 689 of file ipc_stream.
|
inline |
Send the message via IPC to the given receiver.
dst | The destination for the message. |
proto | Protocol to use. |
flags | Flags to use. |
Definition at line 970 of file ipc_stream.
References L4_IPC_NEVER, l4_ipc_send(), L4_MSGTAG_FLAGS, and tag().
|
inline |
Extract a reference to the L4 message tag from the stream.
Definition at line 724 of file ipc_stream.
|
inline |
Extract the L4 message tag from the stream.
Definition at line 717 of file ipc_stream.
Referenced by operator<<(), and send().