#ifndef TDemo1Bank_hxx_seen #define TDemo1Bank_hxx_seen #include "IMidasBank.hxx" #define TDEMO1_BANK_TITLE "Demo1 Bank" namespace COMET { class IDemo1Bank; }; /// This class, and its companion IDemo2Bank, demonstrate how all the /// raw DAQ data is made accessible via a set of TXxxBank classes, /// where 'Xxx' is placeholder for each type of data, that all subclass a /// generic IMidasBank. /// /// People who have to write these subclasses can use these TDemo*Bank /// classes as a template for. Their duties are twofold:- /// /// 1) To provide a series of "Getters" to give access to all the data /// held in the bank. These Getters need to encapsulate any /// organisational details that could conceivably change during the /// lifetime of the experiment. /// /// 2) To provide a mapping from MIDAS bank name to this class. This is /// achieved using the REGISTER_MIDAS_BANK macro. See the /// IMidasBankProxyRegistry class. class COMET::IDemo1Bank : public COMET::IMidasBank { public: IDemo1Bank(); explicit IDemo1Bank(const ULong64_t *bank, const char* title = TDEMO1_BANK_TITLE); virtual ~IDemo1Bank(); /// Print contents to COMETLog void Print(const Option_t* opt = "") const; /// This class has a few, really trivial getters ULong64_t GetWord0() const { return *(this->GetData()+0);} ULong64_t GetWord1() const { return *(this->GetData()+1);} ULong64_t GetWord2() const { return *(this->GetData()+2);} private: }; #endif