SPI  1.1.30
Secured Payment Interface
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Pages
SPIDEF.h
Go to the documentation of this file.
1 
13 #pragma once
14 
15 #include <iostream>
16 #include <string>
17 #include <cstring>
18 #include "types.def"
19 
20 #ifdef WIN32
21 #ifdef SPI_EXPORTS
22 #define SPILIBRARY_API __declspec(dllexport)
23 #elif SPI_NOEXPORTS
24 #define SPILIBRARY_API
25 #else
26 #define SPILIBRARY_API __declspec(dllimport)
27 #endif
28 #elif __GNUC__
29 #ifdef SPI_EXPORTS
30 #define SPILIBRARY_API __attribute__((visibility("default")))
31 #else
32 #define SPILIBRARY_API
33 #endif
34 #endif
35 
36 
37 
38 using std::string;
39 
41 typedef void* APIHandle;
42 
44 typedef usint PortType;
45 
47 typedef uint64_t AmountType;
48 
50 typedef int32_t PaymentType;
51 
53 typedef sint PPIDType;
54 
56 typedef sint ResultType;
57 
59 typedef uint64_t RateType;
60 
62 typedef int32_t PercentType;
63 
65 typedef int32_t MonthType;
66 
68 typedef ulint TimeOutType;
69 
71 typedef byte FrequencyType;
72 
74 typedef int32_t CurrencyISOType;
75 
77 typedef usint CounterType;
78 
79 namespace Modularity {
80 
81  namespace SPI {
84  {
87  SPI_FAIL = -2,
88  SPI_INVALID = -3,
91  SPI_ABORTED = -6,
93  SPI_TIME_OUT = -8,
94  SPI_NO_INIT = -999
95  };
96 
98  enum SPI_STATUS
99  {
100  SPI_READY = 0,
104  SPI_ERROR = -3
105  };
106 
109  {
113  };
114 
117  {
120  };
121 
124  {
129  };
130 
132  enum ServiceID
133  {
137  };
138 
141  {
142  MP3 = 0,
143  MPOS = 1,
144  XPI = 2
145  };
146 
149  {
150  X_REPORT = 0,
151  Z_REPORT = 1
152  };
153 
156  {
161  };
162 
165  {
166  Curr_Shekel = 376,
167  Curr_Dollar = 840,
169  };
170 
173  struct ReceiptLine
174  {
175  string key;
176  string value;
177  };
178 
181  {
193  };
194 
198  namespace Ashrait {
199 
202  {
203  SwipeData = 1,
204  Balance = 2,
209  };
210 
213  {
219  };
220 
223  {
224  ToNone = 0,
225  ToCPI = 1,
226  ToDollar = 2,
227  };
228 
230  enum Status
231  {
232  Ready = 0,
234  BatchNeeded = -2,
235  DBError = -3,
236  PinpadError = -4,
238  Unknown = -6,
241  };
242 
245  {
247  CNP_Phone = 2,
249  };
250 
253  {
256  TT_Unload = 2,
257  TT_Forced = 3,
259  TT_Cash = 7,
262  TT_Refund = 53,
263  TT_Charge = 55,
264  };
265 
267  enum IPayType
268  {
272  IPay_Club = 3,
273  IPay_NoIpay = 99,
274  };
275 
277  enum ECIType
278  {
282  };
283 
286  {
291  };
292 
294  enum Manpik
295  {
300  };
301 
303  enum Solek
304  {
306  Solek_Cal = 2,
308  };
309 
311  enum Mutag
312  {
313  Mutag_PL = 0,
319  Mutag_JCB = 6,
322  };
323 
326  {
333  PEM_RFU = 11,
335  PEM_Phone = 50,
340  PEM_Empty = 99,
341  };
342 
345  {
346  ABS = 1,
347  Pelecard = 2,
348  };
349 
352  {
369  };
370 
371  }
372  }
373 }
374 
375 
376 
377 
378 
379 
380 
381