DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
BackendOpMonFacility.cpp
Go to the documentation of this file.
1
3
4using namespace dunedaq::opmonlib;
5
7
8 std::lock_guard<std::mutex> lk(m_mutex);
9 m_list.push_back(e);
10
11}
12
13
15
16 std::unique_lock<std::mutex> lk(m_mutex);
17 data_t ret;
18 m_list.swap(ret);
19 lk.unlock();
20
21 std::smatch values;
22 auto it = ret.begin();
23 while ( it != ret.end() ) {
24 if ( ! std::regex_match( it->measurement(), values, measurement_filter) ) {
25 it = ret.erase(it);
26 } else {
27 ++it;
28 }
29 }
30
31 return ret;
32}
void publish(entry_t &&e) const override
data_t get_entries(std::regex measurement_filter=std::regex(".*"))