#include <generic_publisher.hpp>
Classes | |
struct | ZeroTransferBuffer |
Public Member Functions | |
GenericPublisher (INode &node, MonotonicDuration tx_timeout, MonotonicDuration max_transfer_interval=TransferSender::getDefaultMaxTransferInterval()) | |
int | init () |
int | init (TransferPriority priority) |
int | publish (const DataStruct &message, TransferType transfer_type, NodeID dst_node_id, MonotonicTime blocking_deadline=MonotonicTime()) |
int | publish (const DataStruct &message, TransferType transfer_type, NodeID dst_node_id, TransferID tid, MonotonicTime blocking_deadline=MonotonicTime()) |
~GenericPublisher () | |
![]() | |
void | allowAnonymousTransfers () |
INode & | getNode () const |
TransferPriority | getPriority () const |
MonotonicDuration | getTxTimeout () const |
void | setPriority (const TransferPriority prio) |
void | setTxTimeout (MonotonicDuration tx_timeout) |
Private Types | |
typedef Select< DataStruct::MaxBitLen==0, ZeroTransferBuffer, StaticTransferBuffer< BitLenToByteLen< DataStruct::MaxBitLen >::Result > >::Result | Buffer |
Private Member Functions | |
int | checkInit () |
int | doEncode (const DataStruct &message, ITransferBuffer &buffer) const |
int | genericPublish (const DataStruct &message, TransferType transfer_type, NodeID dst_node_id, TransferID *tid, MonotonicTime blocking_deadline) |
Additional Inherited Members | |
![]() | |
static MonotonicDuration | getMaxTxTimeout () |
static MonotonicDuration | getMinTxTimeout () |
![]() | |
int | doInit (DataTypeKind dtkind, const char *dtname) |
int | genericPublish (const StaticTransferBufferImpl &buffer, TransferType transfer_type, NodeID dst_node_id, TransferID *tid, MonotonicTime blocking_deadline) |
GenericPublisherBase (INode &node, MonotonicDuration tx_timeout, MonotonicDuration max_transfer_interval) | |
TransferSender & | getTransferSender () |
const TransferSender & | getTransferSender () const |
MonotonicTime | getTxDeadline () const |
bool | isInited () const |
~GenericPublisherBase () | |
Generic publisher, suitable for messages and services. DataSpec - data type specification class DataStruct - instantiable class
Definition at line 85 of file generic_publisher.hpp.
|
private |
Definition at line 94 of file generic_publisher.hpp.
|
inline |
max_transfer_interval | Maximum expected time interval between subsequent publications. Leave default. |
Definition at line 107 of file generic_publisher.hpp.
|
inline |
Definition at line 112 of file generic_publisher.hpp.
|
private |
Definition at line 148 of file generic_publisher.hpp.
|
private |
Definition at line 159 of file generic_publisher.hpp.
|
private |
Definition at line 173 of file generic_publisher.hpp.
|
inline |
Init method can be called prior first publication, but it's not necessary because the publisher can be automatically initialized ad-hoc.
Definition at line 118 of file generic_publisher.hpp.
|
inline |
This overload allows to set the priority; otherwise it's the same.
Definition at line 126 of file generic_publisher.hpp.
|
inline |
Definition at line 132 of file generic_publisher.hpp.
|
inline |
Definition at line 138 of file generic_publisher.hpp.