ADTF
Loading...
Searching...
No Matches
signal_registry_intf.h
Go to the documentation of this file.
1
7#pragma once
8
9#include <adtf_ucom3.h>
10#include <adtf_utils.h>
11#include <adtfbase/chrono.h>
13
16#define CID_ADTF_SIGNAL_REGISTRY "signal_registry.service.adtf.cid"
17
18namespace adtf
19{
20namespace services
21{
22namespace ant
23{
24
30class ADTF3_DEPRECATED("The Signal Registry Service and its interfaces are deprecated, as it has been superseeded by the use of the Qt5 Stream Display.")
31 ISignalRegistry: public adtf::ucom::IObject
32{
33 public:
35 ADTF_IID(ISignalRegistry, "signal_registry.ant.services.adtf.iid");
36
37 protected:
39 ~ISignalRegistry() = default;
40
41 public:
43 typedef size_t tSignalID;
44
46 struct tSignalAttributes
47 {
48 tSignalID nSignalID;
49 const char* strName;
50 const char* strUnit;
51 const char* strDescription;
52 double f64MinValue;
53 double f64MaxValue;
54 };
55
57 struct tSignalValue
58 {
59 tTimeStamp nTimeStamp;
60 double f64Value;
66 const char* strTextValue;
67 };
68
72 class ISignalProvider: public ucom::ant::IObject
73 {
74 public:
76 ADTF_IID(ISignalProvider, "signal_provider.signal_registry.ant.services.adtf.iid");
77
78 protected:
80 ~ISignalProvider() = default;
81
82 public:
89 class IEnabledSignals
90 {
91 public:
97 virtual tResult EnableSignal(tSignalID nSignalID) = 0;
98
104 virtual tResult DisableSignal(tSignalID nSignalID) = 0;
105 };
106
107 public:
114 virtual tResult AddSignal(const tSignalAttributes& sSignal, IEnabledSignals* pEnableCallback = nullptr) = 0;
115
122 virtual tResult UpdateSignal(tSignalID nSignalID, const tSignalValue& sValue) = 0;
123
131 virtual tResult RemoveSignal(tSignalID nSignalID) = 0;
132 };
133
134 public:
135
142 virtual tResult CreateProvider(const char* strName, adtf::ucom::ant::iobject_ptr<ISignalProvider>& pProvider) = 0;
143};
144
145}
146
147namespace flash
148{
149
153class ADTF3_DEPRECATED("The Signal Registry Service and its interfaces are deprecated, as it has been superseeded by the use of the Qt5 Stream Display.")
154 ISignalRegistry: public ant::ISignalRegistry
155{
156 public:
158 ADTF_IID(ISignalRegistry, "signal_registry.flash.services.adtf.iid");
159
160 public:
161 struct tSignalValueNs
162 {
163 base::flash::tNanoSeconds nTimeStamp;
164 double f64Value;
170 const char* strTextValue;
171 };
172
173 class ISignalProvider: public ant::ISignalRegistry::ISignalProvider
174 {
175 public:
177 ADTF_IID(ISignalProvider, "signal_provider.signal_registry.flash.services.adtf.iid");
178
179 protected:
181 ~ISignalProvider() = default;
182
183 public:
184 using ant::ISignalRegistry::ISignalProvider::UpdateSignal;
185
192 virtual tResult UpdateSignal(tSignalID nSignalID, const tSignalValueNs& sValue) = 0;
193 };
194
195 public:
196 using ant::ISignalRegistry::CreateProvider;
203 virtual tResult CreateProvider(const char* strName, adtf::ucom::ant::iobject_ptr<ISignalProvider>& pProvider) = 0;
204
205};
206
207}
208
209using flash::ISignalRegistry;
210
211}
212
213}
#define ADTF3_DEPRECATED(_depr_message_)
Definition adtf_base_deprecated.h:27
#define ADTF_IID(_interface, _striid)
Definition adtf_iid.h:19
A_UTILS_NS::cResult tResult
For backwards compatibility and to bring latest version into scope.
Definition result.h:736
Base object pointer to realize binary compatible reference counting in interface methods.
Definition object_ptr_intf.h:112
ant::IObject IObject
Alias always bringing the latest version of ant::IObject into scope.
Definition object_intf.h:109
Namespace for all functionality provided by ADTF and its SDKs.
Definition adtf_client_connector.h:14