Alignment
CommonAlignmentProducer
plugins
AlignmentSeedSelectorModule.cc
Go to the documentation of this file.
1
2
#include "
FWCore/Framework/interface/ConsumesCollector.h
"
3
#include "
FWCore/Framework/interface/MakerMacros.h
"
4
#include "
CommonTools/UtilAlgos/interface/ObjectSelector.h
"
5
#include "
Alignment/CommonAlignmentProducer/interface/AlignmentSeedSelector.h
"
6
#include "
DataFormats/TrajectorySeed/interface/TrajectorySeedCollection.h
"
7
8
struct
SeedConfigSelector
{
9
typedef
std::vector<const TrajectorySeed *>
container
;
10
typedef
container::const_iterator
const_iterator
;
11
typedef
TrajectorySeedCollection
collection
;
12
13
SeedConfigSelector
(
const
edm::ParameterSet
&
cfg
,
edm::ConsumesCollector
&&iC) :
theSelector
(
cfg
) {}
14
15
const_iterator
begin
()
const
{
return
selected_
.begin(); }
16
const_iterator
end
()
const
{
return
selected_
.end(); }
17
size_t
size
()
const
{
return
selected_
.size(); }
18
19
void
select
(
const
edm::Handle<TrajectorySeedCollection>
c
,
const
edm::Event
&evt,
const
edm::EventSetup
&
/*dummy*/
) {
20
all_
.clear();
21
selected_
.clear();
22
for
(collection::const_iterator
i
=
c
.product()->begin(), iE =
c
.product()->end();
i
!= iE; ++
i
) {
23
all_
.push_back(&*
i
);
24
}
25
selected_
=
theSelector
.
select
(
all_
, evt);
// might add dummy...
26
}
27
28
private
:
29
container
all_
,
selected_
;
30
AlignmentSeedSelector
theSelector
;
31
};
32
33
typedef
ObjectSelector<SeedConfigSelector>
AlignmentSeedSelectorModule
;
34
35
DEFINE_FWK_MODULE
(
AlignmentSeedSelectorModule
);
ObjectSelector.h
mps_fire.i
i
Definition:
mps_fire.py:355
TrajectorySeedCollection
std::vector< TrajectorySeed > TrajectorySeedCollection
Definition:
TrajectorySeedCollection.h:6
AlignmentSeedSelectorModule
ObjectSelector< SeedConfigSelector > AlignmentSeedSelectorModule
Definition:
AlignmentSeedSelectorModule.cc:33
SeedConfigSelector::const_iterator
container::const_iterator const_iterator
Definition:
AlignmentSeedSelectorModule.cc:10
SeedConfigSelector::container
std::vector< const TrajectorySeed * > container
Definition:
AlignmentSeedSelectorModule.cc:9
edm::Handle
Definition:
AssociativeIterator.h:50
SeedConfigSelector::end
const_iterator end() const
Definition:
AlignmentSeedSelectorModule.cc:16
SeedConfigSelector::all_
container all_
Definition:
AlignmentSeedSelectorModule.cc:29
MakerMacros.h
DEFINE_FWK_MODULE
#define DEFINE_FWK_MODULE(type)
Definition:
MakerMacros.h:16
SeedConfigSelector::select
void select(const edm::Handle< TrajectorySeedCollection > c, const edm::Event &evt, const edm::EventSetup &)
Definition:
AlignmentSeedSelectorModule.cc:19
SeedConfigSelector::collection
TrajectorySeedCollection collection
Definition:
AlignmentSeedSelectorModule.cc:11
ObjectSelector
Definition:
ObjectSelector.h:39
edm::ParameterSet
Definition:
ParameterSet.h:36
AlignmentSeedSelector::select
Seeds select(const Seeds &seeds, const edm::Event &evt) const
select tracks
Definition:
AlignmentSeedSelector.cc:21
AlignmentSeedSelector
Definition:
AlignmentSeedSelector.h:12
SeedConfigSelector::size
size_t size() const
Definition:
AlignmentSeedSelectorModule.cc:17
SeedConfigSelector
Definition:
AlignmentSeedSelectorModule.cc:8
edm::EventSetup
Definition:
EventSetup.h:57
HltBtagPostValidation_cff.c
c
Definition:
HltBtagPostValidation_cff.py:31
TrajectorySeedCollection.h
looper.cfg
cfg
Definition:
looper.py:297
SeedConfigSelector::selected_
container selected_
Definition:
AlignmentSeedSelectorModule.cc:29
SeedConfigSelector::SeedConfigSelector
SeedConfigSelector(const edm::ParameterSet &cfg, edm::ConsumesCollector &&iC)
Definition:
AlignmentSeedSelectorModule.cc:13
AlignmentSeedSelector.h
SeedConfigSelector::theSelector
AlignmentSeedSelector theSelector
Definition:
AlignmentSeedSelectorModule.cc:30
ConsumesCollector.h
edm::Event
Definition:
Event.h:73
edm::ConsumesCollector
Definition:
ConsumesCollector.h:39
SeedConfigSelector::begin
const_iterator begin() const
Definition:
AlignmentSeedSelectorModule.cc:15
Generated for CMSSW Reference Manual by
1.8.16