|
gdata
|
#include <gFrameDataCollection.h>
Public Member Functions | |
| GFrameDataCollection (GFrameHeader *header, std::shared_ptr< GLogger > logger) | |
| Construct a frame data collection. | |
| ~GFrameDataCollection () | |
| Destructor. | |
| void | addIntegralPayload (std::vector< int > payload) const |
| Add one integral payload to this frame. | |
| void | addEvent (int evn) |
| Placeholder for adding event-level information into the frame. | |
| bool | shouldWriteFrame () const |
| Placeholder decision hook: should this frame be emitted/written? | |
| const GFrameHeader * | getHeader () const |
| Get the owned frame header (read-only). | |
| const std::vector< GIntegralPayload * > * | getIntegralPayload () const |
| Get the stored payload pointers (read-only). | |
| long int | getFrameID () const |
| Convenience getter for frame ID. | |
Definition at line 32 of file gFrameDataCollection.h.
|
inline |
Ownership:
header is adopted by this object and deleted in the destructor.Internal storage:
| header | Frame header pointer. Ownership is transferred to this object. |
| logger | Logger instance used for diagnostics. |
Definition at line 48 of file gFrameDataCollection.h.
|
inline |
Deletes in the following order:
Definition at line 67 of file gFrameDataCollection.h.
| void GFrameDataCollection::addEvent | ( | int | evn | ) |
Intended usage (future):
| evn | Event number. |
|
inline |
The payload is passed as a vector to support a generic "packed" interface, typically used when data come from external buffers or electronics emulators.
Expected layout (size must be exactly 5):
On success:
On failure:
| payload | Packed payload vector (must have size 5). |
Definition at line 97 of file gFrameDataCollection.h.
|
inline |
Equivalent to calling getFrameID() on the owned header.
Definition at line 171 of file gFrameDataCollection.h.
|
inline |
The returned pointer remains valid as long as this GFrameDataCollection exists. The header is owned by this object and must not be deleted by the caller.
Definition at line 148 of file gFrameDataCollection.h.
|
inline |
The returned pointers:
Definition at line 161 of file gFrameDataCollection.h.
| bool GFrameDataCollection::shouldWriteFrame | ( | ) | const |
Intended usage (future):