#include "abstractsource.h"
-/*! \addtogroup ivipocbase
+/*! \addtogroup libamb
* @{
*/
/*!
* \brief AmbPlugin private class implementation - base class for all plugin implementations.
*
- * Contains common code used in all IviPoC II plugins for Automotive message broker(AMB).
- * For the AMB library API please visit <a href="https://github.com/otcshare/automotive-message-broker">Automotive message broker web page</a>.
+ * Contains common code used in plugins for Automotive message broker(AMB).
+ * For the AMB library API please visit \ref libamb.
*
* \class AmbPluginImpl
*/
*/
virtual void init();
+ /*!
+ * \brief setValue of a property
+ */
+ template <typename T>
+ void setValue(std::shared_ptr<AbstractPropertyType> property, T value)
+ {
+ if(property->value<T>() == value)
+ {
+ return;
+ }
+
+ property->setValue(value);
+ routingEngine->updateProperty(property.get(), source.uuid());
+ }
+
+
protected:
/*! Finds property type in #properties
* \param typeFactory Function to be used to create instance of the AbstractPropertyType for registered property
* \return AbstractPropertyType* if signal exits otherwise nullptr(in this case we do not know its datatype)
*/
- std::shared_ptr<AbstractPropertyType> addPropertySupport(Zone::Type zone, std::function<AbstractPropertyType* (void)> typeFactory);
+ std::shared_ptr<AbstractPropertyType> addPropertySupport(Zone::Type zone, std::function<AbstractPropertyType* (void)> typeFactory, std::string sourceUuid="");
template <class T>
std::shared_ptr<AbstractPropertyType> addPropertySupport(Zone::Type zone)