PathsInfo.h
Go to the documentation of this file.
1 #ifndef art_Framework_Core_PathsInfo_h
2 #define art_Framework_Core_PathsInfo_h
3 // vim: set sw=2 expandtab :
4 
8 
9 #include <atomic>
10 #include <cstddef>
11 #include <map>
12 #include <memory>
13 #include <string>
14 
15 namespace art {
16  class PathsInfo {
17  public:
18  std::map<std::string, std::shared_ptr<Worker>>& workers();
19  std::map<std::string, std::shared_ptr<Worker>> const& workers() const;
20  void add_path(ActionTable const&,
21  ActivityRegistry const&,
22  PathContext const&,
23  std::vector<WorkerInPath>&&,
25  std::vector<Path>& paths();
26  std::vector<Path> const& paths() const;
27  std::vector<std::string> pathNames() const;
29  void reset();
30  void reset_for_event();
33  std::size_t passedEvents() const;
34  std::size_t failedEvents() const;
35  std::size_t totalEvents() const;
36 
37  private:
38  // Maps module_label to Worker.
39  std::map<std::string, std::shared_ptr<Worker>> workers_{};
40  std::vector<Path> paths_{};
42  std::atomic<std::size_t> totalEvents_{};
43  std::atomic<std::size_t> passedEvents_{};
44  };
45 } // namespace art
46 
47 #endif /* art_Framework_Core_PathsInfo_h */
48 
49 // Local Variables:
50 // mode: c++
51 // End:
void add_path(ActionTable const &, ActivityRegistry const &, PathContext const &, std::vector< WorkerInPath > &&, GlobalTaskGroup &)
Definition: PathsInfo.cc:31
HLTGlobalStatus & pathResults()
Definition: PathsInfo.cc:89
std::vector< Path > & paths()
Definition: PathsInfo.cc:51
std::atomic< std::size_t > totalEvents_
Definition: PathsInfo.h:42
std::size_t passedEvents() const
Definition: PathsInfo.cc:107
std::size_t failedEvents() const
Definition: PathsInfo.cc:113
std::map< std::string, std::shared_ptr< Worker > > & workers()
Definition: PathsInfo.cc:19
std::size_t totalEvents() const
Definition: PathsInfo.cc:119
void reset_for_event()
Definition: PathsInfo.cc:82
std::vector< Path > paths_
Definition: PathsInfo.h:40
std::atomic< std::size_t > passedEvents_
Definition: PathsInfo.h:43
void incrementPassedEventCount()
Definition: PathsInfo.cc:101
HLTGlobalStatus pathResults_
Definition: PathsInfo.h:41
std::map< std::string, std::shared_ptr< Worker > > workers_
Definition: PathsInfo.h:39
void reset()
Definition: PathsInfo.cc:74
std::vector< std::string > pathNames() const
Definition: PathsInfo.cc:63
void incrementTotalEventCount()
Definition: PathsInfo.cc:95