The Gaudi Framework  master (594c33fa)
Gaudi::TestSuite::Event Class Reference

#include </builds/gaudi/Gaudi/GaudiTestSuite/include/GaudiTestSuite/Event.h>

Inheritance diagram for Gaudi::TestSuite::Event:
Collaboration diagram for Gaudi::TestSuite::Event:

Public Member Functions

 Event ()
 Constructors. More...
 
const CLIDclID () const override
 Retrieve reference to class definition structure. More...
 
int event () const
 Retrieve event number. More...
 
void setEvent (int value)
 Update event number. More...
 
int run () const
 Retrieve run number. More...
 
void setRun (int value)
 Update run number. More...
 
const Gaudi::Timetime () const
 Retrieve reference to event time stamp. More...
 
void setTime (const Gaudi::Time &value)
 Update reference to event time stamp. More...
 
const SmartRefVector< Collision > & collisions () const
 Access to collisions. More...
 
void addCollision (Collision *vtx)
 Add collision. More...
 
void removeCollision (Collision *vtx)
 Remove collision. More...
 
virtual StreamBufferserialize (StreamBuffer &s) const
 Serialize the object for writing. More...
 
virtual StreamBufferserialize (StreamBuffer &s)
 Serialize the object for reading. More...
 
std::ostreamfillStream (std::ostream &s) const override
 Fill the output stream (ASCII) More...
 
- Public Member Functions inherited from DataObject
 DataObject ()
 Standard Constructor. More...
 
 DataObject (const DataObject &rhs)
 Copy Constructor. More...
 
DataObjectoperator= (const DataObject &rhs)
 Assignment Operator. More...
 
 DataObject (DataObject &&rhs)
 Move Constructor. More...
 
DataObjectoperator= (DataObject &&rhs)
 Move Assignment Operator. More...
 
virtual ~DataObject ()
 Standard Destructor. More...
 
virtual unsigned long addRef ()
 Add reference to object. More...
 
virtual unsigned long release ()
 release reference to object More...
 
const std::stringname () const
 Retreive DataObject name. It is the name when registered in the store. More...
 
virtual StatusCode update ()
 Provide empty placeholder for internal object reconfiguration callback. More...
 
void setRegistry (IRegistry *pRegistry)
 Set pointer to Registry. More...
 
IRegistryregistry () const
 Get pointer to Registry. More...
 
LinkManagerlinkMgr ()
 Retrieve Link manager. More...
 
const LinkManagerlinkMgr () const
 
unsigned char version () const
 Retrieve version number of this object representation. More...
 
void setVersion (unsigned char vsn)
 Set version number of this object representation. More...
 
unsigned long refCount () const
 Return the refcount. More...
 

Static Public Member Functions

static const CLIDclassID ()
 
- Static Public Member Functions inherited from DataObject
static const CLIDclassID ()
 Retrieve reference to class definition structure (static access) More...
 

Private Attributes

int m_event { 0 }
 Event number. More...
 
int m_run { 0 }
 Run number. More...
 
Gaudi::Time m_time
 Time stamp. More...
 
SmartRefVector< Collisionm_collisions
 Vector of collisions this object belongs to. More...
 

Detailed Description

Essential information of the event used in examples It can be identified by "/Event"

Author
Pavel Binko

Definition at line 37 of file Event.h.

Constructor & Destructor Documentation

◆ Event()

Event::Event ( )

Constructors.

Definition at line 15 of file Event.cpp.

15  : DataObject() {
16  // m_collisions(this);
17 }

Member Function Documentation

◆ addCollision()

void Gaudi::TestSuite::Event::addCollision ( Collision vtx)
inline

Add collision.

Add decay vertex.

Definition at line 123 of file Event.h.

123 { m_collisions.push_back( SmartRef<Collision>( c ) ); }

◆ classID()

static const CLID& Gaudi::TestSuite::Event::classID ( )
inlinestatic

Definition at line 45 of file Event.h.

45 { return CLID_Event; }

◆ clID()

const CLID& Gaudi::TestSuite::Event::clID ( ) const
inlineoverridevirtual

Retrieve reference to class definition structure.

Reimplemented from DataObject.

Definition at line 44 of file Event.h.

44 { return classID(); }

◆ collisions()

const SmartRefVector< Collision > & Gaudi::TestSuite::Event::collisions ( ) const
inline

Access to collisions.

Access to decay vertices.

Definition at line 120 of file Event.h.

120 { return m_collisions; }

◆ event()

int Gaudi::TestSuite::Event::event ( ) const
inline

Retrieve event number.

Definition at line 48 of file Event.h.

48 { return m_event; }

◆ fillStream()

std::ostream & Gaudi::TestSuite::Event::fillStream ( std::ostream s) const
inlineoverridevirtual

Fill the output stream (ASCII)

Reimplemented from DataObject.

Definition at line 113 of file Event.h.

113  {
114  return s << "class Event :"
115  << "\n Event number = " << std::setw( 12 ) << m_event << "\n Run number = " << std::setw( 12 )
116  << m_run << "\n Time = " << m_time;
117  }

◆ removeCollision()

void Gaudi::TestSuite::Event::removeCollision ( Collision vtx)
inline

Remove collision.

Remove decay vertex.

Definition at line 126 of file Event.h.

126  {
127  for ( auto i = m_collisions.begin(); i != m_collisions.end(); ++i ) {
128  if ( i->target() == c ) {
129  m_collisions.erase( i );
130  return;
131  }
132  }
133  }

◆ run()

int Gaudi::TestSuite::Event::run ( ) const
inline

Retrieve run number.

Definition at line 53 of file Event.h.

53 { return m_run; }

◆ serialize() [1/2]

StreamBuffer & Gaudi::TestSuite::Event::serialize ( StreamBuffer s)
inlinevirtual

Serialize the object for reading.

Definition at line 108 of file Event.h.

108  {
109  return s >> m_event >> m_run >> m_time >> m_collisions( this );
110  }

◆ serialize() [2/2]

StreamBuffer & Gaudi::TestSuite::Event::serialize ( StreamBuffer s) const
inlinevirtual

Serialize the object for writing.

Definition at line 103 of file Event.h.

103  {
104  return s << m_event << m_run << m_time << m_collisions( this );
105  }

◆ setEvent()

void Gaudi::TestSuite::Event::setEvent ( int  value)
inline

Update event number.

Definition at line 50 of file Event.h.

50 { m_event = value; }

◆ setRun()

void Gaudi::TestSuite::Event::setRun ( int  value)
inline

Update run number.

Definition at line 55 of file Event.h.

55 { m_run = value; }

◆ setTime()

void Gaudi::TestSuite::Event::setTime ( const Gaudi::Time value)
inline

Update reference to event time stamp.

Definition at line 60 of file Event.h.

60 { m_time = value; }

◆ time()

const Gaudi::Time& Gaudi::TestSuite::Event::time ( ) const
inline

Retrieve reference to event time stamp.

Definition at line 58 of file Event.h.

58 { return m_time; }

Member Data Documentation

◆ m_collisions

SmartRefVector<Collision> Gaudi::TestSuite::Event::m_collisions
private

Vector of collisions this object belongs to.

Definition at line 88 of file Event.h.

◆ m_event

int Gaudi::TestSuite::Event::m_event { 0 }
private

Event number.

Definition at line 81 of file Event.h.

◆ m_run

int Gaudi::TestSuite::Event::m_run { 0 }
private

Run number.

Definition at line 83 of file Event.h.

◆ m_time

Gaudi::Time Gaudi::TestSuite::Event::m_time
private

Time stamp.

Definition at line 85 of file Event.h.


The documentation for this class was generated from the following files:
gaudirun.s
string s
Definition: gaudirun.py:346
Gaudi::TestSuite::Event::classID
static const CLID & classID()
Definition: Event.h:45
gaudirun.c
c
Definition: gaudirun.py:525
Gaudi::TestSuite::Event::m_event
int m_event
Event number.
Definition: Event.h:81
Gaudi::TestSuite::Event::m_time
Gaudi::Time m_time
Time stamp.
Definition: Event.h:85
DataObject::DataObject
DataObject()
Standard Constructor.
Definition: DataObject.cpp:23
SmartRef
Kernel objects: SmartRef.
Definition: SmartRef.h:76
Gaudi::TestSuite::Event::m_collisions
SmartRefVector< Collision > m_collisions
Vector of collisions this object belongs to.
Definition: Event.h:88
std::setw
T setw(T... args)
Gaudi::TestSuite::Event::m_run
int m_run
Run number.
Definition: Event.h:83