/********************************************************************************************************************* * Copyright 2013-2014 Tobii Technology AB. All rights reserved. * InteractionObject.hpp *********************************************************************************************************************/ #if !defined(__TOBII_TX_CLIENT_CPPBINDINGS_INTERACTIONOBJECT__HPP__) #define __TOBII_TX_CLIENT_CPPBINDINGS_INTERACTIONOBJECT__HPP__ /*********************************************************************************************************************/ TX_NAMESPACE_BEGIN /*********************************************************************************************************************/ template class InteractionObjectBase : public HandleWrapper { public: InteractionObjectBase(const std::shared_ptr& spContext, THandle hObject); TX_INTERACTIONOBJECTTYPE GetObjectType() const; bool TryGetProperty(std::shared_ptr* pspProperty, const std::string& propertyName) const; std::shared_ptr GetProperty(const std::string& propertyName) const; std::vector> GetProperties() const; void CopyPropertiesTo(const std::shared_ptr& spObject) const; std::string FormatAsText() const; public: template typename PropertyValueResolver::ValueType GetPropertyValue(const std::string& propertyName) const; template bool TryGetPropertyValue(TValue* pValue, const std::string& propertyName) const; }; /*********************************************************************************************************************/ class InteractionObject : public InteractionObjectBase { public: InteractionObject(const std::shared_ptr& spContext, TX_HANDLE hObject); virtual ~InteractionObject(); std::shared_ptr CreateProperty(const std::string& propertyName); public: template void SetPropertyValue(const std::string& propertyName, const TValue& value); }; /*********************************************************************************************************************/ TX_NAMESPACE_END /*********************************************************************************************************************/ #endif // !defined(__TOBII_TX_CLIENT_CPPBINDINGS_INTERACTIONOBJECT__HPP__) /*********************************************************************************************************************/