#include <DaqFormatSelector.h>
Inheritance diagram for DybDaq::DaqFormatSelector:
Public Types | |
SUCCESS | |
NO_INTERFACE | |
VERSMISMATCH | |
LAST_ERROR | |
enum | Status |
SUCCESS | |
NO_INTERFACE | |
VERSMISMATCH | |
LAST_ERROR | |
enum | Status |
Public Member Functions | |
DaqFormatSelector (const std::string &name, ISvcLocator *svc) | |
Creates an instace of this class. | |
~DaqFormatSelector () | |
Destroys the instance of this class. | |
virtual StatusCode | createContext (Context *&context) const |
virtual StatusCode | next (Context &context) const |
virtual StatusCode | next (Context &context, int jump) const |
virtual StatusCode | createAddress (const Context &context, IOpaqueAddress *&iop) const |
virtual StatusCode | releaseContext (Context *&context) const |
virtual StatusCode | queryInterface (const InterfaceID &id, void **interface) |
virtual StatusCode | previous (Context &context) const |
virtual StatusCode | previous (Context &context, int jump) const |
virtual StatusCode | last (Context &context) const |
virtual StatusCode | rewind (Context &context) const |
virtual StatusCode | resetCriteria (const std::string &criteria, Context &context) const |
virtual unsigned long | addRef () |
virtual unsigned long | release () |
virtual const std::string & | name () const |
virtual const InterfaceID & | type () const |
virtual StatusCode | configure () |
virtual StatusCode | initialize () |
virtual StatusCode | start () |
virtual StatusCode | stop () |
virtual StatusCode | finalize () |
virtual StatusCode | terminate () |
virtual Gaudi::StateMachine::State | FSMState () const |
virtual Gaudi::StateMachine::State | targetFSMState () const |
virtual StatusCode | reinitialize () |
virtual StatusCode | restart () |
virtual StatusCode | sysInitialize () |
virtual StatusCode | sysStart () |
virtual StatusCode | sysStop () |
virtual StatusCode | sysFinalize () |
virtual StatusCode | sysReinitialize () |
virtual StatusCode | sysRestart () |
virtual StatusCode | setProperty (const Property &p) |
virtual StatusCode | setProperty (const std::string &s) |
virtual StatusCode | setProperty (const std::string &n, const std::string &v) |
StatusCode | setProperty (const std::string &name, const TYPE &value) |
virtual StatusCode | getProperty (Property *p) const |
virtual const Property & | getProperty (const std::string &name) const |
virtual StatusCode | getProperty (const std::string &n, std::string &v) const |
virtual const std::vector< Property * > & | getProperties () const |
ISvcLocator * | serviceLocator () const |
IMessageSvc * | msgSvc () |
IMessageSvc * | msgSvc () const |
IMessageSvc * | messageService () |
IMessageSvc * | messageService () const |
StatusCode | setProperties () |
StatusCode | service (const std::string &name, T *&psvc, bool createIf=true) const |
StatusCode | service (const std::string &svcType, const std::string &svcName, T *&psvc) const |
Property * | declareProperty (const std::string &name, T &property, const std::string &doc="none") const |
Property * | declareRemoteProperty (const std::string &name, IProperty *rsvc, const std::string &rname="") const |
IAuditorSvc * | auditorSvc () const |
virtual StatusCode | createContext (Context *&c) const =0 |
virtual StatusCode | next (Context &c) const =0 |
virtual StatusCode | next (Context &c, int jump) const =0 |
virtual StatusCode | previous (Context &c) const =0 |
virtual StatusCode | previous (Context &c, int jump) const =0 |
virtual StatusCode | last (Context &refContext) const =0 |
virtual StatusCode | rewind (Context &c) const =0 |
virtual StatusCode | createAddress (const Context &c, IOpaqueAddress *&iop) const =0 |
virtual StatusCode | releaseContext (Context *&) const =0 |
virtual StatusCode | resetCriteria (const std::string &cr, Context &c) const =0 |
virtual unsigned long | addRef ()=0 |
virtual unsigned long | release ()=0 |
Static Public Member Functions | |
static const InterfaceID & | interfaceID () |
static const InterfaceID & | interfaceID () |
static const InterfaceID & | interfaceID () |
static const InterfaceID & | interfaceID () |
Public Attributes | |
SUCCESS | |
NO_INTERFACE | |
VERSMISMATCH | |
LAST_ERROR | |
Protected Member Functions | |
int | outputLevel () const |
Protected Attributes | |
IntegerProperty | m_outputLevel |
Gaudi::StateMachine::State | m_state |
Gaudi::StateMachine::State | m_targetState |
IMessageSvc * | m_messageSvc |
Private Member Functions | |
DaqFormatSelector () | |
Suppress default. | |
DaqFormatSelector (const DaqFormatSelector &rhs) | |
Suppress default. | |
DaqFormatSelector & | operator= (const DaqFormatSelector &rhs) |
Suppress default. | |
Private Attributes | |
std::vector< std::string > * | m_inputFiles |
List of input files. | |
int | m_samplingInterval |
The sampling interval for runnihng spare analysis. | |
unsigned int | m_actionOnInvalid |
The flag defining what action to take when an invalid event is found. | |
Friends | |
friend class | ServiceManager |
Definition at line 19 of file DaqFormatSelector.h.
DaqFormatSelector::DaqFormatSelector | ( | const std::string & | name, | |
ISvcLocator * | svc | |||
) |
Creates an instace of this class.
Definition at line 22 of file DaqFormatSelector.cc.
00023 : 00024 Service(name, 00025 svc), 00026 m_inputFiles(new vector<string>()) { 00027 declareProperty("InputFiles", 00028 *m_inputFiles, 00029 "List of input data files"); 00030 declareProperty("SamplingInterval", 00031 m_samplingInterval = 1, 00032 "The sampling interval for runnihng spare analysis"); 00033 declareProperty("ActionOnInvalid", 00034 m_actionOnInvalid = DaqFormatContext::kExitOnInvalid, 00035 "The action to take when an invalid event is found"); 00036 }
DaqFormatSelector::~DaqFormatSelector | ( | ) |
Destroys the instance of this class.
Definition at line 38 of file DaqFormatSelector.cc.
00038 { 00039 if (0 != m_inputFiles) { 00040 delete m_inputFiles; 00041 } 00042 }
DybDaq::DaqFormatSelector::DaqFormatSelector | ( | ) | [private] |
Suppress default.
DybDaq::DaqFormatSelector::DaqFormatSelector | ( | const DaqFormatSelector & | rhs | ) | [private] |
Suppress default.
StatusCode DaqFormatSelector::createContext | ( | Context *& | context | ) | const [virtual] |
Definition at line 44 of file DaqFormatSelector.cc.
00044 { 00045 IDaqReadoutSvc* daqSvc = 0; 00046 StatusCode status = service("DaqReadoutSvc", 00047 "DaqReadoutSvc", 00048 daqSvc); 00049 if (status.isFailure() ) { 00050 return status; 00051 } 00052 context = new DaqFormatContext(*m_inputFiles, 00053 m_actionOnInvalid, 00054 *msgSvc(), 00055 *daqSvc); 00056 return StatusCode::SUCCESS; 00057 }
StatusCode DaqFormatSelector::next | ( | Context & | context | ) | const [virtual] |
Definition at line 59 of file DaqFormatSelector.cc.
00059 { 00060 return next(context, 00061 m_samplingInterval); 00062 }
StatusCode DaqFormatSelector::next | ( | Context & | context, | |
int | jump | |||
) | const [virtual] |
Definition at line 65 of file DaqFormatSelector.cc.
00066 { 00067 DaqFormatContext* ctxt = dynamic_cast<DaqFormatContext*>(&context); 00068 return ctxt->jump(jump); 00069 }
StatusCode DaqFormatSelector::createAddress | ( | const Context & | context, | |
IOpaqueAddress *& | iop | |||
) | const [virtual] |
Definition at line 72 of file DaqFormatSelector.cc.
00073 { 00074 const DaqFormatContext* ctxt = dynamic_cast<const DaqFormatContext*>(&context); 00075 StatusCode status = ctxt->isGoodEvent(); 00076 if (status.isFailure()) { 00077 return status; 00078 } 00079 iop = new StructureConverter::Address(*ctxt, 00080 StructureConverter::kEvent); 00081 return StatusCode::SUCCESS; 00082 }
StatusCode DaqFormatSelector::releaseContext | ( | Context *& | context | ) | const [virtual] |
Definition at line 85 of file DaqFormatSelector.cc.
00085 { 00086 if (0 != context) { 00087 delete context; 00088 } 00089 return StatusCode::SUCCESS; 00090 }
StatusCode DaqFormatSelector::queryInterface | ( | const InterfaceID & | id, | |
void ** | interface | |||
) | [virtual] |
Implements IEvtSelector.
Definition at line 93 of file DaqFormatSelector.cc.
00094 { 00095 if (IEvtSelector::interfaceID().versionMatch(id)) { 00096 // Good enough. Return this object 00097 *interface = dynamic_cast<IEvtSelector*>(this); 00098 addRef(); 00099 return StatusCode::SUCCESS; 00100 } 00101 // Try base class 00102 return Service::queryInterface(id, 00103 interface); 00104 }
StatusCode DaqFormatSelector::previous | ( | Context & | context | ) | const [virtual] |
Definition at line 106 of file DaqFormatSelector.cc.
00106 { 00107 return StatusCode::FAILURE; 00108 }
StatusCode DaqFormatSelector::previous | ( | Context & | context, | |
int | jump | |||
) | const [virtual] |
Definition at line 110 of file DaqFormatSelector.cc.
00111 { 00112 return StatusCode::FAILURE; 00113 }
StatusCode DaqFormatSelector::last | ( | Context & | context | ) | const [virtual] |
Definition at line 115 of file DaqFormatSelector.cc.
00115 { 00116 return StatusCode::FAILURE; 00117 }
StatusCode DaqFormatSelector::rewind | ( | Context & | context | ) | const [virtual] |
Definition at line 119 of file DaqFormatSelector.cc.
00119 { 00120 return StatusCode::FAILURE; 00121 }
StatusCode DaqFormatSelector::resetCriteria | ( | const std::string & | criteria, | |
Context & | context | |||
) | const [virtual] |
Definition at line 123 of file DaqFormatSelector.cc.
00124 { 00125 return StatusCode::FAILURE; 00126 }
DaqFormatSelector& DybDaq::DaqFormatSelector::operator= | ( | const DaqFormatSelector & | rhs | ) | [private] |
Suppress default.
std::vector<std::string>* DybDaq::DaqFormatSelector::m_inputFiles [private] |
int DybDaq::DaqFormatSelector::m_samplingInterval [private] |
The sampling interval for runnihng spare analysis.
Definition at line 93 of file DaqFormatSelector.h.
unsigned int DybDaq::DaqFormatSelector::m_actionOnInvalid [private] |
The flag defining what action to take when an invalid event is found.
Definition at line 98 of file DaqFormatSelector.h.