File indexing completed on 2025-04-19 09:10:13
0001 #ifndef SHERPA_Filter_H
0002 #define SHERPA_Filter_H
0003
0004 #include "ATOOLS/Org/CXXFLAGS.H"
0005 #include "ATOOLS/Org/Exception.H"
0006 #include "ATOOLS/Phys/Blob_List.H"
0007 #include <map>
0008
0009 namespace ATOOLS {
0010 class Scoped_Settings;
0011 }
0012
0013 namespace SHERPA {
0014 struct FilterCriterion {
0015 ATOOLS::Flavour m_flav;
0016 double m_etamin, m_etamax, m_pTmin, m_pTmax;
0017 int m_Nmin, m_Nmax;
0018 };
0019
0020
0021 class Filter {
0022 private:
0023 std::map<ATOOLS::Flavour,FilterCriterion *> m_filters;
0024 std::list<ATOOLS::Particle * > m_particles;
0025 std::map<ATOOLS::Flavour, int> m_accepted;
0026 bool m_on;
0027
0028 void Add(ATOOLS::Scoped_Settings&);
0029 void Reset();
0030 void HarvestActiveParticles(ATOOLS::Blob_List * blobs);
0031 void FilterAccepted();
0032 bool Check();
0033 public:
0034 Filter();
0035 ~Filter();
0036 bool Init();
0037 static void ShowSyntax(int mode);
0038
0039 bool operator()(ATOOLS::Blob_List * blobs);
0040 };
0041 }
0042
0043 #endif