Zao SDK for Jetson / libzao-endpoint API リファレンス 1.2.0.0 (2023-10-30)
Loading...
Searching...
No Matches
ControlInterface.hpp
1#ifndef ZAO_ENDPOINT_MONITOR_CONTROL_INTERFACE_HPP_
2#define ZAO_ENDPOINT_MONITOR_CONTROL_INTERFACE_HPP_
3
4#include <memory>
5
6namespace zao {
7namespace endpoint {
8namespace monitor {
9
10template <class T>
12
17 public:
24 virtual void Unobserve() = 0;
25
30 virtual bool IsObserving() const noexcept = 0;
31
32 virtual ~ControlCommonInterface() noexcept = default;
33};
34
40template <class T>
42 public:
54 virtual void RegisterCallback(
55 const std::shared_ptr<MonitorCallbackInterface<T>>& listener,
56 bool use_weak_ptr = false) = 0;
57
68 virtual void RegisterCallback(
69 std::unique_ptr<MonitorCallbackInterface<T>>&& listener) = 0;
70
80 virtual bool GetLatest(T& buffer) = 0;
81
82 virtual ~ControlInterface() noexcept = default;
83};
84
85} // namespace monitor
86} // namespace endpoint
87} // namespace zao
88
89#endif // ZAO_ENDPOINT_MONITOR_CONTROL_INTERFACE_HPP_
監視制御オブジェクトの共通インターフェース。
Definition ControlInterface.hpp:16
virtual bool IsObserving() const noexcept=0
監視中か否かを取得する。
virtual void Unobserve()=0
監視を停止する。
特定の監視情報に対する監視の制御を行うインターフェース
Definition ControlInterface.hpp:41
virtual void RegisterCallback(std::unique_ptr< MonitorCallbackInterface< T > > &&listener)=0
コールバックの送信先をunique_ptrで登録する
virtual bool GetLatest(T &buffer)=0
最後に受信した情報を取得する。
virtual void RegisterCallback(const std::shared_ptr< MonitorCallbackInterface< T > > &listener, bool use_weak_ptr=false)=0
コールバックの送信先をshared_ptrまたはweak_ptrで登録する
特定の監視情報に対するコールバックインターフェース
Definition MonitorInterface.hpp:77
Zao製品共通の名前空間
Definition FactoryInterface.hpp:11