knowrob  2.1.0
A Knowledge Base System for Cognition-enabled Robots
Observer.h
Go to the documentation of this file.
1 /*
2  * This file is part of KnowRob, please consult
3  * https://github.com/knowrob/knowrob for license details.
4  */
5 
6 #ifndef KNOWROB_OBSERVER_H
7 #define KNOWROB_OBSERVER_H
8 
9 #include <memory>
10 
11 namespace knowrob {
12  // Forward declaration
13  class ObserverJob;
14 
18  class Observer {
19  public:
24  explicit Observer(const std::shared_ptr<ObserverJob> &job);
25 
27 
32 
36  auto &job() const { return job_; }
37 
38  protected:
39  std::shared_ptr<ObserverJob> job_;
40  };
41 
42  using ObserverPtr = std::shared_ptr<Observer>;
43 
44 } // knowrob
45 
46 #endif //KNOWROB_OBSERVER_H
std::shared_ptr< ObserverJob > job_
Definition: Observer.h:39
auto & job() const
Definition: Observer.h:36
Observer(const std::shared_ptr< ObserverJob > &job)
std::shared_ptr< Observer > ObserverPtr
Definition: Observer.h:42