#include <TYYYEventSource.h>
Public Member Functions | |
TYYYEventSource () | |
TYYYEventSource (const char *name, const char *args, Int_t port) | |
TYYYEventSource (TGo4UserSourceParameter *par) | |
virtual | ~TYYYEventSource () |
virtual Int_t | Open () |
virtual Int_t | Close () |
virtual Bool_t | CheckEventClass (TClass *cl) |
virtual Bool_t | BuildEvent (TGo4EventElement *dest) |
const char * | GetArgs () const |
void | SetArgs (const char *arg) |
Int_t | GetPort () const |
void | SetPort (Int_t val) |
Private Attributes | |
Bool_t | fbIsOpen |
TString | fxArgs |
Int_t | fiPort |
std::ifstream * | fxFile |
Definition at line 23 of file TYYYEventSource.h.
TYYYEventSource::TYYYEventSource | ( | ) |
Definition at line 56 of file TYYYEventSource.cxx.
TYYYEventSource::TYYYEventSource | ( | const char * | name, | |
const char * | args, | |||
Int_t | port | |||
) |
Create source specifying values directly
Definition at line 27 of file TYYYEventSource.cxx.
References Open().
TYYYEventSource::TYYYEventSource | ( | TGo4UserSourceParameter * | par | ) |
Creat source from setup within usersource parameter object
Definition at line 39 of file TYYYEventSource.cxx.
References TGo4Log::Error(), TGo4UserSourceParameter::GetExpression(), TGo4UserSourceParameter::GetPort(), Open(), SetArgs(), and SetPort().
TYYYEventSource::~TYYYEventSource | ( | ) | [virtual] |
Definition at line 65 of file TYYYEventSource.cxx.
References Close().
Bool_t TYYYEventSource::BuildEvent | ( | TGo4EventElement * | dest | ) | [virtual] |
This methods actually fills the target event class which is passed as pointer. Uses the latest event which is referenced by fxEvent or fxBuffer. Does _not_ fetch a new event from source, therefore one source event may be used to fill several TYYYEvent classes. To get a new event call NextEvent() before this method.
Reimplemented from TGo4EventSource.
Definition at line 75 of file TYYYEventSource.cxx.
References TYYYRawEvent::fdData, fxFile, TYYYRawEvent::ReAllocate(), TGo4EventSource::SetCreateStatus(), TGo4EventSource::SetErrMess(), TGo4EventSource::SetEventStatus(), and TGo4EventElement::SetValid().
Bool_t TYYYEventSource::CheckEventClass | ( | TClass * | cl | ) | [virtual] |
This method checks if event class is suited for the source
Reimplemented from TGo4EventSource.
Definition at line 70 of file TYYYEventSource.cxx.
Int_t TYYYEventSource::Close | ( | ) | [virtual] |
Close the file or connection.
Definition at line 142 of file TYYYEventSource.cxx.
References fbIsOpen, fxFile, and TGo4Log::Info().
Referenced by ~TYYYEventSource().
const char* TYYYEventSource::GetArgs | ( | ) | const [inline] |
Definition at line 55 of file TYYYEventSource.h.
References fxArgs.
Int_t TYYYEventSource::GetPort | ( | ) | const [inline] |
Definition at line 59 of file TYYYEventSource.h.
References fiPort.
Int_t TYYYEventSource::Open | ( | ) | [virtual] |
Open the file or connection.
Definition at line 126 of file TYYYEventSource.cxx.
References fbIsOpen, fxFile, TGo4Log::Info(), TGo4EventSource::SetCreateStatus(), and TGo4EventSource::SetErrMess().
Referenced by TYYYEventSource().
void TYYYEventSource::SetArgs | ( | const char * | arg | ) | [inline] |
Definition at line 57 of file TYYYEventSource.h.
References fxArgs.
Referenced by TYYYEventSource().
void TYYYEventSource::SetPort | ( | Int_t | val | ) | [inline] |
Definition at line 61 of file TYYYEventSource.h.
References fiPort.
Referenced by TYYYEventSource().
Bool_t TYYYEventSource::fbIsOpen [private] |
Definition at line 65 of file TYYYEventSource.h.
Int_t TYYYEventSource::fiPort [private] |
Optional port number
Definition at line 71 of file TYYYEventSource.h.
TString TYYYEventSource::fxArgs [private] |
Optional argument string
Definition at line 68 of file TYYYEventSource.h.
std::ifstream* TYYYEventSource::fxFile [private] |
file that contains the data in ascii format.
Definition at line 74 of file TYYYEventSource.h.
Referenced by BuildEvent(), Close(), and Open().