Neonode zForce(TM) SDK

- Main Page
- Modules
- Classes
- Files

- File List
- File Members

zForceCommon.h
Go to the documentation of this file.
1
7 #ifndef ZFORCECOMMON_H
8 #define ZFORCECOMMON_H
9
10 // DLLEXTERNAL is for members visible outside the Shared Library.
11 // DLLINTERNAL is for members visible only inside the Shared Library.
12 // MODULEINTERNAL is for members visible only inside the module.
13
14 #ifdef _WIN32
15 #ifdef COMPILING_ZFORCE_SDK
16 #define DLLEXTERNAL __declspec(dllexport)
17 #else
18 #define DLLEXTERNAL __declspec(dllimport)
19 #endif
20 #define DLLINTERNAL
21 #define MODULEINTERNAL static
22 #elif defined (__clang__) || __GNUC__ > 4
23 #define DLLEXTERNAL __attribute__ ((visibility ("default")))
24 #define DLLINTERNAL __attribute__ ((visibility ("hidden")))
25 #define MODULEINTERNAL static
26 #else
27 #error Unsupported compiler.
28 #endif
29
30 // Violates Barr 4.2d "No header file shall contain a #include statement."
31 // We have a rule exclusion.
32 #include <zForceTypes.h>
33
34 // Macros used to expand OS defines into path/file that can be #included.
35 #define OSINCLUDE1(x) #x
36 #define OSINCLUDE(x) OSINCLUDE1(x)
37
38
43 #define ENOTALLOWED 300
44 #define EALREADYINITIALIZED 301
45 #define EVALUEOVERFLOW 302
46 #define EFAILEDGETTINGTIME 303
47 #define EINTERRUPTED 304
48 #define ENOTSUPPORTED 305
49 #define EINVALIDSIZE 306
50 #define EINVALIDINPUT 307
51
58 #define EOUTOFMEMORY 400
59 #define EILLEGALMEMORYSIZE 401
60
67 #define EMUTEXNOTINITIALIZED 500
68 #define EMUTEXINITIALIZATIONFAILED 501
69 #define EMUTEXLOCKFAILED 502
70 #define EMUTEXUNLOCKFAILED 503
71 #define EMUTEXDESTROYFAILED 504
72 #define EBADMUTEX 505
73 #define ESEMAPHORENOTINITIALIZED 506
74 #define ESEMAPHOREINITIALIZATIONFAILED 507
75 #define ESEMAPHOREWAITFAILED 508
76 #define ESEMAPHOREINCREMENTFAILED 509
77 #define ESEMAPHOREDESTROYFAILED 510
78 #define EBADSEMAPHORE 511
79 #define ESEMAPHOREWAITTIMEDOUT 512
80
87 #define ETHREADCREATEFAILED 600
88 #define EBADTHREAD 601
89
96 #define EQUEUECREATIONFAILED 700
97 #define EENQUEUEFAILED 701
98 #define EDEQUEUEFAILED 702
99 #define EDEQUEUETIMEDOUT 703
100 #define EBADQUEUE 704
101
108 #define EZFORCENOTINITIALIZED 800
109 #define EZFORCEINITIALIZATIONFAILED 801
110
117 #define EBADCONNECTION 900
118 #define EDEVICENOTFOUND 901
119 #define EMESSAGEFILTERALREADYSET 902
120 #define EALREADYCONNECTED 903
121 #define ENOTCONNECTED 904
122 #define ERECEIVETIMEOUT 905
123
130 #define EUNKNOWNDEVICETYPE 1000
131 #define EALREADYINPROGRESS 1001
132
139 #define EUNKNOWNTRANSPORT 1100
141 #define EALREADYOPEN 1101
142 #define ENOTOPENED 1102
143 #define EWRITEFAILED 1103
144 #define EPARAMETERSTRINGTOOLONG 1104
145 #define ECLOSEFAILED 1105
147 #define EOPENFAILED 1106
148 #define ENOPORTENTRY 1107
149 #define EREADFAILED 1108
150 #define EPARTIALWRITE 1109
151 #define ENODEVICEENTRY 1110
152
159 #define EUNKNOWNPROTOCOL 1200
161 #define EALREADYADDED 1201
163 #define EBADNAME 1202
164 #define EPROTOCOLERROR 1203
165
172 #define EUNKNOWNMESSAGETYPE 1300
173 #define EUNKNOWNMESSAGEGROUP 1301
174
176 // Barr 4.2d violation and exclusion.
177 #include <zForceConfig.h>
178
179 #endif // ZFORCECOMMON_H
180
zForceTypes.h