21 std::optional<ProcessAndEventSelectors>
22 make_selectors(vector<string>
const& paths,
std::string const& process_name)
29 vector<pair<string, string>> PPS(paths.size());
30 for (
size_t i = 0; i < paths.size(); ++i) {
33 return std::make_optional<ProcessAndEventSelectors>(PPS, process_name);
41 Observer::~Observer() noexcept =
default;
44 :
Observer{pset.get<vector<string>>(
"SelectEvents", {}),
45 pset.get<vector<string>>(
"RejectEvents", {}),
49 Observer::Observer(vector<string>
const& select_paths,
50 vector<string>
const& reject_paths,
52 : wantAllEvents_{
empty(select_paths) and
empty(reject_paths)}
80 bool const reject_event =
82 return select_event and not reject_event;
101 if (e.
get(empty_process_name, h)) {
std::string const & processName() const
Handle< TriggerResults > getTriggerResults(Event const &e) const
void registerProducts(ProductDescriptions &, ModuleDescription const &)
bool get(SelectorBase const &, Handle< PROD > &result) const
std::string process_name_
std::vector< BranchDescription > ProductDescriptions
bool wantEvent(ScheduleID id, Event const &e) const
void fillDescriptions(ModuleDescription const &)
fhicl::ParameterSetID selector_config_id_
std::string const & processName() const
std::optional< detail::ProcessAndEventSelectors > rejectors_
static Globals * instance()
std::optional< detail::ProcessAndEventSelectors > selectors_
decltype(auto) constexpr empty(T &&obj)
ADL-aware version of std::empty.
fhicl::ParameterSetID selectorConfig() const
std::pair< std::string, std::string > split_process_and_path_names(std::string path_spec)