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", {})}
48 Observer::Observer(vector<string>
const& select_paths,
49 vector<string>
const& reject_paths)
50 : wantAllEvents_{
empty(select_paths) and
empty(reject_paths)}
69 bool const reject_event =
71 return select_event and not reject_event;
84 if (e.
get(empty_process_name, h)) {
std::string const & processName() const
bool get(SelectorBase const &, Handle< PROD > &result) const
Handle< TriggerResults > getTriggerResults(Event const &e) const
std::string process_name_
bool wantEvent(ScheduleID id, Event const &e) const
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.
std::pair< std::string, std::string > split_process_and_path_names(std::string path_spec)