////////////////////////////////////////////////////////////////////////////// // // All methods with selectors derive from this // // Author: Phil G Jones // Author: Matt Mottram < m.mottram@qmul.ac.uk> -- contact person // // REVISION HISTORY: // - 26/04/2011 : P G Jones - New file // - 2014-12-06 : P G Jones - Ability to chain selectors. // // Adds the ability to select a subset of the data PMTs, with the // selection carried out by multiple PMTSelector instances. // ////////////////////////////////////////////////////////////////////////////// #ifndef __RAT_Method_SelectorMethod_hh__ #define __RAT_Method_SelectorMethod_hh__ #include #include #include namespace RAT { namespace PMTSelectors { class PMTSelector; } namespace Methods { //Note virtual inheritance. class SelectorMethod : public virtual Method { public: // Empty virtual destructor virtual ~SelectorMethod() {} // Add the given PMT selector to the list void AddPMTSelector( PMTSelectors::PMTSelector* selector ) { fSelectors.push_back( selector ); } protected: // Invoke the selectors on the fPMTData to produce the fSelectedPMTData // // vertex is the vertex to select on void SelectPMTData( const DS::FitVertex& vertex ); std::list fSelectors; // List of selectors to be applied in order std::vector fSelectedPMTData; // Selected PMTs }; } //::Method } //::RAT #endif