20 #ifndef HIPORECORDBUILDER_H
21 #define HIPORECORDBUILDER_H
48 const int defaultNumberOfEvents = 100000;
49 const int defaultRecordSize = 8*1024*1024;
51 std::vector<char> bufferIndex;
52 std::vector<char> bufferEvents;
53 std::vector<char> bufferData;
54 std::vector<char> bufferRecord;
56 int bufferIndexEntries;
57 int bufferEventsPosition;
58 long bufferUserWordOne = 0;
59 long bufferUserWordTwo = 0;
61 int compressRecord(
int src_size);
62 int getRecordLengthRounding(
int bufferSize);
86 bool addEvent(std::vector<char> &vec,
int start,
int length);
Represents a HIPO event, a container for multiple structures/banks.
Builds HIPO records by accumulating events and compressing them.
void build()
Compresses accumulated events and builds the final record.
void setUserWordOne(long userWordOne)
Sets the first user-defined word in the record header.
virtual ~recordbuilder()
Virtual destructor.
std::vector< char > & getRecordBuffer()
Returns a reference to the internal record buffer.
int getRecordSize()
Returns the total size of the built record in bytes.
recordbuilder()
Default constructor with default capacity.
void reset()
Resets the builder, clearing all accumulated events.
long getUserWordTwo()
Returns the second user-defined word stored in the record header.
void setUserWordTwo(long userWordTwo)
Sets the second user-defined word in the record header.
long getUserWordOne()
Returns the first user-defined word stored in the record header.
bool addEvent(std::vector< char > &vec, int start, int length)
Adds an event from a raw byte vector.
int getEntries()
Returns the number of events currently in the record.
HIPO event container and manipulation interface.
Utility functions and benchmark timer for HIPO library operations.