29 template <
class T,
typename C = std::vector<
typename T::ConstituentTypeFwdPtr>>
40 produces<JetsOutput>();
41 produces<ConstituentsOutput>(
"constituents");
47 desc.
add<
edm::InputTag>(
"src")->setComment(
"InputTag used for retrieving jets in event.");
48 desc.
add<
std::string>(
"cut")->setComment(
"Cut used by which to select jets. For example:\n" 49 " \"pt > 100.0 && abs(rapidity()) < 2.4\".");
60 auto jets = std::make_unique<JetsOutput>();
61 auto candsOut = std::make_unique<ConstituentsOutput>();
67 for (
auto const&
jet : *h_jets) {
72 for (
unsigned int ida {}; ida <
jet.numberOfDaughters(); ++ida) {
73 candsOut->emplace_back(
jet.daughterPtr(ida),
jet.daughterPtr(ida));
T getParameter(std::string const &) const
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
StringCutObjectSelector< T > const selector_
bool getByToken(EDGetToken token, Handle< PROD > &result) const
#define DEFINE_FWK_MODULE(type)
JetConstituentSelector(edm::ParameterSet const ¶ms)
void addDefault(ParameterSetDescription const &psetDescription)
ParameterDescriptionBase * add(U const &iLabel, T const &value)
edm::EDGetTokenT< edm::View< T > > const srcToken_
void produce(edm::Event &iEvent, edm::EventSetup const &iSetup) override
std::vector< T > JetsOutput