#ifndef TRunInfoBank_hxx_seen #define TRunInfoBank_hxx_seen // $Id: IRunInfoBank.hxx,v 1.5 2010/01/16 13:37:01 mcgrew Exp $ // #include #define TRUN_INFO_BANK_TITLE "Event builder information bank" namespace COMET { class IRunInfoBank; class IRawDataHeader; }; /// This is the simple Access Class for the XRUN event builder /// information bank /// /// For an introduction to this and other Access Classes please see /// \ref oaRawEvent class COMET::IRunInfoBank: public COMET::IMidasBank { static const UInt_t undefined; public: IRunInfoBank(); explicit IRunInfoBank(const ULong64_t *bank, const char* title = TRUN_INFO_BANK_TITLE); virtual ~IRunInfoBank(); /// Print contents to COMETLog void Print(const Option_t* opt = "") const; UInt_t GetTime() const { if ( this->GetSize32() > 0) return *(this->GetData32() + 0); else return undefined; } UInt_t GetRun() const { if ( this->GetSize32() > 1) return *(this->GetData32() + 1); else return undefined; } UInt_t GetSubRun() const { if ( this->GetSize32() > 2) return *(this->GetData32() + 2); else return undefined; } UInt_t GetSeqNumber() const { if ( this->GetSize32() > 3) return *(this->GetData32() + 3); else return undefined; } UInt_t GetSpillNumber() const { if ( this->GetSize32() > 4) return *(this->GetData32() + 4); else return undefined; } UInt_t GetDetectorMask() const { if ( this->GetSize32() > 5) return *(this->GetData32() + 5); else return undefined; } UInt_t GetRunType() const { if ( this->GetSize32() > 6) return *(this->GetData32() + 6); else return undefined; } virtual Bool_t IsContextSetter() const {return true;} /// Use this method to see if other getters have returned a defined value. Bool_t IsDefined(UInt_t value) const { return value != undefined; } virtual void SetContext(COMET::IRawDataHeader& header) const; }; #endif