14 ISvcLocator* pSvcLocator) :
34 return StatusCode::SUCCESS;
40 return StatusCode::SUCCESS;
51 sc =
evtStore()->retrieve(theEventInfo,
"TBEventInfo");
52 if (
sc.isFailure() ) {
54 (
"Cannot retrieve TBEventInfo from StoreGate" );
55 setFilterPassed(
false);
56 return StatusCode::SUCCESS;
67 float xFile, yFile, eFile;
104 setFilterPassed(
true);
105 return StatusCode::SUCCESS;
113 std::ifstream xyFile;
116 xyFile.open(filename.c_str());
117 if (!xyFile.is_open()) {
119 return StatusCode::FAILURE;
123 while ( getline(xyFile, line,
'\n') ) {
125 std::istringstream buf(line);
127 buf >>
run >>
x >>
y >> e;
129 if (
run ==
m_nRun && xyFile.good())
return StatusCode::SUCCESS;
132 return StatusCode::FAILURE;
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_WARNING(x)
Define macros for attributes used to control the static checker.
#define ATLAS_THREAD_SAFE
AthAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor with parameters:
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
ServiceHandle< StoreGateSvc > & evtStore()
static std::string find_file(const std::string &logical_file_name, const std::string &search_path)
float getBeamMomentum() const
float getCryoAngle() const
const std::string & getBeamParticle() const
int getEventClock() const
unsigned int getRunNum() const
virtual StatusCode finalize() override
StatusCode getXcryoYtable(float &x, float &y, float &eBeam)
Get Xcryo and Ytable from a text file.
int m_nEventRandomTrigger
virtual StatusCode execute() override
TBXCryYTableRead(const std::string &name, ISvcLocator *pSvcLocator)
virtual StatusCode initialize() override
virtual ~TBXCryYTableRead()
float m_xCryo
Beam momentum.
float m_beamMom
Run number.
TBEventInfo * m_eventinfo
std::string m_txtFileWithXY
TableY.