Pothos
0.1.0
The Pothos dataflow programming software suite
|
#include <Label.hpp>
Public Member Functions | |
Label (void) | |
Create an empty label with null data and zero index. More... | |
template<typename ValueType > | |
Label (const std::string &id, ValueType &&data, const unsigned long long index) | |
Create a label with specified data of ValueType and index. More... | |
bool | operator< (const Label &other) const |
support for sorting Labels by index More... | |
template<class Archive > | |
void | serialize (Archive &ar, const unsigned int version) |
Serialization support. More... | |
Public Attributes | |
std::string | id |
Object | data |
unsigned long long | index |
A Label decorates a stream of information with meta-data. The label's data is an Object with arbitrary contents. The label's index indentifies an element in a stream.
Pothos::Label::Label | ( | void | ) |
Create an empty label with null data and zero index.
Pothos::Label::Label | ( | const std::string & | id, |
ValueType && | data, | ||
const unsigned long long | index | ||
) |
Create a label with specified data of ValueType and index.
|
inline |
support for sorting Labels by index
void Pothos::Label::serialize | ( | Archive & | ar, |
const unsigned int | version | ||
) |
Serialization support.
std::string Pothos::Label::id |
The identifier describes the label's type, meaning, or purpose. Identifiers only have meaning in the context of the blocks that are producing and consuming them. So any given pair of blocks need to agree on a particular set of identifiers and their meanings.
unsigned long long Pothos::Label::index |
The index specifies an offset into a buffer of elements. To associate with the first element of a buffer, index should be 0. To associate with the Nth element of a buffer, index should be N-1.