Samchon Framework for CPP  1.0.0
MonitorBase.hpp
1 #pragma once
2 
3 #include <memory>
4 #include <samchon/HashMap.hpp>
5 
6 namespace samchon
7 {
8 namespace examples
9 {
10 namespace interaction
11 {
12  class Monitor;
13 
14  class Reporter;
15  class System;
16 
17 namespace base
18 {
19  class MonitorBase
20  {
21  friend class Monitor;
22 
23  private:
24  HashMap<int, System*> system_map;
25  std::unique_ptr<Reporter> reporter;
26 
27  public:
28  virtual void constructSystemTree() = 0;
29 
30  auto getReporter() const -> Reporter*
31  {
32  return reporter.get();
33  };
34 
35  auto getSystems() -> HashMap<int, System*>& { return system_map; };
36  auto getSystems() const -> const HashMap<int, System*>& { return system_map; };
37 
38  virtual auto getRootSystem() const -> System* = 0;
39  };
40 };
41 };
42 };
43 };