Драйверы торгового оборудования v.9
iinput_c.h
1 #ifndef INPUT_INTERFACE_C_H
2 #define INPUT_INTERFACE_C_H
3 
4 #if defined(_WIN32) || defined(_WIN32_WCE)
5 # if defined(DTO_LIBRARY)
6 # define DTOSHARED_EXPORT __declspec(dllexport)
7 # else
8 # define DTOSHARED_EXPORT __declspec(dllimport)
9 # endif
10 # define DTOSHARED_CCA __cdecl
11 #elif defined(__linux__) || defined(ANDROID)
12 # define DTOSHARED_EXPORT
13 # define DTOSHARED_CCA
14 #else
15 # define DTOSHARED_EXPORT
16 # define DTOSHARED_CCA __attribute__ ((cdecl))
17 #endif
18 
19 
20 typedef void (*EventHandlerFunc)(void*);
21 
22 extern "C"
23 {
24 
25 DTOSHARED_EXPORT int DTOSHARED_CCA get_LicenseValid(void *ptr, int *state);
26 DTOSHARED_EXPORT int DTOSHARED_CCA get_LicenseExpiredDate(void *ptr, wchar_t *bfr, int bfrSize);
27 DTOSHARED_EXPORT int DTOSHARED_CCA get_Version(void *ptr, wchar_t *bfr, int bfrSize);
28 DTOSHARED_EXPORT int DTOSHARED_CCA get_DriverName(void *ptr, wchar_t *bfr, int bfrSize);
29 DTOSHARED_EXPORT int DTOSHARED_CCA get_DeviceEnabled(void *ptr, int *deviceEnabled);
30 DTOSHARED_EXPORT int DTOSHARED_CCA put_DeviceEnabled(void *ptr, int deviceEnabled);
31 DTOSHARED_EXPORT int DTOSHARED_CCA get_ResultCode(void *ptr, int *resultCode);
32 DTOSHARED_EXPORT int DTOSHARED_CCA get_ResultDescription(void *ptr, wchar_t *bfr, int bfrSize);
33 DTOSHARED_EXPORT int DTOSHARED_CCA get_BadParam(void *ptr, int *badParam);
34 DTOSHARED_EXPORT int DTOSHARED_CCA get_BadParamDescription(void *ptr, wchar_t *bfr, int bfrSize);
35 DTOSHARED_EXPORT int DTOSHARED_CCA get_ApplicationHandle(void *ptr, void **appHandle);
36 DTOSHARED_EXPORT int DTOSHARED_CCA put_ApplicationHandle(void *ptr, void *appHandle);
37 DTOSHARED_EXPORT int DTOSHARED_CCA get_DeviceSettings(void *ptr, wchar_t *bfr, int bfrSize);
38 DTOSHARED_EXPORT int DTOSHARED_CCA put_DeviceSettings(void *ptr, const wchar_t *deviceSettings);
39 DTOSHARED_EXPORT int DTOSHARED_CCA get_DeviceSingleSettingAsBuff(void *ptr, const wchar_t *name, wchar_t *bfr, int bfrSize);
40 DTOSHARED_EXPORT int DTOSHARED_CCA put_DeviceSingleSettingAsBuff(void *ptr, const wchar_t *name, const wchar_t *value);
41 DTOSHARED_EXPORT int DTOSHARED_CCA get_DeviceSingleSettingAsInt(void *ptr, const wchar_t *name, int *value);
42 DTOSHARED_EXPORT int DTOSHARED_CCA put_DeviceSingleSettingAsInt(void *ptr, const wchar_t *name, const int value);
43 DTOSHARED_EXPORT int DTOSHARED_CCA get_DeviceSingleSettingAsDouble(void *ptr, const wchar_t *name, double *value);
44 DTOSHARED_EXPORT int DTOSHARED_CCA put_DeviceSingleSettingAsDouble(void *ptr, const wchar_t *name, const double value);
45 DTOSHARED_EXPORT int DTOSHARED_CCA get_DeviceSingleSettingMapping(void *ptr, const wchar_t *name, wchar_t *bfr, int bfrSize);
46 
47 DTOSHARED_EXPORT int DTOSHARED_CCA ShowProperties(void *ptr);
48 DTOSHARED_EXPORT int DTOSHARED_CCA ApplySingleSettings(void *ptr);
49 DTOSHARED_EXPORT int DTOSHARED_CCA ResetSingleSettings(void *ptr);
50 
51 DTOSHARED_EXPORT int DTOSHARED_CCA get_CurrentDeviceID(void *ptr, wchar_t *bfr, int bfrSize);
52 DTOSHARED_EXPORT int DTOSHARED_CCA put_CurrentDeviceID(void *ptr, const wchar_t *newDeviceID);
53 DTOSHARED_EXPORT int DTOSHARED_CCA put_EventHandler(void *ptr, EventHandlerFunc func);
54 DTOSHARED_EXPORT int DTOSHARED_CCA get_AutoDisable(void *ptr, int *autoDisable);
55 DTOSHARED_EXPORT int DTOSHARED_CCA put_AutoDisable(void *ptr, int autoDisable);
56 DTOSHARED_EXPORT int DTOSHARED_CCA get_DataEventEnabled(void *ptr, int *enableDataEvent);
57 DTOSHARED_EXPORT int DTOSHARED_CCA put_DataEventEnabled(void *ptr, int enableDataEvent);
58 DTOSHARED_EXPORT int DTOSHARED_CCA get_ScanData(void *ptr, wchar_t *bfr, int bfrSize);
59 DTOSHARED_EXPORT int DTOSHARED_CCA get_ActualSensitivity(void *ptr, int *sens);
60 
61 DTOSHARED_EXPORT int DTOSHARED_CCA get_Track1(void *ptr, wchar_t *bfr, int bfrSize);
62 DTOSHARED_EXPORT int DTOSHARED_CCA get_Track2(void *ptr, wchar_t *bfr, int bfrSize);
63 DTOSHARED_EXPORT int DTOSHARED_CCA get_Track3(void *ptr, wchar_t *bfr, int bfrSize);
64 DTOSHARED_EXPORT int DTOSHARED_CCA get_DataCount(void *ptr, int *value);
65 DTOSHARED_EXPORT int DTOSHARED_CCA get_EventNumber(void *ptr, int *value);
66 DTOSHARED_EXPORT int DTOSHARED_CCA put_EventNumber(void *ptr, int value);
67 
68 DTOSHARED_EXPORT int DTOSHARED_CCA get_ScannerEventHandler(void *ptr, void **handler);
69 DTOSHARED_EXPORT int DTOSHARED_CCA put_ScanerPortHandler(void *ptr, void *handler);
70 
71 DTOSHARED_EXPORT int DTOSHARED_CCA DeleteEvent(void *ptr);
72 
73 }
74 
75 #endif // IINPUT_C_H