LCIO
02.17
|
The main event interface. More...
#include <LCEvent.h>
Public Member Functions | |
virtual | ~LCEvent () |
Destructor. More... | |
virtual int | getRunNumber () const =0 |
Return the run number off this event. More... | |
virtual int | getEventNumber () const =0 |
Returns this event's number . More... | |
virtual const std::string & | getDetectorName () const =0 |
Returns the name of the detector setup used in the simulation. More... | |
virtual long64 | getTimeStamp () const =0 |
Returns the time stamp of the event. More... | |
virtual double | getWeight () const =0 |
Returns the event weight. More... | |
virtual const std::vector < std::string > * | getCollectionNames () const =0 |
Returns the names of the collections in the event. More... | |
virtual LCCollection * | getCollection (const std::string &name) const =0 |
Returns the collection for the given name. More... | |
virtual LCCollection * | takeCollection (const std::string &name) const =0 |
Returns the collection for the given name and transfers the ownership of the collection to the caller. More... | |
virtual void | addCollection (LCCollection *col, const std::string &name)=0 |
Adds a collection with the given name (has to be a valid C/C++ variable name). More... | |
virtual void | removeCollection (const std::string &name)=0 |
Removes (and deletes) the collection with name (if it exists in the event). More... | |
virtual const LCParameters & | getParameters () const =0 |
Parameters defined for this event. More... | |
virtual LCParameters & | parameters ()=0 |
Parameters defined for this event. More... | |
virtual lcrtrel::LCRTRelations & | runtime ()=0 |
Get the runtime extensions for this event. More... | |
The main event interface.
Holds named collections with elements of type LCObject ('untyped'). Users have to cast to the corresponding types.
|
inlinevirtual |
|
pure virtual |
Adds a collection with the given name (has to be a valid C/C++ variable name).
Throws an exception if the name already
exists in the event. NB: Adding collections is allowed even when the event is 'read only'.
EventException |
Implemented in IMPL::LCEventImpl.
|
pure virtual |
Returns the collection for the given name.
DataNotAvailableException |
Implemented in IMPL::LCEventImpl, and IOIMPL::LCEventLazyImpl.
Referenced by UTIL::LCTOOLS::dumpEvent(), UTIL::LCTOOLS::dumpEventDetailed(), UTIL::operator<<(), MT::LCReader::postProcessEvent(), SIO::SIOParticleHandler::restoreParentDaughterRelations(), and SIO::SIOEventHandler::write().
|
pure virtual |
Returns the names of the collections in the event.
Implemented in IMPL::LCEventImpl.
Referenced by UTIL::LCTOOLS::dumpEvent(), UTIL::LCTOOLS::dumpEventDetailed(), UTIL::operator<<(), MT::LCReader::postProcessEvent(), SIO::SIOParticleHandler::restoreParentDaughterRelations(), and SIO::SIOEventHandler::write().
|
pure virtual |
Returns the name of the detector setup used in the simulation.
Implemented in IMPL::LCEventImpl.
Referenced by UTIL::LCTOOLS::dumpEvent(), UTIL::LCTOOLS::dumpEventDetailed(), UTIL::operator<<(), and SIO::SIOEventHandler::write().
|
pure virtual |
Returns this event's number .
Implemented in IMPL::LCEventImpl.
Referenced by UTIL::LCTOOLS::dumpEvent(), UTIL::LCTOOLS::dumpEventDetailed(), UTIL::operator<<(), SIO::SIOEventHandler::write(), SIO::SIOWriter::writeEvent(), and MT::LCWriter::writeEvent().
|
pure virtual |
Parameters defined for this event.
Implemented in IMPL::LCEventImpl.
Referenced by UTIL::LCTOOLS::dumpEventDetailed(), and SIO::SIOEventHandler::write().
|
pure virtual |
Return the run number off this event.
Implemented in IMPL::LCEventImpl.
Referenced by UTIL::LCTOOLS::dumpEvent(), UTIL::LCTOOLS::dumpEventDetailed(), UTIL::operator<<(), SIO::SIOEventHandler::write(), SIO::SIOWriter::writeEvent(), and MT::LCWriter::writeEvent().
|
pure virtual |
Returns the time stamp of the event.
Timestamp is a unique 64 bit integer.
Definition: ns since January 1, 1970, 00:00:00 GMT
Implemented in IMPL::LCEventImpl.
Referenced by UTIL::LCTOOLS::dumpEventDetailed(), UTIL::operator<<(), and SIO::SIOEventHandler::write().
|
pure virtual |
Returns the event weight.
Implemented in IMPL::LCEventImpl.
Referenced by UTIL::LCTOOLS::dumpEventDetailed(), and UTIL::operator<<().
|
pure virtual |
Parameters defined for this event.
Implemented in IMPL::LCEventImpl.
|
pure virtual |
Removes (and deletes) the collection with name (if it exists in the event).
Throws an exception if the event is 'read only' as defined by the read mode in LCReader.
ReadOnlyException |
Implemented in IMPL::LCEventImpl, and IOIMPL::LCEventLazyImpl.
|
pure virtual |
Get the runtime extensions for this event.
Implemented in IMPL::LCEventImpl.
|
pure virtual |
Returns the collection for the given name and transfers the ownership of the collection to the caller.
The caller is responsible for deleting the collection after the Event is deleted. The collection is still in the event but flagged as transient after the call returns.
This is usefull when you want to keep the collection for the next events.
Use with care!
DataNotAvailableException |
Implemented in IMPL::LCEventImpl, and IOIMPL::LCEventLazyImpl.