3DiVi Face SDK  3.24.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Groups
StructStorage.h
1 #ifndef __PBIO_API__PBIO__STRUCT_STORAGE_H_3e4a45e14b2b47dba8d3c32883c6a631
2 #define __PBIO_API__PBIO__STRUCT_STORAGE_H_3e4a45e14b2b47dba8d3c32883c6a631
3 
5 
6 #include "ComplexObject.h"
7 #include "StructStorageFields.h"
8 
9 namespace pbio
10 {
11 
12 class StructStorage : public ComplexObject
13 {
14 public:
15 
16  StructStorage(
17  const DHPtr &dll_handle,
18  void* impl);
19 
20  int64_t get_int64(const int field_id) const;
21 
22  double get_double(const int field_id) const;
23 
24  void* get_pointer(const int field_id) const;
25 
26 };
27 
28 
29 // implementation:
30 
31 inline
32 StructStorage::StructStorage(
33  const DHPtr &dll_handle,
34  void* impl):
35 ComplexObject(dll_handle, impl)
36 {
37  // nothing else
38 }
39 
40 inline
41 int64_t StructStorage::get_int64(const int field_id) const
42 {
43  void* exception = NULL;
44 
45  int64_t const result = _dll_handle->StructStorage_get_int64(_impl, field_id, &exception);
46 
47  checkException(exception, *_dll_handle);
48 
49  return result;
50 }
51 
52 inline
53 double StructStorage::get_double(const int field_id) const
54 {
55  void* exception = NULL;
56 
57  double const result = _dll_handle->StructStorage_get_double(_impl, field_id, &exception);
58 
59  checkException(exception, *_dll_handle);
60 
61  return result;
62 }
63 
64 inline
65 void* StructStorage::get_pointer(const int field_id) const
66 {
67  void* exception = NULL;
68 
69  void* const result = _dll_handle->StructStorage_get_pointer(_impl, field_id, &exception);
70 
71  checkException(exception, *_dll_handle);
72 
73  return result;
74 }
75 
76 
77 } // pbio namespace
78 
80 
81 #endif // __PBIO_API__PBIO__STRUCT_STORAGE_H_3e4a45e14b2b47dba8d3c32883c6a631