CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Member Functions | Private Attributes
CollectionCountEventSelector< C, S, N, CS > Class Template Reference

#include <CollectionCountEventSelector.h>

Inheritance diagram for CollectionCountEventSelector< C, S, N, CS >:
EventSelectorBase

Public Member Functions

 CollectionCountEventSelector (const edm::ParameterSet &cfg, edm::ConsumesCollector &&iC)
 constructor More...
 
bool operator() (edm::Event &evt, const edm::EventSetup &) const override
 
- Public Member Functions inherited from EventSelectorBase
 EventSelectorBase ()
 
virtual ~EventSelectorBase ()
 

Static Public Member Functions

static void fillPSetDescription (edm::ParameterSetDescription &desc)
 

Private Attributes

S select_
 object filter More...
 
N sizeSelect_
 minimum number of entries in a collection More...
 
edm::EDGetTokenT< C > srcToken_
 source collection label More...
 

Detailed Description

template<typename C, typename S = AnySelector, typename N = MinNumberSelector, typename CS = typename helper::CollectionInCollectionFilterTrait<C, S, N>::type>
class CollectionCountEventSelector< C, S, N, CS >

Selects an event if a collection has at least N entries

Author
Luca Lista, INFN
Version
Revision
1.2
Id
CollectionCountEventSelector.h,v 1.2 2010/02/20 20:55:24 wmtan Exp

Definition at line 29 of file CollectionCountEventSelector.h.

Constructor & Destructor Documentation

◆ CollectionCountEventSelector()

template<typename C , typename S = AnySelector, typename N = MinNumberSelector, typename CS = typename helper::CollectionInCollectionFilterTrait<C, S, N>::type>
CollectionCountEventSelector< C, S, N, CS >::CollectionCountEventSelector ( const edm::ParameterSet cfg,
edm::ConsumesCollector &&  iC 
)
inlineexplicit

constructor

Definition at line 32 of file CollectionCountEventSelector.h.

33  : srcToken_(iC.consumes<C>(cfg.template getParameter<edm::InputTag>("src"))),
34  select_(reco::modules::make<S>(cfg, iC)),
35  sizeSelect_(reco::modules::make<N>(cfg, iC)) {}
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
N sizeSelect_
minimum number of entries in a collection
edm::EDGetTokenT< C > srcToken_
source collection label

Member Function Documentation

◆ fillPSetDescription()

template<typename C , typename S = AnySelector, typename N = MinNumberSelector, typename CS = typename helper::CollectionInCollectionFilterTrait<C, S, N>::type>
static void CollectionCountEventSelector< C, S, N, CS >::fillPSetDescription ( edm::ParameterSetDescription desc)
inlinestatic

Definition at line 37 of file CollectionCountEventSelector.h.

References submitPVResolutionJobs::desc, and ProducerED_cfi::InputTag.

37  {
38  desc.add<edm::InputTag>("src", edm::InputTag());
39  reco::modules::fillPSetDescription<S>(desc);
40  reco::modules::fillPSetDescription<N>(desc);
41  }

◆ operator()()

template<typename C , typename S = AnySelector, typename N = MinNumberSelector, typename CS = typename helper::CollectionInCollectionFilterTrait<C, S, N>::type>
bool CollectionCountEventSelector< C, S, N, CS >::operator() ( edm::Event evt,
const edm::EventSetup  
) const
inlineoverridevirtual

Member Data Documentation

◆ select_

template<typename C , typename S = AnySelector, typename N = MinNumberSelector, typename CS = typename helper::CollectionInCollectionFilterTrait<C, S, N>::type>
S CollectionCountEventSelector< C, S, N, CS >::select_
private

object filter

Definition at line 54 of file CollectionCountEventSelector.h.

Referenced by CollectionCountEventSelector< C, S, N, CS >::operator()().

◆ sizeSelect_

template<typename C , typename S = AnySelector, typename N = MinNumberSelector, typename CS = typename helper::CollectionInCollectionFilterTrait<C, S, N>::type>
N CollectionCountEventSelector< C, S, N, CS >::sizeSelect_
private

minimum number of entries in a collection

Definition at line 57 of file CollectionCountEventSelector.h.

Referenced by CollectionCountEventSelector< C, S, N, CS >::operator()().

◆ srcToken_

template<typename C , typename S = AnySelector, typename N = MinNumberSelector, typename CS = typename helper::CollectionInCollectionFilterTrait<C, S, N>::type>
edm::EDGetTokenT<C> CollectionCountEventSelector< C, S, N, CS >::srcToken_
private

source collection label

Definition at line 51 of file CollectionCountEventSelector.h.

Referenced by CollectionCountEventSelector< C, S, N, CS >::operator()().