EventData¶
General description¶
Data packets of the EventData type hold a string that describes the event. Processors that operate on EventData will usually specify what events they generate on their output ports or what events they expect at their input ports.
Payload details¶
name |
type |
description |
---|---|---|
event |
string |
event string |
API¶
-
class Data : public Base::Data
Public Functions
-
Data(std::string event = DEFAULT_EVENT)
-
void Initialize(std::string event = DEFAULT_EVENT)
-
inline void Initialize(const Parameters ¶meters)
-
void ClearData() override
-
std::string event() const
-
size_t hash() const
-
size_t size() const
-
void set_event(std::string event)
-
void set_event(const Data &source)
-
void SerializeBinary(std::ostream &stream, Serialization::Format format = Serialization::Format::FULL) const override
-
void SerializeYAML(YAML::Node &node, Serialization::Format format = Serialization::Format::FULL) const override
-
void SerializeFlatBuffer(flexbuffers::Builder &fbb) override
-
void YAMLDescription(YAML::Node &node, Serialization::Format format = Serialization::Format::FULL) const override
-
Data(std::string event = DEFAULT_EVENT)
Parameters¶
name |
type |
description |
validation |
---|---|---|---|
event |
string |
default event string |
cannot be empty |
-
struct Parameters : public Base::Parameters
Public Functions
-
inline Parameters(std::string event = DEFAULT_EVENT)
Public Members
-
std::string default_event
-
inline Parameters(std::string event = DEFAULT_EVENT)
Capabilities¶
-
class Capabilities : public Base::Capabilities
Public Functions
-
inline virtual void Validate(const Parameters ¶meters) const
-
inline virtual void Validate(const Parameters ¶meters) const
Binary Serialization¶
For serialization formats FULL and COMPACT, the event string is serialized as a 128-byte long string.
YAML Serialization¶
For serialization formats FULL and COMPACT, the following YAML is emitted:
event: [event string]