28 #include <ArmarXCore/interface/observers/ObserverInterface.h>
29 #include <ArmarXCore/interface/observers/ChannelRefBase.h>
30 #include <ArmarXCore/interface/observers/ObserverInterface.h>
35 #include <type_traits>
52 virtual public ChannelRefBase
54 template <
class BaseClass,
class VariantClass>
58 validationTimeout(4000),
67 ChannelRef(ObserverInterfacePrx observerPrx, std::string channelName);
76 VariantDataClassPtr clone(
const Ice::Current&
c = Ice::emptyCurrent)
const override;
77 std::string output(
const Ice::Current&
c = Ice::emptyCurrent)
const override;
78 VariantTypeId getType(
const Ice::Current&
c = Ice::emptyCurrent)
const override;
79 bool validate(
const Ice::Current&
c = Ice::emptyCurrent)
override;
84 const Ice::StringSeq& getDataFieldNames()
const;
85 bool hasDatafield(
const std::string& datafieldName)
const;
86 bool getInitialized();
87 void refetchChannel();
91 get(
const std::string& key)
100 return var->get<
T>();
104 typename std::enable_if_t < !std::is_base_of_v<VariantDataClass, T>,
T >
105 get(
const std::string& key)
114 return var->get<
T>();
118 const std::string& getChannelName()
const;
121 const std::string& getObserverName()
const;
122 const ObserverInterfacePrx& getObserverProxy();
138 stream << rhs->output();
143 void serialize(
const ObjectSerializerBasePtr& serializer, const ::Ice::Current& = Ice::emptyCurrent)
const override;
144 void deserialize(
const ObjectSerializerBasePtr& serializer, const ::Ice::Current& = Ice::emptyCurrent)
override;
148 void initializeDataFields(
Observer* obs =
nullptr);
151 const IceUtil::Int64 validationTimeout;
152 const int waitIntervallMs;
156 void ice_postUnmarshal()
override;
165 extern template class ::IceInternal::Handle<::armarx::ChannelRef>;