CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
PairSelector.h
Go to the documentation of this file.
1 #ifndef CommonTools_Utils_PairSelector_h
2 #define CommonTools_Utils_PairSelector_h
3 /* \class PairSelector
4  *
5  * \author Luca Lista, INFN
6  *
7  * $Id: PairSelector.h,v 1.1 2009/02/24 14:40:26 llista Exp $
8  */
9 
10 template<typename S1, typename S2>
11 struct PairSelector {
12  PairSelector(const S1 & s1, const S2 & s2) : s1_(s1), s2_(s2) { }
13  template<typename T>
14  bool operator()(const T & t) const {
15  return s1_(t.first) && s2_(t.second);
16  }
17 private:
18  S1 s1_;
19  S2 s2_;
20 };
21 
22 #endif
tuple s2
Definition: indexGen.py:106
bool operator()(const T &t) const
Definition: PairSelector.h:14
PairSelector(const S1 &s1, const S2 &s2)
Definition: PairSelector.h:12
long double T