Main Page
Namespaces
Classes
Package Documentation
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Pages
src
CommonTools
CandAlgos
plugins
LargestPtCandViewSelector.cc
Go to the documentation of this file.
1
/* \class LargestPtCandViewSelector
2
*
3
* Keep a fixed number of largest pt candidates.
4
* The input collection is read as View<Candidate>.
5
* Saves a collection of references to selected objects.
6
* Usage:
7
*
8
*
9
* module McPartonRefs = LargestPtCandViewSelector {
10
* InputTag src = myCollection
11
* uint32 maxNumber = 3
12
* }
13
*
14
* \author: Loic Quertenmont, UCL
15
*
16
*/
17
18
#include "
FWCore/Framework/interface/MakerMacros.h
"
19
#include "
CommonTools/UtilAlgos/interface/ObjectSelector.h
"
20
#include "
CommonTools/UtilAlgos/interface/SortCollectionSelector.h
"
21
#include "
CommonTools/Utils/interface/PtComparator.h
"
22
#include "
DataFormats/Candidate/interface/Candidate.h
"
23
24
typedef
ObjectSelector
<
25
SortCollectionSelector
<
26
reco::CandidateView
,
27
GreaterByPt<reco::Candidate>
28
>
29
>
LargestPtCandViewSelector
;
30
31
DEFINE_FWK_MODULE
(
LargestPtCandViewSelector
);
ObjectSelector
Definition:
ObjectSelector.h:38
SortCollectionSelector.h
DEFINE_FWK_MODULE
#define DEFINE_FWK_MODULE(type)
Definition:
MakerMacros.h:17
MakerMacros.h
PtComparator.h
Candidate.h
GreaterByPt
Definition:
PtComparator.h:26
ObjectSelector.h
LargestPtCandViewSelector
ObjectSelector< SortCollectionSelector< reco::CandidateView, GreaterByPt< reco::Candidate > > > LargestPtCandViewSelector
Definition:
LargestPtCandViewSelector.cc:29
SortCollectionSelector
Definition:
SortCollectionSelector.h:27
reco::CandidateView
edm::View< Candidate > CandidateView
view of a collection containing candidates
Definition:
CandidateFwd.h:23
Generated for CMSSW Reference Manual by
1.8.5