#include <FWCore/Framework/interface/GroupSelector.h>
Public Member Functions | |
GroupSelector () | |
void | initialize (GroupSelectorRules const &rules, std::vector< BranchDescription const * > const &branchDescriptions) |
bool | initialized () const |
void | print (std::ostream &os) const |
bool | selected (BranchDescription const &desc) const |
Private Attributes | |
std::vector< std::string > | groupsToSelect_ |
bool | initialized_ |
Definition at line 25 of file GroupSelector.h.
edm::GroupSelector::GroupSelector | ( | ) |
void edm::GroupSelector::initialize | ( | GroupSelectorRules const & | rules, | |
std::vector< BranchDescription const * > const & | branchDescriptions | |||
) |
Referenced by edm::RootFile::RootFile(), and edm::OutputModule::selectProducts().
bool edm::GroupSelector::initialized | ( | ) | const [inline] |
Definition at line 38 of file GroupSelector.h.
References initialized_.
Referenced by edm::OutputModule::selectProducts().
00038 {return initialized_;}
void edm::GroupSelector::print | ( | std::ostream & | os | ) | const |
Definition at line 71 of file GroupSelector.cc.
References edm::copy_all(), and groupsToSelect_.
Referenced by edm::operator<<().
00071 { 00072 os << "GroupSelector at: " 00073 << static_cast<void const*>(this) 00074 << " has " 00075 << groupsToSelect_.size() 00076 << " groups to select:\n"; 00077 copy_all(groupsToSelect_, std::ostream_iterator<std::string>(os, "\n")); 00078 }
bool edm::GroupSelector::selected | ( | BranchDescription const & | desc | ) | const |
Definition at line 59 of file GroupSelector.cc.
References edm::binary_search_all(), edm::BranchDescription::branchName(), groupsToSelect_, initialized_, and edm::errors::LogicError.
Referenced by edm::OutputModule::selected(), and edm::RootFile::selected().
00059 { 00060 if (!initialized_) { 00061 throw edm::Exception(edm::errors::LogicError) 00062 << "GroupSelector::selected() called prematurely\n" 00063 << "before the product registry has been frozen.\n"; 00064 } 00065 // We are to select this 'branch' if its name is one of the ones we 00066 // have been told to select. 00067 return binary_search_all(groupsToSelect_, desc.branchName()); 00068 }
std::vector<std::string> edm::GroupSelector::groupsToSelect_ [private] |
bool edm::GroupSelector::initialized_ [private] |