blob: eae842e5881802822a0ca71ebd6ad444d3977567 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
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 <typename THandle>
inline HandleWrapper<THandle>::HandleWrapper(const std::shared_ptr<const Context>& spContext, THandle hObject)
: _spContext(spContext), _hObject(hObject)
{}
/*********************************************************************************************************************/
template <typename THandle>
inline HandleWrapper<THandle>::~HandleWrapper()
{ }
/*********************************************************************************************************************/
template <typename THandle>
inline std::shared_ptr<const Context> HandleWrapper<THandle>::GetContext() const
{
return _spContext;
}
/*********************************************************************************************************************/
template <typename THandle>
inline THandle HandleWrapper<THandle>::GetHandle() const
{
return _hObject;
}
/*********************************************************************************************************************/
template <typename THandle>
template <typename THandle1, typename THandle2>
inline static std::string HandleWrapper<THandle>::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__)
/*********************************************************************************************************************/
|