From be2926499af2e372c313d965533be3a7ee0dcf4d Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Mon, 16 May 2016 11:19:10 +0200 Subject: add tobii eyex sdk --- Tobii EyeX/include/eyex-cpp/HandleWrapper.inl | 61 +++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100755 Tobii EyeX/include/eyex-cpp/HandleWrapper.inl (limited to 'Tobii EyeX/include/eyex-cpp/HandleWrapper.inl') diff --git a/Tobii EyeX/include/eyex-cpp/HandleWrapper.inl b/Tobii EyeX/include/eyex-cpp/HandleWrapper.inl new file mode 100755 index 0000000..eae842e --- /dev/null +++ b/Tobii EyeX/include/eyex-cpp/HandleWrapper.inl @@ -0,0 +1,61 @@ +/********************************************************************************************************************* + * Copyright 2013-2014 Tobii Technology AB. All rights reserved. + * InteractionObject.inl + *********************************************************************************************************************/ + +#if !defined(__TOBII_TX_CLIENT_CPPBINDINGS_HANDLEWRAPPER__INL__) +#define __TOBII_TX_CLIENT_CPPBINDINGS_HANDLEWRAPPER__INL__ + +/*********************************************************************************************************************/ + +TX_NAMESPACE_BEGIN + +/*********************************************************************************************************************/ + +template +inline HandleWrapper::HandleWrapper(const std::shared_ptr& spContext, THandle hObject) +: _spContext(spContext), _hObject(hObject) +{} + +/*********************************************************************************************************************/ + +template +inline HandleWrapper::~HandleWrapper() +{ } + +/*********************************************************************************************************************/ + +template +inline std::shared_ptr HandleWrapper::GetContext() const +{ + return _spContext; +} + +/*********************************************************************************************************************/ + +template +inline THandle HandleWrapper::GetHandle() const +{ + return _hObject; +} + +/*********************************************************************************************************************/ + +template +template +inline static std::string HandleWrapper::GetString(TX_RESULT (*pFn)(THandle1, TX_STRING, TX_SIZE*), THandle2 handle, TX_SIZE estimatedLength) +{ + std::string str; + TX_VALIDATE(Tx::Utils::GetString(&str, pFn, handle, estimatedLength)); + return str; +} + +/*********************************************************************************************************************/ + +TX_NAMESPACE_END + +/*********************************************************************************************************************/ + +#endif // !defined(__TOBII_TX_CLIENT_CPPBINDINGS_HANDLEWRAPPER__INL__) + +/*********************************************************************************************************************/ -- cgit v1.2.3