1 #ifndef IsolationAlgos_IsolationProducer_h
2 #define IsolationAlgos_IsolationProducer_h
23 template<
typename Alg>
24 struct NullIsolationAlgorithmSetup {
28 template<
typename Alg>
29 struct IsolationAlgorithmSetup {
35 namespace modulesNew {
37 template <
typename C1,
typename C2,
typename Alg,
51 template <
typename C1,
typename C2,
typename Alg,
typename OutputCollection,
typename Setup>
53 src_( cfg.
template getParameter<edm::InputTag>(
"src" ) ),
54 elements_( cfg.
template getParameter<edm::InputTag>(
"elements" ) ),
55 alg_(
reco::modules::
make<Alg>( cfg ) ) {
56 produces<OutputCollection>();
59 template <
typename C1,
typename C2,
typename Alg,
typename OutputCollection,
typename Setup>
63 template <
typename C1,
typename C2,
typename Alg,
typename OutputCollection,
typename Setup>
77 typename OutputCollection::Filler filler(*isolations);
78 vector<double> iso(master.
size(),-1);
80 for(
typename C1::const_iterator lep =
src->begin(); lep !=
src->end(); ++ lep )
82 filler.insert(master.
get(), iso.begin(), iso.end());
85 evt.
put( isolations );
const edm::Handle< C1 > & get() const
Master< F > master(const F &f)
std::vector< ProtoJet > OutputCollection
static void init(Alg &, const edm::EventSetup &)
S make(const edm::ParameterSet &cfg)
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
size_t index(size_t i) const
void produce(edm::Event &, const edm::EventSetup &)
IsolationProducer(const edm::ParameterSet &)
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
NullIsolationAlgorithmSetup< Alg > type