class ReceiverBase
Defined at line 26 of file ../../sdk/lib/async/include/lib/async/cpp/receiver.h
Holds content for a packet receiver and its handler.
After successfully queuing packets to the receiver, the client is responsible
for retaining the structure in memory (and unmodified) until all packets have
been received by the handler or the dispatcher shuts down. There is no way
to cancel a packet which has been queued.
Multiple packets may be delivered to the same receiver concurrently.
Concrete implementations: |async::Receiver|, |async::ReceiverMethod|.
Please do not create subclasses of ReceiverBase outside of this library.
Public Methods
zx_status_t QueuePacket (async_dispatcher_t * dispatcher, const zx_packet_user_t * data)
Enqueues a packet of data for delivery to a receiver.
The |data| will be copied into the packet. May be NULL to create a
zero-initialized packet payload.
Returns |ZX_OK| if the packet was successfully enqueued.
Returns |ZX_ERR_BAD_STATE| if the dispatcher is shutting down.
Returns |ZX_ERR_NOT_SUPPORTED| if not supported by the dispatcher.
Defined at line 16 of file ../../sdk/lib/async/receiver.cc
Protected Methods
void ReceiverBase (async_receiver_handler_t * handler)
Defined at line 11 of file ../../sdk/lib/async/receiver.cc
void ~ReceiverBase ()
Defined at line 14 of file ../../sdk/lib/async/receiver.cc
void ReceiverBase (const ReceiverBase & )
Defined at line 31 of file ../../sdk/lib/async/include/lib/async/cpp/receiver.h
void ReceiverBase (ReceiverBase && )
Defined at line 32 of file ../../sdk/lib/async/include/lib/async/cpp/receiver.h
ReceiverBase & operator= (const ReceiverBase & )
Defined at line 33 of file ../../sdk/lib/async/include/lib/async/cpp/receiver.h
ReceiverBase & operator= (ReceiverBase && )
Defined at line 34 of file ../../sdk/lib/async/include/lib/async/cpp/receiver.h
template <typename T>
T * Dispatch (async_receiver_t * receiver)
Defined at line 49 of file ../../sdk/lib/async/include/lib/async/cpp/receiver.h