ATLAS Offline Software
Loading...
Searching...
No Matches
JiveXML::EventStreamID Class Reference

For the client-server communication, each event is uniquely identified by the run number, the event number and a string determining which stream it belongs to. More...

#include <EventStream.h>

Collaboration diagram for JiveXML::EventStreamID:

Public Member Functions

 EventStreamID (unsigned long EventNumber, unsigned int RunNumber, const std::string &StreamName)
 EventStreamID (unsigned long EventNumber, unsigned int RunNumber, const char *StreamName)
 EventStreamID (const std::string &StreamName)
unsigned long EventNumber () const
unsigned int RunNumber () const
const std::string & StreamName () const
const char * StreamNameCStr () const
bool isSameEvent (const EventStreamID &id) const
bool isValid () const
bool operator== (const EventStreamID &id) const
bool operator< (const EventStreamID &id) const

Private Attributes

unsigned int m_event
unsigned int m_run
std::string m_stream

Detailed Description

For the client-server communication, each event is uniquely identified by the run number, the event number and a string determining which stream it belongs to.

Operators are defined only for the stream name, in order to check for identity of two events use isSameEvent

Definition at line 19 of file EventStream.h.

Constructor & Destructor Documentation

◆ EventStreamID() [1/3]

JiveXML::EventStreamID::EventStreamID ( unsigned long EventNumber,
unsigned int RunNumber,
const std::string & StreamName )
inline

Definition at line 24 of file EventStream.h.

24 :
26 };
unsigned int RunNumber() const
Definition EventStream.h:42
unsigned long EventNumber() const
Definition EventStream.h:41
const std::string & StreamName() const
Definition EventStream.h:43

◆ EventStreamID() [2/3]

JiveXML::EventStreamID::EventStreamID ( unsigned long EventNumber,
unsigned int RunNumber,
const char * StreamName )
inline

Definition at line 29 of file EventStream.h.

29 :
31 //Check for NULL pointer
33 };

◆ EventStreamID() [3/3]

JiveXML::EventStreamID::EventStreamID ( const std::string & StreamName)
inline

Definition at line 36 of file EventStream.h.

36 :
38 };

Member Function Documentation

◆ EventNumber()

unsigned long JiveXML::EventStreamID::EventNumber ( ) const
inline

Definition at line 41 of file EventStream.h.

41{ return m_event; };

◆ isSameEvent()

bool JiveXML::EventStreamID::isSameEvent ( const EventStreamID & id) const
inline

Definition at line 47 of file EventStream.h.

47 {
48 return (( id.StreamName() == m_stream ) &&
49 ( id.RunNumber() == m_run ) &&
50 ( id.EventNumber() == m_event ));
51 }

◆ isValid()

bool JiveXML::EventStreamID::isValid ( ) const
inline

Definition at line 55 of file EventStream.h.

55 {
56 return (( !m_stream.empty() ) && ( m_run != 0 ) && ( m_event != 0 ));
57 }

◆ operator<()

bool JiveXML::EventStreamID::operator< ( const EventStreamID & id) const
inline

Definition at line 65 of file EventStream.h.

65 {
66 return ( id.StreamName() < m_stream );
67 }

◆ operator==()

bool JiveXML::EventStreamID::operator== ( const EventStreamID & id) const
inline

Definition at line 61 of file EventStream.h.

61 {
62 return ( id.StreamName() == m_stream );
63 }

◆ RunNumber()

unsigned int JiveXML::EventStreamID::RunNumber ( ) const
inline

Definition at line 42 of file EventStream.h.

42{ return m_run; };

◆ StreamName()

const std::string & JiveXML::EventStreamID::StreamName ( ) const
inline

Definition at line 43 of file EventStream.h.

43{ return m_stream; };

◆ StreamNameCStr()

const char * JiveXML::EventStreamID::StreamNameCStr ( ) const
inline

Definition at line 44 of file EventStream.h.

44{ return m_stream.c_str(); };

Member Data Documentation

◆ m_event

unsigned int JiveXML::EventStreamID::m_event
private

Definition at line 72 of file EventStream.h.

◆ m_run

unsigned int JiveXML::EventStreamID::m_run
private

Definition at line 74 of file EventStream.h.

◆ m_stream

std::string JiveXML::EventStreamID::m_stream
private

Definition at line 76 of file EventStream.h.


The documentation for this class was generated from the following file: