11 #ifndef EVIO_6_0_EVIOEVENT_H
12 #define EVIO_6_0_EVIOEVENT_H
60 std::shared_ptr<EvioEvent> pNode(
new EvioEvent());
69 static std::shared_ptr<EvioEvent>
getInstance(std::shared_ptr<BankHeader>
const & head) {
70 std::shared_ptr<EvioEvent> pNode(
new EvioEvent(head));
82 std::shared_ptr<BankHeader> head(
new BankHeader(tag, typ, num));
83 std::shared_ptr<EvioEvent> pNode(
new EvioEvent(head));
93 size_t eventNumber = 0;
96 std::string dictionaryXML{
""};
142 std::stringstream ss;
153 ss <<
"<Event> has " << dtype.
toString() <<
"s: tag=" <<
header->getTag();
154 ss << std::hex <<
"(" <<
header->getTag() <<
")" << std::dec;
157 ss <<
" num=" << (int)(
header->getNumber()) << std::hex <<
"(" << (
int)(
header->getNumber()) <<
")" << std::dec;
161 ss <<
" dataLen=" << ((
header->getLength() - (
header->getHeaderLength() - 1))/4);
164 ss <<
" dataLen=" << (
rawBytes.size()/4);
167 if (
header->getPadding() != 0) {
168 ss <<
" pad=" << (int)(
header->getPadding());
173 if (numChildren > 0) {
174 ss <<
" children=" << numChildren;
199 #endif //EVIO_6_0_EVIOEVENT_H
std::vector< std::shared_ptr< BaseStructure > > children
Array of children, may be null if this node has no children.
Definition: BaseStructure.h:410
EvioBank()
Constructor.
Definition: EvioBank.h:42
static const StructureType STRUCT_BANK
Bank.
Definition: StructureType.h:41
size_t getEventNumber() const
This returns a number [1..] indicating which event this was in the event file from which it was read...
Definition: EvioEvent.h:186
std::string toString() const
Return a string which is usually the same as the name of the enumerated value, except in the cases of...
Definition: DataType.h:193
StructureType getStructureType() const override
This implements the virtual method from BaseStructure.
Definition: EvioBank.h:92
static std::shared_ptr< EvioEvent > getInstance(uint16_t tag, DataType const &typ, uint8_t num)
Method to return a shared pointer to a constructed object of this class.
Definition: EvioEvent.h:81
bool isParsed() const
Has this object been parsed or not.
Definition: EvioEvent.h:115
std::string toString() const override
Obtain a string representation of the structure.
Definition: EvioEvent.h:140
void setParsed(bool p)
Method to set if this event has been parsed or not.
Definition: EvioEvent.h:109
bool parsed
Has this been parsed yet or not?
Definition: EvioEvent.h:101
std::vector< uint8_t > rawBytes
The raw data of the structure.
Definition: BaseStructure.h:530
This holds a CODA Bank structure.
Definition: EvioBank.h:36
void setEventNumber(size_t evNum)
This sets a number [1..] indicating which event this was in the event file from which it was read...
Definition: EvioEvent.h:194
std::shared_ptr< BaseStructureHeader > header
Holds the header of the bank as a shared pointer.
Definition: BaseStructure.h:527
static std::shared_ptr< EvioEvent > getInstance(std::shared_ptr< BankHeader > const &head)
Method to return a shared pointer to a constructed object of this class.
Definition: EvioEvent.h:69
static std::shared_ptr< EvioEvent > getInstance()
Method to return a shared pointer to a constructed object of this class.
Definition: EvioEvent.h:59
Numerical values associated with evio data types.
Definition: DataType.h:32
An event is really just the outer, primary bank.
Definition: EvioEvent.h:39
bool hasDictionaryXML() const
Is there an XML dictionary associated with this event?
Definition: EvioEvent.h:122
Numerical values associated with evio structure types.
Definition: StructureType.h:34
std::string getDictionaryXML() const
Get the XML dictionary associated with this event if there is one.
Definition: EvioEvent.h:128
void setDictionaryXML(std::string &xml)
Set the XML dictionary associated with this event.
Definition: EvioEvent.h:134