File: | src/mod/languages/mod_lua/mod_lua_wrap.cpp |
Warning: | line 9551, column 18 Called C++ object pointer is null |
Press '?' to see keyboard shortcuts
Keyboard shortcuts:
1 | /* ---------------------------------------------------------------------------- | |||
2 | * This file was automatically generated by SWIG (http://www.swig.org). | |||
3 | * Version 3.0.12 | |||
4 | * | |||
5 | * This file is not intended to be easily readable and contains a number of | |||
6 | * coding conventions designed to improve portability and efficiency. Do not make | |||
7 | * changes to this file unless you know what you are doing--modify the SWIG | |||
8 | * interface file instead. | |||
9 | * ----------------------------------------------------------------------------- */ | |||
10 | ||||
11 | ||||
12 | #ifndef SWIGLUA | |||
13 | #define SWIGLUA | |||
14 | #endif | |||
15 | ||||
16 | #define SWIG_LUA_TARGET1 SWIG_LUA_FLAVOR_LUA1 | |||
17 | #define SWIG_LUA_MODULE_GLOBAL | |||
18 | ||||
19 | ||||
20 | #ifdef __cplusplus201402L | |||
21 | /* SwigValueWrapper is described in swig.swg */ | |||
22 | template<typename T> class SwigValueWrapper { | |||
23 | struct SwigMovePointer { | |||
24 | T *ptr; | |||
25 | SwigMovePointer(T *p) : ptr(p) { } | |||
26 | ~SwigMovePointer() { delete ptr; } | |||
27 | SwigMovePointer& operator=(SwigMovePointer& rhs) { T* oldptr = ptr; ptr = 0; delete oldptr; ptr = rhs.ptr; rhs.ptr = 0; return *this; } | |||
28 | } pointer; | |||
29 | SwigValueWrapper& operator=(const SwigValueWrapper<T>& rhs); | |||
30 | SwigValueWrapper(const SwigValueWrapper<T>& rhs); | |||
31 | public: | |||
32 | SwigValueWrapper() : pointer(0) { } | |||
33 | SwigValueWrapper& operator=(const T& t) { SwigMovePointer tmp(new T(t)); pointer = tmp; return *this; } | |||
34 | operator T&() const { return *pointer.ptr; } | |||
35 | T *operator&() { return pointer.ptr; } | |||
36 | }; | |||
37 | ||||
38 | template <typename T> T SwigValueInit() { | |||
39 | return T(); | |||
40 | } | |||
41 | #endif | |||
42 | ||||
43 | /* ----------------------------------------------------------------------------- | |||
44 | * This section contains generic SWIG labels for method/variable | |||
45 | * declarations/attributes, and other compiler dependent labels. | |||
46 | * ----------------------------------------------------------------------------- */ | |||
47 | ||||
48 | /* template workaround for compilers that cannot correctly implement the C++ standard */ | |||
49 | #ifndef SWIGTEMPLATEDISAMBIGUATOR | |||
50 | # if defined(__SUNPRO_CC) && (__SUNPRO_CC <= 0x560) | |||
51 | # define SWIGTEMPLATEDISAMBIGUATOR template | |||
52 | # elif defined(__HP_aCC) | |||
53 | /* Needed even with `aCC -AA' when `aCC -V' reports HP ANSI C++ B3910B A.03.55 */ | |||
54 | /* If we find a maximum version that requires this, the test would be __HP_aCC <= 35500 for A.03.55 */ | |||
55 | # define SWIGTEMPLATEDISAMBIGUATOR template | |||
56 | # else | |||
57 | # define SWIGTEMPLATEDISAMBIGUATOR | |||
58 | # endif | |||
59 | #endif | |||
60 | ||||
61 | /* inline attribute */ | |||
62 | #ifndef SWIGINLINEinline | |||
63 | # if defined(__cplusplus201402L) || (defined(__GNUC__4) && !defined(__STRICT_ANSI__)) | |||
64 | # define SWIGINLINEinline inline | |||
65 | # else | |||
66 | # define SWIGINLINEinline | |||
67 | # endif | |||
68 | #endif | |||
69 | ||||
70 | /* attribute recognised by some compilers to avoid 'unused' warnings */ | |||
71 | #ifndef SWIGUNUSED__attribute__ ((__unused__)) | |||
72 | # if defined(__GNUC__4) | |||
73 | # if !(defined(__cplusplus201402L)) || (__GNUC__4 > 3 || (__GNUC__4 == 3 && __GNUC_MINOR__2 >= 4)) | |||
74 | # define SWIGUNUSED__attribute__ ((__unused__)) __attribute__ ((__unused__)) | |||
75 | # else | |||
76 | # define SWIGUNUSED__attribute__ ((__unused__)) | |||
77 | # endif | |||
78 | # elif defined(__ICC) | |||
79 | # define SWIGUNUSED__attribute__ ((__unused__)) __attribute__ ((__unused__)) | |||
80 | # else | |||
81 | # define SWIGUNUSED__attribute__ ((__unused__)) | |||
82 | # endif | |||
83 | #endif | |||
84 | ||||
85 | #ifndef SWIG_MSC_UNSUPPRESS_4505 | |||
86 | # if defined(_MSC_VER) | |||
87 | # pragma warning(disable : 4505) /* unreferenced local function has been removed */ | |||
88 | # endif | |||
89 | #endif | |||
90 | ||||
91 | #ifndef SWIGUNUSEDPARM | |||
92 | # ifdef __cplusplus201402L | |||
93 | # define SWIGUNUSEDPARM(p) | |||
94 | # else | |||
95 | # define SWIGUNUSEDPARM(p) p SWIGUNUSED__attribute__ ((__unused__)) | |||
96 | # endif | |||
97 | #endif | |||
98 | ||||
99 | /* internal SWIG method */ | |||
100 | #ifndef SWIGINTERNstatic __attribute__ ((__unused__)) | |||
101 | # define SWIGINTERNstatic __attribute__ ((__unused__)) static SWIGUNUSED__attribute__ ((__unused__)) | |||
102 | #endif | |||
103 | ||||
104 | /* internal inline SWIG method */ | |||
105 | #ifndef SWIGINTERNINLINEstatic __attribute__ ((__unused__)) inline | |||
106 | # define SWIGINTERNINLINEstatic __attribute__ ((__unused__)) inline SWIGINTERNstatic __attribute__ ((__unused__)) SWIGINLINEinline | |||
107 | #endif | |||
108 | ||||
109 | /* exporting methods */ | |||
110 | #if defined(__GNUC__4) | |||
111 | # if (__GNUC__4 >= 4) || (__GNUC__4 == 3 && __GNUC_MINOR__2 >= 4) | |||
112 | # ifndef GCC_HASCLASSVISIBILITY | |||
113 | # define GCC_HASCLASSVISIBILITY | |||
114 | # endif | |||
115 | # endif | |||
116 | #endif | |||
117 | ||||
118 | #ifndef SWIGEXPORT__attribute__ ((visibility("default"))) | |||
119 | # if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__) | |||
120 | # if defined(STATIC_LINKED) | |||
121 | # define SWIGEXPORT__attribute__ ((visibility("default"))) | |||
122 | # else | |||
123 | # define SWIGEXPORT__attribute__ ((visibility("default"))) __declspec(dllexport) | |||
124 | # endif | |||
125 | # else | |||
126 | # if defined(__GNUC__4) && defined(GCC_HASCLASSVISIBILITY) | |||
127 | # define SWIGEXPORT__attribute__ ((visibility("default"))) __attribute__ ((visibility("default"))) | |||
128 | # else | |||
129 | # define SWIGEXPORT__attribute__ ((visibility("default"))) | |||
130 | # endif | |||
131 | # endif | |||
132 | #endif | |||
133 | ||||
134 | /* calling conventions for Windows */ | |||
135 | #ifndef SWIGSTDCALL | |||
136 | # if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__) | |||
137 | # define SWIGSTDCALL __stdcall | |||
138 | # else | |||
139 | # define SWIGSTDCALL | |||
140 | # endif | |||
141 | #endif | |||
142 | ||||
143 | /* Deal with Microsoft's attempt at deprecating C standard runtime functions */ | |||
144 | #if !defined(SWIG_NO_CRT_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_CRT_SECURE_NO_DEPRECATE) | |||
145 | # define _CRT_SECURE_NO_DEPRECATE | |||
146 | #endif | |||
147 | ||||
148 | /* Deal with Microsoft's attempt at deprecating methods in the standard C++ library */ | |||
149 | #if !defined(SWIG_NO_SCL_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_SCL_SECURE_NO_DEPRECATE) | |||
150 | # define _SCL_SECURE_NO_DEPRECATE | |||
151 | #endif | |||
152 | ||||
153 | /* Deal with Apple's deprecated 'AssertMacros.h' from Carbon-framework */ | |||
154 | #if defined(__APPLE__) && !defined(__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES) | |||
155 | # define __ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES 0 | |||
156 | #endif | |||
157 | ||||
158 | /* Intel's compiler complains if a variable which was never initialised is | |||
159 | * cast to void, which is a common idiom which we use to indicate that we | |||
160 | * are aware a variable isn't used. So we just silence that warning. | |||
161 | * See: https://github.com/swig/swig/issues/192 for more discussion. | |||
162 | */ | |||
163 | #ifdef __INTEL_COMPILER | |||
164 | # pragma warning disable 592 | |||
165 | #endif | |||
166 | ||||
167 | /* ----------------------------------------------------------------------------- | |||
168 | * swigrun.swg | |||
169 | * | |||
170 | * This file contains generic C API SWIG runtime support for pointer | |||
171 | * type checking. | |||
172 | * ----------------------------------------------------------------------------- */ | |||
173 | ||||
174 | /* This should only be incremented when either the layout of swig_type_info changes, | |||
175 | or for whatever reason, the runtime changes incompatibly */ | |||
176 | #define SWIG_RUNTIME_VERSION"4" "4" | |||
177 | ||||
178 | /* define SWIG_TYPE_TABLE_NAME as "SWIG_TYPE_TABLE" */ | |||
179 | #ifdef SWIG_TYPE_TABLE | |||
180 | # define SWIG_QUOTE_STRING(x) #x | |||
181 | # define SWIG_EXPAND_AND_QUOTE_STRING(x) SWIG_QUOTE_STRING(x) | |||
182 | # define SWIG_TYPE_TABLE_NAME SWIG_EXPAND_AND_QUOTE_STRING(SWIG_TYPE_TABLE) | |||
183 | #else | |||
184 | # define SWIG_TYPE_TABLE_NAME | |||
185 | #endif | |||
186 | ||||
187 | /* | |||
188 | You can use the SWIGRUNTIME and SWIGRUNTIMEINLINE macros for | |||
189 | creating a static or dynamic library from the SWIG runtime code. | |||
190 | In 99.9% of the cases, SWIG just needs to declare them as 'static'. | |||
191 | ||||
192 | But only do this if strictly necessary, ie, if you have problems | |||
193 | with your compiler or suchlike. | |||
194 | */ | |||
195 | ||||
196 | #ifndef SWIGRUNTIMEstatic __attribute__ ((__unused__)) | |||
197 | # define SWIGRUNTIMEstatic __attribute__ ((__unused__)) SWIGINTERNstatic __attribute__ ((__unused__)) | |||
198 | #endif | |||
199 | ||||
200 | #ifndef SWIGRUNTIMEINLINEstatic __attribute__ ((__unused__)) inline | |||
201 | # define SWIGRUNTIMEINLINEstatic __attribute__ ((__unused__)) inline SWIGRUNTIMEstatic __attribute__ ((__unused__)) SWIGINLINEinline | |||
202 | #endif | |||
203 | ||||
204 | /* Generic buffer size */ | |||
205 | #ifndef SWIG_BUFFER_SIZE1024 | |||
206 | # define SWIG_BUFFER_SIZE1024 1024 | |||
207 | #endif | |||
208 | ||||
209 | /* Flags for pointer conversions */ | |||
210 | #define SWIG_POINTER_DISOWN0x1 0x1 | |||
211 | #define SWIG_CAST_NEW_MEMORY0x2 0x2 | |||
212 | ||||
213 | /* Flags for new pointer objects */ | |||
214 | #define SWIG_POINTER_OWN0x1 0x1 | |||
215 | ||||
216 | ||||
217 | /* | |||
218 | Flags/methods for returning states. | |||
219 | ||||
220 | The SWIG conversion methods, as ConvertPtr, return an integer | |||
221 | that tells if the conversion was successful or not. And if not, | |||
222 | an error code can be returned (see swigerrors.swg for the codes). | |||
223 | ||||
224 | Use the following macros/flags to set or process the returning | |||
225 | states. | |||
226 | ||||
227 | In old versions of SWIG, code such as the following was usually written: | |||
228 | ||||
229 | if (SWIG_ConvertPtr(obj,vptr,ty.flags) != -1) { | |||
230 | // success code | |||
231 | } else { | |||
232 | //fail code | |||
233 | } | |||
234 | ||||
235 | Now you can be more explicit: | |||
236 | ||||
237 | int res = SWIG_ConvertPtr(obj,vptr,ty.flags); | |||
238 | if (SWIG_IsOK(res)) { | |||
239 | // success code | |||
240 | } else { | |||
241 | // fail code | |||
242 | } | |||
243 | ||||
244 | which is the same really, but now you can also do | |||
245 | ||||
246 | Type *ptr; | |||
247 | int res = SWIG_ConvertPtr(obj,(void **)(&ptr),ty.flags); | |||
248 | if (SWIG_IsOK(res)) { | |||
249 | // success code | |||
250 | if (SWIG_IsNewObj(res) { | |||
251 | ... | |||
252 | delete *ptr; | |||
253 | } else { | |||
254 | ... | |||
255 | } | |||
256 | } else { | |||
257 | // fail code | |||
258 | } | |||
259 | ||||
260 | I.e., now SWIG_ConvertPtr can return new objects and you can | |||
261 | identify the case and take care of the deallocation. Of course that | |||
262 | also requires SWIG_ConvertPtr to return new result values, such as | |||
263 | ||||
264 | int SWIG_ConvertPtr(obj, ptr,...) { | |||
265 | if (<obj is ok>) { | |||
266 | if (<need new object>) { | |||
267 | *ptr = <ptr to new allocated object>; | |||
268 | return SWIG_NEWOBJ; | |||
269 | } else { | |||
270 | *ptr = <ptr to old object>; | |||
271 | return SWIG_OLDOBJ; | |||
272 | } | |||
273 | } else { | |||
274 | return SWIG_BADOBJ; | |||
275 | } | |||
276 | } | |||
277 | ||||
278 | Of course, returning the plain '0(success)/-1(fail)' still works, but you can be | |||
279 | more explicit by returning SWIG_BADOBJ, SWIG_ERROR or any of the | |||
280 | SWIG errors code. | |||
281 | ||||
282 | Finally, if the SWIG_CASTRANK_MODE is enabled, the result code | |||
283 | allows to return the 'cast rank', for example, if you have this | |||
284 | ||||
285 | int food(double) | |||
286 | int fooi(int); | |||
287 | ||||
288 | and you call | |||
289 | ||||
290 | food(1) // cast rank '1' (1 -> 1.0) | |||
291 | fooi(1) // cast rank '0' | |||
292 | ||||
293 | just use the SWIG_AddCast()/SWIG_CheckState() | |||
294 | */ | |||
295 | ||||
296 | #define SWIG_OK(0) (0) | |||
297 | #define SWIG_ERROR(-1) (-1) | |||
298 | #define SWIG_IsOK(r)(r >= 0) (r >= 0) | |||
299 | #define SWIG_ArgError(r)((r != (-1)) ? r : SWIG_TypeError) ((r != SWIG_ERROR(-1)) ? r : SWIG_TypeError) | |||
300 | ||||
301 | /* The CastRankLimit says how many bits are used for the cast rank */ | |||
302 | #define SWIG_CASTRANKLIMIT(1 << 8) (1 << 8) | |||
303 | /* The NewMask denotes the object was created (using new/malloc) */ | |||
304 | #define SWIG_NEWOBJMASK((1 << 8) << 1) (SWIG_CASTRANKLIMIT(1 << 8) << 1) | |||
305 | /* The TmpMask is for in/out typemaps that use temporal objects */ | |||
306 | #define SWIG_TMPOBJMASK(((1 << 8) << 1) << 1) (SWIG_NEWOBJMASK((1 << 8) << 1) << 1) | |||
307 | /* Simple returning values */ | |||
308 | #define SWIG_BADOBJ((-1)) (SWIG_ERROR(-1)) | |||
309 | #define SWIG_OLDOBJ((0)) (SWIG_OK(0)) | |||
310 | #define SWIG_NEWOBJ((0) | ((1 << 8) << 1)) (SWIG_OK(0) | SWIG_NEWOBJMASK((1 << 8) << 1)) | |||
311 | #define SWIG_TMPOBJ((0) | (((1 << 8) << 1) << 1)) (SWIG_OK(0) | SWIG_TMPOBJMASK(((1 << 8) << 1) << 1)) | |||
312 | /* Check, add and del mask methods */ | |||
313 | #define SWIG_AddNewMask(r)((r >= 0) ? (r | ((1 << 8) << 1)) : r) (SWIG_IsOK(r)(r >= 0) ? (r | SWIG_NEWOBJMASK((1 << 8) << 1)) : r) | |||
314 | #define SWIG_DelNewMask(r)((r >= 0) ? (r & ~((1 << 8) << 1)) : r) (SWIG_IsOK(r)(r >= 0) ? (r & ~SWIG_NEWOBJMASK((1 << 8) << 1)) : r) | |||
315 | #define SWIG_IsNewObj(r)((r >= 0) && (r & ((1 << 8) << 1)) ) (SWIG_IsOK(r)(r >= 0) && (r & SWIG_NEWOBJMASK((1 << 8) << 1))) | |||
316 | #define SWIG_AddTmpMask(r)((r >= 0) ? (r | (((1 << 8) << 1) << 1)) : r) (SWIG_IsOK(r)(r >= 0) ? (r | SWIG_TMPOBJMASK(((1 << 8) << 1) << 1)) : r) | |||
317 | #define SWIG_DelTmpMask(r)((r >= 0) ? (r & ~(((1 << 8) << 1) << 1)) : r) (SWIG_IsOK(r)(r >= 0) ? (r & ~SWIG_TMPOBJMASK(((1 << 8) << 1) << 1)) : r) | |||
318 | #define SWIG_IsTmpObj(r)((r >= 0) && (r & (((1 << 8) << 1) << 1))) (SWIG_IsOK(r)(r >= 0) && (r & SWIG_TMPOBJMASK(((1 << 8) << 1) << 1))) | |||
319 | ||||
320 | /* Cast-Rank Mode */ | |||
321 | #if defined(SWIG_CASTRANK_MODE) | |||
322 | # ifndef SWIG_TypeRank | |||
323 | # define SWIG_TypeRank unsigned long | |||
324 | # endif | |||
325 | # ifndef SWIG_MAXCASTRANK /* Default cast allowed */ | |||
326 | # define SWIG_MAXCASTRANK (2) | |||
327 | # endif | |||
328 | # define SWIG_CASTRANKMASK ((SWIG_CASTRANKLIMIT(1 << 8)) -1) | |||
329 | # define SWIG_CastRank(r) (r & SWIG_CASTRANKMASK) | |||
330 | SWIGINTERNINLINEstatic __attribute__ ((__unused__)) inline int SWIG_AddCast(int r)(int r) { | |||
331 | return SWIG_IsOK(r)(r >= 0) ? ((SWIG_CastRank(r) < SWIG_MAXCASTRANK) ? (r + 1) : SWIG_ERROR(-1)) : r; | |||
332 | } | |||
333 | SWIGINTERNINLINEstatic __attribute__ ((__unused__)) inline int SWIG_CheckState(int r)((int r >= 0) ? 1 : 0) { | |||
334 | return SWIG_IsOK(r)(r >= 0) ? SWIG_CastRank(r) + 1 : 0; | |||
335 | } | |||
336 | #else /* no cast-rank mode */ | |||
337 | # define SWIG_AddCast(r)(r) (r) | |||
338 | # define SWIG_CheckState(r)((r >= 0) ? 1 : 0) (SWIG_IsOK(r)(r >= 0) ? 1 : 0) | |||
339 | #endif | |||
340 | ||||
341 | ||||
342 | #include <string.h> | |||
343 | ||||
344 | #ifdef __cplusplus201402L | |||
345 | extern "C" { | |||
346 | #endif | |||
347 | ||||
348 | typedef void *(*swig_converter_func)(void *, int *); | |||
349 | typedef struct swig_type_info *(*swig_dycast_func)(void **); | |||
350 | ||||
351 | /* Structure to store information on one type */ | |||
352 | typedef struct swig_type_info { | |||
353 | const char *name; /* mangled name of this type */ | |||
354 | const char *str; /* human readable name of this type */ | |||
355 | swig_dycast_func dcast; /* dynamic cast function down a hierarchy */ | |||
356 | struct swig_cast_info *cast; /* linked list of types that can cast into this type */ | |||
357 | void *clientdata; /* language specific type data */ | |||
358 | int owndata; /* flag if the structure owns the clientdata */ | |||
359 | } swig_type_info; | |||
360 | ||||
361 | /* Structure to store a type and conversion function used for casting */ | |||
362 | typedef struct swig_cast_info { | |||
363 | swig_type_info *type; /* pointer to type that is equivalent to this type */ | |||
364 | swig_converter_func converter; /* function to cast the void pointers */ | |||
365 | struct swig_cast_info *next; /* pointer to next cast in linked list */ | |||
366 | struct swig_cast_info *prev; /* pointer to the previous cast */ | |||
367 | } swig_cast_info; | |||
368 | ||||
369 | /* Structure used to store module information | |||
370 | * Each module generates one structure like this, and the runtime collects | |||
371 | * all of these structures and stores them in a circularly linked list.*/ | |||
372 | typedef struct swig_module_info { | |||
373 | swig_type_info **types; /* Array of pointers to swig_type_info structures that are in this module */ | |||
374 | size_t size; /* Number of types in this module */ | |||
375 | struct swig_module_info *next; /* Pointer to next element in circularly linked list */ | |||
376 | swig_type_info **type_initial; /* Array of initially generated type structures */ | |||
377 | swig_cast_info **cast_initial; /* Array of initially generated casting structures */ | |||
378 | void *clientdata; /* Language specific module data */ | |||
379 | } swig_module_info; | |||
380 | ||||
381 | /* | |||
382 | Compare two type names skipping the space characters, therefore | |||
383 | "char*" == "char *" and "Class<int>" == "Class<int >", etc. | |||
384 | ||||
385 | Return 0 when the two name types are equivalent, as in | |||
386 | strncmp, but skipping ' '. | |||
387 | */ | |||
388 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) int | |||
389 | SWIG_TypeNameComp(const char *f1, const char *l1, | |||
390 | const char *f2, const char *l2) { | |||
391 | for (;(f1 != l1) && (f2 != l2); ++f1, ++f2) { | |||
392 | while ((*f1 == ' ') && (f1 != l1)) ++f1; | |||
393 | while ((*f2 == ' ') && (f2 != l2)) ++f2; | |||
394 | if (*f1 != *f2) return (*f1 > *f2) ? 1 : -1; | |||
395 | } | |||
396 | return (int)((l1 - f1) - (l2 - f2)); | |||
397 | } | |||
398 | ||||
399 | /* | |||
400 | Check type equivalence in a name list like <name1>|<name2>|... | |||
401 | Return 0 if equal, -1 if nb < tb, 1 if nb > tb | |||
402 | */ | |||
403 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) int | |||
404 | SWIG_TypeCmp(const char *nb, const char *tb) { | |||
405 | int equiv = 1; | |||
406 | const char* te = tb + strlen(tb); | |||
407 | const char* ne = nb; | |||
408 | while (equiv != 0 && *ne) { | |||
409 | for (nb = ne; *ne; ++ne) { | |||
410 | if (*ne == '|') break; | |||
411 | } | |||
412 | equiv = SWIG_TypeNameComp(nb, ne, tb, te); | |||
413 | if (*ne) ++ne; | |||
414 | } | |||
415 | return equiv; | |||
416 | } | |||
417 | ||||
418 | /* | |||
419 | Check type equivalence in a name list like <name1>|<name2>|... | |||
420 | Return 0 if not equal, 1 if equal | |||
421 | */ | |||
422 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) int | |||
423 | SWIG_TypeEquiv(const char *nb, const char *tb) { | |||
424 | return SWIG_TypeCmp(nb, tb) == 0 ? 1 : 0; | |||
425 | } | |||
426 | ||||
427 | /* | |||
428 | Check the typename | |||
429 | */ | |||
430 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) swig_cast_info * | |||
431 | SWIG_TypeCheck(const char *c, swig_type_info *ty) { | |||
432 | if (ty) { | |||
433 | swig_cast_info *iter = ty->cast; | |||
434 | while (iter) { | |||
435 | if (strcmp(iter->type->name, c) == 0) { | |||
436 | if (iter == ty->cast) | |||
437 | return iter; | |||
438 | /* Move iter to the top of the linked list */ | |||
439 | iter->prev->next = iter->next; | |||
440 | if (iter->next) | |||
441 | iter->next->prev = iter->prev; | |||
442 | iter->next = ty->cast; | |||
443 | iter->prev = 0; | |||
444 | if (ty->cast) ty->cast->prev = iter; | |||
445 | ty->cast = iter; | |||
446 | return iter; | |||
447 | } | |||
448 | iter = iter->next; | |||
449 | } | |||
450 | } | |||
451 | return 0; | |||
452 | } | |||
453 | ||||
454 | /* | |||
455 | Identical to SWIG_TypeCheck, except strcmp is replaced with a pointer comparison | |||
456 | */ | |||
457 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) swig_cast_info * | |||
458 | SWIG_TypeCheckStruct(swig_type_info *from, swig_type_info *ty) { | |||
459 | if (ty) { | |||
460 | swig_cast_info *iter = ty->cast; | |||
461 | while (iter) { | |||
462 | if (iter->type == from) { | |||
463 | if (iter == ty->cast) | |||
464 | return iter; | |||
465 | /* Move iter to the top of the linked list */ | |||
466 | iter->prev->next = iter->next; | |||
467 | if (iter->next) | |||
468 | iter->next->prev = iter->prev; | |||
469 | iter->next = ty->cast; | |||
470 | iter->prev = 0; | |||
471 | if (ty->cast) ty->cast->prev = iter; | |||
472 | ty->cast = iter; | |||
473 | return iter; | |||
474 | } | |||
475 | iter = iter->next; | |||
476 | } | |||
477 | } | |||
478 | return 0; | |||
479 | } | |||
480 | ||||
481 | /* | |||
482 | Cast a pointer up an inheritance hierarchy | |||
483 | */ | |||
484 | SWIGRUNTIMEINLINEstatic __attribute__ ((__unused__)) inline void * | |||
485 | SWIG_TypeCast(swig_cast_info *ty, void *ptr, int *newmemory) { | |||
486 | return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr, newmemory); | |||
487 | } | |||
488 | ||||
489 | /* | |||
490 | Dynamic pointer casting. Down an inheritance hierarchy | |||
491 | */ | |||
492 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) swig_type_info * | |||
493 | SWIG_TypeDynamicCast(swig_type_info *ty, void **ptr) { | |||
494 | swig_type_info *lastty = ty; | |||
495 | if (!ty || !ty->dcast) return ty; | |||
496 | while (ty && (ty->dcast)) { | |||
497 | ty = (*ty->dcast)(ptr); | |||
498 | if (ty) lastty = ty; | |||
499 | } | |||
500 | return lastty; | |||
501 | } | |||
502 | ||||
503 | /* | |||
504 | Return the name associated with this type | |||
505 | */ | |||
506 | SWIGRUNTIMEINLINEstatic __attribute__ ((__unused__)) inline const char * | |||
507 | SWIG_TypeName(const swig_type_info *ty) { | |||
508 | return ty->name; | |||
509 | } | |||
510 | ||||
511 | /* | |||
512 | Return the pretty name associated with this type, | |||
513 | that is an unmangled type name in a form presentable to the user. | |||
514 | */ | |||
515 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) const char * | |||
516 | SWIG_TypePrettyName(const swig_type_info *type) { | |||
517 | /* The "str" field contains the equivalent pretty names of the | |||
518 | type, separated by vertical-bar characters. We choose | |||
519 | to print the last name, as it is often (?) the most | |||
520 | specific. */ | |||
521 | if (!type) return NULL__null; | |||
522 | if (type->str != NULL__null) { | |||
523 | const char *last_name = type->str; | |||
524 | const char *s; | |||
525 | for (s = type->str; *s; s++) | |||
526 | if (*s == '|') last_name = s+1; | |||
527 | return last_name; | |||
528 | } | |||
529 | else | |||
530 | return type->name; | |||
531 | } | |||
532 | ||||
533 | /* | |||
534 | Set the clientdata field for a type | |||
535 | */ | |||
536 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) void | |||
537 | SWIG_TypeClientData(swig_type_info *ti, void *clientdata) { | |||
538 | swig_cast_info *cast = ti->cast; | |||
539 | /* if (ti->clientdata == clientdata) return; */ | |||
540 | ti->clientdata = clientdata; | |||
541 | ||||
542 | while (cast) { | |||
543 | if (!cast->converter) { | |||
544 | swig_type_info *tc = cast->type; | |||
545 | if (!tc->clientdata) { | |||
546 | SWIG_TypeClientData(tc, clientdata); | |||
547 | } | |||
548 | } | |||
549 | cast = cast->next; | |||
550 | } | |||
551 | } | |||
552 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) void | |||
553 | SWIG_TypeNewClientData(swig_type_info *ti, void *clientdata) { | |||
554 | SWIG_TypeClientData(ti, clientdata); | |||
555 | ti->owndata = 1; | |||
556 | } | |||
557 | ||||
558 | /* | |||
559 | Search for a swig_type_info structure only by mangled name | |||
560 | Search is a O(log #types) | |||
561 | ||||
562 | We start searching at module start, and finish searching when start == end. | |||
563 | Note: if start == end at the beginning of the function, we go all the way around | |||
564 | the circular list. | |||
565 | */ | |||
566 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) swig_type_info * | |||
567 | SWIG_MangledTypeQueryModule(swig_module_info *start, | |||
568 | swig_module_info *end, | |||
569 | const char *name) { | |||
570 | swig_module_info *iter = start; | |||
571 | do { | |||
572 | if (iter->size) { | |||
573 | size_t l = 0; | |||
574 | size_t r = iter->size - 1; | |||
575 | do { | |||
576 | /* since l+r >= 0, we can (>> 1) instead (/ 2) */ | |||
577 | size_t i = (l + r) >> 1; | |||
578 | const char *iname = iter->types[i]->name; | |||
579 | if (iname) { | |||
580 | int compare = strcmp(name, iname); | |||
581 | if (compare == 0) { | |||
582 | return iter->types[i]; | |||
583 | } else if (compare < 0) { | |||
584 | if (i) { | |||
585 | r = i - 1; | |||
586 | } else { | |||
587 | break; | |||
588 | } | |||
589 | } else if (compare > 0) { | |||
590 | l = i + 1; | |||
591 | } | |||
592 | } else { | |||
593 | break; /* should never happen */ | |||
594 | } | |||
595 | } while (l <= r); | |||
596 | } | |||
597 | iter = iter->next; | |||
598 | } while (iter != end); | |||
599 | return 0; | |||
600 | } | |||
601 | ||||
602 | /* | |||
603 | Search for a swig_type_info structure for either a mangled name or a human readable name. | |||
604 | It first searches the mangled names of the types, which is a O(log #types) | |||
605 | If a type is not found it then searches the human readable names, which is O(#types). | |||
606 | ||||
607 | We start searching at module start, and finish searching when start == end. | |||
608 | Note: if start == end at the beginning of the function, we go all the way around | |||
609 | the circular list. | |||
610 | */ | |||
611 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) swig_type_info * | |||
612 | SWIG_TypeQueryModule(swig_module_info *start, | |||
613 | swig_module_info *end, | |||
614 | const char *name) { | |||
615 | /* STEP 1: Search the name field using binary search */ | |||
616 | swig_type_info *ret = SWIG_MangledTypeQueryModule(start, end, name); | |||
617 | if (ret) { | |||
618 | return ret; | |||
619 | } else { | |||
620 | /* STEP 2: If the type hasn't been found, do a complete search | |||
621 | of the str field (the human readable name) */ | |||
622 | swig_module_info *iter = start; | |||
623 | do { | |||
624 | size_t i = 0; | |||
625 | for (; i < iter->size; ++i) { | |||
626 | if (iter->types[i]->str && (SWIG_TypeEquiv(iter->types[i]->str, name))) | |||
627 | return iter->types[i]; | |||
628 | } | |||
629 | iter = iter->next; | |||
630 | } while (iter != end); | |||
631 | } | |||
632 | ||||
633 | /* neither found a match */ | |||
634 | return 0; | |||
635 | } | |||
636 | ||||
637 | /* | |||
638 | Pack binary data into a string | |||
639 | */ | |||
640 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) char * | |||
641 | SWIG_PackData(char *c, void *ptr, size_t sz) { | |||
642 | static const char hex[17] = "0123456789abcdef"; | |||
643 | const unsigned char *u = (unsigned char *) ptr; | |||
644 | const unsigned char *eu = u + sz; | |||
645 | for (; u != eu; ++u) { | |||
646 | unsigned char uu = *u; | |||
647 | *(c++) = hex[(uu & 0xf0) >> 4]; | |||
648 | *(c++) = hex[uu & 0xf]; | |||
649 | } | |||
650 | return c; | |||
651 | } | |||
652 | ||||
653 | /* | |||
654 | Unpack binary data from a string | |||
655 | */ | |||
656 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) const char * | |||
657 | SWIG_UnpackData(const char *c, void *ptr, size_t sz) { | |||
658 | unsigned char *u = (unsigned char *) ptr; | |||
659 | const unsigned char *eu = u + sz; | |||
660 | for (; u != eu; ++u) { | |||
661 | char d = *(c++); | |||
662 | unsigned char uu; | |||
663 | if ((d >= '0') && (d <= '9')) | |||
664 | uu = (unsigned char)((d - '0') << 4); | |||
665 | else if ((d >= 'a') && (d <= 'f')) | |||
666 | uu = (unsigned char)((d - ('a'-10)) << 4); | |||
667 | else | |||
668 | return (char *) 0; | |||
669 | d = *(c++); | |||
670 | if ((d >= '0') && (d <= '9')) | |||
671 | uu |= (unsigned char)(d - '0'); | |||
672 | else if ((d >= 'a') && (d <= 'f')) | |||
673 | uu |= (unsigned char)(d - ('a'-10)); | |||
674 | else | |||
675 | return (char *) 0; | |||
676 | *u = uu; | |||
677 | } | |||
678 | return c; | |||
679 | } | |||
680 | ||||
681 | /* | |||
682 | Pack 'void *' into a string buffer. | |||
683 | */ | |||
684 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) char * | |||
685 | SWIG_PackVoidPtr(char *buff, void *ptr, const char *name, size_t bsz) { | |||
686 | char *r = buff; | |||
687 | if ((2*sizeof(void *) + 2) > bsz) return 0; | |||
688 | *(r++) = '_'; | |||
689 | r = SWIG_PackData(r,&ptr,sizeof(void *)); | |||
690 | if (strlen(name) + 1 > (bsz - (r - buff))) return 0; | |||
691 | strcpy(r,name); | |||
692 | return buff; | |||
693 | } | |||
694 | ||||
695 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) const char * | |||
696 | SWIG_UnpackVoidPtr(const char *c, void **ptr, const char *name) { | |||
697 | if (*c != '_') { | |||
698 | if (strcmp(c,"NULL") == 0) { | |||
699 | *ptr = (void *) 0; | |||
700 | return name; | |||
701 | } else { | |||
702 | return 0; | |||
703 | } | |||
704 | } | |||
705 | return SWIG_UnpackData(++c,ptr,sizeof(void *)); | |||
706 | } | |||
707 | ||||
708 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) char * | |||
709 | SWIG_PackDataName(char *buff, void *ptr, size_t sz, const char *name, size_t bsz) { | |||
710 | char *r = buff; | |||
711 | size_t lname = (name ? strlen(name) : 0); | |||
712 | if ((2*sz + 2 + lname) > bsz) return 0; | |||
713 | *(r++) = '_'; | |||
714 | r = SWIG_PackData(r,ptr,sz); | |||
715 | if (lname) { | |||
716 | strncpy(r,name,lname+1); | |||
717 | } else { | |||
718 | *r = 0; | |||
719 | } | |||
720 | return buff; | |||
721 | } | |||
722 | ||||
723 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) const char * | |||
724 | SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) { | |||
725 | if (*c != '_') { | |||
726 | if (strcmp(c,"NULL") == 0) { | |||
727 | memset(ptr,0,sz); | |||
728 | return name; | |||
729 | } else { | |||
730 | return 0; | |||
731 | } | |||
732 | } | |||
733 | return SWIG_UnpackData(++c,ptr,sz); | |||
734 | } | |||
735 | ||||
736 | #ifdef __cplusplus201402L | |||
737 | } | |||
738 | #endif | |||
739 | ||||
740 | /* ----------------------------------------------------------------------------- | |||
741 | * luarun.swg | |||
742 | * | |||
743 | * This file contains the runtime support for Lua modules | |||
744 | * and includes code for managing global variables and pointer | |||
745 | * type checking. | |||
746 | * ----------------------------------------------------------------------------- */ | |||
747 | ||||
748 | #ifdef __cplusplus201402L | |||
749 | extern "C" { | |||
750 | #endif | |||
751 | ||||
752 | #include "lua.h" | |||
753 | #include "lauxlib.h" | |||
754 | #include <stdlib.h> /* for malloc */ | |||
755 | #include <assert.h> /* for a few sanity tests */ | |||
756 | ||||
757 | /* ----------------------------------------------------------------------------- | |||
758 | * Lua flavors | |||
759 | * ----------------------------------------------------------------------------- */ | |||
760 | ||||
761 | #define SWIG_LUA_FLAVOR_LUA1 1 | |||
762 | #define SWIG_LUA_FLAVOR_ELUA2 2 | |||
763 | #define SWIG_LUA_FLAVOR_ELUAC3 3 | |||
764 | ||||
765 | #if !defined(SWIG_LUA_TARGET1) | |||
766 | # error SWIG_LUA_TARGET1 not defined | |||
767 | #endif | |||
768 | ||||
769 | #if defined(SWIG_LUA_ELUA_EMULATE) | |||
770 | ||||
771 | struct swig_elua_entry; | |||
772 | ||||
773 | typedef struct swig_elua_key { | |||
774 | int type; | |||
775 | union { | |||
776 | const char* strkey; | |||
777 | lua_Number numkey; | |||
778 | } key; | |||
779 | } swig_elua_key; | |||
780 | ||||
781 | typedef struct swig_elua_val { | |||
782 | int type; | |||
783 | union { | |||
784 | lua_Number number; | |||
785 | const struct swig_elua_entry *table; | |||
786 | const char *string; | |||
787 | lua_CFunction function; | |||
788 | struct { | |||
789 | char member; | |||
790 | long lvalue; | |||
791 | void *pvalue; | |||
792 | swig_type_info **ptype; | |||
793 | } userdata; | |||
794 | } value; | |||
795 | } swig_elua_val; | |||
796 | ||||
797 | typedef struct swig_elua_entry { | |||
798 | swig_elua_key key; | |||
799 | swig_elua_val value; | |||
800 | } swig_elua_entry; | |||
801 | ||||
802 | #define LSTRKEY(x) {LUA_TSTRING4, {.strkey = x} } | |||
803 | #define LNUMKEY(x) {LUA_TNUMBER3, {.numkey = x} } | |||
804 | #define LNILKEY {LUA_TNIL0, {.strkey = 0} } | |||
805 | ||||
806 | #define LNUMVAL(x) {LUA_TNUMBER3, {.number = x} } | |||
807 | #define LFUNCVAL(x) {LUA_TFUNCTION6, {.function = x} } | |||
808 | #define LROVAL(x) {LUA_TTABLE5, {.table = x} } | |||
809 | #define LNILVAL {LUA_TNIL0, {.string = 0} } | |||
810 | #define LSTRVAL(x) {LUA_TSTRING4, {.string = x} } | |||
811 | ||||
812 | #define LUA_REG_TYPE swig_elua_entry | |||
813 | ||||
814 | #define SWIG_LUA_ELUA_EMUL_METATABLE_KEY "__metatable" | |||
815 | ||||
816 | #define lua_pushrotable(L,p)\ | |||
817 | lua_newtable(L)lua_createtable(L, 0, 0);\ | |||
818 | assert(p)(static_cast <bool> (p) ? void (0) : __assert_fail ("p" , "mod_lua_wrap.cpp", 818, __extension__ __PRETTY_FUNCTION__) );\ | |||
819 | SWIG_Lua_elua_emulate_register(L,(swig_elua_entry*)(p)); | |||
820 | ||||
821 | #define SWIG_LUA_CONSTTAB_POINTER(B,C,D)4, (char *)B, 0, 0, (void *)C, &D\ | |||
822 | LSTRKEY(B), {LUA_TUSERDATA7, { .userdata={0,0,(void*)(C),&D} } } | |||
823 | ||||
824 | #define SWIG_LUA_CONSTTAB_BINARY(B,S,C,D)5, (char *)B, S, 0, (void *)C, &D\ | |||
825 | LSTRKEY(B), {LUA_TUSERDATA7, { .userdata={1,S,(void*)(C),&D} } } | |||
826 | #endif | |||
827 | ||||
828 | #if (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_ELUA2) || (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_ELUAC3) | |||
829 | # define SWIG_LUA_CONSTTAB_INT(B, C)1, (char *)B, (long)C, 0, 0, 0 LSTRKEY(B), LNUMVAL(C) | |||
830 | # define SWIG_LUA_CONSTTAB_FLOAT(B, C)2, (char *)B, 0, (double)C, 0, 0 LSTRKEY(B), LNUMVAL(C) | |||
831 | # define SWIG_LUA_CONSTTAB_STRING(B, C)3, (char *)B, 0, 0, (void *)C, 0 LSTRKEY(B), LSTRVAL(C) | |||
832 | # define SWIG_LUA_CONSTTAB_CHAR(B, C)6, (char *)B, (long)C, 0, 0, 0 LSTRKEY(B), LNUMVAL(C) | |||
833 | /* Those two types of constants are not supported in elua */ | |||
834 | ||||
835 | #ifndef SWIG_LUA_CONSTTAB_POINTER | |||
836 | #warning eLua does not support pointers as constants. By default, nil will be used as value | |||
837 | #define SWIG_LUA_CONSTTAB_POINTER(B,C,D)4, (char *)B, 0, 0, (void *)C, &D LSTRKEY(B), LNILVAL | |||
838 | #endif | |||
839 | ||||
840 | #ifndef SWIG_LUA_CONSTTAB_BINARY | |||
841 | #warning eLua does not support pointers to member as constants. By default, nil will be used as value | |||
842 | #define SWIG_LUA_CONSTTAB_BINARY(B, S, C, D)5, (char *)B, S, 0, (void *)C, &D LSTRKEY(B), LNILVAL | |||
843 | #endif | |||
844 | #else /* SWIG_LUA_FLAVOR_LUA */ | |||
845 | # define SWIG_LUA_CONSTTAB_INT(B, C)1, (char *)B, (long)C, 0, 0, 0 SWIG_LUA_INT1, (char *)B, (long)C, 0, 0, 0 | |||
846 | # define SWIG_LUA_CONSTTAB_FLOAT(B, C)2, (char *)B, 0, (double)C, 0, 0 SWIG_LUA_FLOAT2, (char *)B, 0, (double)C, 0, 0 | |||
847 | # define SWIG_LUA_CONSTTAB_STRING(B, C)3, (char *)B, 0, 0, (void *)C, 0 SWIG_LUA_STRING3, (char *)B, 0, 0, (void *)C, 0 | |||
848 | # define SWIG_LUA_CONSTTAB_CHAR(B, C)6, (char *)B, (long)C, 0, 0, 0 SWIG_LUA_CHAR6, (char *)B, (long)C, 0, 0, 0 | |||
849 | # define SWIG_LUA_CONSTTAB_POINTER(B,C,D)4, (char *)B, 0, 0, (void *)C, &D\ | |||
850 | SWIG_LUA_POINTER4, (char *)B, 0, 0, (void *)C, &D | |||
851 | # define SWIG_LUA_CONSTTAB_BINARY(B, S, C, D)5, (char *)B, S, 0, (void *)C, &D\ | |||
852 | SWIG_LUA_BINARY5, (char *)B, S, 0, (void *)C, &D | |||
853 | #endif | |||
854 | ||||
855 | #ifndef SWIG_LUA_ELUA_EMULATE | |||
856 | #if (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_ELUA2) || (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_ELUAC3) | |||
857 | # define LRO_STRVAL(v) {{.p = (char *) v}, LUA_TSTRING4} | |||
858 | # define LSTRVAL LRO_STRVAL | |||
859 | #endif | |||
860 | #endif /* SWIG_LUA_ELUA_EMULATE*/ | |||
861 | ||||
862 | #ifndef SWIG_LUA_ELUA_EMULATE | |||
863 | #if (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_ELUA2) || (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_ELUAC3) | |||
864 | ||||
865 | #ifndef MIN_OPT_LEVEL | |||
866 | #define MIN_OPT_LEVEL 2 | |||
867 | #endif | |||
868 | ||||
869 | #include "lrodefs.h" | |||
870 | #include "lrotable.h" | |||
871 | #endif | |||
872 | #endif /* SWIG_LUA_ELUA_EMULATE*/ | |||
873 | /* ----------------------------------------------------------------------------- | |||
874 | * compatibility defines | |||
875 | * ----------------------------------------------------------------------------- */ | |||
876 | ||||
877 | /* History of Lua C API length functions: In Lua 5.0 (and before?) | |||
878 | there was "lua_strlen". In Lua 5.1, this was renamed "lua_objlen", | |||
879 | but a compatibility define of "lua_strlen" was added. In Lua 5.2, | |||
880 | this function was again renamed, to "lua_rawlen" (to emphasize that | |||
881 | it doesn't call the "__len" metamethod), and the compatibility | |||
882 | define of lua_strlen was removed. All SWIG uses have been updated | |||
883 | to "lua_rawlen", and we add our own defines of that here for older | |||
884 | versions of Lua. */ | |||
885 | #if !defined(LUA_VERSION_NUM502) || LUA_VERSION_NUM502 < 501 | |||
886 | # define lua_rawlen lua_strlen | |||
887 | #elif LUA_VERSION_NUM502 == 501 | |||
888 | # define lua_rawlen lua_objlen | |||
889 | #endif | |||
890 | ||||
891 | ||||
892 | /* lua_pushglobaltable is the recommended "future-proof" way to get | |||
893 | the global table for Lua 5.2 and later. Here we define | |||
894 | lua_pushglobaltable ourselves for Lua versions before 5.2. */ | |||
895 | #if !defined(LUA_VERSION_NUM502) || LUA_VERSION_NUM502 < 502 | |||
896 | # define lua_pushglobaltable(L)lua_rawgeti(L, (-1000000 - 1000), 2) lua_pushvalue(L, LUA_GLOBALSINDEX) | |||
897 | #endif | |||
898 | ||||
899 | /* lua_absindex was introduced in Lua 5.2 */ | |||
900 | #if !defined(LUA_VERSION_NUM502) || LUA_VERSION_NUM502 < 502 | |||
901 | # define lua_absindex(L,i) ((i)>0 || (i) <= LUA_REGISTRYINDEX(-1000000 - 1000) ? (i) : lua_gettop(L) + (i) + 1) | |||
902 | #endif | |||
903 | ||||
904 | /* lua_rawsetp was introduced in Lua 5.2 */ | |||
905 | #if !defined(LUA_VERSION_NUM502) || LUA_VERSION_NUM502 < 502 | |||
906 | #define lua_rawsetp(L,index,ptr)\ | |||
907 | lua_pushlightuserdata(L,(void*)(ptr));\ | |||
908 | lua_insert(L,-2);\ | |||
909 | lua_rawset(L,index); | |||
910 | ||||
911 | #define lua_rawgetp(L,index,ptr)\ | |||
912 | lua_pushlightuserdata(L,(void*)(ptr));\ | |||
913 | lua_rawget(L,index); | |||
914 | ||||
915 | #endif | |||
916 | ||||
917 | /* -------------------------------------------------------------------------- | |||
918 | * Helper functions for error handling | |||
919 | * -------------------------------------------------------------------------- */ | |||
920 | ||||
921 | /* Push the string STR on the Lua stack, like lua_pushstring, but | |||
922 | prefixed with the the location of the innermost Lua call-point | |||
923 | (as formated by luaL_where). */ | |||
924 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) void | |||
925 | SWIG_Lua_pusherrstring (lua_State *L, const char *str) | |||
926 | { | |||
927 | luaL_where (L, 1); | |||
928 | lua_pushstring (L, str); | |||
929 | lua_concat (L, 2); | |||
930 | } | |||
931 | ||||
932 | /* Push a formatted string generated from FMT and following args on | |||
933 | the Lua stack, like lua_pushfstring, but prefixed with the the | |||
934 | location of the innermost Lua call-point (as formated by luaL_where). */ | |||
935 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) void | |||
936 | SWIG_Lua_pushferrstring (lua_State *L, const char *fmt, ...) | |||
937 | { | |||
938 | va_list argp; | |||
939 | va_start(argp, fmt)__builtin_va_start(argp, fmt); | |||
940 | luaL_where(L, 1); | |||
941 | lua_pushvfstring(L, fmt, argp); | |||
942 | va_end(argp)__builtin_va_end(argp); | |||
943 | lua_concat(L, 2); | |||
944 | } | |||
945 | ||||
946 | ||||
947 | /* ----------------------------------------------------------------------------- | |||
948 | * global swig types | |||
949 | * ----------------------------------------------------------------------------- */ | |||
950 | /* Constant table */ | |||
951 | #define SWIG_LUA_INT1 1 | |||
952 | #define SWIG_LUA_FLOAT2 2 | |||
953 | #define SWIG_LUA_STRING3 3 | |||
954 | #define SWIG_LUA_POINTER4 4 | |||
955 | #define SWIG_LUA_BINARY5 5 | |||
956 | #define SWIG_LUA_CHAR6 6 | |||
957 | ||||
958 | /* Structure for variable linking table */ | |||
959 | typedef struct { | |||
960 | const char *name; | |||
961 | lua_CFunction get; | |||
962 | lua_CFunction set; | |||
963 | } swig_lua_var_info; | |||
964 | ||||
965 | #if (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_ELUA2) || (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_ELUAC3) | |||
966 | typedef const LUA_REG_TYPE swig_lua_method; | |||
967 | typedef const LUA_REG_TYPE swig_lua_const_info; | |||
968 | #else /* Normal lua */ | |||
969 | typedef luaL_Reg swig_lua_method; | |||
970 | ||||
971 | /* Constant information structure */ | |||
972 | typedef struct { | |||
973 | int type; | |||
974 | char *name; | |||
975 | long lvalue; | |||
976 | double dvalue; | |||
977 | void *pvalue; | |||
978 | swig_type_info **ptype; | |||
979 | } swig_lua_const_info; | |||
980 | ||||
981 | #endif | |||
982 | ||||
983 | typedef struct { | |||
984 | const char *name; | |||
985 | lua_CFunction getmethod; | |||
986 | lua_CFunction setmethod; | |||
987 | } swig_lua_attribute; | |||
988 | ||||
989 | ||||
990 | struct swig_lua_class; | |||
991 | /* Can be used to create namespaces. Currently used to wrap class static methods/variables/constants */ | |||
992 | typedef struct swig_lua_namespace { | |||
993 | const char *name; | |||
994 | swig_lua_method *ns_methods; | |||
995 | swig_lua_attribute *ns_attributes; | |||
996 | swig_lua_const_info *ns_constants; | |||
997 | struct swig_lua_class **ns_classes; | |||
998 | struct swig_lua_namespace **ns_namespaces; | |||
999 | } swig_lua_namespace; | |||
1000 | ||||
1001 | typedef struct swig_lua_class { | |||
1002 | const char *name; /* Name that this class has in Lua */ | |||
1003 | const char *fqname; /* Fully qualified name - Scope + class name */ | |||
1004 | swig_type_info **type; | |||
1005 | lua_CFunction constructor; | |||
1006 | void (*destructor)(void *); | |||
1007 | swig_lua_method *methods; | |||
1008 | swig_lua_attribute *attributes; | |||
1009 | swig_lua_namespace *cls_static; | |||
1010 | swig_lua_method *metatable; /* 0 for -eluac */ | |||
1011 | struct swig_lua_class **bases; | |||
1012 | const char **base_names; | |||
1013 | } swig_lua_class; | |||
1014 | ||||
1015 | /* this is the struct for wrapping all pointers in SwigLua | |||
1016 | */ | |||
1017 | typedef struct { | |||
1018 | swig_type_info *type; | |||
1019 | int own; /* 1 if owned & must be destroyed */ | |||
1020 | void *ptr; | |||
1021 | } swig_lua_userdata; | |||
1022 | ||||
1023 | /* this is the struct for wrapping arbitrary packed binary data | |||
1024 | (currently it is only used for member function pointers) | |||
1025 | the data ordering is similar to swig_lua_userdata, but it is currently not possible | |||
1026 | to tell the two structures apart within SWIG, other than by looking at the type | |||
1027 | */ | |||
1028 | typedef struct { | |||
1029 | swig_type_info *type; | |||
1030 | int own; /* 1 if owned & must be destroyed */ | |||
1031 | char data[1]; /* arbitary amount of data */ | |||
1032 | } swig_lua_rawdata; | |||
1033 | ||||
1034 | /* Common SWIG API */ | |||
1035 | #define SWIG_NewPointerObj(L, ptr, type, owner)SWIG_Lua_NewPointerObj(L, (void *)ptr, type, owner) SWIG_Lua_NewPointerObj(L, (void *)ptr, type, owner) | |||
1036 | #define SWIG_ConvertPtr(L,idx, ptr, type, flags)SWIG_Lua_ConvertPtr(L,idx,ptr,type,flags) SWIG_Lua_ConvertPtr(L,idx,ptr,type,flags) | |||
1037 | #define SWIG_MustGetPtr(L,idx, type,flags, argnum,fnname)SWIG_Lua_MustGetPtr(L,idx, type,flags, argnum,fnname) SWIG_Lua_MustGetPtr(L,idx, type,flags, argnum,fnname) | |||
1038 | /* for C++ member pointers, ie, member methods */ | |||
1039 | #define SWIG_ConvertMember(L, idx, ptr, sz, ty)SWIG_Lua_ConvertPacked(L, idx, ptr, sz, ty) SWIG_Lua_ConvertPacked(L, idx, ptr, sz, ty) | |||
1040 | #define SWIG_NewMemberObj(L, ptr, sz, type)SWIG_Lua_NewPackedObj(L, ptr, sz, type) SWIG_Lua_NewPackedObj(L, ptr, sz, type) | |||
1041 | ||||
1042 | /* Runtime API */ | |||
1043 | #define SWIG_GetModule(clientdata)SWIG_Lua_GetModule((lua_State*)(clientdata)) SWIG_Lua_GetModule((lua_State*)(clientdata)) | |||
1044 | #define SWIG_SetModule(clientdata, pointer)SWIG_Lua_SetModule((lua_State*) (clientdata), pointer) SWIG_Lua_SetModule((lua_State*) (clientdata), pointer) | |||
1045 | #define SWIG_MODULE_CLIENTDATA_TYPElua_State* lua_State* | |||
1046 | ||||
1047 | /* Contract support */ | |||
1048 | #define SWIG_contract_assert(expr, msg)if (!(expr)) { SWIG_Lua_pusherrstring(L, (char *) msg); goto fail ; } else \ | |||
1049 | if (!(expr)) { SWIG_Lua_pusherrstring(L, (char *) msg); goto fail; } else | |||
1050 | ||||
1051 | ||||
1052 | /* helper #defines */ | |||
1053 | #define SWIG_fail{goto fail;} {goto fail;} | |||
1054 | #define SWIG_fail_arg(func_name,argnum,type){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , func_name,argnum,type,SWIG_Lua_typename(L,argnum)); goto fail ;} \ | |||
1055 | {SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'",\ | |||
1056 | func_name,argnum,type,SWIG_Lua_typename(L,argnum));\ | |||
1057 | goto fail;} | |||
1058 | #define SWIG_fail_ptr(func_name,argnum,type){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , func_name,argnum,(type && type->str)?type->str :"void*",SWIG_Lua_typename(L,argnum)); goto fail;} \ | |||
1059 | SWIG_fail_arg(func_name,argnum,(type && type->str)?type->str:"void*"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , func_name,argnum,(type && type->str)?type->str :"void*",SWIG_Lua_typename(L,argnum)); goto fail;} | |||
1060 | #define SWIG_check_num_args(func_name,a,b)if (lua_gettop(L)<a || lua_gettop(L)>b) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d",func_name,a,b,lua_gettop (L)); goto fail;} \ | |||
1061 | if (lua_gettop(L)<a || lua_gettop(L)>b) \ | |||
1062 | {SWIG_Lua_pushferrstring(L,"Error in %s expected %d..%d args, got %d",func_name,a,b,lua_gettop(L));\ | |||
1063 | goto fail;} | |||
1064 | ||||
1065 | ||||
1066 | #define SWIG_Lua_get_table(L,n)(lua_pushstring(L, n), lua_rawget(L,-2)) \ | |||
1067 | (lua_pushstring(L, n), lua_rawget(L,-2)) | |||
1068 | ||||
1069 | #define SWIG_Lua_add_function(L,n,f)(lua_pushstring(L, n), lua_pushcclosure(L, (f), 0), lua_rawset (L,-3)) \ | |||
1070 | (lua_pushstring(L, n), \ | |||
1071 | lua_pushcfunction(L, f)lua_pushcclosure(L, (f), 0), \ | |||
1072 | lua_rawset(L,-3)) | |||
1073 | ||||
1074 | #define SWIG_Lua_add_boolean(L,n,b)(lua_pushstring(L, n), lua_pushboolean(L, b), lua_rawset(L,-3 )) \ | |||
1075 | (lua_pushstring(L, n), \ | |||
1076 | lua_pushboolean(L, b), \ | |||
1077 | lua_rawset(L,-3)) | |||
1078 | ||||
1079 | /* special helper for allowing 'nil' for usertypes */ | |||
1080 | #define SWIG_isptrtype(L,I)(lua_isuserdata(L,I) || (lua_type(L, (I)) == 0)) (lua_isuserdata(L,I) || lua_isnil(L,I)(lua_type(L, (I)) == 0)) | |||
1081 | ||||
1082 | #ifdef __cplusplus201402L | |||
1083 | /* Special helper for member function pointers | |||
1084 | it gets the address, casts it, then dereferences it */ | |||
1085 | /*#define SWIG_mem_fn_as_voidptr(a) (*((char**)&(a))) */ | |||
1086 | #endif | |||
1087 | ||||
1088 | /* storing/access of swig_module_info */ | |||
1089 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) swig_module_info * | |||
1090 | SWIG_Lua_GetModule(lua_State *L) { | |||
1091 | swig_module_info *ret = 0; | |||
1092 | lua_pushstring(L,"swig_runtime_data_type_pointer" SWIG_RUNTIME_VERSION"4" SWIG_TYPE_TABLE_NAME); | |||
1093 | lua_rawget(L,LUA_REGISTRYINDEX(-1000000 - 1000)); | |||
1094 | if (lua_islightuserdata(L,-1)(lua_type(L, (-1)) == 2)) | |||
1095 | ret=(swig_module_info*)lua_touserdata(L,-1); | |||
1096 | lua_pop(L,1)lua_settop(L, -(1)-1); /* tidy */ | |||
1097 | return ret; | |||
1098 | } | |||
1099 | ||||
1100 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) void | |||
1101 | SWIG_Lua_SetModule(lua_State *L, swig_module_info *module) { | |||
1102 | /* add this all into the Lua registry: */ | |||
1103 | lua_pushstring(L,"swig_runtime_data_type_pointer" SWIG_RUNTIME_VERSION"4" SWIG_TYPE_TABLE_NAME); | |||
1104 | lua_pushlightuserdata(L,(void*)module); | |||
1105 | lua_rawset(L,LUA_REGISTRYINDEX(-1000000 - 1000)); | |||
1106 | } | |||
1107 | ||||
1108 | /* ----------------------------------------------------------------------------- | |||
1109 | * global variable support code: modules | |||
1110 | * ----------------------------------------------------------------------------- */ | |||
1111 | ||||
1112 | /* this function is called when trying to set an immutable. | |||
1113 | default action is to print an error. | |||
1114 | This can removed with a compile flag SWIGLUA_IGNORE_SET_IMMUTABLE */ | |||
1115 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_Lua_set_immutable(lua_State *L) | |||
1116 | { | |||
1117 | /* there should be 1 param passed in: the new value */ | |||
1118 | #ifndef SWIGLUA_IGNORE_SET_IMMUTABLE | |||
1119 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove it */ | |||
1120 | luaL_error(L,"This variable is immutable"); | |||
1121 | #endif | |||
1122 | return 0; /* should not return anything */ | |||
1123 | } | |||
1124 | ||||
1125 | #ifdef SWIG_LUA_ELUA_EMULATE | |||
1126 | ||||
1127 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) void SWIG_Lua_NewPointerObj(lua_State *L,void *ptr,swig_type_info *type, int own); | |||
1128 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) void SWIG_Lua_NewPackedObj(lua_State *L,void *ptr,size_t size,swig_type_info *type); | |||
1129 | static int swig_lua_elua_emulate_unique_key; | |||
1130 | ||||
1131 | /* This function emulates eLua rotables behaviour. It loads a rotable definition into the usual lua table. */ | |||
1132 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_elua_emulate_register(lua_State *L, const swig_elua_entry *table) | |||
1133 | { | |||
1134 | int i, table_parsed, parsed_tables_array, target_table; | |||
1135 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1135 , __extension__ __PRETTY_FUNCTION__)); | |||
1136 | target_table = lua_gettop(L); | |||
1137 | /* Get the registry where we put all parsed tables to avoid loops */ | |||
1138 | lua_rawgetp(L, LUA_REGISTRYINDEX(-1000000 - 1000), &swig_lua_elua_emulate_unique_key); | |||
1139 | if(lua_isnil(L,-1)(lua_type(L, (-1)) == 0)) { | |||
1140 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
1141 | lua_newtable(L)lua_createtable(L, 0, 0); | |||
1142 | lua_pushvalue(L,-1); | |||
1143 | lua_rawsetp(L,LUA_REGISTRYINDEX(-1000000 - 1000),(void*)(&swig_lua_elua_emulate_unique_key)); | |||
1144 | } | |||
1145 | parsed_tables_array = lua_gettop(L); | |||
1146 | lua_pushvalue(L,target_table); | |||
1147 | lua_rawsetp(L, parsed_tables_array, table); | |||
1148 | table_parsed = 0; | |||
1149 | const int SWIGUNUSED__attribute__ ((__unused__)) pairs_start = lua_gettop(L); | |||
1150 | for(i = 0;table[i].key.type != LUA_TNIL0 || table[i].value.type != LUA_TNIL0;i++) | |||
1151 | { | |||
1152 | const swig_elua_entry *entry = table + i; | |||
1153 | int is_metatable = 0; | |||
1154 | switch(entry->key.type) { | |||
1155 | case LUA_TSTRING4: | |||
1156 | lua_pushstring(L,entry->key.key.strkey); | |||
1157 | if(strcmp(entry->key.key.strkey, SWIG_LUA_ELUA_EMUL_METATABLE_KEY) == 0) | |||
1158 | is_metatable = 1; | |||
1159 | break; | |||
1160 | case LUA_TNUMBER3: | |||
1161 | lua_pushnumber(L,entry->key.key.numkey); | |||
1162 | break; | |||
1163 | case LUA_TNIL0: | |||
1164 | lua_pushnil(L); | |||
1165 | break; | |||
1166 | default: | |||
1167 | assert(0)(static_cast <bool> (0) ? void (0) : __assert_fail ("0" , "mod_lua_wrap.cpp", 1167, __extension__ __PRETTY_FUNCTION__ )); | |||
1168 | } | |||
1169 | switch(entry->value.type) { | |||
1170 | case LUA_TSTRING4: | |||
1171 | lua_pushstring(L,entry->value.value.string); | |||
1172 | break; | |||
1173 | case LUA_TNUMBER3: | |||
1174 | lua_pushnumber(L,entry->value.value.number); | |||
1175 | break; | |||
1176 | case LUA_TFUNCTION6: | |||
1177 | lua_pushcfunction(L,entry->value.value.function)lua_pushcclosure(L, (entry->value.value.function), 0); | |||
1178 | break; | |||
1179 | case LUA_TTABLE5: | |||
1180 | lua_rawgetp(L,parsed_tables_array, entry->value.value.table); | |||
1181 | table_parsed = !lua_isnil(L,-1)(lua_type(L, (-1)) == 0); | |||
1182 | if(!table_parsed) { | |||
1183 | lua_pop(L,1)lua_settop(L, -(1)-1); /*remove nil */ | |||
1184 | lua_newtable(L)lua_createtable(L, 0, 0); | |||
1185 | SWIG_Lua_elua_emulate_register(L,entry->value.value.table); | |||
1186 | } | |||
1187 | if(is_metatable) { | |||
1188 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1188 , __extension__ __PRETTY_FUNCTION__)); | |||
1189 | lua_pushvalue(L,-1); | |||
1190 | lua_setmetatable(L,target_table); | |||
1191 | } | |||
1192 | ||||
1193 | break; | |||
1194 | case LUA_TUSERDATA7: | |||
1195 | if(entry->value.value.userdata.member) | |||
1196 | SWIG_NewMemberObj(L,entry->value.value.userdata.pvalue,SWIG_Lua_NewPackedObj(L, entry->value.value.userdata.pvalue , entry->value.value.userdata.lvalue, *(entry->value.value .userdata.ptype)) | |||
1197 | entry->value.value.userdata.lvalue,SWIG_Lua_NewPackedObj(L, entry->value.value.userdata.pvalue , entry->value.value.userdata.lvalue, *(entry->value.value .userdata.ptype)) | |||
1198 | *(entry->value.value.userdata.ptype))SWIG_Lua_NewPackedObj(L, entry->value.value.userdata.pvalue , entry->value.value.userdata.lvalue, *(entry->value.value .userdata.ptype)); | |||
1199 | else | |||
1200 | SWIG_NewPointerObj(L,entry->value.value.userdata.pvalue,SWIG_Lua_NewPointerObj(L, (void *)entry->value.value.userdata .pvalue, *(entry->value.value.userdata.ptype), 0) | |||
1201 | *(entry->value.value.userdata.ptype),0)SWIG_Lua_NewPointerObj(L, (void *)entry->value.value.userdata .pvalue, *(entry->value.value.userdata.ptype), 0); | |||
1202 | break; | |||
1203 | case LUA_TNIL0: | |||
1204 | lua_pushnil(L); | |||
1205 | break; | |||
1206 | default: | |||
1207 | assert(0)(static_cast <bool> (0) ? void (0) : __assert_fail ("0" , "mod_lua_wrap.cpp", 1207, __extension__ __PRETTY_FUNCTION__ )); | |||
1208 | } | |||
1209 | assert(lua_gettop(L) == pairs_start + 2)(static_cast <bool> (lua_gettop(L) == pairs_start + 2) ? void (0) : __assert_fail ("lua_gettop(L) == pairs_start + 2" , "mod_lua_wrap.cpp", 1209, __extension__ __PRETTY_FUNCTION__ )); | |||
1210 | lua_rawset(L,target_table); | |||
1211 | } | |||
1212 | lua_pop(L,1)lua_settop(L, -(1)-1); /* Removing parsed tables storage */ | |||
1213 | assert(lua_gettop(L) == target_table)(static_cast <bool> (lua_gettop(L) == target_table) ? void (0) : __assert_fail ("lua_gettop(L) == target_table", "mod_lua_wrap.cpp" , 1213, __extension__ __PRETTY_FUNCTION__)); | |||
1214 | } | |||
1215 | ||||
1216 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_elua_emulate_register_clear(lua_State *L) | |||
1217 | { | |||
1218 | lua_pushnil(L); | |||
1219 | lua_rawsetp(L, LUA_REGISTRYINDEX(-1000000 - 1000), &swig_lua_elua_emulate_unique_key); | |||
1220 | } | |||
1221 | ||||
1222 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_get_class_registry(lua_State *L); | |||
1223 | ||||
1224 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_Lua_emulate_elua_getmetatable(lua_State *L) | |||
1225 | { | |||
1226 | SWIG_check_num_args("getmetatable(SWIG eLua emulation)", 1, 1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","getmetatable(SWIG eLua emulation)" ,1,1,lua_gettop(L)); goto fail;}; | |||
1227 | SWIG_Lua_get_class_registry(L); | |||
1228 | lua_getfield(L,-1,"lua_getmetatable"); | |||
1229 | lua_remove(L,-2); /* remove the registry*/ | |||
1230 | assert(!lua_isnil(L,-1))(static_cast <bool> (!(lua_type(L, (-1)) == 0)) ? void ( 0) : __assert_fail ("!lua_isnil(L,-1)", "mod_lua_wrap.cpp", 1230 , __extension__ __PRETTY_FUNCTION__)); | |||
1231 | lua_pushvalue(L,1); | |||
1232 | assert(lua_gettop(L) == 3)(static_cast <bool> (lua_gettop(L) == 3) ? void (0) : __assert_fail ("lua_gettop(L) == 3", "mod_lua_wrap.cpp", 1232, __extension__ __PRETTY_FUNCTION__)); /* object | function | object again */ | |||
1233 | lua_call(L,1,1)lua_callk(L, (1), (1), 0, __null); | |||
1234 | if(!lua_isnil(L,-1)(lua_type(L, (-1)) == 0)) /*There is an ordinary metatable */ | |||
1235 | return 1; | |||
1236 | /*if it is a table, then emulate elua behaviour - check for __metatable attribute of a table*/ | |||
1237 | assert(lua_gettop(L) == 2)(static_cast <bool> (lua_gettop(L) == 2) ? void (0) : __assert_fail ("lua_gettop(L) == 2", "mod_lua_wrap.cpp", 1237, __extension__ __PRETTY_FUNCTION__)); | |||
1238 | if(lua_istable(L,-2)(lua_type(L, (-2)) == 5)) { | |||
1239 | lua_pop(L,1)lua_settop(L, -(1)-1); /*remove the nil*/ | |||
1240 | lua_getfield(L,-1, SWIG_LUA_ELUA_EMUL_METATABLE_KEY); | |||
1241 | } | |||
1242 | assert(lua_gettop(L) == 2)(static_cast <bool> (lua_gettop(L) == 2) ? void (0) : __assert_fail ("lua_gettop(L) == 2", "mod_lua_wrap.cpp", 1242, __extension__ __PRETTY_FUNCTION__)); | |||
1243 | return 1; | |||
1244 | ||||
1245 | fail: | |||
1246 | lua_error(L); | |||
1247 | return 0; | |||
1248 | } | |||
1249 | ||||
1250 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_emulate_elua_swap_getmetatable(lua_State *L) | |||
1251 | { | |||
1252 | SWIG_Lua_get_class_registry(L); | |||
1253 | lua_pushglobaltable(L)lua_rawgeti(L, (-1000000 - 1000), 2); | |||
1254 | lua_pushstring(L,"lua_getmetatable"); | |||
1255 | lua_getfield(L,-2,"getmetatable"); | |||
1256 | assert(!lua_isnil(L,-1))(static_cast <bool> (!(lua_type(L, (-1)) == 0)) ? void ( 0) : __assert_fail ("!lua_isnil(L,-1)", "mod_lua_wrap.cpp", 1256 , __extension__ __PRETTY_FUNCTION__)); | |||
1257 | lua_rawset(L,-4); | |||
1258 | lua_pushstring(L, "getmetatable"); | |||
1259 | lua_pushcfunction(L, SWIG_Lua_emulate_elua_getmetatable)lua_pushcclosure(L, (SWIG_Lua_emulate_elua_getmetatable), 0); | |||
1260 | lua_rawset(L,-3); | |||
1261 | lua_pop(L,2)lua_settop(L, -(2)-1); | |||
1262 | ||||
1263 | } | |||
1264 | /* END OF REMOVE */ | |||
1265 | ||||
1266 | #endif | |||
1267 | /* ----------------------------------------------------------------------------- | |||
1268 | * global variable support code: namespaces and modules (which are the same thing) | |||
1269 | * ----------------------------------------------------------------------------- */ | |||
1270 | ||||
1271 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_Lua_namespace_get(lua_State *L) | |||
1272 | { | |||
1273 | /* there should be 2 params passed in | |||
1274 | (1) table (not the meta table) | |||
1275 | (2) string name of the attribute | |||
1276 | */ | |||
1277 | assert(lua_istable(L,-2))(static_cast <bool> ((lua_type(L, (-2)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-2)", "mod_lua_wrap.cpp", 1277 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
1278 | lua_getmetatable(L,-2); | |||
1279 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1279 , __extension__ __PRETTY_FUNCTION__)); | |||
1280 | SWIG_Lua_get_table(L,".get")(lua_pushstring(L, ".get"), lua_rawget(L,-2)); /* find the .get table */ | |||
1281 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1281 , __extension__ __PRETTY_FUNCTION__)); | |||
1282 | /* look for the key in the .get table */ | |||
1283 | lua_pushvalue(L,2); /* key */ | |||
1284 | lua_rawget(L,-2); | |||
1285 | lua_remove(L,-2); /* stack tidy, remove .get table */ | |||
1286 | if (lua_iscfunction(L,-1)) | |||
1287 | { /* found it so call the fn & return its value */ | |||
1288 | lua_call(L,0,1)lua_callk(L, (0), (1), 0, __null); /* 1 value in (userdata),1 out (result) */ | |||
1289 | lua_remove(L,-2); /* stack tidy, remove metatable */ | |||
1290 | return 1; | |||
1291 | } | |||
1292 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove whatever was there */ | |||
1293 | /* ok, so try the .fn table */ | |||
1294 | SWIG_Lua_get_table(L,".fn")(lua_pushstring(L, ".fn"), lua_rawget(L,-2)); /* find the .get table */ | |||
1295 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1295 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
1296 | lua_pushvalue(L,2); /* key */ | |||
1297 | lua_rawget(L,-2); /* look for the fn */ | |||
1298 | lua_remove(L,-2); /* stack tidy, remove .fn table */ | |||
1299 | if (lua_isfunction(L,-1)(lua_type(L, (-1)) == 6)) /* note: whether it's a C function or lua function */ | |||
1300 | { /* found it so return the fn & let lua call it */ | |||
1301 | lua_remove(L,-2); /* stack tidy, remove metatable */ | |||
1302 | return 1; | |||
1303 | } | |||
1304 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove whatever was there */ | |||
1305 | return 0; | |||
1306 | } | |||
1307 | ||||
1308 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_Lua_namespace_set(lua_State *L) | |||
1309 | { | |||
1310 | /* there should be 3 params passed in | |||
1311 | (1) table (not the meta table) | |||
1312 | (2) string name of the attribute | |||
1313 | (3) any for the new value | |||
1314 | */ | |||
1315 | ||||
1316 | assert(lua_istable(L,1))(static_cast <bool> ((lua_type(L, (1)) == 5)) ? void (0 ) : __assert_fail ("lua_istable(L,1)", "mod_lua_wrap.cpp", 1316 , __extension__ __PRETTY_FUNCTION__)); | |||
1317 | lua_getmetatable(L,1); /* get the meta table */ | |||
1318 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1318 , __extension__ __PRETTY_FUNCTION__)); | |||
1319 | ||||
1320 | SWIG_Lua_get_table(L,".set")(lua_pushstring(L, ".set"), lua_rawget(L,-2)); /* find the .set table */ | |||
1321 | if (lua_istable(L,-1)(lua_type(L, (-1)) == 5)) | |||
1322 | { | |||
1323 | /* look for the key in the .set table */ | |||
1324 | lua_pushvalue(L,2); /* key */ | |||
1325 | lua_rawget(L,-2); | |||
1326 | if (lua_iscfunction(L,-1)) | |||
1327 | { /* found it so call the fn & return its value */ | |||
1328 | lua_pushvalue(L,3); /* value */ | |||
1329 | lua_call(L,1,0)lua_callk(L, (1), (0), 0, __null); | |||
1330 | return 0; | |||
1331 | } | |||
1332 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove the value */ | |||
1333 | } | |||
1334 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove the value .set table */ | |||
1335 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remote metatable */ | |||
1336 | lua_rawset(L,-3); | |||
1337 | return 0; | |||
1338 | } | |||
1339 | ||||
1340 | #if (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_LUA1) /* In elua this is useless */ | |||
1341 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_InstallConstants(lua_State *L, swig_lua_const_info constants[]); /* forward declaration */ | |||
1342 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_add_variable(lua_State *L,const char *name,lua_CFunction getFn,lua_CFunction setFn); /* forward declaration */ | |||
1343 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_class_register(lua_State *L,swig_lua_class *clss); | |||
1344 | ||||
1345 | /* helper function - register namespace methods and attributes into namespace */ | |||
1346 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_Lua_add_namespace_details(lua_State *L, swig_lua_namespace *ns) | |||
1347 | { | |||
1348 | int i; | |||
1349 | /* There must be namespace table (not metatable) at the top of the stack */ | |||
1350 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1350 , __extension__ __PRETTY_FUNCTION__)); | |||
1351 | SWIG_Lua_InstallConstants(L, ns->ns_constants); | |||
1352 | ||||
1353 | /* add methods to the namespace/module table */ | |||
1354 | for(i=0;ns->ns_methods[i].name;i++){ | |||
1355 | SWIG_Lua_add_function(L,ns->ns_methods[i].name,ns->ns_methods[i].func)(lua_pushstring(L, ns->ns_methods[i].name), lua_pushcclosure (L, (ns->ns_methods[i].func), 0), lua_rawset(L,-3)); | |||
1356 | } | |||
1357 | lua_getmetatable(L,-1); | |||
1358 | ||||
1359 | /* add fns */ | |||
1360 | for(i=0;ns->ns_attributes[i].name;i++){ | |||
1361 | SWIG_Lua_add_variable(L,ns->ns_attributes[i].name,ns->ns_attributes[i].getmethod,ns->ns_attributes[i].setmethod); | |||
1362 | } | |||
1363 | ||||
1364 | /* clear stack - remove metatble */ | |||
1365 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
1366 | return 0; | |||
1367 | } | |||
1368 | ||||
1369 | /* Register all classes in the namespace */ | |||
1370 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_add_namespace_classes(lua_State *L, swig_lua_namespace *ns) | |||
1371 | { | |||
1372 | swig_lua_class **classes; | |||
1373 | ||||
1374 | /* There must be a module/namespace table at the top of the stack */ | |||
1375 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1375 , __extension__ __PRETTY_FUNCTION__)); | |||
1376 | ||||
1377 | classes = ns->ns_classes; | |||
1378 | ||||
1379 | if( classes != 0 ) { | |||
1380 | while(*classes != 0) { | |||
1381 | SWIG_Lua_class_register(L, *classes); | |||
1382 | classes++; | |||
1383 | } | |||
1384 | } | |||
1385 | } | |||
1386 | ||||
1387 | /* Helper function. Creates namespace table and adds it to module table | |||
1388 | if 'reg' is true, then will register namespace table to parent one (must be on top of the stack | |||
1389 | when function is called). | |||
1390 | Function always returns newly registered table on top of the stack. | |||
1391 | */ | |||
1392 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_namespace_register(lua_State *L, swig_lua_namespace *ns, int reg) | |||
1393 | { | |||
1394 | swig_lua_namespace **sub_namespace; | |||
1395 | /* 1 argument - table on the top of the stack */ | |||
1396 | const int SWIGUNUSED__attribute__ ((__unused__)) begin = lua_gettop(L); | |||
1397 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1397 , __extension__ __PRETTY_FUNCTION__)); /* just in case. This is supposed to be module table or parent namespace table */ | |||
1398 | lua_checkstack(L,5); | |||
1399 | lua_newtable(L)lua_createtable(L, 0, 0); /* namespace itself */ | |||
1400 | lua_newtable(L)lua_createtable(L, 0, 0); /* metatable for namespace */ | |||
1401 | ||||
1402 | /* add a table called ".get" */ | |||
1403 | lua_pushstring(L,".get"); | |||
1404 | lua_newtable(L)lua_createtable(L, 0, 0); | |||
1405 | lua_rawset(L,-3); | |||
1406 | /* add a table called ".set" */ | |||
1407 | lua_pushstring(L,".set"); | |||
1408 | lua_newtable(L)lua_createtable(L, 0, 0); | |||
1409 | lua_rawset(L,-3); | |||
1410 | /* add a table called ".fn" */ | |||
1411 | lua_pushstring(L,".fn"); | |||
1412 | lua_newtable(L)lua_createtable(L, 0, 0); | |||
1413 | lua_rawset(L,-3); | |||
1414 | ||||
1415 | /* add accessor fns for using the .get,.set&.fn */ | |||
1416 | SWIG_Lua_add_function(L,"__index",SWIG_Lua_namespace_get)(lua_pushstring(L, "__index"), lua_pushcclosure(L, (SWIG_Lua_namespace_get ), 0), lua_rawset(L,-3)); | |||
1417 | SWIG_Lua_add_function(L,"__newindex",SWIG_Lua_namespace_set)(lua_pushstring(L, "__newindex"), lua_pushcclosure(L, (SWIG_Lua_namespace_set ), 0), lua_rawset(L,-3)); | |||
1418 | ||||
1419 | lua_setmetatable(L,-2); /* set metatable */ | |||
1420 | ||||
1421 | /* Register all functions, variables etc */ | |||
1422 | SWIG_Lua_add_namespace_details(L,ns); | |||
1423 | /* Register classes */ | |||
1424 | SWIG_Lua_add_namespace_classes(L,ns); | |||
1425 | ||||
1426 | sub_namespace = ns->ns_namespaces; | |||
1427 | if( sub_namespace != 0) { | |||
1428 | while(*sub_namespace != 0) { | |||
1429 | SWIG_Lua_namespace_register(L, *sub_namespace, 1); | |||
1430 | lua_pop(L,1)lua_settop(L, -(1)-1); /* removing sub-namespace table */ | |||
1431 | sub_namespace++; | |||
1432 | } | |||
1433 | } | |||
1434 | ||||
1435 | if (reg) { | |||
1436 | lua_pushstring(L,ns->name); | |||
1437 | lua_pushvalue(L,-2); | |||
1438 | lua_rawset(L,-4); /* add namespace to module table */ | |||
1439 | } | |||
1440 | assert(lua_gettop(L) == begin+1)(static_cast <bool> (lua_gettop(L) == begin+1) ? void ( 0) : __assert_fail ("lua_gettop(L) == begin+1", "mod_lua_wrap.cpp" , 1440, __extension__ __PRETTY_FUNCTION__)); | |||
1441 | } | |||
1442 | #endif /* SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA */ | |||
1443 | ||||
1444 | /* ----------------------------------------------------------------------------- | |||
1445 | * global variable support code: classes | |||
1446 | * ----------------------------------------------------------------------------- */ | |||
1447 | ||||
1448 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_get_class_metatable(lua_State *L,const char *cname); | |||
1449 | ||||
1450 | typedef int (*swig_lua_base_iterator_func)(lua_State*,swig_type_info*, int, int *ret); | |||
1451 | ||||
1452 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_Lua_iterate_bases(lua_State *L, swig_type_info * SWIGUNUSED__attribute__ ((__unused__)) swig_type, | |||
1453 | int first_arg, swig_lua_base_iterator_func func, int *const ret) | |||
1454 | { | |||
1455 | /* first_arg - position of the object in stack. Everything that is above are arguments | |||
1456 | * and is passed to every evocation of the func */ | |||
1457 | int last_arg = lua_gettop(L);/* position of last argument */ | |||
1458 | int original_metatable = last_arg + 1; | |||
1459 | size_t bases_count; | |||
1460 | int result = SWIG_ERROR(-1); | |||
1461 | int bases_table; | |||
1462 | (void)swig_type; | |||
1463 | lua_getmetatable(L,first_arg); | |||
1464 | ||||
1465 | /* initialise base search */ | |||
1466 | #if (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_LUA1) | |||
1467 | SWIG_Lua_get_table(L,".bases")(lua_pushstring(L, ".bases"), lua_rawget(L,-2)); | |||
1468 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1468 , __extension__ __PRETTY_FUNCTION__)); | |||
1469 | bases_count = lua_rawlen(L,-1); | |||
1470 | bases_table = lua_gettop(L); | |||
1471 | #else | |||
1472 | /* In elua .bases table doesn't exist. Use table from swig_lua_class */ | |||
1473 | (void)bases_table; | |||
1474 | assert(swig_type!=0)(static_cast <bool> (swig_type!=0) ? void (0) : __assert_fail ("swig_type!=0", "mod_lua_wrap.cpp", 1474, __extension__ __PRETTY_FUNCTION__ )); | |||
1475 | swig_module_info *module=SWIG_GetModule(L)SWIG_Lua_GetModule((lua_State*)(L)); | |||
1476 | swig_lua_class **bases= ((swig_lua_class*)(swig_type->clientdata))->bases; | |||
1477 | const char **base_names= ((swig_lua_class*)(swig_type->clientdata))->base_names; | |||
1478 | bases_count = 0; | |||
1479 | for(;base_names[bases_count]; | |||
1480 | bases_count++);/* get length of bases */ | |||
1481 | #endif | |||
1482 | ||||
1483 | if(ret) | |||
1484 | *ret = 0; | |||
1485 | if(bases_count>0) | |||
1486 | { | |||
1487 | int to_remove; | |||
1488 | size_t i; | |||
1489 | int j; | |||
1490 | int subcall_last_arg; | |||
1491 | int subcall_first_arg = lua_gettop(L) + 1;/* Here a copy of first_arg and arguments begin */ | |||
1492 | int valid = 1; | |||
1493 | swig_type_info *base_swig_type = 0; | |||
1494 | for(j=first_arg;j<=last_arg;j++) | |||
1495 | lua_pushvalue(L,j); | |||
1496 | subcall_last_arg = lua_gettop(L); | |||
1497 | ||||
1498 | /* Trick: temporarily replacing original metatable with metatable for base class and call getter */ | |||
1499 | for(i=0;i<bases_count;i++) { | |||
1500 | /* Iteration through class bases */ | |||
1501 | #if (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_LUA1) | |||
1502 | lua_rawgeti(L,bases_table,i+1); | |||
1503 | base_swig_type = 0; | |||
1504 | if(lua_isnil(L,-1)(lua_type(L, (-1)) == 0)) { | |||
1505 | valid = 0; | |||
1506 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
1507 | } else { | |||
1508 | valid = 1; | |||
1509 | } | |||
1510 | #else /* In elua .bases table doesn't exist. Use table from swig_lua_class */ | |||
1511 | swig_lua_class *base_class = bases[i]; | |||
1512 | if(!base_class) { | |||
1513 | valid = 0; | |||
1514 | } else { | |||
1515 | valid = 1; | |||
1516 | SWIG_Lua_get_class_metatable(L,base_class->fqname); | |||
1517 | base_swig_type = SWIG_TypeQueryModule(module,module,base_names[i]); | |||
1518 | assert(base_swig_type != 0)(static_cast <bool> (base_swig_type != 0) ? void (0) : __assert_fail ("base_swig_type != 0", "mod_lua_wrap.cpp", 1518, __extension__ __PRETTY_FUNCTION__)); | |||
1519 | } | |||
1520 | #endif | |||
1521 | ||||
1522 | if(!valid) | |||
1523 | continue; | |||
1524 | assert(lua_isuserdata(L, subcall_first_arg))(static_cast <bool> (lua_isuserdata(L, subcall_first_arg )) ? void (0) : __assert_fail ("lua_isuserdata(L, subcall_first_arg)" , "mod_lua_wrap.cpp", 1524, __extension__ __PRETTY_FUNCTION__ )); | |||
1525 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1525 , __extension__ __PRETTY_FUNCTION__)); | |||
1526 | lua_setmetatable(L,subcall_first_arg); /* Set new metatable */ | |||
1527 | assert(lua_gettop(L) == subcall_last_arg)(static_cast <bool> (lua_gettop(L) == subcall_last_arg) ? void (0) : __assert_fail ("lua_gettop(L) == subcall_last_arg" , "mod_lua_wrap.cpp", 1527, __extension__ __PRETTY_FUNCTION__ )); | |||
1528 | result = func(L, base_swig_type,subcall_first_arg, ret); /* Forward call */ | |||
1529 | if(result != SWIG_ERROR(-1)) { | |||
1530 | break; | |||
1531 | } | |||
1532 | } | |||
1533 | /* Restore original metatable */ | |||
1534 | lua_pushvalue(L,original_metatable); | |||
1535 | lua_setmetatable(L,first_arg); | |||
1536 | /* Clear - remove everything between last_arg and subcall_last_arg including */ | |||
1537 | to_remove = subcall_last_arg - last_arg; | |||
1538 | for(j=0;j<to_remove;j++) | |||
1539 | lua_remove(L,last_arg+1); | |||
1540 | } else { | |||
1541 | /* Remove everything after last_arg */ | |||
1542 | lua_pop(L, lua_gettop(L) - last_arg)lua_settop(L, -(lua_gettop(L) - last_arg)-1); | |||
1543 | } | |||
1544 | if(ret) assert(lua_gettop(L) == last_arg + *ret)(static_cast <bool> (lua_gettop(L) == last_arg + *ret) ? void (0) : __assert_fail ("lua_gettop(L) == last_arg + *ret" , "mod_lua_wrap.cpp", 1544, __extension__ __PRETTY_FUNCTION__ )); | |||
1545 | return result; | |||
1546 | } | |||
1547 | ||||
1548 | /* The class.get method helper, performs the lookup of class attributes. | |||
1549 | * It returns an error code. Number of function return values is passed inside 'ret'. | |||
1550 | * first_arg is not used in this function because function always has 2 arguments. | |||
1551 | */ | |||
1552 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_Lua_class_do_get_item(lua_State *L, swig_type_info *type, int SWIGUNUSED__attribute__ ((__unused__)) first_arg, int *ret) | |||
1553 | { | |||
1554 | /* there should be 2 params passed in | |||
1555 | (1) userdata (not the meta table) | |||
1556 | (2) string name of the attribute | |||
1557 | */ | |||
1558 | int bases_search_result; | |||
1559 | int substack_start = lua_gettop(L)-2; | |||
1560 | assert(first_arg == substack_start+1)(static_cast <bool> (first_arg == substack_start+1) ? void (0) : __assert_fail ("first_arg == substack_start+1", "mod_lua_wrap.cpp" , 1560, __extension__ __PRETTY_FUNCTION__)); | |||
1561 | lua_checkstack(L,5); | |||
1562 | assert(lua_isuserdata(L,-2))(static_cast <bool> (lua_isuserdata(L,-2)) ? void (0) : __assert_fail ("lua_isuserdata(L,-2)", "mod_lua_wrap.cpp", 1562 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
1563 | lua_getmetatable(L,-2); /* get the meta table */ | |||
1564 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1564 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
1565 | /* NEW: looks for the __getitem() fn | |||
1566 | this is a user provided get fn */ | |||
1567 | SWIG_Lua_get_table(L,"__getitem")(lua_pushstring(L, "__getitem"), lua_rawget(L,-2)); /* find the __getitem fn */ | |||
1568 | if (lua_iscfunction(L,-1)) /* if its there */ | |||
1569 | { /* found it so call the fn & return its value */ | |||
1570 | lua_pushvalue(L,substack_start+1); /* the userdata */ | |||
1571 | lua_pushvalue(L,substack_start+2); /* the parameter */ | |||
1572 | lua_call(L,2,1)lua_callk(L, (2), (1), 0, __null); /* 2 value in (userdata),1 out (result) */ | |||
1573 | lua_remove(L,-2); /* stack tidy, remove metatable */ | |||
1574 | if(ret) *ret = 1; | |||
1575 | return SWIG_OK(0); | |||
1576 | } | |||
1577 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
1578 | /* Remove the metatable */ | |||
1579 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
1580 | /* Search in base classes */ | |||
1581 | bases_search_result = SWIG_Lua_iterate_bases(L,type,substack_start+1,SWIG_Lua_class_do_get_item,ret); | |||
1582 | return bases_search_result; /* sorry not known */ | |||
1583 | } | |||
1584 | ||||
1585 | ||||
1586 | /* The class.get method helper, performs the lookup of class attributes. | |||
1587 | * It returns an error code. Number of function return values is passed inside 'ret'. | |||
1588 | * first_arg is not used in this function because function always has 2 arguments. | |||
1589 | */ | |||
1590 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_Lua_class_do_get(lua_State *L, swig_type_info *type, int SWIGUNUSED__attribute__ ((__unused__)) first_arg, int *ret) | |||
1591 | { | |||
1592 | /* there should be 2 params passed in | |||
1593 | (1) userdata (not the meta table) | |||
1594 | (2) string name of the attribute | |||
1595 | */ | |||
1596 | int bases_search_result; | |||
1597 | int substack_start = lua_gettop(L)-2; | |||
1598 | assert(first_arg == substack_start+1)(static_cast <bool> (first_arg == substack_start+1) ? void (0) : __assert_fail ("first_arg == substack_start+1", "mod_lua_wrap.cpp" , 1598, __extension__ __PRETTY_FUNCTION__)); | |||
1599 | lua_checkstack(L,5); | |||
1600 | assert(lua_isuserdata(L,-2))(static_cast <bool> (lua_isuserdata(L,-2)) ? void (0) : __assert_fail ("lua_isuserdata(L,-2)", "mod_lua_wrap.cpp", 1600 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
1601 | lua_getmetatable(L,-2); /* get the meta table */ | |||
1602 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1602 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
1603 | SWIG_Lua_get_table(L,".get")(lua_pushstring(L, ".get"), lua_rawget(L,-2)); /* find the .get table */ | |||
1604 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1604 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
1605 | /* look for the key in the .get table */ | |||
1606 | lua_pushvalue(L,substack_start+2); /* key */ | |||
1607 | lua_rawget(L,-2); | |||
1608 | lua_remove(L,-2); /* stack tidy, remove .get table */ | |||
1609 | if (lua_iscfunction(L,-1)) | |||
1610 | { /* found it so call the fn & return its value */ | |||
1611 | lua_pushvalue(L,substack_start+1); /* the userdata */ | |||
1612 | lua_call(L,1,1)lua_callk(L, (1), (1), 0, __null); /* 1 value in (userdata),1 out (result) */ | |||
1613 | lua_remove(L,-2); /* stack tidy, remove metatable */ | |||
1614 | if(ret) | |||
1615 | *ret = 1; | |||
1616 | return SWIG_OK(0); | |||
1617 | } | |||
1618 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove whatever was there */ | |||
1619 | /* ok, so try the .fn table */ | |||
1620 | SWIG_Lua_get_table(L,".fn")(lua_pushstring(L, ".fn"), lua_rawget(L,-2)); /* find the .fn table */ | |||
1621 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1621 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
1622 | lua_pushvalue(L,substack_start+2); /* key */ | |||
1623 | lua_rawget(L,-2); /* look for the fn */ | |||
1624 | lua_remove(L,-2); /* stack tidy, remove .fn table */ | |||
1625 | if (lua_isfunction(L,-1)(lua_type(L, (-1)) == 6)) /* note: if its a C function or lua function */ | |||
1626 | { /* found it so return the fn & let lua call it */ | |||
1627 | lua_remove(L,-2); /* stack tidy, remove metatable */ | |||
1628 | if(ret) | |||
1629 | *ret = 1; | |||
1630 | return SWIG_OK(0); | |||
1631 | } | |||
1632 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove whatever was there */ | |||
1633 | /* Remove the metatable */ | |||
1634 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
1635 | /* Search in base classes */ | |||
1636 | bases_search_result = SWIG_Lua_iterate_bases(L,type,substack_start+1,SWIG_Lua_class_do_get,ret); | |||
1637 | return bases_search_result; /* sorry not known */ | |||
1638 | } | |||
1639 | ||||
1640 | /* the class.get method, performs the lookup of class attributes | |||
1641 | */ | |||
1642 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_Lua_class_get(lua_State *L) | |||
1643 | { | |||
1644 | /* there should be 2 params passed in | |||
1645 | (1) userdata (not the meta table) | |||
1646 | (2) string name of the attribute | |||
1647 | */ | |||
1648 | int result; | |||
1649 | swig_lua_userdata *usr; | |||
1650 | swig_type_info *type; | |||
1651 | int ret = 0; | |||
1652 | assert(lua_isuserdata(L,1))(static_cast <bool> (lua_isuserdata(L,1)) ? void (0) : __assert_fail ("lua_isuserdata(L,1)", "mod_lua_wrap.cpp", 1652, __extension__ __PRETTY_FUNCTION__)); | |||
1653 | usr=(swig_lua_userdata*)lua_touserdata(L,1); /* get data */ | |||
1654 | type = usr->type; | |||
1655 | result = SWIG_Lua_class_do_get(L,type,1,&ret); | |||
1656 | if(result == SWIG_OK(0)) | |||
1657 | return ret; | |||
1658 | ||||
1659 | result = SWIG_Lua_class_do_get_item(L,type,1,&ret); | |||
1660 | if(result == SWIG_OK(0)) | |||
1661 | return ret; | |||
1662 | ||||
1663 | return 0; | |||
1664 | } | |||
1665 | ||||
1666 | /* helper for the class.set method, performs the lookup of class attributes | |||
1667 | * It returns error code. Number of function return values is passed inside 'ret' | |||
1668 | */ | |||
1669 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_Lua_class_do_set(lua_State *L, swig_type_info *type, int first_arg, int *ret) | |||
1670 | { | |||
1671 | /* there should be 3 params passed in | |||
1672 | (1) table (not the meta table) | |||
1673 | (2) string name of the attribute | |||
1674 | (3) any for the new value | |||
1675 | */ | |||
1676 | ||||
1677 | int bases_search_result; | |||
1678 | int substack_start = lua_gettop(L) - 3; | |||
1679 | lua_checkstack(L,5); | |||
1680 | assert(lua_isuserdata(L,substack_start+1))(static_cast <bool> (lua_isuserdata(L,substack_start+1) ) ? void (0) : __assert_fail ("lua_isuserdata(L,substack_start+1)" , "mod_lua_wrap.cpp", 1680, __extension__ __PRETTY_FUNCTION__ )); /* just in case */ | |||
1681 | lua_getmetatable(L,substack_start+1); /* get the meta table */ | |||
1682 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1682 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
1683 | if(ret) | |||
1684 | *ret = 0; /* it is setter - number of return values is always 0 */ | |||
1685 | ||||
1686 | SWIG_Lua_get_table(L,".set")(lua_pushstring(L, ".set"), lua_rawget(L,-2)); /* find the .set table */ | |||
1687 | if (lua_istable(L,-1)(lua_type(L, (-1)) == 5)) | |||
1688 | { | |||
1689 | /* look for the key in the .set table */ | |||
1690 | lua_pushvalue(L,substack_start+2); /* key */ | |||
1691 | lua_rawget(L,-2); | |||
1692 | lua_remove(L,-2); /* tidy stack, remove .set table */ | |||
1693 | if (lua_iscfunction(L,-1)) | |||
1694 | { /* found it so call the fn & return its value */ | |||
1695 | lua_pushvalue(L,substack_start+1); /* userdata */ | |||
1696 | lua_pushvalue(L,substack_start+3); /* value */ | |||
1697 | lua_call(L,2,0)lua_callk(L, (2), (0), 0, __null); | |||
1698 | lua_remove(L,substack_start+4); /*remove metatable*/ | |||
1699 | return SWIG_OK(0); | |||
1700 | } | |||
1701 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove the value */ | |||
1702 | } else { | |||
1703 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove the answer for .set table request*/ | |||
1704 | } | |||
1705 | /* NEW: looks for the __setitem() fn | |||
1706 | this is a user provided set fn */ | |||
1707 | SWIG_Lua_get_table(L,"__setitem")(lua_pushstring(L, "__setitem"), lua_rawget(L,-2)); /* find the fn */ | |||
1708 | if (lua_iscfunction(L,-1)) /* if its there */ | |||
1709 | { /* found it so call the fn & return its value */ | |||
1710 | lua_pushvalue(L,substack_start+1); /* the userdata */ | |||
1711 | lua_pushvalue(L,substack_start+2); /* the parameter */ | |||
1712 | lua_pushvalue(L,substack_start+3); /* the value */ | |||
1713 | lua_call(L,3,0)lua_callk(L, (3), (0), 0, __null); /* 3 values in ,0 out */ | |||
1714 | lua_remove(L,-2); /* stack tidy, remove metatable */ | |||
1715 | return SWIG_OK(0); | |||
1716 | } | |||
1717 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove value */ | |||
1718 | ||||
1719 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove metatable */ | |||
1720 | /* Search among bases */ | |||
1721 | bases_search_result = SWIG_Lua_iterate_bases(L,type,first_arg,SWIG_Lua_class_do_set,ret); | |||
1722 | if(ret) | |||
1723 | assert(*ret == 0)(static_cast <bool> (*ret == 0) ? void (0) : __assert_fail ("*ret == 0", "mod_lua_wrap.cpp", 1723, __extension__ __PRETTY_FUNCTION__ )); | |||
1724 | assert(lua_gettop(L) == substack_start + 3)(static_cast <bool> (lua_gettop(L) == substack_start + 3 ) ? void (0) : __assert_fail ("lua_gettop(L) == substack_start + 3" , "mod_lua_wrap.cpp", 1724, __extension__ __PRETTY_FUNCTION__ )); | |||
1725 | return bases_search_result; | |||
1726 | } | |||
1727 | ||||
1728 | /* This is the actual method exported to Lua. It calls SWIG_Lua_class_do_set and correctly | |||
1729 | * handles return values. | |||
1730 | */ | |||
1731 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_Lua_class_set(lua_State *L) | |||
1732 | { | |||
1733 | /* There should be 3 params passed in | |||
1734 | (1) table (not the meta table) | |||
1735 | (2) string name of the attribute | |||
1736 | (3) any for the new value | |||
1737 | */ | |||
1738 | int ret = 0; | |||
1739 | int result; | |||
1740 | swig_lua_userdata *usr; | |||
1741 | swig_type_info *type; | |||
1742 | assert(lua_isuserdata(L,1))(static_cast <bool> (lua_isuserdata(L,1)) ? void (0) : __assert_fail ("lua_isuserdata(L,1)", "mod_lua_wrap.cpp", 1742, __extension__ __PRETTY_FUNCTION__)); | |||
1743 | usr=(swig_lua_userdata*)lua_touserdata(L,1); /* get data */ | |||
1744 | type = usr->type; | |||
1745 | result = SWIG_Lua_class_do_set(L,type,1,&ret); | |||
1746 | if(result != SWIG_OK(0)) { | |||
1747 | SWIG_Lua_pushferrstring(L,"Assignment not possible. No setter/member with this name. For custom assignments implement __setitem method."); | |||
1748 | lua_error(L); | |||
1749 | } else { | |||
1750 | assert(ret==0)(static_cast <bool> (ret==0) ? void (0) : __assert_fail ("ret==0", "mod_lua_wrap.cpp", 1750, __extension__ __PRETTY_FUNCTION__ )); | |||
1751 | } | |||
1752 | return 0; | |||
1753 | } | |||
1754 | ||||
1755 | /* the class.destruct method called by the interpreter */ | |||
1756 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_Lua_class_destruct(lua_State *L) | |||
1757 | { | |||
1758 | /* there should be 1 params passed in | |||
1759 | (1) userdata (not the meta table) */ | |||
1760 | swig_lua_userdata *usr; | |||
1761 | swig_lua_class *clss; | |||
1762 | assert(lua_isuserdata(L,-1))(static_cast <bool> (lua_isuserdata(L,-1)) ? void (0) : __assert_fail ("lua_isuserdata(L,-1)", "mod_lua_wrap.cpp", 1762 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
1763 | usr=(swig_lua_userdata*)lua_touserdata(L,-1); /* get it */ | |||
1764 | /* if must be destroyed & has a destructor */ | |||
1765 | if (usr->own) /* if must be destroyed */ | |||
1766 | { | |||
1767 | clss=(swig_lua_class*)usr->type->clientdata; /* get the class */ | |||
1768 | if (clss && clss->destructor) /* there is a destroy fn */ | |||
1769 | { | |||
1770 | clss->destructor(usr->ptr); /* bye bye */ | |||
1771 | } | |||
1772 | } | |||
1773 | return 0; | |||
1774 | } | |||
1775 | ||||
1776 | /* the class.__tostring method called by the interpreter and print */ | |||
1777 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_Lua_class_tostring(lua_State *L) | |||
1778 | { | |||
1779 | /* there should be 1 param passed in | |||
1780 | (1) userdata (not the metatable) */ | |||
1781 | const char *className; | |||
1782 | void* userData; | |||
1783 | assert(lua_isuserdata(L,1))(static_cast <bool> (lua_isuserdata(L,1)) ? void (0) : __assert_fail ("lua_isuserdata(L,1)", "mod_lua_wrap.cpp", 1783, __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
1784 | userData = lua_touserdata(L,1); /* get the userdata address for later */ | |||
1785 | lua_getmetatable(L,1); /* get the meta table */ | |||
1786 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1786 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
1787 | ||||
1788 | lua_getfield(L, -1, ".type"); | |||
1789 | className = lua_tostring(L, -1)lua_tolstring(L, (-1), __null); | |||
1790 | ||||
1791 | lua_pushfstring(L, "<%s userdata: %p>", className, userData); | |||
1792 | return 1; | |||
1793 | } | |||
1794 | ||||
1795 | /* to manually disown some userdata */ | |||
1796 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_Lua_class_disown(lua_State *L) | |||
1797 | { | |||
1798 | /* there should be 1 params passed in | |||
1799 | (1) userdata (not the meta table) */ | |||
1800 | swig_lua_userdata *usr; | |||
1801 | assert(lua_isuserdata(L,-1))(static_cast <bool> (lua_isuserdata(L,-1)) ? void (0) : __assert_fail ("lua_isuserdata(L,-1)", "mod_lua_wrap.cpp", 1801 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
1802 | usr=(swig_lua_userdata*)lua_touserdata(L,-1); /* get it */ | |||
1803 | ||||
1804 | usr->own = 0; /* clear our ownership */ | |||
1805 | return 0; | |||
1806 | } | |||
1807 | ||||
1808 | /* lua callable function to compare userdata's value | |||
1809 | the issue is that two userdata may point to the same thing | |||
1810 | but to lua, they are different objects */ | |||
1811 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) int SWIG_Lua_class_equal(lua_State *L) | |||
1812 | { | |||
1813 | int result; | |||
1814 | swig_lua_userdata *usr1,*usr2; | |||
1815 | if (!lua_isuserdata(L,1) || !lua_isuserdata(L,2)) /* just in case */ | |||
1816 | return 0; /* nil reply */ | |||
1817 | usr1=(swig_lua_userdata*)lua_touserdata(L,1); /* get data */ | |||
1818 | usr2=(swig_lua_userdata*)lua_touserdata(L,2); /* get data */ | |||
1819 | /*result=(usr1->ptr==usr2->ptr && usr1->type==usr2->type); only works if type is the same*/ | |||
1820 | result=(usr1->ptr==usr2->ptr); | |||
1821 | lua_pushboolean(L,result); | |||
1822 | return 1; | |||
1823 | } | |||
1824 | ||||
1825 | /* populate table at the top of the stack with metamethods that ought to be inherited */ | |||
1826 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_populate_inheritable_metamethods(lua_State *L) | |||
1827 | { | |||
1828 | SWIG_Lua_add_boolean(L, "__add", 1)(lua_pushstring(L, "__add"), lua_pushboolean(L, 1), lua_rawset (L,-3)); | |||
1829 | SWIG_Lua_add_boolean(L, "__sub", 1)(lua_pushstring(L, "__sub"), lua_pushboolean(L, 1), lua_rawset (L,-3)); | |||
1830 | SWIG_Lua_add_boolean(L, "__mul", 1)(lua_pushstring(L, "__mul"), lua_pushboolean(L, 1), lua_rawset (L,-3)); | |||
1831 | SWIG_Lua_add_boolean(L, "__div", 1)(lua_pushstring(L, "__div"), lua_pushboolean(L, 1), lua_rawset (L,-3)); | |||
1832 | SWIG_Lua_add_boolean(L, "__mod", 1)(lua_pushstring(L, "__mod"), lua_pushboolean(L, 1), lua_rawset (L,-3)); | |||
1833 | SWIG_Lua_add_boolean(L, "__pow", 1)(lua_pushstring(L, "__pow"), lua_pushboolean(L, 1), lua_rawset (L,-3)); | |||
1834 | SWIG_Lua_add_boolean(L, "__unm", 1)(lua_pushstring(L, "__unm"), lua_pushboolean(L, 1), lua_rawset (L,-3)); | |||
1835 | SWIG_Lua_add_boolean(L, "__len", 1 )(lua_pushstring(L, "__len"), lua_pushboolean(L, 1), lua_rawset (L,-3)); | |||
1836 | SWIG_Lua_add_boolean(L, "__concat", 1 )(lua_pushstring(L, "__concat"), lua_pushboolean(L, 1), lua_rawset (L,-3)); | |||
1837 | SWIG_Lua_add_boolean(L, "__eq", 1)(lua_pushstring(L, "__eq"), lua_pushboolean(L, 1), lua_rawset (L,-3)); | |||
1838 | SWIG_Lua_add_boolean(L, "__lt", 1)(lua_pushstring(L, "__lt"), lua_pushboolean(L, 1), lua_rawset (L,-3)); | |||
1839 | SWIG_Lua_add_boolean(L, "__le", 1)(lua_pushstring(L, "__le"), lua_pushboolean(L, 1), lua_rawset (L,-3)); | |||
1840 | SWIG_Lua_add_boolean(L, "__call", 1)(lua_pushstring(L, "__call"), lua_pushboolean(L, 1), lua_rawset (L,-3)); | |||
1841 | SWIG_Lua_add_boolean(L, "__tostring", 1)(lua_pushstring(L, "__tostring"), lua_pushboolean(L, 1), lua_rawset (L,-3)); | |||
1842 | SWIG_Lua_add_boolean(L, "__gc", 0)(lua_pushstring(L, "__gc"), lua_pushboolean(L, 0), lua_rawset (L,-3)); | |||
1843 | } | |||
1844 | ||||
1845 | /* creates the swig registry */ | |||
1846 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_create_class_registry(lua_State *L) | |||
1847 | { | |||
1848 | /* create main SWIG registry table */ | |||
1849 | lua_pushstring(L,"SWIG"); | |||
1850 | lua_newtable(L)lua_createtable(L, 0, 0); | |||
1851 | /* populate it with some predefined data */ | |||
1852 | ||||
1853 | /* .library table. Placeholder */ | |||
1854 | lua_pushstring(L,".library"); | |||
1855 | lua_newtable(L)lua_createtable(L, 0, 0); | |||
1856 | { | |||
1857 | /* list of metamethods that class inherits from its bases */ | |||
1858 | lua_pushstring(L,"inheritable_metamethods"); | |||
1859 | lua_newtable(L)lua_createtable(L, 0, 0); | |||
1860 | /* populate with list of metamethods */ | |||
1861 | SWIG_Lua_populate_inheritable_metamethods(L); | |||
1862 | lua_rawset(L,-3); | |||
1863 | } | |||
1864 | lua_rawset(L,-3); | |||
1865 | ||||
1866 | lua_rawset(L,LUA_REGISTRYINDEX(-1000000 - 1000)); | |||
1867 | } | |||
1868 | ||||
1869 | /* gets the swig registry (or creates it) */ | |||
1870 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_get_class_registry(lua_State *L) | |||
1871 | { | |||
1872 | /* add this all into the swig registry: */ | |||
1873 | lua_pushstring(L,"SWIG"); | |||
1874 | lua_rawget(L,LUA_REGISTRYINDEX(-1000000 - 1000)); /* get the registry */ | |||
1875 | if (!lua_istable(L,-1)(lua_type(L, (-1)) == 5)) /* not there */ | |||
1876 | { /* must be first time, so add it */ | |||
1877 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove the result */ | |||
1878 | SWIG_Lua_create_class_registry(L); | |||
1879 | /* then get it */ | |||
1880 | lua_pushstring(L,"SWIG"); | |||
1881 | lua_rawget(L,LUA_REGISTRYINDEX(-1000000 - 1000)); | |||
1882 | } | |||
1883 | } | |||
1884 | ||||
1885 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_get_inheritable_metamethods(lua_State *L) | |||
1886 | { | |||
1887 | SWIG_Lua_get_class_registry(L); | |||
1888 | lua_pushstring(L, ".library"); | |||
1889 | lua_rawget(L,-2); | |||
1890 | assert( !lua_isnil(L,-1) )(static_cast <bool> (!(lua_type(L, (-1)) == 0)) ? void ( 0) : __assert_fail ("!lua_isnil(L,-1)", "mod_lua_wrap.cpp", 1890 , __extension__ __PRETTY_FUNCTION__)); | |||
1891 | lua_pushstring(L, "inheritable_metamethods"); | |||
1892 | lua_rawget(L,-2); | |||
1893 | ||||
1894 | /* Remove class registry and library table */ | |||
1895 | lua_remove(L,-2); | |||
1896 | lua_remove(L,-2); | |||
1897 | } | |||
1898 | ||||
1899 | /* Helper function to get the classes metatable from the register */ | |||
1900 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_get_class_metatable(lua_State *L,const char *cname) | |||
1901 | { | |||
1902 | SWIG_Lua_get_class_registry(L); /* get the registry */ | |||
1903 | lua_pushstring(L,cname); /* get the name */ | |||
1904 | lua_rawget(L,-2); /* get it */ | |||
1905 | lua_remove(L,-2); /* tidy up (remove registry) */ | |||
1906 | } | |||
1907 | ||||
1908 | /* Set up the base classes pointers. | |||
1909 | Each class structure has a list of pointers to the base class structures. | |||
1910 | This function fills them. | |||
1911 | It cannot be done at compile time, as this will not work with hireachies | |||
1912 | spread over more than one swig file. | |||
1913 | Therefore it must be done at runtime, querying the SWIG type system. | |||
1914 | */ | |||
1915 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_init_base_class(lua_State *L,swig_lua_class *clss) | |||
1916 | { | |||
1917 | int i=0; | |||
1918 | swig_module_info *module=SWIG_GetModule(L)SWIG_Lua_GetModule((lua_State*)(L)); | |||
1919 | for(i=0;clss->base_names[i];i++) | |||
1920 | { | |||
1921 | if (clss->bases[i]==0) /* not found yet */ | |||
1922 | { | |||
1923 | /* lookup and cache the base class */ | |||
1924 | swig_type_info *info = SWIG_TypeQueryModule(module,module,clss->base_names[i]); | |||
1925 | if (info) clss->bases[i] = (swig_lua_class *) info->clientdata; | |||
1926 | } | |||
1927 | } | |||
1928 | } | |||
1929 | ||||
1930 | #if defined(SWIG_LUA_SQUASH_BASES) && (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_LUA1) | |||
1931 | /* Merges two tables */ | |||
1932 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_merge_tables_by_index(lua_State *L, int target, int source) | |||
1933 | { | |||
1934 | /* iterating */ | |||
1935 | lua_pushnil(L); | |||
1936 | while (lua_next(L,source) != 0) { | |||
1937 | /* -1 - value, -2 - index */ | |||
1938 | /* have to copy to assign */ | |||
1939 | lua_pushvalue(L,-2); /* copy of index */ | |||
1940 | lua_pushvalue(L,-2); /* copy of value */ | |||
1941 | lua_rawset(L, target); | |||
1942 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
1943 | /* only key is left */ | |||
1944 | } | |||
1945 | } | |||
1946 | ||||
1947 | /* Merges two tables with given name. original - index of target metatable, base - index of source metatable */ | |||
1948 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_merge_tables(lua_State *L, const char* name, int original, int base) | |||
1949 | { | |||
1950 | /* push original[name], then base[name] */ | |||
1951 | lua_pushstring(L,name); | |||
1952 | lua_rawget(L,original); | |||
1953 | int original_table = lua_gettop(L); | |||
1954 | lua_pushstring(L,name); | |||
1955 | lua_rawget(L,base); | |||
1956 | int base_table = lua_gettop(L); | |||
1957 | SWIG_Lua_merge_tables_by_index(L, original_table, base_table); | |||
1958 | /* clearing stack */ | |||
1959 | lua_pop(L,2)lua_settop(L, -(2)-1); | |||
1960 | } | |||
1961 | ||||
1962 | /* Function takes all symbols from base and adds it to derived class. It's just a helper. */ | |||
1963 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_class_squash_base(lua_State *L, swig_lua_class *base_cls) | |||
1964 | { | |||
1965 | /* There is one parameter - original, i.e. 'derived' class metatable */ | |||
1966 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1966 , __extension__ __PRETTY_FUNCTION__)); | |||
1967 | int original = lua_gettop(L); | |||
1968 | SWIG_Lua_get_class_metatable(L,base_cls->fqname); | |||
1969 | int base = lua_gettop(L); | |||
1970 | SWIG_Lua_merge_tables(L, ".fn", original, base ); | |||
1971 | SWIG_Lua_merge_tables(L, ".set", original, base ); | |||
1972 | SWIG_Lua_merge_tables(L, ".get", original, base ); | |||
1973 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
1974 | } | |||
1975 | ||||
1976 | /* Function squashes all symbols from 'clss' bases into itself */ | |||
1977 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_class_squash_bases(lua_State *L, swig_lua_class *clss) | |||
1978 | { | |||
1979 | int i; | |||
1980 | SWIG_Lua_get_class_metatable(L,clss->fqname); | |||
1981 | for(i=0;clss->base_names[i];i++) | |||
1982 | { | |||
1983 | if (clss->bases[i]==0) /* Somehow it's not found. Skip it */ | |||
1984 | continue; | |||
1985 | /* Thing is: all bases are already registered. Thus they have already executed | |||
1986 | * this function. So we just need to squash them into us, because their bases | |||
1987 | * are already squashed into them. No need for recursion here! | |||
1988 | */ | |||
1989 | SWIG_Lua_class_squash_base(L, clss->bases[i]); | |||
1990 | } | |||
1991 | lua_pop(L,1)lua_settop(L, -(1)-1); /*tidy stack*/ | |||
1992 | } | |||
1993 | #endif | |||
1994 | ||||
1995 | #if (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_LUA1) /* In elua this is useless */ | |||
1996 | /* helper add a variable to a registered class */ | |||
1997 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_add_variable(lua_State *L,const char *name,lua_CFunction getFn,lua_CFunction setFn) | |||
1998 | { | |||
1999 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 1999 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
2000 | SWIG_Lua_get_table(L,".get")(lua_pushstring(L, ".get"), lua_rawget(L,-2)); /* find the .get table */ | |||
2001 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 2001 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
2002 | SWIG_Lua_add_function(L,name,getFn)(lua_pushstring(L, name), lua_pushcclosure(L, (getFn), 0), lua_rawset (L,-3)); | |||
2003 | lua_pop(L,1)lua_settop(L, -(1)-1); /* tidy stack (remove table) */ | |||
2004 | if (setFn) | |||
2005 | { | |||
2006 | SWIG_Lua_get_table(L,".set")(lua_pushstring(L, ".set"), lua_rawget(L,-2)); /* find the .set table */ | |||
2007 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 2007 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
2008 | SWIG_Lua_add_function(L,name,setFn)(lua_pushstring(L, name), lua_pushcclosure(L, (setFn), 0), lua_rawset (L,-3)); | |||
2009 | lua_pop(L,1)lua_settop(L, -(1)-1); /* tidy stack (remove table) */ | |||
2010 | } | |||
2011 | } | |||
2012 | ||||
2013 | /* helper to recursively add class static details (static attributes, operations and constants) */ | |||
2014 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_add_class_static_details(lua_State *L, swig_lua_class *clss) | |||
2015 | { | |||
2016 | int i = 0; | |||
2017 | /* The class namespace table must be on the top of the stack */ | |||
2018 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 2018 , __extension__ __PRETTY_FUNCTION__)); | |||
2019 | /* call all the base classes first: we can then override these later: */ | |||
2020 | for(i=0;clss->bases[i];i++) | |||
2021 | { | |||
2022 | SWIG_Lua_add_class_static_details(L,clss->bases[i]); | |||
2023 | } | |||
2024 | ||||
2025 | SWIG_Lua_add_namespace_details(L, clss->cls_static); | |||
2026 | } | |||
2027 | ||||
2028 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_add_class_user_metamethods(lua_State *L, swig_lua_class *clss); /* forward declaration */ | |||
2029 | ||||
2030 | /* helper to recursively add class details (attributes & operations) */ | |||
2031 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_add_class_instance_details(lua_State *L, swig_lua_class *clss) | |||
2032 | { | |||
2033 | int i; | |||
2034 | size_t bases_count = 0; | |||
2035 | /* Add bases to .bases table */ | |||
2036 | SWIG_Lua_get_table(L,".bases")(lua_pushstring(L, ".bases"), lua_rawget(L,-2)); | |||
2037 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 2037 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
2038 | for(i=0;clss->bases[i];i++) | |||
2039 | { | |||
2040 | SWIG_Lua_get_class_metatable(L,clss->bases[i]->fqname); | |||
2041 | /* Base class must be already registered */ | |||
2042 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 2042 , __extension__ __PRETTY_FUNCTION__)); | |||
2043 | lua_rawseti(L,-2,i+1); /* In lua indexing starts from 1 */ | |||
2044 | bases_count++; | |||
2045 | } | |||
2046 | assert(lua_rawlen(L,-1) == bases_count)(static_cast <bool> (lua_rawlen(L,-1) == bases_count) ? void (0) : __assert_fail ("lua_rawlen(L,-1) == bases_count", "mod_lua_wrap.cpp", 2046, __extension__ __PRETTY_FUNCTION__) ); | |||
2047 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove .bases table */ | |||
2048 | /* add attributes */ | |||
2049 | for(i=0;clss->attributes[i].name;i++){ | |||
2050 | SWIG_Lua_add_variable(L,clss->attributes[i].name,clss->attributes[i].getmethod,clss->attributes[i].setmethod); | |||
2051 | } | |||
2052 | /* add methods to the metatable */ | |||
2053 | SWIG_Lua_get_table(L,".fn")(lua_pushstring(L, ".fn"), lua_rawget(L,-2)); /* find the .fn table */ | |||
2054 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 2054 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
2055 | for(i=0;clss->methods[i].name;i++){ | |||
2056 | SWIG_Lua_add_function(L,clss->methods[i].name,clss->methods[i].func)(lua_pushstring(L, clss->methods[i].name), lua_pushcclosure (L, (clss->methods[i].func), 0), lua_rawset(L,-3)); | |||
2057 | } | |||
2058 | lua_pop(L,1)lua_settop(L, -(1)-1); /* tidy stack (remove table) */ | |||
2059 | /* add operator overloads | |||
2060 | This adds methods from metatable array to metatable. Can mess up garbage | |||
2061 | collectind if someone defines __gc method | |||
2062 | */ | |||
2063 | if(clss->metatable) { | |||
2064 | for(i=0;clss->metatable[i].name;i++) { | |||
2065 | SWIG_Lua_add_function(L,clss->metatable[i].name,clss->metatable[i].func)(lua_pushstring(L, clss->metatable[i].name), lua_pushcclosure (L, (clss->metatable[i].func), 0), lua_rawset(L,-3)); | |||
2066 | } | |||
2067 | } | |||
2068 | ||||
2069 | #if !defined(SWIG_LUA_SQUASH_BASES) | |||
2070 | /* Adding metamethods that are defined in base classes. If bases were squashed | |||
2071 | * then it is obviously unnecessary | |||
2072 | */ | |||
2073 | SWIG_Lua_add_class_user_metamethods(L, clss); | |||
2074 | #endif | |||
2075 | } | |||
2076 | ||||
2077 | /* Helpers to add user defined class metamedhods - __add, __sub etc. The helpers are needed | |||
2078 | for the following issue: Lua runtime checks for metamethod existence with rawget function | |||
2079 | ignoring our SWIG-provided __index and __newindex functions. Thus our inheritance-aware method | |||
2080 | search algorithm doesn't work in such case. (Not to say that Lua runtime queries metamethod directly | |||
2081 | in metatable and not in object). | |||
2082 | Current solution is this: if somewhere in hierarchy metamethod __x is defined, then all descendants | |||
2083 | are automatically given a special proxy __x that calls the real __x method. | |||
2084 | Obvious idea - to copy __x instead of creating __x-proxy is wrong because if someone changes __x in runtime, | |||
2085 | those changes must be reflected in all descendants. | |||
2086 | */ | |||
2087 | ||||
2088 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) int SWIG_Lua_resolve_metamethod(lua_State *L); /*forward declaration*/ | |||
2089 | ||||
2090 | /* The real function that resolves a metamethod. | |||
2091 | * Function searches given class and all it's bases(recursively) for first instance of something that is | |||
2092 | * not equal to SWIG_Lua_resolve_metatmethod. (Almost always this 'something' is actual metamethod implementation | |||
2093 | * and it is a SWIG-generated C function.). It returns value on the top of the L and there is no garbage below the | |||
2094 | * answer. | |||
2095 | * Returns 1 if found, 0 otherwise. | |||
2096 | * clss is class which metatable we will search for method | |||
2097 | * metamethod_name_idx is index in L where metamethod name (as string) lies | |||
2098 | * skip_check allows to skip searching metamethod in givel clss and immideatelly go to searching in bases. skip_check | |||
2099 | * is not caried to subsequent recursive calls - false is always passed. It is set to true only at first call from | |||
2100 | * SWIG_Lua_resolve_metamethod | |||
2101 | * */ | |||
2102 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_Lua_do_resolve_metamethod(lua_State *L, const swig_lua_class *clss, int metamethod_name_idx, | |||
2103 | int skip_check) | |||
2104 | { | |||
2105 | /* This function is called recursively */ | |||
2106 | int result = 0; | |||
2107 | int i = 0; | |||
2108 | ||||
2109 | if (!skip_check) { | |||
2110 | SWIG_Lua_get_class_metatable(L, clss->fqname); | |||
2111 | lua_pushvalue(L, metamethod_name_idx); | |||
2112 | lua_rawget(L,-2); | |||
2113 | /* If this is cfunction and it is equal to SWIG_Lua_resolve_metamethod then | |||
2114 | * this isn't the function we are looking for :) | |||
2115 | * lua_tocfunction will return NULL if not cfunction | |||
2116 | */ | |||
2117 | if (!lua_isnil(L,-1)(lua_type(L, (-1)) == 0) && lua_tocfunction(L,-1) != SWIG_Lua_resolve_metamethod ) { | |||
2118 | lua_remove(L,-2); /* removing class metatable */ | |||
2119 | return 1; | |||
2120 | } | |||
2121 | lua_pop(L,2)lua_settop(L, -(2)-1); /* remove class metatable and query result */ | |||
2122 | } | |||
2123 | ||||
2124 | /* Forwarding calls to bases */ | |||
2125 | for(i=0;clss->bases[i];i++) | |||
2126 | { | |||
2127 | result = SWIG_Lua_do_resolve_metamethod(L, clss->bases[i], metamethod_name_idx, 0); | |||
2128 | if (result) | |||
2129 | break; | |||
2130 | } | |||
2131 | ||||
2132 | return result; | |||
2133 | } | |||
2134 | ||||
2135 | /* The proxy function for metamethod. All parameters are passed as cclosure. Searches for actual method | |||
2136 | * and calls it */ | |||
2137 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) int SWIG_Lua_resolve_metamethod(lua_State *L) | |||
2138 | { | |||
2139 | int numargs; | |||
2140 | int metamethod_name_idx; | |||
2141 | const swig_lua_class* clss; | |||
2142 | int result; | |||
2143 | ||||
2144 | lua_checkstack(L,5); | |||
2145 | numargs = lua_gettop(L); /* number of arguments to pass to actual metamethod */ | |||
2146 | ||||
2147 | /* Get upvalues from closure */ | |||
2148 | lua_pushvalue(L, lua_upvalueindex(1)((-1000000 - 1000) - (1))); /*Get function name*/ | |||
2149 | metamethod_name_idx = lua_gettop(L); | |||
2150 | ||||
2151 | lua_pushvalue(L, lua_upvalueindex(2)((-1000000 - 1000) - (2))); | |||
2152 | clss = (const swig_lua_class*)(lua_touserdata(L,-1)); | |||
2153 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove lightuserdata with clss from stack */ | |||
2154 | ||||
2155 | /* Actual work */ | |||
2156 | result = SWIG_Lua_do_resolve_metamethod(L, clss, metamethod_name_idx, 1); | |||
2157 | if (!result) { | |||
2158 | SWIG_Lua_pushferrstring(L,"The metamethod proxy is set, but it failed to find actual metamethod. Memory corruption is most likely explanation."); | |||
2159 | lua_error(L); | |||
2160 | return 0; | |||
2161 | } | |||
2162 | ||||
2163 | lua_remove(L,-2); /* remove metamethod key */ | |||
2164 | lua_insert(L,1); /* move function to correct position */ | |||
2165 | lua_call(L, numargs, LUA_MULTRET)lua_callk(L, (numargs), ((-1)), 0, __null); | |||
2166 | return lua_gettop(L); /* return all results */ | |||
2167 | } | |||
2168 | ||||
2169 | ||||
2170 | /* If given metamethod must be present in given class, then creates appropriate proxy | |||
2171 | * Returns 1 if successfully added, 0 if not added because no base class has it, -1 | |||
2172 | * if method is defined in the class metatable itself | |||
2173 | */ | |||
2174 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_Lua_add_class_user_metamethod(lua_State *L, swig_lua_class *clss, const int metatable_index) | |||
2175 | { | |||
2176 | int key_index; | |||
2177 | int success = 0; | |||
2178 | int i = 0; | |||
2179 | ||||
2180 | /* metamethod name - on the top of the stack */ | |||
2181 | assert(lua_isstring(L,-1))(static_cast <bool> (lua_isstring(L,-1)) ? void (0) : __assert_fail ("lua_isstring(L,-1)", "mod_lua_wrap.cpp", 2181, __extension__ __PRETTY_FUNCTION__)); | |||
2182 | ||||
2183 | key_index = lua_gettop(L); | |||
2184 | ||||
2185 | /* Check whether method is already defined in metatable */ | |||
2186 | lua_pushvalue(L,key_index); /* copy of the key */ | |||
2187 | lua_gettable(L,metatable_index); | |||
2188 | if( !lua_isnil(L,-1)(lua_type(L, (-1)) == 0) ) { | |||
2189 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
2190 | return -1; | |||
2191 | } | |||
2192 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
2193 | ||||
2194 | /* Iterating over immediate bases */ | |||
2195 | for(i=0;clss->bases[i];i++) | |||
2196 | { | |||
2197 | const swig_lua_class *base = clss->bases[i]; | |||
2198 | SWIG_Lua_get_class_metatable(L, base->fqname); | |||
2199 | lua_pushvalue(L, key_index); | |||
2200 | lua_rawget(L, -2); | |||
2201 | if( !lua_isnil(L,-1)(lua_type(L, (-1)) == 0) ) { | |||
2202 | lua_pushvalue(L, key_index); | |||
2203 | ||||
2204 | /* Add proxy function */ | |||
2205 | lua_pushvalue(L, key_index); /* first closure value is function name */ | |||
2206 | lua_pushlightuserdata(L, clss); /* second closure value is swig_lua_class structure */ | |||
2207 | lua_pushcclosure(L, SWIG_Lua_resolve_metamethod, 2); | |||
2208 | ||||
2209 | lua_rawset(L, metatable_index); | |||
2210 | success = 1; | |||
2211 | } | |||
2212 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove function or nil */ | |||
2213 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove base class metatable */ | |||
2214 | ||||
2215 | if( success ) | |||
2216 | break; | |||
2217 | } | |||
2218 | ||||
2219 | return success; | |||
2220 | } | |||
2221 | ||||
2222 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_add_class_user_metamethods(lua_State *L, swig_lua_class *clss) | |||
2223 | { | |||
2224 | int metatable_index; | |||
2225 | int metamethods_info_index; | |||
2226 | int tostring_undefined; | |||
2227 | int eq_undefined = 0; | |||
2228 | ||||
2229 | SWIG_Lua_get_class_metatable(L, clss->fqname); | |||
2230 | metatable_index = lua_gettop(L); | |||
2231 | SWIG_Lua_get_inheritable_metamethods(L); | |||
2232 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 2232 , __extension__ __PRETTY_FUNCTION__)); | |||
2233 | metamethods_info_index = lua_gettop(L); | |||
2234 | lua_pushnil(L); /* first key */ | |||
2235 | while(lua_next(L, metamethods_info_index) != 0 ) { | |||
2236 | /* key at index -2, value at index -1 */ | |||
2237 | const int is_inheritable = lua_toboolean(L,-2); | |||
2238 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove value - we don't need it anymore */ | |||
2239 | ||||
2240 | if(is_inheritable) { /* if metamethod is inheritable */ | |||
2241 | SWIG_Lua_add_class_user_metamethod(L,clss,metatable_index); | |||
2242 | } | |||
2243 | } | |||
2244 | ||||
2245 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove inheritable metatmethods table */ | |||
2246 | ||||
2247 | /* Special handling for __tostring method */ | |||
2248 | lua_pushstring(L, "__tostring"); | |||
2249 | lua_pushvalue(L,-1); | |||
2250 | lua_rawget(L,metatable_index); | |||
2251 | tostring_undefined = lua_isnil(L,-1)(lua_type(L, (-1)) == 0); | |||
2252 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
2253 | if( tostring_undefined ) { | |||
2254 | lua_pushcfunction(L, SWIG_Lua_class_tostring)lua_pushcclosure(L, (SWIG_Lua_class_tostring), 0); | |||
2255 | lua_rawset(L, metatable_index); | |||
2256 | } else { | |||
2257 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove copy of the key */ | |||
2258 | } | |||
2259 | ||||
2260 | /* Special handling for __eq method */ | |||
2261 | lua_pushstring(L, "__eq"); | |||
2262 | lua_pushvalue(L,-1); | |||
2263 | lua_rawget(L,metatable_index); | |||
2264 | eq_undefined = lua_isnil(L,-1)(lua_type(L, (-1)) == 0); | |||
2265 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
2266 | if( eq_undefined ) { | |||
2267 | lua_pushcfunction(L, SWIG_Lua_class_equal)lua_pushcclosure(L, (SWIG_Lua_class_equal), 0); | |||
2268 | lua_rawset(L, metatable_index); | |||
2269 | } else { | |||
2270 | lua_pop(L,1)lua_settop(L, -(1)-1); /* remove copy of the key */ | |||
2271 | } | |||
2272 | /* Warning: __index and __newindex are SWIG-defined. For user-defined operator[] | |||
2273 | * a __getitem/__setitem method should be defined | |||
2274 | */ | |||
2275 | lua_pop(L,1)lua_settop(L, -(1)-1); /* pop class metatable */ | |||
2276 | } | |||
2277 | ||||
2278 | /* Register class static methods,attributes etc as well as constructor proxy */ | |||
2279 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_class_register_static(lua_State *L, swig_lua_class *clss) | |||
2280 | { | |||
2281 | const int SWIGUNUSED__attribute__ ((__unused__)) begin = lua_gettop(L); | |||
2282 | lua_checkstack(L,5); /* just in case */ | |||
2283 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 2283 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
2284 | assert(strcmp(clss->name, clss->cls_static->name) == 0)(static_cast <bool> (strcmp(clss->name, clss->cls_static ->name) == 0) ? void (0) : __assert_fail ("strcmp(clss->name, clss->cls_static->name) == 0" , "mod_lua_wrap.cpp", 2284, __extension__ __PRETTY_FUNCTION__ )); /* in class those 2 must be equal */ | |||
2285 | ||||
2286 | SWIG_Lua_namespace_register(L,clss->cls_static, 1); | |||
2287 | ||||
2288 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 2288 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
2289 | ||||
2290 | /* add its constructor to module with the name of the class | |||
2291 | so you can do MyClass(...) as well as new_MyClass(...) | |||
2292 | BUT only if a constructor is defined | |||
2293 | (this overcomes the problem of pure virtual classes without constructors)*/ | |||
2294 | if (clss->constructor) | |||
2295 | { | |||
2296 | lua_getmetatable(L,-1); | |||
2297 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 2297 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
2298 | SWIG_Lua_add_function(L,"__call", clss->constructor)(lua_pushstring(L, "__call"), lua_pushcclosure(L, (clss->constructor ), 0), lua_rawset(L,-3)); | |||
2299 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
2300 | } | |||
2301 | ||||
2302 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 2302 , __extension__ __PRETTY_FUNCTION__)); /* just in case */ | |||
2303 | SWIG_Lua_add_class_static_details(L, clss); | |||
2304 | ||||
2305 | /* clear stack */ | |||
2306 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
2307 | assert( lua_gettop(L) == begin )(static_cast <bool> (lua_gettop(L) == begin) ? void (0) : __assert_fail ("lua_gettop(L) == begin", "mod_lua_wrap.cpp" , 2307, __extension__ __PRETTY_FUNCTION__)); | |||
2308 | } | |||
2309 | ||||
2310 | /* Performs the instance (non-static) class registration process. Metatable for class is created | |||
2311 | * and added to the class registry. | |||
2312 | */ | |||
2313 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_class_register_instance(lua_State *L,swig_lua_class *clss) | |||
2314 | { | |||
2315 | const int SWIGUNUSED__attribute__ ((__unused__)) begin = lua_gettop(L); | |||
2316 | int i; | |||
2317 | /* if name already there (class is already registered) then do nothing */ | |||
2318 | SWIG_Lua_get_class_registry(L); /* get the registry */ | |||
2319 | lua_pushstring(L,clss->fqname); /* get the name */ | |||
2320 | lua_rawget(L,-2); | |||
2321 | if(!lua_isnil(L,-1)(lua_type(L, (-1)) == 0)) { | |||
2322 | lua_pop(L,2)lua_settop(L, -(2)-1); | |||
2323 | assert(lua_gettop(L)==begin)(static_cast <bool> (lua_gettop(L)==begin) ? void (0) : __assert_fail ("lua_gettop(L)==begin", "mod_lua_wrap.cpp", 2323 , __extension__ __PRETTY_FUNCTION__)); | |||
2324 | return; | |||
2325 | } | |||
2326 | lua_pop(L,2)lua_settop(L, -(2)-1); /* tidy stack */ | |||
2327 | /* Recursively initialize all bases */ | |||
2328 | for(i=0;clss->bases[i];i++) | |||
2329 | { | |||
2330 | SWIG_Lua_class_register_instance(L,clss->bases[i]); | |||
2331 | } | |||
2332 | /* Again, get registry and push name */ | |||
2333 | SWIG_Lua_get_class_registry(L); /* get the registry */ | |||
2334 | lua_pushstring(L,clss->fqname); /* get the name */ | |||
2335 | lua_newtable(L)lua_createtable(L, 0, 0); /* create the metatable */ | |||
2336 | #if defined(SWIG_LUA_SQUASH_BASES) && (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_LUA1) | |||
2337 | /* If squashing is requested, then merges all bases metatable into this one. | |||
2338 | * It would get us all special methods: __getitem, __add etc. | |||
2339 | * This would set .fn, .type, and other .xxx incorrectly, but we will overwrite it right away | |||
2340 | */ | |||
2341 | { | |||
2342 | int new_metatable_index = lua_absindex(L,-1); | |||
2343 | for(i=0;clss->bases[i];i++) | |||
2344 | { | |||
2345 | int base_metatable; | |||
2346 | SWIG_Lua_get_class_metatable(L,clss->bases[i]->fqname); | |||
2347 | base_metatable = lua_absindex(L,-1); | |||
2348 | SWIG_Lua_merge_tables_by_index(L,new_metatable_index, base_metatable); | |||
2349 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
2350 | } | |||
2351 | } | |||
2352 | /* And now we will overwrite all incorrectly set data */ | |||
2353 | #endif | |||
2354 | /* add string of class name called ".type" */ | |||
2355 | lua_pushstring(L,".type"); | |||
2356 | lua_pushstring(L,clss->fqname); | |||
2357 | lua_rawset(L,-3); | |||
2358 | /* add a table called bases */ | |||
2359 | lua_pushstring(L,".bases"); | |||
2360 | lua_newtable(L)lua_createtable(L, 0, 0); | |||
2361 | lua_rawset(L,-3); | |||
2362 | /* add a table called ".get" */ | |||
2363 | lua_pushstring(L,".get"); | |||
2364 | lua_newtable(L)lua_createtable(L, 0, 0); | |||
2365 | lua_rawset(L,-3); | |||
2366 | /* add a table called ".set" */ | |||
2367 | lua_pushstring(L,".set"); | |||
2368 | lua_newtable(L)lua_createtable(L, 0, 0); | |||
2369 | lua_rawset(L,-3); | |||
2370 | /* add a table called ".fn" */ | |||
2371 | lua_pushstring(L,".fn"); | |||
2372 | lua_newtable(L)lua_createtable(L, 0, 0); | |||
2373 | /* add manual disown method */ | |||
2374 | SWIG_Lua_add_function(L,"__disown",SWIG_Lua_class_disown)(lua_pushstring(L, "__disown"), lua_pushcclosure(L, (SWIG_Lua_class_disown ), 0), lua_rawset(L,-3)); | |||
2375 | lua_rawset(L,-3); | |||
2376 | /* add accessor fns for using the .get,.set&.fn */ | |||
2377 | SWIG_Lua_add_function(L,"__index",SWIG_Lua_class_get)(lua_pushstring(L, "__index"), lua_pushcclosure(L, (SWIG_Lua_class_get ), 0), lua_rawset(L,-3)); | |||
2378 | SWIG_Lua_add_function(L,"__newindex",SWIG_Lua_class_set)(lua_pushstring(L, "__newindex"), lua_pushcclosure(L, (SWIG_Lua_class_set ), 0), lua_rawset(L,-3)); | |||
2379 | SWIG_Lua_add_function(L,"__gc",SWIG_Lua_class_destruct)(lua_pushstring(L, "__gc"), lua_pushcclosure(L, (SWIG_Lua_class_destruct ), 0), lua_rawset(L,-3)); | |||
2380 | /* add it */ | |||
2381 | lua_rawset(L,-3); /* metatable into registry */ | |||
2382 | lua_pop(L,1)lua_settop(L, -(1)-1); /* tidy stack (remove registry) */ | |||
2383 | assert(lua_gettop(L) == begin)(static_cast <bool> (lua_gettop(L) == begin) ? void (0) : __assert_fail ("lua_gettop(L) == begin", "mod_lua_wrap.cpp" , 2383, __extension__ __PRETTY_FUNCTION__)); | |||
2384 | ||||
2385 | #if defined(SWIG_LUA_SQUASH_BASES) && (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_LUA1) | |||
2386 | /* Now merge all symbols from .fn, .set, .get etc from bases to our tables */ | |||
2387 | SWIG_Lua_class_squash_bases(L,clss); | |||
2388 | #endif | |||
2389 | SWIG_Lua_get_class_metatable(L,clss->fqname); | |||
2390 | SWIG_Lua_add_class_instance_details(L,clss); /* recursive adding of details (atts & ops) */ | |||
2391 | lua_pop(L,1)lua_settop(L, -(1)-1); /* tidy stack (remove class metatable) */ | |||
2392 | assert( lua_gettop(L) == begin )(static_cast <bool> (lua_gettop(L) == begin) ? void (0) : __assert_fail ("lua_gettop(L) == begin", "mod_lua_wrap.cpp" , 2392, __extension__ __PRETTY_FUNCTION__)); | |||
2393 | } | |||
2394 | ||||
2395 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_class_register(lua_State *L,swig_lua_class *clss) | |||
2396 | { | |||
2397 | int SWIGUNUSED__attribute__ ((__unused__)) begin; | |||
2398 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 2398 , __extension__ __PRETTY_FUNCTION__)); /* This is a table (module or namespace) where classes will be added */ | |||
2399 | SWIG_Lua_class_register_instance(L,clss); | |||
2400 | SWIG_Lua_class_register_static(L,clss); | |||
2401 | ||||
2402 | /* Add links from static part to instance part and vice versa */ | |||
2403 | /* [SWIG registry] [Module] | |||
2404 | * "MyClass" ----> [MyClass metatable] <===== "MyClass" -+> [static part] | |||
2405 | * ".get" ----> ... | | getmetatable()----| | |||
2406 | * ".set" ----> ... | | | | |||
2407 | * ".static" --------------)----------------/ [static part metatable] | |||
2408 | * | ".get" --> ... | |||
2409 | * | ".set" --> .... | |||
2410 | * |=============================== ".instance" | |||
2411 | */ | |||
2412 | begin = lua_gettop(L); | |||
2413 | lua_pushstring(L,clss->cls_static->name); | |||
2414 | lua_rawget(L,-2); /* get class static table */ | |||
2415 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 2415 , __extension__ __PRETTY_FUNCTION__)); | |||
2416 | lua_getmetatable(L,-1); | |||
2417 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 2417 , __extension__ __PRETTY_FUNCTION__)); /* get class static metatable */ | |||
2418 | lua_pushstring(L,".instance"); /* prepare key */ | |||
2419 | ||||
2420 | SWIG_Lua_get_class_metatable(L,clss->fqname); /* get class metatable */ | |||
2421 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 2421 , __extension__ __PRETTY_FUNCTION__)); | |||
2422 | lua_pushstring(L,".static"); /* prepare key */ | |||
2423 | lua_pushvalue(L, -4); /* push static class TABLE */ | |||
2424 | assert(lua_istable(L,-1))(static_cast <bool> ((lua_type(L, (-1)) == 5)) ? void ( 0) : __assert_fail ("lua_istable(L,-1)", "mod_lua_wrap.cpp", 2424 , __extension__ __PRETTY_FUNCTION__)); | |||
2425 | lua_rawset(L,-3); /* assign static class table(!NOT metatable) as ".static" member of class metatable */ | |||
2426 | lua_rawset(L,-3); /* assign class metatable as ".instance" member of class static METATABLE */ | |||
2427 | lua_pop(L,2)lua_settop(L, -(2)-1); | |||
2428 | assert(lua_gettop(L) == begin)(static_cast <bool> (lua_gettop(L) == begin) ? void (0) : __assert_fail ("lua_gettop(L) == begin", "mod_lua_wrap.cpp" , 2428, __extension__ __PRETTY_FUNCTION__)); | |||
2429 | } | |||
2430 | #endif /* SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA */ | |||
2431 | ||||
2432 | #if (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_ELUA2) || (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_ELUAC3) | |||
2433 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_elua_class_register_instance(lua_State *L, swig_lua_class *clss) | |||
2434 | { | |||
2435 | const int SWIGUNUSED__attribute__ ((__unused__)) begin = lua_gettop(L); | |||
2436 | int i; | |||
2437 | /* if name already there (class is already registered) then do nothing */ | |||
2438 | SWIG_Lua_get_class_registry(L); /* get the registry */ | |||
2439 | lua_pushstring(L,clss->fqname); /* get the name */ | |||
2440 | lua_rawget(L,-2); | |||
2441 | if(!lua_isnil(L,-1)(lua_type(L, (-1)) == 0)) { | |||
2442 | lua_pop(L,2)lua_settop(L, -(2)-1); | |||
2443 | assert(lua_gettop(L)==begin)(static_cast <bool> (lua_gettop(L)==begin) ? void (0) : __assert_fail ("lua_gettop(L)==begin", "mod_lua_wrap.cpp", 2443 , __extension__ __PRETTY_FUNCTION__)); | |||
2444 | return; | |||
2445 | } | |||
2446 | lua_pop(L,2)lua_settop(L, -(2)-1); /* tidy stack */ | |||
2447 | /* Recursively initialize all bases */ | |||
2448 | for(i=0;clss->bases[i];i++) | |||
2449 | { | |||
2450 | SWIG_Lua_elua_class_register_instance(L,clss->bases[i]); | |||
2451 | } | |||
2452 | /* Again, get registry and push name */ | |||
2453 | SWIG_Lua_get_class_registry(L); /* get the registry */ | |||
2454 | lua_pushstring(L,clss->fqname); /* get the name */ | |||
2455 | assert(clss->metatable)(static_cast <bool> (clss->metatable) ? void (0) : __assert_fail ("clss->metatable", "mod_lua_wrap.cpp", 2455, __extension__ __PRETTY_FUNCTION__)); | |||
2456 | lua_pushrotable(L, (void*)(clss->metatable)); /* create the metatable */ | |||
2457 | lua_rawset(L,-3); | |||
2458 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
2459 | assert(lua_gettop(L) == begin)(static_cast <bool> (lua_gettop(L) == begin) ? void (0) : __assert_fail ("lua_gettop(L) == begin", "mod_lua_wrap.cpp" , 2459, __extension__ __PRETTY_FUNCTION__)); | |||
2460 | } | |||
2461 | #endif /* elua && eluac */ | |||
2462 | ||||
2463 | /* ----------------------------------------------------------------------------- | |||
2464 | * Class/structure conversion fns | |||
2465 | * ----------------------------------------------------------------------------- */ | |||
2466 | ||||
2467 | /* helper to add metatable to new lua object */ | |||
2468 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_Lua_AddMetatable(lua_State *L,swig_type_info *type) | |||
2469 | { | |||
2470 | if (type->clientdata) /* there is clientdata: so add the metatable */ | |||
2471 | { | |||
2472 | SWIG_Lua_get_class_metatable(L,((swig_lua_class*)(type->clientdata))->fqname); | |||
2473 | if (lua_istable(L,-1)(lua_type(L, (-1)) == 5)) | |||
2474 | { | |||
2475 | lua_setmetatable(L,-2); | |||
2476 | } | |||
2477 | else | |||
2478 | { | |||
2479 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
2480 | } | |||
2481 | } | |||
2482 | } | |||
2483 | ||||
2484 | /* pushes a new object into the lua stack */ | |||
2485 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) void SWIG_Lua_NewPointerObj(lua_State *L,void *ptr,swig_type_info *type, int own) | |||
2486 | { | |||
2487 | swig_lua_userdata *usr; | |||
2488 | if (!ptr){ | |||
2489 | lua_pushnil(L); | |||
2490 | return; | |||
2491 | } | |||
2492 | usr=(swig_lua_userdata*)lua_newuserdata(L,sizeof(swig_lua_userdata)); /* get data */ | |||
2493 | usr->ptr=ptr; /* set the ptr */ | |||
2494 | usr->type=type; | |||
2495 | usr->own=own; | |||
2496 | #if (SWIG_LUA_TARGET1 != SWIG_LUA_FLAVOR_ELUAC3) | |||
2497 | SWIG_Lua_AddMetatable(L,type); /* add metatable */ | |||
2498 | #endif | |||
2499 | } | |||
2500 | ||||
2501 | /* takes a object from the lua stack & converts it into an object of the correct type | |||
2502 | (if possible) */ | |||
2503 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) int SWIG_Lua_ConvertPtr(lua_State *L,int index,void **ptr,swig_type_info *type,int flags) | |||
2504 | { | |||
2505 | swig_lua_userdata *usr; | |||
2506 | swig_cast_info *cast; | |||
2507 | if (lua_isnil(L,index)(lua_type(L, (index)) == 0)){*ptr=0; return SWIG_OK(0);} /* special case: lua nil => NULL pointer */ | |||
2508 | usr=(swig_lua_userdata*)lua_touserdata(L,index); /* get data */ | |||
2509 | if (usr) | |||
2510 | { | |||
2511 | if (flags & SWIG_POINTER_DISOWN0x1) /* must disown the object */ | |||
2512 | { | |||
2513 | usr->own=0; | |||
2514 | } | |||
2515 | if (!type) /* special cast void*, no casting fn */ | |||
2516 | { | |||
2517 | *ptr=usr->ptr; | |||
2518 | return SWIG_OK(0); /* ok */ | |||
2519 | } | |||
2520 | cast=SWIG_TypeCheckStruct(usr->type,type); /* performs normal type checking */ | |||
2521 | if (cast) | |||
2522 | { | |||
2523 | int newmemory = 0; | |||
2524 | *ptr=SWIG_TypeCast(cast,usr->ptr,&newmemory); | |||
2525 | assert(!newmemory)(static_cast <bool> (!newmemory) ? void (0) : __assert_fail ("!newmemory", "mod_lua_wrap.cpp", 2525, __extension__ __PRETTY_FUNCTION__ )); /* newmemory handling not yet implemented */ | |||
2526 | return SWIG_OK(0); /* ok */ | |||
2527 | } | |||
2528 | } | |||
2529 | return SWIG_ERROR(-1); /* error */ | |||
2530 | } | |||
2531 | ||||
2532 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) void* SWIG_Lua_MustGetPtr(lua_State *L,int index,swig_type_info *type,int flags, | |||
2533 | int argnum,const char *func_name){ | |||
2534 | void *result; | |||
2535 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,index,&result,type,flags))(SWIG_Lua_ConvertPtr(L,index,&result,type,flags) >= 0)){ | |||
2536 | luaL_error (L,"Error in %s, expected a %s at argument number %d\n", | |||
2537 | func_name,(type && type->str)?type->str:"void*",argnum); | |||
2538 | } | |||
2539 | return result; | |||
2540 | } | |||
2541 | ||||
2542 | /* pushes a packed userdata. user for member fn pointers only */ | |||
2543 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) void SWIG_Lua_NewPackedObj(lua_State *L,void *ptr,size_t size,swig_type_info *type) | |||
2544 | { | |||
2545 | swig_lua_rawdata *raw; | |||
2546 | assert(ptr)(static_cast <bool> (ptr) ? void (0) : __assert_fail ("ptr" , "mod_lua_wrap.cpp", 2546, __extension__ __PRETTY_FUNCTION__ )); /* not acceptable to pass in a NULL value */ | |||
2547 | raw=(swig_lua_rawdata*)lua_newuserdata(L,sizeof(swig_lua_rawdata)-1+size); /* alloc data */ | |||
2548 | raw->type=type; | |||
2549 | raw->own=0; | |||
2550 | memcpy(raw->data,ptr,size); /* copy the data */ | |||
2551 | SWIG_Lua_AddMetatable(L,type); /* add metatable */ | |||
2552 | } | |||
2553 | ||||
2554 | /* converts a packed userdata. user for member fn pointers only */ | |||
2555 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) int SWIG_Lua_ConvertPacked(lua_State *L,int index,void *ptr,size_t size,swig_type_info *type) | |||
2556 | { | |||
2557 | swig_lua_rawdata *raw; | |||
2558 | raw=(swig_lua_rawdata*)lua_touserdata(L,index); /* get data */ | |||
2559 | if (!raw) return SWIG_ERROR(-1); /* error */ | |||
2560 | if (type==0 || type==raw->type) /* void* or identical type */ | |||
2561 | { | |||
2562 | memcpy(ptr,raw->data,size); /* copy it */ | |||
2563 | return SWIG_OK(0); /* ok */ | |||
2564 | } | |||
2565 | return SWIG_ERROR(-1); /* error */ | |||
2566 | } | |||
2567 | ||||
2568 | /* a function to get the typestring of a piece of data */ | |||
2569 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) const char *SWIG_Lua_typename(lua_State *L, int tp) | |||
2570 | { | |||
2571 | swig_lua_userdata *usr; | |||
2572 | if (lua_isuserdata(L,tp)) | |||
2573 | { | |||
2574 | usr=(swig_lua_userdata*)lua_touserdata(L,tp); /* get data */ | |||
2575 | if (usr && usr->type && usr->type->str) | |||
2576 | return usr->type->str; | |||
2577 | return "userdata (unknown type)"; | |||
2578 | } | |||
2579 | return lua_typename(L,lua_type(L,tp)); | |||
2580 | } | |||
2581 | ||||
2582 | /* lua callable function to get the userdata's type */ | |||
2583 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) int SWIG_Lua_type(lua_State *L) | |||
2584 | { | |||
2585 | lua_pushstring(L,SWIG_Lua_typename(L,1)); | |||
2586 | return 1; | |||
2587 | } | |||
2588 | ||||
2589 | /* ----------------------------------------------------------------------------- | |||
2590 | * global variable support code: class/struct typemap functions | |||
2591 | * ----------------------------------------------------------------------------- */ | |||
2592 | ||||
2593 | #if ((SWIG_LUA_TARGET1 != SWIG_LUA_FLAVOR_ELUA2) && (SWIG_LUA_TARGET1 != SWIG_LUA_FLAVOR_ELUAC3)) | |||
2594 | /* Install Constants */ | |||
2595 | SWIGINTERNstatic __attribute__ ((__unused__)) void | |||
2596 | SWIG_Lua_InstallConstants(lua_State *L, swig_lua_const_info constants[]) { | |||
2597 | int i; | |||
2598 | for (i = 0; constants[i].type; i++) { | |||
2599 | switch(constants[i].type) { | |||
2600 | case SWIG_LUA_INT1: | |||
2601 | lua_pushstring(L,constants[i].name); | |||
2602 | lua_pushinteger(L,(lua_Number)constants[i].lvalue); | |||
2603 | lua_rawset(L,-3); | |||
2604 | break; | |||
2605 | case SWIG_LUA_FLOAT2: | |||
2606 | lua_pushstring(L,constants[i].name); | |||
2607 | lua_pushnumber(L,(lua_Number)constants[i].dvalue); | |||
2608 | lua_rawset(L,-3); | |||
2609 | break; | |||
2610 | case SWIG_LUA_CHAR6: | |||
2611 | lua_pushstring(L,constants[i].name); | |||
2612 | { | |||
2613 | char c = constants[i].lvalue; | |||
2614 | lua_pushlstring(L,&c,1); | |||
2615 | } | |||
2616 | lua_rawset(L,-3); | |||
2617 | break; | |||
2618 | case SWIG_LUA_STRING3: | |||
2619 | lua_pushstring(L,constants[i].name); | |||
2620 | lua_pushstring(L,(char *) constants[i].pvalue); | |||
2621 | lua_rawset(L,-3); | |||
2622 | break; | |||
2623 | case SWIG_LUA_POINTER4: | |||
2624 | lua_pushstring(L,constants[i].name); | |||
2625 | SWIG_NewPointerObj(L,constants[i].pvalue, *(constants[i]).ptype,0)SWIG_Lua_NewPointerObj(L, (void *)constants[i].pvalue, *(constants [i]).ptype, 0); | |||
2626 | lua_rawset(L,-3); | |||
2627 | break; | |||
2628 | case SWIG_LUA_BINARY5: | |||
2629 | lua_pushstring(L,constants[i].name); | |||
2630 | SWIG_NewMemberObj(L,constants[i].pvalue,constants[i].lvalue,*(constants[i]).ptype)SWIG_Lua_NewPackedObj(L, constants[i].pvalue, constants[i].lvalue , *(constants[i]).ptype); | |||
2631 | lua_rawset(L,-3); | |||
2632 | break; | |||
2633 | default: | |||
2634 | break; | |||
2635 | } | |||
2636 | } | |||
2637 | } | |||
2638 | #endif | |||
2639 | ||||
2640 | /* ----------------------------------------------------------------------------- | |||
2641 | * executing lua code from within the wrapper | |||
2642 | * ----------------------------------------------------------------------------- */ | |||
2643 | ||||
2644 | #ifndef SWIG_DOSTRING_FAIL /* Allows redefining of error function */ | |||
2645 | #define SWIG_DOSTRING_FAIL(S)fprintf(stderr,"%s\n",S) fprintf(stderrstderr,"%s\n",S) | |||
2646 | #endif | |||
2647 | /* Executes a C string in Lua which is a really simple way of calling lua from C | |||
2648 | Unfortunately lua keeps changing its APIs, so we need a conditional compile | |||
2649 | In lua 5.0.X it's lua_dostring() | |||
2650 | In lua 5.1.X it's luaL_dostring() | |||
2651 | */ | |||
2652 | SWIGINTERNstatic __attribute__ ((__unused__)) int | |||
2653 | SWIG_Lua_dostring(lua_State *L, const char *str) { | |||
2654 | int ok,top; | |||
2655 | if (str==0 || str[0]==0) return 0; /* nothing to do */ | |||
2656 | top=lua_gettop(L); /* save stack */ | |||
2657 | #if (defined(LUA_VERSION_NUM502) && (LUA_VERSION_NUM502>=501)) | |||
2658 | ok=luaL_dostring(L,str)(luaL_loadstring(L, str) || lua_pcallk(L, (0), ((-1)), (0), 0 , __null)); /* looks like this is lua 5.1.X or later, good */ | |||
2659 | #else | |||
2660 | ok=lua_dostring(L,str); /* might be lua 5.0.x, using lua_dostring */ | |||
2661 | #endif | |||
2662 | if (ok!=0) { | |||
2663 | SWIG_DOSTRING_FAIL(lua_tostring(L,-1))fprintf(stderr,"%s\n",lua_tolstring(L, (-1), __null)); | |||
2664 | } | |||
2665 | lua_settop(L,top); /* restore the stack */ | |||
2666 | return ok; | |||
2667 | } | |||
2668 | ||||
2669 | #ifdef __cplusplus201402L | |||
2670 | } | |||
2671 | #endif | |||
2672 | ||||
2673 | /* ------------------------------ end luarun.swg ------------------------------ */ | |||
2674 | ||||
2675 | ||||
2676 | /* -------- TYPES TABLE (BEGIN) -------- */ | |||
2677 | ||||
2678 | #define SWIGTYPE_p_APIswig_types[0] swig_types[0] | |||
2679 | #define SWIGTYPE_p_CoreSessionswig_types[1] swig_types[1] | |||
2680 | #define SWIGTYPE_p_DTMFswig_types[2] swig_types[2] | |||
2681 | #define SWIGTYPE_p_Eventswig_types[3] swig_types[3] | |||
2682 | #define SWIGTYPE_p_EventConsumerswig_types[4] swig_types[4] | |||
2683 | #define SWIGTYPE_p_IVRMenuswig_types[5] swig_types[5] | |||
2684 | #define SWIGTYPE_p_LUA__Dbhswig_types[6] swig_types[6] | |||
2685 | #define SWIGTYPE_p_LUA__JSONswig_types[7] swig_types[7] | |||
2686 | #define SWIGTYPE_p_LUA__Sessionswig_types[8] swig_types[8] | |||
2687 | #define SWIGTYPE_p_SWIGLUA_FNswig_types[9] swig_types[9] | |||
2688 | #define SWIGTYPE_p_Streamswig_types[10] swig_types[10] | |||
2689 | #define SWIGTYPE_p_input_callback_stateswig_types[11] swig_types[11] | |||
2690 | #define SWIGTYPE_p_intswig_types[12] swig_types[12] | |||
2691 | #define SWIGTYPE_p_lua_Stateswig_types[13] swig_types[13] | |||
2692 | #define SWIGTYPE_p_p_switch_event_node_tswig_types[14] swig_types[14] | |||
2693 | #define SWIGTYPE_p_session_flag_tswig_types[15] swig_types[15] | |||
2694 | #define SWIGTYPE_p_std__stringswig_types[16] swig_types[16] | |||
2695 | #define SWIGTYPE_p_switch_call_cause_tswig_types[17] swig_types[17] | |||
2696 | #define SWIGTYPE_p_switch_channel_state_tswig_types[18] swig_types[18] | |||
2697 | #define SWIGTYPE_p_switch_channel_tswig_types[19] swig_types[19] | |||
2698 | #define SWIGTYPE_p_switch_core_session_tswig_types[20] swig_types[20] | |||
2699 | #define SWIGTYPE_p_switch_event_tswig_types[21] swig_types[21] | |||
2700 | #define SWIGTYPE_p_switch_event_types_tswig_types[22] swig_types[22] | |||
2701 | #define SWIGTYPE_p_switch_input_args_tswig_types[23] swig_types[23] | |||
2702 | #define SWIGTYPE_p_switch_input_type_tswig_types[24] swig_types[24] | |||
2703 | #define SWIGTYPE_p_switch_priority_tswig_types[25] swig_types[25] | |||
2704 | #define SWIGTYPE_p_switch_queue_tswig_types[26] swig_types[26] | |||
2705 | #define SWIGTYPE_p_switch_state_handler_table_tswig_types[27] swig_types[27] | |||
2706 | #define SWIGTYPE_p_switch_status_tswig_types[28] swig_types[28] | |||
2707 | #define SWIGTYPE_p_switch_stream_handle_tswig_types[29] swig_types[29] | |||
2708 | #define SWIGTYPE_p_uint32_tswig_types[30] swig_types[30] | |||
2709 | #define SWIGTYPE_p_voidswig_types[31] swig_types[31] | |||
2710 | static swig_type_info *swig_types[33]; | |||
2711 | static swig_module_info swig_module = {swig_types, 32, 0, 0, 0, 0}; | |||
2712 | #define SWIG_TypeQuery(name)SWIG_TypeQueryModule(&swig_module, &swig_module, name ) SWIG_TypeQueryModule(&swig_module, &swig_module, name) | |||
2713 | #define SWIG_MangledTypeQuery(name)SWIG_MangledTypeQueryModule(&swig_module, &swig_module , name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name) | |||
2714 | ||||
2715 | /* -------- TYPES TABLE (END) -------- */ | |||
2716 | ||||
2717 | #define SWIG_name"freeswitch" "freeswitch" | |||
2718 | #define SWIG_initluaopen_freeswitch luaopen_freeswitch | |||
2719 | #define SWIG_init_userluaopen_freeswitch_user luaopen_freeswitch_user | |||
2720 | ||||
2721 | #define SWIG_LUACODEluaopen_freeswitch_luacode luaopen_freeswitch_luacode | |||
2722 | ||||
2723 | namespace swig { | |||
2724 | typedef struct{} LANGUAGE_OBJ; | |||
2725 | } | |||
2726 | ||||
2727 | ||||
2728 | #include <string> | |||
2729 | ||||
2730 | ||||
2731 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_lua_isnilstring(lua_State *L, int idx) { | |||
2732 | int ret = lua_isstring(L, idx); | |||
2733 | if (!ret) | |||
2734 | ret = lua_isnil(L, idx)(lua_type(L, (idx)) == 0); | |||
2735 | return ret; | |||
2736 | } | |||
2737 | ||||
2738 | ||||
2739 | #include "switch.h" | |||
2740 | #include "switch_cpp.h" | |||
2741 | #include "freeswitch_lua.h" | |||
2742 | ||||
2743 | ||||
2744 | #ifdef __cplusplus201402L /* generic alloc/dealloc fns*/ | |||
2745 | #define SWIG_ALLOC_ARRAY(TYPE,LEN)new TYPE[LEN] new TYPE[LEN] | |||
2746 | #define SWIG_FREE_ARRAY(PTR)delete[] PTR delete[] PTR | |||
2747 | #else | |||
2748 | #define SWIG_ALLOC_ARRAY(TYPE,LEN)new TYPE[LEN] (TYPE *)malloc(LEN*sizeof(TYPE)) | |||
2749 | #define SWIG_FREE_ARRAY(PTR)delete[] PTR free(PTR) | |||
2750 | #endif | |||
2751 | /* counting the size of arrays:*/ | |||
2752 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_itable_size(lua_State* L, int index) | |||
2753 | { | |||
2754 | int n=0; | |||
2755 | while(1){ | |||
2756 | lua_rawgeti(L,index,n+1); | |||
2757 | if (lua_isnil(L,-1)(lua_type(L, (-1)) == 0))break; | |||
2758 | ++n; | |||
2759 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
2760 | } | |||
2761 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
2762 | return n; | |||
2763 | } | |||
2764 | ||||
2765 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_table_size(lua_State* L, int index) | |||
2766 | { | |||
2767 | int n=0; | |||
2768 | lua_pushnil(L); /* first key*/ | |||
2769 | while (lua_next(L, index) != 0) { | |||
2770 | ++n; | |||
2771 | lua_pop(L, 1)lua_settop(L, -(1)-1); /* removes `value'; keeps `key' for next iteration*/ | |||
2772 | } | |||
2773 | return n; | |||
2774 | } | |||
2775 | ||||
2776 | /* super macro to declare array typemap helper fns */ | |||
2777 | #define SWIG_DECLARE_TYPEMAP_ARR_FN(NAME,TYPE)static __attribute__ ((__unused__)) int SWIG_read_NAME_num_array (lua_State* L,int index,TYPE *array,int size){ int i; for (i = 0; i < size; i++) { lua_rawgeti(L,index,i+1); if (lua_isnumber (L,-1)){ array[i] = (TYPE)lua_tonumberx(L,-1,__null); } else { lua_settop(L, -(1)-1); return 0; } lua_settop(L, -(1)-1); } return 1; } static __attribute__ ((__unused__)) TYPE* SWIG_get_NAME_num_array_fixed (lua_State* L, int index, int size){ TYPE *array; if (!(lua_type (L, (index)) == 5) || SWIG_itable_size(L,index) != size) { SWIG_Lua_pushferrstring (L,"expected a table of size %d",size); return 0; } array=new TYPE[size]; if (!SWIG_read_NAME_num_array(L,index,array,size )){ SWIG_Lua_pusherrstring(L,"table must contain numbers"); delete [] array; return 0; } return array; } static __attribute__ (( __unused__)) TYPE* SWIG_get_NAME_num_array_var(lua_State* L, int index, int* size) { TYPE *array; if (!(lua_type(L, (index)) == 5)) { SWIG_Lua_pusherrstring(L,"expected a table"); return 0 ; } *size=SWIG_itable_size(L,index); if (*size<1){ SWIG_Lua_pusherrstring (L,"table appears to be empty"); return 0; } array=new TYPE[* size]; if (!SWIG_read_NAME_num_array(L,index,array,*size)){ SWIG_Lua_pusherrstring (L,"table must contain numbers"); delete[] array; return 0; } return array; } static __attribute__ ((__unused__)) void SWIG_write_NAME_num_array (lua_State* L,TYPE *array,int size){ int i; lua_createtable(L , 0, 0); for (i = 0; i < size; i++){ lua_pushnumber(L,(lua_Number )array[i]); lua_rawseti(L,-2,i+1); } }\ | |||
2778 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_read_##NAME##_num_array(lua_State* L,int index,TYPE *array,int size){\ | |||
2779 | int i;\ | |||
2780 | for (i = 0; i < size; i++) {\ | |||
2781 | lua_rawgeti(L,index,i+1);\ | |||
2782 | if (lua_isnumber(L,-1)){\ | |||
2783 | array[i] = (TYPE)lua_tonumber(L,-1)lua_tonumberx(L,-1,__null);\ | |||
2784 | } else {\ | |||
2785 | lua_pop(L,1)lua_settop(L, -(1)-1);\ | |||
2786 | return 0;\ | |||
2787 | }\ | |||
2788 | lua_pop(L,1)lua_settop(L, -(1)-1);\ | |||
2789 | }\ | |||
2790 | return 1;\ | |||
2791 | }\ | |||
2792 | SWIGINTERNstatic __attribute__ ((__unused__)) TYPE* SWIG_get_##NAME##_num_array_fixed(lua_State* L, int index, int size){\ | |||
2793 | TYPE *array;\ | |||
2794 | if (!lua_istable(L,index)(lua_type(L, (index)) == 5) || SWIG_itable_size(L,index) != size) {\ | |||
2795 | SWIG_Lua_pushferrstring(L,"expected a table of size %d",size);\ | |||
2796 | return 0;\ | |||
2797 | }\ | |||
2798 | array=SWIG_ALLOC_ARRAY(TYPE,size)new TYPE[size];\ | |||
2799 | if (!SWIG_read_##NAME##_num_array(L,index,array,size)){\ | |||
2800 | SWIG_Lua_pusherrstring(L,"table must contain numbers");\ | |||
2801 | SWIG_FREE_ARRAY(array)delete[] array;\ | |||
2802 | return 0;\ | |||
2803 | }\ | |||
2804 | return array;\ | |||
2805 | }\ | |||
2806 | SWIGINTERNstatic __attribute__ ((__unused__)) TYPE* SWIG_get_##NAME##_num_array_var(lua_State* L, int index, int* size)\ | |||
2807 | {\ | |||
2808 | TYPE *array;\ | |||
2809 | if (!lua_istable(L,index)(lua_type(L, (index)) == 5)) {\ | |||
2810 | SWIG_Lua_pusherrstring(L,"expected a table");\ | |||
2811 | return 0;\ | |||
2812 | }\ | |||
2813 | *size=SWIG_itable_size(L,index);\ | |||
2814 | if (*size<1){\ | |||
2815 | SWIG_Lua_pusherrstring(L,"table appears to be empty");\ | |||
2816 | return 0;\ | |||
2817 | }\ | |||
2818 | array=SWIG_ALLOC_ARRAY(TYPE,*size)new TYPE[*size];\ | |||
2819 | if (!SWIG_read_##NAME##_num_array(L,index,array,*size)){\ | |||
2820 | SWIG_Lua_pusherrstring(L,"table must contain numbers");\ | |||
2821 | SWIG_FREE_ARRAY(array)delete[] array;\ | |||
2822 | return 0;\ | |||
2823 | }\ | |||
2824 | return array;\ | |||
2825 | }\ | |||
2826 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_write_##NAME##_num_array(lua_State* L,TYPE *array,int size){\ | |||
2827 | int i;\ | |||
2828 | lua_newtable(L)lua_createtable(L, 0, 0);\ | |||
2829 | for (i = 0; i < size; i++){\ | |||
2830 | lua_pushnumber(L,(lua_Number)array[i]);\ | |||
2831 | lua_rawseti(L,-2,i+1);/* -1 is the number, -2 is the table*/ \ | |||
2832 | }\ | |||
2833 | } | |||
2834 | ||||
2835 | SWIG_DECLARE_TYPEMAP_ARR_FN(schar,signed char)static __attribute__ ((__unused__)) int SWIG_read_schar_num_array (lua_State* L,int index,signed char *array,int size){ int i; for (i = 0; i < size; i++) { lua_rawgeti(L,index,i+1); if (lua_isnumber (L,-1)){ array[i] = (signed char)lua_tonumberx(L,-1,__null); } else { lua_settop(L, -(1)-1); return 0; } lua_settop(L, -(1) -1); } return 1; } static __attribute__ ((__unused__)) signed char* SWIG_get_schar_num_array_fixed(lua_State* L, int index , int size){ signed char *array; if (!(lua_type(L, (index)) == 5) || SWIG_itable_size(L,index) != size) { SWIG_Lua_pushferrstring (L,"expected a table of size %d",size); return 0; } array=new signed char[size]; if (!SWIG_read_schar_num_array(L,index,array ,size)){ SWIG_Lua_pusherrstring(L,"table must contain numbers" ); delete[] array; return 0; } return array; } static __attribute__ ((__unused__)) signed char* SWIG_get_schar_num_array_var(lua_State * L, int index, int* size) { signed char *array; if (!(lua_type (L, (index)) == 5)) { SWIG_Lua_pusherrstring(L,"expected a table" ); return 0; } *size=SWIG_itable_size(L,index); if (*size< 1){ SWIG_Lua_pusherrstring(L,"table appears to be empty"); return 0; } array=new signed char[*size]; if (!SWIG_read_schar_num_array (L,index,array,*size)){ SWIG_Lua_pusherrstring(L,"table must contain numbers" ); delete[] array; return 0; } return array; } static __attribute__ ((__unused__)) void SWIG_write_schar_num_array(lua_State* L, signed char *array,int size){ int i; lua_createtable(L, 0, 0) ; for (i = 0; i < size; i++){ lua_pushnumber(L,(lua_Number )array[i]); lua_rawseti(L,-2,i+1); } } | |||
2836 | SWIG_DECLARE_TYPEMAP_ARR_FN(uchar,unsigned char)static __attribute__ ((__unused__)) int SWIG_read_uchar_num_array (lua_State* L,int index,unsigned char *array,int size){ int i ; for (i = 0; i < size; i++) { lua_rawgeti(L,index,i+1); if (lua_isnumber(L,-1)){ array[i] = (unsigned char)lua_tonumberx (L,-1,__null); } else { lua_settop(L, -(1)-1); return 0; } lua_settop (L, -(1)-1); } return 1; } static __attribute__ ((__unused__) ) unsigned char* SWIG_get_uchar_num_array_fixed(lua_State* L, int index, int size){ unsigned char *array; if (!(lua_type(L , (index)) == 5) || SWIG_itable_size(L,index) != size) { SWIG_Lua_pushferrstring (L,"expected a table of size %d",size); return 0; } array=new unsigned char[size]; if (!SWIG_read_uchar_num_array(L,index, array,size)){ SWIG_Lua_pusherrstring(L,"table must contain numbers" ); delete[] array; return 0; } return array; } static __attribute__ ((__unused__)) unsigned char* SWIG_get_uchar_num_array_var(lua_State * L, int index, int* size) { unsigned char *array; if (!(lua_type (L, (index)) == 5)) { SWIG_Lua_pusherrstring(L,"expected a table" ); return 0; } *size=SWIG_itable_size(L,index); if (*size< 1){ SWIG_Lua_pusherrstring(L,"table appears to be empty"); return 0; } array=new unsigned char[*size]; if (!SWIG_read_uchar_num_array (L,index,array,*size)){ SWIG_Lua_pusherrstring(L,"table must contain numbers" ); delete[] array; return 0; } return array; } static __attribute__ ((__unused__)) void SWIG_write_uchar_num_array(lua_State* L, unsigned char *array,int size){ int i; lua_createtable(L, 0, 0 ); for (i = 0; i < size; i++){ lua_pushnumber(L,(lua_Number )array[i]); lua_rawseti(L,-2,i+1); } } | |||
2837 | SWIG_DECLARE_TYPEMAP_ARR_FN(int,int)static __attribute__ ((__unused__)) int SWIG_read_int_num_array (lua_State* L,int index,int *array,int size){ int i; for (i = 0; i < size; i++) { lua_rawgeti(L,index,i+1); if (lua_isnumber (L,-1)){ array[i] = (int)lua_tonumberx(L,-1,__null); } else { lua_settop(L, -(1)-1); return 0; } lua_settop(L, -(1)-1); } return 1; } static __attribute__ ((__unused__)) int* SWIG_get_int_num_array_fixed (lua_State* L, int index, int size){ int *array; if (!(lua_type (L, (index)) == 5) || SWIG_itable_size(L,index) != size) { SWIG_Lua_pushferrstring (L,"expected a table of size %d",size); return 0; } array=new int[size]; if (!SWIG_read_int_num_array(L,index,array,size)) { SWIG_Lua_pusherrstring(L,"table must contain numbers"); delete [] array; return 0; } return array; } static __attribute__ (( __unused__)) int* SWIG_get_int_num_array_var(lua_State* L, int index, int* size) { int *array; if (!(lua_type(L, (index)) == 5)) { SWIG_Lua_pusherrstring(L,"expected a table"); return 0 ; } *size=SWIG_itable_size(L,index); if (*size<1){ SWIG_Lua_pusherrstring (L,"table appears to be empty"); return 0; } array=new int[*size ]; if (!SWIG_read_int_num_array(L,index,array,*size)){ SWIG_Lua_pusherrstring (L,"table must contain numbers"); delete[] array; return 0; } return array; } static __attribute__ ((__unused__)) void SWIG_write_int_num_array (lua_State* L,int *array,int size){ int i; lua_createtable(L, 0, 0); for (i = 0; i < size; i++){ lua_pushnumber(L,(lua_Number )array[i]); lua_rawseti(L,-2,i+1); } } | |||
2838 | SWIG_DECLARE_TYPEMAP_ARR_FN(uint,unsigned int)static __attribute__ ((__unused__)) int SWIG_read_uint_num_array (lua_State* L,int index,unsigned int *array,int size){ int i; for (i = 0; i < size; i++) { lua_rawgeti(L,index,i+1); if (lua_isnumber(L,-1)){ array[i] = (unsigned int)lua_tonumberx (L,-1,__null); } else { lua_settop(L, -(1)-1); return 0; } lua_settop (L, -(1)-1); } return 1; } static __attribute__ ((__unused__) ) unsigned int* SWIG_get_uint_num_array_fixed(lua_State* L, int index, int size){ unsigned int *array; if (!(lua_type(L, (index )) == 5) || SWIG_itable_size(L,index) != size) { SWIG_Lua_pushferrstring (L,"expected a table of size %d",size); return 0; } array=new unsigned int[size]; if (!SWIG_read_uint_num_array(L,index,array ,size)){ SWIG_Lua_pusherrstring(L,"table must contain numbers" ); delete[] array; return 0; } return array; } static __attribute__ ((__unused__)) unsigned int* SWIG_get_uint_num_array_var(lua_State * L, int index, int* size) { unsigned int *array; if (!(lua_type (L, (index)) == 5)) { SWIG_Lua_pusherrstring(L,"expected a table" ); return 0; } *size=SWIG_itable_size(L,index); if (*size< 1){ SWIG_Lua_pusherrstring(L,"table appears to be empty"); return 0; } array=new unsigned int[*size]; if (!SWIG_read_uint_num_array (L,index,array,*size)){ SWIG_Lua_pusherrstring(L,"table must contain numbers" ); delete[] array; return 0; } return array; } static __attribute__ ((__unused__)) void SWIG_write_uint_num_array(lua_State* L,unsigned int *array,int size){ int i; lua_createtable(L, 0, 0); for ( i = 0; i < size; i++){ lua_pushnumber(L,(lua_Number)array[ i]); lua_rawseti(L,-2,i+1); } } | |||
2839 | SWIG_DECLARE_TYPEMAP_ARR_FN(short,short)static __attribute__ ((__unused__)) int SWIG_read_short_num_array (lua_State* L,int index,short *array,int size){ int i; for (i = 0; i < size; i++) { lua_rawgeti(L,index,i+1); if (lua_isnumber (L,-1)){ array[i] = (short)lua_tonumberx(L,-1,__null); } else { lua_settop(L, -(1)-1); return 0; } lua_settop(L, -(1)-1); } return 1; } static __attribute__ ((__unused__)) short* SWIG_get_short_num_array_fixed (lua_State* L, int index, int size){ short *array; if (!(lua_type (L, (index)) == 5) || SWIG_itable_size(L,index) != size) { SWIG_Lua_pushferrstring (L,"expected a table of size %d",size); return 0; } array=new short[size]; if (!SWIG_read_short_num_array(L,index,array,size )){ SWIG_Lua_pusherrstring(L,"table must contain numbers"); delete [] array; return 0; } return array; } static __attribute__ (( __unused__)) short* SWIG_get_short_num_array_var(lua_State* L , int index, int* size) { short *array; if (!(lua_type(L, (index )) == 5)) { SWIG_Lua_pusherrstring(L,"expected a table"); return 0; } *size=SWIG_itable_size(L,index); if (*size<1){ SWIG_Lua_pusherrstring (L,"table appears to be empty"); return 0; } array=new short[ *size]; if (!SWIG_read_short_num_array(L,index,array,*size)){ SWIG_Lua_pusherrstring(L,"table must contain numbers"); delete [] array; return 0; } return array; } static __attribute__ (( __unused__)) void SWIG_write_short_num_array(lua_State* L,short *array,int size){ int i; lua_createtable(L, 0, 0); for (i = 0 ; i < size; i++){ lua_pushnumber(L,(lua_Number)array[i]); lua_rawseti (L,-2,i+1); } } | |||
2840 | SWIG_DECLARE_TYPEMAP_ARR_FN(ushort,unsigned short)static __attribute__ ((__unused__)) int SWIG_read_ushort_num_array (lua_State* L,int index,unsigned short *array,int size){ int i ; for (i = 0; i < size; i++) { lua_rawgeti(L,index,i+1); if (lua_isnumber(L,-1)){ array[i] = (unsigned short)lua_tonumberx (L,-1,__null); } else { lua_settop(L, -(1)-1); return 0; } lua_settop (L, -(1)-1); } return 1; } static __attribute__ ((__unused__) ) unsigned short* SWIG_get_ushort_num_array_fixed(lua_State* L , int index, int size){ unsigned short *array; if (!(lua_type (L, (index)) == 5) || SWIG_itable_size(L,index) != size) { SWIG_Lua_pushferrstring (L,"expected a table of size %d",size); return 0; } array=new unsigned short[size]; if (!SWIG_read_ushort_num_array(L,index ,array,size)){ SWIG_Lua_pusherrstring(L,"table must contain numbers" ); delete[] array; return 0; } return array; } static __attribute__ ((__unused__)) unsigned short* SWIG_get_ushort_num_array_var (lua_State* L, int index, int* size) { unsigned short *array; if (!(lua_type(L, (index)) == 5)) { SWIG_Lua_pusherrstring(L ,"expected a table"); return 0; } *size=SWIG_itable_size(L,index ); if (*size<1){ SWIG_Lua_pusherrstring(L,"table appears to be empty" ); return 0; } array=new unsigned short[*size]; if (!SWIG_read_ushort_num_array (L,index,array,*size)){ SWIG_Lua_pusherrstring(L,"table must contain numbers" ); delete[] array; return 0; } return array; } static __attribute__ ((__unused__)) void SWIG_write_ushort_num_array(lua_State* L ,unsigned short *array,int size){ int i; lua_createtable(L, 0 , 0); for (i = 0; i < size; i++){ lua_pushnumber(L,(lua_Number )array[i]); lua_rawseti(L,-2,i+1); } } | |||
2841 | SWIG_DECLARE_TYPEMAP_ARR_FN(long,long)static __attribute__ ((__unused__)) int SWIG_read_long_num_array (lua_State* L,int index,long *array,int size){ int i; for (i = 0; i < size; i++) { lua_rawgeti(L,index,i+1); if (lua_isnumber (L,-1)){ array[i] = (long)lua_tonumberx(L,-1,__null); } else { lua_settop(L, -(1)-1); return 0; } lua_settop(L, -(1)-1); } return 1; } static __attribute__ ((__unused__)) long* SWIG_get_long_num_array_fixed (lua_State* L, int index, int size){ long *array; if (!(lua_type (L, (index)) == 5) || SWIG_itable_size(L,index) != size) { SWIG_Lua_pushferrstring (L,"expected a table of size %d",size); return 0; } array=new long[size]; if (!SWIG_read_long_num_array(L,index,array,size )){ SWIG_Lua_pusherrstring(L,"table must contain numbers"); delete [] array; return 0; } return array; } static __attribute__ (( __unused__)) long* SWIG_get_long_num_array_var(lua_State* L, int index, int* size) { long *array; if (!(lua_type(L, (index)) == 5)) { SWIG_Lua_pusherrstring(L,"expected a table"); return 0 ; } *size=SWIG_itable_size(L,index); if (*size<1){ SWIG_Lua_pusherrstring (L,"table appears to be empty"); return 0; } array=new long[* size]; if (!SWIG_read_long_num_array(L,index,array,*size)){ SWIG_Lua_pusherrstring (L,"table must contain numbers"); delete[] array; return 0; } return array; } static __attribute__ ((__unused__)) void SWIG_write_long_num_array (lua_State* L,long *array,int size){ int i; lua_createtable(L , 0, 0); for (i = 0; i < size; i++){ lua_pushnumber(L,(lua_Number )array[i]); lua_rawseti(L,-2,i+1); } } | |||
2842 | SWIG_DECLARE_TYPEMAP_ARR_FN(ulong,unsigned long)static __attribute__ ((__unused__)) int SWIG_read_ulong_num_array (lua_State* L,int index,unsigned long *array,int size){ int i ; for (i = 0; i < size; i++) { lua_rawgeti(L,index,i+1); if (lua_isnumber(L,-1)){ array[i] = (unsigned long)lua_tonumberx (L,-1,__null); } else { lua_settop(L, -(1)-1); return 0; } lua_settop (L, -(1)-1); } return 1; } static __attribute__ ((__unused__) ) unsigned long* SWIG_get_ulong_num_array_fixed(lua_State* L, int index, int size){ unsigned long *array; if (!(lua_type(L , (index)) == 5) || SWIG_itable_size(L,index) != size) { SWIG_Lua_pushferrstring (L,"expected a table of size %d",size); return 0; } array=new unsigned long[size]; if (!SWIG_read_ulong_num_array(L,index, array,size)){ SWIG_Lua_pusherrstring(L,"table must contain numbers" ); delete[] array; return 0; } return array; } static __attribute__ ((__unused__)) unsigned long* SWIG_get_ulong_num_array_var(lua_State * L, int index, int* size) { unsigned long *array; if (!(lua_type (L, (index)) == 5)) { SWIG_Lua_pusherrstring(L,"expected a table" ); return 0; } *size=SWIG_itable_size(L,index); if (*size< 1){ SWIG_Lua_pusherrstring(L,"table appears to be empty"); return 0; } array=new unsigned long[*size]; if (!SWIG_read_ulong_num_array (L,index,array,*size)){ SWIG_Lua_pusherrstring(L,"table must contain numbers" ); delete[] array; return 0; } return array; } static __attribute__ ((__unused__)) void SWIG_write_ulong_num_array(lua_State* L, unsigned long *array,int size){ int i; lua_createtable(L, 0, 0 ); for (i = 0; i < size; i++){ lua_pushnumber(L,(lua_Number )array[i]); lua_rawseti(L,-2,i+1); } } | |||
2843 | SWIG_DECLARE_TYPEMAP_ARR_FN(float,float)static __attribute__ ((__unused__)) int SWIG_read_float_num_array (lua_State* L,int index,float *array,int size){ int i; for (i = 0; i < size; i++) { lua_rawgeti(L,index,i+1); if (lua_isnumber (L,-1)){ array[i] = (float)lua_tonumberx(L,-1,__null); } else { lua_settop(L, -(1)-1); return 0; } lua_settop(L, -(1)-1); } return 1; } static __attribute__ ((__unused__)) float* SWIG_get_float_num_array_fixed (lua_State* L, int index, int size){ float *array; if (!(lua_type (L, (index)) == 5) || SWIG_itable_size(L,index) != size) { SWIG_Lua_pushferrstring (L,"expected a table of size %d",size); return 0; } array=new float[size]; if (!SWIG_read_float_num_array(L,index,array,size )){ SWIG_Lua_pusherrstring(L,"table must contain numbers"); delete [] array; return 0; } return array; } static __attribute__ (( __unused__)) float* SWIG_get_float_num_array_var(lua_State* L , int index, int* size) { float *array; if (!(lua_type(L, (index )) == 5)) { SWIG_Lua_pusherrstring(L,"expected a table"); return 0; } *size=SWIG_itable_size(L,index); if (*size<1){ SWIG_Lua_pusherrstring (L,"table appears to be empty"); return 0; } array=new float[ *size]; if (!SWIG_read_float_num_array(L,index,array,*size)){ SWIG_Lua_pusherrstring(L,"table must contain numbers"); delete [] array; return 0; } return array; } static __attribute__ (( __unused__)) void SWIG_write_float_num_array(lua_State* L,float *array,int size){ int i; lua_createtable(L, 0, 0); for (i = 0 ; i < size; i++){ lua_pushnumber(L,(lua_Number)array[i]); lua_rawseti (L,-2,i+1); } } | |||
2844 | SWIG_DECLARE_TYPEMAP_ARR_FN(double,double)static __attribute__ ((__unused__)) int SWIG_read_double_num_array (lua_State* L,int index,double *array,int size){ int i; for ( i = 0; i < size; i++) { lua_rawgeti(L,index,i+1); if (lua_isnumber (L,-1)){ array[i] = (double)lua_tonumberx(L,-1,__null); } else { lua_settop(L, -(1)-1); return 0; } lua_settop(L, -(1)-1); } return 1; } static __attribute__ ((__unused__)) double* SWIG_get_double_num_array_fixed (lua_State* L, int index, int size){ double *array; if (!(lua_type (L, (index)) == 5) || SWIG_itable_size(L,index) != size) { SWIG_Lua_pushferrstring (L,"expected a table of size %d",size); return 0; } array=new double[size]; if (!SWIG_read_double_num_array(L,index,array, size)){ SWIG_Lua_pusherrstring(L,"table must contain numbers" ); delete[] array; return 0; } return array; } static __attribute__ ((__unused__)) double* SWIG_get_double_num_array_var(lua_State * L, int index, int* size) { double *array; if (!(lua_type(L, (index)) == 5)) { SWIG_Lua_pusherrstring(L,"expected a table" ); return 0; } *size=SWIG_itable_size(L,index); if (*size< 1){ SWIG_Lua_pusherrstring(L,"table appears to be empty"); return 0; } array=new double[*size]; if (!SWIG_read_double_num_array (L,index,array,*size)){ SWIG_Lua_pusherrstring(L,"table must contain numbers" ); delete[] array; return 0; } return array; } static __attribute__ ((__unused__)) void SWIG_write_double_num_array(lua_State* L ,double *array,int size){ int i; lua_createtable(L, 0, 0); for (i = 0; i < size; i++){ lua_pushnumber(L,(lua_Number)array [i]); lua_rawseti(L,-2,i+1); } } | |||
2845 | ||||
2846 | SWIGINTERNstatic __attribute__ ((__unused__)) int SWIG_read_ptr_array(lua_State* L,int index,void **array,int size,swig_type_info *type){ | |||
2847 | int i; | |||
2848 | for (i = 0; i < size; i++) { | |||
2849 | lua_rawgeti(L,index,i+1); | |||
2850 | if (!lua_isuserdata(L,-1) || SWIG_ConvertPtr(L,-1,&array[i],type,0)SWIG_Lua_ConvertPtr(L,-1,&array[i],type,0)==-1){ | |||
2851 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
2852 | return 0; | |||
2853 | } | |||
2854 | lua_pop(L,1)lua_settop(L, -(1)-1); | |||
2855 | } | |||
2856 | return 1; | |||
2857 | } | |||
2858 | SWIGINTERNstatic __attribute__ ((__unused__)) void** SWIG_get_ptr_array_fixed(lua_State* L, int index, int size,swig_type_info *type){ | |||
2859 | void **array; | |||
2860 | if (!lua_istable(L,index)(lua_type(L, (index)) == 5) || SWIG_itable_size(L,index) != size) { | |||
2861 | SWIG_Lua_pushferrstring(L,"expected a table of size %d",size); | |||
2862 | return 0; | |||
2863 | } | |||
2864 | array=SWIG_ALLOC_ARRAY(void*,size)new void*[size]; | |||
2865 | if (!SWIG_read_ptr_array(L,index,array,size,type)){ | |||
2866 | SWIG_Lua_pushferrstring(L,"table must contain pointers of type %s",type->name); | |||
2867 | SWIG_FREE_ARRAY(array)delete[] array; | |||
2868 | return 0; | |||
2869 | } | |||
2870 | return array; | |||
2871 | } | |||
2872 | SWIGINTERNstatic __attribute__ ((__unused__)) void** SWIG_get_ptr_array_var(lua_State* L, int index, int* size,swig_type_info *type){ | |||
2873 | void **array; | |||
2874 | if (!lua_istable(L,index)(lua_type(L, (index)) == 5)) { | |||
2875 | SWIG_Lua_pusherrstring(L,"expected a table"); | |||
2876 | return 0; | |||
2877 | } | |||
2878 | *size=SWIG_itable_size(L,index); | |||
2879 | if (*size<1){ | |||
2880 | SWIG_Lua_pusherrstring(L,"table appears to be empty"); | |||
2881 | return 0; | |||
2882 | } | |||
2883 | array=SWIG_ALLOC_ARRAY(void*,*size)new void*[*size]; | |||
2884 | if (!SWIG_read_ptr_array(L,index,array,*size,type)){ | |||
2885 | SWIG_Lua_pushferrstring(L,"table must contain pointers of type %s",type->name); | |||
2886 | SWIG_FREE_ARRAY(array)delete[] array; | |||
2887 | return 0; | |||
2888 | } | |||
2889 | return array; | |||
2890 | } | |||
2891 | SWIGINTERNstatic __attribute__ ((__unused__)) void SWIG_write_ptr_array(lua_State* L,void **array,int size,swig_type_info *type,int own){ | |||
2892 | int i; | |||
2893 | lua_newtable(L)lua_createtable(L, 0, 0); | |||
2894 | for (i = 0; i < size; i++){ | |||
2895 | SWIG_NewPointerObj(L,array[i],type,own)SWIG_Lua_NewPointerObj(L, (void *)array[i], type, own); | |||
2896 | lua_rawseti(L,-2,i+1);/* -1 is the number, -2 is the table*/ | |||
2897 | } | |||
2898 | } | |||
2899 | ||||
2900 | #ifdef __cplusplus201402L | |||
2901 | extern "C" { | |||
2902 | #endif | |||
2903 | static int _wrap_new_string__SWIG_0(lua_State* L) { | |||
2904 | int SWIG_arg = 0; | |||
2905 | std::string *result = 0 ; | |||
2906 | ||||
2907 | SWIG_check_num_args("std::string::string",0,0)if (lua_gettop(L)<0 || lua_gettop(L)>0) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","std::string::string" ,0,0,lua_gettop(L)); goto fail;} | |||
2908 | result = (std::string *)new std::string(); | |||
2909 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_std__string,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[16], 1); SWIG_arg++; | |||
2910 | return SWIG_arg; | |||
2911 | ||||
2912 | if(0) SWIG_fail{goto fail;}; | |||
2913 | ||||
2914 | fail: | |||
2915 | lua_error(L); | |||
2916 | return SWIG_arg; | |||
2917 | } | |||
2918 | ||||
2919 | ||||
2920 | static int _wrap_new_string__SWIG_1(lua_State* L) { | |||
2921 | int SWIG_arg = 0; | |||
2922 | char *arg1 = (char *) 0 ; | |||
2923 | std::string *result = 0 ; | |||
2924 | ||||
2925 | SWIG_check_num_args("std::string::string",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","std::string::string" ,1,1,lua_gettop(L)); goto fail;} | |||
2926 | if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("std::string::string",1,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "std::string::string",1,"char const *",SWIG_Lua_typename(L, 1)); goto fail;}; | |||
2927 | arg1 = (char *)lua_tostring(L, 1)lua_tolstring(L, (1), __null); | |||
2928 | result = (std::string *)new std::string((char const *)arg1); | |||
2929 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_std__string,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[16], 1); SWIG_arg++; | |||
2930 | return SWIG_arg; | |||
2931 | ||||
2932 | if(0) SWIG_fail{goto fail;}; | |||
2933 | ||||
2934 | fail: | |||
2935 | lua_error(L); | |||
2936 | return SWIG_arg; | |||
2937 | } | |||
2938 | ||||
2939 | ||||
2940 | static int _wrap_new_string(lua_State* L) { | |||
2941 | int argc; | |||
2942 | int argv[2]={ | |||
2943 | 1,2 | |||
2944 | }; | |||
2945 | ||||
2946 | argc = lua_gettop(L); | |||
2947 | if (argc == 0) { | |||
2948 | return _wrap_new_string__SWIG_0(L); | |||
2949 | } | |||
2950 | if (argc == 1) { | |||
2951 | int _v; | |||
2952 | { | |||
2953 | _v = SWIG_lua_isnilstring(L,argv[0]); | |||
2954 | } | |||
2955 | if (_v) { | |||
2956 | return _wrap_new_string__SWIG_1(L); | |||
2957 | } | |||
2958 | } | |||
2959 | ||||
2960 | SWIG_Lua_pusherrstring(L,"Wrong arguments for overloaded function 'new_string'\n" | |||
2961 | " Possible C/C++ prototypes are:\n" | |||
2962 | " std::string::string()\n" | |||
2963 | " std::string::string(char const *)\n"); | |||
2964 | lua_error(L);return 0; | |||
2965 | } | |||
2966 | ||||
2967 | ||||
2968 | static int _wrap_string_size(lua_State* L) { | |||
2969 | int SWIG_arg = 0; | |||
2970 | std::string *arg1 = (std::string *) 0 ; | |||
2971 | unsigned int result; | |||
2972 | ||||
2973 | SWIG_check_num_args("std::string::size",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","std::string::size" ,1,1,lua_gettop(L)); goto fail;} | |||
2974 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("std::string::size",1,"std::string const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "std::string::size",1,"std::string const *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
2975 | ||||
2976 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_std__string,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[16],0) >= 0)){ | |||
2977 | SWIG_fail_ptr("string_size",1,SWIGTYPE_p_std__string){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "string_size",1,(swig_types[16] && swig_types[16]-> str)?swig_types[16]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
2978 | } | |||
2979 | ||||
2980 | result = (unsigned int)((std::string const *)arg1)->size(); | |||
2981 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
2982 | return SWIG_arg; | |||
2983 | ||||
2984 | if(0) SWIG_fail{goto fail;}; | |||
2985 | ||||
2986 | fail: | |||
2987 | lua_error(L); | |||
2988 | return SWIG_arg; | |||
2989 | } | |||
2990 | ||||
2991 | ||||
2992 | static int _wrap_string_length(lua_State* L) { | |||
2993 | int SWIG_arg = 0; | |||
2994 | std::string *arg1 = (std::string *) 0 ; | |||
2995 | unsigned int result; | |||
2996 | ||||
2997 | SWIG_check_num_args("std::string::length",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","std::string::length" ,1,1,lua_gettop(L)); goto fail;} | |||
2998 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("std::string::length",1,"std::string const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "std::string::length",1,"std::string const *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
2999 | ||||
3000 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_std__string,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[16],0) >= 0)){ | |||
3001 | SWIG_fail_ptr("string_length",1,SWIGTYPE_p_std__string){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "string_length",1,(swig_types[16] && swig_types[16] ->str)?swig_types[16]->str:"void*",SWIG_Lua_typename(L, 1)); goto fail;}; | |||
3002 | } | |||
3003 | ||||
3004 | result = (unsigned int)((std::string const *)arg1)->length(); | |||
3005 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
3006 | return SWIG_arg; | |||
3007 | ||||
3008 | if(0) SWIG_fail{goto fail;}; | |||
3009 | ||||
3010 | fail: | |||
3011 | lua_error(L); | |||
3012 | return SWIG_arg; | |||
3013 | } | |||
3014 | ||||
3015 | ||||
3016 | static int _wrap_string_empty(lua_State* L) { | |||
3017 | int SWIG_arg = 0; | |||
3018 | std::string *arg1 = (std::string *) 0 ; | |||
3019 | bool result; | |||
3020 | ||||
3021 | SWIG_check_num_args("std::string::empty",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","std::string::empty" ,1,1,lua_gettop(L)); goto fail;} | |||
3022 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("std::string::empty",1,"std::string const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "std::string::empty",1,"std::string const *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
3023 | ||||
3024 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_std__string,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[16],0) >= 0)){ | |||
3025 | SWIG_fail_ptr("string_empty",1,SWIGTYPE_p_std__string){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "string_empty",1,(swig_types[16] && swig_types[16]-> str)?swig_types[16]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
3026 | } | |||
3027 | ||||
3028 | result = (bool)((std::string const *)arg1)->empty(); | |||
3029 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
3030 | return SWIG_arg; | |||
3031 | ||||
3032 | if(0) SWIG_fail{goto fail;}; | |||
3033 | ||||
3034 | fail: | |||
3035 | lua_error(L); | |||
3036 | return SWIG_arg; | |||
3037 | } | |||
3038 | ||||
3039 | ||||
3040 | static int _wrap_string_c_str(lua_State* L) { | |||
3041 | int SWIG_arg = 0; | |||
3042 | std::string *arg1 = (std::string *) 0 ; | |||
3043 | char *result = 0 ; | |||
3044 | ||||
3045 | SWIG_check_num_args("std::string::c_str",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","std::string::c_str" ,1,1,lua_gettop(L)); goto fail;} | |||
3046 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("std::string::c_str",1,"std::string const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "std::string::c_str",1,"std::string const *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
3047 | ||||
3048 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_std__string,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[16],0) >= 0)){ | |||
3049 | SWIG_fail_ptr("string_c_str",1,SWIGTYPE_p_std__string){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "string_c_str",1,(swig_types[16] && swig_types[16]-> str)?swig_types[16]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
3050 | } | |||
3051 | ||||
3052 | result = (char *)((std::string const *)arg1)->c_str(); | |||
3053 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
3054 | return SWIG_arg; | |||
3055 | ||||
3056 | if(0) SWIG_fail{goto fail;}; | |||
3057 | ||||
3058 | fail: | |||
3059 | lua_error(L); | |||
3060 | return SWIG_arg; | |||
3061 | } | |||
3062 | ||||
3063 | ||||
3064 | static int _wrap_string_data(lua_State* L) { | |||
3065 | int SWIG_arg = 0; | |||
3066 | std::string *arg1 = (std::string *) 0 ; | |||
3067 | char *result = 0 ; | |||
3068 | ||||
3069 | SWIG_check_num_args("std::string::data",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","std::string::data" ,1,1,lua_gettop(L)); goto fail;} | |||
3070 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("std::string::data",1,"std::string const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "std::string::data",1,"std::string const *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
3071 | ||||
3072 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_std__string,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[16],0) >= 0)){ | |||
3073 | SWIG_fail_ptr("string_data",1,SWIGTYPE_p_std__string){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "string_data",1,(swig_types[16] && swig_types[16]-> str)?swig_types[16]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
3074 | } | |||
3075 | ||||
3076 | result = (char *)((std::string const *)arg1)->data(); | |||
3077 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
3078 | return SWIG_arg; | |||
3079 | ||||
3080 | if(0) SWIG_fail{goto fail;}; | |||
3081 | ||||
3082 | fail: | |||
3083 | lua_error(L); | |||
3084 | return SWIG_arg; | |||
3085 | } | |||
3086 | ||||
3087 | ||||
3088 | static int _wrap_string_assign(lua_State* L) { | |||
3089 | int SWIG_arg = 0; | |||
3090 | std::string *arg1 = (std::string *) 0 ; | |||
3091 | char *arg2 = (char *) 0 ; | |||
3092 | ||||
3093 | SWIG_check_num_args("std::string::assign",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","std::string::assign" ,2,2,lua_gettop(L)); goto fail;} | |||
3094 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("std::string::assign",1,"std::string *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "std::string::assign",1,"std::string *",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
3095 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("std::string::assign",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "std::string::assign",2,"char const *",SWIG_Lua_typename(L, 2)); goto fail;}; | |||
3096 | ||||
3097 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_std__string,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[16],0) >= 0)){ | |||
3098 | SWIG_fail_ptr("string_assign",1,SWIGTYPE_p_std__string){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "string_assign",1,(swig_types[16] && swig_types[16] ->str)?swig_types[16]->str:"void*",SWIG_Lua_typename(L, 1)); goto fail;}; | |||
3099 | } | |||
3100 | ||||
3101 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
3102 | (arg1)->assign((char const *)arg2); | |||
3103 | ||||
3104 | return SWIG_arg; | |||
3105 | ||||
3106 | if(0) SWIG_fail{goto fail;}; | |||
3107 | ||||
3108 | fail: | |||
3109 | lua_error(L); | |||
3110 | return SWIG_arg; | |||
3111 | } | |||
3112 | ||||
3113 | ||||
3114 | static void swig_delete_string(void *obj) { | |||
3115 | std::string *arg1 = (std::string *) obj; | |||
3116 | delete arg1; | |||
3117 | } | |||
3118 | static int _proxy__wrap_new_string(lua_State *L) { | |||
3119 | assert(lua_istable(L,1))(static_cast <bool> ((lua_type(L, (1)) == 5)) ? void (0 ) : __assert_fail ("lua_istable(L,1)", "mod_lua_wrap.cpp", 3119 , __extension__ __PRETTY_FUNCTION__)); | |||
3120 | lua_pushcfunction(L,_wrap_new_string)lua_pushcclosure(L, (_wrap_new_string), 0); | |||
3121 | assert(!lua_isnil(L,-1))(static_cast <bool> (!(lua_type(L, (-1)) == 0)) ? void ( 0) : __assert_fail ("!lua_isnil(L,-1)", "mod_lua_wrap.cpp", 3121 , __extension__ __PRETTY_FUNCTION__)); | |||
3122 | lua_replace(L,1); /* replace our table with real constructor */ | |||
3123 | lua_call(L,lua_gettop(L)-1,1)lua_callk(L, (lua_gettop(L)-1), (1), 0, __null); | |||
3124 | return 1; | |||
3125 | } | |||
3126 | static swig_lua_attribute swig_string_attributes[] = { | |||
3127 | {0,0,0} | |||
3128 | }; | |||
3129 | static swig_lua_method swig_string_methods[]= { | |||
3130 | { "size", _wrap_string_size}, | |||
3131 | { "length", _wrap_string_length}, | |||
3132 | { "empty", _wrap_string_empty}, | |||
3133 | { "c_str", _wrap_string_c_str}, | |||
3134 | { "data", _wrap_string_data}, | |||
3135 | { "assign", _wrap_string_assign}, | |||
3136 | {0,0} | |||
3137 | }; | |||
3138 | static swig_lua_method swig_string_meta[] = { | |||
3139 | {0,0} | |||
3140 | }; | |||
3141 | ||||
3142 | static swig_lua_attribute swig_string_Sf_SwigStatic_attributes[] = { | |||
3143 | {0,0,0} | |||
3144 | }; | |||
3145 | static swig_lua_const_info swig_string_Sf_SwigStatic_constants[]= { | |||
3146 | {0,0,0,0,0,0} | |||
3147 | }; | |||
3148 | static swig_lua_method swig_string_Sf_SwigStatic_methods[]= { | |||
3149 | {0,0} | |||
3150 | }; | |||
3151 | static swig_lua_class* swig_string_Sf_SwigStatic_classes[]= { | |||
3152 | 0 | |||
3153 | }; | |||
3154 | ||||
3155 | static swig_lua_namespace swig_string_Sf_SwigStatic = { | |||
3156 | "string", | |||
3157 | swig_string_Sf_SwigStatic_methods, | |||
3158 | swig_string_Sf_SwigStatic_attributes, | |||
3159 | swig_string_Sf_SwigStatic_constants, | |||
3160 | swig_string_Sf_SwigStatic_classes, | |||
3161 | 0 | |||
3162 | }; | |||
3163 | static swig_lua_class *swig_string_bases[] = {0}; | |||
3164 | static const char *swig_string_base_names[] = {0}; | |||
3165 | static swig_lua_class _wrap_class_string = { "string", "string", &SWIGTYPE_p_std__stringswig_types[16],_proxy__wrap_new_string, swig_delete_string, swig_string_methods, swig_string_attributes, &swig_string_Sf_SwigStatic, swig_string_meta, swig_string_bases, swig_string_base_names }; | |||
3166 | ||||
3167 | static int _wrap_setGlobalVariable(lua_State* L) { | |||
3168 | int SWIG_arg = 0; | |||
3169 | char *arg1 = (char *) 0 ; | |||
3170 | char *arg2 = (char *) 0 ; | |||
3171 | ||||
3172 | SWIG_check_num_args("setGlobalVariable",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","setGlobalVariable" ,2,2,lua_gettop(L)); goto fail;} | |||
3173 | if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("setGlobalVariable",1,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "setGlobalVariable",1,"char *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
3174 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("setGlobalVariable",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "setGlobalVariable",2,"char *",SWIG_Lua_typename(L,2)); goto fail;}; | |||
3175 | arg1 = (char *)lua_tostring(L, 1)lua_tolstring(L, (1), __null); | |||
3176 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
3177 | setGlobalVariable(arg1,arg2); | |||
3178 | ||||
3179 | return SWIG_arg; | |||
3180 | ||||
3181 | if(0) SWIG_fail{goto fail;}; | |||
3182 | ||||
3183 | fail: | |||
3184 | lua_error(L); | |||
3185 | return SWIG_arg; | |||
3186 | } | |||
3187 | ||||
3188 | ||||
3189 | static int _wrap_getGlobalVariable(lua_State* L) { | |||
3190 | int SWIG_arg = 0; | |||
3191 | char *arg1 = (char *) 0 ; | |||
3192 | char *result = 0 ; | |||
3193 | ||||
3194 | SWIG_check_num_args("getGlobalVariable",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","getGlobalVariable" ,1,1,lua_gettop(L)); goto fail;} | |||
3195 | if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("getGlobalVariable",1,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "getGlobalVariable",1,"char *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
3196 | arg1 = (char *)lua_tostring(L, 1)lua_tolstring(L, (1), __null); | |||
3197 | result = (char *)getGlobalVariable(arg1); | |||
3198 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
3199 | free(result); | |||
3200 | return SWIG_arg; | |||
3201 | ||||
3202 | if(0) SWIG_fail{goto fail;}; | |||
3203 | ||||
3204 | fail: | |||
3205 | lua_error(L); | |||
3206 | return SWIG_arg; | |||
3207 | } | |||
3208 | ||||
3209 | ||||
3210 | static int _wrap_consoleLog(lua_State* L) { | |||
3211 | int SWIG_arg = 0; | |||
3212 | char *arg1 = (char *) 0 ; | |||
3213 | char *arg2 = (char *) 0 ; | |||
3214 | ||||
3215 | SWIG_check_num_args("consoleLog",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","consoleLog",2, 2,lua_gettop(L)); goto fail;} | |||
3216 | if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("consoleLog",1,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "consoleLog",1,"char *",SWIG_Lua_typename(L,1)); goto fail; }; | |||
3217 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("consoleLog",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "consoleLog",2,"char *",SWIG_Lua_typename(L,2)); goto fail; }; | |||
3218 | arg1 = (char *)lua_tostring(L, 1)lua_tolstring(L, (1), __null); | |||
3219 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
3220 | consoleLog(arg1,arg2); | |||
3221 | ||||
3222 | return SWIG_arg; | |||
3223 | ||||
3224 | if(0) SWIG_fail{goto fail;}; | |||
3225 | ||||
3226 | fail: | |||
3227 | lua_error(L); | |||
3228 | return SWIG_arg; | |||
3229 | } | |||
3230 | ||||
3231 | ||||
3232 | static int _wrap_consoleLog2(lua_State* L) { | |||
3233 | int SWIG_arg = 0; | |||
3234 | char *arg1 = (char *) 0 ; | |||
3235 | char *arg2 = (char *) 0 ; | |||
3236 | char *arg3 = (char *) 0 ; | |||
3237 | int arg4 ; | |||
3238 | char *arg5 = (char *) 0 ; | |||
3239 | ||||
3240 | SWIG_check_num_args("consoleLog2",5,5)if (lua_gettop(L)<5 || lua_gettop(L)>5) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","consoleLog2",5 ,5,lua_gettop(L)); goto fail;} | |||
3241 | if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("consoleLog2",1,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "consoleLog2",1,"char *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
3242 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("consoleLog2",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "consoleLog2",2,"char *",SWIG_Lua_typename(L,2)); goto fail ;}; | |||
3243 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("consoleLog2",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "consoleLog2",3,"char *",SWIG_Lua_typename(L,3)); goto fail ;}; | |||
3244 | if(!lua_isnumber(L,4)) SWIG_fail_arg("consoleLog2",4,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "consoleLog2",4,"int",SWIG_Lua_typename(L,4)); goto fail;}; | |||
3245 | if(!SWIG_lua_isnilstring(L,5)) SWIG_fail_arg("consoleLog2",5,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "consoleLog2",5,"char *",SWIG_Lua_typename(L,5)); goto fail ;}; | |||
3246 | arg1 = (char *)lua_tostring(L, 1)lua_tolstring(L, (1), __null); | |||
3247 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
3248 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
3249 | arg4 = (int)lua_tonumber(L, 4)lua_tonumberx(L,4,__null); | |||
3250 | arg5 = (char *)lua_tostring(L, 5)lua_tolstring(L, (5), __null); | |||
3251 | consoleLog2(arg1,arg2,arg3,arg4,arg5); | |||
3252 | ||||
3253 | return SWIG_arg; | |||
3254 | ||||
3255 | if(0) SWIG_fail{goto fail;}; | |||
3256 | ||||
3257 | fail: | |||
3258 | lua_error(L); | |||
3259 | return SWIG_arg; | |||
3260 | } | |||
3261 | ||||
3262 | ||||
3263 | static int _wrap_consoleCleanLog(lua_State* L) { | |||
3264 | int SWIG_arg = 0; | |||
3265 | char *arg1 = (char *) 0 ; | |||
3266 | ||||
3267 | SWIG_check_num_args("consoleCleanLog",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","consoleCleanLog" ,1,1,lua_gettop(L)); goto fail;} | |||
3268 | if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("consoleCleanLog",1,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "consoleCleanLog",1,"char *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
3269 | arg1 = (char *)lua_tostring(L, 1)lua_tolstring(L, (1), __null); | |||
3270 | consoleCleanLog(arg1); | |||
3271 | ||||
3272 | return SWIG_arg; | |||
3273 | ||||
3274 | if(0) SWIG_fail{goto fail;}; | |||
3275 | ||||
3276 | fail: | |||
3277 | lua_error(L); | |||
3278 | return SWIG_arg; | |||
3279 | } | |||
3280 | ||||
3281 | ||||
3282 | static int _wrap_running(lua_State* L) { | |||
3283 | int SWIG_arg = 0; | |||
3284 | bool result; | |||
3285 | ||||
3286 | SWIG_check_num_args("running",0,0)if (lua_gettop(L)<0 || lua_gettop(L)>0) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","running",0,0,lua_gettop (L)); goto fail;} | |||
3287 | result = (bool)running(); | |||
3288 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
3289 | return SWIG_arg; | |||
3290 | ||||
3291 | if(0) SWIG_fail{goto fail;}; | |||
3292 | ||||
3293 | fail: | |||
3294 | lua_error(L); | |||
3295 | return SWIG_arg; | |||
3296 | } | |||
3297 | ||||
3298 | ||||
3299 | static int _wrap_email(lua_State* L) { | |||
3300 | int SWIG_arg = 0; | |||
3301 | char *arg1 = (char *) 0 ; | |||
3302 | char *arg2 = (char *) 0 ; | |||
3303 | char *arg3 = (char *) NULL__null ; | |||
3304 | char *arg4 = (char *) NULL__null ; | |||
3305 | char *arg5 = (char *) NULL__null ; | |||
3306 | char *arg6 = (char *) NULL__null ; | |||
3307 | char *arg7 = (char *) NULL__null ; | |||
3308 | bool result; | |||
3309 | ||||
3310 | SWIG_check_num_args("email",2,7)if (lua_gettop(L)<2 || lua_gettop(L)>7) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","email",2,7,lua_gettop (L)); goto fail;} | |||
3311 | if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("email",1,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "email",1,"char *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
3312 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("email",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "email",2,"char *",SWIG_Lua_typename(L,2)); goto fail;}; | |||
3313 | if(lua_gettop(L)>=3 && !SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("email",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "email",3,"char *",SWIG_Lua_typename(L,3)); goto fail;}; | |||
3314 | if(lua_gettop(L)>=4 && !SWIG_lua_isnilstring(L,4)) SWIG_fail_arg("email",4,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "email",4,"char *",SWIG_Lua_typename(L,4)); goto fail;}; | |||
3315 | if(lua_gettop(L)>=5 && !SWIG_lua_isnilstring(L,5)) SWIG_fail_arg("email",5,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "email",5,"char *",SWIG_Lua_typename(L,5)); goto fail;}; | |||
3316 | if(lua_gettop(L)>=6 && !SWIG_lua_isnilstring(L,6)) SWIG_fail_arg("email",6,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "email",6,"char *",SWIG_Lua_typename(L,6)); goto fail;}; | |||
3317 | if(lua_gettop(L)>=7 && !SWIG_lua_isnilstring(L,7)) SWIG_fail_arg("email",7,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "email",7,"char *",SWIG_Lua_typename(L,7)); goto fail;}; | |||
3318 | arg1 = (char *)lua_tostring(L, 1)lua_tolstring(L, (1), __null); | |||
3319 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
3320 | if(lua_gettop(L)>=3){ | |||
3321 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
3322 | } | |||
3323 | if(lua_gettop(L)>=4){ | |||
3324 | arg4 = (char *)lua_tostring(L, 4)lua_tolstring(L, (4), __null); | |||
3325 | } | |||
3326 | if(lua_gettop(L)>=5){ | |||
3327 | arg5 = (char *)lua_tostring(L, 5)lua_tolstring(L, (5), __null); | |||
3328 | } | |||
3329 | if(lua_gettop(L)>=6){ | |||
3330 | arg6 = (char *)lua_tostring(L, 6)lua_tolstring(L, (6), __null); | |||
3331 | } | |||
3332 | if(lua_gettop(L)>=7){ | |||
3333 | arg7 = (char *)lua_tostring(L, 7)lua_tolstring(L, (7), __null); | |||
3334 | } | |||
3335 | result = (bool)email(arg1,arg2,arg3,arg4,arg5,arg6,arg7); | |||
3336 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
3337 | return SWIG_arg; | |||
3338 | ||||
3339 | if(0) SWIG_fail{goto fail;}; | |||
3340 | ||||
3341 | fail: | |||
3342 | lua_error(L); | |||
3343 | return SWIG_arg; | |||
3344 | } | |||
3345 | ||||
3346 | ||||
3347 | static int _wrap_new_IVRMenu(lua_State* L) { | |||
3348 | int SWIG_arg = 0; | |||
3349 | IVRMenu *arg1 = (IVRMenu *) 0 ; | |||
3350 | char *arg2 = (char *) 0 ; | |||
3351 | char *arg3 = (char *) 0 ; | |||
3352 | char *arg4 = (char *) 0 ; | |||
3353 | char *arg5 = (char *) 0 ; | |||
3354 | char *arg6 = (char *) 0 ; | |||
3355 | char *arg7 = (char *) 0 ; | |||
3356 | char *arg8 = (char *) 0 ; | |||
3357 | char *arg9 = (char *) 0 ; | |||
3358 | char *arg10 = (char *) 0 ; | |||
3359 | char *arg11 = (char *) 0 ; | |||
3360 | int arg12 ; | |||
3361 | int arg13 ; | |||
3362 | int arg14 ; | |||
3363 | int arg15 ; | |||
3364 | int arg16 ; | |||
3365 | int arg17 ; | |||
3366 | IVRMenu *result = 0 ; | |||
3367 | ||||
3368 | SWIG_check_num_args("IVRMenu::IVRMenu",17,17)if (lua_gettop(L)<17 || lua_gettop(L)>17) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","IVRMenu::IVRMenu" ,17,17,lua_gettop(L)); goto fail;} | |||
3369 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("IVRMenu::IVRMenu",1,"IVRMenu *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::IVRMenu",1,"IVRMenu *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
3370 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("IVRMenu::IVRMenu",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::IVRMenu",2,"char const *",SWIG_Lua_typename(L,2)) ; goto fail;}; | |||
3371 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("IVRMenu::IVRMenu",3,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::IVRMenu",3,"char const *",SWIG_Lua_typename(L,3)) ; goto fail;}; | |||
3372 | if(!SWIG_lua_isnilstring(L,4)) SWIG_fail_arg("IVRMenu::IVRMenu",4,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::IVRMenu",4,"char const *",SWIG_Lua_typename(L,4)) ; goto fail;}; | |||
3373 | if(!SWIG_lua_isnilstring(L,5)) SWIG_fail_arg("IVRMenu::IVRMenu",5,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::IVRMenu",5,"char const *",SWIG_Lua_typename(L,5)) ; goto fail;}; | |||
3374 | if(!SWIG_lua_isnilstring(L,6)) SWIG_fail_arg("IVRMenu::IVRMenu",6,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::IVRMenu",6,"char const *",SWIG_Lua_typename(L,6)) ; goto fail;}; | |||
3375 | if(!SWIG_lua_isnilstring(L,7)) SWIG_fail_arg("IVRMenu::IVRMenu",7,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::IVRMenu",7,"char const *",SWIG_Lua_typename(L,7)) ; goto fail;}; | |||
3376 | if(!SWIG_lua_isnilstring(L,8)) SWIG_fail_arg("IVRMenu::IVRMenu",8,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::IVRMenu",8,"char const *",SWIG_Lua_typename(L,8)) ; goto fail;}; | |||
3377 | if(!SWIG_lua_isnilstring(L,9)) SWIG_fail_arg("IVRMenu::IVRMenu",9,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::IVRMenu",9,"char const *",SWIG_Lua_typename(L,9)) ; goto fail;}; | |||
3378 | if(!SWIG_lua_isnilstring(L,10)) SWIG_fail_arg("IVRMenu::IVRMenu",10,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::IVRMenu",10,"char const *",SWIG_Lua_typename(L,10 )); goto fail;}; | |||
3379 | if(!SWIG_lua_isnilstring(L,11)) SWIG_fail_arg("IVRMenu::IVRMenu",11,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::IVRMenu",11,"char const *",SWIG_Lua_typename(L,11 )); goto fail;}; | |||
3380 | if(!lua_isnumber(L,12)) SWIG_fail_arg("IVRMenu::IVRMenu",12,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::IVRMenu",12,"int",SWIG_Lua_typename(L,12)); goto fail ;}; | |||
3381 | if(!lua_isnumber(L,13)) SWIG_fail_arg("IVRMenu::IVRMenu",13,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::IVRMenu",13,"int",SWIG_Lua_typename(L,13)); goto fail ;}; | |||
3382 | if(!lua_isnumber(L,14)) SWIG_fail_arg("IVRMenu::IVRMenu",14,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::IVRMenu",14,"int",SWIG_Lua_typename(L,14)); goto fail ;}; | |||
3383 | if(!lua_isnumber(L,15)) SWIG_fail_arg("IVRMenu::IVRMenu",15,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::IVRMenu",15,"int",SWIG_Lua_typename(L,15)); goto fail ;}; | |||
3384 | if(!lua_isnumber(L,16)) SWIG_fail_arg("IVRMenu::IVRMenu",16,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::IVRMenu",16,"int",SWIG_Lua_typename(L,16)); goto fail ;}; | |||
3385 | if(!lua_isnumber(L,17)) SWIG_fail_arg("IVRMenu::IVRMenu",17,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::IVRMenu",17,"int",SWIG_Lua_typename(L,17)); goto fail ;}; | |||
3386 | ||||
3387 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_IVRMenu,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[5],0) >= 0)){ | |||
3388 | SWIG_fail_ptr("new_IVRMenu",1,SWIGTYPE_p_IVRMenu){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "new_IVRMenu",1,(swig_types[5] && swig_types[5]-> str)?swig_types[5]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
3389 | } | |||
3390 | ||||
3391 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
3392 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
3393 | arg4 = (char *)lua_tostring(L, 4)lua_tolstring(L, (4), __null); | |||
3394 | arg5 = (char *)lua_tostring(L, 5)lua_tolstring(L, (5), __null); | |||
3395 | arg6 = (char *)lua_tostring(L, 6)lua_tolstring(L, (6), __null); | |||
3396 | arg7 = (char *)lua_tostring(L, 7)lua_tolstring(L, (7), __null); | |||
3397 | arg8 = (char *)lua_tostring(L, 8)lua_tolstring(L, (8), __null); | |||
3398 | arg9 = (char *)lua_tostring(L, 9)lua_tolstring(L, (9), __null); | |||
3399 | arg10 = (char *)lua_tostring(L, 10)lua_tolstring(L, (10), __null); | |||
3400 | arg11 = (char *)lua_tostring(L, 11)lua_tolstring(L, (11), __null); | |||
3401 | arg12 = (int)lua_tonumber(L, 12)lua_tonumberx(L,12,__null); | |||
3402 | arg13 = (int)lua_tonumber(L, 13)lua_tonumberx(L,13,__null); | |||
3403 | arg14 = (int)lua_tonumber(L, 14)lua_tonumberx(L,14,__null); | |||
3404 | arg15 = (int)lua_tonumber(L, 15)lua_tonumberx(L,15,__null); | |||
3405 | arg16 = (int)lua_tonumber(L, 16)lua_tonumberx(L,16,__null); | |||
3406 | arg17 = (int)lua_tonumber(L, 17)lua_tonumberx(L,17,__null); | |||
3407 | result = (IVRMenu *)new IVRMenu(arg1,(char const *)arg2,(char const *)arg3,(char const *)arg4,(char const *)arg5,(char const *)arg6,(char const *)arg7,(char const *)arg8,(char const *)arg9,(char const *)arg10,(char const *)arg11,arg12,arg13,arg14,arg15,arg16,arg17); | |||
3408 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_IVRMenu,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[5], 1); SWIG_arg++; | |||
3409 | return SWIG_arg; | |||
3410 | ||||
3411 | if(0) SWIG_fail{goto fail;}; | |||
3412 | ||||
3413 | fail: | |||
3414 | lua_error(L); | |||
3415 | return SWIG_arg; | |||
3416 | } | |||
3417 | ||||
3418 | ||||
3419 | static int _wrap_IVRMenu_bindAction(lua_State* L) { | |||
3420 | int SWIG_arg = 0; | |||
3421 | IVRMenu *arg1 = (IVRMenu *) 0 ; | |||
3422 | char *arg2 = (char *) 0 ; | |||
3423 | char *arg3 = (char *) 0 ; | |||
3424 | char *arg4 = (char *) 0 ; | |||
3425 | ||||
3426 | SWIG_check_num_args("IVRMenu::bindAction",4,4)if (lua_gettop(L)<4 || lua_gettop(L)>4) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","IVRMenu::bindAction" ,4,4,lua_gettop(L)); goto fail;} | |||
3427 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("IVRMenu::bindAction",1,"IVRMenu *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::bindAction",1,"IVRMenu *",SWIG_Lua_typename(L,1)) ; goto fail;}; | |||
3428 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("IVRMenu::bindAction",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::bindAction",2,"char *",SWIG_Lua_typename(L,2)); goto fail;}; | |||
3429 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("IVRMenu::bindAction",3,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::bindAction",3,"char const *",SWIG_Lua_typename(L, 3)); goto fail;}; | |||
3430 | if(!SWIG_lua_isnilstring(L,4)) SWIG_fail_arg("IVRMenu::bindAction",4,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::bindAction",4,"char const *",SWIG_Lua_typename(L, 4)); goto fail;}; | |||
3431 | ||||
3432 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_IVRMenu,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[5],0) >= 0)){ | |||
3433 | SWIG_fail_ptr("IVRMenu_bindAction",1,SWIGTYPE_p_IVRMenu){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu_bindAction",1,(swig_types[5] && swig_types [5]->str)?swig_types[5]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
3434 | } | |||
3435 | ||||
3436 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
3437 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
3438 | arg4 = (char *)lua_tostring(L, 4)lua_tolstring(L, (4), __null); | |||
3439 | (arg1)->bindAction(arg2,(char const *)arg3,(char const *)arg4); | |||
3440 | ||||
3441 | return SWIG_arg; | |||
3442 | ||||
3443 | if(0) SWIG_fail{goto fail;}; | |||
3444 | ||||
3445 | fail: | |||
3446 | lua_error(L); | |||
3447 | return SWIG_arg; | |||
3448 | } | |||
3449 | ||||
3450 | ||||
3451 | static int _wrap_IVRMenu_execute(lua_State* L) { | |||
3452 | int SWIG_arg = 0; | |||
3453 | IVRMenu *arg1 = (IVRMenu *) 0 ; | |||
3454 | CoreSession *arg2 = (CoreSession *) 0 ; | |||
3455 | char *arg3 = (char *) 0 ; | |||
3456 | ||||
3457 | SWIG_check_num_args("IVRMenu::execute",3,3)if (lua_gettop(L)<3 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","IVRMenu::execute" ,3,3,lua_gettop(L)); goto fail;} | |||
3458 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("IVRMenu::execute",1,"IVRMenu *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::execute",1,"IVRMenu *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
3459 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("IVRMenu::execute",2,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::execute",2,"CoreSession *",SWIG_Lua_typename(L,2) ); goto fail;}; | |||
3460 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("IVRMenu::execute",3,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu::execute",3,"char const *",SWIG_Lua_typename(L,3)) ; goto fail;}; | |||
3461 | ||||
3462 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_IVRMenu,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[5],0) >= 0)){ | |||
3463 | SWIG_fail_ptr("IVRMenu_execute",1,SWIGTYPE_p_IVRMenu){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu_execute",1,(swig_types[5] && swig_types[5] ->str)?swig_types[5]->str:"void*",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
3464 | } | |||
3465 | ||||
3466 | ||||
3467 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&arg2,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&arg2,swig_types[1],0) >= 0)){ | |||
3468 | SWIG_fail_ptr("IVRMenu_execute",2,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "IVRMenu_execute",2,(swig_types[1] && swig_types[1] ->str)?swig_types[1]->str:"void*",SWIG_Lua_typename(L,2 )); goto fail;}; | |||
3469 | } | |||
3470 | ||||
3471 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
3472 | (arg1)->execute(arg2,(char const *)arg3); | |||
3473 | ||||
3474 | return SWIG_arg; | |||
3475 | ||||
3476 | if(0) SWIG_fail{goto fail;}; | |||
3477 | ||||
3478 | fail: | |||
3479 | lua_error(L); | |||
3480 | return SWIG_arg; | |||
3481 | } | |||
3482 | ||||
3483 | ||||
3484 | static void swig_delete_IVRMenu(void *obj) { | |||
3485 | IVRMenu *arg1 = (IVRMenu *) obj; | |||
3486 | delete arg1; | |||
3487 | } | |||
3488 | static int _proxy__wrap_new_IVRMenu(lua_State *L) { | |||
3489 | assert(lua_istable(L,1))(static_cast <bool> ((lua_type(L, (1)) == 5)) ? void (0 ) : __assert_fail ("lua_istable(L,1)", "mod_lua_wrap.cpp", 3489 , __extension__ __PRETTY_FUNCTION__)); | |||
3490 | lua_pushcfunction(L,_wrap_new_IVRMenu)lua_pushcclosure(L, (_wrap_new_IVRMenu), 0); | |||
3491 | assert(!lua_isnil(L,-1))(static_cast <bool> (!(lua_type(L, (-1)) == 0)) ? void ( 0) : __assert_fail ("!lua_isnil(L,-1)", "mod_lua_wrap.cpp", 3491 , __extension__ __PRETTY_FUNCTION__)); | |||
3492 | lua_replace(L,1); /* replace our table with real constructor */ | |||
3493 | lua_call(L,lua_gettop(L)-1,1)lua_callk(L, (lua_gettop(L)-1), (1), 0, __null); | |||
3494 | return 1; | |||
3495 | } | |||
3496 | static swig_lua_attribute swig_IVRMenu_attributes[] = { | |||
3497 | {0,0,0} | |||
3498 | }; | |||
3499 | static swig_lua_method swig_IVRMenu_methods[]= { | |||
3500 | { "bindAction", _wrap_IVRMenu_bindAction}, | |||
3501 | { "execute", _wrap_IVRMenu_execute}, | |||
3502 | {0,0} | |||
3503 | }; | |||
3504 | static swig_lua_method swig_IVRMenu_meta[] = { | |||
3505 | {0,0} | |||
3506 | }; | |||
3507 | ||||
3508 | static swig_lua_attribute swig_IVRMenu_Sf_SwigStatic_attributes[] = { | |||
3509 | {0,0,0} | |||
3510 | }; | |||
3511 | static swig_lua_const_info swig_IVRMenu_Sf_SwigStatic_constants[]= { | |||
3512 | {0,0,0,0,0,0} | |||
3513 | }; | |||
3514 | static swig_lua_method swig_IVRMenu_Sf_SwigStatic_methods[]= { | |||
3515 | {0,0} | |||
3516 | }; | |||
3517 | static swig_lua_class* swig_IVRMenu_Sf_SwigStatic_classes[]= { | |||
3518 | 0 | |||
3519 | }; | |||
3520 | ||||
3521 | static swig_lua_namespace swig_IVRMenu_Sf_SwigStatic = { | |||
3522 | "IVRMenu", | |||
3523 | swig_IVRMenu_Sf_SwigStatic_methods, | |||
3524 | swig_IVRMenu_Sf_SwigStatic_attributes, | |||
3525 | swig_IVRMenu_Sf_SwigStatic_constants, | |||
3526 | swig_IVRMenu_Sf_SwigStatic_classes, | |||
3527 | 0 | |||
3528 | }; | |||
3529 | static swig_lua_class *swig_IVRMenu_bases[] = {0}; | |||
3530 | static const char *swig_IVRMenu_base_names[] = {0}; | |||
3531 | static swig_lua_class _wrap_class_IVRMenu = { "IVRMenu", "IVRMenu", &SWIGTYPE_p_IVRMenuswig_types[5],_proxy__wrap_new_IVRMenu, swig_delete_IVRMenu, swig_IVRMenu_methods, swig_IVRMenu_attributes, &swig_IVRMenu_Sf_SwigStatic, swig_IVRMenu_meta, swig_IVRMenu_bases, swig_IVRMenu_base_names }; | |||
3532 | ||||
3533 | static int _wrap_new_API(lua_State* L) { | |||
3534 | int SWIG_arg = 0; | |||
3535 | CoreSession *arg1 = (CoreSession *) NULL__null ; | |||
3536 | API *result = 0 ; | |||
3537 | ||||
3538 | SWIG_check_num_args("API::API",0,1)if (lua_gettop(L)<0 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","API::API",0,1, lua_gettop(L)); goto fail;} | |||
3539 | if(lua_gettop(L)>=1 && !SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("API::API",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "API::API",1,"CoreSession *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
3540 | if(lua_gettop(L)>=1){ | |||
3541 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
3542 | SWIG_fail_ptr("new_API",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "new_API",1,(swig_types[1] && swig_types[1]->str )?swig_types[1]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
3543 | } | |||
3544 | } | |||
3545 | result = (API *)new API(arg1); | |||
3546 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_API,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[0], 1); SWIG_arg++; | |||
3547 | return SWIG_arg; | |||
3548 | ||||
3549 | if(0) SWIG_fail{goto fail;}; | |||
3550 | ||||
3551 | fail: | |||
3552 | lua_error(L); | |||
3553 | return SWIG_arg; | |||
3554 | } | |||
3555 | ||||
3556 | ||||
3557 | static int _wrap_API_execute(lua_State* L) { | |||
3558 | int SWIG_arg = 0; | |||
3559 | API *arg1 = (API *) 0 ; | |||
3560 | char *arg2 = (char *) 0 ; | |||
3561 | char *arg3 = (char *) NULL__null ; | |||
3562 | char *result = 0 ; | |||
3563 | ||||
3564 | SWIG_check_num_args("API::execute",2,3)if (lua_gettop(L)<2 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","API::execute", 2,3,lua_gettop(L)); goto fail;} | |||
3565 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("API::execute",1,"API *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "API::execute",1,"API *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
3566 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("API::execute",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "API::execute",2,"char const *",SWIG_Lua_typename(L,2)); goto fail;}; | |||
3567 | if(lua_gettop(L)>=3 && !SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("API::execute",3,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "API::execute",3,"char const *",SWIG_Lua_typename(L,3)); goto fail;}; | |||
3568 | ||||
3569 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_API,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[0],0) >= 0)){ | |||
3570 | SWIG_fail_ptr("API_execute",1,SWIGTYPE_p_API){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "API_execute",1,(swig_types[0] && swig_types[0]-> str)?swig_types[0]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
3571 | } | |||
3572 | ||||
3573 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
3574 | if(lua_gettop(L)>=3){ | |||
3575 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
3576 | } | |||
3577 | result = (char *)(arg1)->execute((char const *)arg2,(char const *)arg3); | |||
3578 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
3579 | free(result); | |||
3580 | return SWIG_arg; | |||
3581 | ||||
3582 | if(0) SWIG_fail{goto fail;}; | |||
3583 | ||||
3584 | fail: | |||
3585 | lua_error(L); | |||
3586 | return SWIG_arg; | |||
3587 | } | |||
3588 | ||||
3589 | ||||
3590 | static int _wrap_API_executeString(lua_State* L) { | |||
3591 | int SWIG_arg = 0; | |||
3592 | API *arg1 = (API *) 0 ; | |||
3593 | char *arg2 = (char *) 0 ; | |||
3594 | char *result = 0 ; | |||
3595 | ||||
3596 | SWIG_check_num_args("API::executeString",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","API::executeString" ,2,2,lua_gettop(L)); goto fail;} | |||
3597 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("API::executeString",1,"API *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "API::executeString",1,"API *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
3598 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("API::executeString",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "API::executeString",2,"char const *",SWIG_Lua_typename(L,2 )); goto fail;}; | |||
3599 | ||||
3600 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_API,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[0],0) >= 0)){ | |||
3601 | SWIG_fail_ptr("API_executeString",1,SWIGTYPE_p_API){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "API_executeString",1,(swig_types[0] && swig_types[ 0]->str)?swig_types[0]->str:"void*",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
3602 | } | |||
3603 | ||||
3604 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
3605 | result = (char *)(arg1)->executeString((char const *)arg2); | |||
3606 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
3607 | free(result); | |||
3608 | return SWIG_arg; | |||
3609 | ||||
3610 | if(0) SWIG_fail{goto fail;}; | |||
3611 | ||||
3612 | fail: | |||
3613 | lua_error(L); | |||
3614 | return SWIG_arg; | |||
3615 | } | |||
3616 | ||||
3617 | ||||
3618 | static int _wrap_API_getTime(lua_State* L) { | |||
3619 | int SWIG_arg = 0; | |||
3620 | API *arg1 = (API *) 0 ; | |||
3621 | char *result = 0 ; | |||
3622 | ||||
3623 | SWIG_check_num_args("API::getTime",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","API::getTime", 1,1,lua_gettop(L)); goto fail;} | |||
3624 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("API::getTime",1,"API *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "API::getTime",1,"API *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
3625 | ||||
3626 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_API,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[0],0) >= 0)){ | |||
3627 | SWIG_fail_ptr("API_getTime",1,SWIGTYPE_p_API){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "API_getTime",1,(swig_types[0] && swig_types[0]-> str)?swig_types[0]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
3628 | } | |||
3629 | ||||
3630 | result = (char *)(arg1)->getTime(); | |||
3631 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
3632 | return SWIG_arg; | |||
3633 | ||||
3634 | if(0) SWIG_fail{goto fail;}; | |||
3635 | ||||
3636 | fail: | |||
3637 | lua_error(L); | |||
3638 | return SWIG_arg; | |||
3639 | } | |||
3640 | ||||
3641 | ||||
3642 | static void swig_delete_API(void *obj) { | |||
3643 | API *arg1 = (API *) obj; | |||
3644 | delete arg1; | |||
3645 | } | |||
3646 | static int _proxy__wrap_new_API(lua_State *L) { | |||
3647 | assert(lua_istable(L,1))(static_cast <bool> ((lua_type(L, (1)) == 5)) ? void (0 ) : __assert_fail ("lua_istable(L,1)", "mod_lua_wrap.cpp", 3647 , __extension__ __PRETTY_FUNCTION__)); | |||
3648 | lua_pushcfunction(L,_wrap_new_API)lua_pushcclosure(L, (_wrap_new_API), 0); | |||
3649 | assert(!lua_isnil(L,-1))(static_cast <bool> (!(lua_type(L, (-1)) == 0)) ? void ( 0) : __assert_fail ("!lua_isnil(L,-1)", "mod_lua_wrap.cpp", 3649 , __extension__ __PRETTY_FUNCTION__)); | |||
3650 | lua_replace(L,1); /* replace our table with real constructor */ | |||
3651 | lua_call(L,lua_gettop(L)-1,1)lua_callk(L, (lua_gettop(L)-1), (1), 0, __null); | |||
3652 | return 1; | |||
3653 | } | |||
3654 | static swig_lua_attribute swig_API_attributes[] = { | |||
3655 | {0,0,0} | |||
3656 | }; | |||
3657 | static swig_lua_method swig_API_methods[]= { | |||
3658 | { "execute", _wrap_API_execute}, | |||
3659 | { "executeString", _wrap_API_executeString}, | |||
3660 | { "getTime", _wrap_API_getTime}, | |||
3661 | {0,0} | |||
3662 | }; | |||
3663 | static swig_lua_method swig_API_meta[] = { | |||
3664 | {0,0} | |||
3665 | }; | |||
3666 | ||||
3667 | static swig_lua_attribute swig_API_Sf_SwigStatic_attributes[] = { | |||
3668 | {0,0,0} | |||
3669 | }; | |||
3670 | static swig_lua_const_info swig_API_Sf_SwigStatic_constants[]= { | |||
3671 | {0,0,0,0,0,0} | |||
3672 | }; | |||
3673 | static swig_lua_method swig_API_Sf_SwigStatic_methods[]= { | |||
3674 | {0,0} | |||
3675 | }; | |||
3676 | static swig_lua_class* swig_API_Sf_SwigStatic_classes[]= { | |||
3677 | 0 | |||
3678 | }; | |||
3679 | ||||
3680 | static swig_lua_namespace swig_API_Sf_SwigStatic = { | |||
3681 | "API", | |||
3682 | swig_API_Sf_SwigStatic_methods, | |||
3683 | swig_API_Sf_SwigStatic_attributes, | |||
3684 | swig_API_Sf_SwigStatic_constants, | |||
3685 | swig_API_Sf_SwigStatic_classes, | |||
3686 | 0 | |||
3687 | }; | |||
3688 | static swig_lua_class *swig_API_bases[] = {0}; | |||
3689 | static const char *swig_API_base_names[] = {0}; | |||
3690 | static swig_lua_class _wrap_class_API = { "API", "API", &SWIGTYPE_p_APIswig_types[0],_proxy__wrap_new_API, swig_delete_API, swig_API_methods, swig_API_attributes, &swig_API_Sf_SwigStatic, swig_API_meta, swig_API_bases, swig_API_base_names }; | |||
3691 | ||||
3692 | static int _wrap_input_callback_state_t_c_function_set(lua_State* L) { | |||
3693 | int SWIG_arg = 0; | |||
3694 | input_callback_state *arg1 = (input_callback_state *) 0 ; | |||
3695 | void *arg2 = (void *) 0 ; | |||
3696 | ||||
3697 | SWIG_check_num_args("input_callback_state::function",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","input_callback_state::function" ,2,2,lua_gettop(L)); goto fail;} | |||
3698 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("input_callback_state::function",1,"input_callback_state *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state::function",1,"input_callback_state *" ,SWIG_Lua_typename(L,1)); goto fail;}; | |||
3699 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("input_callback_state::function",2,"void *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state::function",2,"void *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
3700 | ||||
3701 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_input_callback_state,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[11],0) >= 0)){ | |||
3702 | SWIG_fail_ptr("input_callback_state_t_c_function_set",1,SWIGTYPE_p_input_callback_state){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state_t_c_function_set",1,(swig_types[11] && swig_types[11]->str)?swig_types[11]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
3703 | } | |||
3704 | ||||
3705 | arg2=(void *)SWIG_MustGetPtr(L,2,0,0,2,"input_callback_state_t_c_function_set")SWIG_Lua_MustGetPtr(L,2, 0,0, 2,"input_callback_state_t_c_function_set" ); | |||
3706 | if (arg1) (arg1)->function = arg2; | |||
3707 | ||||
3708 | return SWIG_arg; | |||
3709 | ||||
3710 | if(0) SWIG_fail{goto fail;}; | |||
3711 | ||||
3712 | fail: | |||
3713 | lua_error(L); | |||
3714 | return SWIG_arg; | |||
3715 | } | |||
3716 | ||||
3717 | ||||
3718 | static int _wrap_input_callback_state_t_c_function_get(lua_State* L) { | |||
3719 | int SWIG_arg = 0; | |||
3720 | input_callback_state *arg1 = (input_callback_state *) 0 ; | |||
3721 | void *result = 0 ; | |||
3722 | ||||
3723 | SWIG_check_num_args("input_callback_state::function",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","input_callback_state::function" ,1,1,lua_gettop(L)); goto fail;} | |||
3724 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("input_callback_state::function",1,"input_callback_state *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state::function",1,"input_callback_state *" ,SWIG_Lua_typename(L,1)); goto fail;}; | |||
3725 | ||||
3726 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_input_callback_state,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[11],0) >= 0)){ | |||
3727 | SWIG_fail_ptr("input_callback_state_t_c_function_get",1,SWIGTYPE_p_input_callback_state){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state_t_c_function_get",1,(swig_types[11] && swig_types[11]->str)?swig_types[11]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
3728 | } | |||
3729 | ||||
3730 | result = (void *) ((arg1)->function); | |||
3731 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_void,0)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[31], 0); SWIG_arg++; | |||
3732 | return SWIG_arg; | |||
3733 | ||||
3734 | if(0) SWIG_fail{goto fail;}; | |||
3735 | ||||
3736 | fail: | |||
3737 | lua_error(L); | |||
3738 | return SWIG_arg; | |||
3739 | } | |||
3740 | ||||
3741 | ||||
3742 | static int _wrap_input_callback_state_t_threadState_set(lua_State* L) { | |||
3743 | int SWIG_arg = 0; | |||
3744 | input_callback_state *arg1 = (input_callback_state *) 0 ; | |||
3745 | void *arg2 = (void *) 0 ; | |||
3746 | ||||
3747 | SWIG_check_num_args("input_callback_state::threadState",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","input_callback_state::threadState" ,2,2,lua_gettop(L)); goto fail;} | |||
3748 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("input_callback_state::threadState",1,"input_callback_state *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state::threadState",1,"input_callback_state *" ,SWIG_Lua_typename(L,1)); goto fail;}; | |||
3749 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("input_callback_state::threadState",2,"void *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state::threadState",2,"void *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
3750 | ||||
3751 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_input_callback_state,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[11],0) >= 0)){ | |||
3752 | SWIG_fail_ptr("input_callback_state_t_threadState_set",1,SWIGTYPE_p_input_callback_state){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state_t_threadState_set",1,(swig_types[11] && swig_types[11]->str)?swig_types[11]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
3753 | } | |||
3754 | ||||
3755 | arg2=(void *)SWIG_MustGetPtr(L,2,0,0,2,"input_callback_state_t_threadState_set")SWIG_Lua_MustGetPtr(L,2, 0,0, 2,"input_callback_state_t_threadState_set" ); | |||
3756 | if (arg1) (arg1)->threadState = arg2; | |||
3757 | ||||
3758 | return SWIG_arg; | |||
3759 | ||||
3760 | if(0) SWIG_fail{goto fail;}; | |||
3761 | ||||
3762 | fail: | |||
3763 | lua_error(L); | |||
3764 | return SWIG_arg; | |||
3765 | } | |||
3766 | ||||
3767 | ||||
3768 | static int _wrap_input_callback_state_t_threadState_get(lua_State* L) { | |||
3769 | int SWIG_arg = 0; | |||
3770 | input_callback_state *arg1 = (input_callback_state *) 0 ; | |||
3771 | void *result = 0 ; | |||
3772 | ||||
3773 | SWIG_check_num_args("input_callback_state::threadState",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","input_callback_state::threadState" ,1,1,lua_gettop(L)); goto fail;} | |||
3774 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("input_callback_state::threadState",1,"input_callback_state *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state::threadState",1,"input_callback_state *" ,SWIG_Lua_typename(L,1)); goto fail;}; | |||
3775 | ||||
3776 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_input_callback_state,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[11],0) >= 0)){ | |||
3777 | SWIG_fail_ptr("input_callback_state_t_threadState_get",1,SWIGTYPE_p_input_callback_state){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state_t_threadState_get",1,(swig_types[11] && swig_types[11]->str)?swig_types[11]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
3778 | } | |||
3779 | ||||
3780 | result = (void *) ((arg1)->threadState); | |||
3781 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_void,0)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[31], 0); SWIG_arg++; | |||
3782 | return SWIG_arg; | |||
3783 | ||||
3784 | if(0) SWIG_fail{goto fail;}; | |||
3785 | ||||
3786 | fail: | |||
3787 | lua_error(L); | |||
3788 | return SWIG_arg; | |||
3789 | } | |||
3790 | ||||
3791 | ||||
3792 | static int _wrap_input_callback_state_t_extra_set(lua_State* L) { | |||
3793 | int SWIG_arg = 0; | |||
3794 | input_callback_state *arg1 = (input_callback_state *) 0 ; | |||
3795 | void *arg2 = (void *) 0 ; | |||
3796 | ||||
3797 | SWIG_check_num_args("input_callback_state::extra",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","input_callback_state::extra" ,2,2,lua_gettop(L)); goto fail;} | |||
3798 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("input_callback_state::extra",1,"input_callback_state *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state::extra",1,"input_callback_state *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
3799 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("input_callback_state::extra",2,"void *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state::extra",2,"void *",SWIG_Lua_typename( L,2)); goto fail;}; | |||
3800 | ||||
3801 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_input_callback_state,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[11],0) >= 0)){ | |||
3802 | SWIG_fail_ptr("input_callback_state_t_extra_set",1,SWIGTYPE_p_input_callback_state){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state_t_extra_set",1,(swig_types[11] && swig_types[11]->str)?swig_types[11]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
3803 | } | |||
3804 | ||||
3805 | arg2=(void *)SWIG_MustGetPtr(L,2,0,0,2,"input_callback_state_t_extra_set")SWIG_Lua_MustGetPtr(L,2, 0,0, 2,"input_callback_state_t_extra_set" ); | |||
3806 | if (arg1) (arg1)->extra = arg2; | |||
3807 | ||||
3808 | return SWIG_arg; | |||
3809 | ||||
3810 | if(0) SWIG_fail{goto fail;}; | |||
3811 | ||||
3812 | fail: | |||
3813 | lua_error(L); | |||
3814 | return SWIG_arg; | |||
3815 | } | |||
3816 | ||||
3817 | ||||
3818 | static int _wrap_input_callback_state_t_extra_get(lua_State* L) { | |||
3819 | int SWIG_arg = 0; | |||
3820 | input_callback_state *arg1 = (input_callback_state *) 0 ; | |||
3821 | void *result = 0 ; | |||
3822 | ||||
3823 | SWIG_check_num_args("input_callback_state::extra",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","input_callback_state::extra" ,1,1,lua_gettop(L)); goto fail;} | |||
3824 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("input_callback_state::extra",1,"input_callback_state *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state::extra",1,"input_callback_state *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
3825 | ||||
3826 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_input_callback_state,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[11],0) >= 0)){ | |||
3827 | SWIG_fail_ptr("input_callback_state_t_extra_get",1,SWIGTYPE_p_input_callback_state){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state_t_extra_get",1,(swig_types[11] && swig_types[11]->str)?swig_types[11]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
3828 | } | |||
3829 | ||||
3830 | result = (void *) ((arg1)->extra); | |||
3831 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_void,0)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[31], 0); SWIG_arg++; | |||
3832 | return SWIG_arg; | |||
3833 | ||||
3834 | if(0) SWIG_fail{goto fail;}; | |||
3835 | ||||
3836 | fail: | |||
3837 | lua_error(L); | |||
3838 | return SWIG_arg; | |||
3839 | } | |||
3840 | ||||
3841 | ||||
3842 | static int _wrap_input_callback_state_t_funcargs_set(lua_State* L) { | |||
3843 | int SWIG_arg = 0; | |||
3844 | input_callback_state *arg1 = (input_callback_state *) 0 ; | |||
3845 | char *arg2 = (char *) 0 ; | |||
3846 | ||||
3847 | SWIG_check_num_args("input_callback_state::funcargs",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","input_callback_state::funcargs" ,2,2,lua_gettop(L)); goto fail;} | |||
3848 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("input_callback_state::funcargs",1,"input_callback_state *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state::funcargs",1,"input_callback_state *" ,SWIG_Lua_typename(L,1)); goto fail;}; | |||
3849 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("input_callback_state::funcargs",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state::funcargs",2,"char *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
3850 | ||||
3851 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_input_callback_state,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[11],0) >= 0)){ | |||
3852 | SWIG_fail_ptr("input_callback_state_t_funcargs_set",1,SWIGTYPE_p_input_callback_state){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state_t_funcargs_set",1,(swig_types[11] && swig_types[11]->str)?swig_types[11]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
3853 | } | |||
3854 | ||||
3855 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
3856 | { | |||
3857 | delete [] arg1->funcargs; | |||
3858 | if (arg2) { | |||
3859 | arg1->funcargs = (char *) (new char[strlen((const char *)arg2)+1]); | |||
3860 | strcpy((char *)arg1->funcargs, (const char *)arg2); | |||
3861 | } else { | |||
3862 | arg1->funcargs = 0; | |||
3863 | } | |||
3864 | } | |||
3865 | ||||
3866 | return SWIG_arg; | |||
3867 | ||||
3868 | if(0) SWIG_fail{goto fail;}; | |||
3869 | ||||
3870 | fail: | |||
3871 | lua_error(L); | |||
3872 | return SWIG_arg; | |||
3873 | } | |||
3874 | ||||
3875 | ||||
3876 | static int _wrap_input_callback_state_t_funcargs_get(lua_State* L) { | |||
3877 | int SWIG_arg = 0; | |||
3878 | input_callback_state *arg1 = (input_callback_state *) 0 ; | |||
3879 | char *result = 0 ; | |||
3880 | ||||
3881 | SWIG_check_num_args("input_callback_state::funcargs",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","input_callback_state::funcargs" ,1,1,lua_gettop(L)); goto fail;} | |||
3882 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("input_callback_state::funcargs",1,"input_callback_state *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state::funcargs",1,"input_callback_state *" ,SWIG_Lua_typename(L,1)); goto fail;}; | |||
3883 | ||||
3884 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_input_callback_state,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[11],0) >= 0)){ | |||
3885 | SWIG_fail_ptr("input_callback_state_t_funcargs_get",1,SWIGTYPE_p_input_callback_state){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "input_callback_state_t_funcargs_get",1,(swig_types[11] && swig_types[11]->str)?swig_types[11]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
3886 | } | |||
3887 | ||||
3888 | result = (char *) ((arg1)->funcargs); | |||
3889 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
3890 | return SWIG_arg; | |||
3891 | ||||
3892 | if(0) SWIG_fail{goto fail;}; | |||
3893 | ||||
3894 | fail: | |||
3895 | lua_error(L); | |||
3896 | return SWIG_arg; | |||
3897 | } | |||
3898 | ||||
3899 | ||||
3900 | static int _wrap_new_input_callback_state_t(lua_State* L) { | |||
3901 | int SWIG_arg = 0; | |||
3902 | input_callback_state *result = 0 ; | |||
3903 | ||||
3904 | SWIG_check_num_args("input_callback_state::input_callback_state",0,0)if (lua_gettop(L)<0 || lua_gettop(L)>0) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","input_callback_state::input_callback_state" ,0,0,lua_gettop(L)); goto fail;} | |||
3905 | result = (input_callback_state *)new input_callback_state(); | |||
3906 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_input_callback_state,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[11], 1); SWIG_arg++; | |||
3907 | return SWIG_arg; | |||
3908 | ||||
3909 | if(0) SWIG_fail{goto fail;}; | |||
3910 | ||||
3911 | fail: | |||
3912 | lua_error(L); | |||
3913 | return SWIG_arg; | |||
3914 | } | |||
3915 | ||||
3916 | ||||
3917 | static void swig_delete_input_callback_state_t(void *obj) { | |||
3918 | input_callback_state *arg1 = (input_callback_state *) obj; | |||
3919 | delete arg1; | |||
3920 | } | |||
3921 | static int _proxy__wrap_new_input_callback_state_t(lua_State *L) { | |||
3922 | assert(lua_istable(L,1))(static_cast <bool> ((lua_type(L, (1)) == 5)) ? void (0 ) : __assert_fail ("lua_istable(L,1)", "mod_lua_wrap.cpp", 3922 , __extension__ __PRETTY_FUNCTION__)); | |||
3923 | lua_pushcfunction(L,_wrap_new_input_callback_state_t)lua_pushcclosure(L, (_wrap_new_input_callback_state_t), 0); | |||
3924 | assert(!lua_isnil(L,-1))(static_cast <bool> (!(lua_type(L, (-1)) == 0)) ? void ( 0) : __assert_fail ("!lua_isnil(L,-1)", "mod_lua_wrap.cpp", 3924 , __extension__ __PRETTY_FUNCTION__)); | |||
3925 | lua_replace(L,1); /* replace our table with real constructor */ | |||
3926 | lua_call(L,lua_gettop(L)-1,1)lua_callk(L, (lua_gettop(L)-1), (1), 0, __null); | |||
3927 | return 1; | |||
3928 | } | |||
3929 | static swig_lua_attribute swig_input_callback_state_t_attributes[] = { | |||
3930 | { "c_function", _wrap_input_callback_state_t_c_function_get, _wrap_input_callback_state_t_c_function_set }, | |||
3931 | { "threadState", _wrap_input_callback_state_t_threadState_get, _wrap_input_callback_state_t_threadState_set }, | |||
3932 | { "extra", _wrap_input_callback_state_t_extra_get, _wrap_input_callback_state_t_extra_set }, | |||
3933 | { "funcargs", _wrap_input_callback_state_t_funcargs_get, _wrap_input_callback_state_t_funcargs_set }, | |||
3934 | {0,0,0} | |||
3935 | }; | |||
3936 | static swig_lua_method swig_input_callback_state_t_methods[]= { | |||
3937 | {0,0} | |||
3938 | }; | |||
3939 | static swig_lua_method swig_input_callback_state_t_meta[] = { | |||
3940 | {0,0} | |||
3941 | }; | |||
3942 | ||||
3943 | static swig_lua_attribute swig_input_callback_state_t_Sf_SwigStatic_attributes[] = { | |||
3944 | {0,0,0} | |||
3945 | }; | |||
3946 | static swig_lua_const_info swig_input_callback_state_t_Sf_SwigStatic_constants[]= { | |||
3947 | {0,0,0,0,0,0} | |||
3948 | }; | |||
3949 | static swig_lua_method swig_input_callback_state_t_Sf_SwigStatic_methods[]= { | |||
3950 | {0,0} | |||
3951 | }; | |||
3952 | static swig_lua_class* swig_input_callback_state_t_Sf_SwigStatic_classes[]= { | |||
3953 | 0 | |||
3954 | }; | |||
3955 | ||||
3956 | static swig_lua_namespace swig_input_callback_state_t_Sf_SwigStatic = { | |||
3957 | "input_callback_state_t", | |||
3958 | swig_input_callback_state_t_Sf_SwigStatic_methods, | |||
3959 | swig_input_callback_state_t_Sf_SwigStatic_attributes, | |||
3960 | swig_input_callback_state_t_Sf_SwigStatic_constants, | |||
3961 | swig_input_callback_state_t_Sf_SwigStatic_classes, | |||
3962 | 0 | |||
3963 | }; | |||
3964 | static swig_lua_class *swig_input_callback_state_t_bases[] = {0}; | |||
3965 | static const char *swig_input_callback_state_t_base_names[] = {0}; | |||
3966 | static swig_lua_class _wrap_class_input_callback_state_t = { "input_callback_state_t", "input_callback_state_t", &SWIGTYPE_p_input_callback_stateswig_types[11],_proxy__wrap_new_input_callback_state_t, swig_delete_input_callback_state_t, swig_input_callback_state_t_methods, swig_input_callback_state_t_attributes, &swig_input_callback_state_t_Sf_SwigStatic, swig_input_callback_state_t_meta, swig_input_callback_state_t_bases, swig_input_callback_state_t_base_names }; | |||
3967 | ||||
3968 | static int _wrap_DTMF_digit_set(lua_State* L) { | |||
3969 | int SWIG_arg = 0; | |||
3970 | DTMF *arg1 = (DTMF *) 0 ; | |||
3971 | char arg2 ; | |||
3972 | ||||
3973 | SWIG_check_num_args("DTMF::digit",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","DTMF::digit",2 ,2,lua_gettop(L)); goto fail;} | |||
3974 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("DTMF::digit",1,"DTMF *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "DTMF::digit",1,"DTMF *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
3975 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("DTMF::digit",2,"char"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "DTMF::digit",2,"char",SWIG_Lua_typename(L,2)); goto fail;}; | |||
3976 | ||||
3977 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_DTMF,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[2],0) >= 0)){ | |||
3978 | SWIG_fail_ptr("DTMF_digit_set",1,SWIGTYPE_p_DTMF){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "DTMF_digit_set",1,(swig_types[2] && swig_types[2]-> str)?swig_types[2]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
3979 | } | |||
3980 | ||||
3981 | arg2 = (lua_tostring(L, 2)lua_tolstring(L, (2), __null))[0]; | |||
3982 | if (arg1) (arg1)->digit = arg2; | |||
3983 | ||||
3984 | return SWIG_arg; | |||
3985 | ||||
3986 | if(0) SWIG_fail{goto fail;}; | |||
3987 | ||||
3988 | fail: | |||
3989 | lua_error(L); | |||
3990 | return SWIG_arg; | |||
3991 | } | |||
3992 | ||||
3993 | ||||
3994 | static int _wrap_DTMF_digit_get(lua_State* L) { | |||
3995 | int SWIG_arg = 0; | |||
3996 | DTMF *arg1 = (DTMF *) 0 ; | |||
3997 | char result; | |||
3998 | ||||
3999 | SWIG_check_num_args("DTMF::digit",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","DTMF::digit",1 ,1,lua_gettop(L)); goto fail;} | |||
4000 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("DTMF::digit",1,"DTMF *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "DTMF::digit",1,"DTMF *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
4001 | ||||
4002 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_DTMF,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[2],0) >= 0)){ | |||
4003 | SWIG_fail_ptr("DTMF_digit_get",1,SWIGTYPE_p_DTMF){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "DTMF_digit_get",1,(swig_types[2] && swig_types[2]-> str)?swig_types[2]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4004 | } | |||
4005 | ||||
4006 | result = (char) ((arg1)->digit); | |||
4007 | lua_pushlstring(L, &result, 1); SWIG_arg++; | |||
4008 | return SWIG_arg; | |||
4009 | ||||
4010 | if(0) SWIG_fail{goto fail;}; | |||
4011 | ||||
4012 | fail: | |||
4013 | lua_error(L); | |||
4014 | return SWIG_arg; | |||
4015 | } | |||
4016 | ||||
4017 | ||||
4018 | static int _wrap_DTMF_duration_set(lua_State* L) { | |||
4019 | int SWIG_arg = 0; | |||
4020 | DTMF *arg1 = (DTMF *) 0 ; | |||
4021 | uint32_t arg2 ; | |||
4022 | uint32_t *argp2 ; | |||
4023 | ||||
4024 | SWIG_check_num_args("DTMF::duration",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","DTMF::duration" ,2,2,lua_gettop(L)); goto fail;} | |||
4025 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("DTMF::duration",1,"DTMF *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "DTMF::duration",1,"DTMF *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
4026 | if(!lua_isuserdata(L,2)) SWIG_fail_arg("DTMF::duration",2,"uint32_t"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "DTMF::duration",2,"uint32_t",SWIG_Lua_typename(L,2)); goto fail;}; | |||
4027 | ||||
4028 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_DTMF,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[2],0) >= 0)){ | |||
4029 | SWIG_fail_ptr("DTMF_duration_set",1,SWIGTYPE_p_DTMF){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "DTMF_duration_set",1,(swig_types[2] && swig_types[ 2]->str)?swig_types[2]->str:"void*",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
4030 | } | |||
4031 | ||||
4032 | ||||
4033 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&argp2,SWIGTYPE_p_uint32_t,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&argp2,swig_types[30],0) >= 0)){ | |||
4034 | SWIG_fail_ptr("DTMF_duration_set",2,SWIGTYPE_p_uint32_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "DTMF_duration_set",2,(swig_types[30] && swig_types [30]->str)?swig_types[30]->str:"void*",SWIG_Lua_typename (L,2)); goto fail;}; | |||
4035 | } | |||
4036 | arg2 = *argp2; | |||
4037 | ||||
4038 | if (arg1) (arg1)->duration = arg2; | |||
4039 | ||||
4040 | return SWIG_arg; | |||
4041 | ||||
4042 | if(0) SWIG_fail{goto fail;}; | |||
4043 | ||||
4044 | fail: | |||
4045 | lua_error(L); | |||
4046 | return SWIG_arg; | |||
4047 | } | |||
4048 | ||||
4049 | ||||
4050 | static int _wrap_DTMF_duration_get(lua_State* L) { | |||
4051 | int SWIG_arg = 0; | |||
4052 | DTMF *arg1 = (DTMF *) 0 ; | |||
4053 | uint32_t result; | |||
4054 | ||||
4055 | SWIG_check_num_args("DTMF::duration",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","DTMF::duration" ,1,1,lua_gettop(L)); goto fail;} | |||
4056 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("DTMF::duration",1,"DTMF *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "DTMF::duration",1,"DTMF *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
4057 | ||||
4058 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_DTMF,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[2],0) >= 0)){ | |||
4059 | SWIG_fail_ptr("DTMF_duration_get",1,SWIGTYPE_p_DTMF){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "DTMF_duration_get",1,(swig_types[2] && swig_types[ 2]->str)?swig_types[2]->str:"void*",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
4060 | } | |||
4061 | ||||
4062 | result = ((arg1)->duration); | |||
4063 | { | |||
4064 | uint32_t * resultptr = new uint32_t((const uint32_t &) result); | |||
4065 | SWIG_NewPointerObj(L,(void *) resultptr,SWIGTYPE_p_uint32_t,1)SWIG_Lua_NewPointerObj(L, (void *)(void *) resultptr, swig_types [30], 1); SWIG_arg++; | |||
4066 | } | |||
4067 | return SWIG_arg; | |||
4068 | ||||
4069 | if(0) SWIG_fail{goto fail;}; | |||
4070 | ||||
4071 | fail: | |||
4072 | lua_error(L); | |||
4073 | return SWIG_arg; | |||
4074 | } | |||
4075 | ||||
4076 | ||||
4077 | static int _wrap_new_DTMF(lua_State* L) { | |||
4078 | int SWIG_arg = 0; | |||
4079 | char arg1 ; | |||
4080 | uint32_t arg2 = (uint32_t) SWITCH_DEFAULT_DTMF_DURATION2000 ; | |||
4081 | uint32_t *argp2 ; | |||
4082 | DTMF *result = 0 ; | |||
4083 | ||||
4084 | SWIG_check_num_args("DTMF::DTMF",1,2)if (lua_gettop(L)<1 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","DTMF::DTMF",1, 2,lua_gettop(L)); goto fail;} | |||
4085 | if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("DTMF::DTMF",1,"char"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "DTMF::DTMF",1,"char",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4086 | if(lua_gettop(L)>=2 && !lua_isuserdata(L,2)) SWIG_fail_arg("DTMF::DTMF",2,"uint32_t"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "DTMF::DTMF",2,"uint32_t",SWIG_Lua_typename(L,2)); goto fail ;}; | |||
4087 | arg1 = (lua_tostring(L, 1)lua_tolstring(L, (1), __null))[0]; | |||
4088 | if(lua_gettop(L)>=2){ | |||
4089 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&argp2,SWIGTYPE_p_uint32_t,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&argp2,swig_types[30],0) >= 0)){ | |||
4090 | SWIG_fail_ptr("new_DTMF",2,SWIGTYPE_p_uint32_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "new_DTMF",2,(swig_types[30] && swig_types[30]-> str)?swig_types[30]->str:"void*",SWIG_Lua_typename(L,2)); goto fail;}; | |||
4091 | } | |||
4092 | arg2 = *argp2; | |||
4093 | } | |||
4094 | result = (DTMF *)new DTMF(arg1,arg2); | |||
4095 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_DTMF,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[2], 1); SWIG_arg++; | |||
4096 | return SWIG_arg; | |||
4097 | ||||
4098 | if(0) SWIG_fail{goto fail;}; | |||
4099 | ||||
4100 | fail: | |||
4101 | lua_error(L); | |||
4102 | return SWIG_arg; | |||
4103 | } | |||
4104 | ||||
4105 | ||||
4106 | static void swig_delete_DTMF(void *obj) { | |||
4107 | DTMF *arg1 = (DTMF *) obj; | |||
4108 | delete arg1; | |||
4109 | } | |||
4110 | static int _proxy__wrap_new_DTMF(lua_State *L) { | |||
4111 | assert(lua_istable(L,1))(static_cast <bool> ((lua_type(L, (1)) == 5)) ? void (0 ) : __assert_fail ("lua_istable(L,1)", "mod_lua_wrap.cpp", 4111 , __extension__ __PRETTY_FUNCTION__)); | |||
4112 | lua_pushcfunction(L,_wrap_new_DTMF)lua_pushcclosure(L, (_wrap_new_DTMF), 0); | |||
4113 | assert(!lua_isnil(L,-1))(static_cast <bool> (!(lua_type(L, (-1)) == 0)) ? void ( 0) : __assert_fail ("!lua_isnil(L,-1)", "mod_lua_wrap.cpp", 4113 , __extension__ __PRETTY_FUNCTION__)); | |||
4114 | lua_replace(L,1); /* replace our table with real constructor */ | |||
4115 | lua_call(L,lua_gettop(L)-1,1)lua_callk(L, (lua_gettop(L)-1), (1), 0, __null); | |||
4116 | return 1; | |||
4117 | } | |||
4118 | static swig_lua_attribute swig_DTMF_attributes[] = { | |||
4119 | { "digit", _wrap_DTMF_digit_get, _wrap_DTMF_digit_set }, | |||
4120 | { "duration", _wrap_DTMF_duration_get, _wrap_DTMF_duration_set }, | |||
4121 | {0,0,0} | |||
4122 | }; | |||
4123 | static swig_lua_method swig_DTMF_methods[]= { | |||
4124 | {0,0} | |||
4125 | }; | |||
4126 | static swig_lua_method swig_DTMF_meta[] = { | |||
4127 | {0,0} | |||
4128 | }; | |||
4129 | ||||
4130 | static swig_lua_attribute swig_DTMF_Sf_SwigStatic_attributes[] = { | |||
4131 | {0,0,0} | |||
4132 | }; | |||
4133 | static swig_lua_const_info swig_DTMF_Sf_SwigStatic_constants[]= { | |||
4134 | {0,0,0,0,0,0} | |||
4135 | }; | |||
4136 | static swig_lua_method swig_DTMF_Sf_SwigStatic_methods[]= { | |||
4137 | {0,0} | |||
4138 | }; | |||
4139 | static swig_lua_class* swig_DTMF_Sf_SwigStatic_classes[]= { | |||
4140 | 0 | |||
4141 | }; | |||
4142 | ||||
4143 | static swig_lua_namespace swig_DTMF_Sf_SwigStatic = { | |||
4144 | "DTMF", | |||
4145 | swig_DTMF_Sf_SwigStatic_methods, | |||
4146 | swig_DTMF_Sf_SwigStatic_attributes, | |||
4147 | swig_DTMF_Sf_SwigStatic_constants, | |||
4148 | swig_DTMF_Sf_SwigStatic_classes, | |||
4149 | 0 | |||
4150 | }; | |||
4151 | static swig_lua_class *swig_DTMF_bases[] = {0}; | |||
4152 | static const char *swig_DTMF_base_names[] = {0}; | |||
4153 | static swig_lua_class _wrap_class_DTMF = { "DTMF", "DTMF", &SWIGTYPE_p_DTMFswig_types[2],_proxy__wrap_new_DTMF, swig_delete_DTMF, swig_DTMF_methods, swig_DTMF_attributes, &swig_DTMF_Sf_SwigStatic, swig_DTMF_meta, swig_DTMF_bases, swig_DTMF_base_names }; | |||
4154 | ||||
4155 | static int _wrap_new_Stream__SWIG_0(lua_State* L) { | |||
4156 | int SWIG_arg = 0; | |||
4157 | Stream *result = 0 ; | |||
4158 | ||||
4159 | SWIG_check_num_args("Stream::Stream",0,0)if (lua_gettop(L)<0 || lua_gettop(L)>0) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Stream::Stream" ,0,0,lua_gettop(L)); goto fail;} | |||
4160 | result = (Stream *)new Stream(); | |||
4161 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_Stream,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[10], 1); SWIG_arg++; | |||
4162 | return SWIG_arg; | |||
4163 | ||||
4164 | if(0) SWIG_fail{goto fail;}; | |||
4165 | ||||
4166 | fail: | |||
4167 | lua_error(L); | |||
4168 | return SWIG_arg; | |||
4169 | } | |||
4170 | ||||
4171 | ||||
4172 | static int _wrap_new_Stream__SWIG_1(lua_State* L) { | |||
4173 | int SWIG_arg = 0; | |||
4174 | switch_stream_handle_t *arg1 = (switch_stream_handle_t *) 0 ; | |||
4175 | Stream *result = 0 ; | |||
4176 | ||||
4177 | SWIG_check_num_args("Stream::Stream",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Stream::Stream" ,1,1,lua_gettop(L)); goto fail;} | |||
4178 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Stream::Stream",1,"switch_stream_handle_t *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Stream::Stream",1,"switch_stream_handle_t *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
4179 | ||||
4180 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_switch_stream_handle_t,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[29],0) >= 0)){ | |||
4181 | SWIG_fail_ptr("new_Stream",1,SWIGTYPE_p_switch_stream_handle_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "new_Stream",1,(swig_types[29] && swig_types[29]-> str)?swig_types[29]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4182 | } | |||
4183 | ||||
4184 | result = (Stream *)new Stream(arg1); | |||
4185 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_Stream,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[10], 1); SWIG_arg++; | |||
4186 | return SWIG_arg; | |||
4187 | ||||
4188 | if(0) SWIG_fail{goto fail;}; | |||
4189 | ||||
4190 | fail: | |||
4191 | lua_error(L); | |||
4192 | return SWIG_arg; | |||
4193 | } | |||
4194 | ||||
4195 | ||||
4196 | static int _wrap_new_Stream(lua_State* L) { | |||
4197 | int argc; | |||
4198 | int argv[2]={ | |||
4199 | 1,2 | |||
4200 | }; | |||
4201 | ||||
4202 | argc = lua_gettop(L); | |||
4203 | if (argc == 0) { | |||
4204 | return _wrap_new_Stream__SWIG_0(L); | |||
4205 | } | |||
4206 | if (argc == 1) { | |||
4207 | int _v; | |||
4208 | { | |||
4209 | void *ptr; | |||
4210 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_switch_stream_handle_t, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[29 ],0)) { | |||
4211 | _v = 0; | |||
4212 | } else { | |||
4213 | _v = 1; | |||
4214 | } | |||
4215 | } | |||
4216 | if (_v) { | |||
4217 | return _wrap_new_Stream__SWIG_1(L); | |||
4218 | } | |||
4219 | } | |||
4220 | ||||
4221 | SWIG_Lua_pusherrstring(L,"Wrong arguments for overloaded function 'new_Stream'\n" | |||
4222 | " Possible C/C++ prototypes are:\n" | |||
4223 | " Stream::Stream()\n" | |||
4224 | " Stream::Stream(switch_stream_handle_t *)\n"); | |||
4225 | lua_error(L);return 0; | |||
4226 | } | |||
4227 | ||||
4228 | ||||
4229 | static int _wrap_Stream_read(lua_State* L) { | |||
4230 | int SWIG_arg = 0; | |||
4231 | Stream *arg1 = (Stream *) 0 ; | |||
4232 | int *arg2 = (int *) 0 ; | |||
4233 | int temp2 ; | |||
4234 | char *result = 0 ; | |||
4235 | ||||
4236 | arg2 = &temp2; | |||
4237 | SWIG_check_num_args("Stream::read",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Stream::read", 1,1,lua_gettop(L)); goto fail;} | |||
4238 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Stream::read",1,"Stream *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Stream::read",1,"Stream *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
4239 | ||||
4240 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Stream,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[10],0) >= 0)){ | |||
4241 | SWIG_fail_ptr("Stream_read",1,SWIGTYPE_p_Stream){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Stream_read",1,(swig_types[10] && swig_types[10]-> str)?swig_types[10]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4242 | } | |||
4243 | ||||
4244 | result = (char *)(arg1)->read(arg2); | |||
4245 | lua_pushlstring(L,(const char*)result, (*arg2)); SWIG_arg++; | |||
4246 | lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++; | |||
4247 | return SWIG_arg; | |||
4248 | ||||
4249 | if(0) SWIG_fail{goto fail;}; | |||
4250 | ||||
4251 | fail: | |||
4252 | lua_error(L); | |||
4253 | return SWIG_arg; | |||
4254 | } | |||
4255 | ||||
4256 | ||||
4257 | static int _wrap_Stream_write(lua_State* L) { | |||
4258 | int SWIG_arg = 0; | |||
4259 | Stream *arg1 = (Stream *) 0 ; | |||
4260 | char *arg2 = (char *) 0 ; | |||
4261 | ||||
4262 | SWIG_check_num_args("Stream::write",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Stream::write" ,2,2,lua_gettop(L)); goto fail;} | |||
4263 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Stream::write",1,"Stream *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Stream::write",1,"Stream *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
4264 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("Stream::write",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Stream::write",2,"char const *",SWIG_Lua_typename(L,2)); goto fail;}; | |||
4265 | ||||
4266 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Stream,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[10],0) >= 0)){ | |||
4267 | SWIG_fail_ptr("Stream_write",1,SWIGTYPE_p_Stream){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Stream_write",1,(swig_types[10] && swig_types[10]-> str)?swig_types[10]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4268 | } | |||
4269 | ||||
4270 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
4271 | (arg1)->write((char const *)arg2); | |||
4272 | ||||
4273 | return SWIG_arg; | |||
4274 | ||||
4275 | if(0) SWIG_fail{goto fail;}; | |||
4276 | ||||
4277 | fail: | |||
4278 | lua_error(L); | |||
4279 | return SWIG_arg; | |||
4280 | } | |||
4281 | ||||
4282 | ||||
4283 | static int _wrap_Stream_raw_write(lua_State* L) { | |||
4284 | int SWIG_arg = 0; | |||
4285 | Stream *arg1 = (Stream *) 0 ; | |||
4286 | char *arg2 = (char *) 0 ; | |||
4287 | int arg3 ; | |||
4288 | ||||
4289 | SWIG_check_num_args("Stream::raw_write",3,3)if (lua_gettop(L)<3 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Stream::raw_write" ,3,3,lua_gettop(L)); goto fail;} | |||
4290 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Stream::raw_write",1,"Stream *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Stream::raw_write",1,"Stream *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4291 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("Stream::raw_write",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Stream::raw_write",2,"char const *",SWIG_Lua_typename(L,2) ); goto fail;}; | |||
4292 | if(!lua_isnumber(L,3)) SWIG_fail_arg("Stream::raw_write",3,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Stream::raw_write",3,"int",SWIG_Lua_typename(L,3)); goto fail ;}; | |||
4293 | ||||
4294 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Stream,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[10],0) >= 0)){ | |||
4295 | SWIG_fail_ptr("Stream_raw_write",1,SWIGTYPE_p_Stream){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Stream_raw_write",1,(swig_types[10] && swig_types[ 10]->str)?swig_types[10]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
4296 | } | |||
4297 | ||||
4298 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
4299 | arg3 = (int)lua_tonumber(L, 3)lua_tonumberx(L,3,__null); | |||
4300 | (arg1)->raw_write((char const *)arg2,arg3); | |||
4301 | ||||
4302 | return SWIG_arg; | |||
4303 | ||||
4304 | if(0) SWIG_fail{goto fail;}; | |||
4305 | ||||
4306 | fail: | |||
4307 | lua_error(L); | |||
4308 | return SWIG_arg; | |||
4309 | } | |||
4310 | ||||
4311 | ||||
4312 | static int _wrap_Stream_get_data(lua_State* L) { | |||
4313 | int SWIG_arg = 0; | |||
4314 | Stream *arg1 = (Stream *) 0 ; | |||
4315 | char *result = 0 ; | |||
4316 | ||||
4317 | SWIG_check_num_args("Stream::get_data",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Stream::get_data" ,1,1,lua_gettop(L)); goto fail;} | |||
4318 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Stream::get_data",1,"Stream *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Stream::get_data",1,"Stream *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4319 | ||||
4320 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Stream,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[10],0) >= 0)){ | |||
4321 | SWIG_fail_ptr("Stream_get_data",1,SWIGTYPE_p_Stream){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Stream_get_data",1,(swig_types[10] && swig_types[10 ]->str)?swig_types[10]->str:"void*",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
4322 | } | |||
4323 | ||||
4324 | result = (char *)(arg1)->get_data(); | |||
4325 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
4326 | return SWIG_arg; | |||
4327 | ||||
4328 | if(0) SWIG_fail{goto fail;}; | |||
4329 | ||||
4330 | fail: | |||
4331 | lua_error(L); | |||
4332 | return SWIG_arg; | |||
4333 | } | |||
4334 | ||||
4335 | ||||
4336 | static void swig_delete_Stream(void *obj) { | |||
4337 | Stream *arg1 = (Stream *) obj; | |||
4338 | delete arg1; | |||
4339 | } | |||
4340 | static int _proxy__wrap_new_Stream(lua_State *L) { | |||
4341 | assert(lua_istable(L,1))(static_cast <bool> ((lua_type(L, (1)) == 5)) ? void (0 ) : __assert_fail ("lua_istable(L,1)", "mod_lua_wrap.cpp", 4341 , __extension__ __PRETTY_FUNCTION__)); | |||
4342 | lua_pushcfunction(L,_wrap_new_Stream)lua_pushcclosure(L, (_wrap_new_Stream), 0); | |||
4343 | assert(!lua_isnil(L,-1))(static_cast <bool> (!(lua_type(L, (-1)) == 0)) ? void ( 0) : __assert_fail ("!lua_isnil(L,-1)", "mod_lua_wrap.cpp", 4343 , __extension__ __PRETTY_FUNCTION__)); | |||
4344 | lua_replace(L,1); /* replace our table with real constructor */ | |||
4345 | lua_call(L,lua_gettop(L)-1,1)lua_callk(L, (lua_gettop(L)-1), (1), 0, __null); | |||
4346 | return 1; | |||
4347 | } | |||
4348 | static swig_lua_attribute swig_Stream_attributes[] = { | |||
4349 | {0,0,0} | |||
4350 | }; | |||
4351 | static swig_lua_method swig_Stream_methods[]= { | |||
4352 | { "read", _wrap_Stream_read}, | |||
4353 | { "write", _wrap_Stream_write}, | |||
4354 | { "raw_write", _wrap_Stream_raw_write}, | |||
4355 | { "get_data", _wrap_Stream_get_data}, | |||
4356 | {0,0} | |||
4357 | }; | |||
4358 | static swig_lua_method swig_Stream_meta[] = { | |||
4359 | {0,0} | |||
4360 | }; | |||
4361 | ||||
4362 | static swig_lua_attribute swig_Stream_Sf_SwigStatic_attributes[] = { | |||
4363 | {0,0,0} | |||
4364 | }; | |||
4365 | static swig_lua_const_info swig_Stream_Sf_SwigStatic_constants[]= { | |||
4366 | {0,0,0,0,0,0} | |||
4367 | }; | |||
4368 | static swig_lua_method swig_Stream_Sf_SwigStatic_methods[]= { | |||
4369 | {0,0} | |||
4370 | }; | |||
4371 | static swig_lua_class* swig_Stream_Sf_SwigStatic_classes[]= { | |||
4372 | 0 | |||
4373 | }; | |||
4374 | ||||
4375 | static swig_lua_namespace swig_Stream_Sf_SwigStatic = { | |||
4376 | "Stream", | |||
4377 | swig_Stream_Sf_SwigStatic_methods, | |||
4378 | swig_Stream_Sf_SwigStatic_attributes, | |||
4379 | swig_Stream_Sf_SwigStatic_constants, | |||
4380 | swig_Stream_Sf_SwigStatic_classes, | |||
4381 | 0 | |||
4382 | }; | |||
4383 | static swig_lua_class *swig_Stream_bases[] = {0}; | |||
4384 | static const char *swig_Stream_base_names[] = {0}; | |||
4385 | static swig_lua_class _wrap_class_Stream = { "Stream", "Stream", &SWIGTYPE_p_Streamswig_types[10],_proxy__wrap_new_Stream, swig_delete_Stream, swig_Stream_methods, swig_Stream_attributes, &swig_Stream_Sf_SwigStatic, swig_Stream_meta, swig_Stream_bases, swig_Stream_base_names }; | |||
4386 | ||||
4387 | static int _wrap_Event_event_set(lua_State* L) { | |||
4388 | int SWIG_arg = 0; | |||
4389 | Event *arg1 = (Event *) 0 ; | |||
4390 | switch_event_t *arg2 = (switch_event_t *) 0 ; | |||
4391 | ||||
4392 | SWIG_check_num_args("Event::event",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::event", 2,2,lua_gettop(L)); goto fail;} | |||
4393 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::event",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::event",1,"Event *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
4394 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("Event::event",2,"switch_event_t *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::event",2,"switch_event_t *",SWIG_Lua_typename(L,2)) ; goto fail;}; | |||
4395 | ||||
4396 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4397 | SWIG_fail_ptr("Event_event_set",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_event_set",1,(swig_types[3] && swig_types[3] ->str)?swig_types[3]->str:"void*",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
4398 | } | |||
4399 | ||||
4400 | ||||
4401 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&arg2,SWIGTYPE_p_switch_event_t,SWIG_POINTER_DISOWN))(SWIG_Lua_ConvertPtr(L,2,(void**)&arg2,swig_types[21],0x1 ) >= 0)){ | |||
4402 | SWIG_fail_ptr("Event_event_set",2,SWIGTYPE_p_switch_event_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_event_set",2,(swig_types[21] && swig_types[21 ]->str)?swig_types[21]->str:"void*",SWIG_Lua_typename(L ,2)); goto fail;}; | |||
4403 | } | |||
4404 | ||||
4405 | if (arg1) (arg1)->event = arg2; | |||
4406 | ||||
4407 | return SWIG_arg; | |||
4408 | ||||
4409 | if(0) SWIG_fail{goto fail;}; | |||
4410 | ||||
4411 | fail: | |||
4412 | lua_error(L); | |||
4413 | return SWIG_arg; | |||
4414 | } | |||
4415 | ||||
4416 | ||||
4417 | static int _wrap_Event_event_get(lua_State* L) { | |||
4418 | int SWIG_arg = 0; | |||
4419 | Event *arg1 = (Event *) 0 ; | |||
4420 | switch_event_t *result = 0 ; | |||
4421 | ||||
4422 | SWIG_check_num_args("Event::event",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::event", 1,1,lua_gettop(L)); goto fail;} | |||
4423 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::event",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::event",1,"Event *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
4424 | ||||
4425 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4426 | SWIG_fail_ptr("Event_event_get",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_event_get",1,(swig_types[3] && swig_types[3] ->str)?swig_types[3]->str:"void*",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
4427 | } | |||
4428 | ||||
4429 | result = (switch_event_t *) ((arg1)->event); | |||
4430 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_switch_event_t,0)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[21], 0); SWIG_arg++; | |||
4431 | return SWIG_arg; | |||
4432 | ||||
4433 | if(0) SWIG_fail{goto fail;}; | |||
4434 | ||||
4435 | fail: | |||
4436 | lua_error(L); | |||
4437 | return SWIG_arg; | |||
4438 | } | |||
4439 | ||||
4440 | ||||
4441 | static int _wrap_Event_serialized_string_set(lua_State* L) { | |||
4442 | int SWIG_arg = 0; | |||
4443 | Event *arg1 = (Event *) 0 ; | |||
4444 | char *arg2 = (char *) 0 ; | |||
4445 | ||||
4446 | SWIG_check_num_args("Event::serialized_string",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::serialized_string" ,2,2,lua_gettop(L)); goto fail;} | |||
4447 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::serialized_string",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::serialized_string",1,"Event *",SWIG_Lua_typename(L, 1)); goto fail;}; | |||
4448 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("Event::serialized_string",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::serialized_string",2,"char *",SWIG_Lua_typename(L,2 )); goto fail;}; | |||
4449 | ||||
4450 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4451 | SWIG_fail_ptr("Event_serialized_string_set",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_serialized_string_set",1,(swig_types[3] && swig_types [3]->str)?swig_types[3]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
4452 | } | |||
4453 | ||||
4454 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
4455 | { | |||
4456 | delete [] arg1->serialized_string; | |||
4457 | if (arg2) { | |||
4458 | arg1->serialized_string = (char *) (new char[strlen((const char *)arg2)+1]); | |||
4459 | strcpy((char *)arg1->serialized_string, (const char *)arg2); | |||
4460 | } else { | |||
4461 | arg1->serialized_string = 0; | |||
4462 | } | |||
4463 | } | |||
4464 | ||||
4465 | return SWIG_arg; | |||
4466 | ||||
4467 | if(0) SWIG_fail{goto fail;}; | |||
4468 | ||||
4469 | fail: | |||
4470 | lua_error(L); | |||
4471 | return SWIG_arg; | |||
4472 | } | |||
4473 | ||||
4474 | ||||
4475 | static int _wrap_Event_serialized_string_get(lua_State* L) { | |||
4476 | int SWIG_arg = 0; | |||
4477 | Event *arg1 = (Event *) 0 ; | |||
4478 | char *result = 0 ; | |||
4479 | ||||
4480 | SWIG_check_num_args("Event::serialized_string",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::serialized_string" ,1,1,lua_gettop(L)); goto fail;} | |||
4481 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::serialized_string",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::serialized_string",1,"Event *",SWIG_Lua_typename(L, 1)); goto fail;}; | |||
4482 | ||||
4483 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4484 | SWIG_fail_ptr("Event_serialized_string_get",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_serialized_string_get",1,(swig_types[3] && swig_types [3]->str)?swig_types[3]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
4485 | } | |||
4486 | ||||
4487 | result = (char *) ((arg1)->serialized_string); | |||
4488 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
4489 | return SWIG_arg; | |||
4490 | ||||
4491 | if(0) SWIG_fail{goto fail;}; | |||
4492 | ||||
4493 | fail: | |||
4494 | lua_error(L); | |||
4495 | return SWIG_arg; | |||
4496 | } | |||
4497 | ||||
4498 | ||||
4499 | static int _wrap_Event_mine_set(lua_State* L) { | |||
4500 | int SWIG_arg = 0; | |||
4501 | Event *arg1 = (Event *) 0 ; | |||
4502 | int arg2 ; | |||
4503 | ||||
4504 | SWIG_check_num_args("Event::mine",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::mine",2 ,2,lua_gettop(L)); goto fail;} | |||
4505 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::mine",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::mine",1,"Event *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
4506 | if(!lua_isnumber(L,2)) SWIG_fail_arg("Event::mine",2,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::mine",2,"int",SWIG_Lua_typename(L,2)); goto fail;}; | |||
4507 | ||||
4508 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4509 | SWIG_fail_ptr("Event_mine_set",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_mine_set",1,(swig_types[3] && swig_types[3]-> str)?swig_types[3]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4510 | } | |||
4511 | ||||
4512 | arg2 = (int)lua_tonumber(L, 2)lua_tonumberx(L,2,__null); | |||
4513 | if (arg1) (arg1)->mine = arg2; | |||
4514 | ||||
4515 | return SWIG_arg; | |||
4516 | ||||
4517 | if(0) SWIG_fail{goto fail;}; | |||
4518 | ||||
4519 | fail: | |||
4520 | lua_error(L); | |||
4521 | return SWIG_arg; | |||
4522 | } | |||
4523 | ||||
4524 | ||||
4525 | static int _wrap_Event_mine_get(lua_State* L) { | |||
4526 | int SWIG_arg = 0; | |||
4527 | Event *arg1 = (Event *) 0 ; | |||
4528 | int result; | |||
4529 | ||||
4530 | SWIG_check_num_args("Event::mine",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::mine",1 ,1,lua_gettop(L)); goto fail;} | |||
4531 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::mine",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::mine",1,"Event *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
4532 | ||||
4533 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4534 | SWIG_fail_ptr("Event_mine_get",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_mine_get",1,(swig_types[3] && swig_types[3]-> str)?swig_types[3]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4535 | } | |||
4536 | ||||
4537 | result = (int) ((arg1)->mine); | |||
4538 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
4539 | return SWIG_arg; | |||
4540 | ||||
4541 | if(0) SWIG_fail{goto fail;}; | |||
4542 | ||||
4543 | fail: | |||
4544 | lua_error(L); | |||
4545 | return SWIG_arg; | |||
4546 | } | |||
4547 | ||||
4548 | ||||
4549 | static int _wrap_new_Event__SWIG_0(lua_State* L) { | |||
4550 | int SWIG_arg = 0; | |||
4551 | char *arg1 = (char *) 0 ; | |||
4552 | char *arg2 = (char *) NULL__null ; | |||
4553 | Event *result = 0 ; | |||
4554 | ||||
4555 | SWIG_check_num_args("Event::Event",1,2)if (lua_gettop(L)<1 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::Event", 1,2,lua_gettop(L)); goto fail;} | |||
4556 | if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("Event::Event",1,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::Event",1,"char const *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4557 | if(lua_gettop(L)>=2 && !SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("Event::Event",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::Event",2,"char const *",SWIG_Lua_typename(L,2)); goto fail;}; | |||
4558 | arg1 = (char *)lua_tostring(L, 1)lua_tolstring(L, (1), __null); | |||
4559 | if(lua_gettop(L)>=2){ | |||
4560 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
4561 | } | |||
4562 | result = (Event *)new Event((char const *)arg1,(char const *)arg2); | |||
4563 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_Event,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[3], 1); SWIG_arg++; | |||
4564 | return SWIG_arg; | |||
4565 | ||||
4566 | if(0) SWIG_fail{goto fail;}; | |||
4567 | ||||
4568 | fail: | |||
4569 | lua_error(L); | |||
4570 | return SWIG_arg; | |||
4571 | } | |||
4572 | ||||
4573 | ||||
4574 | static int _wrap_new_Event__SWIG_1(lua_State* L) { | |||
4575 | int SWIG_arg = 0; | |||
4576 | switch_event_t *arg1 = (switch_event_t *) 0 ; | |||
4577 | int arg2 = (int) 0 ; | |||
4578 | Event *result = 0 ; | |||
4579 | ||||
4580 | SWIG_check_num_args("Event::Event",1,2)if (lua_gettop(L)<1 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::Event", 1,2,lua_gettop(L)); goto fail;} | |||
4581 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::Event",1,"switch_event_t *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::Event",1,"switch_event_t *",SWIG_Lua_typename(L,1)) ; goto fail;}; | |||
4582 | if(lua_gettop(L)>=2 && !lua_isnumber(L,2)) SWIG_fail_arg("Event::Event",2,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::Event",2,"int",SWIG_Lua_typename(L,2)); goto fail;}; | |||
4583 | ||||
4584 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_switch_event_t,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[21],0) >= 0)){ | |||
4585 | SWIG_fail_ptr("new_Event",1,SWIGTYPE_p_switch_event_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "new_Event",1,(swig_types[21] && swig_types[21]-> str)?swig_types[21]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4586 | } | |||
4587 | ||||
4588 | if(lua_gettop(L)>=2){ | |||
4589 | arg2 = (int)lua_tonumber(L, 2)lua_tonumberx(L,2,__null); | |||
4590 | } | |||
4591 | result = (Event *)new Event(arg1,arg2); | |||
4592 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_Event,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[3], 1); SWIG_arg++; | |||
4593 | return SWIG_arg; | |||
4594 | ||||
4595 | if(0) SWIG_fail{goto fail;}; | |||
4596 | ||||
4597 | fail: | |||
4598 | lua_error(L); | |||
4599 | return SWIG_arg; | |||
4600 | } | |||
4601 | ||||
4602 | ||||
4603 | static int _wrap_new_Event(lua_State* L) { | |||
4604 | int argc; | |||
4605 | int argv[3]={ | |||
4606 | 1,2,3 | |||
4607 | }; | |||
4608 | ||||
4609 | argc = lua_gettop(L); | |||
4610 | if ((argc >= 1) && (argc <= 2)) { | |||
4611 | int _v; | |||
4612 | { | |||
4613 | void *ptr; | |||
4614 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_switch_event_t, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[21 ],0)) { | |||
4615 | _v = 0; | |||
4616 | } else { | |||
4617 | _v = 1; | |||
4618 | } | |||
4619 | } | |||
4620 | if (_v) { | |||
4621 | if (argc <= 1) { | |||
4622 | return _wrap_new_Event__SWIG_1(L); | |||
4623 | } | |||
4624 | { | |||
4625 | _v = lua_isnumber(L,argv[1]); | |||
4626 | } | |||
4627 | if (_v) { | |||
4628 | return _wrap_new_Event__SWIG_1(L); | |||
4629 | } | |||
4630 | } | |||
4631 | } | |||
4632 | if ((argc >= 1) && (argc <= 2)) { | |||
4633 | int _v; | |||
4634 | { | |||
4635 | _v = SWIG_lua_isnilstring(L,argv[0]); | |||
4636 | } | |||
4637 | if (_v) { | |||
4638 | if (argc <= 1) { | |||
4639 | return _wrap_new_Event__SWIG_0(L); | |||
4640 | } | |||
4641 | { | |||
4642 | _v = SWIG_lua_isnilstring(L,argv[1]); | |||
4643 | } | |||
4644 | if (_v) { | |||
4645 | return _wrap_new_Event__SWIG_0(L); | |||
4646 | } | |||
4647 | } | |||
4648 | } | |||
4649 | ||||
4650 | SWIG_Lua_pusherrstring(L,"Wrong arguments for overloaded function 'new_Event'\n" | |||
4651 | " Possible C/C++ prototypes are:\n" | |||
4652 | " Event::Event(char const *,char const *)\n" | |||
4653 | " Event::Event(switch_event_t *,int)\n"); | |||
4654 | lua_error(L);return 0; | |||
4655 | } | |||
4656 | ||||
4657 | ||||
4658 | static int _wrap_Event_chat_execute(lua_State* L) { | |||
4659 | int SWIG_arg = 0; | |||
4660 | Event *arg1 = (Event *) 0 ; | |||
4661 | char *arg2 = (char *) 0 ; | |||
4662 | char *arg3 = (char *) NULL__null ; | |||
4663 | int result; | |||
4664 | ||||
4665 | SWIG_check_num_args("Event::chat_execute",2,3)if (lua_gettop(L)<2 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::chat_execute" ,2,3,lua_gettop(L)); goto fail;} | |||
4666 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::chat_execute",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::chat_execute",1,"Event *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4667 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("Event::chat_execute",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::chat_execute",2,"char const *",SWIG_Lua_typename(L, 2)); goto fail;}; | |||
4668 | if(lua_gettop(L)>=3 && !SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("Event::chat_execute",3,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::chat_execute",3,"char const *",SWIG_Lua_typename(L, 3)); goto fail;}; | |||
4669 | ||||
4670 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4671 | SWIG_fail_ptr("Event_chat_execute",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_chat_execute",1,(swig_types[3] && swig_types [3]->str)?swig_types[3]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
4672 | } | |||
4673 | ||||
4674 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
4675 | if(lua_gettop(L)>=3){ | |||
4676 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
4677 | } | |||
4678 | result = (int)(arg1)->chat_execute((char const *)arg2,(char const *)arg3); | |||
4679 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
4680 | return SWIG_arg; | |||
4681 | ||||
4682 | if(0) SWIG_fail{goto fail;}; | |||
4683 | ||||
4684 | fail: | |||
4685 | lua_error(L); | |||
4686 | return SWIG_arg; | |||
4687 | } | |||
4688 | ||||
4689 | ||||
4690 | static int _wrap_Event_chat_send(lua_State* L) { | |||
4691 | int SWIG_arg = 0; | |||
4692 | Event *arg1 = (Event *) 0 ; | |||
4693 | char *arg2 = (char *) NULL__null ; | |||
4694 | int result; | |||
4695 | ||||
4696 | SWIG_check_num_args("Event::chat_send",1,2)if (lua_gettop(L)<1 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::chat_send" ,1,2,lua_gettop(L)); goto fail;} | |||
4697 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::chat_send",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::chat_send",1,"Event *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4698 | if(lua_gettop(L)>=2 && !SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("Event::chat_send",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::chat_send",2,"char const *",SWIG_Lua_typename(L,2)) ; goto fail;}; | |||
4699 | ||||
4700 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4701 | SWIG_fail_ptr("Event_chat_send",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_chat_send",1,(swig_types[3] && swig_types[3] ->str)?swig_types[3]->str:"void*",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
4702 | } | |||
4703 | ||||
4704 | if(lua_gettop(L)>=2){ | |||
4705 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
4706 | } | |||
4707 | result = (int)(arg1)->chat_send((char const *)arg2); | |||
4708 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
4709 | return SWIG_arg; | |||
4710 | ||||
4711 | if(0) SWIG_fail{goto fail;}; | |||
4712 | ||||
4713 | fail: | |||
4714 | lua_error(L); | |||
4715 | return SWIG_arg; | |||
4716 | } | |||
4717 | ||||
4718 | ||||
4719 | static int _wrap_Event_serialize(lua_State* L) { | |||
4720 | int SWIG_arg = 0; | |||
4721 | Event *arg1 = (Event *) 0 ; | |||
4722 | char *arg2 = (char *) NULL__null ; | |||
4723 | char *result = 0 ; | |||
4724 | ||||
4725 | SWIG_check_num_args("Event::serialize",1,2)if (lua_gettop(L)<1 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::serialize" ,1,2,lua_gettop(L)); goto fail;} | |||
4726 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::serialize",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::serialize",1,"Event *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4727 | if(lua_gettop(L)>=2 && !SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("Event::serialize",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::serialize",2,"char const *",SWIG_Lua_typename(L,2)) ; goto fail;}; | |||
4728 | ||||
4729 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4730 | SWIG_fail_ptr("Event_serialize",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_serialize",1,(swig_types[3] && swig_types[3] ->str)?swig_types[3]->str:"void*",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
4731 | } | |||
4732 | ||||
4733 | if(lua_gettop(L)>=2){ | |||
4734 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
4735 | } | |||
4736 | result = (char *)(arg1)->serialize((char const *)arg2); | |||
4737 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
4738 | return SWIG_arg; | |||
4739 | ||||
4740 | if(0) SWIG_fail{goto fail;}; | |||
4741 | ||||
4742 | fail: | |||
4743 | lua_error(L); | |||
4744 | return SWIG_arg; | |||
4745 | } | |||
4746 | ||||
4747 | ||||
4748 | static int _wrap_Event_setPriority(lua_State* L) { | |||
4749 | int SWIG_arg = 0; | |||
4750 | Event *arg1 = (Event *) 0 ; | |||
4751 | switch_priority_t arg2 = (switch_priority_t) SWITCH_PRIORITY_NORMAL ; | |||
4752 | switch_priority_t *argp2 ; | |||
4753 | bool result; | |||
4754 | ||||
4755 | SWIG_check_num_args("Event::setPriority",1,2)if (lua_gettop(L)<1 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::setPriority" ,1,2,lua_gettop(L)); goto fail;} | |||
4756 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::setPriority",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::setPriority",1,"Event *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4757 | if(lua_gettop(L)>=2 && !lua_isuserdata(L,2)) SWIG_fail_arg("Event::setPriority",2,"switch_priority_t"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::setPriority",2,"switch_priority_t",SWIG_Lua_typename (L,2)); goto fail;}; | |||
4758 | ||||
4759 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4760 | SWIG_fail_ptr("Event_setPriority",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_setPriority",1,(swig_types[3] && swig_types[ 3]->str)?swig_types[3]->str:"void*",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
4761 | } | |||
4762 | ||||
4763 | if(lua_gettop(L)>=2){ | |||
4764 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&argp2,SWIGTYPE_p_switch_priority_t,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&argp2,swig_types[25],0) >= 0)){ | |||
4765 | SWIG_fail_ptr("Event_setPriority",2,SWIGTYPE_p_switch_priority_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_setPriority",2,(swig_types[25] && swig_types [25]->str)?swig_types[25]->str:"void*",SWIG_Lua_typename (L,2)); goto fail;}; | |||
4766 | } | |||
4767 | arg2 = *argp2; | |||
4768 | } | |||
4769 | result = (bool)(arg1)->setPriority(arg2); | |||
4770 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
4771 | return SWIG_arg; | |||
4772 | ||||
4773 | if(0) SWIG_fail{goto fail;}; | |||
4774 | ||||
4775 | fail: | |||
4776 | lua_error(L); | |||
4777 | return SWIG_arg; | |||
4778 | } | |||
4779 | ||||
4780 | ||||
4781 | static int _wrap_Event_getHeader(lua_State* L) { | |||
4782 | int SWIG_arg = 0; | |||
4783 | Event *arg1 = (Event *) 0 ; | |||
4784 | char *arg2 = (char *) 0 ; | |||
4785 | char *result = 0 ; | |||
4786 | ||||
4787 | SWIG_check_num_args("Event::getHeader",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::getHeader" ,2,2,lua_gettop(L)); goto fail;} | |||
4788 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::getHeader",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::getHeader",1,"Event *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4789 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("Event::getHeader",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::getHeader",2,"char const *",SWIG_Lua_typename(L,2)) ; goto fail;}; | |||
4790 | ||||
4791 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4792 | SWIG_fail_ptr("Event_getHeader",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_getHeader",1,(swig_types[3] && swig_types[3] ->str)?swig_types[3]->str:"void*",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
4793 | } | |||
4794 | ||||
4795 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
4796 | result = (char *)(arg1)->getHeader((char const *)arg2); | |||
4797 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
4798 | return SWIG_arg; | |||
4799 | ||||
4800 | if(0) SWIG_fail{goto fail;}; | |||
4801 | ||||
4802 | fail: | |||
4803 | lua_error(L); | |||
4804 | return SWIG_arg; | |||
4805 | } | |||
4806 | ||||
4807 | ||||
4808 | static int _wrap_Event_getBody(lua_State* L) { | |||
4809 | int SWIG_arg = 0; | |||
4810 | Event *arg1 = (Event *) 0 ; | |||
4811 | char *result = 0 ; | |||
4812 | ||||
4813 | SWIG_check_num_args("Event::getBody",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::getBody" ,1,1,lua_gettop(L)); goto fail;} | |||
4814 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::getBody",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::getBody",1,"Event *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
4815 | ||||
4816 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4817 | SWIG_fail_ptr("Event_getBody",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_getBody",1,(swig_types[3] && swig_types[3]-> str)?swig_types[3]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4818 | } | |||
4819 | ||||
4820 | result = (char *)(arg1)->getBody(); | |||
4821 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
4822 | return SWIG_arg; | |||
4823 | ||||
4824 | if(0) SWIG_fail{goto fail;}; | |||
4825 | ||||
4826 | fail: | |||
4827 | lua_error(L); | |||
4828 | return SWIG_arg; | |||
4829 | } | |||
4830 | ||||
4831 | ||||
4832 | static int _wrap_Event_getType(lua_State* L) { | |||
4833 | int SWIG_arg = 0; | |||
4834 | Event *arg1 = (Event *) 0 ; | |||
4835 | char *result = 0 ; | |||
4836 | ||||
4837 | SWIG_check_num_args("Event::getType",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::getType" ,1,1,lua_gettop(L)); goto fail;} | |||
4838 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::getType",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::getType",1,"Event *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
4839 | ||||
4840 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4841 | SWIG_fail_ptr("Event_getType",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_getType",1,(swig_types[3] && swig_types[3]-> str)?swig_types[3]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4842 | } | |||
4843 | ||||
4844 | result = (char *)(arg1)->getType(); | |||
4845 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
4846 | return SWIG_arg; | |||
4847 | ||||
4848 | if(0) SWIG_fail{goto fail;}; | |||
4849 | ||||
4850 | fail: | |||
4851 | lua_error(L); | |||
4852 | return SWIG_arg; | |||
4853 | } | |||
4854 | ||||
4855 | ||||
4856 | static int _wrap_Event_addBody(lua_State* L) { | |||
4857 | int SWIG_arg = 0; | |||
4858 | Event *arg1 = (Event *) 0 ; | |||
4859 | char *arg2 = (char *) 0 ; | |||
4860 | bool result; | |||
4861 | ||||
4862 | SWIG_check_num_args("Event::addBody",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::addBody" ,2,2,lua_gettop(L)); goto fail;} | |||
4863 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::addBody",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::addBody",1,"Event *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
4864 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("Event::addBody",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::addBody",2,"char const *",SWIG_Lua_typename(L,2)); goto fail;}; | |||
4865 | ||||
4866 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4867 | SWIG_fail_ptr("Event_addBody",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_addBody",1,(swig_types[3] && swig_types[3]-> str)?swig_types[3]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4868 | } | |||
4869 | ||||
4870 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
4871 | result = (bool)(arg1)->addBody((char const *)arg2); | |||
4872 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
4873 | return SWIG_arg; | |||
4874 | ||||
4875 | if(0) SWIG_fail{goto fail;}; | |||
4876 | ||||
4877 | fail: | |||
4878 | lua_error(L); | |||
4879 | return SWIG_arg; | |||
4880 | } | |||
4881 | ||||
4882 | ||||
4883 | static int _wrap_Event_addHeader(lua_State* L) { | |||
4884 | int SWIG_arg = 0; | |||
4885 | Event *arg1 = (Event *) 0 ; | |||
4886 | char *arg2 = (char *) 0 ; | |||
4887 | char *arg3 = (char *) 0 ; | |||
4888 | bool result; | |||
4889 | ||||
4890 | SWIG_check_num_args("Event::addHeader",3,3)if (lua_gettop(L)<3 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::addHeader" ,3,3,lua_gettop(L)); goto fail;} | |||
4891 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::addHeader",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::addHeader",1,"Event *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4892 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("Event::addHeader",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::addHeader",2,"char const *",SWIG_Lua_typename(L,2)) ; goto fail;}; | |||
4893 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("Event::addHeader",3,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::addHeader",3,"char const *",SWIG_Lua_typename(L,3)) ; goto fail;}; | |||
4894 | ||||
4895 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4896 | SWIG_fail_ptr("Event_addHeader",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_addHeader",1,(swig_types[3] && swig_types[3] ->str)?swig_types[3]->str:"void*",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
4897 | } | |||
4898 | ||||
4899 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
4900 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
4901 | result = (bool)(arg1)->addHeader((char const *)arg2,(char const *)arg3); | |||
4902 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
4903 | return SWIG_arg; | |||
4904 | ||||
4905 | if(0) SWIG_fail{goto fail;}; | |||
4906 | ||||
4907 | fail: | |||
4908 | lua_error(L); | |||
4909 | return SWIG_arg; | |||
4910 | } | |||
4911 | ||||
4912 | ||||
4913 | static int _wrap_Event_delHeader(lua_State* L) { | |||
4914 | int SWIG_arg = 0; | |||
4915 | Event *arg1 = (Event *) 0 ; | |||
4916 | char *arg2 = (char *) 0 ; | |||
4917 | bool result; | |||
4918 | ||||
4919 | SWIG_check_num_args("Event::delHeader",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::delHeader" ,2,2,lua_gettop(L)); goto fail;} | |||
4920 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::delHeader",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::delHeader",1,"Event *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4921 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("Event::delHeader",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::delHeader",2,"char const *",SWIG_Lua_typename(L,2)) ; goto fail;}; | |||
4922 | ||||
4923 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4924 | SWIG_fail_ptr("Event_delHeader",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_delHeader",1,(swig_types[3] && swig_types[3] ->str)?swig_types[3]->str:"void*",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
4925 | } | |||
4926 | ||||
4927 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
4928 | result = (bool)(arg1)->delHeader((char const *)arg2); | |||
4929 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
4930 | return SWIG_arg; | |||
4931 | ||||
4932 | if(0) SWIG_fail{goto fail;}; | |||
4933 | ||||
4934 | fail: | |||
4935 | lua_error(L); | |||
4936 | return SWIG_arg; | |||
4937 | } | |||
4938 | ||||
4939 | ||||
4940 | static int _wrap_Event_fire(lua_State* L) { | |||
4941 | int SWIG_arg = 0; | |||
4942 | Event *arg1 = (Event *) 0 ; | |||
4943 | bool result; | |||
4944 | ||||
4945 | SWIG_check_num_args("Event::fire",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::fire",1 ,1,lua_gettop(L)); goto fail;} | |||
4946 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::fire",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::fire",1,"Event *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
4947 | ||||
4948 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4949 | SWIG_fail_ptr("Event_fire",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_fire",1,(swig_types[3] && swig_types[3]-> str)?swig_types[3]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4950 | } | |||
4951 | ||||
4952 | result = (bool)(arg1)->fire(); | |||
4953 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
4954 | return SWIG_arg; | |||
4955 | ||||
4956 | if(0) SWIG_fail{goto fail;}; | |||
4957 | ||||
4958 | fail: | |||
4959 | lua_error(L); | |||
4960 | return SWIG_arg; | |||
4961 | } | |||
4962 | ||||
4963 | ||||
4964 | static int _wrap_Event_merge(lua_State* L) { | |||
4965 | int SWIG_arg = 0; | |||
4966 | Event *arg1 = (Event *) 0 ; | |||
4967 | Event *arg2 = (Event *) 0 ; | |||
4968 | bool result; | |||
4969 | ||||
4970 | SWIG_check_num_args("Event::merge",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","Event::merge", 2,2,lua_gettop(L)); goto fail;} | |||
4971 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("Event::merge",1,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::merge",1,"Event *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
4972 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("Event::merge",2,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event::merge",2,"Event *",SWIG_Lua_typename(L,2)); goto fail ;}; | |||
4973 | ||||
4974 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[3],0) >= 0)){ | |||
4975 | SWIG_fail_ptr("Event_merge",1,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_merge",1,(swig_types[3] && swig_types[3]-> str)?swig_types[3]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
4976 | } | |||
4977 | ||||
4978 | ||||
4979 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&arg2,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&arg2,swig_types[3],0) >= 0)){ | |||
4980 | SWIG_fail_ptr("Event_merge",2,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Event_merge",2,(swig_types[3] && swig_types[3]-> str)?swig_types[3]->str:"void*",SWIG_Lua_typename(L,2)); goto fail;}; | |||
4981 | } | |||
4982 | ||||
4983 | result = (bool)(arg1)->merge(arg2); | |||
4984 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
4985 | return SWIG_arg; | |||
4986 | ||||
4987 | if(0) SWIG_fail{goto fail;}; | |||
4988 | ||||
4989 | fail: | |||
4990 | lua_error(L); | |||
4991 | return SWIG_arg; | |||
4992 | } | |||
4993 | ||||
4994 | ||||
4995 | static void swig_delete_Event(void *obj) { | |||
4996 | Event *arg1 = (Event *) obj; | |||
4997 | delete arg1; | |||
4998 | } | |||
4999 | static int _proxy__wrap_new_Event(lua_State *L) { | |||
5000 | assert(lua_istable(L,1))(static_cast <bool> ((lua_type(L, (1)) == 5)) ? void (0 ) : __assert_fail ("lua_istable(L,1)", "mod_lua_wrap.cpp", 5000 , __extension__ __PRETTY_FUNCTION__)); | |||
5001 | lua_pushcfunction(L,_wrap_new_Event)lua_pushcclosure(L, (_wrap_new_Event), 0); | |||
5002 | assert(!lua_isnil(L,-1))(static_cast <bool> (!(lua_type(L, (-1)) == 0)) ? void ( 0) : __assert_fail ("!lua_isnil(L,-1)", "mod_lua_wrap.cpp", 5002 , __extension__ __PRETTY_FUNCTION__)); | |||
5003 | lua_replace(L,1); /* replace our table with real constructor */ | |||
5004 | lua_call(L,lua_gettop(L)-1,1)lua_callk(L, (lua_gettop(L)-1), (1), 0, __null); | |||
5005 | return 1; | |||
5006 | } | |||
5007 | static swig_lua_attribute swig_Event_attributes[] = { | |||
5008 | { "event", _wrap_Event_event_get, _wrap_Event_event_set }, | |||
5009 | { "serialized_string", _wrap_Event_serialized_string_get, _wrap_Event_serialized_string_set }, | |||
5010 | { "mine", _wrap_Event_mine_get, _wrap_Event_mine_set }, | |||
5011 | {0,0,0} | |||
5012 | }; | |||
5013 | static swig_lua_method swig_Event_methods[]= { | |||
5014 | { "chat_execute", _wrap_Event_chat_execute}, | |||
5015 | { "chat_send", _wrap_Event_chat_send}, | |||
5016 | { "serialize", _wrap_Event_serialize}, | |||
5017 | { "setPriority", _wrap_Event_setPriority}, | |||
5018 | { "getHeader", _wrap_Event_getHeader}, | |||
5019 | { "getBody", _wrap_Event_getBody}, | |||
5020 | { "getType", _wrap_Event_getType}, | |||
5021 | { "addBody", _wrap_Event_addBody}, | |||
5022 | { "addHeader", _wrap_Event_addHeader}, | |||
5023 | { "delHeader", _wrap_Event_delHeader}, | |||
5024 | { "fire", _wrap_Event_fire}, | |||
5025 | { "merge", _wrap_Event_merge}, | |||
5026 | {0,0} | |||
5027 | }; | |||
5028 | static swig_lua_method swig_Event_meta[] = { | |||
5029 | {0,0} | |||
5030 | }; | |||
5031 | ||||
5032 | static swig_lua_attribute swig_Event_Sf_SwigStatic_attributes[] = { | |||
5033 | {0,0,0} | |||
5034 | }; | |||
5035 | static swig_lua_const_info swig_Event_Sf_SwigStatic_constants[]= { | |||
5036 | {0,0,0,0,0,0} | |||
5037 | }; | |||
5038 | static swig_lua_method swig_Event_Sf_SwigStatic_methods[]= { | |||
5039 | {0,0} | |||
5040 | }; | |||
5041 | static swig_lua_class* swig_Event_Sf_SwigStatic_classes[]= { | |||
5042 | 0 | |||
5043 | }; | |||
5044 | ||||
5045 | static swig_lua_namespace swig_Event_Sf_SwigStatic = { | |||
5046 | "Event", | |||
5047 | swig_Event_Sf_SwigStatic_methods, | |||
5048 | swig_Event_Sf_SwigStatic_attributes, | |||
5049 | swig_Event_Sf_SwigStatic_constants, | |||
5050 | swig_Event_Sf_SwigStatic_classes, | |||
5051 | 0 | |||
5052 | }; | |||
5053 | static swig_lua_class *swig_Event_bases[] = {0}; | |||
5054 | static const char *swig_Event_base_names[] = {0}; | |||
5055 | static swig_lua_class _wrap_class_Event = { "Event", "Event", &SWIGTYPE_p_Eventswig_types[3],_proxy__wrap_new_Event, swig_delete_Event, swig_Event_methods, swig_Event_attributes, &swig_Event_Sf_SwigStatic, swig_Event_meta, swig_Event_bases, swig_Event_base_names }; | |||
5056 | ||||
5057 | static int _wrap_EventConsumer_events_set(lua_State* L) { | |||
5058 | int SWIG_arg = 0; | |||
5059 | EventConsumer *arg1 = (EventConsumer *) 0 ; | |||
5060 | switch_queue_t *arg2 = (switch_queue_t *) 0 ; | |||
5061 | ||||
5062 | SWIG_check_num_args("EventConsumer::events",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::events" ,2,2,lua_gettop(L)); goto fail;} | |||
5063 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("EventConsumer::events",1,"EventConsumer *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::events",1,"EventConsumer *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5064 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("EventConsumer::events",2,"switch_queue_t *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::events",2,"switch_queue_t *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5065 | ||||
5066 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_EventConsumer,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[4],0) >= 0)){ | |||
5067 | SWIG_fail_ptr("EventConsumer_events_set",1,SWIGTYPE_p_EventConsumer){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_events_set",1,(swig_types[4] && swig_types [4]->str)?swig_types[4]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5068 | } | |||
5069 | ||||
5070 | ||||
5071 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&arg2,SWIGTYPE_p_switch_queue_t,SWIG_POINTER_DISOWN))(SWIG_Lua_ConvertPtr(L,2,(void**)&arg2,swig_types[26],0x1 ) >= 0)){ | |||
5072 | SWIG_fail_ptr("EventConsumer_events_set",2,SWIGTYPE_p_switch_queue_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_events_set",2,(swig_types[26] && swig_types [26]->str)?swig_types[26]->str:"void*",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5073 | } | |||
5074 | ||||
5075 | if (arg1) (arg1)->events = arg2; | |||
5076 | ||||
5077 | return SWIG_arg; | |||
5078 | ||||
5079 | if(0) SWIG_fail{goto fail;}; | |||
5080 | ||||
5081 | fail: | |||
5082 | lua_error(L); | |||
5083 | return SWIG_arg; | |||
5084 | } | |||
5085 | ||||
5086 | ||||
5087 | static int _wrap_EventConsumer_events_get(lua_State* L) { | |||
5088 | int SWIG_arg = 0; | |||
5089 | EventConsumer *arg1 = (EventConsumer *) 0 ; | |||
5090 | switch_queue_t *result = 0 ; | |||
5091 | ||||
5092 | SWIG_check_num_args("EventConsumer::events",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::events" ,1,1,lua_gettop(L)); goto fail;} | |||
5093 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("EventConsumer::events",1,"EventConsumer *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::events",1,"EventConsumer *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5094 | ||||
5095 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_EventConsumer,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[4],0) >= 0)){ | |||
5096 | SWIG_fail_ptr("EventConsumer_events_get",1,SWIGTYPE_p_EventConsumer){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_events_get",1,(swig_types[4] && swig_types [4]->str)?swig_types[4]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5097 | } | |||
5098 | ||||
5099 | result = (switch_queue_t *) ((arg1)->events); | |||
5100 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_switch_queue_t,0)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[26], 0); SWIG_arg++; | |||
5101 | return SWIG_arg; | |||
5102 | ||||
5103 | if(0) SWIG_fail{goto fail;}; | |||
5104 | ||||
5105 | fail: | |||
5106 | lua_error(L); | |||
5107 | return SWIG_arg; | |||
5108 | } | |||
5109 | ||||
5110 | ||||
5111 | static int _wrap_EventConsumer_e_event_id_set(lua_State* L) { | |||
5112 | int SWIG_arg = 0; | |||
5113 | EventConsumer *arg1 = (EventConsumer *) 0 ; | |||
5114 | switch_event_types_t arg2 ; | |||
5115 | switch_event_types_t *argp2 ; | |||
5116 | ||||
5117 | SWIG_check_num_args("EventConsumer::e_event_id",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::e_event_id" ,2,2,lua_gettop(L)); goto fail;} | |||
5118 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("EventConsumer::e_event_id",1,"EventConsumer *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::e_event_id",1,"EventConsumer *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5119 | if(!lua_isuserdata(L,2)) SWIG_fail_arg("EventConsumer::e_event_id",2,"switch_event_types_t"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::e_event_id",2,"switch_event_types_t",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5120 | ||||
5121 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_EventConsumer,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[4],0) >= 0)){ | |||
5122 | SWIG_fail_ptr("EventConsumer_e_event_id_set",1,SWIGTYPE_p_EventConsumer){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_e_event_id_set",1,(swig_types[4] && swig_types [4]->str)?swig_types[4]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5123 | } | |||
5124 | ||||
5125 | ||||
5126 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&argp2,SWIGTYPE_p_switch_event_types_t,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&argp2,swig_types[22],0) >= 0)){ | |||
5127 | SWIG_fail_ptr("EventConsumer_e_event_id_set",2,SWIGTYPE_p_switch_event_types_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_e_event_id_set",2,(swig_types[22] && swig_types[22]->str)?swig_types[22]->str:"void*",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5128 | } | |||
5129 | arg2 = *argp2; | |||
5130 | ||||
5131 | if (arg1) (arg1)->e_event_id = arg2; | |||
5132 | ||||
5133 | return SWIG_arg; | |||
5134 | ||||
5135 | if(0) SWIG_fail{goto fail;}; | |||
5136 | ||||
5137 | fail: | |||
5138 | lua_error(L); | |||
5139 | return SWIG_arg; | |||
5140 | } | |||
5141 | ||||
5142 | ||||
5143 | static int _wrap_EventConsumer_e_event_id_get(lua_State* L) { | |||
5144 | int SWIG_arg = 0; | |||
5145 | EventConsumer *arg1 = (EventConsumer *) 0 ; | |||
5146 | switch_event_types_t result; | |||
5147 | ||||
5148 | SWIG_check_num_args("EventConsumer::e_event_id",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::e_event_id" ,1,1,lua_gettop(L)); goto fail;} | |||
5149 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("EventConsumer::e_event_id",1,"EventConsumer *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::e_event_id",1,"EventConsumer *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5150 | ||||
5151 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_EventConsumer,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[4],0) >= 0)){ | |||
5152 | SWIG_fail_ptr("EventConsumer_e_event_id_get",1,SWIGTYPE_p_EventConsumer){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_e_event_id_get",1,(swig_types[4] && swig_types [4]->str)?swig_types[4]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5153 | } | |||
5154 | ||||
5155 | result = ((arg1)->e_event_id); | |||
5156 | { | |||
5157 | switch_event_types_t * resultptr = new switch_event_types_t((const switch_event_types_t &) result); | |||
5158 | SWIG_NewPointerObj(L,(void *) resultptr,SWIGTYPE_p_switch_event_types_t,1)SWIG_Lua_NewPointerObj(L, (void *)(void *) resultptr, swig_types [22], 1); SWIG_arg++; | |||
5159 | } | |||
5160 | return SWIG_arg; | |||
5161 | ||||
5162 | if(0) SWIG_fail{goto fail;}; | |||
5163 | ||||
5164 | fail: | |||
5165 | lua_error(L); | |||
5166 | return SWIG_arg; | |||
5167 | } | |||
5168 | ||||
5169 | ||||
5170 | static int _wrap_EventConsumer_e_callback_set(lua_State* L) { | |||
5171 | int SWIG_arg = 0; | |||
5172 | EventConsumer *arg1 = (EventConsumer *) 0 ; | |||
5173 | char *arg2 = (char *) 0 ; | |||
5174 | ||||
5175 | SWIG_check_num_args("EventConsumer::e_callback",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::e_callback" ,2,2,lua_gettop(L)); goto fail;} | |||
5176 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("EventConsumer::e_callback",1,"EventConsumer *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::e_callback",1,"EventConsumer *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5177 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("EventConsumer::e_callback",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::e_callback",2,"char *",SWIG_Lua_typename(L, 2)); goto fail;}; | |||
5178 | ||||
5179 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_EventConsumer,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[4],0) >= 0)){ | |||
5180 | SWIG_fail_ptr("EventConsumer_e_callback_set",1,SWIGTYPE_p_EventConsumer){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_e_callback_set",1,(swig_types[4] && swig_types [4]->str)?swig_types[4]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5181 | } | |||
5182 | ||||
5183 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
5184 | { | |||
5185 | delete [] arg1->e_callback; | |||
5186 | if (arg2) { | |||
5187 | arg1->e_callback = (char *) (new char[strlen((const char *)arg2)+1]); | |||
5188 | strcpy((char *)arg1->e_callback, (const char *)arg2); | |||
5189 | } else { | |||
5190 | arg1->e_callback = 0; | |||
5191 | } | |||
5192 | } | |||
5193 | ||||
5194 | return SWIG_arg; | |||
5195 | ||||
5196 | if(0) SWIG_fail{goto fail;}; | |||
5197 | ||||
5198 | fail: | |||
5199 | lua_error(L); | |||
5200 | return SWIG_arg; | |||
5201 | } | |||
5202 | ||||
5203 | ||||
5204 | static int _wrap_EventConsumer_e_callback_get(lua_State* L) { | |||
5205 | int SWIG_arg = 0; | |||
5206 | EventConsumer *arg1 = (EventConsumer *) 0 ; | |||
5207 | char *result = 0 ; | |||
5208 | ||||
5209 | SWIG_check_num_args("EventConsumer::e_callback",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::e_callback" ,1,1,lua_gettop(L)); goto fail;} | |||
5210 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("EventConsumer::e_callback",1,"EventConsumer *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::e_callback",1,"EventConsumer *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5211 | ||||
5212 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_EventConsumer,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[4],0) >= 0)){ | |||
5213 | SWIG_fail_ptr("EventConsumer_e_callback_get",1,SWIGTYPE_p_EventConsumer){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_e_callback_get",1,(swig_types[4] && swig_types [4]->str)?swig_types[4]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5214 | } | |||
5215 | ||||
5216 | result = (char *) ((arg1)->e_callback); | |||
5217 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
5218 | return SWIG_arg; | |||
5219 | ||||
5220 | if(0) SWIG_fail{goto fail;}; | |||
5221 | ||||
5222 | fail: | |||
5223 | lua_error(L); | |||
5224 | return SWIG_arg; | |||
5225 | } | |||
5226 | ||||
5227 | ||||
5228 | static int _wrap_EventConsumer_e_subclass_name_set(lua_State* L) { | |||
5229 | int SWIG_arg = 0; | |||
5230 | EventConsumer *arg1 = (EventConsumer *) 0 ; | |||
5231 | char *arg2 = (char *) 0 ; | |||
5232 | ||||
5233 | SWIG_check_num_args("EventConsumer::e_subclass_name",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::e_subclass_name" ,2,2,lua_gettop(L)); goto fail;} | |||
5234 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("EventConsumer::e_subclass_name",1,"EventConsumer *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::e_subclass_name",1,"EventConsumer *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5235 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("EventConsumer::e_subclass_name",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::e_subclass_name",2,"char *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5236 | ||||
5237 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_EventConsumer,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[4],0) >= 0)){ | |||
5238 | SWIG_fail_ptr("EventConsumer_e_subclass_name_set",1,SWIGTYPE_p_EventConsumer){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_e_subclass_name_set",1,(swig_types[4] && swig_types[4]->str)?swig_types[4]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5239 | } | |||
5240 | ||||
5241 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
5242 | { | |||
5243 | delete [] arg1->e_subclass_name; | |||
5244 | if (arg2) { | |||
5245 | arg1->e_subclass_name = (char *) (new char[strlen((const char *)arg2)+1]); | |||
5246 | strcpy((char *)arg1->e_subclass_name, (const char *)arg2); | |||
5247 | } else { | |||
5248 | arg1->e_subclass_name = 0; | |||
5249 | } | |||
5250 | } | |||
5251 | ||||
5252 | return SWIG_arg; | |||
5253 | ||||
5254 | if(0) SWIG_fail{goto fail;}; | |||
5255 | ||||
5256 | fail: | |||
5257 | lua_error(L); | |||
5258 | return SWIG_arg; | |||
5259 | } | |||
5260 | ||||
5261 | ||||
5262 | static int _wrap_EventConsumer_e_subclass_name_get(lua_State* L) { | |||
5263 | int SWIG_arg = 0; | |||
5264 | EventConsumer *arg1 = (EventConsumer *) 0 ; | |||
5265 | char *result = 0 ; | |||
5266 | ||||
5267 | SWIG_check_num_args("EventConsumer::e_subclass_name",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::e_subclass_name" ,1,1,lua_gettop(L)); goto fail;} | |||
5268 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("EventConsumer::e_subclass_name",1,"EventConsumer *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::e_subclass_name",1,"EventConsumer *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5269 | ||||
5270 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_EventConsumer,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[4],0) >= 0)){ | |||
5271 | SWIG_fail_ptr("EventConsumer_e_subclass_name_get",1,SWIGTYPE_p_EventConsumer){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_e_subclass_name_get",1,(swig_types[4] && swig_types[4]->str)?swig_types[4]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5272 | } | |||
5273 | ||||
5274 | result = (char *) ((arg1)->e_subclass_name); | |||
5275 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
5276 | return SWIG_arg; | |||
5277 | ||||
5278 | if(0) SWIG_fail{goto fail;}; | |||
5279 | ||||
5280 | fail: | |||
5281 | lua_error(L); | |||
5282 | return SWIG_arg; | |||
5283 | } | |||
5284 | ||||
5285 | ||||
5286 | static int _wrap_EventConsumer_e_cb_arg_set(lua_State* L) { | |||
5287 | int SWIG_arg = 0; | |||
5288 | EventConsumer *arg1 = (EventConsumer *) 0 ; | |||
5289 | char *arg2 = (char *) 0 ; | |||
5290 | ||||
5291 | SWIG_check_num_args("EventConsumer::e_cb_arg",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::e_cb_arg" ,2,2,lua_gettop(L)); goto fail;} | |||
5292 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("EventConsumer::e_cb_arg",1,"EventConsumer *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::e_cb_arg",1,"EventConsumer *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5293 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("EventConsumer::e_cb_arg",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::e_cb_arg",2,"char *",SWIG_Lua_typename(L,2) ); goto fail;}; | |||
5294 | ||||
5295 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_EventConsumer,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[4],0) >= 0)){ | |||
5296 | SWIG_fail_ptr("EventConsumer_e_cb_arg_set",1,SWIGTYPE_p_EventConsumer){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_e_cb_arg_set",1,(swig_types[4] && swig_types [4]->str)?swig_types[4]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5297 | } | |||
5298 | ||||
5299 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
5300 | { | |||
5301 | delete [] arg1->e_cb_arg; | |||
5302 | if (arg2) { | |||
5303 | arg1->e_cb_arg = (char *) (new char[strlen((const char *)arg2)+1]); | |||
5304 | strcpy((char *)arg1->e_cb_arg, (const char *)arg2); | |||
5305 | } else { | |||
5306 | arg1->e_cb_arg = 0; | |||
5307 | } | |||
5308 | } | |||
5309 | ||||
5310 | return SWIG_arg; | |||
5311 | ||||
5312 | if(0) SWIG_fail{goto fail;}; | |||
5313 | ||||
5314 | fail: | |||
5315 | lua_error(L); | |||
5316 | return SWIG_arg; | |||
5317 | } | |||
5318 | ||||
5319 | ||||
5320 | static int _wrap_EventConsumer_e_cb_arg_get(lua_State* L) { | |||
5321 | int SWIG_arg = 0; | |||
5322 | EventConsumer *arg1 = (EventConsumer *) 0 ; | |||
5323 | char *result = 0 ; | |||
5324 | ||||
5325 | SWIG_check_num_args("EventConsumer::e_cb_arg",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::e_cb_arg" ,1,1,lua_gettop(L)); goto fail;} | |||
5326 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("EventConsumer::e_cb_arg",1,"EventConsumer *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::e_cb_arg",1,"EventConsumer *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5327 | ||||
5328 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_EventConsumer,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[4],0) >= 0)){ | |||
5329 | SWIG_fail_ptr("EventConsumer_e_cb_arg_get",1,SWIGTYPE_p_EventConsumer){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_e_cb_arg_get",1,(swig_types[4] && swig_types [4]->str)?swig_types[4]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5330 | } | |||
5331 | ||||
5332 | result = (char *) ((arg1)->e_cb_arg); | |||
5333 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
5334 | return SWIG_arg; | |||
5335 | ||||
5336 | if(0) SWIG_fail{goto fail;}; | |||
5337 | ||||
5338 | fail: | |||
5339 | lua_error(L); | |||
5340 | return SWIG_arg; | |||
5341 | } | |||
5342 | ||||
5343 | ||||
5344 | static int _wrap_EventConsumer_enodes_set(lua_State* L) { | |||
5345 | int SWIG_arg = 0; | |||
5346 | EventConsumer *arg1 = (EventConsumer *) 0 ; | |||
5347 | switch_event_node_t **arg2 ; | |||
5348 | ||||
5349 | SWIG_check_num_args("EventConsumer::enodes",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::enodes" ,2,2,lua_gettop(L)); goto fail;} | |||
5350 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("EventConsumer::enodes",1,"EventConsumer *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::enodes",1,"EventConsumer *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5351 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("EventConsumer::enodes",2,"switch_event_node_t *[SWITCH_EVENT_ALL+1]"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::enodes",2,"switch_event_node_t *[SWITCH_EVENT_ALL+1]" ,SWIG_Lua_typename(L,2)); goto fail;}; | |||
5352 | ||||
5353 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_EventConsumer,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[4],0) >= 0)){ | |||
5354 | SWIG_fail_ptr("EventConsumer_enodes_set",1,SWIGTYPE_p_EventConsumer){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_enodes_set",1,(swig_types[4] && swig_types [4]->str)?swig_types[4]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5355 | } | |||
5356 | ||||
5357 | ||||
5358 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&arg2,SWIGTYPE_p_p_switch_event_node_t,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&arg2,swig_types[14],0) >= 0)){ | |||
5359 | SWIG_fail_ptr("EventConsumer_enodes_set",2,SWIGTYPE_p_p_switch_event_node_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_enodes_set",2,(swig_types[14] && swig_types [14]->str)?swig_types[14]->str:"void*",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5360 | } | |||
5361 | ||||
5362 | { | |||
5363 | size_t ii; | |||
5364 | switch_event_node_t * *b = (switch_event_node_t * *) arg1->enodes; | |||
5365 | for (ii = 0; ii < (size_t)SWITCH_EVENT_ALL+1; ii++) b[ii] = *((switch_event_node_t * *) arg2 + ii); | |||
5366 | } | |||
5367 | ||||
5368 | return SWIG_arg; | |||
5369 | ||||
5370 | if(0) SWIG_fail{goto fail;}; | |||
5371 | ||||
5372 | fail: | |||
5373 | lua_error(L); | |||
5374 | return SWIG_arg; | |||
5375 | } | |||
5376 | ||||
5377 | ||||
5378 | static int _wrap_EventConsumer_enodes_get(lua_State* L) { | |||
5379 | int SWIG_arg = 0; | |||
5380 | EventConsumer *arg1 = (EventConsumer *) 0 ; | |||
5381 | switch_event_node_t **result = 0 ; | |||
5382 | ||||
5383 | SWIG_check_num_args("EventConsumer::enodes",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::enodes" ,1,1,lua_gettop(L)); goto fail;} | |||
5384 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("EventConsumer::enodes",1,"EventConsumer *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::enodes",1,"EventConsumer *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5385 | ||||
5386 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_EventConsumer,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[4],0) >= 0)){ | |||
5387 | SWIG_fail_ptr("EventConsumer_enodes_get",1,SWIGTYPE_p_EventConsumer){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_enodes_get",1,(swig_types[4] && swig_types [4]->str)?swig_types[4]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5388 | } | |||
5389 | ||||
5390 | result = (switch_event_node_t **)(switch_event_node_t **) ((arg1)->enodes); | |||
5391 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_p_switch_event_node_t,0)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[14], 0); SWIG_arg++; | |||
5392 | return SWIG_arg; | |||
5393 | ||||
5394 | if(0) SWIG_fail{goto fail;}; | |||
5395 | ||||
5396 | fail: | |||
5397 | lua_error(L); | |||
5398 | return SWIG_arg; | |||
5399 | } | |||
5400 | ||||
5401 | ||||
5402 | static int _wrap_EventConsumer_node_index_set(lua_State* L) { | |||
5403 | int SWIG_arg = 0; | |||
5404 | EventConsumer *arg1 = (EventConsumer *) 0 ; | |||
5405 | uint32_t arg2 ; | |||
5406 | uint32_t *argp2 ; | |||
5407 | ||||
5408 | SWIG_check_num_args("EventConsumer::node_index",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::node_index" ,2,2,lua_gettop(L)); goto fail;} | |||
5409 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("EventConsumer::node_index",1,"EventConsumer *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::node_index",1,"EventConsumer *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5410 | if(!lua_isuserdata(L,2)) SWIG_fail_arg("EventConsumer::node_index",2,"uint32_t"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::node_index",2,"uint32_t",SWIG_Lua_typename( L,2)); goto fail;}; | |||
5411 | ||||
5412 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_EventConsumer,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[4],0) >= 0)){ | |||
5413 | SWIG_fail_ptr("EventConsumer_node_index_set",1,SWIGTYPE_p_EventConsumer){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_node_index_set",1,(swig_types[4] && swig_types [4]->str)?swig_types[4]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5414 | } | |||
5415 | ||||
5416 | ||||
5417 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&argp2,SWIGTYPE_p_uint32_t,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&argp2,swig_types[30],0) >= 0)){ | |||
5418 | SWIG_fail_ptr("EventConsumer_node_index_set",2,SWIGTYPE_p_uint32_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_node_index_set",2,(swig_types[30] && swig_types[30]->str)?swig_types[30]->str:"void*",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5419 | } | |||
5420 | arg2 = *argp2; | |||
5421 | ||||
5422 | if (arg1) (arg1)->node_index = arg2; | |||
5423 | ||||
5424 | return SWIG_arg; | |||
5425 | ||||
5426 | if(0) SWIG_fail{goto fail;}; | |||
5427 | ||||
5428 | fail: | |||
5429 | lua_error(L); | |||
5430 | return SWIG_arg; | |||
5431 | } | |||
5432 | ||||
5433 | ||||
5434 | static int _wrap_EventConsumer_node_index_get(lua_State* L) { | |||
5435 | int SWIG_arg = 0; | |||
5436 | EventConsumer *arg1 = (EventConsumer *) 0 ; | |||
5437 | uint32_t result; | |||
5438 | ||||
5439 | SWIG_check_num_args("EventConsumer::node_index",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::node_index" ,1,1,lua_gettop(L)); goto fail;} | |||
5440 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("EventConsumer::node_index",1,"EventConsumer *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::node_index",1,"EventConsumer *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5441 | ||||
5442 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_EventConsumer,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[4],0) >= 0)){ | |||
5443 | SWIG_fail_ptr("EventConsumer_node_index_get",1,SWIGTYPE_p_EventConsumer){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_node_index_get",1,(swig_types[4] && swig_types [4]->str)?swig_types[4]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5444 | } | |||
5445 | ||||
5446 | result = ((arg1)->node_index); | |||
5447 | { | |||
5448 | uint32_t * resultptr = new uint32_t((const uint32_t &) result); | |||
5449 | SWIG_NewPointerObj(L,(void *) resultptr,SWIGTYPE_p_uint32_t,1)SWIG_Lua_NewPointerObj(L, (void *)(void *) resultptr, swig_types [30], 1); SWIG_arg++; | |||
5450 | } | |||
5451 | return SWIG_arg; | |||
5452 | ||||
5453 | if(0) SWIG_fail{goto fail;}; | |||
5454 | ||||
5455 | fail: | |||
5456 | lua_error(L); | |||
5457 | return SWIG_arg; | |||
5458 | } | |||
5459 | ||||
5460 | ||||
5461 | static int _wrap_new_EventConsumer(lua_State* L) { | |||
5462 | int SWIG_arg = 0; | |||
5463 | char *arg1 = (char *) NULL__null ; | |||
5464 | char *arg2 = (char *) "" ; | |||
5465 | int arg3 = (int) 5000 ; | |||
5466 | EventConsumer *result = 0 ; | |||
5467 | ||||
5468 | SWIG_check_num_args("EventConsumer::EventConsumer",0,3)if (lua_gettop(L)<0 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::EventConsumer" ,0,3,lua_gettop(L)); goto fail;} | |||
5469 | if(lua_gettop(L)>=1 && !SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("EventConsumer::EventConsumer",1,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::EventConsumer",1,"char const *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5470 | if(lua_gettop(L)>=2 && !SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("EventConsumer::EventConsumer",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::EventConsumer",2,"char const *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5471 | if(lua_gettop(L)>=3 && !lua_isnumber(L,3)) SWIG_fail_arg("EventConsumer::EventConsumer",3,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::EventConsumer",3,"int",SWIG_Lua_typename(L, 3)); goto fail;}; | |||
5472 | if(lua_gettop(L)>=1){ | |||
5473 | arg1 = (char *)lua_tostring(L, 1)lua_tolstring(L, (1), __null); | |||
5474 | } | |||
5475 | if(lua_gettop(L)>=2){ | |||
5476 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
5477 | } | |||
5478 | if(lua_gettop(L)>=3){ | |||
5479 | arg3 = (int)lua_tonumber(L, 3)lua_tonumberx(L,3,__null); | |||
5480 | } | |||
5481 | result = (EventConsumer *)new EventConsumer((char const *)arg1,(char const *)arg2,arg3); | |||
5482 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_EventConsumer,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[4], 1); SWIG_arg++; | |||
5483 | return SWIG_arg; | |||
5484 | ||||
5485 | if(0) SWIG_fail{goto fail;}; | |||
5486 | ||||
5487 | fail: | |||
5488 | lua_error(L); | |||
5489 | return SWIG_arg; | |||
5490 | } | |||
5491 | ||||
5492 | ||||
5493 | static int _wrap_EventConsumer_bind(lua_State* L) { | |||
5494 | int SWIG_arg = 0; | |||
5495 | EventConsumer *arg1 = (EventConsumer *) 0 ; | |||
5496 | char *arg2 = (char *) 0 ; | |||
5497 | char *arg3 = (char *) "" ; | |||
5498 | int result; | |||
5499 | ||||
5500 | SWIG_check_num_args("EventConsumer::bind",2,3)if (lua_gettop(L)<2 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::bind" ,2,3,lua_gettop(L)); goto fail;} | |||
5501 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("EventConsumer::bind",1,"EventConsumer *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::bind",1,"EventConsumer *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5502 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("EventConsumer::bind",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::bind",2,"char const *",SWIG_Lua_typename(L, 2)); goto fail;}; | |||
5503 | if(lua_gettop(L)>=3 && !SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("EventConsumer::bind",3,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::bind",3,"char const *",SWIG_Lua_typename(L, 3)); goto fail;}; | |||
5504 | ||||
5505 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_EventConsumer,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[4],0) >= 0)){ | |||
5506 | SWIG_fail_ptr("EventConsumer_bind",1,SWIGTYPE_p_EventConsumer){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_bind",1,(swig_types[4] && swig_types [4]->str)?swig_types[4]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5507 | } | |||
5508 | ||||
5509 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
5510 | if(lua_gettop(L)>=3){ | |||
5511 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
5512 | } | |||
5513 | result = (int)(arg1)->bind((char const *)arg2,(char const *)arg3); | |||
5514 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
5515 | return SWIG_arg; | |||
5516 | ||||
5517 | if(0) SWIG_fail{goto fail;}; | |||
5518 | ||||
5519 | fail: | |||
5520 | lua_error(L); | |||
5521 | return SWIG_arg; | |||
5522 | } | |||
5523 | ||||
5524 | ||||
5525 | static int _wrap_EventConsumer_pop(lua_State* L) { | |||
5526 | int SWIG_arg = 0; | |||
5527 | EventConsumer *arg1 = (EventConsumer *) 0 ; | |||
5528 | int arg2 = (int) 0 ; | |||
5529 | int arg3 = (int) 0 ; | |||
5530 | Event *result = 0 ; | |||
5531 | ||||
5532 | SWIG_check_num_args("EventConsumer::pop",1,3)if (lua_gettop(L)<1 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::pop" ,1,3,lua_gettop(L)); goto fail;} | |||
5533 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("EventConsumer::pop",1,"EventConsumer *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::pop",1,"EventConsumer *",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5534 | if(lua_gettop(L)>=2 && !lua_isnumber(L,2)) SWIG_fail_arg("EventConsumer::pop",2,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::pop",2,"int",SWIG_Lua_typename(L,2)); goto fail ;}; | |||
5535 | if(lua_gettop(L)>=3 && !lua_isnumber(L,3)) SWIG_fail_arg("EventConsumer::pop",3,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::pop",3,"int",SWIG_Lua_typename(L,3)); goto fail ;}; | |||
5536 | ||||
5537 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_EventConsumer,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[4],0) >= 0)){ | |||
5538 | SWIG_fail_ptr("EventConsumer_pop",1,SWIGTYPE_p_EventConsumer){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_pop",1,(swig_types[4] && swig_types[ 4]->str)?swig_types[4]->str:"void*",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
5539 | } | |||
5540 | ||||
5541 | if(lua_gettop(L)>=2){ | |||
5542 | arg2 = (int)lua_tonumber(L, 2)lua_tonumberx(L,2,__null); | |||
5543 | } | |||
5544 | if(lua_gettop(L)>=3){ | |||
5545 | arg3 = (int)lua_tonumber(L, 3)lua_tonumberx(L,3,__null); | |||
5546 | } | |||
5547 | result = (Event *)(arg1)->pop(arg2,arg3); | |||
5548 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_Event,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[3], 1); SWIG_arg++; | |||
5549 | return SWIG_arg; | |||
5550 | ||||
5551 | if(0) SWIG_fail{goto fail;}; | |||
5552 | ||||
5553 | fail: | |||
5554 | lua_error(L); | |||
5555 | return SWIG_arg; | |||
5556 | } | |||
5557 | ||||
5558 | ||||
5559 | static int _wrap_EventConsumer_cleanup(lua_State* L) { | |||
5560 | int SWIG_arg = 0; | |||
5561 | EventConsumer *arg1 = (EventConsumer *) 0 ; | |||
5562 | ||||
5563 | SWIG_check_num_args("EventConsumer::cleanup",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","EventConsumer::cleanup" ,1,1,lua_gettop(L)); goto fail;} | |||
5564 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("EventConsumer::cleanup",1,"EventConsumer *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer::cleanup",1,"EventConsumer *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5565 | ||||
5566 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_EventConsumer,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[4],0) >= 0)){ | |||
5567 | SWIG_fail_ptr("EventConsumer_cleanup",1,SWIGTYPE_p_EventConsumer){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "EventConsumer_cleanup",1,(swig_types[4] && swig_types [4]->str)?swig_types[4]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5568 | } | |||
5569 | ||||
5570 | (arg1)->cleanup(); | |||
5571 | ||||
5572 | return SWIG_arg; | |||
5573 | ||||
5574 | if(0) SWIG_fail{goto fail;}; | |||
5575 | ||||
5576 | fail: | |||
5577 | lua_error(L); | |||
5578 | return SWIG_arg; | |||
5579 | } | |||
5580 | ||||
5581 | ||||
5582 | static void swig_delete_EventConsumer(void *obj) { | |||
5583 | EventConsumer *arg1 = (EventConsumer *) obj; | |||
5584 | delete arg1; | |||
5585 | } | |||
5586 | static int _proxy__wrap_new_EventConsumer(lua_State *L) { | |||
5587 | assert(lua_istable(L,1))(static_cast <bool> ((lua_type(L, (1)) == 5)) ? void (0 ) : __assert_fail ("lua_istable(L,1)", "mod_lua_wrap.cpp", 5587 , __extension__ __PRETTY_FUNCTION__)); | |||
5588 | lua_pushcfunction(L,_wrap_new_EventConsumer)lua_pushcclosure(L, (_wrap_new_EventConsumer), 0); | |||
5589 | assert(!lua_isnil(L,-1))(static_cast <bool> (!(lua_type(L, (-1)) == 0)) ? void ( 0) : __assert_fail ("!lua_isnil(L,-1)", "mod_lua_wrap.cpp", 5589 , __extension__ __PRETTY_FUNCTION__)); | |||
5590 | lua_replace(L,1); /* replace our table with real constructor */ | |||
5591 | lua_call(L,lua_gettop(L)-1,1)lua_callk(L, (lua_gettop(L)-1), (1), 0, __null); | |||
5592 | return 1; | |||
5593 | } | |||
5594 | static swig_lua_attribute swig_EventConsumer_attributes[] = { | |||
5595 | { "events", _wrap_EventConsumer_events_get, _wrap_EventConsumer_events_set }, | |||
5596 | { "e_event_id", _wrap_EventConsumer_e_event_id_get, _wrap_EventConsumer_e_event_id_set }, | |||
5597 | { "e_callback", _wrap_EventConsumer_e_callback_get, _wrap_EventConsumer_e_callback_set }, | |||
5598 | { "e_subclass_name", _wrap_EventConsumer_e_subclass_name_get, _wrap_EventConsumer_e_subclass_name_set }, | |||
5599 | { "e_cb_arg", _wrap_EventConsumer_e_cb_arg_get, _wrap_EventConsumer_e_cb_arg_set }, | |||
5600 | { "enodes", _wrap_EventConsumer_enodes_get, _wrap_EventConsumer_enodes_set }, | |||
5601 | { "node_index", _wrap_EventConsumer_node_index_get, _wrap_EventConsumer_node_index_set }, | |||
5602 | {0,0,0} | |||
5603 | }; | |||
5604 | static swig_lua_method swig_EventConsumer_methods[]= { | |||
5605 | { "bind", _wrap_EventConsumer_bind}, | |||
5606 | { "pop", _wrap_EventConsumer_pop}, | |||
5607 | { "cleanup", _wrap_EventConsumer_cleanup}, | |||
5608 | {0,0} | |||
5609 | }; | |||
5610 | static swig_lua_method swig_EventConsumer_meta[] = { | |||
5611 | {0,0} | |||
5612 | }; | |||
5613 | ||||
5614 | static swig_lua_attribute swig_EventConsumer_Sf_SwigStatic_attributes[] = { | |||
5615 | {0,0,0} | |||
5616 | }; | |||
5617 | static swig_lua_const_info swig_EventConsumer_Sf_SwigStatic_constants[]= { | |||
5618 | {0,0,0,0,0,0} | |||
5619 | }; | |||
5620 | static swig_lua_method swig_EventConsumer_Sf_SwigStatic_methods[]= { | |||
5621 | {0,0} | |||
5622 | }; | |||
5623 | static swig_lua_class* swig_EventConsumer_Sf_SwigStatic_classes[]= { | |||
5624 | 0 | |||
5625 | }; | |||
5626 | ||||
5627 | static swig_lua_namespace swig_EventConsumer_Sf_SwigStatic = { | |||
5628 | "EventConsumer", | |||
5629 | swig_EventConsumer_Sf_SwigStatic_methods, | |||
5630 | swig_EventConsumer_Sf_SwigStatic_attributes, | |||
5631 | swig_EventConsumer_Sf_SwigStatic_constants, | |||
5632 | swig_EventConsumer_Sf_SwigStatic_classes, | |||
5633 | 0 | |||
5634 | }; | |||
5635 | static swig_lua_class *swig_EventConsumer_bases[] = {0}; | |||
5636 | static const char *swig_EventConsumer_base_names[] = {0}; | |||
5637 | static swig_lua_class _wrap_class_EventConsumer = { "EventConsumer", "EventConsumer", &SWIGTYPE_p_EventConsumerswig_types[4],_proxy__wrap_new_EventConsumer, swig_delete_EventConsumer, swig_EventConsumer_methods, swig_EventConsumer_attributes, &swig_EventConsumer_Sf_SwigStatic, swig_EventConsumer_meta, swig_EventConsumer_bases, swig_EventConsumer_base_names }; | |||
5638 | ||||
5639 | static int _wrap_CoreSession_session_set(lua_State* L) { | |||
5640 | int SWIG_arg = 0; | |||
5641 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
5642 | switch_core_session_t *arg2 = (switch_core_session_t *) 0 ; | |||
5643 | ||||
5644 | SWIG_check_num_args("CoreSession::session",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::session" ,2,2,lua_gettop(L)); goto fail;} | |||
5645 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::session",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::session",1,"CoreSession *",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5646 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("CoreSession::session",2,"switch_core_session_t *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::session",2,"switch_core_session_t *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5647 | ||||
5648 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
5649 | SWIG_fail_ptr("CoreSession_session_set",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_session_set",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5650 | } | |||
5651 | ||||
5652 | ||||
5653 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&arg2,SWIGTYPE_p_switch_core_session_t,SWIG_POINTER_DISOWN))(SWIG_Lua_ConvertPtr(L,2,(void**)&arg2,swig_types[20],0x1 ) >= 0)){ | |||
5654 | SWIG_fail_ptr("CoreSession_session_set",2,SWIGTYPE_p_switch_core_session_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_session_set",2,(swig_types[20] && swig_types [20]->str)?swig_types[20]->str:"void*",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5655 | } | |||
5656 | ||||
5657 | if (arg1) (arg1)->session = arg2; | |||
5658 | ||||
5659 | return SWIG_arg; | |||
5660 | ||||
5661 | if(0) SWIG_fail{goto fail;}; | |||
5662 | ||||
5663 | fail: | |||
5664 | lua_error(L); | |||
5665 | return SWIG_arg; | |||
5666 | } | |||
5667 | ||||
5668 | ||||
5669 | static int _wrap_CoreSession_session_get(lua_State* L) { | |||
5670 | int SWIG_arg = 0; | |||
5671 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
5672 | switch_core_session_t *result = 0 ; | |||
5673 | ||||
5674 | SWIG_check_num_args("CoreSession::session",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::session" ,1,1,lua_gettop(L)); goto fail;} | |||
5675 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::session",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::session",1,"CoreSession *",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5676 | ||||
5677 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
5678 | SWIG_fail_ptr("CoreSession_session_get",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_session_get",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5679 | } | |||
5680 | ||||
5681 | result = (switch_core_session_t *) ((arg1)->session); | |||
5682 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_switch_core_session_t,0)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[20], 0); SWIG_arg++; | |||
5683 | return SWIG_arg; | |||
5684 | ||||
5685 | if(0) SWIG_fail{goto fail;}; | |||
5686 | ||||
5687 | fail: | |||
5688 | lua_error(L); | |||
5689 | return SWIG_arg; | |||
5690 | } | |||
5691 | ||||
5692 | ||||
5693 | static int _wrap_CoreSession_channel_set(lua_State* L) { | |||
5694 | int SWIG_arg = 0; | |||
5695 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
5696 | switch_channel_t *arg2 = (switch_channel_t *) 0 ; | |||
5697 | ||||
5698 | SWIG_check_num_args("CoreSession::channel",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::channel" ,2,2,lua_gettop(L)); goto fail;} | |||
5699 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::channel",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::channel",1,"CoreSession *",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5700 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("CoreSession::channel",2,"switch_channel_t *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::channel",2,"switch_channel_t *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5701 | ||||
5702 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
5703 | SWIG_fail_ptr("CoreSession_channel_set",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_channel_set",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5704 | } | |||
5705 | ||||
5706 | ||||
5707 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&arg2,SWIGTYPE_p_switch_channel_t,SWIG_POINTER_DISOWN))(SWIG_Lua_ConvertPtr(L,2,(void**)&arg2,swig_types[19],0x1 ) >= 0)){ | |||
5708 | SWIG_fail_ptr("CoreSession_channel_set",2,SWIGTYPE_p_switch_channel_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_channel_set",2,(swig_types[19] && swig_types [19]->str)?swig_types[19]->str:"void*",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5709 | } | |||
5710 | ||||
5711 | if (arg1) (arg1)->channel = arg2; | |||
5712 | ||||
5713 | return SWIG_arg; | |||
5714 | ||||
5715 | if(0) SWIG_fail{goto fail;}; | |||
5716 | ||||
5717 | fail: | |||
5718 | lua_error(L); | |||
5719 | return SWIG_arg; | |||
5720 | } | |||
5721 | ||||
5722 | ||||
5723 | static int _wrap_CoreSession_channel_get(lua_State* L) { | |||
5724 | int SWIG_arg = 0; | |||
5725 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
5726 | switch_channel_t *result = 0 ; | |||
5727 | ||||
5728 | SWIG_check_num_args("CoreSession::channel",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::channel" ,1,1,lua_gettop(L)); goto fail;} | |||
5729 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::channel",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::channel",1,"CoreSession *",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5730 | ||||
5731 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
5732 | SWIG_fail_ptr("CoreSession_channel_get",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_channel_get",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5733 | } | |||
5734 | ||||
5735 | result = (switch_channel_t *) ((arg1)->channel); | |||
5736 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_switch_channel_t,0)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[19], 0); SWIG_arg++; | |||
5737 | return SWIG_arg; | |||
5738 | ||||
5739 | if(0) SWIG_fail{goto fail;}; | |||
5740 | ||||
5741 | fail: | |||
5742 | lua_error(L); | |||
5743 | return SWIG_arg; | |||
5744 | } | |||
5745 | ||||
5746 | ||||
5747 | static int _wrap_CoreSession_flags_set(lua_State* L) { | |||
5748 | int SWIG_arg = 0; | |||
5749 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
5750 | unsigned int arg2 ; | |||
5751 | ||||
5752 | SWIG_check_num_args("CoreSession::flags",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::flags" ,2,2,lua_gettop(L)); goto fail;} | |||
5753 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::flags",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::flags",1,"CoreSession *",SWIG_Lua_typename(L, 1)); goto fail;}; | |||
5754 | if(!lua_isnumber(L,2)) SWIG_fail_arg("CoreSession::flags",2,"unsigned int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::flags",2,"unsigned int",SWIG_Lua_typename(L,2 )); goto fail;}; | |||
5755 | ||||
5756 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
5757 | SWIG_fail_ptr("CoreSession_flags_set",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_flags_set",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5758 | } | |||
5759 | ||||
5760 | SWIG_contract_assert((lua_tonumber(L,2)>=0),"number must not be negative")if (!((lua_tonumberx(L,2,__null)>=0))) { SWIG_Lua_pusherrstring (L, (char *) "number must not be negative"); goto fail; } else | |||
5761 | arg2 = (unsigned int)lua_tonumber(L, 2)lua_tonumberx(L,2,__null); | |||
5762 | if (arg1) (arg1)->flags = arg2; | |||
5763 | ||||
5764 | return SWIG_arg; | |||
5765 | ||||
5766 | if(0) SWIG_fail{goto fail;}; | |||
5767 | ||||
5768 | fail: | |||
5769 | lua_error(L); | |||
5770 | return SWIG_arg; | |||
5771 | } | |||
5772 | ||||
5773 | ||||
5774 | static int _wrap_CoreSession_flags_get(lua_State* L) { | |||
5775 | int SWIG_arg = 0; | |||
5776 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
5777 | unsigned int result; | |||
5778 | ||||
5779 | SWIG_check_num_args("CoreSession::flags",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::flags" ,1,1,lua_gettop(L)); goto fail;} | |||
5780 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::flags",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::flags",1,"CoreSession *",SWIG_Lua_typename(L, 1)); goto fail;}; | |||
5781 | ||||
5782 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
5783 | SWIG_fail_ptr("CoreSession_flags_get",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_flags_get",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5784 | } | |||
5785 | ||||
5786 | result = (unsigned int) ((arg1)->flags); | |||
5787 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
5788 | return SWIG_arg; | |||
5789 | ||||
5790 | if(0) SWIG_fail{goto fail;}; | |||
5791 | ||||
5792 | fail: | |||
5793 | lua_error(L); | |||
5794 | return SWIG_arg; | |||
5795 | } | |||
5796 | ||||
5797 | ||||
5798 | static int _wrap_CoreSession_allocated_set(lua_State* L) { | |||
5799 | int SWIG_arg = 0; | |||
5800 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
5801 | int arg2 ; | |||
5802 | ||||
5803 | SWIG_check_num_args("CoreSession::allocated",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::allocated" ,2,2,lua_gettop(L)); goto fail;} | |||
5804 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::allocated",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::allocated",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5805 | if(!lua_isnumber(L,2)) SWIG_fail_arg("CoreSession::allocated",2,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::allocated",2,"int",SWIG_Lua_typename(L,2)); goto fail;}; | |||
5806 | ||||
5807 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
5808 | SWIG_fail_ptr("CoreSession_allocated_set",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_allocated_set",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5809 | } | |||
5810 | ||||
5811 | arg2 = (int)lua_tonumber(L, 2)lua_tonumberx(L,2,__null); | |||
5812 | if (arg1) (arg1)->allocated = arg2; | |||
5813 | ||||
5814 | return SWIG_arg; | |||
5815 | ||||
5816 | if(0) SWIG_fail{goto fail;}; | |||
5817 | ||||
5818 | fail: | |||
5819 | lua_error(L); | |||
5820 | return SWIG_arg; | |||
5821 | } | |||
5822 | ||||
5823 | ||||
5824 | static int _wrap_CoreSession_allocated_get(lua_State* L) { | |||
5825 | int SWIG_arg = 0; | |||
5826 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
5827 | int result; | |||
5828 | ||||
5829 | SWIG_check_num_args("CoreSession::allocated",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::allocated" ,1,1,lua_gettop(L)); goto fail;} | |||
5830 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::allocated",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::allocated",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5831 | ||||
5832 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
5833 | SWIG_fail_ptr("CoreSession_allocated_get",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_allocated_get",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5834 | } | |||
5835 | ||||
5836 | result = (int) ((arg1)->allocated); | |||
5837 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
5838 | return SWIG_arg; | |||
5839 | ||||
5840 | if(0) SWIG_fail{goto fail;}; | |||
5841 | ||||
5842 | fail: | |||
5843 | lua_error(L); | |||
5844 | return SWIG_arg; | |||
5845 | } | |||
5846 | ||||
5847 | ||||
5848 | static int _wrap_CoreSession_cb_state_set(lua_State* L) { | |||
5849 | int SWIG_arg = 0; | |||
5850 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
5851 | input_callback_state *arg2 = (input_callback_state *) 0 ; | |||
5852 | ||||
5853 | SWIG_check_num_args("CoreSession::cb_state",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::cb_state" ,2,2,lua_gettop(L)); goto fail;} | |||
5854 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::cb_state",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::cb_state",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5855 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("CoreSession::cb_state",2,"input_callback_state *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::cb_state",2,"input_callback_state *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5856 | ||||
5857 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
5858 | SWIG_fail_ptr("CoreSession_cb_state_set",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_cb_state_set",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5859 | } | |||
5860 | ||||
5861 | ||||
5862 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&arg2,SWIGTYPE_p_input_callback_state,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&arg2,swig_types[11],0) >= 0)){ | |||
5863 | SWIG_fail_ptr("CoreSession_cb_state_set",2,SWIGTYPE_p_input_callback_state){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_cb_state_set",2,(swig_types[11] && swig_types [11]->str)?swig_types[11]->str:"void*",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5864 | } | |||
5865 | ||||
5866 | if (arg1) (arg1)->cb_state = *arg2; | |||
5867 | ||||
5868 | return SWIG_arg; | |||
5869 | ||||
5870 | if(0) SWIG_fail{goto fail;}; | |||
5871 | ||||
5872 | fail: | |||
5873 | lua_error(L); | |||
5874 | return SWIG_arg; | |||
5875 | } | |||
5876 | ||||
5877 | ||||
5878 | static int _wrap_CoreSession_cb_state_get(lua_State* L) { | |||
5879 | int SWIG_arg = 0; | |||
5880 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
5881 | input_callback_state *result = 0 ; | |||
5882 | ||||
5883 | SWIG_check_num_args("CoreSession::cb_state",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::cb_state" ,1,1,lua_gettop(L)); goto fail;} | |||
5884 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::cb_state",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::cb_state",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5885 | ||||
5886 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
5887 | SWIG_fail_ptr("CoreSession_cb_state_get",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_cb_state_get",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5888 | } | |||
5889 | ||||
5890 | result = (input_callback_state *)& ((arg1)->cb_state); | |||
5891 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_input_callback_state,0)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[11], 0); SWIG_arg++; | |||
5892 | return SWIG_arg; | |||
5893 | ||||
5894 | if(0) SWIG_fail{goto fail;}; | |||
5895 | ||||
5896 | fail: | |||
5897 | lua_error(L); | |||
5898 | return SWIG_arg; | |||
5899 | } | |||
5900 | ||||
5901 | ||||
5902 | static int _wrap_CoreSession_hook_state_set(lua_State* L) { | |||
5903 | int SWIG_arg = 0; | |||
5904 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
5905 | switch_channel_state_t arg2 ; | |||
5906 | switch_channel_state_t *argp2 ; | |||
5907 | ||||
5908 | SWIG_check_num_args("CoreSession::hook_state",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::hook_state" ,2,2,lua_gettop(L)); goto fail;} | |||
5909 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::hook_state",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::hook_state",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5910 | if(!lua_isuserdata(L,2)) SWIG_fail_arg("CoreSession::hook_state",2,"switch_channel_state_t"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::hook_state",2,"switch_channel_state_t",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5911 | ||||
5912 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
5913 | SWIG_fail_ptr("CoreSession_hook_state_set",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_hook_state_set",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5914 | } | |||
5915 | ||||
5916 | ||||
5917 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&argp2,SWIGTYPE_p_switch_channel_state_t,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&argp2,swig_types[18],0) >= 0)){ | |||
5918 | SWIG_fail_ptr("CoreSession_hook_state_set",2,SWIGTYPE_p_switch_channel_state_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_hook_state_set",2,(swig_types[18] && swig_types [18]->str)?swig_types[18]->str:"void*",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5919 | } | |||
5920 | arg2 = *argp2; | |||
5921 | ||||
5922 | if (arg1) (arg1)->hook_state = arg2; | |||
5923 | ||||
5924 | return SWIG_arg; | |||
5925 | ||||
5926 | if(0) SWIG_fail{goto fail;}; | |||
5927 | ||||
5928 | fail: | |||
5929 | lua_error(L); | |||
5930 | return SWIG_arg; | |||
5931 | } | |||
5932 | ||||
5933 | ||||
5934 | static int _wrap_CoreSession_hook_state_get(lua_State* L) { | |||
5935 | int SWIG_arg = 0; | |||
5936 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
5937 | switch_channel_state_t result; | |||
5938 | ||||
5939 | SWIG_check_num_args("CoreSession::hook_state",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::hook_state" ,1,1,lua_gettop(L)); goto fail;} | |||
5940 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::hook_state",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::hook_state",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
5941 | ||||
5942 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
5943 | SWIG_fail_ptr("CoreSession_hook_state_get",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_hook_state_get",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5944 | } | |||
5945 | ||||
5946 | result = ((arg1)->hook_state); | |||
5947 | { | |||
5948 | switch_channel_state_t * resultptr = new switch_channel_state_t((const switch_channel_state_t &) result); | |||
5949 | SWIG_NewPointerObj(L,(void *) resultptr,SWIGTYPE_p_switch_channel_state_t,1)SWIG_Lua_NewPointerObj(L, (void *)(void *) resultptr, swig_types [18], 1); SWIG_arg++; | |||
5950 | } | |||
5951 | return SWIG_arg; | |||
5952 | ||||
5953 | if(0) SWIG_fail{goto fail;}; | |||
5954 | ||||
5955 | fail: | |||
5956 | lua_error(L); | |||
5957 | return SWIG_arg; | |||
5958 | } | |||
5959 | ||||
5960 | ||||
5961 | static int _wrap_CoreSession_cause_set(lua_State* L) { | |||
5962 | int SWIG_arg = 0; | |||
5963 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
5964 | switch_call_cause_t arg2 ; | |||
5965 | switch_call_cause_t *argp2 ; | |||
5966 | ||||
5967 | SWIG_check_num_args("CoreSession::cause",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::cause" ,2,2,lua_gettop(L)); goto fail;} | |||
5968 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::cause",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::cause",1,"CoreSession *",SWIG_Lua_typename(L, 1)); goto fail;}; | |||
5969 | if(!lua_isuserdata(L,2)) SWIG_fail_arg("CoreSession::cause",2,"switch_call_cause_t"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::cause",2,"switch_call_cause_t",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5970 | ||||
5971 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
5972 | SWIG_fail_ptr("CoreSession_cause_set",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_cause_set",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
5973 | } | |||
5974 | ||||
5975 | ||||
5976 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&argp2,SWIGTYPE_p_switch_call_cause_t,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&argp2,swig_types[17],0) >= 0)){ | |||
5977 | SWIG_fail_ptr("CoreSession_cause_set",2,SWIGTYPE_p_switch_call_cause_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_cause_set",2,(swig_types[17] && swig_types [17]->str)?swig_types[17]->str:"void*",SWIG_Lua_typename (L,2)); goto fail;}; | |||
5978 | } | |||
5979 | arg2 = *argp2; | |||
5980 | ||||
5981 | if (arg1) (arg1)->cause = arg2; | |||
5982 | ||||
5983 | return SWIG_arg; | |||
5984 | ||||
5985 | if(0) SWIG_fail{goto fail;}; | |||
5986 | ||||
5987 | fail: | |||
5988 | lua_error(L); | |||
5989 | return SWIG_arg; | |||
5990 | } | |||
5991 | ||||
5992 | ||||
5993 | static int _wrap_CoreSession_cause_get(lua_State* L) { | |||
5994 | int SWIG_arg = 0; | |||
5995 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
5996 | switch_call_cause_t result; | |||
5997 | ||||
5998 | SWIG_check_num_args("CoreSession::cause",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::cause" ,1,1,lua_gettop(L)); goto fail;} | |||
5999 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::cause",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::cause",1,"CoreSession *",SWIG_Lua_typename(L, 1)); goto fail;}; | |||
6000 | ||||
6001 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6002 | SWIG_fail_ptr("CoreSession_cause_get",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_cause_get",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6003 | } | |||
6004 | ||||
6005 | result = ((arg1)->cause); | |||
6006 | { | |||
6007 | switch_call_cause_t * resultptr = new switch_call_cause_t((const switch_call_cause_t &) result); | |||
6008 | SWIG_NewPointerObj(L,(void *) resultptr,SWIGTYPE_p_switch_call_cause_t,1)SWIG_Lua_NewPointerObj(L, (void *)(void *) resultptr, swig_types [17], 1); SWIG_arg++; | |||
6009 | } | |||
6010 | return SWIG_arg; | |||
6011 | ||||
6012 | if(0) SWIG_fail{goto fail;}; | |||
6013 | ||||
6014 | fail: | |||
6015 | lua_error(L); | |||
6016 | return SWIG_arg; | |||
6017 | } | |||
6018 | ||||
6019 | ||||
6020 | static int _wrap_CoreSession_uuid_set(lua_State* L) { | |||
6021 | int SWIG_arg = 0; | |||
6022 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6023 | char *arg2 = (char *) 0 ; | |||
6024 | ||||
6025 | SWIG_check_num_args("CoreSession::uuid",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::uuid" ,2,2,lua_gettop(L)); goto fail;} | |||
6026 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::uuid",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::uuid",1,"CoreSession *",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
6027 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::uuid",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::uuid",2,"char *",SWIG_Lua_typename(L,2)); goto fail;}; | |||
6028 | ||||
6029 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6030 | SWIG_fail_ptr("CoreSession_uuid_set",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_uuid_set",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6031 | } | |||
6032 | ||||
6033 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
6034 | { | |||
6035 | delete [] arg1->uuid; | |||
6036 | if (arg2) { | |||
6037 | arg1->uuid = (char *) (new char[strlen((const char *)arg2)+1]); | |||
6038 | strcpy((char *)arg1->uuid, (const char *)arg2); | |||
6039 | } else { | |||
6040 | arg1->uuid = 0; | |||
6041 | } | |||
6042 | } | |||
6043 | ||||
6044 | return SWIG_arg; | |||
6045 | ||||
6046 | if(0) SWIG_fail{goto fail;}; | |||
6047 | ||||
6048 | fail: | |||
6049 | lua_error(L); | |||
6050 | return SWIG_arg; | |||
6051 | } | |||
6052 | ||||
6053 | ||||
6054 | static int _wrap_CoreSession_uuid_get(lua_State* L) { | |||
6055 | int SWIG_arg = 0; | |||
6056 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6057 | char *result = 0 ; | |||
6058 | ||||
6059 | SWIG_check_num_args("CoreSession::uuid",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::uuid" ,1,1,lua_gettop(L)); goto fail;} | |||
6060 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::uuid",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::uuid",1,"CoreSession *",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
6061 | ||||
6062 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6063 | SWIG_fail_ptr("CoreSession_uuid_get",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_uuid_get",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6064 | } | |||
6065 | ||||
6066 | result = (char *) ((arg1)->uuid); | |||
6067 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
6068 | return SWIG_arg; | |||
6069 | ||||
6070 | if(0) SWIG_fail{goto fail;}; | |||
6071 | ||||
6072 | fail: | |||
6073 | lua_error(L); | |||
6074 | return SWIG_arg; | |||
6075 | } | |||
6076 | ||||
6077 | ||||
6078 | static int _wrap_CoreSession_tts_name_set(lua_State* L) { | |||
6079 | int SWIG_arg = 0; | |||
6080 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6081 | char *arg2 = (char *) 0 ; | |||
6082 | ||||
6083 | SWIG_check_num_args("CoreSession::tts_name",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::tts_name" ,2,2,lua_gettop(L)); goto fail;} | |||
6084 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::tts_name",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::tts_name",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6085 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::tts_name",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::tts_name",2,"char *",SWIG_Lua_typename(L,2)); goto fail;}; | |||
6086 | ||||
6087 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6088 | SWIG_fail_ptr("CoreSession_tts_name_set",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_tts_name_set",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6089 | } | |||
6090 | ||||
6091 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
6092 | { | |||
6093 | delete [] arg1->tts_name; | |||
6094 | if (arg2) { | |||
6095 | arg1->tts_name = (char *) (new char[strlen((const char *)arg2)+1]); | |||
6096 | strcpy((char *)arg1->tts_name, (const char *)arg2); | |||
6097 | } else { | |||
6098 | arg1->tts_name = 0; | |||
6099 | } | |||
6100 | } | |||
6101 | ||||
6102 | return SWIG_arg; | |||
6103 | ||||
6104 | if(0) SWIG_fail{goto fail;}; | |||
6105 | ||||
6106 | fail: | |||
6107 | lua_error(L); | |||
6108 | return SWIG_arg; | |||
6109 | } | |||
6110 | ||||
6111 | ||||
6112 | static int _wrap_CoreSession_tts_name_get(lua_State* L) { | |||
6113 | int SWIG_arg = 0; | |||
6114 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6115 | char *result = 0 ; | |||
6116 | ||||
6117 | SWIG_check_num_args("CoreSession::tts_name",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::tts_name" ,1,1,lua_gettop(L)); goto fail;} | |||
6118 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::tts_name",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::tts_name",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6119 | ||||
6120 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6121 | SWIG_fail_ptr("CoreSession_tts_name_get",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_tts_name_get",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6122 | } | |||
6123 | ||||
6124 | result = (char *) ((arg1)->tts_name); | |||
6125 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
6126 | return SWIG_arg; | |||
6127 | ||||
6128 | if(0) SWIG_fail{goto fail;}; | |||
6129 | ||||
6130 | fail: | |||
6131 | lua_error(L); | |||
6132 | return SWIG_arg; | |||
6133 | } | |||
6134 | ||||
6135 | ||||
6136 | static int _wrap_CoreSession_voice_name_set(lua_State* L) { | |||
6137 | int SWIG_arg = 0; | |||
6138 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6139 | char *arg2 = (char *) 0 ; | |||
6140 | ||||
6141 | SWIG_check_num_args("CoreSession::voice_name",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::voice_name" ,2,2,lua_gettop(L)); goto fail;} | |||
6142 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::voice_name",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::voice_name",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6143 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::voice_name",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::voice_name",2,"char *",SWIG_Lua_typename(L,2) ); goto fail;}; | |||
6144 | ||||
6145 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6146 | SWIG_fail_ptr("CoreSession_voice_name_set",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_voice_name_set",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6147 | } | |||
6148 | ||||
6149 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
6150 | { | |||
6151 | delete [] arg1->voice_name; | |||
6152 | if (arg2) { | |||
6153 | arg1->voice_name = (char *) (new char[strlen((const char *)arg2)+1]); | |||
6154 | strcpy((char *)arg1->voice_name, (const char *)arg2); | |||
6155 | } else { | |||
6156 | arg1->voice_name = 0; | |||
6157 | } | |||
6158 | } | |||
6159 | ||||
6160 | return SWIG_arg; | |||
6161 | ||||
6162 | if(0) SWIG_fail{goto fail;}; | |||
6163 | ||||
6164 | fail: | |||
6165 | lua_error(L); | |||
6166 | return SWIG_arg; | |||
6167 | } | |||
6168 | ||||
6169 | ||||
6170 | static int _wrap_CoreSession_voice_name_get(lua_State* L) { | |||
6171 | int SWIG_arg = 0; | |||
6172 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6173 | char *result = 0 ; | |||
6174 | ||||
6175 | SWIG_check_num_args("CoreSession::voice_name",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::voice_name" ,1,1,lua_gettop(L)); goto fail;} | |||
6176 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::voice_name",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::voice_name",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6177 | ||||
6178 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6179 | SWIG_fail_ptr("CoreSession_voice_name_get",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_voice_name_get",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6180 | } | |||
6181 | ||||
6182 | result = (char *) ((arg1)->voice_name); | |||
6183 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
6184 | return SWIG_arg; | |||
6185 | ||||
6186 | if(0) SWIG_fail{goto fail;}; | |||
6187 | ||||
6188 | fail: | |||
6189 | lua_error(L); | |||
6190 | return SWIG_arg; | |||
6191 | } | |||
6192 | ||||
6193 | ||||
6194 | static int _wrap_CoreSession_insertFile(lua_State* L) { | |||
6195 | int SWIG_arg = 0; | |||
6196 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6197 | char *arg2 = (char *) 0 ; | |||
6198 | char *arg3 = (char *) 0 ; | |||
6199 | int arg4 ; | |||
6200 | int result; | |||
6201 | ||||
6202 | SWIG_check_num_args("CoreSession::insertFile",4,4)if (lua_gettop(L)<4 || lua_gettop(L)>4) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::insertFile" ,4,4,lua_gettop(L)); goto fail;} | |||
6203 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::insertFile",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::insertFile",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6204 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::insertFile",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::insertFile",2,"char const *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
6205 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("CoreSession::insertFile",3,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::insertFile",3,"char const *",SWIG_Lua_typename (L,3)); goto fail;}; | |||
6206 | if(!lua_isnumber(L,4)) SWIG_fail_arg("CoreSession::insertFile",4,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::insertFile",4,"int",SWIG_Lua_typename(L,4)); goto fail;}; | |||
6207 | ||||
6208 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6209 | SWIG_fail_ptr("CoreSession_insertFile",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_insertFile",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6210 | } | |||
6211 | ||||
6212 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
6213 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
6214 | arg4 = (int)lua_tonumber(L, 4)lua_tonumberx(L,4,__null); | |||
6215 | result = (int)(arg1)->insertFile((char const *)arg2,(char const *)arg3,arg4); | |||
6216 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
6217 | return SWIG_arg; | |||
6218 | ||||
6219 | if(0) SWIG_fail{goto fail;}; | |||
6220 | ||||
6221 | fail: | |||
6222 | lua_error(L); | |||
6223 | return SWIG_arg; | |||
6224 | } | |||
6225 | ||||
6226 | ||||
6227 | static int _wrap_CoreSession_answer(lua_State* L) { | |||
6228 | int SWIG_arg = 0; | |||
6229 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6230 | int result; | |||
6231 | ||||
6232 | SWIG_check_num_args("CoreSession::answer",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::answer" ,1,1,lua_gettop(L)); goto fail;} | |||
6233 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::answer",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::answer",1,"CoreSession *",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
6234 | ||||
6235 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6236 | SWIG_fail_ptr("CoreSession_answer",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_answer",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6237 | } | |||
6238 | ||||
6239 | result = (int)(arg1)->answer(); | |||
6240 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
6241 | return SWIG_arg; | |||
6242 | ||||
6243 | if(0) SWIG_fail{goto fail;}; | |||
6244 | ||||
6245 | fail: | |||
6246 | lua_error(L); | |||
6247 | return SWIG_arg; | |||
6248 | } | |||
6249 | ||||
6250 | ||||
6251 | static int _wrap_CoreSession_print(lua_State* L) { | |||
6252 | int SWIG_arg = 0; | |||
6253 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6254 | char *arg2 = (char *) 0 ; | |||
6255 | int result; | |||
6256 | ||||
6257 | SWIG_check_num_args("CoreSession::print",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::print" ,2,2,lua_gettop(L)); goto fail;} | |||
6258 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::print",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::print",1,"CoreSession *",SWIG_Lua_typename(L, 1)); goto fail;}; | |||
6259 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::print",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::print",2,"char *",SWIG_Lua_typename(L,2)); goto fail;}; | |||
6260 | ||||
6261 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6262 | SWIG_fail_ptr("CoreSession_print",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_print",1,(swig_types[1] && swig_types[ 1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
6263 | } | |||
6264 | ||||
6265 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
6266 | result = (int)(arg1)->print(arg2); | |||
6267 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
6268 | return SWIG_arg; | |||
6269 | ||||
6270 | if(0) SWIG_fail{goto fail;}; | |||
6271 | ||||
6272 | fail: | |||
6273 | lua_error(L); | |||
6274 | return SWIG_arg; | |||
6275 | } | |||
6276 | ||||
6277 | ||||
6278 | static int _wrap_CoreSession_preAnswer(lua_State* L) { | |||
6279 | int SWIG_arg = 0; | |||
6280 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6281 | int result; | |||
6282 | ||||
6283 | SWIG_check_num_args("CoreSession::preAnswer",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::preAnswer" ,1,1,lua_gettop(L)); goto fail;} | |||
6284 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::preAnswer",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::preAnswer",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6285 | ||||
6286 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6287 | SWIG_fail_ptr("CoreSession_preAnswer",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_preAnswer",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6288 | } | |||
6289 | ||||
6290 | result = (int)(arg1)->preAnswer(); | |||
6291 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
6292 | return SWIG_arg; | |||
6293 | ||||
6294 | if(0) SWIG_fail{goto fail;}; | |||
6295 | ||||
6296 | fail: | |||
6297 | lua_error(L); | |||
6298 | return SWIG_arg; | |||
6299 | } | |||
6300 | ||||
6301 | ||||
6302 | static int _wrap_CoreSession_hangup(lua_State* L) { | |||
6303 | int SWIG_arg = 0; | |||
6304 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6305 | char *arg2 = (char *) "normal_clearing" ; | |||
6306 | ||||
6307 | SWIG_check_num_args("CoreSession::hangup",1,2)if (lua_gettop(L)<1 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::hangup" ,1,2,lua_gettop(L)); goto fail;} | |||
6308 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::hangup",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::hangup",1,"CoreSession *",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
6309 | if(lua_gettop(L)>=2 && !SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::hangup",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::hangup",2,"char const *",SWIG_Lua_typename(L, 2)); goto fail;}; | |||
6310 | ||||
6311 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6312 | SWIG_fail_ptr("CoreSession_hangup",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_hangup",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6313 | } | |||
6314 | ||||
6315 | if(lua_gettop(L)>=2){ | |||
6316 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
6317 | } | |||
6318 | (arg1)->hangup((char const *)arg2); | |||
6319 | ||||
6320 | return SWIG_arg; | |||
6321 | ||||
6322 | if(0) SWIG_fail{goto fail;}; | |||
6323 | ||||
6324 | fail: | |||
6325 | lua_error(L); | |||
6326 | return SWIG_arg; | |||
6327 | } | |||
6328 | ||||
6329 | ||||
6330 | static int _wrap_CoreSession_hangupState(lua_State* L) { | |||
6331 | int SWIG_arg = 0; | |||
6332 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6333 | ||||
6334 | SWIG_check_num_args("CoreSession::hangupState",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::hangupState" ,1,1,lua_gettop(L)); goto fail;} | |||
6335 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::hangupState",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::hangupState",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6336 | ||||
6337 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6338 | SWIG_fail_ptr("CoreSession_hangupState",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_hangupState",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6339 | } | |||
6340 | ||||
6341 | (arg1)->hangupState(); | |||
6342 | ||||
6343 | return SWIG_arg; | |||
6344 | ||||
6345 | if(0) SWIG_fail{goto fail;}; | |||
6346 | ||||
6347 | fail: | |||
6348 | lua_error(L); | |||
6349 | return SWIG_arg; | |||
6350 | } | |||
6351 | ||||
6352 | ||||
6353 | static int _wrap_CoreSession_setVariable(lua_State* L) { | |||
6354 | int SWIG_arg = 0; | |||
6355 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6356 | char *arg2 = (char *) 0 ; | |||
6357 | char *arg3 = (char *) 0 ; | |||
6358 | ||||
6359 | SWIG_check_num_args("CoreSession::setVariable",3,3)if (lua_gettop(L)<3 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::setVariable" ,3,3,lua_gettop(L)); goto fail;} | |||
6360 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::setVariable",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::setVariable",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6361 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::setVariable",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::setVariable",2,"char *",SWIG_Lua_typename(L,2 )); goto fail;}; | |||
6362 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("CoreSession::setVariable",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::setVariable",3,"char *",SWIG_Lua_typename(L,3 )); goto fail;}; | |||
6363 | ||||
6364 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6365 | SWIG_fail_ptr("CoreSession_setVariable",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_setVariable",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6366 | } | |||
6367 | ||||
6368 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
6369 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
6370 | (arg1)->setVariable(arg2,arg3); | |||
6371 | ||||
6372 | return SWIG_arg; | |||
6373 | ||||
6374 | if(0) SWIG_fail{goto fail;}; | |||
6375 | ||||
6376 | fail: | |||
6377 | lua_error(L); | |||
6378 | return SWIG_arg; | |||
6379 | } | |||
6380 | ||||
6381 | ||||
6382 | static int _wrap_CoreSession_setPrivate(lua_State* L) { | |||
6383 | int SWIG_arg = 0; | |||
6384 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6385 | char *arg2 = (char *) 0 ; | |||
6386 | void *arg3 = (void *) 0 ; | |||
6387 | ||||
6388 | SWIG_check_num_args("CoreSession::setPrivate",3,3)if (lua_gettop(L)<3 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::setPrivate" ,3,3,lua_gettop(L)); goto fail;} | |||
6389 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::setPrivate",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::setPrivate",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6390 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::setPrivate",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::setPrivate",2,"char *",SWIG_Lua_typename(L,2) ); goto fail;}; | |||
6391 | if(!SWIG_isptrtype(L,3)(lua_isuserdata(L,3) || (lua_type(L, (3)) == 0))) SWIG_fail_arg("CoreSession::setPrivate",3,"void *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::setPrivate",3,"void *",SWIG_Lua_typename(L,3) ); goto fail;}; | |||
6392 | ||||
6393 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6394 | SWIG_fail_ptr("CoreSession_setPrivate",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_setPrivate",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6395 | } | |||
6396 | ||||
6397 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
6398 | arg3=(void *)SWIG_MustGetPtr(L,3,0,0,3,"CoreSession_setPrivate")SWIG_Lua_MustGetPtr(L,3, 0,0, 3,"CoreSession_setPrivate"); | |||
6399 | (arg1)->setPrivate(arg2,arg3); | |||
6400 | ||||
6401 | return SWIG_arg; | |||
6402 | ||||
6403 | if(0) SWIG_fail{goto fail;}; | |||
6404 | ||||
6405 | fail: | |||
6406 | lua_error(L); | |||
6407 | return SWIG_arg; | |||
6408 | } | |||
6409 | ||||
6410 | ||||
6411 | static int _wrap_CoreSession_getPrivate(lua_State* L) { | |||
6412 | int SWIG_arg = 0; | |||
6413 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6414 | char *arg2 = (char *) 0 ; | |||
6415 | void *result = 0 ; | |||
6416 | ||||
6417 | SWIG_check_num_args("CoreSession::getPrivate",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::getPrivate" ,2,2,lua_gettop(L)); goto fail;} | |||
6418 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::getPrivate",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getPrivate",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6419 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::getPrivate",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getPrivate",2,"char *",SWIG_Lua_typename(L,2) ); goto fail;}; | |||
6420 | ||||
6421 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6422 | SWIG_fail_ptr("CoreSession_getPrivate",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_getPrivate",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6423 | } | |||
6424 | ||||
6425 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
6426 | result = (void *)(arg1)->getPrivate(arg2); | |||
6427 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_void,0)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[31], 0); SWIG_arg++; | |||
6428 | return SWIG_arg; | |||
6429 | ||||
6430 | if(0) SWIG_fail{goto fail;}; | |||
6431 | ||||
6432 | fail: | |||
6433 | lua_error(L); | |||
6434 | return SWIG_arg; | |||
6435 | } | |||
6436 | ||||
6437 | ||||
6438 | static int _wrap_CoreSession_getVariable(lua_State* L) { | |||
6439 | int SWIG_arg = 0; | |||
6440 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6441 | char *arg2 = (char *) 0 ; | |||
6442 | char *result = 0 ; | |||
6443 | ||||
6444 | SWIG_check_num_args("CoreSession::getVariable",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::getVariable" ,2,2,lua_gettop(L)); goto fail;} | |||
6445 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::getVariable",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getVariable",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6446 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::getVariable",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getVariable",2,"char *",SWIG_Lua_typename(L,2 )); goto fail;}; | |||
6447 | ||||
6448 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6449 | SWIG_fail_ptr("CoreSession_getVariable",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_getVariable",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6450 | } | |||
6451 | ||||
6452 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
6453 | result = (char *)(arg1)->getVariable(arg2); | |||
6454 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
6455 | return SWIG_arg; | |||
6456 | ||||
6457 | if(0) SWIG_fail{goto fail;}; | |||
6458 | ||||
6459 | fail: | |||
6460 | lua_error(L); | |||
6461 | return SWIG_arg; | |||
6462 | } | |||
6463 | ||||
6464 | ||||
6465 | static int _wrap_CoreSession_process_callback_result(lua_State* L) { | |||
6466 | int SWIG_arg = 0; | |||
6467 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6468 | char *arg2 = (char *) 0 ; | |||
6469 | switch_status_t result; | |||
6470 | ||||
6471 | SWIG_check_num_args("CoreSession::process_callback_result",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::process_callback_result" ,2,2,lua_gettop(L)); goto fail;} | |||
6472 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::process_callback_result",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::process_callback_result",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6473 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::process_callback_result",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::process_callback_result",2,"char *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
6474 | ||||
6475 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6476 | SWIG_fail_ptr("CoreSession_process_callback_result",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_process_callback_result",1,(swig_types[1] && swig_types[1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6477 | } | |||
6478 | ||||
6479 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
6480 | result = (arg1)->process_callback_result(arg2); | |||
6481 | { | |||
6482 | switch_status_t * resultptr = new switch_status_t((const switch_status_t &) result); | |||
6483 | SWIG_NewPointerObj(L,(void *) resultptr,SWIGTYPE_p_switch_status_t,1)SWIG_Lua_NewPointerObj(L, (void *)(void *) resultptr, swig_types [28], 1); SWIG_arg++; | |||
6484 | } | |||
6485 | return SWIG_arg; | |||
6486 | ||||
6487 | if(0) SWIG_fail{goto fail;}; | |||
6488 | ||||
6489 | fail: | |||
6490 | lua_error(L); | |||
6491 | return SWIG_arg; | |||
6492 | } | |||
6493 | ||||
6494 | ||||
6495 | static int _wrap_CoreSession_say(lua_State* L) { | |||
6496 | int SWIG_arg = 0; | |||
6497 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6498 | char *arg2 = (char *) 0 ; | |||
6499 | char *arg3 = (char *) 0 ; | |||
6500 | char *arg4 = (char *) 0 ; | |||
6501 | char *arg5 = (char *) 0 ; | |||
6502 | char *arg6 = (char *) NULL__null ; | |||
6503 | ||||
6504 | SWIG_check_num_args("CoreSession::say",5,6)if (lua_gettop(L)<5 || lua_gettop(L)>6) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::say" ,5,6,lua_gettop(L)); goto fail;} | |||
6505 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::say",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::say",1,"CoreSession *",SWIG_Lua_typename(L,1) ); goto fail;}; | |||
6506 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::say",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::say",2,"char const *",SWIG_Lua_typename(L,2)) ; goto fail;}; | |||
6507 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("CoreSession::say",3,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::say",3,"char const *",SWIG_Lua_typename(L,3)) ; goto fail;}; | |||
6508 | if(!SWIG_lua_isnilstring(L,4)) SWIG_fail_arg("CoreSession::say",4,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::say",4,"char const *",SWIG_Lua_typename(L,4)) ; goto fail;}; | |||
6509 | if(!SWIG_lua_isnilstring(L,5)) SWIG_fail_arg("CoreSession::say",5,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::say",5,"char const *",SWIG_Lua_typename(L,5)) ; goto fail;}; | |||
6510 | if(lua_gettop(L)>=6 && !SWIG_lua_isnilstring(L,6)) SWIG_fail_arg("CoreSession::say",6,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::say",6,"char const *",SWIG_Lua_typename(L,6)) ; goto fail;}; | |||
6511 | ||||
6512 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6513 | SWIG_fail_ptr("CoreSession_say",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_say",1,(swig_types[1] && swig_types[1] ->str)?swig_types[1]->str:"void*",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
6514 | } | |||
6515 | ||||
6516 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
6517 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
6518 | arg4 = (char *)lua_tostring(L, 4)lua_tolstring(L, (4), __null); | |||
6519 | arg5 = (char *)lua_tostring(L, 5)lua_tolstring(L, (5), __null); | |||
6520 | if(lua_gettop(L)>=6){ | |||
6521 | arg6 = (char *)lua_tostring(L, 6)lua_tolstring(L, (6), __null); | |||
6522 | } | |||
6523 | (arg1)->say((char const *)arg2,(char const *)arg3,(char const *)arg4,(char const *)arg5,(char const *)arg6); | |||
6524 | ||||
6525 | return SWIG_arg; | |||
6526 | ||||
6527 | if(0) SWIG_fail{goto fail;}; | |||
6528 | ||||
6529 | fail: | |||
6530 | lua_error(L); | |||
6531 | return SWIG_arg; | |||
6532 | } | |||
6533 | ||||
6534 | ||||
6535 | static int _wrap_CoreSession_sayPhrase(lua_State* L) { | |||
6536 | int SWIG_arg = 0; | |||
6537 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6538 | char *arg2 = (char *) 0 ; | |||
6539 | char *arg3 = (char *) "" ; | |||
6540 | char *arg4 = (char *) NULL__null ; | |||
6541 | ||||
6542 | SWIG_check_num_args("CoreSession::sayPhrase",2,4)if (lua_gettop(L)<2 || lua_gettop(L)>4) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::sayPhrase" ,2,4,lua_gettop(L)); goto fail;} | |||
6543 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::sayPhrase",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::sayPhrase",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6544 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::sayPhrase",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::sayPhrase",2,"char const *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
6545 | if(lua_gettop(L)>=3 && !SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("CoreSession::sayPhrase",3,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::sayPhrase",3,"char const *",SWIG_Lua_typename (L,3)); goto fail;}; | |||
6546 | if(lua_gettop(L)>=4 && !SWIG_lua_isnilstring(L,4)) SWIG_fail_arg("CoreSession::sayPhrase",4,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::sayPhrase",4,"char const *",SWIG_Lua_typename (L,4)); goto fail;}; | |||
6547 | ||||
6548 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6549 | SWIG_fail_ptr("CoreSession_sayPhrase",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_sayPhrase",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6550 | } | |||
6551 | ||||
6552 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
6553 | if(lua_gettop(L)>=3){ | |||
6554 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
6555 | } | |||
6556 | if(lua_gettop(L)>=4){ | |||
6557 | arg4 = (char *)lua_tostring(L, 4)lua_tolstring(L, (4), __null); | |||
6558 | } | |||
6559 | (arg1)->sayPhrase((char const *)arg2,(char const *)arg3,(char const *)arg4); | |||
6560 | ||||
6561 | return SWIG_arg; | |||
6562 | ||||
6563 | if(0) SWIG_fail{goto fail;}; | |||
6564 | ||||
6565 | fail: | |||
6566 | lua_error(L); | |||
6567 | return SWIG_arg; | |||
6568 | } | |||
6569 | ||||
6570 | ||||
6571 | static int _wrap_CoreSession_hangupCause(lua_State* L) { | |||
6572 | int SWIG_arg = 0; | |||
6573 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6574 | char *result = 0 ; | |||
6575 | ||||
6576 | SWIG_check_num_args("CoreSession::hangupCause",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::hangupCause" ,1,1,lua_gettop(L)); goto fail;} | |||
6577 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::hangupCause",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::hangupCause",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6578 | ||||
6579 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6580 | SWIG_fail_ptr("CoreSession_hangupCause",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_hangupCause",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6581 | } | |||
6582 | ||||
6583 | result = (char *)(arg1)->hangupCause(); | |||
6584 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
6585 | return SWIG_arg; | |||
6586 | ||||
6587 | if(0) SWIG_fail{goto fail;}; | |||
6588 | ||||
6589 | fail: | |||
6590 | lua_error(L); | |||
6591 | return SWIG_arg; | |||
6592 | } | |||
6593 | ||||
6594 | ||||
6595 | static int _wrap_CoreSession_getState(lua_State* L) { | |||
6596 | int SWIG_arg = 0; | |||
6597 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6598 | char *result = 0 ; | |||
6599 | ||||
6600 | SWIG_check_num_args("CoreSession::getState",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::getState" ,1,1,lua_gettop(L)); goto fail;} | |||
6601 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::getState",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getState",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6602 | ||||
6603 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6604 | SWIG_fail_ptr("CoreSession_getState",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_getState",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6605 | } | |||
6606 | ||||
6607 | result = (char *)(arg1)->getState(); | |||
6608 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
6609 | return SWIG_arg; | |||
6610 | ||||
6611 | if(0) SWIG_fail{goto fail;}; | |||
6612 | ||||
6613 | fail: | |||
6614 | lua_error(L); | |||
6615 | return SWIG_arg; | |||
6616 | } | |||
6617 | ||||
6618 | ||||
6619 | static int _wrap_CoreSession_recordFile(lua_State* L) { | |||
6620 | int SWIG_arg = 0; | |||
6621 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6622 | char *arg2 = (char *) 0 ; | |||
6623 | int arg3 = (int) 0 ; | |||
6624 | int arg4 = (int) 0 ; | |||
6625 | int arg5 = (int) 0 ; | |||
6626 | int result; | |||
6627 | ||||
6628 | SWIG_check_num_args("CoreSession::recordFile",2,5)if (lua_gettop(L)<2 || lua_gettop(L)>5) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::recordFile" ,2,5,lua_gettop(L)); goto fail;} | |||
6629 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::recordFile",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::recordFile",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6630 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::recordFile",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::recordFile",2,"char *",SWIG_Lua_typename(L,2) ); goto fail;}; | |||
6631 | if(lua_gettop(L)>=3 && !lua_isnumber(L,3)) SWIG_fail_arg("CoreSession::recordFile",3,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::recordFile",3,"int",SWIG_Lua_typename(L,3)); goto fail;}; | |||
6632 | if(lua_gettop(L)>=4 && !lua_isnumber(L,4)) SWIG_fail_arg("CoreSession::recordFile",4,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::recordFile",4,"int",SWIG_Lua_typename(L,4)); goto fail;}; | |||
6633 | if(lua_gettop(L)>=5 && !lua_isnumber(L,5)) SWIG_fail_arg("CoreSession::recordFile",5,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::recordFile",5,"int",SWIG_Lua_typename(L,5)); goto fail;}; | |||
6634 | ||||
6635 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6636 | SWIG_fail_ptr("CoreSession_recordFile",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_recordFile",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6637 | } | |||
6638 | ||||
6639 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
6640 | if(lua_gettop(L)>=3){ | |||
6641 | arg3 = (int)lua_tonumber(L, 3)lua_tonumberx(L,3,__null); | |||
6642 | } | |||
6643 | if(lua_gettop(L)>=4){ | |||
6644 | arg4 = (int)lua_tonumber(L, 4)lua_tonumberx(L,4,__null); | |||
6645 | } | |||
6646 | if(lua_gettop(L)>=5){ | |||
6647 | arg5 = (int)lua_tonumber(L, 5)lua_tonumberx(L,5,__null); | |||
6648 | } | |||
6649 | result = (int)(arg1)->recordFile(arg2,arg3,arg4,arg5); | |||
6650 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
6651 | return SWIG_arg; | |||
6652 | ||||
6653 | if(0) SWIG_fail{goto fail;}; | |||
6654 | ||||
6655 | fail: | |||
6656 | lua_error(L); | |||
6657 | return SWIG_arg; | |||
6658 | } | |||
6659 | ||||
6660 | ||||
6661 | static int _wrap_CoreSession_originate(lua_State* L) { | |||
6662 | int SWIG_arg = 0; | |||
6663 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6664 | CoreSession *arg2 = (CoreSession *) 0 ; | |||
6665 | char *arg3 = (char *) 0 ; | |||
6666 | int arg4 = (int) 60 ; | |||
6667 | switch_state_handler_table_t *arg5 = (switch_state_handler_table_t *) NULL__null ; | |||
6668 | int result; | |||
6669 | ||||
6670 | SWIG_check_num_args("CoreSession::originate",3,5)if (lua_gettop(L)<3 || lua_gettop(L)>5) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::originate" ,3,5,lua_gettop(L)); goto fail;} | |||
6671 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::originate",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::originate",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6672 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("CoreSession::originate",2,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::originate",2,"CoreSession *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
6673 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("CoreSession::originate",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::originate",3,"char *",SWIG_Lua_typename(L,3)) ; goto fail;}; | |||
6674 | if(lua_gettop(L)>=4 && !lua_isnumber(L,4)) SWIG_fail_arg("CoreSession::originate",4,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::originate",4,"int",SWIG_Lua_typename(L,4)); goto fail;}; | |||
6675 | if(lua_gettop(L)>=5 && !SWIG_isptrtype(L,5)(lua_isuserdata(L,5) || (lua_type(L, (5)) == 0))) SWIG_fail_arg("CoreSession::originate",5,"switch_state_handler_table_t *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::originate",5,"switch_state_handler_table_t *" ,SWIG_Lua_typename(L,5)); goto fail;}; | |||
6676 | ||||
6677 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6678 | SWIG_fail_ptr("CoreSession_originate",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_originate",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6679 | } | |||
6680 | ||||
6681 | ||||
6682 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&arg2,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&arg2,swig_types[1],0) >= 0)){ | |||
6683 | SWIG_fail_ptr("CoreSession_originate",2,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_originate",2,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,2)); goto fail;}; | |||
6684 | } | |||
6685 | ||||
6686 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
6687 | if(lua_gettop(L)>=4){ | |||
6688 | arg4 = (int)lua_tonumber(L, 4)lua_tonumberx(L,4,__null); | |||
6689 | } | |||
6690 | if(lua_gettop(L)>=5){ | |||
6691 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,5,(void**)&arg5,SWIGTYPE_p_switch_state_handler_table_t,0))(SWIG_Lua_ConvertPtr(L,5,(void**)&arg5,swig_types[27],0) >= 0)){ | |||
6692 | SWIG_fail_ptr("CoreSession_originate",5,SWIGTYPE_p_switch_state_handler_table_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_originate",5,(swig_types[27] && swig_types [27]->str)?swig_types[27]->str:"void*",SWIG_Lua_typename (L,5)); goto fail;}; | |||
6693 | } | |||
6694 | } | |||
6695 | result = (int)(arg1)->originate(arg2,arg3,arg4,arg5); | |||
6696 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
6697 | return SWIG_arg; | |||
6698 | ||||
6699 | if(0) SWIG_fail{goto fail;}; | |||
6700 | ||||
6701 | fail: | |||
6702 | lua_error(L); | |||
6703 | return SWIG_arg; | |||
6704 | } | |||
6705 | ||||
6706 | ||||
6707 | static int _wrap_CoreSession_destroy(lua_State* L) { | |||
6708 | int SWIG_arg = 0; | |||
6709 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6710 | ||||
6711 | SWIG_check_num_args("CoreSession::destroy",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::destroy" ,1,1,lua_gettop(L)); goto fail;} | |||
6712 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::destroy",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::destroy",1,"CoreSession *",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6713 | ||||
6714 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6715 | SWIG_fail_ptr("CoreSession_destroy",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_destroy",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6716 | } | |||
6717 | ||||
6718 | (arg1)->destroy(); | |||
6719 | ||||
6720 | return SWIG_arg; | |||
6721 | ||||
6722 | if(0) SWIG_fail{goto fail;}; | |||
6723 | ||||
6724 | fail: | |||
6725 | lua_error(L); | |||
6726 | return SWIG_arg; | |||
6727 | } | |||
6728 | ||||
6729 | ||||
6730 | static int _wrap_CoreSession_setDTMFCallback(lua_State* L) { | |||
6731 | int SWIG_arg = 0; | |||
6732 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6733 | void *arg2 = (void *) 0 ; | |||
6734 | char *arg3 = (char *) 0 ; | |||
6735 | ||||
6736 | SWIG_check_num_args("CoreSession::setDTMFCallback",3,3)if (lua_gettop(L)<3 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::setDTMFCallback" ,3,3,lua_gettop(L)); goto fail;} | |||
6737 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::setDTMFCallback",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::setDTMFCallback",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6738 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("CoreSession::setDTMFCallback",2,"void *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::setDTMFCallback",2,"void *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
6739 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("CoreSession::setDTMFCallback",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::setDTMFCallback",3,"char *",SWIG_Lua_typename (L,3)); goto fail;}; | |||
6740 | ||||
6741 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6742 | SWIG_fail_ptr("CoreSession_setDTMFCallback",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_setDTMFCallback",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6743 | } | |||
6744 | ||||
6745 | arg2=(void *)SWIG_MustGetPtr(L,2,0,0,2,"CoreSession_setDTMFCallback")SWIG_Lua_MustGetPtr(L,2, 0,0, 2,"CoreSession_setDTMFCallback" ); | |||
6746 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
6747 | (arg1)->setDTMFCallback(arg2,arg3); | |||
6748 | ||||
6749 | return SWIG_arg; | |||
6750 | ||||
6751 | if(0) SWIG_fail{goto fail;}; | |||
6752 | ||||
6753 | fail: | |||
6754 | lua_error(L); | |||
6755 | return SWIG_arg; | |||
6756 | } | |||
6757 | ||||
6758 | ||||
6759 | static int _wrap_CoreSession_speak(lua_State* L) { | |||
6760 | int SWIG_arg = 0; | |||
6761 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6762 | char *arg2 = (char *) 0 ; | |||
6763 | int result; | |||
6764 | ||||
6765 | SWIG_check_num_args("CoreSession::speak",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::speak" ,2,2,lua_gettop(L)); goto fail;} | |||
6766 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::speak",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::speak",1,"CoreSession *",SWIG_Lua_typename(L, 1)); goto fail;}; | |||
6767 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::speak",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::speak",2,"char *",SWIG_Lua_typename(L,2)); goto fail;}; | |||
6768 | ||||
6769 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6770 | SWIG_fail_ptr("CoreSession_speak",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_speak",1,(swig_types[1] && swig_types[ 1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
6771 | } | |||
6772 | ||||
6773 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
6774 | result = (int)(arg1)->speak(arg2); | |||
6775 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
6776 | return SWIG_arg; | |||
6777 | ||||
6778 | if(0) SWIG_fail{goto fail;}; | |||
6779 | ||||
6780 | fail: | |||
6781 | lua_error(L); | |||
6782 | return SWIG_arg; | |||
6783 | } | |||
6784 | ||||
6785 | ||||
6786 | static int _wrap_CoreSession_set_tts_parms(lua_State* L) { | |||
6787 | int SWIG_arg = 0; | |||
6788 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6789 | char *arg2 = (char *) 0 ; | |||
6790 | char *arg3 = (char *) 0 ; | |||
6791 | ||||
6792 | SWIG_check_num_args("CoreSession::set_tts_parms",3,3)if (lua_gettop(L)<3 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::set_tts_parms" ,3,3,lua_gettop(L)); goto fail;} | |||
6793 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::set_tts_parms",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::set_tts_parms",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6794 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::set_tts_parms",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::set_tts_parms",2,"char *",SWIG_Lua_typename(L ,2)); goto fail;}; | |||
6795 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("CoreSession::set_tts_parms",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::set_tts_parms",3,"char *",SWIG_Lua_typename(L ,3)); goto fail;}; | |||
6796 | ||||
6797 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6798 | SWIG_fail_ptr("CoreSession_set_tts_parms",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_set_tts_parms",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6799 | } | |||
6800 | ||||
6801 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
6802 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
6803 | (arg1)->set_tts_parms(arg2,arg3); | |||
6804 | ||||
6805 | return SWIG_arg; | |||
6806 | ||||
6807 | if(0) SWIG_fail{goto fail;}; | |||
6808 | ||||
6809 | fail: | |||
6810 | lua_error(L); | |||
6811 | return SWIG_arg; | |||
6812 | } | |||
6813 | ||||
6814 | ||||
6815 | static int _wrap_CoreSession_set_tts_params(lua_State* L) { | |||
6816 | int SWIG_arg = 0; | |||
6817 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6818 | char *arg2 = (char *) 0 ; | |||
6819 | char *arg3 = (char *) 0 ; | |||
6820 | ||||
6821 | SWIG_check_num_args("CoreSession::set_tts_params",3,3)if (lua_gettop(L)<3 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::set_tts_params" ,3,3,lua_gettop(L)); goto fail;} | |||
6822 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::set_tts_params",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::set_tts_params",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6823 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::set_tts_params",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::set_tts_params",2,"char *",SWIG_Lua_typename( L,2)); goto fail;}; | |||
6824 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("CoreSession::set_tts_params",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::set_tts_params",3,"char *",SWIG_Lua_typename( L,3)); goto fail;}; | |||
6825 | ||||
6826 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6827 | SWIG_fail_ptr("CoreSession_set_tts_params",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_set_tts_params",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6828 | } | |||
6829 | ||||
6830 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
6831 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
6832 | (arg1)->set_tts_params(arg2,arg3); | |||
6833 | ||||
6834 | return SWIG_arg; | |||
6835 | ||||
6836 | if(0) SWIG_fail{goto fail;}; | |||
6837 | ||||
6838 | fail: | |||
6839 | lua_error(L); | |||
6840 | return SWIG_arg; | |||
6841 | } | |||
6842 | ||||
6843 | ||||
6844 | static int _wrap_CoreSession_collectDigits__SWIG_0(lua_State* L) { | |||
6845 | int SWIG_arg = 0; | |||
6846 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6847 | int arg2 ; | |||
6848 | int result; | |||
6849 | ||||
6850 | SWIG_check_num_args("CoreSession::collectDigits",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::collectDigits" ,2,2,lua_gettop(L)); goto fail;} | |||
6851 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::collectDigits",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::collectDigits",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6852 | if(!lua_isnumber(L,2)) SWIG_fail_arg("CoreSession::collectDigits",2,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::collectDigits",2,"int",SWIG_Lua_typename(L,2) ); goto fail;}; | |||
6853 | ||||
6854 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6855 | SWIG_fail_ptr("CoreSession_collectDigits",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_collectDigits",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6856 | } | |||
6857 | ||||
6858 | arg2 = (int)lua_tonumber(L, 2)lua_tonumberx(L,2,__null); | |||
6859 | result = (int)(arg1)->collectDigits(arg2); | |||
6860 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
6861 | return SWIG_arg; | |||
6862 | ||||
6863 | if(0) SWIG_fail{goto fail;}; | |||
6864 | ||||
6865 | fail: | |||
6866 | lua_error(L); | |||
6867 | return SWIG_arg; | |||
6868 | } | |||
6869 | ||||
6870 | ||||
6871 | static int _wrap_CoreSession_collectDigits__SWIG_1(lua_State* L) { | |||
6872 | int SWIG_arg = 0; | |||
6873 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6874 | int arg2 ; | |||
6875 | int arg3 ; | |||
6876 | int result; | |||
6877 | ||||
6878 | SWIG_check_num_args("CoreSession::collectDigits",3,3)if (lua_gettop(L)<3 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::collectDigits" ,3,3,lua_gettop(L)); goto fail;} | |||
6879 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::collectDigits",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::collectDigits",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6880 | if(!lua_isnumber(L,2)) SWIG_fail_arg("CoreSession::collectDigits",2,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::collectDigits",2,"int",SWIG_Lua_typename(L,2) ); goto fail;}; | |||
6881 | if(!lua_isnumber(L,3)) SWIG_fail_arg("CoreSession::collectDigits",3,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::collectDigits",3,"int",SWIG_Lua_typename(L,3) ); goto fail;}; | |||
6882 | ||||
6883 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6884 | SWIG_fail_ptr("CoreSession_collectDigits",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_collectDigits",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6885 | } | |||
6886 | ||||
6887 | arg2 = (int)lua_tonumber(L, 2)lua_tonumberx(L,2,__null); | |||
6888 | arg3 = (int)lua_tonumber(L, 3)lua_tonumberx(L,3,__null); | |||
6889 | result = (int)(arg1)->collectDigits(arg2,arg3); | |||
6890 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
6891 | return SWIG_arg; | |||
6892 | ||||
6893 | if(0) SWIG_fail{goto fail;}; | |||
6894 | ||||
6895 | fail: | |||
6896 | lua_error(L); | |||
6897 | return SWIG_arg; | |||
6898 | } | |||
6899 | ||||
6900 | ||||
6901 | static int _wrap_CoreSession_collectDigits(lua_State* L) { | |||
6902 | int argc; | |||
6903 | int argv[4]={ | |||
6904 | 1,2,3,4 | |||
6905 | }; | |||
6906 | ||||
6907 | argc = lua_gettop(L); | |||
6908 | if (argc == 2) { | |||
6909 | int _v; | |||
6910 | { | |||
6911 | void *ptr; | |||
6912 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_CoreSession, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[1 ],0)) { | |||
6913 | _v = 0; | |||
6914 | } else { | |||
6915 | _v = 1; | |||
6916 | } | |||
6917 | } | |||
6918 | if (_v) { | |||
6919 | { | |||
6920 | _v = lua_isnumber(L,argv[1]); | |||
6921 | } | |||
6922 | if (_v) { | |||
6923 | return _wrap_CoreSession_collectDigits__SWIG_0(L); | |||
6924 | } | |||
6925 | } | |||
6926 | } | |||
6927 | if (argc == 3) { | |||
6928 | int _v; | |||
6929 | { | |||
6930 | void *ptr; | |||
6931 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_CoreSession, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[1 ],0)) { | |||
6932 | _v = 0; | |||
6933 | } else { | |||
6934 | _v = 1; | |||
6935 | } | |||
6936 | } | |||
6937 | if (_v) { | |||
6938 | { | |||
6939 | _v = lua_isnumber(L,argv[1]); | |||
6940 | } | |||
6941 | if (_v) { | |||
6942 | { | |||
6943 | _v = lua_isnumber(L,argv[2]); | |||
6944 | } | |||
6945 | if (_v) { | |||
6946 | return _wrap_CoreSession_collectDigits__SWIG_1(L); | |||
6947 | } | |||
6948 | } | |||
6949 | } | |||
6950 | } | |||
6951 | ||||
6952 | SWIG_Lua_pusherrstring(L,"Wrong arguments for overloaded function 'CoreSession_collectDigits'\n" | |||
6953 | " Possible C/C++ prototypes are:\n" | |||
6954 | " CoreSession::collectDigits(int)\n" | |||
6955 | " CoreSession::collectDigits(int,int)\n"); | |||
6956 | lua_error(L);return 0; | |||
6957 | } | |||
6958 | ||||
6959 | ||||
6960 | static int _wrap_CoreSession_getDigits__SWIG_0(lua_State* L) { | |||
6961 | int SWIG_arg = 0; | |||
6962 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6963 | int arg2 ; | |||
6964 | char *arg3 = (char *) 0 ; | |||
6965 | int arg4 ; | |||
6966 | char *result = 0 ; | |||
6967 | ||||
6968 | SWIG_check_num_args("CoreSession::getDigits",4,4)if (lua_gettop(L)<4 || lua_gettop(L)>4) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::getDigits" ,4,4,lua_gettop(L)); goto fail;} | |||
6969 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::getDigits",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getDigits",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
6970 | if(!lua_isnumber(L,2)) SWIG_fail_arg("CoreSession::getDigits",2,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getDigits",2,"int",SWIG_Lua_typename(L,2)); goto fail;}; | |||
6971 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("CoreSession::getDigits",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getDigits",3,"char *",SWIG_Lua_typename(L,3)) ; goto fail;}; | |||
6972 | if(!lua_isnumber(L,4)) SWIG_fail_arg("CoreSession::getDigits",4,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getDigits",4,"int",SWIG_Lua_typename(L,4)); goto fail;}; | |||
6973 | ||||
6974 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
6975 | SWIG_fail_ptr("CoreSession_getDigits",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_getDigits",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
6976 | } | |||
6977 | ||||
6978 | arg2 = (int)lua_tonumber(L, 2)lua_tonumberx(L,2,__null); | |||
6979 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
6980 | arg4 = (int)lua_tonumber(L, 4)lua_tonumberx(L,4,__null); | |||
6981 | result = (char *)(arg1)->getDigits(arg2,arg3,arg4); | |||
6982 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
6983 | return SWIG_arg; | |||
6984 | ||||
6985 | if(0) SWIG_fail{goto fail;}; | |||
6986 | ||||
6987 | fail: | |||
6988 | lua_error(L); | |||
6989 | return SWIG_arg; | |||
6990 | } | |||
6991 | ||||
6992 | ||||
6993 | static int _wrap_CoreSession_getDigits__SWIG_1(lua_State* L) { | |||
6994 | int SWIG_arg = 0; | |||
6995 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
6996 | int arg2 ; | |||
6997 | char *arg3 = (char *) 0 ; | |||
6998 | int arg4 ; | |||
6999 | int arg5 ; | |||
7000 | char *result = 0 ; | |||
7001 | ||||
7002 | SWIG_check_num_args("CoreSession::getDigits",5,5)if (lua_gettop(L)<5 || lua_gettop(L)>5) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::getDigits" ,5,5,lua_gettop(L)); goto fail;} | |||
7003 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::getDigits",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getDigits",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7004 | if(!lua_isnumber(L,2)) SWIG_fail_arg("CoreSession::getDigits",2,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getDigits",2,"int",SWIG_Lua_typename(L,2)); goto fail;}; | |||
7005 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("CoreSession::getDigits",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getDigits",3,"char *",SWIG_Lua_typename(L,3)) ; goto fail;}; | |||
7006 | if(!lua_isnumber(L,4)) SWIG_fail_arg("CoreSession::getDigits",4,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getDigits",4,"int",SWIG_Lua_typename(L,4)); goto fail;}; | |||
7007 | if(!lua_isnumber(L,5)) SWIG_fail_arg("CoreSession::getDigits",5,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getDigits",5,"int",SWIG_Lua_typename(L,5)); goto fail;}; | |||
7008 | ||||
7009 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7010 | SWIG_fail_ptr("CoreSession_getDigits",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_getDigits",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7011 | } | |||
7012 | ||||
7013 | arg2 = (int)lua_tonumber(L, 2)lua_tonumberx(L,2,__null); | |||
7014 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
7015 | arg4 = (int)lua_tonumber(L, 4)lua_tonumberx(L,4,__null); | |||
7016 | arg5 = (int)lua_tonumber(L, 5)lua_tonumberx(L,5,__null); | |||
7017 | result = (char *)(arg1)->getDigits(arg2,arg3,arg4,arg5); | |||
7018 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
7019 | return SWIG_arg; | |||
7020 | ||||
7021 | if(0) SWIG_fail{goto fail;}; | |||
7022 | ||||
7023 | fail: | |||
7024 | lua_error(L); | |||
7025 | return SWIG_arg; | |||
7026 | } | |||
7027 | ||||
7028 | ||||
7029 | static int _wrap_CoreSession_getDigits__SWIG_2(lua_State* L) { | |||
7030 | int SWIG_arg = 0; | |||
7031 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7032 | int arg2 ; | |||
7033 | char *arg3 = (char *) 0 ; | |||
7034 | int arg4 ; | |||
7035 | int arg5 ; | |||
7036 | int arg6 ; | |||
7037 | char *result = 0 ; | |||
7038 | ||||
7039 | SWIG_check_num_args("CoreSession::getDigits",6,6)if (lua_gettop(L)<6 || lua_gettop(L)>6) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::getDigits" ,6,6,lua_gettop(L)); goto fail;} | |||
7040 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::getDigits",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getDigits",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7041 | if(!lua_isnumber(L,2)) SWIG_fail_arg("CoreSession::getDigits",2,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getDigits",2,"int",SWIG_Lua_typename(L,2)); goto fail;}; | |||
7042 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("CoreSession::getDigits",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getDigits",3,"char *",SWIG_Lua_typename(L,3)) ; goto fail;}; | |||
7043 | if(!lua_isnumber(L,4)) SWIG_fail_arg("CoreSession::getDigits",4,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getDigits",4,"int",SWIG_Lua_typename(L,4)); goto fail;}; | |||
7044 | if(!lua_isnumber(L,5)) SWIG_fail_arg("CoreSession::getDigits",5,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getDigits",5,"int",SWIG_Lua_typename(L,5)); goto fail;}; | |||
7045 | if(!lua_isnumber(L,6)) SWIG_fail_arg("CoreSession::getDigits",6,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getDigits",6,"int",SWIG_Lua_typename(L,6)); goto fail;}; | |||
7046 | ||||
7047 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7048 | SWIG_fail_ptr("CoreSession_getDigits",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_getDigits",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7049 | } | |||
7050 | ||||
7051 | arg2 = (int)lua_tonumber(L, 2)lua_tonumberx(L,2,__null); | |||
7052 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
7053 | arg4 = (int)lua_tonumber(L, 4)lua_tonumberx(L,4,__null); | |||
7054 | arg5 = (int)lua_tonumber(L, 5)lua_tonumberx(L,5,__null); | |||
7055 | arg6 = (int)lua_tonumber(L, 6)lua_tonumberx(L,6,__null); | |||
7056 | result = (char *)(arg1)->getDigits(arg2,arg3,arg4,arg5,arg6); | |||
7057 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
7058 | return SWIG_arg; | |||
7059 | ||||
7060 | if(0) SWIG_fail{goto fail;}; | |||
7061 | ||||
7062 | fail: | |||
7063 | lua_error(L); | |||
7064 | return SWIG_arg; | |||
7065 | } | |||
7066 | ||||
7067 | ||||
7068 | static int _wrap_CoreSession_getDigits(lua_State* L) { | |||
7069 | int argc; | |||
7070 | int argv[7]={ | |||
7071 | 1,2,3,4,5,6,7 | |||
7072 | }; | |||
7073 | ||||
7074 | argc = lua_gettop(L); | |||
7075 | if (argc == 4) { | |||
7076 | int _v; | |||
7077 | { | |||
7078 | void *ptr; | |||
7079 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_CoreSession, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[1 ],0)) { | |||
7080 | _v = 0; | |||
7081 | } else { | |||
7082 | _v = 1; | |||
7083 | } | |||
7084 | } | |||
7085 | if (_v) { | |||
7086 | { | |||
7087 | _v = lua_isnumber(L,argv[1]); | |||
7088 | } | |||
7089 | if (_v) { | |||
7090 | { | |||
7091 | _v = SWIG_lua_isnilstring(L,argv[2]); | |||
7092 | } | |||
7093 | if (_v) { | |||
7094 | { | |||
7095 | _v = lua_isnumber(L,argv[3]); | |||
7096 | } | |||
7097 | if (_v) { | |||
7098 | return _wrap_CoreSession_getDigits__SWIG_0(L); | |||
7099 | } | |||
7100 | } | |||
7101 | } | |||
7102 | } | |||
7103 | } | |||
7104 | if (argc == 5) { | |||
7105 | int _v; | |||
7106 | { | |||
7107 | void *ptr; | |||
7108 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_CoreSession, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[1 ],0)) { | |||
7109 | _v = 0; | |||
7110 | } else { | |||
7111 | _v = 1; | |||
7112 | } | |||
7113 | } | |||
7114 | if (_v) { | |||
7115 | { | |||
7116 | _v = lua_isnumber(L,argv[1]); | |||
7117 | } | |||
7118 | if (_v) { | |||
7119 | { | |||
7120 | _v = SWIG_lua_isnilstring(L,argv[2]); | |||
7121 | } | |||
7122 | if (_v) { | |||
7123 | { | |||
7124 | _v = lua_isnumber(L,argv[3]); | |||
7125 | } | |||
7126 | if (_v) { | |||
7127 | { | |||
7128 | _v = lua_isnumber(L,argv[4]); | |||
7129 | } | |||
7130 | if (_v) { | |||
7131 | return _wrap_CoreSession_getDigits__SWIG_1(L); | |||
7132 | } | |||
7133 | } | |||
7134 | } | |||
7135 | } | |||
7136 | } | |||
7137 | } | |||
7138 | if (argc == 6) { | |||
7139 | int _v; | |||
7140 | { | |||
7141 | void *ptr; | |||
7142 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_CoreSession, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[1 ],0)) { | |||
7143 | _v = 0; | |||
7144 | } else { | |||
7145 | _v = 1; | |||
7146 | } | |||
7147 | } | |||
7148 | if (_v) { | |||
7149 | { | |||
7150 | _v = lua_isnumber(L,argv[1]); | |||
7151 | } | |||
7152 | if (_v) { | |||
7153 | { | |||
7154 | _v = SWIG_lua_isnilstring(L,argv[2]); | |||
7155 | } | |||
7156 | if (_v) { | |||
7157 | { | |||
7158 | _v = lua_isnumber(L,argv[3]); | |||
7159 | } | |||
7160 | if (_v) { | |||
7161 | { | |||
7162 | _v = lua_isnumber(L,argv[4]); | |||
7163 | } | |||
7164 | if (_v) { | |||
7165 | { | |||
7166 | _v = lua_isnumber(L,argv[5]); | |||
7167 | } | |||
7168 | if (_v) { | |||
7169 | return _wrap_CoreSession_getDigits__SWIG_2(L); | |||
7170 | } | |||
7171 | } | |||
7172 | } | |||
7173 | } | |||
7174 | } | |||
7175 | } | |||
7176 | } | |||
7177 | ||||
7178 | SWIG_Lua_pusherrstring(L,"Wrong arguments for overloaded function 'CoreSession_getDigits'\n" | |||
7179 | " Possible C/C++ prototypes are:\n" | |||
7180 | " CoreSession::getDigits(int,char *,int)\n" | |||
7181 | " CoreSession::getDigits(int,char *,int,int)\n" | |||
7182 | " CoreSession::getDigits(int,char *,int,int,int)\n"); | |||
7183 | lua_error(L);return 0; | |||
7184 | } | |||
7185 | ||||
7186 | ||||
7187 | static int _wrap_CoreSession_transfer(lua_State* L) { | |||
7188 | int SWIG_arg = 0; | |||
7189 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7190 | char *arg2 = (char *) 0 ; | |||
7191 | char *arg3 = (char *) NULL__null ; | |||
7192 | char *arg4 = (char *) NULL__null ; | |||
7193 | int result; | |||
7194 | ||||
7195 | SWIG_check_num_args("CoreSession::transfer",2,4)if (lua_gettop(L)<2 || lua_gettop(L)>4) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::transfer" ,2,4,lua_gettop(L)); goto fail;} | |||
7196 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::transfer",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::transfer",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7197 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::transfer",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::transfer",2,"char *",SWIG_Lua_typename(L,2)); goto fail;}; | |||
7198 | if(lua_gettop(L)>=3 && !SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("CoreSession::transfer",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::transfer",3,"char *",SWIG_Lua_typename(L,3)); goto fail;}; | |||
7199 | if(lua_gettop(L)>=4 && !SWIG_lua_isnilstring(L,4)) SWIG_fail_arg("CoreSession::transfer",4,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::transfer",4,"char *",SWIG_Lua_typename(L,4)); goto fail;}; | |||
7200 | ||||
7201 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7202 | SWIG_fail_ptr("CoreSession_transfer",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_transfer",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7203 | } | |||
7204 | ||||
7205 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
7206 | if(lua_gettop(L)>=3){ | |||
7207 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
7208 | } | |||
7209 | if(lua_gettop(L)>=4){ | |||
7210 | arg4 = (char *)lua_tostring(L, 4)lua_tolstring(L, (4), __null); | |||
7211 | } | |||
7212 | result = (int)(arg1)->transfer(arg2,arg3,arg4); | |||
7213 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
7214 | return SWIG_arg; | |||
7215 | ||||
7216 | if(0) SWIG_fail{goto fail;}; | |||
7217 | ||||
7218 | fail: | |||
7219 | lua_error(L); | |||
7220 | return SWIG_arg; | |||
7221 | } | |||
7222 | ||||
7223 | ||||
7224 | static int _wrap_CoreSession_read(lua_State* L) { | |||
7225 | int SWIG_arg = 0; | |||
7226 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7227 | int arg2 ; | |||
7228 | int arg3 ; | |||
7229 | char *arg4 = (char *) 0 ; | |||
7230 | int arg5 ; | |||
7231 | char *arg6 = (char *) 0 ; | |||
7232 | int arg7 = (int) 0 ; | |||
7233 | char *result = 0 ; | |||
7234 | ||||
7235 | SWIG_check_num_args("CoreSession::read",6,7)if (lua_gettop(L)<6 || lua_gettop(L)>7) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::read" ,6,7,lua_gettop(L)); goto fail;} | |||
7236 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::read",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::read",1,"CoreSession *",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
7237 | if(!lua_isnumber(L,2)) SWIG_fail_arg("CoreSession::read",2,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::read",2,"int",SWIG_Lua_typename(L,2)); goto fail ;}; | |||
7238 | if(!lua_isnumber(L,3)) SWIG_fail_arg("CoreSession::read",3,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::read",3,"int",SWIG_Lua_typename(L,3)); goto fail ;}; | |||
7239 | if(!SWIG_lua_isnilstring(L,4)) SWIG_fail_arg("CoreSession::read",4,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::read",4,"char const *",SWIG_Lua_typename(L,4) ); goto fail;}; | |||
7240 | if(!lua_isnumber(L,5)) SWIG_fail_arg("CoreSession::read",5,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::read",5,"int",SWIG_Lua_typename(L,5)); goto fail ;}; | |||
7241 | if(!SWIG_lua_isnilstring(L,6)) SWIG_fail_arg("CoreSession::read",6,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::read",6,"char const *",SWIG_Lua_typename(L,6) ); goto fail;}; | |||
7242 | if(lua_gettop(L)>=7 && !lua_isnumber(L,7)) SWIG_fail_arg("CoreSession::read",7,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::read",7,"int",SWIG_Lua_typename(L,7)); goto fail ;}; | |||
7243 | ||||
7244 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7245 | SWIG_fail_ptr("CoreSession_read",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_read",1,(swig_types[1] && swig_types[1 ]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename(L, 1)); goto fail;}; | |||
7246 | } | |||
7247 | ||||
7248 | arg2 = (int)lua_tonumber(L, 2)lua_tonumberx(L,2,__null); | |||
7249 | arg3 = (int)lua_tonumber(L, 3)lua_tonumberx(L,3,__null); | |||
7250 | arg4 = (char *)lua_tostring(L, 4)lua_tolstring(L, (4), __null); | |||
7251 | arg5 = (int)lua_tonumber(L, 5)lua_tonumberx(L,5,__null); | |||
7252 | arg6 = (char *)lua_tostring(L, 6)lua_tolstring(L, (6), __null); | |||
7253 | if(lua_gettop(L)>=7){ | |||
7254 | arg7 = (int)lua_tonumber(L, 7)lua_tonumberx(L,7,__null); | |||
7255 | } | |||
7256 | result = (char *)(arg1)->read(arg2,arg3,(char const *)arg4,arg5,(char const *)arg6,arg7); | |||
7257 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
7258 | return SWIG_arg; | |||
7259 | ||||
7260 | if(0) SWIG_fail{goto fail;}; | |||
7261 | ||||
7262 | fail: | |||
7263 | lua_error(L); | |||
7264 | return SWIG_arg; | |||
7265 | } | |||
7266 | ||||
7267 | ||||
7268 | static int _wrap_CoreSession_detectSpeech(lua_State* L) { | |||
7269 | int SWIG_arg = 0; | |||
7270 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7271 | char *arg2 = (char *) 0 ; | |||
7272 | char *arg3 = (char *) NULL__null ; | |||
7273 | char *arg4 = (char *) NULL__null ; | |||
7274 | char *arg5 = (char *) NULL__null ; | |||
7275 | ||||
7276 | SWIG_check_num_args("CoreSession::detectSpeech",2,5)if (lua_gettop(L)<2 || lua_gettop(L)>5) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::detectSpeech" ,2,5,lua_gettop(L)); goto fail;} | |||
7277 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::detectSpeech",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::detectSpeech",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7278 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::detectSpeech",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::detectSpeech",2,"char *",SWIG_Lua_typename(L, 2)); goto fail;}; | |||
7279 | if(lua_gettop(L)>=3 && !SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("CoreSession::detectSpeech",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::detectSpeech",3,"char *",SWIG_Lua_typename(L, 3)); goto fail;}; | |||
7280 | if(lua_gettop(L)>=4 && !SWIG_lua_isnilstring(L,4)) SWIG_fail_arg("CoreSession::detectSpeech",4,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::detectSpeech",4,"char *",SWIG_Lua_typename(L, 4)); goto fail;}; | |||
7281 | if(lua_gettop(L)>=5 && !SWIG_lua_isnilstring(L,5)) SWIG_fail_arg("CoreSession::detectSpeech",5,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::detectSpeech",5,"char *",SWIG_Lua_typename(L, 5)); goto fail;}; | |||
7282 | ||||
7283 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7284 | SWIG_fail_ptr("CoreSession_detectSpeech",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_detectSpeech",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7285 | } | |||
7286 | ||||
7287 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
7288 | if(lua_gettop(L)>=3){ | |||
7289 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
7290 | } | |||
7291 | if(lua_gettop(L)>=4){ | |||
7292 | arg4 = (char *)lua_tostring(L, 4)lua_tolstring(L, (4), __null); | |||
7293 | } | |||
7294 | if(lua_gettop(L)>=5){ | |||
7295 | arg5 = (char *)lua_tostring(L, 5)lua_tolstring(L, (5), __null); | |||
7296 | } | |||
7297 | (arg1)->detectSpeech(arg2,arg3,arg4,arg5); | |||
7298 | ||||
7299 | return SWIG_arg; | |||
7300 | ||||
7301 | if(0) SWIG_fail{goto fail;}; | |||
7302 | ||||
7303 | fail: | |||
7304 | lua_error(L); | |||
7305 | return SWIG_arg; | |||
7306 | } | |||
7307 | ||||
7308 | ||||
7309 | static int _wrap_CoreSession_playAndGetDigits(lua_State* L) { | |||
7310 | int SWIG_arg = 0; | |||
7311 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7312 | int arg2 ; | |||
7313 | int arg3 ; | |||
7314 | int arg4 ; | |||
7315 | int arg5 ; | |||
7316 | char *arg6 = (char *) 0 ; | |||
7317 | char *arg7 = (char *) 0 ; | |||
7318 | char *arg8 = (char *) 0 ; | |||
7319 | char *arg9 = (char *) 0 ; | |||
7320 | char *arg10 = (char *) NULL__null ; | |||
7321 | int arg11 = (int) 0 ; | |||
7322 | char *arg12 = (char *) NULL__null ; | |||
7323 | char *result = 0 ; | |||
7324 | ||||
7325 | SWIG_check_num_args("CoreSession::playAndGetDigits",9,12)if (lua_gettop(L)<9 || lua_gettop(L)>12) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::playAndGetDigits" ,9,12,lua_gettop(L)); goto fail;} | |||
7326 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::playAndGetDigits",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::playAndGetDigits",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7327 | if(!lua_isnumber(L,2)) SWIG_fail_arg("CoreSession::playAndGetDigits",2,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::playAndGetDigits",2,"int",SWIG_Lua_typename(L ,2)); goto fail;}; | |||
7328 | if(!lua_isnumber(L,3)) SWIG_fail_arg("CoreSession::playAndGetDigits",3,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::playAndGetDigits",3,"int",SWIG_Lua_typename(L ,3)); goto fail;}; | |||
7329 | if(!lua_isnumber(L,4)) SWIG_fail_arg("CoreSession::playAndGetDigits",4,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::playAndGetDigits",4,"int",SWIG_Lua_typename(L ,4)); goto fail;}; | |||
7330 | if(!lua_isnumber(L,5)) SWIG_fail_arg("CoreSession::playAndGetDigits",5,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::playAndGetDigits",5,"int",SWIG_Lua_typename(L ,5)); goto fail;}; | |||
7331 | if(!SWIG_lua_isnilstring(L,6)) SWIG_fail_arg("CoreSession::playAndGetDigits",6,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::playAndGetDigits",6,"char *",SWIG_Lua_typename (L,6)); goto fail;}; | |||
7332 | if(!SWIG_lua_isnilstring(L,7)) SWIG_fail_arg("CoreSession::playAndGetDigits",7,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::playAndGetDigits",7,"char *",SWIG_Lua_typename (L,7)); goto fail;}; | |||
7333 | if(!SWIG_lua_isnilstring(L,8)) SWIG_fail_arg("CoreSession::playAndGetDigits",8,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::playAndGetDigits",8,"char *",SWIG_Lua_typename (L,8)); goto fail;}; | |||
7334 | if(!SWIG_lua_isnilstring(L,9)) SWIG_fail_arg("CoreSession::playAndGetDigits",9,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::playAndGetDigits",9,"char *",SWIG_Lua_typename (L,9)); goto fail;}; | |||
7335 | if(lua_gettop(L)>=10 && !SWIG_lua_isnilstring(L,10)) SWIG_fail_arg("CoreSession::playAndGetDigits",10,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::playAndGetDigits",10,"char const *",SWIG_Lua_typename (L,10)); goto fail;}; | |||
7336 | if(lua_gettop(L)>=11 && !lua_isnumber(L,11)) SWIG_fail_arg("CoreSession::playAndGetDigits",11,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::playAndGetDigits",11,"int",SWIG_Lua_typename( L,11)); goto fail;}; | |||
7337 | if(lua_gettop(L)>=12 && !SWIG_lua_isnilstring(L,12)) SWIG_fail_arg("CoreSession::playAndGetDigits",12,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::playAndGetDigits",12,"char const *",SWIG_Lua_typename (L,12)); goto fail;}; | |||
7338 | ||||
7339 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7340 | SWIG_fail_ptr("CoreSession_playAndGetDigits",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_playAndGetDigits",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7341 | } | |||
7342 | ||||
7343 | arg2 = (int)lua_tonumber(L, 2)lua_tonumberx(L,2,__null); | |||
7344 | arg3 = (int)lua_tonumber(L, 3)lua_tonumberx(L,3,__null); | |||
7345 | arg4 = (int)lua_tonumber(L, 4)lua_tonumberx(L,4,__null); | |||
7346 | arg5 = (int)lua_tonumber(L, 5)lua_tonumberx(L,5,__null); | |||
7347 | arg6 = (char *)lua_tostring(L, 6)lua_tolstring(L, (6), __null); | |||
7348 | arg7 = (char *)lua_tostring(L, 7)lua_tolstring(L, (7), __null); | |||
7349 | arg8 = (char *)lua_tostring(L, 8)lua_tolstring(L, (8), __null); | |||
7350 | arg9 = (char *)lua_tostring(L, 9)lua_tolstring(L, (9), __null); | |||
7351 | if(lua_gettop(L)>=10){ | |||
7352 | arg10 = (char *)lua_tostring(L, 10)lua_tolstring(L, (10), __null); | |||
7353 | } | |||
7354 | if(lua_gettop(L)>=11){ | |||
7355 | arg11 = (int)lua_tonumber(L, 11)lua_tonumberx(L,11,__null); | |||
7356 | } | |||
7357 | if(lua_gettop(L)>=12){ | |||
7358 | arg12 = (char *)lua_tostring(L, 12)lua_tolstring(L, (12), __null); | |||
7359 | } | |||
7360 | result = (char *)(arg1)->playAndGetDigits(arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,(char const *)arg10,arg11,(char const *)arg12); | |||
7361 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
7362 | return SWIG_arg; | |||
7363 | ||||
7364 | if(0) SWIG_fail{goto fail;}; | |||
7365 | ||||
7366 | fail: | |||
7367 | lua_error(L); | |||
7368 | return SWIG_arg; | |||
7369 | } | |||
7370 | ||||
7371 | ||||
7372 | static int _wrap_CoreSession_playAndDetectSpeech(lua_State* L) { | |||
7373 | int SWIG_arg = 0; | |||
7374 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7375 | char *arg2 = (char *) 0 ; | |||
7376 | char *arg3 = (char *) 0 ; | |||
7377 | char *arg4 = (char *) 0 ; | |||
7378 | char *result = 0 ; | |||
7379 | ||||
7380 | SWIG_check_num_args("CoreSession::playAndDetectSpeech",4,4)if (lua_gettop(L)<4 || lua_gettop(L)>4) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::playAndDetectSpeech" ,4,4,lua_gettop(L)); goto fail;} | |||
7381 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::playAndDetectSpeech",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::playAndDetectSpeech",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7382 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::playAndDetectSpeech",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::playAndDetectSpeech",2,"char *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
7383 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("CoreSession::playAndDetectSpeech",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::playAndDetectSpeech",3,"char *",SWIG_Lua_typename (L,3)); goto fail;}; | |||
7384 | if(!SWIG_lua_isnilstring(L,4)) SWIG_fail_arg("CoreSession::playAndDetectSpeech",4,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::playAndDetectSpeech",4,"char *",SWIG_Lua_typename (L,4)); goto fail;}; | |||
7385 | ||||
7386 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7387 | SWIG_fail_ptr("CoreSession_playAndDetectSpeech",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_playAndDetectSpeech",1,(swig_types[1] && swig_types[1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7388 | } | |||
7389 | ||||
7390 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
7391 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
7392 | arg4 = (char *)lua_tostring(L, 4)lua_tolstring(L, (4), __null); | |||
7393 | result = (char *)(arg1)->playAndDetectSpeech(arg2,arg3,arg4); | |||
7394 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
7395 | free(result); | |||
7396 | return SWIG_arg; | |||
7397 | ||||
7398 | if(0) SWIG_fail{goto fail;}; | |||
7399 | ||||
7400 | fail: | |||
7401 | lua_error(L); | |||
7402 | return SWIG_arg; | |||
7403 | } | |||
7404 | ||||
7405 | ||||
7406 | static int _wrap_CoreSession_streamFile(lua_State* L) { | |||
7407 | int SWIG_arg = 0; | |||
7408 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7409 | char *arg2 = (char *) 0 ; | |||
7410 | int arg3 = (int) 0 ; | |||
7411 | int result; | |||
7412 | ||||
7413 | SWIG_check_num_args("CoreSession::streamFile",2,3)if (lua_gettop(L)<2 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::streamFile" ,2,3,lua_gettop(L)); goto fail;} | |||
7414 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::streamFile",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::streamFile",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7415 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::streamFile",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::streamFile",2,"char *",SWIG_Lua_typename(L,2) ); goto fail;}; | |||
7416 | if(lua_gettop(L)>=3 && !lua_isnumber(L,3)) SWIG_fail_arg("CoreSession::streamFile",3,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::streamFile",3,"int",SWIG_Lua_typename(L,3)); goto fail;}; | |||
7417 | ||||
7418 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7419 | SWIG_fail_ptr("CoreSession_streamFile",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_streamFile",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7420 | } | |||
7421 | ||||
7422 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
7423 | if(lua_gettop(L)>=3){ | |||
7424 | arg3 = (int)lua_tonumber(L, 3)lua_tonumberx(L,3,__null); | |||
7425 | } | |||
7426 | result = (int)(arg1)->streamFile(arg2,arg3); | |||
7427 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
7428 | return SWIG_arg; | |||
7429 | ||||
7430 | if(0) SWIG_fail{goto fail;}; | |||
7431 | ||||
7432 | fail: | |||
7433 | lua_error(L); | |||
7434 | return SWIG_arg; | |||
7435 | } | |||
7436 | ||||
7437 | ||||
7438 | static int _wrap_CoreSession_sleep(lua_State* L) { | |||
7439 | int SWIG_arg = 0; | |||
7440 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7441 | int arg2 ; | |||
7442 | int arg3 = (int) 0 ; | |||
7443 | int result; | |||
7444 | ||||
7445 | SWIG_check_num_args("CoreSession::sleep",2,3)if (lua_gettop(L)<2 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::sleep" ,2,3,lua_gettop(L)); goto fail;} | |||
7446 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::sleep",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::sleep",1,"CoreSession *",SWIG_Lua_typename(L, 1)); goto fail;}; | |||
7447 | if(!lua_isnumber(L,2)) SWIG_fail_arg("CoreSession::sleep",2,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::sleep",2,"int",SWIG_Lua_typename(L,2)); goto fail ;}; | |||
7448 | if(lua_gettop(L)>=3 && !lua_isnumber(L,3)) SWIG_fail_arg("CoreSession::sleep",3,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::sleep",3,"int",SWIG_Lua_typename(L,3)); goto fail ;}; | |||
7449 | ||||
7450 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7451 | SWIG_fail_ptr("CoreSession_sleep",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_sleep",1,(swig_types[1] && swig_types[ 1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
7452 | } | |||
7453 | ||||
7454 | arg2 = (int)lua_tonumber(L, 2)lua_tonumberx(L,2,__null); | |||
7455 | if(lua_gettop(L)>=3){ | |||
7456 | arg3 = (int)lua_tonumber(L, 3)lua_tonumberx(L,3,__null); | |||
7457 | } | |||
7458 | result = (int)(arg1)->sleep(arg2,arg3); | |||
7459 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
7460 | return SWIG_arg; | |||
7461 | ||||
7462 | if(0) SWIG_fail{goto fail;}; | |||
7463 | ||||
7464 | fail: | |||
7465 | lua_error(L); | |||
7466 | return SWIG_arg; | |||
7467 | } | |||
7468 | ||||
7469 | ||||
7470 | static int _wrap_CoreSession_flushEvents(lua_State* L) { | |||
7471 | int SWIG_arg = 0; | |||
7472 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7473 | int result; | |||
7474 | ||||
7475 | SWIG_check_num_args("CoreSession::flushEvents",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::flushEvents" ,1,1,lua_gettop(L)); goto fail;} | |||
7476 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::flushEvents",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::flushEvents",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7477 | ||||
7478 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7479 | SWIG_fail_ptr("CoreSession_flushEvents",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_flushEvents",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7480 | } | |||
7481 | ||||
7482 | result = (int)(arg1)->flushEvents(); | |||
7483 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
7484 | return SWIG_arg; | |||
7485 | ||||
7486 | if(0) SWIG_fail{goto fail;}; | |||
7487 | ||||
7488 | fail: | |||
7489 | lua_error(L); | |||
7490 | return SWIG_arg; | |||
7491 | } | |||
7492 | ||||
7493 | ||||
7494 | static int _wrap_CoreSession_flushDigits(lua_State* L) { | |||
7495 | int SWIG_arg = 0; | |||
7496 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7497 | int result; | |||
7498 | ||||
7499 | SWIG_check_num_args("CoreSession::flushDigits",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::flushDigits" ,1,1,lua_gettop(L)); goto fail;} | |||
7500 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::flushDigits",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::flushDigits",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7501 | ||||
7502 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7503 | SWIG_fail_ptr("CoreSession_flushDigits",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_flushDigits",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7504 | } | |||
7505 | ||||
7506 | result = (int)(arg1)->flushDigits(); | |||
7507 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
7508 | return SWIG_arg; | |||
7509 | ||||
7510 | if(0) SWIG_fail{goto fail;}; | |||
7511 | ||||
7512 | fail: | |||
7513 | lua_error(L); | |||
7514 | return SWIG_arg; | |||
7515 | } | |||
7516 | ||||
7517 | ||||
7518 | static int _wrap_CoreSession_setAutoHangup(lua_State* L) { | |||
7519 | int SWIG_arg = 0; | |||
7520 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7521 | bool arg2 ; | |||
7522 | int result; | |||
7523 | ||||
7524 | SWIG_check_num_args("CoreSession::setAutoHangup",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::setAutoHangup" ,2,2,lua_gettop(L)); goto fail;} | |||
7525 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::setAutoHangup",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::setAutoHangup",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7526 | if(!lua_isboolean(L,2)(lua_type(L, (2)) == 1)) SWIG_fail_arg("CoreSession::setAutoHangup",2,"bool"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::setAutoHangup",2,"bool",SWIG_Lua_typename(L,2 )); goto fail;}; | |||
7527 | ||||
7528 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7529 | SWIG_fail_ptr("CoreSession_setAutoHangup",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_setAutoHangup",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7530 | } | |||
7531 | ||||
7532 | arg2 = (lua_toboolean(L, 2)!=0); | |||
7533 | result = (int)(arg1)->setAutoHangup(arg2); | |||
7534 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
7535 | return SWIG_arg; | |||
7536 | ||||
7537 | if(0) SWIG_fail{goto fail;}; | |||
7538 | ||||
7539 | fail: | |||
7540 | lua_error(L); | |||
7541 | return SWIG_arg; | |||
7542 | } | |||
7543 | ||||
7544 | ||||
7545 | static int _wrap_CoreSession_setHangupHook(lua_State* L) { | |||
7546 | int SWIG_arg = 0; | |||
7547 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7548 | void *arg2 = (void *) 0 ; | |||
7549 | ||||
7550 | SWIG_check_num_args("CoreSession::setHangupHook",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::setHangupHook" ,2,2,lua_gettop(L)); goto fail;} | |||
7551 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::setHangupHook",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::setHangupHook",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7552 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("CoreSession::setHangupHook",2,"void *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::setHangupHook",2,"void *",SWIG_Lua_typename(L ,2)); goto fail;}; | |||
7553 | ||||
7554 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7555 | SWIG_fail_ptr("CoreSession_setHangupHook",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_setHangupHook",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7556 | } | |||
7557 | ||||
7558 | arg2=(void *)SWIG_MustGetPtr(L,2,0,0,2,"CoreSession_setHangupHook")SWIG_Lua_MustGetPtr(L,2, 0,0, 2,"CoreSession_setHangupHook"); | |||
7559 | (arg1)->setHangupHook(arg2); | |||
7560 | ||||
7561 | return SWIG_arg; | |||
7562 | ||||
7563 | if(0) SWIG_fail{goto fail;}; | |||
7564 | ||||
7565 | fail: | |||
7566 | lua_error(L); | |||
7567 | return SWIG_arg; | |||
7568 | } | |||
7569 | ||||
7570 | ||||
7571 | static int _wrap_CoreSession_ready(lua_State* L) { | |||
7572 | int SWIG_arg = 0; | |||
7573 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7574 | bool result; | |||
7575 | ||||
7576 | SWIG_check_num_args("CoreSession::ready",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::ready" ,1,1,lua_gettop(L)); goto fail;} | |||
7577 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::ready",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::ready",1,"CoreSession *",SWIG_Lua_typename(L, 1)); goto fail;}; | |||
7578 | ||||
7579 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7580 | SWIG_fail_ptr("CoreSession_ready",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_ready",1,(swig_types[1] && swig_types[ 1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
7581 | } | |||
7582 | ||||
7583 | result = (bool)(arg1)->ready(); | |||
7584 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
7585 | return SWIG_arg; | |||
7586 | ||||
7587 | if(0) SWIG_fail{goto fail;}; | |||
7588 | ||||
7589 | fail: | |||
7590 | lua_error(L); | |||
7591 | return SWIG_arg; | |||
7592 | } | |||
7593 | ||||
7594 | ||||
7595 | static int _wrap_CoreSession_bridged(lua_State* L) { | |||
7596 | int SWIG_arg = 0; | |||
7597 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7598 | bool result; | |||
7599 | ||||
7600 | SWIG_check_num_args("CoreSession::bridged",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::bridged" ,1,1,lua_gettop(L)); goto fail;} | |||
7601 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::bridged",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::bridged",1,"CoreSession *",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7602 | ||||
7603 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7604 | SWIG_fail_ptr("CoreSession_bridged",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_bridged",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7605 | } | |||
7606 | ||||
7607 | result = (bool)(arg1)->bridged(); | |||
7608 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
7609 | return SWIG_arg; | |||
7610 | ||||
7611 | if(0) SWIG_fail{goto fail;}; | |||
7612 | ||||
7613 | fail: | |||
7614 | lua_error(L); | |||
7615 | return SWIG_arg; | |||
7616 | } | |||
7617 | ||||
7618 | ||||
7619 | static int _wrap_CoreSession_answered(lua_State* L) { | |||
7620 | int SWIG_arg = 0; | |||
7621 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7622 | bool result; | |||
7623 | ||||
7624 | SWIG_check_num_args("CoreSession::answered",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::answered" ,1,1,lua_gettop(L)); goto fail;} | |||
7625 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::answered",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::answered",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7626 | ||||
7627 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7628 | SWIG_fail_ptr("CoreSession_answered",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_answered",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7629 | } | |||
7630 | ||||
7631 | result = (bool)(arg1)->answered(); | |||
7632 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
7633 | return SWIG_arg; | |||
7634 | ||||
7635 | if(0) SWIG_fail{goto fail;}; | |||
7636 | ||||
7637 | fail: | |||
7638 | lua_error(L); | |||
7639 | return SWIG_arg; | |||
7640 | } | |||
7641 | ||||
7642 | ||||
7643 | static int _wrap_CoreSession_mediaReady(lua_State* L) { | |||
7644 | int SWIG_arg = 0; | |||
7645 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7646 | bool result; | |||
7647 | ||||
7648 | SWIG_check_num_args("CoreSession::mediaReady",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::mediaReady" ,1,1,lua_gettop(L)); goto fail;} | |||
7649 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::mediaReady",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::mediaReady",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7650 | ||||
7651 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7652 | SWIG_fail_ptr("CoreSession_mediaReady",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_mediaReady",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7653 | } | |||
7654 | ||||
7655 | result = (bool)(arg1)->mediaReady(); | |||
7656 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
7657 | return SWIG_arg; | |||
7658 | ||||
7659 | if(0) SWIG_fail{goto fail;}; | |||
7660 | ||||
7661 | fail: | |||
7662 | lua_error(L); | |||
7663 | return SWIG_arg; | |||
7664 | } | |||
7665 | ||||
7666 | ||||
7667 | static int _wrap_CoreSession_waitForAnswer(lua_State* L) { | |||
7668 | int SWIG_arg = 0; | |||
7669 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7670 | CoreSession *arg2 = (CoreSession *) 0 ; | |||
7671 | ||||
7672 | SWIG_check_num_args("CoreSession::waitForAnswer",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::waitForAnswer" ,2,2,lua_gettop(L)); goto fail;} | |||
7673 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::waitForAnswer",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::waitForAnswer",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7674 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("CoreSession::waitForAnswer",2,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::waitForAnswer",2,"CoreSession *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
7675 | ||||
7676 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7677 | SWIG_fail_ptr("CoreSession_waitForAnswer",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_waitForAnswer",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7678 | } | |||
7679 | ||||
7680 | ||||
7681 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&arg2,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&arg2,swig_types[1],0) >= 0)){ | |||
7682 | SWIG_fail_ptr("CoreSession_waitForAnswer",2,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_waitForAnswer",2,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,2)); goto fail;}; | |||
7683 | } | |||
7684 | ||||
7685 | (arg1)->waitForAnswer(arg2); | |||
7686 | ||||
7687 | return SWIG_arg; | |||
7688 | ||||
7689 | if(0) SWIG_fail{goto fail;}; | |||
7690 | ||||
7691 | fail: | |||
7692 | lua_error(L); | |||
7693 | return SWIG_arg; | |||
7694 | } | |||
7695 | ||||
7696 | ||||
7697 | static int _wrap_CoreSession_execute(lua_State* L) { | |||
7698 | int SWIG_arg = 0; | |||
7699 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7700 | char *arg2 = (char *) 0 ; | |||
7701 | char *arg3 = (char *) NULL__null ; | |||
7702 | ||||
7703 | SWIG_check_num_args("CoreSession::execute",2,3)if (lua_gettop(L)<2 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::execute" ,2,3,lua_gettop(L)); goto fail;} | |||
7704 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::execute",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::execute",1,"CoreSession *",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7705 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::execute",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::execute",2,"char const *",SWIG_Lua_typename(L ,2)); goto fail;}; | |||
7706 | if(lua_gettop(L)>=3 && !SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("CoreSession::execute",3,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::execute",3,"char const *",SWIG_Lua_typename(L ,3)); goto fail;}; | |||
7707 | ||||
7708 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7709 | SWIG_fail_ptr("CoreSession_execute",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_execute",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7710 | } | |||
7711 | ||||
7712 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
7713 | if(lua_gettop(L)>=3){ | |||
7714 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
7715 | } | |||
7716 | (arg1)->execute((char const *)arg2,(char const *)arg3); | |||
7717 | ||||
7718 | return SWIG_arg; | |||
7719 | ||||
7720 | if(0) SWIG_fail{goto fail;}; | |||
7721 | ||||
7722 | fail: | |||
7723 | lua_error(L); | |||
7724 | return SWIG_arg; | |||
7725 | } | |||
7726 | ||||
7727 | ||||
7728 | static int _wrap_CoreSession_sendEvent(lua_State* L) { | |||
7729 | int SWIG_arg = 0; | |||
7730 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7731 | Event *arg2 = (Event *) 0 ; | |||
7732 | ||||
7733 | SWIG_check_num_args("CoreSession::sendEvent",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::sendEvent" ,2,2,lua_gettop(L)); goto fail;} | |||
7734 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::sendEvent",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::sendEvent",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7735 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("CoreSession::sendEvent",2,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::sendEvent",2,"Event *",SWIG_Lua_typename(L,2) ); goto fail;}; | |||
7736 | ||||
7737 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7738 | SWIG_fail_ptr("CoreSession_sendEvent",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_sendEvent",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7739 | } | |||
7740 | ||||
7741 | ||||
7742 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&arg2,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&arg2,swig_types[3],0) >= 0)){ | |||
7743 | SWIG_fail_ptr("CoreSession_sendEvent",2,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_sendEvent",2,(swig_types[3] && swig_types [3]->str)?swig_types[3]->str:"void*",SWIG_Lua_typename( L,2)); goto fail;}; | |||
7744 | } | |||
7745 | ||||
7746 | (arg1)->sendEvent(arg2); | |||
7747 | ||||
7748 | return SWIG_arg; | |||
7749 | ||||
7750 | if(0) SWIG_fail{goto fail;}; | |||
7751 | ||||
7752 | fail: | |||
7753 | lua_error(L); | |||
7754 | return SWIG_arg; | |||
7755 | } | |||
7756 | ||||
7757 | ||||
7758 | static int _wrap_CoreSession_setEventData(lua_State* L) { | |||
7759 | int SWIG_arg = 0; | |||
7760 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7761 | Event *arg2 = (Event *) 0 ; | |||
7762 | ||||
7763 | SWIG_check_num_args("CoreSession::setEventData",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::setEventData" ,2,2,lua_gettop(L)); goto fail;} | |||
7764 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::setEventData",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::setEventData",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7765 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("CoreSession::setEventData",2,"Event *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::setEventData",2,"Event *",SWIG_Lua_typename(L ,2)); goto fail;}; | |||
7766 | ||||
7767 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7768 | SWIG_fail_ptr("CoreSession_setEventData",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_setEventData",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7769 | } | |||
7770 | ||||
7771 | ||||
7772 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&arg2,SWIGTYPE_p_Event,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&arg2,swig_types[3],0) >= 0)){ | |||
7773 | SWIG_fail_ptr("CoreSession_setEventData",2,SWIGTYPE_p_Event){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_setEventData",2,(swig_types[3] && swig_types [3]->str)?swig_types[3]->str:"void*",SWIG_Lua_typename( L,2)); goto fail;}; | |||
7774 | } | |||
7775 | ||||
7776 | (arg1)->setEventData(arg2); | |||
7777 | ||||
7778 | return SWIG_arg; | |||
7779 | ||||
7780 | if(0) SWIG_fail{goto fail;}; | |||
7781 | ||||
7782 | fail: | |||
7783 | lua_error(L); | |||
7784 | return SWIG_arg; | |||
7785 | } | |||
7786 | ||||
7787 | ||||
7788 | static int _wrap_CoreSession_getXMLCDR(lua_State* L) { | |||
7789 | int SWIG_arg = 0; | |||
7790 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7791 | char *result = 0 ; | |||
7792 | ||||
7793 | SWIG_check_num_args("CoreSession::getXMLCDR",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::getXMLCDR" ,1,1,lua_gettop(L)); goto fail;} | |||
7794 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::getXMLCDR",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::getXMLCDR",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7795 | ||||
7796 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7797 | SWIG_fail_ptr("CoreSession_getXMLCDR",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_getXMLCDR",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7798 | } | |||
7799 | ||||
7800 | result = (char *)(arg1)->getXMLCDR(); | |||
7801 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
7802 | return SWIG_arg; | |||
7803 | ||||
7804 | if(0) SWIG_fail{goto fail;}; | |||
7805 | ||||
7806 | fail: | |||
7807 | lua_error(L); | |||
7808 | return SWIG_arg; | |||
7809 | } | |||
7810 | ||||
7811 | ||||
7812 | static int _wrap_CoreSession_begin_allow_threads(lua_State* L) { | |||
7813 | int SWIG_arg = 0; | |||
7814 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7815 | bool result; | |||
7816 | ||||
7817 | SWIG_check_num_args("CoreSession::begin_allow_threads",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::begin_allow_threads" ,1,1,lua_gettop(L)); goto fail;} | |||
7818 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::begin_allow_threads",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::begin_allow_threads",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7819 | ||||
7820 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7821 | SWIG_fail_ptr("CoreSession_begin_allow_threads",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_begin_allow_threads",1,(swig_types[1] && swig_types[1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7822 | } | |||
7823 | ||||
7824 | result = (bool)(arg1)->begin_allow_threads(); | |||
7825 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
7826 | return SWIG_arg; | |||
7827 | ||||
7828 | if(0) SWIG_fail{goto fail;}; | |||
7829 | ||||
7830 | fail: | |||
7831 | lua_error(L); | |||
7832 | return SWIG_arg; | |||
7833 | } | |||
7834 | ||||
7835 | ||||
7836 | static int _wrap_CoreSession_end_allow_threads(lua_State* L) { | |||
7837 | int SWIG_arg = 0; | |||
7838 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7839 | bool result; | |||
7840 | ||||
7841 | SWIG_check_num_args("CoreSession::end_allow_threads",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::end_allow_threads" ,1,1,lua_gettop(L)); goto fail;} | |||
7842 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::end_allow_threads",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::end_allow_threads",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7843 | ||||
7844 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7845 | SWIG_fail_ptr("CoreSession_end_allow_threads",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_end_allow_threads",1,(swig_types[1] && swig_types[1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7846 | } | |||
7847 | ||||
7848 | result = (bool)(arg1)->end_allow_threads(); | |||
7849 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
7850 | return SWIG_arg; | |||
7851 | ||||
7852 | if(0) SWIG_fail{goto fail;}; | |||
7853 | ||||
7854 | fail: | |||
7855 | lua_error(L); | |||
7856 | return SWIG_arg; | |||
7857 | } | |||
7858 | ||||
7859 | ||||
7860 | static int _wrap_CoreSession_get_uuid(lua_State* L) { | |||
7861 | int SWIG_arg = 0; | |||
7862 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7863 | char *result = 0 ; | |||
7864 | ||||
7865 | SWIG_check_num_args("CoreSession::get_uuid",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::get_uuid" ,1,1,lua_gettop(L)); goto fail;} | |||
7866 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::get_uuid",1,"CoreSession const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::get_uuid",1,"CoreSession const *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7867 | ||||
7868 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7869 | SWIG_fail_ptr("CoreSession_get_uuid",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_get_uuid",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7870 | } | |||
7871 | ||||
7872 | result = (char *)((CoreSession const *)arg1)->get_uuid(); | |||
7873 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
7874 | return SWIG_arg; | |||
7875 | ||||
7876 | if(0) SWIG_fail{goto fail;}; | |||
7877 | ||||
7878 | fail: | |||
7879 | lua_error(L); | |||
7880 | return SWIG_arg; | |||
7881 | } | |||
7882 | ||||
7883 | ||||
7884 | static int _wrap_CoreSession_get_cb_args(lua_State* L) { | |||
7885 | int SWIG_arg = 0; | |||
7886 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7887 | switch_input_args_t *result = 0 ; | |||
7888 | ||||
7889 | SWIG_check_num_args("CoreSession::get_cb_args",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::get_cb_args" ,1,1,lua_gettop(L)); goto fail;} | |||
7890 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::get_cb_args",1,"CoreSession const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::get_cb_args",1,"CoreSession const *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7891 | ||||
7892 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7893 | SWIG_fail_ptr("CoreSession_get_cb_args",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_get_cb_args",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7894 | } | |||
7895 | ||||
7896 | result = (switch_input_args_t *) &((CoreSession const *)arg1)->get_cb_args(); | |||
7897 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_switch_input_args_t,0)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[23], 0); SWIG_arg++; | |||
7898 | return SWIG_arg; | |||
7899 | ||||
7900 | if(0) SWIG_fail{goto fail;}; | |||
7901 | ||||
7902 | fail: | |||
7903 | lua_error(L); | |||
7904 | return SWIG_arg; | |||
7905 | } | |||
7906 | ||||
7907 | ||||
7908 | static int _wrap_CoreSession_check_hangup_hook(lua_State* L) { | |||
7909 | int SWIG_arg = 0; | |||
7910 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7911 | ||||
7912 | SWIG_check_num_args("CoreSession::check_hangup_hook",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::check_hangup_hook" ,1,1,lua_gettop(L)); goto fail;} | |||
7913 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::check_hangup_hook",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::check_hangup_hook",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7914 | ||||
7915 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7916 | SWIG_fail_ptr("CoreSession_check_hangup_hook",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_check_hangup_hook",1,(swig_types[1] && swig_types[1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7917 | } | |||
7918 | ||||
7919 | (arg1)->check_hangup_hook(); | |||
7920 | ||||
7921 | return SWIG_arg; | |||
7922 | ||||
7923 | if(0) SWIG_fail{goto fail;}; | |||
7924 | ||||
7925 | fail: | |||
7926 | lua_error(L); | |||
7927 | return SWIG_arg; | |||
7928 | } | |||
7929 | ||||
7930 | ||||
7931 | static int _wrap_CoreSession_run_dtmf_callback(lua_State* L) { | |||
7932 | int SWIG_arg = 0; | |||
7933 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7934 | void *arg2 = (void *) 0 ; | |||
7935 | switch_input_type_t arg3 ; | |||
7936 | switch_input_type_t *argp3 ; | |||
7937 | switch_status_t result; | |||
7938 | ||||
7939 | SWIG_check_num_args("CoreSession::run_dtmf_callback",3,3)if (lua_gettop(L)<3 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::run_dtmf_callback" ,3,3,lua_gettop(L)); goto fail;} | |||
7940 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::run_dtmf_callback",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::run_dtmf_callback",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7941 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("CoreSession::run_dtmf_callback",2,"void *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::run_dtmf_callback",2,"void *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
7942 | if(!lua_isuserdata(L,3)) SWIG_fail_arg("CoreSession::run_dtmf_callback",3,"switch_input_type_t"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::run_dtmf_callback",3,"switch_input_type_t",SWIG_Lua_typename (L,3)); goto fail;}; | |||
7943 | ||||
7944 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7945 | SWIG_fail_ptr("CoreSession_run_dtmf_callback",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_run_dtmf_callback",1,(swig_types[1] && swig_types[1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7946 | } | |||
7947 | ||||
7948 | arg2=(void *)SWIG_MustGetPtr(L,2,0,0,2,"CoreSession_run_dtmf_callback")SWIG_Lua_MustGetPtr(L,2, 0,0, 2,"CoreSession_run_dtmf_callback" ); | |||
7949 | ||||
7950 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,3,(void**)&argp3,SWIGTYPE_p_switch_input_type_t,0))(SWIG_Lua_ConvertPtr(L,3,(void**)&argp3,swig_types[24],0) >= 0)){ | |||
7951 | SWIG_fail_ptr("CoreSession_run_dtmf_callback",3,SWIGTYPE_p_switch_input_type_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_run_dtmf_callback",3,(swig_types[24] && swig_types[24]->str)?swig_types[24]->str:"void*",SWIG_Lua_typename (L,3)); goto fail;}; | |||
7952 | } | |||
7953 | arg3 = *argp3; | |||
7954 | ||||
7955 | result = (arg1)->run_dtmf_callback(arg2,arg3); | |||
7956 | { | |||
7957 | switch_status_t * resultptr = new switch_status_t((const switch_status_t &) result); | |||
7958 | SWIG_NewPointerObj(L,(void *) resultptr,SWIGTYPE_p_switch_status_t,1)SWIG_Lua_NewPointerObj(L, (void *)(void *) resultptr, swig_types [28], 1); SWIG_arg++; | |||
7959 | } | |||
7960 | return SWIG_arg; | |||
7961 | ||||
7962 | if(0) SWIG_fail{goto fail;}; | |||
7963 | ||||
7964 | fail: | |||
7965 | lua_error(L); | |||
7966 | return SWIG_arg; | |||
7967 | } | |||
7968 | ||||
7969 | ||||
7970 | static int _wrap_CoreSession_consoleLog(lua_State* L) { | |||
7971 | int SWIG_arg = 0; | |||
7972 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
7973 | char *arg2 = (char *) 0 ; | |||
7974 | char *arg3 = (char *) 0 ; | |||
7975 | ||||
7976 | SWIG_check_num_args("CoreSession::consoleLog",3,3)if (lua_gettop(L)<3 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::consoleLog" ,3,3,lua_gettop(L)); goto fail;} | |||
7977 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::consoleLog",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::consoleLog",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
7978 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::consoleLog",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::consoleLog",2,"char *",SWIG_Lua_typename(L,2) ); goto fail;}; | |||
7979 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("CoreSession::consoleLog",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::consoleLog",3,"char *",SWIG_Lua_typename(L,3) ); goto fail;}; | |||
7980 | ||||
7981 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
7982 | SWIG_fail_ptr("CoreSession_consoleLog",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_consoleLog",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
7983 | } | |||
7984 | ||||
7985 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
7986 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
7987 | (arg1)->consoleLog(arg2,arg3); | |||
7988 | ||||
7989 | return SWIG_arg; | |||
7990 | ||||
7991 | if(0) SWIG_fail{goto fail;}; | |||
7992 | ||||
7993 | fail: | |||
7994 | lua_error(L); | |||
7995 | return SWIG_arg; | |||
7996 | } | |||
7997 | ||||
7998 | ||||
7999 | static int _wrap_CoreSession_consoleLog2(lua_State* L) { | |||
8000 | int SWIG_arg = 0; | |||
8001 | CoreSession *arg1 = (CoreSession *) 0 ; | |||
8002 | char *arg2 = (char *) 0 ; | |||
8003 | char *arg3 = (char *) 0 ; | |||
8004 | char *arg4 = (char *) 0 ; | |||
8005 | int arg5 ; | |||
8006 | char *arg6 = (char *) 0 ; | |||
8007 | ||||
8008 | SWIG_check_num_args("CoreSession::consoleLog2",6,6)if (lua_gettop(L)<6 || lua_gettop(L)>6) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","CoreSession::consoleLog2" ,6,6,lua_gettop(L)); goto fail;} | |||
8009 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("CoreSession::consoleLog2",1,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::consoleLog2",1,"CoreSession *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
8010 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("CoreSession::consoleLog2",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::consoleLog2",2,"char *",SWIG_Lua_typename(L,2 )); goto fail;}; | |||
8011 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("CoreSession::consoleLog2",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::consoleLog2",3,"char *",SWIG_Lua_typename(L,3 )); goto fail;}; | |||
8012 | if(!SWIG_lua_isnilstring(L,4)) SWIG_fail_arg("CoreSession::consoleLog2",4,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::consoleLog2",4,"char *",SWIG_Lua_typename(L,4 )); goto fail;}; | |||
8013 | if(!lua_isnumber(L,5)) SWIG_fail_arg("CoreSession::consoleLog2",5,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::consoleLog2",5,"int",SWIG_Lua_typename(L,5)); goto fail;}; | |||
8014 | if(!SWIG_lua_isnilstring(L,6)) SWIG_fail_arg("CoreSession::consoleLog2",6,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession::consoleLog2",6,"char *",SWIG_Lua_typename(L,6 )); goto fail;}; | |||
8015 | ||||
8016 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
8017 | SWIG_fail_ptr("CoreSession_consoleLog2",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "CoreSession_consoleLog2",1,(swig_types[1] && swig_types [1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
8018 | } | |||
8019 | ||||
8020 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
8021 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
8022 | arg4 = (char *)lua_tostring(L, 4)lua_tolstring(L, (4), __null); | |||
8023 | arg5 = (int)lua_tonumber(L, 5)lua_tonumberx(L,5,__null); | |||
8024 | arg6 = (char *)lua_tostring(L, 6)lua_tolstring(L, (6), __null); | |||
8025 | (arg1)->consoleLog2(arg2,arg3,arg4,arg5,arg6); | |||
8026 | ||||
8027 | return SWIG_arg; | |||
8028 | ||||
8029 | if(0) SWIG_fail{goto fail;}; | |||
8030 | ||||
8031 | fail: | |||
8032 | lua_error(L); | |||
8033 | return SWIG_arg; | |||
8034 | } | |||
8035 | ||||
8036 | ||||
8037 | static void swig_delete_CoreSession(void *obj) { | |||
8038 | CoreSession *arg1 = (CoreSession *) obj; | |||
8039 | delete arg1; | |||
8040 | } | |||
8041 | static swig_lua_attribute swig_CoreSession_attributes[] = { | |||
8042 | { "session", _wrap_CoreSession_session_get, _wrap_CoreSession_session_set }, | |||
8043 | { "channel", _wrap_CoreSession_channel_get, _wrap_CoreSession_channel_set }, | |||
8044 | { "flags", _wrap_CoreSession_flags_get, _wrap_CoreSession_flags_set }, | |||
8045 | { "allocated", _wrap_CoreSession_allocated_get, _wrap_CoreSession_allocated_set }, | |||
8046 | { "cb_state", _wrap_CoreSession_cb_state_get, _wrap_CoreSession_cb_state_set }, | |||
8047 | { "hook_state", _wrap_CoreSession_hook_state_get, _wrap_CoreSession_hook_state_set }, | |||
8048 | { "cause", _wrap_CoreSession_cause_get, _wrap_CoreSession_cause_set }, | |||
8049 | { "uuid", _wrap_CoreSession_uuid_get, _wrap_CoreSession_uuid_set }, | |||
8050 | { "tts_name", _wrap_CoreSession_tts_name_get, _wrap_CoreSession_tts_name_set }, | |||
8051 | { "voice_name", _wrap_CoreSession_voice_name_get, _wrap_CoreSession_voice_name_set }, | |||
8052 | {0,0,0} | |||
8053 | }; | |||
8054 | static swig_lua_method swig_CoreSession_methods[]= { | |||
8055 | { "insertFile", _wrap_CoreSession_insertFile}, | |||
8056 | { "answer", _wrap_CoreSession_answer}, | |||
8057 | { "print", _wrap_CoreSession_print}, | |||
8058 | { "preAnswer", _wrap_CoreSession_preAnswer}, | |||
8059 | { "hangup", _wrap_CoreSession_hangup}, | |||
8060 | { "hangupState", _wrap_CoreSession_hangupState}, | |||
8061 | { "setVariable", _wrap_CoreSession_setVariable}, | |||
8062 | { "setPrivate", _wrap_CoreSession_setPrivate}, | |||
8063 | { "getPrivate", _wrap_CoreSession_getPrivate}, | |||
8064 | { "getVariable", _wrap_CoreSession_getVariable}, | |||
8065 | { "process_callback_result", _wrap_CoreSession_process_callback_result}, | |||
8066 | { "say", _wrap_CoreSession_say}, | |||
8067 | { "sayPhrase", _wrap_CoreSession_sayPhrase}, | |||
8068 | { "hangupCause", _wrap_CoreSession_hangupCause}, | |||
8069 | { "getState", _wrap_CoreSession_getState}, | |||
8070 | { "recordFile", _wrap_CoreSession_recordFile}, | |||
8071 | { "originate", _wrap_CoreSession_originate}, | |||
8072 | { "destroy", _wrap_CoreSession_destroy}, | |||
8073 | { "setDTMFCallback", _wrap_CoreSession_setDTMFCallback}, | |||
8074 | { "speak", _wrap_CoreSession_speak}, | |||
8075 | { "set_tts_parms", _wrap_CoreSession_set_tts_parms}, | |||
8076 | { "set_tts_params", _wrap_CoreSession_set_tts_params}, | |||
8077 | { "collectDigits", _wrap_CoreSession_collectDigits}, | |||
8078 | { "getDigits", _wrap_CoreSession_getDigits}, | |||
8079 | { "transfer", _wrap_CoreSession_transfer}, | |||
8080 | { "read", _wrap_CoreSession_read}, | |||
8081 | { "detectSpeech", _wrap_CoreSession_detectSpeech}, | |||
8082 | { "playAndGetDigits", _wrap_CoreSession_playAndGetDigits}, | |||
8083 | { "playAndDetectSpeech", _wrap_CoreSession_playAndDetectSpeech}, | |||
8084 | { "streamFile", _wrap_CoreSession_streamFile}, | |||
8085 | { "sleep", _wrap_CoreSession_sleep}, | |||
8086 | { "flushEvents", _wrap_CoreSession_flushEvents}, | |||
8087 | { "flushDigits", _wrap_CoreSession_flushDigits}, | |||
8088 | { "setAutoHangup", _wrap_CoreSession_setAutoHangup}, | |||
8089 | { "setHangupHook", _wrap_CoreSession_setHangupHook}, | |||
8090 | { "ready", _wrap_CoreSession_ready}, | |||
8091 | { "bridged", _wrap_CoreSession_bridged}, | |||
8092 | { "answered", _wrap_CoreSession_answered}, | |||
8093 | { "mediaReady", _wrap_CoreSession_mediaReady}, | |||
8094 | { "waitForAnswer", _wrap_CoreSession_waitForAnswer}, | |||
8095 | { "execute", _wrap_CoreSession_execute}, | |||
8096 | { "sendEvent", _wrap_CoreSession_sendEvent}, | |||
8097 | { "setEventData", _wrap_CoreSession_setEventData}, | |||
8098 | { "getXMLCDR", _wrap_CoreSession_getXMLCDR}, | |||
8099 | { "begin_allow_threads", _wrap_CoreSession_begin_allow_threads}, | |||
8100 | { "end_allow_threads", _wrap_CoreSession_end_allow_threads}, | |||
8101 | { "get_uuid", _wrap_CoreSession_get_uuid}, | |||
8102 | { "get_cb_args", _wrap_CoreSession_get_cb_args}, | |||
8103 | { "check_hangup_hook", _wrap_CoreSession_check_hangup_hook}, | |||
8104 | { "run_dtmf_callback", _wrap_CoreSession_run_dtmf_callback}, | |||
8105 | { "consoleLog", _wrap_CoreSession_consoleLog}, | |||
8106 | { "consoleLog2", _wrap_CoreSession_consoleLog2}, | |||
8107 | {0,0} | |||
8108 | }; | |||
8109 | static swig_lua_method swig_CoreSession_meta[] = { | |||
8110 | {0,0} | |||
8111 | }; | |||
8112 | ||||
8113 | static swig_lua_attribute swig_CoreSession_Sf_SwigStatic_attributes[] = { | |||
8114 | {0,0,0} | |||
8115 | }; | |||
8116 | static swig_lua_const_info swig_CoreSession_Sf_SwigStatic_constants[]= { | |||
8117 | {0,0,0,0,0,0} | |||
8118 | }; | |||
8119 | static swig_lua_method swig_CoreSession_Sf_SwigStatic_methods[]= { | |||
8120 | {0,0} | |||
8121 | }; | |||
8122 | static swig_lua_class* swig_CoreSession_Sf_SwigStatic_classes[]= { | |||
8123 | 0 | |||
8124 | }; | |||
8125 | ||||
8126 | static swig_lua_namespace swig_CoreSession_Sf_SwigStatic = { | |||
8127 | "CoreSession", | |||
8128 | swig_CoreSession_Sf_SwigStatic_methods, | |||
8129 | swig_CoreSession_Sf_SwigStatic_attributes, | |||
8130 | swig_CoreSession_Sf_SwigStatic_constants, | |||
8131 | swig_CoreSession_Sf_SwigStatic_classes, | |||
8132 | 0 | |||
8133 | }; | |||
8134 | static swig_lua_class *swig_CoreSession_bases[] = {0}; | |||
8135 | static const char *swig_CoreSession_base_names[] = {0}; | |||
8136 | static swig_lua_class _wrap_class_CoreSession = { "CoreSession", "CoreSession", &SWIGTYPE_p_CoreSessionswig_types[1],0, swig_delete_CoreSession, swig_CoreSession_methods, swig_CoreSession_attributes, &swig_CoreSession_Sf_SwigStatic, swig_CoreSession_meta, swig_CoreSession_bases, swig_CoreSession_base_names }; | |||
8137 | ||||
8138 | static int _wrap_console_log(lua_State* L) { | |||
8139 | int SWIG_arg = 0; | |||
8140 | char *arg1 = (char *) 0 ; | |||
8141 | char *arg2 = (char *) 0 ; | |||
8142 | ||||
8143 | SWIG_check_num_args("console_log",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","console_log",2 ,2,lua_gettop(L)); goto fail;} | |||
8144 | if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("console_log",1,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "console_log",1,"char *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
8145 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("console_log",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "console_log",2,"char *",SWIG_Lua_typename(L,2)); goto fail ;}; | |||
8146 | arg1 = (char *)lua_tostring(L, 1)lua_tolstring(L, (1), __null); | |||
8147 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
8148 | console_log(arg1,arg2); | |||
8149 | ||||
8150 | return SWIG_arg; | |||
8151 | ||||
8152 | if(0) SWIG_fail{goto fail;}; | |||
8153 | ||||
8154 | fail: | |||
8155 | lua_error(L); | |||
8156 | return SWIG_arg; | |||
8157 | } | |||
8158 | ||||
8159 | ||||
8160 | static int _wrap_console_log2(lua_State* L) { | |||
8161 | int SWIG_arg = 0; | |||
8162 | char *arg1 = (char *) 0 ; | |||
8163 | char *arg2 = (char *) 0 ; | |||
8164 | char *arg3 = (char *) 0 ; | |||
8165 | int arg4 ; | |||
8166 | char *arg5 = (char *) 0 ; | |||
8167 | ||||
8168 | SWIG_check_num_args("console_log2",5,5)if (lua_gettop(L)<5 || lua_gettop(L)>5) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","console_log2", 5,5,lua_gettop(L)); goto fail;} | |||
8169 | if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("console_log2",1,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "console_log2",1,"char *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
8170 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("console_log2",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "console_log2",2,"char *",SWIG_Lua_typename(L,2)); goto fail ;}; | |||
8171 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("console_log2",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "console_log2",3,"char *",SWIG_Lua_typename(L,3)); goto fail ;}; | |||
8172 | if(!lua_isnumber(L,4)) SWIG_fail_arg("console_log2",4,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "console_log2",4,"int",SWIG_Lua_typename(L,4)); goto fail;}; | |||
8173 | if(!SWIG_lua_isnilstring(L,5)) SWIG_fail_arg("console_log2",5,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "console_log2",5,"char *",SWIG_Lua_typename(L,5)); goto fail ;}; | |||
8174 | arg1 = (char *)lua_tostring(L, 1)lua_tolstring(L, (1), __null); | |||
8175 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
8176 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
8177 | arg4 = (int)lua_tonumber(L, 4)lua_tonumberx(L,4,__null); | |||
8178 | arg5 = (char *)lua_tostring(L, 5)lua_tolstring(L, (5), __null); | |||
8179 | console_log2(arg1,arg2,arg3,arg4,arg5); | |||
8180 | ||||
8181 | return SWIG_arg; | |||
8182 | ||||
8183 | if(0) SWIG_fail{goto fail;}; | |||
8184 | ||||
8185 | fail: | |||
8186 | lua_error(L); | |||
8187 | return SWIG_arg; | |||
8188 | } | |||
8189 | ||||
8190 | ||||
8191 | static int _wrap_console_clean_log(lua_State* L) { | |||
8192 | int SWIG_arg = 0; | |||
8193 | char *arg1 = (char *) 0 ; | |||
8194 | ||||
8195 | SWIG_check_num_args("console_clean_log",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","console_clean_log" ,1,1,lua_gettop(L)); goto fail;} | |||
8196 | if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("console_clean_log",1,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "console_clean_log",1,"char *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
8197 | arg1 = (char *)lua_tostring(L, 1)lua_tolstring(L, (1), __null); | |||
8198 | console_clean_log(arg1); | |||
8199 | ||||
8200 | return SWIG_arg; | |||
8201 | ||||
8202 | if(0) SWIG_fail{goto fail;}; | |||
8203 | ||||
8204 | fail: | |||
8205 | lua_error(L); | |||
8206 | return SWIG_arg; | |||
8207 | } | |||
8208 | ||||
8209 | ||||
8210 | static int _wrap_msleep(lua_State* L) { | |||
8211 | int SWIG_arg = 0; | |||
8212 | unsigned int arg1 ; | |||
8213 | ||||
8214 | SWIG_check_num_args("switch_msleep",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","switch_msleep" ,1,1,lua_gettop(L)); goto fail;} | |||
8215 | if(!lua_isnumber(L,1)) SWIG_fail_arg("switch_msleep",1,"unsigned int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "switch_msleep",1,"unsigned int",SWIG_Lua_typename(L,1)); goto fail;}; | |||
8216 | SWIG_contract_assert((lua_tonumber(L,1)>=0),"number must not be negative")if (!((lua_tonumberx(L,1,__null)>=0))) { SWIG_Lua_pusherrstring (L, (char *) "number must not be negative"); goto fail; } else | |||
8217 | arg1 = (unsigned int)lua_tonumber(L, 1)lua_tonumberx(L,1,__null); | |||
8218 | switch_msleep(arg1); | |||
8219 | ||||
8220 | return SWIG_arg; | |||
8221 | ||||
8222 | if(0) SWIG_fail{goto fail;}; | |||
8223 | ||||
8224 | fail: | |||
8225 | lua_error(L); | |||
8226 | return SWIG_arg; | |||
8227 | } | |||
8228 | ||||
8229 | ||||
8230 | static int _wrap_bridge(lua_State* L) { | |||
8231 | int SWIG_arg = 0; | |||
8232 | CoreSession *arg1 = 0 ; | |||
8233 | CoreSession *arg2 = 0 ; | |||
8234 | ||||
8235 | SWIG_check_num_args("bridge",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","bridge",2,2,lua_gettop (L)); goto fail;} | |||
8236 | if(!lua_isuserdata(L,1)) SWIG_fail_arg("bridge",1,"CoreSession &"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "bridge",1,"CoreSession &",SWIG_Lua_typename(L,1)); goto fail;}; | |||
8237 | if(!lua_isuserdata(L,2)) SWIG_fail_arg("bridge",2,"CoreSession &"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "bridge",2,"CoreSession &",SWIG_Lua_typename(L,2)); goto fail;}; | |||
8238 | ||||
8239 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[1],0) >= 0)){ | |||
8240 | SWIG_fail_ptr("bridge",1,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "bridge",1,(swig_types[1] && swig_types[1]->str) ?swig_types[1]->str:"void*",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
8241 | } | |||
8242 | ||||
8243 | ||||
8244 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&arg2,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&arg2,swig_types[1],0) >= 0)){ | |||
8245 | SWIG_fail_ptr("bridge",2,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "bridge",2,(swig_types[1] && swig_types[1]->str) ?swig_types[1]->str:"void*",SWIG_Lua_typename(L,2)); goto fail ;}; | |||
8246 | } | |||
8247 | ||||
8248 | bridge(*arg1,*arg2); | |||
8249 | ||||
8250 | return SWIG_arg; | |||
8251 | ||||
8252 | if(0) SWIG_fail{goto fail;}; | |||
8253 | ||||
8254 | fail: | |||
8255 | lua_error(L); | |||
8256 | return SWIG_arg; | |||
8257 | } | |||
8258 | ||||
8259 | ||||
8260 | static int _wrap_hanguphook(lua_State* L) { | |||
8261 | int SWIG_arg = 0; | |||
8262 | switch_core_session_t *arg1 = (switch_core_session_t *) 0 ; | |||
8263 | switch_status_t result; | |||
8264 | ||||
8265 | SWIG_check_num_args("hanguphook",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","hanguphook",1, 1,lua_gettop(L)); goto fail;} | |||
8266 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("hanguphook",1,"switch_core_session_t *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "hanguphook",1,"switch_core_session_t *",SWIG_Lua_typename( L,1)); goto fail;}; | |||
8267 | ||||
8268 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_switch_core_session_t,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[20],0) >= 0)){ | |||
8269 | SWIG_fail_ptr("hanguphook",1,SWIGTYPE_p_switch_core_session_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "hanguphook",1,(swig_types[20] && swig_types[20]-> str)?swig_types[20]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
8270 | } | |||
8271 | ||||
8272 | result = hanguphook(arg1); | |||
8273 | { | |||
8274 | switch_status_t * resultptr = new switch_status_t((const switch_status_t &) result); | |||
8275 | SWIG_NewPointerObj(L,(void *) resultptr,SWIGTYPE_p_switch_status_t,1)SWIG_Lua_NewPointerObj(L, (void *)(void *) resultptr, swig_types [28], 1); SWIG_arg++; | |||
8276 | } | |||
8277 | return SWIG_arg; | |||
8278 | ||||
8279 | if(0) SWIG_fail{goto fail;}; | |||
8280 | ||||
8281 | fail: | |||
8282 | lua_error(L); | |||
8283 | return SWIG_arg; | |||
8284 | } | |||
8285 | ||||
8286 | ||||
8287 | static int _wrap_dtmf_callback(lua_State* L) { | |||
8288 | int SWIG_arg = 0; | |||
8289 | switch_core_session_t *arg1 = (switch_core_session_t *) 0 ; | |||
8290 | void *arg2 = (void *) 0 ; | |||
8291 | switch_input_type_t arg3 ; | |||
8292 | void *arg4 = (void *) 0 ; | |||
8293 | unsigned int arg5 ; | |||
8294 | switch_input_type_t *argp3 ; | |||
8295 | switch_status_t result; | |||
8296 | ||||
8297 | SWIG_check_num_args("dtmf_callback",5,5)if (lua_gettop(L)<5 || lua_gettop(L)>5) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","dtmf_callback" ,5,5,lua_gettop(L)); goto fail;} | |||
8298 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("dtmf_callback",1,"switch_core_session_t *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "dtmf_callback",1,"switch_core_session_t *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
8299 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("dtmf_callback",2,"void *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "dtmf_callback",2,"void *",SWIG_Lua_typename(L,2)); goto fail ;}; | |||
8300 | if(!lua_isuserdata(L,3)) SWIG_fail_arg("dtmf_callback",3,"switch_input_type_t"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "dtmf_callback",3,"switch_input_type_t",SWIG_Lua_typename(L ,3)); goto fail;}; | |||
8301 | if(!SWIG_isptrtype(L,4)(lua_isuserdata(L,4) || (lua_type(L, (4)) == 0))) SWIG_fail_arg("dtmf_callback",4,"void *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "dtmf_callback",4,"void *",SWIG_Lua_typename(L,4)); goto fail ;}; | |||
8302 | if(!lua_isnumber(L,5)) SWIG_fail_arg("dtmf_callback",5,"unsigned int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "dtmf_callback",5,"unsigned int",SWIG_Lua_typename(L,5)); goto fail;}; | |||
8303 | ||||
8304 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_switch_core_session_t,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[20],0) >= 0)){ | |||
8305 | SWIG_fail_ptr("dtmf_callback",1,SWIGTYPE_p_switch_core_session_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "dtmf_callback",1,(swig_types[20] && swig_types[20] ->str)?swig_types[20]->str:"void*",SWIG_Lua_typename(L, 1)); goto fail;}; | |||
8306 | } | |||
8307 | ||||
8308 | arg2=(void *)SWIG_MustGetPtr(L,2,0,0,2,"dtmf_callback")SWIG_Lua_MustGetPtr(L,2, 0,0, 2,"dtmf_callback"); | |||
8309 | ||||
8310 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,3,(void**)&argp3,SWIGTYPE_p_switch_input_type_t,0))(SWIG_Lua_ConvertPtr(L,3,(void**)&argp3,swig_types[24],0) >= 0)){ | |||
8311 | SWIG_fail_ptr("dtmf_callback",3,SWIGTYPE_p_switch_input_type_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "dtmf_callback",3,(swig_types[24] && swig_types[24] ->str)?swig_types[24]->str:"void*",SWIG_Lua_typename(L, 3)); goto fail;}; | |||
8312 | } | |||
8313 | arg3 = *argp3; | |||
8314 | ||||
8315 | arg4=(void *)SWIG_MustGetPtr(L,4,0,0,4,"dtmf_callback")SWIG_Lua_MustGetPtr(L,4, 0,0, 4,"dtmf_callback"); | |||
8316 | SWIG_contract_assert((lua_tonumber(L,5)>=0),"number must not be negative")if (!((lua_tonumberx(L,5,__null)>=0))) { SWIG_Lua_pusherrstring (L, (char *) "number must not be negative"); goto fail; } else | |||
8317 | arg5 = (unsigned int)lua_tonumber(L, 5)lua_tonumberx(L,5,__null); | |||
8318 | result = dtmf_callback(arg1,arg2,arg3,arg4,arg5); | |||
8319 | { | |||
8320 | switch_status_t * resultptr = new switch_status_t((const switch_status_t &) result); | |||
8321 | SWIG_NewPointerObj(L,(void *) resultptr,SWIGTYPE_p_switch_status_t,1)SWIG_Lua_NewPointerObj(L, (void *)(void *) resultptr, swig_types [28], 1); SWIG_arg++; | |||
8322 | } | |||
8323 | return SWIG_arg; | |||
8324 | ||||
8325 | if(0) SWIG_fail{goto fail;}; | |||
8326 | ||||
8327 | fail: | |||
8328 | lua_error(L); | |||
8329 | return SWIG_arg; | |||
8330 | } | |||
8331 | ||||
8332 | ||||
8333 | static int _wrap_new_Session__SWIG_0(lua_State* L) { | |||
8334 | int SWIG_arg = 0; | |||
8335 | LUA::Session *result = 0 ; | |||
8336 | ||||
8337 | SWIG_check_num_args("LUA::Session::Session",0,0)if (lua_gettop(L)<0 || lua_gettop(L)>0) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::Session" ,0,0,lua_gettop(L)); goto fail;} | |||
8338 | result = (LUA::Session *)new LUA::Session(); | |||
8339 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_LUA__Session,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[8], 1); SWIG_arg++; result->setLUA(L); | |||
8340 | return SWIG_arg; | |||
8341 | ||||
8342 | if(0) SWIG_fail{goto fail;}; | |||
8343 | ||||
8344 | fail: | |||
8345 | lua_error(L); | |||
8346 | return SWIG_arg; | |||
8347 | } | |||
8348 | ||||
8349 | ||||
8350 | static int _wrap_new_Session__SWIG_1(lua_State* L) { | |||
8351 | int SWIG_arg = 0; | |||
8352 | char *arg1 = (char *) 0 ; | |||
8353 | CoreSession *arg2 = (CoreSession *) 0 ; | |||
8354 | LUA::Session *result = 0 ; | |||
8355 | ||||
8356 | SWIG_check_num_args("LUA::Session::Session",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::Session" ,2,2,lua_gettop(L)); goto fail;} | |||
8357 | if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("LUA::Session::Session",1,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::Session",1,"char *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
8358 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("LUA::Session::Session",2,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::Session",2,"CoreSession *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
8359 | arg1 = (char *)lua_tostring(L, 1)lua_tolstring(L, (1), __null); | |||
8360 | ||||
8361 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&arg2,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&arg2,swig_types[1],0) >= 0)){ | |||
8362 | SWIG_fail_ptr("new_Session",2,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "new_Session",2,(swig_types[1] && swig_types[1]-> str)?swig_types[1]->str:"void*",SWIG_Lua_typename(L,2)); goto fail;}; | |||
8363 | } | |||
8364 | ||||
8365 | result = (LUA::Session *)new LUA::Session(arg1,arg2); | |||
8366 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_LUA__Session,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[8], 1); SWIG_arg++; result->setLUA(L); | |||
8367 | return SWIG_arg; | |||
8368 | ||||
8369 | if(0) SWIG_fail{goto fail;}; | |||
8370 | ||||
8371 | fail: | |||
8372 | lua_error(L); | |||
8373 | return SWIG_arg; | |||
8374 | } | |||
8375 | ||||
8376 | ||||
8377 | static int _wrap_new_Session__SWIG_2(lua_State* L) { | |||
8378 | int SWIG_arg = 0; | |||
8379 | char *arg1 = (char *) 0 ; | |||
8380 | LUA::Session *result = 0 ; | |||
8381 | ||||
8382 | SWIG_check_num_args("LUA::Session::Session",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::Session" ,1,1,lua_gettop(L)); goto fail;} | |||
8383 | if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("LUA::Session::Session",1,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::Session",1,"char *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
8384 | arg1 = (char *)lua_tostring(L, 1)lua_tolstring(L, (1), __null); | |||
8385 | result = (LUA::Session *)new LUA::Session(arg1); | |||
8386 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_LUA__Session,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[8], 1); SWIG_arg++; result->setLUA(L); | |||
8387 | return SWIG_arg; | |||
8388 | ||||
8389 | if(0) SWIG_fail{goto fail;}; | |||
8390 | ||||
8391 | fail: | |||
8392 | lua_error(L); | |||
8393 | return SWIG_arg; | |||
8394 | } | |||
8395 | ||||
8396 | ||||
8397 | static int _wrap_new_Session__SWIG_3(lua_State* L) { | |||
8398 | int SWIG_arg = 0; | |||
8399 | switch_core_session_t *arg1 = (switch_core_session_t *) 0 ; | |||
8400 | LUA::Session *result = 0 ; | |||
8401 | ||||
8402 | SWIG_check_num_args("LUA::Session::Session",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::Session" ,1,1,lua_gettop(L)); goto fail;} | |||
8403 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::Session",1,"switch_core_session_t *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::Session",1,"switch_core_session_t *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
8404 | ||||
8405 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_switch_core_session_t,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[20],0) >= 0)){ | |||
8406 | SWIG_fail_ptr("new_Session",1,SWIGTYPE_p_switch_core_session_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "new_Session",1,(swig_types[20] && swig_types[20]-> str)?swig_types[20]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
8407 | } | |||
8408 | ||||
8409 | result = (LUA::Session *)new LUA::Session(arg1); | |||
8410 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_LUA__Session,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[8], 1); SWIG_arg++; result->setLUA(L); | |||
8411 | return SWIG_arg; | |||
8412 | ||||
8413 | if(0) SWIG_fail{goto fail;}; | |||
8414 | ||||
8415 | fail: | |||
8416 | lua_error(L); | |||
8417 | return SWIG_arg; | |||
8418 | } | |||
8419 | ||||
8420 | ||||
8421 | static int _wrap_new_Session(lua_State* L) { | |||
8422 | int argc; | |||
8423 | int argv[3]={ | |||
8424 | 1,2,3 | |||
8425 | }; | |||
8426 | ||||
8427 | argc = lua_gettop(L); | |||
8428 | if (argc == 0) { | |||
8429 | return _wrap_new_Session__SWIG_0(L); | |||
8430 | } | |||
8431 | if (argc == 1) { | |||
8432 | int _v; | |||
8433 | { | |||
8434 | void *ptr; | |||
8435 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_switch_core_session_t, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[20 ],0)) { | |||
8436 | _v = 0; | |||
8437 | } else { | |||
8438 | _v = 1; | |||
8439 | } | |||
8440 | } | |||
8441 | if (_v) { | |||
8442 | return _wrap_new_Session__SWIG_3(L); | |||
8443 | } | |||
8444 | } | |||
8445 | if (argc == 1) { | |||
8446 | int _v; | |||
8447 | { | |||
8448 | _v = SWIG_lua_isnilstring(L,argv[0]); | |||
8449 | } | |||
8450 | if (_v) { | |||
8451 | return _wrap_new_Session__SWIG_2(L); | |||
8452 | } | |||
8453 | } | |||
8454 | if (argc == 2) { | |||
8455 | int _v; | |||
8456 | { | |||
8457 | _v = SWIG_lua_isnilstring(L,argv[0]); | |||
8458 | } | |||
8459 | if (_v) { | |||
8460 | { | |||
8461 | void *ptr; | |||
8462 | if (SWIG_isptrtype(L,argv[1])(lua_isuserdata(L,argv[1]) || (lua_type(L, (argv[1])) == 0))==0 || SWIG_ConvertPtr(L,argv[1], (void **) &ptr, SWIGTYPE_p_CoreSession, 0)SWIG_Lua_ConvertPtr(L,argv[1],(void **) &ptr,swig_types[1 ],0)) { | |||
8463 | _v = 0; | |||
8464 | } else { | |||
8465 | _v = 1; | |||
8466 | } | |||
8467 | } | |||
8468 | if (_v) { | |||
8469 | return _wrap_new_Session__SWIG_1(L); | |||
8470 | } | |||
8471 | } | |||
8472 | } | |||
8473 | ||||
8474 | SWIG_Lua_pusherrstring(L,"Wrong arguments for overloaded function 'new_Session'\n" | |||
8475 | " Possible C/C++ prototypes are:\n" | |||
8476 | " LUA::Session::Session()\n" | |||
8477 | " LUA::Session::Session(char *,CoreSession *)\n" | |||
8478 | " LUA::Session::Session(char *)\n" | |||
8479 | " LUA::Session::Session(switch_core_session_t *)\n"); | |||
8480 | lua_error(L);return 0; | |||
8481 | } | |||
8482 | ||||
8483 | ||||
8484 | static int _wrap_Session_destroy__SWIG_0(lua_State* L) { | |||
8485 | int SWIG_arg = 0; | |||
8486 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
8487 | char *arg2 = (char *) 0 ; | |||
8488 | ||||
8489 | SWIG_check_num_args("LUA::Session::destroy",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::destroy" ,2,2,lua_gettop(L)); goto fail;} | |||
8490 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::destroy",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::destroy",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
8491 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::Session::destroy",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::destroy",2,"char const *",SWIG_Lua_typename( L,2)); goto fail;}; | |||
8492 | ||||
8493 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
8494 | SWIG_fail_ptr("Session_destroy",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_destroy",1,(swig_types[8] && swig_types[8] ->str)?swig_types[8]->str:"void*",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
8495 | } | |||
8496 | ||||
8497 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
8498 | (arg1)->destroy((char const *)arg2); | |||
8499 | ||||
8500 | return SWIG_arg; | |||
8501 | ||||
8502 | if(0) SWIG_fail{goto fail;}; | |||
8503 | ||||
8504 | fail: | |||
8505 | lua_error(L); | |||
8506 | return SWIG_arg; | |||
8507 | } | |||
8508 | ||||
8509 | ||||
8510 | static int _wrap_Session_destroy__SWIG_1(lua_State* L) { | |||
8511 | int SWIG_arg = 0; | |||
8512 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
8513 | ||||
8514 | SWIG_check_num_args("LUA::Session::destroy",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::destroy" ,1,1,lua_gettop(L)); goto fail;} | |||
8515 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::destroy",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::destroy",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
8516 | ||||
8517 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
8518 | SWIG_fail_ptr("Session_destroy",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_destroy",1,(swig_types[8] && swig_types[8] ->str)?swig_types[8]->str:"void*",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
8519 | } | |||
8520 | ||||
8521 | (arg1)->destroy(); | |||
8522 | ||||
8523 | return SWIG_arg; | |||
8524 | ||||
8525 | if(0) SWIG_fail{goto fail;}; | |||
8526 | ||||
8527 | fail: | |||
8528 | lua_error(L); | |||
8529 | return SWIG_arg; | |||
8530 | } | |||
8531 | ||||
8532 | ||||
8533 | static int _wrap_Session_destroy(lua_State* L) { | |||
8534 | int argc; | |||
8535 | int argv[3]={ | |||
8536 | 1,2,3 | |||
8537 | }; | |||
8538 | ||||
8539 | argc = lua_gettop(L); | |||
8540 | if (argc == 1) { | |||
8541 | int _v; | |||
8542 | { | |||
8543 | void *ptr; | |||
8544 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_LUA__Session, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[8 ],0)) { | |||
8545 | _v = 0; | |||
8546 | } else { | |||
8547 | _v = 1; | |||
8548 | } | |||
8549 | } | |||
8550 | if (_v) { | |||
8551 | return _wrap_Session_destroy__SWIG_1(L); | |||
8552 | } | |||
8553 | } | |||
8554 | if (argc == 2) { | |||
8555 | int _v; | |||
8556 | { | |||
8557 | void *ptr; | |||
8558 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_LUA__Session, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[8 ],0)) { | |||
8559 | _v = 0; | |||
8560 | } else { | |||
8561 | _v = 1; | |||
8562 | } | |||
8563 | } | |||
8564 | if (_v) { | |||
8565 | { | |||
8566 | _v = SWIG_lua_isnilstring(L,argv[1]); | |||
8567 | } | |||
8568 | if (_v) { | |||
8569 | return _wrap_Session_destroy__SWIG_0(L); | |||
8570 | } | |||
8571 | } | |||
8572 | } | |||
8573 | ||||
8574 | SWIG_Lua_pusherrstring(L,"Wrong arguments for overloaded function 'Session_destroy'\n" | |||
8575 | " Possible C/C++ prototypes are:\n" | |||
8576 | " LUA::Session::destroy(char const *)\n" | |||
8577 | " LUA::Session::destroy()\n"); | |||
8578 | lua_error(L);return 0; | |||
8579 | } | |||
8580 | ||||
8581 | ||||
8582 | static int _wrap_Session_begin_allow_threads(lua_State* L) { | |||
8583 | int SWIG_arg = 0; | |||
8584 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
8585 | bool result; | |||
8586 | ||||
8587 | SWIG_check_num_args("LUA::Session::begin_allow_threads",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::begin_allow_threads" ,1,1,lua_gettop(L)); goto fail;} | |||
8588 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::begin_allow_threads",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::begin_allow_threads",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
8589 | ||||
8590 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
8591 | SWIG_fail_ptr("Session_begin_allow_threads",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_begin_allow_threads",1,(swig_types[8] && swig_types [8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
8592 | } | |||
8593 | ||||
8594 | result = (bool)(arg1)->begin_allow_threads(); | |||
8595 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
8596 | return SWIG_arg; | |||
8597 | ||||
8598 | if(0) SWIG_fail{goto fail;}; | |||
8599 | ||||
8600 | fail: | |||
8601 | lua_error(L); | |||
8602 | return SWIG_arg; | |||
8603 | } | |||
8604 | ||||
8605 | ||||
8606 | static int _wrap_Session_end_allow_threads(lua_State* L) { | |||
8607 | int SWIG_arg = 0; | |||
8608 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
8609 | bool result; | |||
8610 | ||||
8611 | SWIG_check_num_args("LUA::Session::end_allow_threads",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::end_allow_threads" ,1,1,lua_gettop(L)); goto fail;} | |||
8612 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::end_allow_threads",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::end_allow_threads",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
8613 | ||||
8614 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
8615 | SWIG_fail_ptr("Session_end_allow_threads",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_end_allow_threads",1,(swig_types[8] && swig_types [8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
8616 | } | |||
8617 | ||||
8618 | result = (bool)(arg1)->end_allow_threads(); | |||
8619 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
8620 | return SWIG_arg; | |||
8621 | ||||
8622 | if(0) SWIG_fail{goto fail;}; | |||
8623 | ||||
8624 | fail: | |||
8625 | lua_error(L); | |||
8626 | return SWIG_arg; | |||
8627 | } | |||
8628 | ||||
8629 | ||||
8630 | static int _wrap_Session_check_hangup_hook(lua_State* L) { | |||
8631 | int SWIG_arg = 0; | |||
8632 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
8633 | ||||
8634 | SWIG_check_num_args("LUA::Session::check_hangup_hook",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::check_hangup_hook" ,1,1,lua_gettop(L)); goto fail;} | |||
8635 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::check_hangup_hook",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::check_hangup_hook",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
8636 | ||||
8637 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
8638 | SWIG_fail_ptr("Session_check_hangup_hook",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_check_hangup_hook",1,(swig_types[8] && swig_types [8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
8639 | } | |||
8640 | ||||
8641 | (arg1)->check_hangup_hook(); | |||
8642 | ||||
8643 | return SWIG_arg; | |||
8644 | ||||
8645 | if(0) SWIG_fail{goto fail;}; | |||
8646 | ||||
8647 | fail: | |||
8648 | lua_error(L); | |||
8649 | return SWIG_arg; | |||
8650 | } | |||
8651 | ||||
8652 | ||||
8653 | static int _wrap_Session_run_dtmf_callback(lua_State* L) { | |||
8654 | int SWIG_arg = 0; | |||
8655 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
8656 | void *arg2 = (void *) 0 ; | |||
8657 | switch_input_type_t arg3 ; | |||
8658 | switch_input_type_t *argp3 ; | |||
8659 | switch_status_t result; | |||
8660 | ||||
8661 | SWIG_check_num_args("LUA::Session::run_dtmf_callback",3,3)if (lua_gettop(L)<3 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::run_dtmf_callback" ,3,3,lua_gettop(L)); goto fail;} | |||
8662 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::run_dtmf_callback",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::run_dtmf_callback",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
8663 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("LUA::Session::run_dtmf_callback",2,"void *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::run_dtmf_callback",2,"void *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
8664 | if(!lua_isuserdata(L,3)) SWIG_fail_arg("LUA::Session::run_dtmf_callback",3,"switch_input_type_t"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::run_dtmf_callback",3,"switch_input_type_t",SWIG_Lua_typename (L,3)); goto fail;}; | |||
8665 | ||||
8666 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
8667 | SWIG_fail_ptr("Session_run_dtmf_callback",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_run_dtmf_callback",1,(swig_types[8] && swig_types [8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
8668 | } | |||
8669 | ||||
8670 | arg2=(void *)SWIG_MustGetPtr(L,2,0,0,2,"Session_run_dtmf_callback")SWIG_Lua_MustGetPtr(L,2, 0,0, 2,"Session_run_dtmf_callback"); | |||
8671 | ||||
8672 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,3,(void**)&argp3,SWIGTYPE_p_switch_input_type_t,0))(SWIG_Lua_ConvertPtr(L,3,(void**)&argp3,swig_types[24],0) >= 0)){ | |||
8673 | SWIG_fail_ptr("Session_run_dtmf_callback",3,SWIGTYPE_p_switch_input_type_t){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_run_dtmf_callback",3,(swig_types[24] && swig_types [24]->str)?swig_types[24]->str:"void*",SWIG_Lua_typename (L,3)); goto fail;}; | |||
8674 | } | |||
8675 | arg3 = *argp3; | |||
8676 | ||||
8677 | result = (arg1)->run_dtmf_callback(arg2,arg3); | |||
8678 | { | |||
8679 | switch_status_t * resultptr = new switch_status_t((const switch_status_t &) result); | |||
8680 | SWIG_NewPointerObj(L,(void *) resultptr,SWIGTYPE_p_switch_status_t,1)SWIG_Lua_NewPointerObj(L, (void *)(void *) resultptr, swig_types [28], 1); SWIG_arg++; | |||
8681 | } | |||
8682 | return SWIG_arg; | |||
8683 | ||||
8684 | if(0) SWIG_fail{goto fail;}; | |||
8685 | ||||
8686 | fail: | |||
8687 | lua_error(L); | |||
8688 | return SWIG_arg; | |||
8689 | } | |||
8690 | ||||
8691 | ||||
8692 | static int _wrap_Session_unsetInputCallback(lua_State* L) { | |||
8693 | int SWIG_arg = 0; | |||
8694 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
8695 | ||||
8696 | SWIG_check_num_args("LUA::Session::unsetInputCallback",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::unsetInputCallback" ,1,1,lua_gettop(L)); goto fail;} | |||
8697 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::unsetInputCallback",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::unsetInputCallback",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
8698 | ||||
8699 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
8700 | SWIG_fail_ptr("Session_unsetInputCallback",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_unsetInputCallback",1,(swig_types[8] && swig_types [8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
8701 | } | |||
8702 | ||||
8703 | (arg1)->unsetInputCallback(); | |||
8704 | ||||
8705 | return SWIG_arg; | |||
8706 | ||||
8707 | if(0) SWIG_fail{goto fail;}; | |||
8708 | ||||
8709 | fail: | |||
8710 | lua_error(L); | |||
8711 | return SWIG_arg; | |||
8712 | } | |||
8713 | ||||
8714 | ||||
8715 | static int _wrap_Session_setInputCallback__SWIG_0(lua_State* L) { | |||
8716 | int SWIG_arg = 0; | |||
8717 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
8718 | char *arg2 = (char *) 0 ; | |||
8719 | char *arg3 = (char *) 0 ; | |||
8720 | ||||
8721 | SWIG_check_num_args("LUA::Session::setInputCallback",3,3)if (lua_gettop(L)<3 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::setInputCallback" ,3,3,lua_gettop(L)); goto fail;} | |||
8722 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::setInputCallback",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::setInputCallback",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
8723 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::Session::setInputCallback",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::setInputCallback",2,"char *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
8724 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("LUA::Session::setInputCallback",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::setInputCallback",3,"char *",SWIG_Lua_typename (L,3)); goto fail;}; | |||
8725 | ||||
8726 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
8727 | SWIG_fail_ptr("Session_setInputCallback",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_setInputCallback",1,(swig_types[8] && swig_types [8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
8728 | } | |||
8729 | ||||
8730 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
8731 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
8732 | (arg1)->setInputCallback(arg2,arg3); | |||
8733 | ||||
8734 | return SWIG_arg; | |||
8735 | ||||
8736 | if(0) SWIG_fail{goto fail;}; | |||
8737 | ||||
8738 | fail: | |||
8739 | lua_error(L); | |||
8740 | return SWIG_arg; | |||
8741 | } | |||
8742 | ||||
8743 | ||||
8744 | static int _wrap_Session_setInputCallback__SWIG_1(lua_State* L) { | |||
8745 | int SWIG_arg = 0; | |||
8746 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
8747 | char *arg2 = (char *) 0 ; | |||
8748 | ||||
8749 | SWIG_check_num_args("LUA::Session::setInputCallback",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::setInputCallback" ,2,2,lua_gettop(L)); goto fail;} | |||
8750 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::setInputCallback",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::setInputCallback",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
8751 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::Session::setInputCallback",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::setInputCallback",2,"char *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
8752 | ||||
8753 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
8754 | SWIG_fail_ptr("Session_setInputCallback",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_setInputCallback",1,(swig_types[8] && swig_types [8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
8755 | } | |||
8756 | ||||
8757 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
8758 | (arg1)->setInputCallback(arg2); | |||
8759 | ||||
8760 | return SWIG_arg; | |||
8761 | ||||
8762 | if(0) SWIG_fail{goto fail;}; | |||
8763 | ||||
8764 | fail: | |||
8765 | lua_error(L); | |||
8766 | return SWIG_arg; | |||
8767 | } | |||
8768 | ||||
8769 | ||||
8770 | static int _wrap_Session_setInputCallback(lua_State* L) { | |||
8771 | int argc; | |||
8772 | int argv[4]={ | |||
8773 | 1,2,3,4 | |||
8774 | }; | |||
8775 | ||||
8776 | argc = lua_gettop(L); | |||
8777 | if (argc == 2) { | |||
8778 | int _v; | |||
8779 | { | |||
8780 | void *ptr; | |||
8781 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_LUA__Session, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[8 ],0)) { | |||
8782 | _v = 0; | |||
8783 | } else { | |||
8784 | _v = 1; | |||
8785 | } | |||
8786 | } | |||
8787 | if (_v) { | |||
8788 | { | |||
8789 | _v = SWIG_lua_isnilstring(L,argv[1]); | |||
8790 | } | |||
8791 | if (_v) { | |||
8792 | return _wrap_Session_setInputCallback__SWIG_1(L); | |||
8793 | } | |||
8794 | } | |||
8795 | } | |||
8796 | if (argc == 3) { | |||
8797 | int _v; | |||
8798 | { | |||
8799 | void *ptr; | |||
8800 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_LUA__Session, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[8 ],0)) { | |||
8801 | _v = 0; | |||
8802 | } else { | |||
8803 | _v = 1; | |||
8804 | } | |||
8805 | } | |||
8806 | if (_v) { | |||
8807 | { | |||
8808 | _v = SWIG_lua_isnilstring(L,argv[1]); | |||
8809 | } | |||
8810 | if (_v) { | |||
8811 | { | |||
8812 | _v = SWIG_lua_isnilstring(L,argv[2]); | |||
8813 | } | |||
8814 | if (_v) { | |||
8815 | return _wrap_Session_setInputCallback__SWIG_0(L); | |||
8816 | } | |||
8817 | } | |||
8818 | } | |||
8819 | } | |||
8820 | ||||
8821 | SWIG_Lua_pusherrstring(L,"Wrong arguments for overloaded function 'Session_setInputCallback'\n" | |||
8822 | " Possible C/C++ prototypes are:\n" | |||
8823 | " LUA::Session::setInputCallback(char *,char *)\n" | |||
8824 | " LUA::Session::setInputCallback(char *)\n"); | |||
8825 | lua_error(L);return 0; | |||
8826 | } | |||
8827 | ||||
8828 | ||||
8829 | static int _wrap_Session_setHangupHook__SWIG_0(lua_State* L) { | |||
8830 | int SWIG_arg = 0; | |||
8831 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
8832 | char *arg2 = (char *) 0 ; | |||
8833 | char *arg3 = (char *) 0 ; | |||
8834 | ||||
8835 | SWIG_check_num_args("LUA::Session::setHangupHook",3,3)if (lua_gettop(L)<3 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::setHangupHook" ,3,3,lua_gettop(L)); goto fail;} | |||
8836 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::setHangupHook",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::setHangupHook",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
8837 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::Session::setHangupHook",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::setHangupHook",2,"char *",SWIG_Lua_typename( L,2)); goto fail;}; | |||
8838 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("LUA::Session::setHangupHook",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::setHangupHook",3,"char *",SWIG_Lua_typename( L,3)); goto fail;}; | |||
8839 | ||||
8840 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
8841 | SWIG_fail_ptr("Session_setHangupHook",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_setHangupHook",1,(swig_types[8] && swig_types [8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
8842 | } | |||
8843 | ||||
8844 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
8845 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
8846 | (arg1)->setHangupHook(arg2,arg3); | |||
8847 | ||||
8848 | return SWIG_arg; | |||
8849 | ||||
8850 | if(0) SWIG_fail{goto fail;}; | |||
8851 | ||||
8852 | fail: | |||
8853 | lua_error(L); | |||
8854 | return SWIG_arg; | |||
8855 | } | |||
8856 | ||||
8857 | ||||
8858 | static int _wrap_Session_setHangupHook__SWIG_1(lua_State* L) { | |||
8859 | int SWIG_arg = 0; | |||
8860 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
8861 | char *arg2 = (char *) 0 ; | |||
8862 | ||||
8863 | SWIG_check_num_args("LUA::Session::setHangupHook",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::setHangupHook" ,2,2,lua_gettop(L)); goto fail;} | |||
8864 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::setHangupHook",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::setHangupHook",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
8865 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::Session::setHangupHook",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::setHangupHook",2,"char *",SWIG_Lua_typename( L,2)); goto fail;}; | |||
8866 | ||||
8867 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
8868 | SWIG_fail_ptr("Session_setHangupHook",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_setHangupHook",1,(swig_types[8] && swig_types [8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
8869 | } | |||
8870 | ||||
8871 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
8872 | (arg1)->setHangupHook(arg2); | |||
8873 | ||||
8874 | return SWIG_arg; | |||
8875 | ||||
8876 | if(0) SWIG_fail{goto fail;}; | |||
8877 | ||||
8878 | fail: | |||
8879 | lua_error(L); | |||
8880 | return SWIG_arg; | |||
8881 | } | |||
8882 | ||||
8883 | ||||
8884 | static int _wrap_Session_setHangupHook(lua_State* L) { | |||
8885 | int argc; | |||
8886 | int argv[4]={ | |||
8887 | 1,2,3,4 | |||
8888 | }; | |||
8889 | ||||
8890 | argc = lua_gettop(L); | |||
8891 | if (argc == 2) { | |||
8892 | int _v; | |||
8893 | { | |||
8894 | void *ptr; | |||
8895 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_LUA__Session, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[8 ],0)) { | |||
8896 | _v = 0; | |||
8897 | } else { | |||
8898 | _v = 1; | |||
8899 | } | |||
8900 | } | |||
8901 | if (_v) { | |||
8902 | { | |||
8903 | _v = SWIG_lua_isnilstring(L,argv[1]); | |||
8904 | } | |||
8905 | if (_v) { | |||
8906 | return _wrap_Session_setHangupHook__SWIG_1(L); | |||
8907 | } | |||
8908 | } | |||
8909 | } | |||
8910 | if (argc == 3) { | |||
8911 | int _v; | |||
8912 | { | |||
8913 | void *ptr; | |||
8914 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_LUA__Session, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[8 ],0)) { | |||
8915 | _v = 0; | |||
8916 | } else { | |||
8917 | _v = 1; | |||
8918 | } | |||
8919 | } | |||
8920 | if (_v) { | |||
8921 | { | |||
8922 | _v = SWIG_lua_isnilstring(L,argv[1]); | |||
8923 | } | |||
8924 | if (_v) { | |||
8925 | { | |||
8926 | _v = SWIG_lua_isnilstring(L,argv[2]); | |||
8927 | } | |||
8928 | if (_v) { | |||
8929 | return _wrap_Session_setHangupHook__SWIG_0(L); | |||
8930 | } | |||
8931 | } | |||
8932 | } | |||
8933 | } | |||
8934 | ||||
8935 | SWIG_Lua_pusherrstring(L,"Wrong arguments for overloaded function 'Session_setHangupHook'\n" | |||
8936 | " Possible C/C++ prototypes are:\n" | |||
8937 | " LUA::Session::setHangupHook(char *,char *)\n" | |||
8938 | " LUA::Session::setHangupHook(char *)\n"); | |||
8939 | lua_error(L);return 0; | |||
8940 | } | |||
8941 | ||||
8942 | ||||
8943 | static int _wrap_Session_ready(lua_State* L) { | |||
8944 | int SWIG_arg = 0; | |||
8945 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
8946 | bool result; | |||
8947 | ||||
8948 | SWIG_check_num_args("LUA::Session::ready",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::ready" ,1,1,lua_gettop(L)); goto fail;} | |||
8949 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::ready",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::ready",1,"LUA::Session *",SWIG_Lua_typename( L,1)); goto fail;}; | |||
8950 | ||||
8951 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
8952 | SWIG_fail_ptr("Session_ready",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_ready",1,(swig_types[8] && swig_types[8]-> str)?swig_types[8]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
8953 | } | |||
8954 | ||||
8955 | result = (bool)(arg1)->ready(); | |||
8956 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
8957 | return SWIG_arg; | |||
8958 | ||||
8959 | if(0) SWIG_fail{goto fail;}; | |||
8960 | ||||
8961 | fail: | |||
8962 | lua_error(L); | |||
8963 | return SWIG_arg; | |||
8964 | } | |||
8965 | ||||
8966 | ||||
8967 | static int _wrap_Session_originate(lua_State* L) { | |||
8968 | int SWIG_arg = 0; | |||
8969 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
8970 | CoreSession *arg2 = (CoreSession *) 0 ; | |||
8971 | char *arg3 = (char *) 0 ; | |||
8972 | int arg4 ; | |||
8973 | int result; | |||
8974 | ||||
8975 | SWIG_check_num_args("LUA::Session::originate",4,4)if (lua_gettop(L)<4 || lua_gettop(L)>4) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::originate" ,4,4,lua_gettop(L)); goto fail;} | |||
8976 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::originate",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::originate",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
8977 | if(!SWIG_isptrtype(L,2)(lua_isuserdata(L,2) || (lua_type(L, (2)) == 0))) SWIG_fail_arg("LUA::Session::originate",2,"CoreSession *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::originate",2,"CoreSession *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
8978 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("LUA::Session::originate",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::originate",3,"char *",SWIG_Lua_typename(L,3) ); goto fail;}; | |||
8979 | if(!lua_isnumber(L,4)) SWIG_fail_arg("LUA::Session::originate",4,"int"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::originate",4,"int",SWIG_Lua_typename(L,4)); goto fail;}; | |||
8980 | ||||
8981 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
8982 | SWIG_fail_ptr("Session_originate",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_originate",1,(swig_types[8] && swig_types[ 8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
8983 | } | |||
8984 | ||||
8985 | ||||
8986 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,2,(void**)&arg2,SWIGTYPE_p_CoreSession,0))(SWIG_Lua_ConvertPtr(L,2,(void**)&arg2,swig_types[1],0) >= 0)){ | |||
8987 | SWIG_fail_ptr("Session_originate",2,SWIGTYPE_p_CoreSession){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_originate",2,(swig_types[1] && swig_types[ 1]->str)?swig_types[1]->str:"void*",SWIG_Lua_typename(L ,2)); goto fail;}; | |||
8988 | } | |||
8989 | ||||
8990 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
8991 | arg4 = (int)lua_tonumber(L, 4)lua_tonumberx(L,4,__null); | |||
8992 | result = (int)(arg1)->originate(arg2,arg3,arg4); | |||
8993 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
8994 | return SWIG_arg; | |||
8995 | ||||
8996 | if(0) SWIG_fail{goto fail;}; | |||
8997 | ||||
8998 | fail: | |||
8999 | lua_error(L); | |||
9000 | return SWIG_arg; | |||
9001 | } | |||
9002 | ||||
9003 | ||||
9004 | static int _wrap_Session_cb_function_set(lua_State* L) { | |||
9005 | int SWIG_arg = 0; | |||
9006 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
9007 | char *arg2 = (char *) 0 ; | |||
9008 | ||||
9009 | SWIG_check_num_args("LUA::Session::cb_function",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::cb_function" ,2,2,lua_gettop(L)); goto fail;} | |||
9010 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::cb_function",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::cb_function",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
9011 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::Session::cb_function",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::cb_function",2,"char *",SWIG_Lua_typename(L, 2)); goto fail;}; | |||
9012 | ||||
9013 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
9014 | SWIG_fail_ptr("Session_cb_function_set",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_cb_function_set",1,(swig_types[8] && swig_types [8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
9015 | } | |||
9016 | ||||
9017 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
9018 | { | |||
9019 | delete [] arg1->cb_function; | |||
9020 | if (arg2) { | |||
9021 | arg1->cb_function = (char *) (new char[strlen((const char *)arg2)+1]); | |||
9022 | strcpy((char *)arg1->cb_function, (const char *)arg2); | |||
9023 | } else { | |||
9024 | arg1->cb_function = 0; | |||
9025 | } | |||
9026 | } | |||
9027 | ||||
9028 | return SWIG_arg; | |||
9029 | ||||
9030 | if(0) SWIG_fail{goto fail;}; | |||
9031 | ||||
9032 | fail: | |||
9033 | lua_error(L); | |||
9034 | return SWIG_arg; | |||
9035 | } | |||
9036 | ||||
9037 | ||||
9038 | static int _wrap_Session_cb_function_get(lua_State* L) { | |||
9039 | int SWIG_arg = 0; | |||
9040 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
9041 | char *result = 0 ; | |||
9042 | ||||
9043 | SWIG_check_num_args("LUA::Session::cb_function",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::cb_function" ,1,1,lua_gettop(L)); goto fail;} | |||
9044 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::cb_function",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::cb_function",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
9045 | ||||
9046 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
9047 | SWIG_fail_ptr("Session_cb_function_get",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_cb_function_get",1,(swig_types[8] && swig_types [8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
9048 | } | |||
9049 | ||||
9050 | result = (char *) ((arg1)->cb_function); | |||
9051 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
9052 | return SWIG_arg; | |||
9053 | ||||
9054 | if(0) SWIG_fail{goto fail;}; | |||
9055 | ||||
9056 | fail: | |||
9057 | lua_error(L); | |||
9058 | return SWIG_arg; | |||
9059 | } | |||
9060 | ||||
9061 | ||||
9062 | static int _wrap_Session_cb_arg_set(lua_State* L) { | |||
9063 | int SWIG_arg = 0; | |||
9064 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
9065 | char *arg2 = (char *) 0 ; | |||
9066 | ||||
9067 | SWIG_check_num_args("LUA::Session::cb_arg",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::cb_arg" ,2,2,lua_gettop(L)); goto fail;} | |||
9068 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::cb_arg",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::cb_arg",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
9069 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::Session::cb_arg",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::cb_arg",2,"char *",SWIG_Lua_typename(L,2)); goto fail;}; | |||
9070 | ||||
9071 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
9072 | SWIG_fail_ptr("Session_cb_arg_set",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_cb_arg_set",1,(swig_types[8] && swig_types [8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
9073 | } | |||
9074 | ||||
9075 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
9076 | { | |||
9077 | delete [] arg1->cb_arg; | |||
9078 | if (arg2) { | |||
9079 | arg1->cb_arg = (char *) (new char[strlen((const char *)arg2)+1]); | |||
9080 | strcpy((char *)arg1->cb_arg, (const char *)arg2); | |||
9081 | } else { | |||
9082 | arg1->cb_arg = 0; | |||
9083 | } | |||
9084 | } | |||
9085 | ||||
9086 | return SWIG_arg; | |||
9087 | ||||
9088 | if(0) SWIG_fail{goto fail;}; | |||
9089 | ||||
9090 | fail: | |||
9091 | lua_error(L); | |||
9092 | return SWIG_arg; | |||
9093 | } | |||
9094 | ||||
9095 | ||||
9096 | static int _wrap_Session_cb_arg_get(lua_State* L) { | |||
9097 | int SWIG_arg = 0; | |||
9098 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
9099 | char *result = 0 ; | |||
9100 | ||||
9101 | SWIG_check_num_args("LUA::Session::cb_arg",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::cb_arg" ,1,1,lua_gettop(L)); goto fail;} | |||
9102 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::cb_arg",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::cb_arg",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
9103 | ||||
9104 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
9105 | SWIG_fail_ptr("Session_cb_arg_get",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_cb_arg_get",1,(swig_types[8] && swig_types [8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
9106 | } | |||
9107 | ||||
9108 | result = (char *) ((arg1)->cb_arg); | |||
9109 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
9110 | return SWIG_arg; | |||
9111 | ||||
9112 | if(0) SWIG_fail{goto fail;}; | |||
9113 | ||||
9114 | fail: | |||
9115 | lua_error(L); | |||
9116 | return SWIG_arg; | |||
9117 | } | |||
9118 | ||||
9119 | ||||
9120 | static int _wrap_Session_hangup_func_str_set(lua_State* L) { | |||
9121 | int SWIG_arg = 0; | |||
9122 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
9123 | char *arg2 = (char *) 0 ; | |||
9124 | ||||
9125 | SWIG_check_num_args("LUA::Session::hangup_func_str",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::hangup_func_str" ,2,2,lua_gettop(L)); goto fail;} | |||
9126 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::hangup_func_str",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::hangup_func_str",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
9127 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::Session::hangup_func_str",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::hangup_func_str",2,"char *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
9128 | ||||
9129 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
9130 | SWIG_fail_ptr("Session_hangup_func_str_set",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_hangup_func_str_set",1,(swig_types[8] && swig_types [8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
9131 | } | |||
9132 | ||||
9133 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
9134 | { | |||
9135 | delete [] arg1->hangup_func_str; | |||
9136 | if (arg2) { | |||
9137 | arg1->hangup_func_str = (char *) (new char[strlen((const char *)arg2)+1]); | |||
9138 | strcpy((char *)arg1->hangup_func_str, (const char *)arg2); | |||
9139 | } else { | |||
9140 | arg1->hangup_func_str = 0; | |||
9141 | } | |||
9142 | } | |||
9143 | ||||
9144 | return SWIG_arg; | |||
9145 | ||||
9146 | if(0) SWIG_fail{goto fail;}; | |||
9147 | ||||
9148 | fail: | |||
9149 | lua_error(L); | |||
9150 | return SWIG_arg; | |||
9151 | } | |||
9152 | ||||
9153 | ||||
9154 | static int _wrap_Session_hangup_func_str_get(lua_State* L) { | |||
9155 | int SWIG_arg = 0; | |||
9156 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
9157 | char *result = 0 ; | |||
9158 | ||||
9159 | SWIG_check_num_args("LUA::Session::hangup_func_str",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::hangup_func_str" ,1,1,lua_gettop(L)); goto fail;} | |||
9160 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::hangup_func_str",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::hangup_func_str",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
9161 | ||||
9162 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
9163 | SWIG_fail_ptr("Session_hangup_func_str_get",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_hangup_func_str_get",1,(swig_types[8] && swig_types [8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
9164 | } | |||
9165 | ||||
9166 | result = (char *) ((arg1)->hangup_func_str); | |||
9167 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
9168 | return SWIG_arg; | |||
9169 | ||||
9170 | if(0) SWIG_fail{goto fail;}; | |||
9171 | ||||
9172 | fail: | |||
9173 | lua_error(L); | |||
9174 | return SWIG_arg; | |||
9175 | } | |||
9176 | ||||
9177 | ||||
9178 | static int _wrap_Session_hangup_func_arg_set(lua_State* L) { | |||
9179 | int SWIG_arg = 0; | |||
9180 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
9181 | char *arg2 = (char *) 0 ; | |||
9182 | ||||
9183 | SWIG_check_num_args("LUA::Session::hangup_func_arg",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::hangup_func_arg" ,2,2,lua_gettop(L)); goto fail;} | |||
9184 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::hangup_func_arg",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::hangup_func_arg",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
9185 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::Session::hangup_func_arg",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::hangup_func_arg",2,"char *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
9186 | ||||
9187 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
9188 | SWIG_fail_ptr("Session_hangup_func_arg_set",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_hangup_func_arg_set",1,(swig_types[8] && swig_types [8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
9189 | } | |||
9190 | ||||
9191 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
9192 | { | |||
9193 | delete [] arg1->hangup_func_arg; | |||
9194 | if (arg2) { | |||
9195 | arg1->hangup_func_arg = (char *) (new char[strlen((const char *)arg2)+1]); | |||
9196 | strcpy((char *)arg1->hangup_func_arg, (const char *)arg2); | |||
9197 | } else { | |||
9198 | arg1->hangup_func_arg = 0; | |||
9199 | } | |||
9200 | } | |||
9201 | ||||
9202 | return SWIG_arg; | |||
9203 | ||||
9204 | if(0) SWIG_fail{goto fail;}; | |||
9205 | ||||
9206 | fail: | |||
9207 | lua_error(L); | |||
9208 | return SWIG_arg; | |||
9209 | } | |||
9210 | ||||
9211 | ||||
9212 | static int _wrap_Session_hangup_func_arg_get(lua_State* L) { | |||
9213 | int SWIG_arg = 0; | |||
9214 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
9215 | char *result = 0 ; | |||
9216 | ||||
9217 | SWIG_check_num_args("LUA::Session::hangup_func_arg",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::hangup_func_arg" ,1,1,lua_gettop(L)); goto fail;} | |||
9218 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::hangup_func_arg",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::hangup_func_arg",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
9219 | ||||
9220 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
9221 | SWIG_fail_ptr("Session_hangup_func_arg_get",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_hangup_func_arg_get",1,(swig_types[8] && swig_types [8]->str)?swig_types[8]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
9222 | } | |||
9223 | ||||
9224 | result = (char *) ((arg1)->hangup_func_arg); | |||
9225 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
9226 | return SWIG_arg; | |||
9227 | ||||
9228 | if(0) SWIG_fail{goto fail;}; | |||
9229 | ||||
9230 | fail: | |||
9231 | lua_error(L); | |||
9232 | return SWIG_arg; | |||
9233 | } | |||
9234 | ||||
9235 | ||||
9236 | static int _wrap_Session_setLUA(lua_State* L) { | |||
9237 | int SWIG_arg = 0; | |||
9238 | LUA::Session *arg1 = (LUA::Session *) 0 ; | |||
9239 | lua_State *arg2 = (lua_State *) 0 ; | |||
9240 | ||||
9241 | arg2 = L; | |||
9242 | SWIG_check_num_args("LUA::Session::setLUA",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Session::setLUA" ,1,1,lua_gettop(L)); goto fail;} | |||
9243 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Session::setLUA",1,"LUA::Session *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Session::setLUA",1,"LUA::Session *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
9244 | ||||
9245 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Session,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[8],0) >= 0)){ | |||
9246 | SWIG_fail_ptr("Session_setLUA",1,SWIGTYPE_p_LUA__Session){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Session_setLUA",1,(swig_types[8] && swig_types[8]-> str)?swig_types[8]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
9247 | } | |||
9248 | ||||
9249 | (arg1)->setLUA(arg2); | |||
9250 | ||||
9251 | return SWIG_arg; | |||
9252 | ||||
9253 | if(0) SWIG_fail{goto fail;}; | |||
9254 | ||||
9255 | fail: | |||
9256 | lua_error(L); | |||
9257 | return SWIG_arg; | |||
9258 | } | |||
9259 | ||||
9260 | ||||
9261 | static void swig_delete_Session(void *obj) { | |||
9262 | LUA::Session *arg1 = (LUA::Session *) obj; | |||
9263 | delete arg1; | |||
9264 | } | |||
9265 | static int _proxy__wrap_new_Session(lua_State *L) { | |||
9266 | assert(lua_istable(L,1))(static_cast <bool> ((lua_type(L, (1)) == 5)) ? void (0 ) : __assert_fail ("lua_istable(L,1)", "mod_lua_wrap.cpp", 9266 , __extension__ __PRETTY_FUNCTION__)); | |||
9267 | lua_pushcfunction(L,_wrap_new_Session)lua_pushcclosure(L, (_wrap_new_Session), 0); | |||
9268 | assert(!lua_isnil(L,-1))(static_cast <bool> (!(lua_type(L, (-1)) == 0)) ? void ( 0) : __assert_fail ("!lua_isnil(L,-1)", "mod_lua_wrap.cpp", 9268 , __extension__ __PRETTY_FUNCTION__)); | |||
9269 | lua_replace(L,1); /* replace our table with real constructor */ | |||
9270 | lua_call(L,lua_gettop(L)-1,1)lua_callk(L, (lua_gettop(L)-1), (1), 0, __null); | |||
9271 | return 1; | |||
9272 | } | |||
9273 | static swig_lua_attribute swig_Session_attributes[] = { | |||
9274 | { "cb_function", _wrap_Session_cb_function_get, _wrap_Session_cb_function_set }, | |||
9275 | { "cb_arg", _wrap_Session_cb_arg_get, _wrap_Session_cb_arg_set }, | |||
9276 | { "hangup_func_str", _wrap_Session_hangup_func_str_get, _wrap_Session_hangup_func_str_set }, | |||
9277 | { "hangup_func_arg", _wrap_Session_hangup_func_arg_get, _wrap_Session_hangup_func_arg_set }, | |||
9278 | {0,0,0} | |||
9279 | }; | |||
9280 | static swig_lua_method swig_Session_methods[]= { | |||
9281 | { "destroy", _wrap_Session_destroy}, | |||
9282 | { "begin_allow_threads", _wrap_Session_begin_allow_threads}, | |||
9283 | { "end_allow_threads", _wrap_Session_end_allow_threads}, | |||
9284 | { "check_hangup_hook", _wrap_Session_check_hangup_hook}, | |||
9285 | { "run_dtmf_callback", _wrap_Session_run_dtmf_callback}, | |||
9286 | { "unsetInputCallback", _wrap_Session_unsetInputCallback}, | |||
9287 | { "setInputCallback", _wrap_Session_setInputCallback}, | |||
9288 | { "setHangupHook", _wrap_Session_setHangupHook}, | |||
9289 | { "ready", _wrap_Session_ready}, | |||
9290 | { "originate", _wrap_Session_originate}, | |||
9291 | { "setLUA", _wrap_Session_setLUA}, | |||
9292 | {0,0} | |||
9293 | }; | |||
9294 | static swig_lua_method swig_Session_meta[] = { | |||
9295 | {0,0} | |||
9296 | }; | |||
9297 | ||||
9298 | static swig_lua_attribute swig_Session_Sf_SwigStatic_attributes[] = { | |||
9299 | {0,0,0} | |||
9300 | }; | |||
9301 | static swig_lua_const_info swig_Session_Sf_SwigStatic_constants[]= { | |||
9302 | {0,0,0,0,0,0} | |||
9303 | }; | |||
9304 | static swig_lua_method swig_Session_Sf_SwigStatic_methods[]= { | |||
9305 | {0,0} | |||
9306 | }; | |||
9307 | static swig_lua_class* swig_Session_Sf_SwigStatic_classes[]= { | |||
9308 | 0 | |||
9309 | }; | |||
9310 | ||||
9311 | static swig_lua_namespace swig_Session_Sf_SwigStatic = { | |||
9312 | "Session", | |||
9313 | swig_Session_Sf_SwigStatic_methods, | |||
9314 | swig_Session_Sf_SwigStatic_attributes, | |||
9315 | swig_Session_Sf_SwigStatic_constants, | |||
9316 | swig_Session_Sf_SwigStatic_classes, | |||
9317 | 0 | |||
9318 | }; | |||
9319 | static swig_lua_class *swig_Session_bases[] = {0,0}; | |||
9320 | static const char *swig_Session_base_names[] = {"CoreSession *",0}; | |||
9321 | static swig_lua_class _wrap_class_Session = { "Session", "Session", &SWIGTYPE_p_LUA__Sessionswig_types[8],_proxy__wrap_new_Session, swig_delete_Session, swig_Session_methods, swig_Session_attributes, &swig_Session_Sf_SwigStatic, swig_Session_meta, swig_Session_bases, swig_Session_base_names }; | |||
9322 | ||||
9323 | static int _wrap_new_Dbh__SWIG_0(lua_State* L) { | |||
9324 | int SWIG_arg = 0; | |||
9325 | char *arg1 = (char *) 0 ; | |||
9326 | char *arg2 = (char *) 0 ; | |||
9327 | char *arg3 = (char *) 0 ; | |||
9328 | LUA::Dbh *result = 0 ; | |||
9329 | ||||
9330 | SWIG_check_num_args("LUA::Dbh::Dbh",3,3)if (lua_gettop(L)<3 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Dbh::Dbh" ,3,3,lua_gettop(L)); goto fail;} | |||
9331 | if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("LUA::Dbh::Dbh",1,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::Dbh",1,"char *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
9332 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::Dbh::Dbh",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::Dbh",2,"char *",SWIG_Lua_typename(L,2)); goto fail ;}; | |||
9333 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("LUA::Dbh::Dbh",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::Dbh",3,"char *",SWIG_Lua_typename(L,3)); goto fail ;}; | |||
9334 | arg1 = (char *)lua_tostring(L, 1)lua_tolstring(L, (1), __null); | |||
9335 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
9336 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
9337 | result = (LUA::Dbh *)new LUA::Dbh(arg1,arg2,arg3); | |||
9338 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_LUA__Dbh,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[6], 1); SWIG_arg++; | |||
9339 | return SWIG_arg; | |||
9340 | ||||
9341 | if(0) SWIG_fail{goto fail;}; | |||
9342 | ||||
9343 | fail: | |||
9344 | lua_error(L); | |||
9345 | return SWIG_arg; | |||
9346 | } | |||
9347 | ||||
9348 | ||||
9349 | static int _wrap_new_Dbh__SWIG_1(lua_State* L) { | |||
9350 | int SWIG_arg = 0; | |||
9351 | char *arg1 = (char *) 0 ; | |||
9352 | char *arg2 = (char *) 0 ; | |||
9353 | LUA::Dbh *result = 0 ; | |||
9354 | ||||
9355 | SWIG_check_num_args("LUA::Dbh::Dbh",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Dbh::Dbh" ,2,2,lua_gettop(L)); goto fail;} | |||
9356 | if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("LUA::Dbh::Dbh",1,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::Dbh",1,"char *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
9357 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::Dbh::Dbh",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::Dbh",2,"char *",SWIG_Lua_typename(L,2)); goto fail ;}; | |||
9358 | arg1 = (char *)lua_tostring(L, 1)lua_tolstring(L, (1), __null); | |||
9359 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
9360 | result = (LUA::Dbh *)new LUA::Dbh(arg1,arg2); | |||
9361 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_LUA__Dbh,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[6], 1); SWIG_arg++; | |||
9362 | return SWIG_arg; | |||
9363 | ||||
9364 | if(0) SWIG_fail{goto fail;}; | |||
9365 | ||||
9366 | fail: | |||
9367 | lua_error(L); | |||
9368 | return SWIG_arg; | |||
9369 | } | |||
9370 | ||||
9371 | ||||
9372 | static int _wrap_new_Dbh__SWIG_2(lua_State* L) { | |||
9373 | int SWIG_arg = 0; | |||
9374 | char *arg1 = (char *) 0 ; | |||
9375 | LUA::Dbh *result = 0 ; | |||
9376 | ||||
9377 | SWIG_check_num_args("LUA::Dbh::Dbh",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Dbh::Dbh" ,1,1,lua_gettop(L)); goto fail;} | |||
9378 | if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("LUA::Dbh::Dbh",1,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::Dbh",1,"char *",SWIG_Lua_typename(L,1)); goto fail ;}; | |||
9379 | arg1 = (char *)lua_tostring(L, 1)lua_tolstring(L, (1), __null); | |||
9380 | result = (LUA::Dbh *)new LUA::Dbh(arg1); | |||
9381 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_LUA__Dbh,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[6], 1); SWIG_arg++; | |||
9382 | return SWIG_arg; | |||
9383 | ||||
9384 | if(0) SWIG_fail{goto fail;}; | |||
9385 | ||||
9386 | fail: | |||
9387 | lua_error(L); | |||
9388 | return SWIG_arg; | |||
9389 | } | |||
9390 | ||||
9391 | ||||
9392 | static int _wrap_new_Dbh(lua_State* L) { | |||
9393 | int argc; | |||
9394 | int argv[4]={ | |||
9395 | 1,2,3,4 | |||
9396 | }; | |||
9397 | ||||
9398 | argc = lua_gettop(L); | |||
9399 | if (argc == 1) { | |||
9400 | int _v; | |||
9401 | { | |||
9402 | _v = SWIG_lua_isnilstring(L,argv[0]); | |||
9403 | } | |||
9404 | if (_v) { | |||
9405 | return _wrap_new_Dbh__SWIG_2(L); | |||
9406 | } | |||
9407 | } | |||
9408 | if (argc == 2) { | |||
9409 | int _v; | |||
9410 | { | |||
9411 | _v = SWIG_lua_isnilstring(L,argv[0]); | |||
9412 | } | |||
9413 | if (_v) { | |||
9414 | { | |||
9415 | _v = SWIG_lua_isnilstring(L,argv[1]); | |||
9416 | } | |||
9417 | if (_v) { | |||
9418 | return _wrap_new_Dbh__SWIG_1(L); | |||
9419 | } | |||
9420 | } | |||
9421 | } | |||
9422 | if (argc == 3) { | |||
9423 | int _v; | |||
9424 | { | |||
9425 | _v = SWIG_lua_isnilstring(L,argv[0]); | |||
9426 | } | |||
9427 | if (_v) { | |||
9428 | { | |||
9429 | _v = SWIG_lua_isnilstring(L,argv[1]); | |||
9430 | } | |||
9431 | if (_v) { | |||
9432 | { | |||
9433 | _v = SWIG_lua_isnilstring(L,argv[2]); | |||
9434 | } | |||
9435 | if (_v) { | |||
9436 | return _wrap_new_Dbh__SWIG_0(L); | |||
9437 | } | |||
9438 | } | |||
9439 | } | |||
9440 | } | |||
9441 | ||||
9442 | SWIG_Lua_pusherrstring(L,"Wrong arguments for overloaded function 'new_Dbh'\n" | |||
9443 | " Possible C/C++ prototypes are:\n" | |||
9444 | " LUA::Dbh::Dbh(char *,char *,char *)\n" | |||
9445 | " LUA::Dbh::Dbh(char *,char *)\n" | |||
9446 | " LUA::Dbh::Dbh(char *)\n"); | |||
9447 | lua_error(L);return 0; | |||
9448 | } | |||
9449 | ||||
9450 | ||||
9451 | static int _wrap_Dbh_release(lua_State* L) { | |||
9452 | int SWIG_arg = 0; | |||
9453 | LUA::Dbh *arg1 = (LUA::Dbh *) 0 ; | |||
9454 | bool result; | |||
9455 | ||||
9456 | SWIG_check_num_args("LUA::Dbh::release",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Dbh::release" ,1,1,lua_gettop(L)); goto fail;} | |||
9457 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Dbh::release",1,"LUA::Dbh *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::release",1,"LUA::Dbh *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
9458 | ||||
9459 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Dbh,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[6],0) >= 0)){ | |||
9460 | SWIG_fail_ptr("Dbh_release",1,SWIGTYPE_p_LUA__Dbh){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Dbh_release",1,(swig_types[6] && swig_types[6]-> str)?swig_types[6]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
9461 | } | |||
9462 | ||||
9463 | result = (bool)(arg1)->release(); | |||
9464 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
9465 | return SWIG_arg; | |||
9466 | ||||
9467 | if(0) SWIG_fail{goto fail;}; | |||
9468 | ||||
9469 | fail: | |||
9470 | lua_error(L); | |||
9471 | return SWIG_arg; | |||
9472 | } | |||
9473 | ||||
9474 | ||||
9475 | static int _wrap_Dbh_connected(lua_State* L) { | |||
9476 | int SWIG_arg = 0; | |||
9477 | LUA::Dbh *arg1 = (LUA::Dbh *) 0 ; | |||
9478 | bool result; | |||
9479 | ||||
9480 | SWIG_check_num_args("LUA::Dbh::connected",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Dbh::connected" ,1,1,lua_gettop(L)); goto fail;} | |||
9481 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Dbh::connected",1,"LUA::Dbh *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::connected",1,"LUA::Dbh *",SWIG_Lua_typename(L,1) ); goto fail;}; | |||
9482 | ||||
9483 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Dbh,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[6],0) >= 0)){ | |||
9484 | SWIG_fail_ptr("Dbh_connected",1,SWIGTYPE_p_LUA__Dbh){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Dbh_connected",1,(swig_types[6] && swig_types[6]-> str)?swig_types[6]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
9485 | } | |||
9486 | ||||
9487 | result = (bool)(arg1)->connected(); | |||
9488 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
9489 | return SWIG_arg; | |||
9490 | ||||
9491 | if(0) SWIG_fail{goto fail;}; | |||
9492 | ||||
9493 | fail: | |||
9494 | lua_error(L); | |||
9495 | return SWIG_arg; | |||
9496 | } | |||
9497 | ||||
9498 | ||||
9499 | static int _wrap_Dbh_test_reactive__SWIG_0(lua_State* L) { | |||
9500 | int SWIG_arg = 0; | |||
9501 | LUA::Dbh *arg1 = (LUA::Dbh *) 0 ; | |||
9502 | char *arg2 = (char *) 0 ; | |||
9503 | char *arg3 = (char *) 0 ; | |||
9504 | char *arg4 = (char *) 0 ; | |||
9505 | bool result; | |||
9506 | ||||
9507 | SWIG_check_num_args("LUA::Dbh::test_reactive",4,4)if (lua_gettop(L)<4 || lua_gettop(L)>4) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Dbh::test_reactive" ,4,4,lua_gettop(L)); goto fail;} | |||
9508 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Dbh::test_reactive",1,"LUA::Dbh *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::test_reactive",1,"LUA::Dbh *",SWIG_Lua_typename( L,1)); goto fail;}; | |||
9509 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::Dbh::test_reactive",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::test_reactive",2,"char *",SWIG_Lua_typename(L,2) ); goto fail;}; | |||
9510 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("LUA::Dbh::test_reactive",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::test_reactive",3,"char *",SWIG_Lua_typename(L,3) ); goto fail;}; | |||
9511 | if(!SWIG_lua_isnilstring(L,4)) SWIG_fail_arg("LUA::Dbh::test_reactive",4,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::test_reactive",4,"char *",SWIG_Lua_typename(L,4) ); goto fail;}; | |||
9512 | ||||
9513 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Dbh,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[6],0) >= 0)){ | |||
9514 | SWIG_fail_ptr("Dbh_test_reactive",1,SWIGTYPE_p_LUA__Dbh){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Dbh_test_reactive",1,(swig_types[6] && swig_types[ 6]->str)?swig_types[6]->str:"void*",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
9515 | } | |||
9516 | ||||
9517 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
9518 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
9519 | arg4 = (char *)lua_tostring(L, 4)lua_tolstring(L, (4), __null); | |||
9520 | switch_assert(arg1)(static_cast <bool> (arg1) ? void (0) : __assert_fail ( "arg1", "mod_lua_wrap.cpp", 9520, __extension__ __PRETTY_FUNCTION__ )); | |||
9521 | result = (bool)(arg1)->test_reactive(arg2,arg3,arg4); | |||
9522 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
9523 | return SWIG_arg; | |||
9524 | ||||
9525 | if(0) SWIG_fail{goto fail;}; | |||
9526 | ||||
9527 | fail: | |||
9528 | lua_error(L); | |||
9529 | return SWIG_arg; | |||
9530 | } | |||
9531 | ||||
9532 | ||||
9533 | static int _wrap_Dbh_test_reactive__SWIG_1(lua_State* L) { | |||
9534 | int SWIG_arg = 0; | |||
9535 | LUA::Dbh *arg1 = (LUA::Dbh *) 0 ; | |||
9536 | char *arg2 = (char *) 0 ; | |||
9537 | char *arg3 = (char *) 0 ; | |||
9538 | bool result; | |||
9539 | ||||
9540 | SWIG_check_num_args("LUA::Dbh::test_reactive",3,3)if (lua_gettop(L)<3 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Dbh::test_reactive" ,3,3,lua_gettop(L)); goto fail;} | |||
9541 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Dbh::test_reactive",1,"LUA::Dbh *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::test_reactive",1,"LUA::Dbh *",SWIG_Lua_typename( L,1)); goto fail;}; | |||
9542 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::Dbh::test_reactive",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::test_reactive",2,"char *",SWIG_Lua_typename(L,2) ); goto fail;}; | |||
9543 | if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("LUA::Dbh::test_reactive",3,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::test_reactive",3,"char *",SWIG_Lua_typename(L,3) ); goto fail;}; | |||
9544 | ||||
9545 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Dbh,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[6],0) >= 0)){ | |||
9546 | SWIG_fail_ptr("Dbh_test_reactive",1,SWIGTYPE_p_LUA__Dbh){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Dbh_test_reactive",1,(swig_types[6] && swig_types[ 6]->str)?swig_types[6]->str:"void*",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
9547 | } | |||
9548 | ||||
9549 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
9550 | arg3 = (char *)lua_tostring(L, 3)lua_tolstring(L, (3), __null); | |||
9551 | result = (bool)(arg1)->test_reactive(arg2,arg3); | |||
| ||||
9552 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
9553 | return SWIG_arg; | |||
9554 | ||||
9555 | if(0) SWIG_fail{goto fail;}; | |||
9556 | ||||
9557 | fail: | |||
9558 | lua_error(L); | |||
9559 | return SWIG_arg; | |||
9560 | } | |||
9561 | ||||
9562 | ||||
9563 | static int _wrap_Dbh_test_reactive__SWIG_2(lua_State* L) { | |||
9564 | int SWIG_arg = 0; | |||
9565 | LUA::Dbh *arg1 = (LUA::Dbh *) 0 ; | |||
9566 | char *arg2 = (char *) 0 ; | |||
9567 | bool result; | |||
9568 | ||||
9569 | SWIG_check_num_args("LUA::Dbh::test_reactive",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Dbh::test_reactive" ,2,2,lua_gettop(L)); goto fail;} | |||
9570 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Dbh::test_reactive",1,"LUA::Dbh *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::test_reactive",1,"LUA::Dbh *",SWIG_Lua_typename( L,1)); goto fail;}; | |||
9571 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::Dbh::test_reactive",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::test_reactive",2,"char *",SWIG_Lua_typename(L,2) ); goto fail;}; | |||
9572 | ||||
9573 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Dbh,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[6],0) >= 0)){ | |||
9574 | SWIG_fail_ptr("Dbh_test_reactive",1,SWIGTYPE_p_LUA__Dbh){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Dbh_test_reactive",1,(swig_types[6] && swig_types[ 6]->str)?swig_types[6]->str:"void*",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
9575 | } | |||
9576 | ||||
9577 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
9578 | result = (bool)(arg1)->test_reactive(arg2); | |||
9579 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
9580 | return SWIG_arg; | |||
9581 | ||||
9582 | if(0) SWIG_fail{goto fail;}; | |||
9583 | ||||
9584 | fail: | |||
9585 | lua_error(L); | |||
9586 | return SWIG_arg; | |||
9587 | } | |||
9588 | ||||
9589 | ||||
9590 | static int _wrap_Dbh_test_reactive(lua_State* L) { | |||
9591 | int argc; | |||
9592 | int argv[5]={ | |||
9593 | 1,2,3,4,5 | |||
9594 | }; | |||
9595 | ||||
9596 | argc = lua_gettop(L); | |||
9597 | if (argc == 2) { | |||
| ||||
9598 | int _v; | |||
9599 | { | |||
9600 | void *ptr; | |||
9601 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_LUA__Dbh, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[6 ],0)) { | |||
9602 | _v = 0; | |||
9603 | } else { | |||
9604 | _v = 1; | |||
9605 | } | |||
9606 | } | |||
9607 | if (_v) { | |||
9608 | { | |||
9609 | _v = SWIG_lua_isnilstring(L,argv[1]); | |||
9610 | } | |||
9611 | if (_v) { | |||
9612 | return _wrap_Dbh_test_reactive__SWIG_2(L); | |||
9613 | } | |||
9614 | } | |||
9615 | } | |||
9616 | if (argc == 3) { | |||
9617 | int _v; | |||
9618 | { | |||
9619 | void *ptr; | |||
9620 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_LUA__Dbh, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[6 ],0)) { | |||
9621 | _v = 0; | |||
9622 | } else { | |||
9623 | _v = 1; | |||
9624 | } | |||
9625 | } | |||
9626 | if (_v) { | |||
9627 | { | |||
9628 | _v = SWIG_lua_isnilstring(L,argv[1]); | |||
9629 | } | |||
9630 | if (_v) { | |||
9631 | { | |||
9632 | _v = SWIG_lua_isnilstring(L,argv[2]); | |||
9633 | } | |||
9634 | if (_v) { | |||
9635 | return _wrap_Dbh_test_reactive__SWIG_1(L); | |||
9636 | } | |||
9637 | } | |||
9638 | } | |||
9639 | } | |||
9640 | if (argc == 4) { | |||
9641 | int _v; | |||
9642 | { | |||
9643 | void *ptr; | |||
9644 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_LUA__Dbh, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[6 ],0)) { | |||
9645 | _v = 0; | |||
9646 | } else { | |||
9647 | _v = 1; | |||
9648 | } | |||
9649 | } | |||
9650 | if (_v) { | |||
9651 | { | |||
9652 | _v = SWIG_lua_isnilstring(L,argv[1]); | |||
9653 | } | |||
9654 | if (_v) { | |||
9655 | { | |||
9656 | _v = SWIG_lua_isnilstring(L,argv[2]); | |||
9657 | } | |||
9658 | if (_v) { | |||
9659 | { | |||
9660 | _v = SWIG_lua_isnilstring(L,argv[3]); | |||
9661 | } | |||
9662 | if (_v) { | |||
9663 | return _wrap_Dbh_test_reactive__SWIG_0(L); | |||
9664 | } | |||
9665 | } | |||
9666 | } | |||
9667 | } | |||
9668 | } | |||
9669 | ||||
9670 | SWIG_Lua_pusherrstring(L,"Wrong arguments for overloaded function 'Dbh_test_reactive'\n" | |||
9671 | " Possible C/C++ prototypes are:\n" | |||
9672 | " LUA::Dbh::test_reactive(char *,char *,char *)\n" | |||
9673 | " LUA::Dbh::test_reactive(char *,char *)\n" | |||
9674 | " LUA::Dbh::test_reactive(char *)\n"); | |||
9675 | lua_error(L);return 0; | |||
9676 | } | |||
9677 | ||||
9678 | ||||
9679 | static int _wrap_Dbh_query(lua_State* L) { | |||
9680 | int SWIG_arg = 0; | |||
9681 | LUA::Dbh *arg1 = (LUA::Dbh *) 0 ; | |||
9682 | char *arg2 = (char *) 0 ; | |||
9683 | SWIGLUA_FN arg3 ; | |||
9684 | bool result; | |||
9685 | ||||
9686 | { | |||
9687 | SWIGLUA_FN default_swiglua_fn = { | |||
9688 | 0 | |||
9689 | }; | |||
9690 | arg3 = default_swiglua_fn; | |||
9691 | } | |||
9692 | SWIG_check_num_args("LUA::Dbh::query",2,3)if (lua_gettop(L)<2 || lua_gettop(L)>3) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Dbh::query" ,2,3,lua_gettop(L)); goto fail;} | |||
9693 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Dbh::query",1,"LUA::Dbh *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::query",1,"LUA::Dbh *",SWIG_Lua_typename(L,1)); goto fail;}; | |||
9694 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::Dbh::query",2,"char *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::query",2,"char *",SWIG_Lua_typename(L,2)); goto fail ;}; | |||
9695 | if(lua_gettop(L)>=3 && !lua_isfunction(L,3)(lua_type(L, (3)) == 6)) SWIG_fail_arg("LUA::Dbh::query",3,"SWIGLUA_FN"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::query",3,"SWIGLUA_FN",SWIG_Lua_typename(L,3)); goto fail;}; | |||
9696 | ||||
9697 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Dbh,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[6],0) >= 0)){ | |||
9698 | SWIG_fail_ptr("Dbh_query",1,SWIGTYPE_p_LUA__Dbh){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Dbh_query",1,(swig_types[6] && swig_types[6]->str )?swig_types[6]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
9699 | } | |||
9700 | ||||
9701 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
9702 | if(lua_gettop(L)>=3){ | |||
9703 | { | |||
9704 | (&arg3)->L = L; | |||
9705 | (&arg3)->idx = 3; | |||
9706 | } | |||
9707 | } | |||
9708 | switch_assert(arg1)(static_cast <bool> (arg1) ? void (0) : __assert_fail ( "arg1", "mod_lua_wrap.cpp", 9708, __extension__ __PRETTY_FUNCTION__ )); | |||
9709 | result = (bool)(arg1)->query(arg2,arg3); | |||
9710 | lua_pushboolean(L,(int)(result!=0)); SWIG_arg++; | |||
9711 | return SWIG_arg; | |||
9712 | ||||
9713 | if(0) SWIG_fail{goto fail;}; | |||
9714 | ||||
9715 | fail: | |||
9716 | lua_error(L); | |||
9717 | return SWIG_arg; | |||
9718 | } | |||
9719 | ||||
9720 | ||||
9721 | static int _wrap_Dbh_affected_rows(lua_State* L) { | |||
9722 | int SWIG_arg = 0; | |||
9723 | LUA::Dbh *arg1 = (LUA::Dbh *) 0 ; | |||
9724 | int result; | |||
9725 | ||||
9726 | SWIG_check_num_args("LUA::Dbh::affected_rows",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Dbh::affected_rows" ,1,1,lua_gettop(L)); goto fail;} | |||
9727 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Dbh::affected_rows",1,"LUA::Dbh *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::affected_rows",1,"LUA::Dbh *",SWIG_Lua_typename( L,1)); goto fail;}; | |||
9728 | ||||
9729 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Dbh,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[6],0) >= 0)){ | |||
9730 | SWIG_fail_ptr("Dbh_affected_rows",1,SWIGTYPE_p_LUA__Dbh){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Dbh_affected_rows",1,(swig_types[6] && swig_types[ 6]->str)?swig_types[6]->str:"void*",SWIG_Lua_typename(L ,1)); goto fail;}; | |||
9731 | } | |||
9732 | switch_assert(arg1)(static_cast <bool> (arg1) ? void (0) : __assert_fail ( "arg1", "mod_lua_wrap.cpp", 9732, __extension__ __PRETTY_FUNCTION__ )); | |||
9733 | result = (int)(arg1)->affected_rows(); | |||
9734 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
9735 | return SWIG_arg; | |||
9736 | ||||
9737 | if(0) SWIG_fail{goto fail;}; | |||
9738 | ||||
9739 | fail: | |||
9740 | lua_error(L); | |||
9741 | return SWIG_arg; | |||
9742 | } | |||
9743 | ||||
9744 | ||||
9745 | static int _wrap_Dbh_last_error(lua_State* L) { | |||
9746 | int SWIG_arg = 0; | |||
9747 | LUA::Dbh *arg1 = (LUA::Dbh *) 0 ; | |||
9748 | char *result = 0 ; | |||
9749 | ||||
9750 | SWIG_check_num_args("LUA::Dbh::last_error",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Dbh::last_error" ,1,1,lua_gettop(L)); goto fail;} | |||
9751 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Dbh::last_error",1,"LUA::Dbh *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::last_error",1,"LUA::Dbh *",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
9752 | ||||
9753 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Dbh,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[6],0) >= 0)){ | |||
9754 | SWIG_fail_ptr("Dbh_last_error",1,SWIGTYPE_p_LUA__Dbh){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Dbh_last_error",1,(swig_types[6] && swig_types[6]-> str)?swig_types[6]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
9755 | } | |||
9756 | switch_assert(arg1)(static_cast <bool> (arg1) ? void (0) : __assert_fail ( "arg1", "mod_lua_wrap.cpp", 9756, __extension__ __PRETTY_FUNCTION__ )); | |||
9757 | result = (char *)(arg1)->last_error(); | |||
9758 | lua_pushstring(L,(const char *)result); SWIG_arg++; | |||
9759 | return SWIG_arg; | |||
9760 | ||||
9761 | if(0) SWIG_fail{goto fail;}; | |||
9762 | ||||
9763 | fail: | |||
9764 | lua_error(L); | |||
9765 | return SWIG_arg; | |||
9766 | } | |||
9767 | ||||
9768 | ||||
9769 | static int _wrap_Dbh_clear_error(lua_State* L) { | |||
9770 | int SWIG_arg = 0; | |||
9771 | LUA::Dbh *arg1 = (LUA::Dbh *) 0 ; | |||
9772 | ||||
9773 | SWIG_check_num_args("LUA::Dbh::clear_error",1,1)if (lua_gettop(L)<1 || lua_gettop(L)>1) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Dbh::clear_error" ,1,1,lua_gettop(L)); goto fail;} | |||
9774 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Dbh::clear_error",1,"LUA::Dbh *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::clear_error",1,"LUA::Dbh *",SWIG_Lua_typename(L, 1)); goto fail;}; | |||
9775 | ||||
9776 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Dbh,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[6],0) >= 0)){ | |||
9777 | SWIG_fail_ptr("Dbh_clear_error",1,SWIGTYPE_p_LUA__Dbh){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Dbh_clear_error",1,(swig_types[6] && swig_types[6] ->str)?swig_types[6]->str:"void*",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
9778 | } | |||
9779 | switch_assert(arg1)(static_cast <bool> (arg1) ? void (0) : __assert_fail ( "arg1", "mod_lua_wrap.cpp", 9779, __extension__ __PRETTY_FUNCTION__ )); | |||
9780 | (arg1)->clear_error(); | |||
9781 | ||||
9782 | return SWIG_arg; | |||
9783 | ||||
9784 | if(0) SWIG_fail{goto fail;}; | |||
9785 | ||||
9786 | fail: | |||
9787 | lua_error(L); | |||
9788 | return SWIG_arg; | |||
9789 | } | |||
9790 | ||||
9791 | ||||
9792 | static int _wrap_Dbh_load_extension(lua_State* L) { | |||
9793 | int SWIG_arg = 0; | |||
9794 | LUA::Dbh *arg1 = (LUA::Dbh *) 0 ; | |||
9795 | char *arg2 = (char *) 0 ; | |||
9796 | int result; | |||
9797 | ||||
9798 | SWIG_check_num_args("LUA::Dbh::load_extension",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::Dbh::load_extension" ,2,2,lua_gettop(L)); goto fail;} | |||
9799 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::Dbh::load_extension",1,"LUA::Dbh *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::load_extension",1,"LUA::Dbh *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
9800 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::Dbh::load_extension",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::Dbh::load_extension",2,"char const *",SWIG_Lua_typename (L,2)); goto fail;}; | |||
9801 | ||||
9802 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__Dbh,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[6],0) >= 0)){ | |||
9803 | SWIG_fail_ptr("Dbh_load_extension",1,SWIGTYPE_p_LUA__Dbh){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "Dbh_load_extension",1,(swig_types[6] && swig_types [6]->str)?swig_types[6]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
9804 | } | |||
9805 | ||||
9806 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
9807 | switch_assert(arg1)(static_cast <bool> (arg1) ? void (0) : __assert_fail ( "arg1", "mod_lua_wrap.cpp", 9807, __extension__ __PRETTY_FUNCTION__ )); | |||
9808 | result = (int)(arg1)->load_extension((char const *)arg2); | |||
9809 | lua_pushnumber(L, (lua_Number) result); SWIG_arg++; | |||
9810 | return SWIG_arg; | |||
9811 | ||||
9812 | if(0) SWIG_fail{goto fail;}; | |||
9813 | ||||
9814 | fail: | |||
9815 | lua_error(L); | |||
9816 | return SWIG_arg; | |||
9817 | } | |||
9818 | ||||
9819 | ||||
9820 | static void swig_delete_Dbh(void *obj) { | |||
9821 | LUA::Dbh *arg1 = (LUA::Dbh *) obj; | |||
9822 | delete arg1; | |||
9823 | } | |||
9824 | static int _proxy__wrap_new_Dbh(lua_State *L) { | |||
9825 | assert(lua_istable(L,1))(static_cast <bool> ((lua_type(L, (1)) == 5)) ? void (0 ) : __assert_fail ("lua_istable(L,1)", "mod_lua_wrap.cpp", 9825 , __extension__ __PRETTY_FUNCTION__)); | |||
9826 | lua_pushcfunction(L,_wrap_new_Dbh)lua_pushcclosure(L, (_wrap_new_Dbh), 0); | |||
9827 | assert(!lua_isnil(L,-1))(static_cast <bool> (!(lua_type(L, (-1)) == 0)) ? void ( 0) : __assert_fail ("!lua_isnil(L,-1)", "mod_lua_wrap.cpp", 9827 , __extension__ __PRETTY_FUNCTION__)); | |||
9828 | lua_replace(L,1); /* replace our table with real constructor */ | |||
9829 | lua_call(L,lua_gettop(L)-1,1)lua_callk(L, (lua_gettop(L)-1), (1), 0, __null); | |||
9830 | return 1; | |||
9831 | } | |||
9832 | static swig_lua_attribute swig_Dbh_attributes[] = { | |||
9833 | {0,0,0} | |||
9834 | }; | |||
9835 | static swig_lua_method swig_Dbh_methods[]= { | |||
9836 | { "release", _wrap_Dbh_release}, | |||
9837 | { "connected", _wrap_Dbh_connected}, | |||
9838 | { "test_reactive", _wrap_Dbh_test_reactive}, | |||
9839 | { "query", _wrap_Dbh_query}, | |||
9840 | { "affected_rows", _wrap_Dbh_affected_rows}, | |||
9841 | { "last_error", _wrap_Dbh_last_error}, | |||
9842 | { "clear_error", _wrap_Dbh_clear_error}, | |||
9843 | { "load_extension", _wrap_Dbh_load_extension}, | |||
9844 | {0,0} | |||
9845 | }; | |||
9846 | static swig_lua_method swig_Dbh_meta[] = { | |||
9847 | {0,0} | |||
9848 | }; | |||
9849 | ||||
9850 | static swig_lua_attribute swig_Dbh_Sf_SwigStatic_attributes[] = { | |||
9851 | {0,0,0} | |||
9852 | }; | |||
9853 | static swig_lua_const_info swig_Dbh_Sf_SwigStatic_constants[]= { | |||
9854 | {0,0,0,0,0,0} | |||
9855 | }; | |||
9856 | static swig_lua_method swig_Dbh_Sf_SwigStatic_methods[]= { | |||
9857 | {0,0} | |||
9858 | }; | |||
9859 | static swig_lua_class* swig_Dbh_Sf_SwigStatic_classes[]= { | |||
9860 | 0 | |||
9861 | }; | |||
9862 | ||||
9863 | static swig_lua_namespace swig_Dbh_Sf_SwigStatic = { | |||
9864 | "Dbh", | |||
9865 | swig_Dbh_Sf_SwigStatic_methods, | |||
9866 | swig_Dbh_Sf_SwigStatic_attributes, | |||
9867 | swig_Dbh_Sf_SwigStatic_constants, | |||
9868 | swig_Dbh_Sf_SwigStatic_classes, | |||
9869 | 0 | |||
9870 | }; | |||
9871 | static swig_lua_class *swig_Dbh_bases[] = {0}; | |||
9872 | static const char *swig_Dbh_base_names[] = {0}; | |||
9873 | static swig_lua_class _wrap_class_Dbh = { "Dbh", "Dbh", &SWIGTYPE_p_LUA__Dbhswig_types[6],_proxy__wrap_new_Dbh, swig_delete_Dbh, swig_Dbh_methods, swig_Dbh_attributes, &swig_Dbh_Sf_SwigStatic, swig_Dbh_meta, swig_Dbh_bases, swig_Dbh_base_names }; | |||
9874 | ||||
9875 | static int _wrap_new_JSON(lua_State* L) { | |||
9876 | int SWIG_arg = 0; | |||
9877 | LUA::JSON *result = 0 ; | |||
9878 | ||||
9879 | SWIG_check_num_args("LUA::JSON::JSON",0,0)if (lua_gettop(L)<0 || lua_gettop(L)>0) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::JSON::JSON" ,0,0,lua_gettop(L)); goto fail;} | |||
9880 | result = (LUA::JSON *)new LUA::JSON(); | |||
9881 | SWIG_NewPointerObj(L,result,SWIGTYPE_p_LUA__JSON,1)SWIG_Lua_NewPointerObj(L, (void *)result, swig_types[7], 1); SWIG_arg++; | |||
9882 | return SWIG_arg; | |||
9883 | ||||
9884 | if(0) SWIG_fail{goto fail;}; | |||
9885 | ||||
9886 | fail: | |||
9887 | lua_error(L); | |||
9888 | return SWIG_arg; | |||
9889 | } | |||
9890 | ||||
9891 | ||||
9892 | static int _wrap_JSON_decode(lua_State* L) { | |||
9893 | int SWIG_arg = 0; | |||
9894 | LUA::JSON *arg1 = (LUA::JSON *) 0 ; | |||
9895 | char *arg2 = (char *) 0 ; | |||
9896 | cJSON *result = 0 ; | |||
9897 | ||||
9898 | SWIG_check_num_args("LUA::JSON::decode",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::JSON::decode" ,2,2,lua_gettop(L)); goto fail;} | |||
9899 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::JSON::decode",1,"LUA::JSON *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::JSON::decode",1,"LUA::JSON *",SWIG_Lua_typename(L,1)) ; goto fail;}; | |||
9900 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::JSON::decode",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::JSON::decode",2,"char const *",SWIG_Lua_typename(L,2) ); goto fail;}; | |||
9901 | ||||
9902 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__JSON,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[7],0) >= 0)){ | |||
9903 | SWIG_fail_ptr("JSON_decode",1,SWIGTYPE_p_LUA__JSON){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "JSON_decode",1,(swig_types[7] && swig_types[7]-> str)?swig_types[7]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
9904 | } | |||
9905 | ||||
9906 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
9907 | switch_assert(arg1)(static_cast <bool> (arg1) ? void (0) : __assert_fail ( "arg1", "mod_lua_wrap.cpp", 9907, __extension__ __PRETTY_FUNCTION__ )); | |||
9908 | result = (cJSON *)(arg1)->decode((char const *)arg2); | |||
9909 | { | |||
9910 | SWIG_arg += LUA::JSON::cJSON2LuaTable(L, result); | |||
9911 | cJSON_Delete(result); | |||
9912 | } | |||
9913 | return SWIG_arg; | |||
9914 | ||||
9915 | if(0) SWIG_fail{goto fail;}; | |||
9916 | ||||
9917 | fail: | |||
9918 | lua_error(L); | |||
9919 | return SWIG_arg; | |||
9920 | } | |||
9921 | ||||
9922 | ||||
9923 | static int _wrap_JSON_encode(lua_State* L) { | |||
9924 | int SWIG_arg = 0; | |||
9925 | LUA::JSON *arg1 = (LUA::JSON *) 0 ; | |||
9926 | SWIGLUA_TABLE arg2 ; | |||
9927 | std::string result; | |||
9928 | ||||
9929 | SWIG_check_num_args("LUA::JSON::encode",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::JSON::encode" ,2,2,lua_gettop(L)); goto fail;} | |||
9930 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::JSON::encode",1,"LUA::JSON *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::JSON::encode",1,"LUA::JSON *",SWIG_Lua_typename(L,1)) ; goto fail;}; | |||
9931 | if(!lua_istable(L,2)(lua_type(L, (2)) == 5)) SWIG_fail_arg("LUA::JSON::encode",2,"SWIGLUA_TABLE"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::JSON::encode",2,"SWIGLUA_TABLE",SWIG_Lua_typename(L,2 )); goto fail;}; | |||
9932 | ||||
9933 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__JSON,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[7],0) >= 0)){ | |||
9934 | SWIG_fail_ptr("JSON_encode",1,SWIGTYPE_p_LUA__JSON){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "JSON_encode",1,(swig_types[7] && swig_types[7]-> str)?swig_types[7]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
9935 | } | |||
9936 | ||||
9937 | { | |||
9938 | (&arg2)->L = L; | |||
9939 | (&arg2)->idx = 2; | |||
9940 | } | |||
9941 | switch_assert(arg1)(static_cast <bool> (arg1) ? void (0) : __assert_fail ( "arg1", "mod_lua_wrap.cpp", 9941, __extension__ __PRETTY_FUNCTION__ )); | |||
9942 | result = (arg1)->encode(arg2); | |||
9943 | lua_pushlstring(L,(&result)->data(),(&result)->size()); SWIG_arg++; | |||
9944 | return SWIG_arg; | |||
9945 | ||||
9946 | if(0) SWIG_fail{goto fail;}; | |||
9947 | ||||
9948 | fail: | |||
9949 | lua_error(L); | |||
9950 | return SWIG_arg; | |||
9951 | } | |||
9952 | ||||
9953 | ||||
9954 | static int _wrap_JSON_execute__SWIG_0(lua_State* L) { | |||
9955 | int SWIG_arg = 0; | |||
9956 | LUA::JSON *arg1 = (LUA::JSON *) 0 ; | |||
9957 | char *arg2 = (char *) 0 ; | |||
9958 | cJSON *result = 0 ; | |||
9959 | ||||
9960 | SWIG_check_num_args("LUA::JSON::execute",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::JSON::execute" ,2,2,lua_gettop(L)); goto fail;} | |||
9961 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::JSON::execute",1,"LUA::JSON *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::JSON::execute",1,"LUA::JSON *",SWIG_Lua_typename(L,1) ); goto fail;}; | |||
9962 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::JSON::execute",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::JSON::execute",2,"char const *",SWIG_Lua_typename(L,2 )); goto fail;}; | |||
9963 | ||||
9964 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__JSON,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[7],0) >= 0)){ | |||
9965 | SWIG_fail_ptr("JSON_execute",1,SWIGTYPE_p_LUA__JSON){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "JSON_execute",1,(swig_types[7] && swig_types[7]-> str)?swig_types[7]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
9966 | } | |||
9967 | ||||
9968 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
9969 | switch_assert(arg1)(static_cast <bool> (arg1) ? void (0) : __assert_fail ( "arg1", "mod_lua_wrap.cpp", 9969, __extension__ __PRETTY_FUNCTION__ )); | |||
9970 | result = (cJSON *)(arg1)->execute((char const *)arg2); | |||
9971 | { | |||
9972 | SWIG_arg += LUA::JSON::cJSON2LuaTable(L, result); | |||
9973 | cJSON_Delete(result); | |||
9974 | } | |||
9975 | return SWIG_arg; | |||
9976 | ||||
9977 | if(0) SWIG_fail{goto fail;}; | |||
9978 | ||||
9979 | fail: | |||
9980 | lua_error(L); | |||
9981 | return SWIG_arg; | |||
9982 | } | |||
9983 | ||||
9984 | ||||
9985 | static int _wrap_JSON_execute__SWIG_1(lua_State* L) { | |||
9986 | int SWIG_arg = 0; | |||
9987 | LUA::JSON *arg1 = (LUA::JSON *) 0 ; | |||
9988 | SWIGLUA_TABLE arg2 ; | |||
9989 | cJSON *result = 0 ; | |||
9990 | ||||
9991 | SWIG_check_num_args("LUA::JSON::execute",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::JSON::execute" ,2,2,lua_gettop(L)); goto fail;} | |||
9992 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::JSON::execute",1,"LUA::JSON *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::JSON::execute",1,"LUA::JSON *",SWIG_Lua_typename(L,1) ); goto fail;}; | |||
9993 | if(!lua_istable(L,2)(lua_type(L, (2)) == 5)) SWIG_fail_arg("LUA::JSON::execute",2,"SWIGLUA_TABLE"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::JSON::execute",2,"SWIGLUA_TABLE",SWIG_Lua_typename(L, 2)); goto fail;}; | |||
9994 | ||||
9995 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__JSON,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[7],0) >= 0)){ | |||
9996 | SWIG_fail_ptr("JSON_execute",1,SWIGTYPE_p_LUA__JSON){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "JSON_execute",1,(swig_types[7] && swig_types[7]-> str)?swig_types[7]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
9997 | } | |||
9998 | ||||
9999 | { | |||
10000 | (&arg2)->L = L; | |||
10001 | (&arg2)->idx = 2; | |||
10002 | } | |||
10003 | switch_assert(arg1)(static_cast <bool> (arg1) ? void (0) : __assert_fail ( "arg1", "mod_lua_wrap.cpp", 10003, __extension__ __PRETTY_FUNCTION__ )); | |||
10004 | result = (cJSON *)(arg1)->execute(arg2); | |||
10005 | { | |||
10006 | SWIG_arg += LUA::JSON::cJSON2LuaTable(L, result); | |||
10007 | cJSON_Delete(result); | |||
10008 | } | |||
10009 | return SWIG_arg; | |||
10010 | ||||
10011 | if(0) SWIG_fail{goto fail;}; | |||
10012 | ||||
10013 | fail: | |||
10014 | lua_error(L); | |||
10015 | return SWIG_arg; | |||
10016 | } | |||
10017 | ||||
10018 | ||||
10019 | static int _wrap_JSON_execute(lua_State* L) { | |||
10020 | int argc; | |||
10021 | int argv[3]={ | |||
10022 | 1,2,3 | |||
10023 | }; | |||
10024 | ||||
10025 | argc = lua_gettop(L); | |||
10026 | if (argc == 2) { | |||
10027 | int _v; | |||
10028 | { | |||
10029 | void *ptr; | |||
10030 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_LUA__JSON, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[7 ],0)) { | |||
10031 | _v = 0; | |||
10032 | } else { | |||
10033 | _v = 1; | |||
10034 | } | |||
10035 | } | |||
10036 | if (_v) { | |||
10037 | { | |||
10038 | _v = SWIG_lua_isnilstring(L,argv[1]); | |||
10039 | } | |||
10040 | if (_v) { | |||
10041 | return _wrap_JSON_execute__SWIG_0(L); | |||
10042 | } | |||
10043 | } | |||
10044 | } | |||
10045 | if (argc == 2) { | |||
10046 | int _v; | |||
10047 | { | |||
10048 | void *ptr; | |||
10049 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_LUA__JSON, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[7 ],0)) { | |||
10050 | _v = 0; | |||
10051 | } else { | |||
10052 | _v = 1; | |||
10053 | } | |||
10054 | } | |||
10055 | if (_v) { | |||
10056 | { | |||
10057 | _v = lua_istable(L, argv[1])(lua_type(L, (argv[1])) == 5); | |||
10058 | } | |||
10059 | if (_v) { | |||
10060 | return _wrap_JSON_execute__SWIG_1(L); | |||
10061 | } | |||
10062 | } | |||
10063 | } | |||
10064 | ||||
10065 | SWIG_Lua_pusherrstring(L,"Wrong arguments for overloaded function 'JSON_execute'\n" | |||
10066 | " Possible C/C++ prototypes are:\n" | |||
10067 | " LUA::JSON::execute(char const *)\n" | |||
10068 | " LUA::JSON::execute(SWIGLUA_TABLE)\n"); | |||
10069 | lua_error(L);return 0; | |||
10070 | } | |||
10071 | ||||
10072 | ||||
10073 | static int _wrap_JSON_execute2__SWIG_0(lua_State* L) { | |||
10074 | int SWIG_arg = 0; | |||
10075 | LUA::JSON *arg1 = (LUA::JSON *) 0 ; | |||
10076 | char *arg2 = (char *) 0 ; | |||
10077 | std::string result; | |||
10078 | ||||
10079 | SWIG_check_num_args("LUA::JSON::execute2",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::JSON::execute2" ,2,2,lua_gettop(L)); goto fail;} | |||
10080 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::JSON::execute2",1,"LUA::JSON *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::JSON::execute2",1,"LUA::JSON *",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
10081 | if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("LUA::JSON::execute2",2,"char const *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::JSON::execute2",2,"char const *",SWIG_Lua_typename(L, 2)); goto fail;}; | |||
10082 | ||||
10083 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__JSON,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[7],0) >= 0)){ | |||
10084 | SWIG_fail_ptr("JSON_execute2",1,SWIGTYPE_p_LUA__JSON){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "JSON_execute2",1,(swig_types[7] && swig_types[7]-> str)?swig_types[7]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
10085 | } | |||
10086 | ||||
10087 | arg2 = (char *)lua_tostring(L, 2)lua_tolstring(L, (2), __null); | |||
10088 | switch_assert(arg1)(static_cast <bool> (arg1) ? void (0) : __assert_fail ( "arg1", "mod_lua_wrap.cpp", 10088, __extension__ __PRETTY_FUNCTION__ )); | |||
10089 | result = (arg1)->execute2((char const *)arg2); | |||
10090 | lua_pushlstring(L,(&result)->data(),(&result)->size()); SWIG_arg++; | |||
10091 | return SWIG_arg; | |||
10092 | ||||
10093 | if(0) SWIG_fail{goto fail;}; | |||
10094 | ||||
10095 | fail: | |||
10096 | lua_error(L); | |||
10097 | return SWIG_arg; | |||
10098 | } | |||
10099 | ||||
10100 | ||||
10101 | static int _wrap_JSON_execute2__SWIG_1(lua_State* L) { | |||
10102 | int SWIG_arg = 0; | |||
10103 | LUA::JSON *arg1 = (LUA::JSON *) 0 ; | |||
10104 | SWIGLUA_TABLE arg2 ; | |||
10105 | std::string result; | |||
10106 | ||||
10107 | SWIG_check_num_args("LUA::JSON::execute2",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::JSON::execute2" ,2,2,lua_gettop(L)); goto fail;} | |||
10108 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::JSON::execute2",1,"LUA::JSON *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::JSON::execute2",1,"LUA::JSON *",SWIG_Lua_typename(L,1 )); goto fail;}; | |||
10109 | if(!lua_istable(L,2)(lua_type(L, (2)) == 5)) SWIG_fail_arg("LUA::JSON::execute2",2,"SWIGLUA_TABLE"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::JSON::execute2",2,"SWIGLUA_TABLE",SWIG_Lua_typename(L ,2)); goto fail;}; | |||
10110 | ||||
10111 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__JSON,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[7],0) >= 0)){ | |||
10112 | SWIG_fail_ptr("JSON_execute2",1,SWIGTYPE_p_LUA__JSON){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "JSON_execute2",1,(swig_types[7] && swig_types[7]-> str)?swig_types[7]->str:"void*",SWIG_Lua_typename(L,1)); goto fail;}; | |||
10113 | } | |||
10114 | ||||
10115 | { | |||
10116 | (&arg2)->L = L; | |||
10117 | (&arg2)->idx = 2; | |||
10118 | } | |||
10119 | switch_assert(arg1)(static_cast <bool> (arg1) ? void (0) : __assert_fail ( "arg1", "mod_lua_wrap.cpp", 10119, __extension__ __PRETTY_FUNCTION__ )); | |||
10120 | result = (arg1)->execute2(arg2); | |||
10121 | lua_pushlstring(L,(&result)->data(),(&result)->size()); SWIG_arg++; | |||
10122 | return SWIG_arg; | |||
10123 | ||||
10124 | if(0) SWIG_fail{goto fail;}; | |||
10125 | ||||
10126 | fail: | |||
10127 | lua_error(L); | |||
10128 | return SWIG_arg; | |||
10129 | } | |||
10130 | ||||
10131 | ||||
10132 | static int _wrap_JSON_execute2(lua_State* L) { | |||
10133 | int argc; | |||
10134 | int argv[3]={ | |||
10135 | 1,2,3 | |||
10136 | }; | |||
10137 | ||||
10138 | argc = lua_gettop(L); | |||
10139 | if (argc == 2) { | |||
10140 | int _v; | |||
10141 | { | |||
10142 | void *ptr; | |||
10143 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_LUA__JSON, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[7 ],0)) { | |||
10144 | _v = 0; | |||
10145 | } else { | |||
10146 | _v = 1; | |||
10147 | } | |||
10148 | } | |||
10149 | if (_v) { | |||
10150 | { | |||
10151 | _v = SWIG_lua_isnilstring(L,argv[1]); | |||
10152 | } | |||
10153 | if (_v) { | |||
10154 | return _wrap_JSON_execute2__SWIG_0(L); | |||
10155 | } | |||
10156 | } | |||
10157 | } | |||
10158 | if (argc == 2) { | |||
10159 | int _v; | |||
10160 | { | |||
10161 | void *ptr; | |||
10162 | if (SWIG_isptrtype(L,argv[0])(lua_isuserdata(L,argv[0]) || (lua_type(L, (argv[0])) == 0))==0 || SWIG_ConvertPtr(L,argv[0], (void **) &ptr, SWIGTYPE_p_LUA__JSON, 0)SWIG_Lua_ConvertPtr(L,argv[0],(void **) &ptr,swig_types[7 ],0)) { | |||
10163 | _v = 0; | |||
10164 | } else { | |||
10165 | _v = 1; | |||
10166 | } | |||
10167 | } | |||
10168 | if (_v) { | |||
10169 | { | |||
10170 | _v = lua_istable(L, argv[1])(lua_type(L, (argv[1])) == 5); | |||
10171 | } | |||
10172 | if (_v) { | |||
10173 | return _wrap_JSON_execute2__SWIG_1(L); | |||
10174 | } | |||
10175 | } | |||
10176 | } | |||
10177 | ||||
10178 | SWIG_Lua_pusherrstring(L,"Wrong arguments for overloaded function 'JSON_execute2'\n" | |||
10179 | " Possible C/C++ prototypes are:\n" | |||
10180 | " LUA::JSON::execute2(char const *)\n" | |||
10181 | " LUA::JSON::execute2(SWIGLUA_TABLE)\n"); | |||
10182 | lua_error(L);return 0; | |||
10183 | } | |||
10184 | ||||
10185 | ||||
10186 | static int _wrap_JSON_encode_empty_table_as_object(lua_State* L) { | |||
10187 | int SWIG_arg = 0; | |||
10188 | LUA::JSON *arg1 = (LUA::JSON *) 0 ; | |||
10189 | bool arg2 ; | |||
10190 | ||||
10191 | SWIG_check_num_args("LUA::JSON::encode_empty_table_as_object",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::JSON::encode_empty_table_as_object" ,2,2,lua_gettop(L)); goto fail;} | |||
10192 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::JSON::encode_empty_table_as_object",1,"LUA::JSON *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::JSON::encode_empty_table_as_object",1,"LUA::JSON *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
10193 | if(!lua_isboolean(L,2)(lua_type(L, (2)) == 1)) SWIG_fail_arg("LUA::JSON::encode_empty_table_as_object",2,"bool"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::JSON::encode_empty_table_as_object",2,"bool",SWIG_Lua_typename (L,2)); goto fail;}; | |||
10194 | ||||
10195 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__JSON,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[7],0) >= 0)){ | |||
10196 | SWIG_fail_ptr("JSON_encode_empty_table_as_object",1,SWIGTYPE_p_LUA__JSON){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "JSON_encode_empty_table_as_object",1,(swig_types[7] && swig_types[7]->str)?swig_types[7]->str:"void*",SWIG_Lua_typename (L,1)); goto fail;}; | |||
10197 | } | |||
10198 | ||||
10199 | arg2 = (lua_toboolean(L, 2)!=0); | |||
10200 | switch_assert(arg1)(static_cast <bool> (arg1) ? void (0) : __assert_fail ( "arg1", "mod_lua_wrap.cpp", 10200, __extension__ __PRETTY_FUNCTION__ )); | |||
10201 | (arg1)->encode_empty_table_as_object(arg2); | |||
10202 | ||||
10203 | return SWIG_arg; | |||
10204 | ||||
10205 | if(0) SWIG_fail{goto fail;}; | |||
10206 | ||||
10207 | fail: | |||
10208 | lua_error(L); | |||
10209 | return SWIG_arg; | |||
10210 | } | |||
10211 | ||||
10212 | ||||
10213 | static int _wrap_JSON_return_unformatted_json(lua_State* L) { | |||
10214 | int SWIG_arg = 0; | |||
10215 | LUA::JSON *arg1 = (LUA::JSON *) 0 ; | |||
10216 | bool arg2 ; | |||
10217 | ||||
10218 | SWIG_check_num_args("LUA::JSON::return_unformatted_json",2,2)if (lua_gettop(L)<2 || lua_gettop(L)>2) {SWIG_Lua_pushferrstring (L,"Error in %s expected %d..%d args, got %d","LUA::JSON::return_unformatted_json" ,2,2,lua_gettop(L)); goto fail;} | |||
10219 | if(!SWIG_isptrtype(L,1)(lua_isuserdata(L,1) || (lua_type(L, (1)) == 0))) SWIG_fail_arg("LUA::JSON::return_unformatted_json",1,"LUA::JSON *"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::JSON::return_unformatted_json",1,"LUA::JSON *",SWIG_Lua_typename (L,1)); goto fail;}; | |||
10220 | if(!lua_isboolean(L,2)(lua_type(L, (2)) == 1)) SWIG_fail_arg("LUA::JSON::return_unformatted_json",2,"bool"){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "LUA::JSON::return_unformatted_json",2,"bool",SWIG_Lua_typename (L,2)); goto fail;}; | |||
10221 | ||||
10222 | if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_LUA__JSON,0))(SWIG_Lua_ConvertPtr(L,1,(void**)&arg1,swig_types[7],0) >= 0)){ | |||
10223 | SWIG_fail_ptr("JSON_return_unformatted_json",1,SWIGTYPE_p_LUA__JSON){SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'" , "JSON_return_unformatted_json",1,(swig_types[7] && swig_types [7]->str)?swig_types[7]->str:"void*",SWIG_Lua_typename( L,1)); goto fail;}; | |||
10224 | } | |||
10225 | ||||
10226 | arg2 = (lua_toboolean(L, 2)!=0); | |||
10227 | switch_assert(arg1)(static_cast <bool> (arg1) ? void (0) : __assert_fail ( "arg1", "mod_lua_wrap.cpp", 10227, __extension__ __PRETTY_FUNCTION__ )); | |||
10228 | (arg1)->return_unformatted_json(arg2); | |||
10229 | ||||
10230 | return SWIG_arg; | |||
10231 | ||||
10232 | if(0) SWIG_fail{goto fail;}; | |||
10233 | ||||
10234 | fail: | |||
10235 | lua_error(L); | |||
10236 | return SWIG_arg; | |||
10237 | } | |||
10238 | ||||
10239 | ||||
10240 | static void swig_delete_JSON(void *obj) { | |||
10241 | LUA::JSON *arg1 = (LUA::JSON *) obj; | |||
10242 | delete arg1; | |||
10243 | } | |||
10244 | static int _proxy__wrap_new_JSON(lua_State *L) { | |||
10245 | assert(lua_istable(L,1))(static_cast <bool> ((lua_type(L, (1)) == 5)) ? void (0 ) : __assert_fail ("lua_istable(L,1)", "mod_lua_wrap.cpp", 10245 , __extension__ __PRETTY_FUNCTION__)); | |||
10246 | lua_pushcfunction(L,_wrap_new_JSON)lua_pushcclosure(L, (_wrap_new_JSON), 0); | |||
10247 | assert(!lua_isnil(L,-1))(static_cast <bool> (!(lua_type(L, (-1)) == 0)) ? void ( 0) : __assert_fail ("!lua_isnil(L,-1)", "mod_lua_wrap.cpp", 10247 , __extension__ __PRETTY_FUNCTION__)); | |||
10248 | lua_replace(L,1); /* replace our table with real constructor */ | |||
10249 | lua_call(L,lua_gettop(L)-1,1)lua_callk(L, (lua_gettop(L)-1), (1), 0, __null); | |||
10250 | return 1; | |||
10251 | } | |||
10252 | static swig_lua_attribute swig_JSON_attributes[] = { | |||
10253 | {0,0,0} | |||
10254 | }; | |||
10255 | static swig_lua_method swig_JSON_methods[]= { | |||
10256 | { "decode", _wrap_JSON_decode}, | |||
10257 | { "encode", _wrap_JSON_encode}, | |||
10258 | { "execute", _wrap_JSON_execute}, | |||
10259 | { "execute2", _wrap_JSON_execute2}, | |||
10260 | { "encode_empty_table_as_object", _wrap_JSON_encode_empty_table_as_object}, | |||
10261 | { "return_unformatted_json", _wrap_JSON_return_unformatted_json}, | |||
10262 | {0,0} | |||
10263 | }; | |||
10264 | static swig_lua_method swig_JSON_meta[] = { | |||
10265 | {0,0} | |||
10266 | }; | |||
10267 | ||||
10268 | static swig_lua_attribute swig_JSON_Sf_SwigStatic_attributes[] = { | |||
10269 | {0,0,0} | |||
10270 | }; | |||
10271 | static swig_lua_const_info swig_JSON_Sf_SwigStatic_constants[]= { | |||
10272 | {0,0,0,0,0,0} | |||
10273 | }; | |||
10274 | static swig_lua_method swig_JSON_Sf_SwigStatic_methods[]= { | |||
10275 | {0,0} | |||
10276 | }; | |||
10277 | static swig_lua_class* swig_JSON_Sf_SwigStatic_classes[]= { | |||
10278 | 0 | |||
10279 | }; | |||
10280 | ||||
10281 | static swig_lua_namespace swig_JSON_Sf_SwigStatic = { | |||
10282 | "JSON", | |||
10283 | swig_JSON_Sf_SwigStatic_methods, | |||
10284 | swig_JSON_Sf_SwigStatic_attributes, | |||
10285 | swig_JSON_Sf_SwigStatic_constants, | |||
10286 | swig_JSON_Sf_SwigStatic_classes, | |||
10287 | 0 | |||
10288 | }; | |||
10289 | static swig_lua_class *swig_JSON_bases[] = {0}; | |||
10290 | static const char *swig_JSON_base_names[] = {0}; | |||
10291 | static swig_lua_class _wrap_class_JSON = { "JSON", "JSON", &SWIGTYPE_p_LUA__JSONswig_types[7],_proxy__wrap_new_JSON, swig_delete_JSON, swig_JSON_methods, swig_JSON_attributes, &swig_JSON_Sf_SwigStatic, swig_JSON_meta, swig_JSON_bases, swig_JSON_base_names }; | |||
10292 | ||||
10293 | static swig_lua_attribute swig_SwigModule_attributes[] = { | |||
10294 | {0,0,0} | |||
10295 | }; | |||
10296 | static swig_lua_const_info swig_SwigModule_constants[]= { | |||
10297 | {SWIG_LUA_CONSTTAB_INT("S_HUP", S_HUP)1, (char *)"S_HUP", (long)S_HUP, 0, 0, 0}, | |||
10298 | {SWIG_LUA_CONSTTAB_INT("S_FREE", S_FREE)1, (char *)"S_FREE", (long)S_FREE, 0, 0, 0}, | |||
10299 | {SWIG_LUA_CONSTTAB_INT("S_RDLOCK", S_RDLOCK)1, (char *)"S_RDLOCK", (long)S_RDLOCK, 0, 0, 0}, | |||
10300 | {0,0,0,0,0,0} | |||
10301 | }; | |||
10302 | static swig_lua_method swig_SwigModule_methods[]= { | |||
10303 | { "setGlobalVariable", _wrap_setGlobalVariable}, | |||
10304 | { "getGlobalVariable", _wrap_getGlobalVariable}, | |||
10305 | { "consoleLog", _wrap_consoleLog}, | |||
10306 | { "consoleLog2", _wrap_consoleLog2}, | |||
10307 | { "consoleCleanLog", _wrap_consoleCleanLog}, | |||
10308 | { "running", _wrap_running}, | |||
10309 | { "email", _wrap_email}, | |||
10310 | { "console_log", _wrap_console_log}, | |||
10311 | { "console_log2", _wrap_console_log2}, | |||
10312 | { "console_clean_log", _wrap_console_clean_log}, | |||
10313 | { "msleep", _wrap_msleep}, | |||
10314 | { "bridge", _wrap_bridge}, | |||
10315 | { "hanguphook", _wrap_hanguphook}, | |||
10316 | { "dtmf_callback", _wrap_dtmf_callback}, | |||
10317 | {0,0} | |||
10318 | }; | |||
10319 | static swig_lua_class* swig_SwigModule_classes[]= { | |||
10320 | &_wrap_class_string, | |||
10321 | &_wrap_class_IVRMenu, | |||
10322 | &_wrap_class_API, | |||
10323 | &_wrap_class_input_callback_state_t, | |||
10324 | &_wrap_class_DTMF, | |||
10325 | &_wrap_class_Stream, | |||
10326 | &_wrap_class_Event, | |||
10327 | &_wrap_class_EventConsumer, | |||
10328 | &_wrap_class_CoreSession, | |||
10329 | &_wrap_class_Session, | |||
10330 | &_wrap_class_Dbh, | |||
10331 | &_wrap_class_JSON, | |||
10332 | 0 | |||
10333 | }; | |||
10334 | static swig_lua_namespace* swig_SwigModule_namespaces[] = { | |||
10335 | 0 | |||
10336 | }; | |||
10337 | ||||
10338 | static swig_lua_namespace swig_SwigModule = { | |||
10339 | "freeswitch", | |||
10340 | swig_SwigModule_methods, | |||
10341 | swig_SwigModule_attributes, | |||
10342 | swig_SwigModule_constants, | |||
10343 | swig_SwigModule_classes, | |||
10344 | swig_SwigModule_namespaces | |||
10345 | }; | |||
10346 | #ifdef __cplusplus201402L | |||
10347 | } | |||
10348 | #endif | |||
10349 | ||||
10350 | /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */ | |||
10351 | ||||
10352 | static void *_p_LUA__SessionTo_p_CoreSession(void *x, int *SWIGUNUSEDPARM(newmemory)) { | |||
10353 | return (void *)((CoreSession *) ((LUA::Session *) x)); | |||
10354 | } | |||
10355 | static swig_type_info _swigt__p_API = {"_p_API", "API *", 0, 0, (void*)&_wrap_class_API, 0}; | |||
10356 | static swig_type_info _swigt__p_CoreSession = {"_p_CoreSession", "CoreSession *", 0, 0, (void*)&_wrap_class_CoreSession, 0}; | |||
10357 | static swig_type_info _swigt__p_DTMF = {"_p_DTMF", "DTMF *", 0, 0, (void*)&_wrap_class_DTMF, 0}; | |||
10358 | static swig_type_info _swigt__p_Event = {"_p_Event", "Event *", 0, 0, (void*)&_wrap_class_Event, 0}; | |||
10359 | static swig_type_info _swigt__p_EventConsumer = {"_p_EventConsumer", "EventConsumer *", 0, 0, (void*)&_wrap_class_EventConsumer, 0}; | |||
10360 | static swig_type_info _swigt__p_IVRMenu = {"_p_IVRMenu", "IVRMenu *", 0, 0, (void*)&_wrap_class_IVRMenu, 0}; | |||
10361 | static swig_type_info _swigt__p_LUA__Dbh = {"_p_LUA__Dbh", "LUA::Dbh *", 0, 0, (void*)&_wrap_class_Dbh, 0}; | |||
10362 | static swig_type_info _swigt__p_LUA__JSON = {"_p_LUA__JSON", "LUA::JSON *", 0, 0, (void*)&_wrap_class_JSON, 0}; | |||
10363 | static swig_type_info _swigt__p_LUA__Session = {"_p_LUA__Session", "LUA::Session *", 0, 0, (void*)&_wrap_class_Session, 0}; | |||
10364 | static swig_type_info _swigt__p_SWIGLUA_FN = {"_p_SWIGLUA_FN", "SWIGLUA_FN *", 0, 0, (void*)0, 0}; | |||
10365 | static swig_type_info _swigt__p_Stream = {"_p_Stream", "Stream *", 0, 0, (void*)&_wrap_class_Stream, 0}; | |||
10366 | static swig_type_info _swigt__p_input_callback_state = {"_p_input_callback_state", "input_callback_state_t *|input_callback_state *", 0, 0, (void*)&_wrap_class_input_callback_state_t, 0}; | |||
10367 | static swig_type_info _swigt__p_int = {"_p_int", "int *", 0, 0, (void*)0, 0}; | |||
10368 | static swig_type_info _swigt__p_lua_State = {"_p_lua_State", "lua_State *", 0, 0, (void*)0, 0}; | |||
10369 | static swig_type_info _swigt__p_p_switch_event_node_t = {"_p_p_switch_event_node_t", "switch_event_node_t **", 0, 0, (void*)0, 0}; | |||
10370 | static swig_type_info _swigt__p_session_flag_t = {"_p_session_flag_t", "enum session_flag_t *|session_flag_t *", 0, 0, (void*)0, 0}; | |||
10371 | static swig_type_info _swigt__p_std__string = {"_p_std__string", "std::string *", 0, 0, (void*)&_wrap_class_string, 0}; | |||
10372 | static swig_type_info _swigt__p_switch_call_cause_t = {"_p_switch_call_cause_t", "switch_call_cause_t *", 0, 0, (void*)0, 0}; | |||
10373 | static swig_type_info _swigt__p_switch_channel_state_t = {"_p_switch_channel_state_t", "switch_channel_state_t *", 0, 0, (void*)0, 0}; | |||
10374 | static swig_type_info _swigt__p_switch_channel_t = {"_p_switch_channel_t", "switch_channel_t *", 0, 0, (void*)0, 0}; | |||
10375 | static swig_type_info _swigt__p_switch_core_session_t = {"_p_switch_core_session_t", "switch_core_session_t *", 0, 0, (void*)0, 0}; | |||
10376 | static swig_type_info _swigt__p_switch_event_t = {"_p_switch_event_t", "switch_event_t *", 0, 0, (void*)0, 0}; | |||
10377 | static swig_type_info _swigt__p_switch_event_types_t = {"_p_switch_event_types_t", "switch_event_types_t *", 0, 0, (void*)0, 0}; | |||
10378 | static swig_type_info _swigt__p_switch_input_args_t = {"_p_switch_input_args_t", "switch_input_args_t *", 0, 0, (void*)0, 0}; | |||
10379 | static swig_type_info _swigt__p_switch_input_type_t = {"_p_switch_input_type_t", "switch_input_type_t *", 0, 0, (void*)0, 0}; | |||
10380 | static swig_type_info _swigt__p_switch_priority_t = {"_p_switch_priority_t", "switch_priority_t *", 0, 0, (void*)0, 0}; | |||
10381 | static swig_type_info _swigt__p_switch_queue_t = {"_p_switch_queue_t", "switch_queue_t *", 0, 0, (void*)0, 0}; | |||
10382 | static swig_type_info _swigt__p_switch_state_handler_table_t = {"_p_switch_state_handler_table_t", "switch_state_handler_table_t *", 0, 0, (void*)0, 0}; | |||
10383 | static swig_type_info _swigt__p_switch_status_t = {"_p_switch_status_t", "switch_status_t *", 0, 0, (void*)0, 0}; | |||
10384 | static swig_type_info _swigt__p_switch_stream_handle_t = {"_p_switch_stream_handle_t", "switch_stream_handle_t *", 0, 0, (void*)0, 0}; | |||
10385 | static swig_type_info _swigt__p_uint32_t = {"_p_uint32_t", "uint32_t *", 0, 0, (void*)0, 0}; | |||
10386 | static swig_type_info _swigt__p_void = {"_p_void", "void *", 0, 0, (void*)0, 0}; | |||
10387 | ||||
10388 | static swig_type_info *swig_type_initial[] = { | |||
10389 | &_swigt__p_API, | |||
10390 | &_swigt__p_CoreSession, | |||
10391 | &_swigt__p_DTMF, | |||
10392 | &_swigt__p_Event, | |||
10393 | &_swigt__p_EventConsumer, | |||
10394 | &_swigt__p_IVRMenu, | |||
10395 | &_swigt__p_LUA__Dbh, | |||
10396 | &_swigt__p_LUA__JSON, | |||
10397 | &_swigt__p_LUA__Session, | |||
10398 | &_swigt__p_SWIGLUA_FN, | |||
10399 | &_swigt__p_Stream, | |||
10400 | &_swigt__p_input_callback_state, | |||
10401 | &_swigt__p_int, | |||
10402 | &_swigt__p_lua_State, | |||
10403 | &_swigt__p_p_switch_event_node_t, | |||
10404 | &_swigt__p_session_flag_t, | |||
10405 | &_swigt__p_std__string, | |||
10406 | &_swigt__p_switch_call_cause_t, | |||
10407 | &_swigt__p_switch_channel_state_t, | |||
10408 | &_swigt__p_switch_channel_t, | |||
10409 | &_swigt__p_switch_core_session_t, | |||
10410 | &_swigt__p_switch_event_t, | |||
10411 | &_swigt__p_switch_event_types_t, | |||
10412 | &_swigt__p_switch_input_args_t, | |||
10413 | &_swigt__p_switch_input_type_t, | |||
10414 | &_swigt__p_switch_priority_t, | |||
10415 | &_swigt__p_switch_queue_t, | |||
10416 | &_swigt__p_switch_state_handler_table_t, | |||
10417 | &_swigt__p_switch_status_t, | |||
10418 | &_swigt__p_switch_stream_handle_t, | |||
10419 | &_swigt__p_uint32_t, | |||
10420 | &_swigt__p_void, | |||
10421 | }; | |||
10422 | ||||
10423 | static swig_cast_info _swigc__p_API[] = { {&_swigt__p_API, 0, 0, 0},{0, 0, 0, 0}}; | |||
10424 | static swig_cast_info _swigc__p_CoreSession[] = { {&_swigt__p_CoreSession, 0, 0, 0}, {&_swigt__p_LUA__Session, _p_LUA__SessionTo_p_CoreSession, 0, 0},{0, 0, 0, 0}}; | |||
10425 | static swig_cast_info _swigc__p_DTMF[] = { {&_swigt__p_DTMF, 0, 0, 0},{0, 0, 0, 0}}; | |||
10426 | static swig_cast_info _swigc__p_Event[] = { {&_swigt__p_Event, 0, 0, 0},{0, 0, 0, 0}}; | |||
10427 | static swig_cast_info _swigc__p_EventConsumer[] = { {&_swigt__p_EventConsumer, 0, 0, 0},{0, 0, 0, 0}}; | |||
10428 | static swig_cast_info _swigc__p_IVRMenu[] = { {&_swigt__p_IVRMenu, 0, 0, 0},{0, 0, 0, 0}}; | |||
10429 | static swig_cast_info _swigc__p_LUA__Dbh[] = { {&_swigt__p_LUA__Dbh, 0, 0, 0},{0, 0, 0, 0}}; | |||
10430 | static swig_cast_info _swigc__p_LUA__JSON[] = { {&_swigt__p_LUA__JSON, 0, 0, 0},{0, 0, 0, 0}}; | |||
10431 | static swig_cast_info _swigc__p_LUA__Session[] = { {&_swigt__p_LUA__Session, 0, 0, 0},{0, 0, 0, 0}}; | |||
10432 | static swig_cast_info _swigc__p_SWIGLUA_FN[] = { {&_swigt__p_SWIGLUA_FN, 0, 0, 0},{0, 0, 0, 0}}; | |||
10433 | static swig_cast_info _swigc__p_Stream[] = { {&_swigt__p_Stream, 0, 0, 0},{0, 0, 0, 0}}; | |||
10434 | static swig_cast_info _swigc__p_input_callback_state[] = { {&_swigt__p_input_callback_state, 0, 0, 0},{0, 0, 0, 0}}; | |||
10435 | static swig_cast_info _swigc__p_int[] = { {&_swigt__p_int, 0, 0, 0},{0, 0, 0, 0}}; | |||
10436 | static swig_cast_info _swigc__p_lua_State[] = { {&_swigt__p_lua_State, 0, 0, 0},{0, 0, 0, 0}}; | |||
10437 | static swig_cast_info _swigc__p_p_switch_event_node_t[] = { {&_swigt__p_p_switch_event_node_t, 0, 0, 0},{0, 0, 0, 0}}; | |||
10438 | static swig_cast_info _swigc__p_session_flag_t[] = { {&_swigt__p_session_flag_t, 0, 0, 0},{0, 0, 0, 0}}; | |||
10439 | static swig_cast_info _swigc__p_std__string[] = { {&_swigt__p_std__string, 0, 0, 0},{0, 0, 0, 0}}; | |||
10440 | static swig_cast_info _swigc__p_switch_call_cause_t[] = { {&_swigt__p_switch_call_cause_t, 0, 0, 0},{0, 0, 0, 0}}; | |||
10441 | static swig_cast_info _swigc__p_switch_channel_state_t[] = { {&_swigt__p_switch_channel_state_t, 0, 0, 0},{0, 0, 0, 0}}; | |||
10442 | static swig_cast_info _swigc__p_switch_channel_t[] = { {&_swigt__p_switch_channel_t, 0, 0, 0},{0, 0, 0, 0}}; | |||
10443 | static swig_cast_info _swigc__p_switch_core_session_t[] = { {&_swigt__p_switch_core_session_t, 0, 0, 0},{0, 0, 0, 0}}; | |||
10444 | static swig_cast_info _swigc__p_switch_event_t[] = { {&_swigt__p_switch_event_t, 0, 0, 0},{0, 0, 0, 0}}; | |||
10445 | static swig_cast_info _swigc__p_switch_event_types_t[] = { {&_swigt__p_switch_event_types_t, 0, 0, 0},{0, 0, 0, 0}}; | |||
10446 | static swig_cast_info _swigc__p_switch_input_args_t[] = { {&_swigt__p_switch_input_args_t, 0, 0, 0},{0, 0, 0, 0}}; | |||
10447 | static swig_cast_info _swigc__p_switch_input_type_t[] = { {&_swigt__p_switch_input_type_t, 0, 0, 0},{0, 0, 0, 0}}; | |||
10448 | static swig_cast_info _swigc__p_switch_priority_t[] = { {&_swigt__p_switch_priority_t, 0, 0, 0},{0, 0, 0, 0}}; | |||
10449 | static swig_cast_info _swigc__p_switch_queue_t[] = { {&_swigt__p_switch_queue_t, 0, 0, 0},{0, 0, 0, 0}}; | |||
10450 | static swig_cast_info _swigc__p_switch_state_handler_table_t[] = { {&_swigt__p_switch_state_handler_table_t, 0, 0, 0},{0, 0, 0, 0}}; | |||
10451 | static swig_cast_info _swigc__p_switch_status_t[] = { {&_swigt__p_switch_status_t, 0, 0, 0},{0, 0, 0, 0}}; | |||
10452 | static swig_cast_info _swigc__p_switch_stream_handle_t[] = { {&_swigt__p_switch_stream_handle_t, 0, 0, 0},{0, 0, 0, 0}}; | |||
10453 | static swig_cast_info _swigc__p_uint32_t[] = { {&_swigt__p_uint32_t, 0, 0, 0},{0, 0, 0, 0}}; | |||
10454 | static swig_cast_info _swigc__p_void[] = { {&_swigt__p_void, 0, 0, 0},{0, 0, 0, 0}}; | |||
10455 | ||||
10456 | static swig_cast_info *swig_cast_initial[] = { | |||
10457 | _swigc__p_API, | |||
10458 | _swigc__p_CoreSession, | |||
10459 | _swigc__p_DTMF, | |||
10460 | _swigc__p_Event, | |||
10461 | _swigc__p_EventConsumer, | |||
10462 | _swigc__p_IVRMenu, | |||
10463 | _swigc__p_LUA__Dbh, | |||
10464 | _swigc__p_LUA__JSON, | |||
10465 | _swigc__p_LUA__Session, | |||
10466 | _swigc__p_SWIGLUA_FN, | |||
10467 | _swigc__p_Stream, | |||
10468 | _swigc__p_input_callback_state, | |||
10469 | _swigc__p_int, | |||
10470 | _swigc__p_lua_State, | |||
10471 | _swigc__p_p_switch_event_node_t, | |||
10472 | _swigc__p_session_flag_t, | |||
10473 | _swigc__p_std__string, | |||
10474 | _swigc__p_switch_call_cause_t, | |||
10475 | _swigc__p_switch_channel_state_t, | |||
10476 | _swigc__p_switch_channel_t, | |||
10477 | _swigc__p_switch_core_session_t, | |||
10478 | _swigc__p_switch_event_t, | |||
10479 | _swigc__p_switch_event_types_t, | |||
10480 | _swigc__p_switch_input_args_t, | |||
10481 | _swigc__p_switch_input_type_t, | |||
10482 | _swigc__p_switch_priority_t, | |||
10483 | _swigc__p_switch_queue_t, | |||
10484 | _swigc__p_switch_state_handler_table_t, | |||
10485 | _swigc__p_switch_status_t, | |||
10486 | _swigc__p_switch_stream_handle_t, | |||
10487 | _swigc__p_uint32_t, | |||
10488 | _swigc__p_void, | |||
10489 | }; | |||
10490 | ||||
10491 | ||||
10492 | /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (END) -------- */ | |||
10493 | ||||
10494 | /* ----------------------------------------------------------------------------- | |||
10495 | * Type initialization: | |||
10496 | * This problem is tough by the requirement that no dynamic | |||
10497 | * memory is used. Also, since swig_type_info structures store pointers to | |||
10498 | * swig_cast_info structures and swig_cast_info structures store pointers back | |||
10499 | * to swig_type_info structures, we need some lookup code at initialization. | |||
10500 | * The idea is that swig generates all the structures that are needed. | |||
10501 | * The runtime then collects these partially filled structures. | |||
10502 | * The SWIG_InitializeModule function takes these initial arrays out of | |||
10503 | * swig_module, and does all the lookup, filling in the swig_module.types | |||
10504 | * array with the correct data and linking the correct swig_cast_info | |||
10505 | * structures together. | |||
10506 | * | |||
10507 | * The generated swig_type_info structures are assigned statically to an initial | |||
10508 | * array. We just loop through that array, and handle each type individually. | |||
10509 | * First we lookup if this type has been already loaded, and if so, use the | |||
10510 | * loaded structure instead of the generated one. Then we have to fill in the | |||
10511 | * cast linked list. The cast data is initially stored in something like a | |||
10512 | * two-dimensional array. Each row corresponds to a type (there are the same | |||
10513 | * number of rows as there are in the swig_type_initial array). Each entry in | |||
10514 | * a column is one of the swig_cast_info structures for that type. | |||
10515 | * The cast_initial array is actually an array of arrays, because each row has | |||
10516 | * a variable number of columns. So to actually build the cast linked list, | |||
10517 | * we find the array of casts associated with the type, and loop through it | |||
10518 | * adding the casts to the list. The one last trick we need to do is making | |||
10519 | * sure the type pointer in the swig_cast_info struct is correct. | |||
10520 | * | |||
10521 | * First off, we lookup the cast->type name to see if it is already loaded. | |||
10522 | * There are three cases to handle: | |||
10523 | * 1) If the cast->type has already been loaded AND the type we are adding | |||
10524 | * casting info to has not been loaded (it is in this module), THEN we | |||
10525 | * replace the cast->type pointer with the type pointer that has already | |||
10526 | * been loaded. | |||
10527 | * 2) If BOTH types (the one we are adding casting info to, and the | |||
10528 | * cast->type) are loaded, THEN the cast info has already been loaded by | |||
10529 | * the previous module so we just ignore it. | |||
10530 | * 3) Finally, if cast->type has not already been loaded, then we add that | |||
10531 | * swig_cast_info to the linked list (because the cast->type) pointer will | |||
10532 | * be correct. | |||
10533 | * ----------------------------------------------------------------------------- */ | |||
10534 | ||||
10535 | #ifdef __cplusplus201402L | |||
10536 | extern "C" { | |||
10537 | #if 0 | |||
10538 | } /* c-mode */ | |||
10539 | #endif | |||
10540 | #endif | |||
10541 | ||||
10542 | #if 0 | |||
10543 | #define SWIGRUNTIME_DEBUG | |||
10544 | #endif | |||
10545 | ||||
10546 | ||||
10547 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) void | |||
10548 | SWIG_InitializeModule(void *clientdata) { | |||
10549 | size_t i; | |||
10550 | swig_module_info *module_head, *iter; | |||
10551 | int init; | |||
10552 | ||||
10553 | /* check to see if the circular list has been setup, if not, set it up */ | |||
10554 | if (swig_module.next==0) { | |||
10555 | /* Initialize the swig_module */ | |||
10556 | swig_module.type_initial = swig_type_initial; | |||
10557 | swig_module.cast_initial = swig_cast_initial; | |||
10558 | swig_module.next = &swig_module; | |||
10559 | init = 1; | |||
10560 | } else { | |||
10561 | init = 0; | |||
10562 | } | |||
10563 | ||||
10564 | /* Try and load any already created modules */ | |||
10565 | module_head = SWIG_GetModule(clientdata)SWIG_Lua_GetModule((lua_State*)(clientdata)); | |||
10566 | if (!module_head) { | |||
10567 | /* This is the first module loaded for this interpreter */ | |||
10568 | /* so set the swig module into the interpreter */ | |||
10569 | SWIG_SetModule(clientdata, &swig_module)SWIG_Lua_SetModule((lua_State*) (clientdata), &swig_module ); | |||
10570 | } else { | |||
10571 | /* the interpreter has loaded a SWIG module, but has it loaded this one? */ | |||
10572 | iter=module_head; | |||
10573 | do { | |||
10574 | if (iter==&swig_module) { | |||
10575 | /* Our module is already in the list, so there's nothing more to do. */ | |||
10576 | return; | |||
10577 | } | |||
10578 | iter=iter->next; | |||
10579 | } while (iter!= module_head); | |||
10580 | ||||
10581 | /* otherwise we must add our module into the list */ | |||
10582 | swig_module.next = module_head->next; | |||
10583 | module_head->next = &swig_module; | |||
10584 | } | |||
10585 | ||||
10586 | /* When multiple interpreters are used, a module could have already been initialized in | |||
10587 | a different interpreter, but not yet have a pointer in this interpreter. | |||
10588 | In this case, we do not want to continue adding types... everything should be | |||
10589 | set up already */ | |||
10590 | if (init == 0) return; | |||
10591 | ||||
10592 | /* Now work on filling in swig_module.types */ | |||
10593 | #ifdef SWIGRUNTIME_DEBUG | |||
10594 | printf("SWIG_InitializeModule: size %d\n", swig_module.size); | |||
10595 | #endif | |||
10596 | for (i = 0; i < swig_module.size; ++i) { | |||
10597 | swig_type_info *type = 0; | |||
10598 | swig_type_info *ret; | |||
10599 | swig_cast_info *cast; | |||
10600 | ||||
10601 | #ifdef SWIGRUNTIME_DEBUG | |||
10602 | printf("SWIG_InitializeModule: type %d %s\n", i, swig_module.type_initial[i]->name); | |||
10603 | #endif | |||
10604 | ||||
10605 | /* if there is another module already loaded */ | |||
10606 | if (swig_module.next != &swig_module) { | |||
10607 | type = SWIG_MangledTypeQueryModule(swig_module.next, &swig_module, swig_module.type_initial[i]->name); | |||
10608 | } | |||
10609 | if (type) { | |||
10610 | /* Overwrite clientdata field */ | |||
10611 | #ifdef SWIGRUNTIME_DEBUG | |||
10612 | printf("SWIG_InitializeModule: found type %s\n", type->name); | |||
10613 | #endif | |||
10614 | if (swig_module.type_initial[i]->clientdata) { | |||
10615 | type->clientdata = swig_module.type_initial[i]->clientdata; | |||
10616 | #ifdef SWIGRUNTIME_DEBUG | |||
10617 | printf("SWIG_InitializeModule: found and overwrite type %s \n", type->name); | |||
10618 | #endif | |||
10619 | } | |||
10620 | } else { | |||
10621 | type = swig_module.type_initial[i]; | |||
10622 | } | |||
10623 | ||||
10624 | /* Insert casting types */ | |||
10625 | cast = swig_module.cast_initial[i]; | |||
10626 | while (cast->type) { | |||
10627 | ||||
10628 | /* Don't need to add information already in the list */ | |||
10629 | ret = 0; | |||
10630 | #ifdef SWIGRUNTIME_DEBUG | |||
10631 | printf("SWIG_InitializeModule: look cast %s\n", cast->type->name); | |||
10632 | #endif | |||
10633 | if (swig_module.next != &swig_module) { | |||
10634 | ret = SWIG_MangledTypeQueryModule(swig_module.next, &swig_module, cast->type->name); | |||
10635 | #ifdef SWIGRUNTIME_DEBUG | |||
10636 | if (ret) printf("SWIG_InitializeModule: found cast %s\n", ret->name); | |||
10637 | #endif | |||
10638 | } | |||
10639 | if (ret) { | |||
10640 | if (type == swig_module.type_initial[i]) { | |||
10641 | #ifdef SWIGRUNTIME_DEBUG | |||
10642 | printf("SWIG_InitializeModule: skip old type %s\n", ret->name); | |||
10643 | #endif | |||
10644 | cast->type = ret; | |||
10645 | ret = 0; | |||
10646 | } else { | |||
10647 | /* Check for casting already in the list */ | |||
10648 | swig_cast_info *ocast = SWIG_TypeCheck(ret->name, type); | |||
10649 | #ifdef SWIGRUNTIME_DEBUG | |||
10650 | if (ocast) printf("SWIG_InitializeModule: skip old cast %s\n", ret->name); | |||
10651 | #endif | |||
10652 | if (!ocast) ret = 0; | |||
10653 | } | |||
10654 | } | |||
10655 | ||||
10656 | if (!ret) { | |||
10657 | #ifdef SWIGRUNTIME_DEBUG | |||
10658 | printf("SWIG_InitializeModule: adding cast %s\n", cast->type->name); | |||
10659 | #endif | |||
10660 | if (type->cast) { | |||
10661 | type->cast->prev = cast; | |||
10662 | cast->next = type->cast; | |||
10663 | } | |||
10664 | type->cast = cast; | |||
10665 | } | |||
10666 | cast++; | |||
10667 | } | |||
10668 | /* Set entry in modules->types array equal to the type */ | |||
10669 | swig_module.types[i] = type; | |||
10670 | } | |||
10671 | swig_module.types[i] = 0; | |||
10672 | ||||
10673 | #ifdef SWIGRUNTIME_DEBUG | |||
10674 | printf("**** SWIG_InitializeModule: Cast List ******\n"); | |||
10675 | for (i = 0; i < swig_module.size; ++i) { | |||
10676 | int j = 0; | |||
10677 | swig_cast_info *cast = swig_module.cast_initial[i]; | |||
10678 | printf("SWIG_InitializeModule: type %d %s\n", i, swig_module.type_initial[i]->name); | |||
10679 | while (cast->type) { | |||
10680 | printf("SWIG_InitializeModule: cast type %s\n", cast->type->name); | |||
10681 | cast++; | |||
10682 | ++j; | |||
10683 | } | |||
10684 | printf("---- Total casts: %d\n",j); | |||
10685 | } | |||
10686 | printf("**** SWIG_InitializeModule: Cast List ******\n"); | |||
10687 | #endif | |||
10688 | } | |||
10689 | ||||
10690 | /* This function will propagate the clientdata field of type to | |||
10691 | * any new swig_type_info structures that have been added into the list | |||
10692 | * of equivalent types. It is like calling | |||
10693 | * SWIG_TypeClientData(type, clientdata) a second time. | |||
10694 | */ | |||
10695 | SWIGRUNTIMEstatic __attribute__ ((__unused__)) void | |||
10696 | SWIG_PropagateClientData(void) { | |||
10697 | size_t i; | |||
10698 | swig_cast_info *equiv; | |||
10699 | static int init_run = 0; | |||
10700 | ||||
10701 | if (init_run) return; | |||
10702 | init_run = 1; | |||
10703 | ||||
10704 | for (i = 0; i < swig_module.size; i++) { | |||
10705 | if (swig_module.types[i]->clientdata) { | |||
10706 | equiv = swig_module.types[i]->cast; | |||
10707 | while (equiv) { | |||
10708 | if (!equiv->converter) { | |||
10709 | if (equiv->type && !equiv->type->clientdata) | |||
10710 | SWIG_TypeClientData(equiv->type, swig_module.types[i]->clientdata); | |||
10711 | } | |||
10712 | equiv = equiv->next; | |||
10713 | } | |||
10714 | } | |||
10715 | } | |||
10716 | } | |||
10717 | ||||
10718 | #ifdef __cplusplus201402L | |||
10719 | #if 0 | |||
10720 | { /* c-mode */ | |||
10721 | #endif | |||
10722 | } | |||
10723 | #endif | |||
10724 | ||||
10725 | ||||
10726 | ||||
10727 | /* Forward declaration of where the user's %init{} gets inserted */ | |||
10728 | void SWIG_init_userluaopen_freeswitch_user(lua_State* L ); | |||
10729 | ||||
10730 | #ifdef __cplusplus201402L | |||
10731 | extern "C" { | |||
10732 | #endif | |||
10733 | /* this is the initialization function | |||
10734 | added at the very end of the code | |||
10735 | the function is always called SWIG_init, but an earlier #define will rename it | |||
10736 | */ | |||
10737 | #if ((SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_ELUA2) || (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_ELUAC3)) | |||
10738 | LUALIB_APIextern "C" int SWIG_initluaopen_freeswitch(lua_State* L) | |||
10739 | #else | |||
10740 | SWIGEXPORT__attribute__ ((visibility("default"))) int SWIG_initluaopen_freeswitch(lua_State* L) /* default Lua action */ | |||
10741 | #endif | |||
10742 | { | |||
10743 | #if (SWIG_LUA_TARGET1 != SWIG_LUA_FLAVOR_ELUAC3) /* valid for both Lua and eLua */ | |||
10744 | int i; | |||
10745 | int globalRegister = 0; | |||
10746 | /* start with global table */ | |||
10747 | lua_pushglobaltable (L)lua_rawgeti(L, (-1000000 - 1000), 2); | |||
10748 | /* SWIG's internal initialisation */ | |||
10749 | SWIG_InitializeModule((void*)L); | |||
10750 | SWIG_PropagateClientData(); | |||
10751 | #endif | |||
10752 | ||||
10753 | #if ((SWIG_LUA_TARGET1 != SWIG_LUA_FLAVOR_ELUA2) && (SWIG_LUA_TARGET1 != SWIG_LUA_FLAVOR_ELUAC3)) || defined(SWIG_LUA_ELUA_EMULATE) | |||
10754 | /* add a global fn */ | |||
10755 | SWIG_Lua_add_function(L,"swig_type",SWIG_Lua_type)(lua_pushstring(L, "swig_type"), lua_pushcclosure(L, (SWIG_Lua_type ), 0), lua_rawset(L,-3)); | |||
10756 | SWIG_Lua_add_function(L,"swig_equals",SWIG_Lua_class_equal)(lua_pushstring(L, "swig_equals"), lua_pushcclosure(L, (SWIG_Lua_class_equal ), 0), lua_rawset(L,-3)); | |||
10757 | #endif | |||
10758 | ||||
10759 | #if (SWIG_LUA_TARGET1 != SWIG_LUA_FLAVOR_ELUAC3) | |||
10760 | /* set up base class pointers (the hierarchy) */ | |||
10761 | for (i = 0; swig_types[i]; i++){ | |||
10762 | if (swig_types[i]->clientdata){ | |||
10763 | SWIG_Lua_init_base_class(L,(swig_lua_class*)(swig_types[i]->clientdata)); | |||
10764 | } | |||
10765 | } | |||
10766 | #ifdef SWIG_LUA_MODULE_GLOBAL | |||
10767 | globalRegister = 1; | |||
10768 | #endif | |||
10769 | ||||
10770 | ||||
10771 | #if (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_LUA1) | |||
10772 | SWIG_Lua_namespace_register(L,&swig_SwigModule, globalRegister); | |||
10773 | #endif | |||
10774 | ||||
10775 | #if (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_ELUA2) || (SWIG_LUA_TARGET1 == SWIG_LUA_FLAVOR_ELUAC3) | |||
10776 | for (i = 0; swig_types[i]; i++){ | |||
10777 | if (swig_types[i]->clientdata){ | |||
10778 | SWIG_Lua_elua_class_register_instance(L,(swig_lua_class*)(swig_types[i]->clientdata)); | |||
10779 | } | |||
10780 | } | |||
10781 | #endif | |||
10782 | ||||
10783 | #if defined(SWIG_LUA_ELUA_EMULATE) | |||
10784 | lua_newtable(L)lua_createtable(L, 0, 0); | |||
10785 | SWIG_Lua_elua_emulate_register(L,swig_SwigModule.ns_methods); | |||
10786 | SWIG_Lua_elua_emulate_register_clear(L); | |||
10787 | if(globalRegister) { | |||
10788 | lua_pushstring(L,swig_SwigModule.name); | |||
10789 | lua_pushvalue(L,-2); | |||
10790 | lua_rawset(L,-4); | |||
10791 | } | |||
10792 | #endif | |||
10793 | ||||
10794 | #endif | |||
10795 | ||||
10796 | #if (SWIG_LUA_TARGET1 != SWIG_LUA_FLAVOR_ELUAC3) | |||
10797 | /* invoke user-specific initialization */ | |||
10798 | SWIG_init_userluaopen_freeswitch_user(L); | |||
10799 | /* end module */ | |||
10800 | /* Note: We do not clean up the stack here (Lua will do this for us). At this | |||
10801 | point, we have the globals table and out module table on the stack. Returning | |||
10802 | one value makes the module table the result of the require command. */ | |||
10803 | return 1; | |||
10804 | #else | |||
10805 | return 0; | |||
10806 | #endif | |||
10807 | } | |||
10808 | ||||
10809 | #ifdef __cplusplus201402L | |||
10810 | } | |||
10811 | #endif | |||
10812 | ||||
10813 | ||||
10814 | const char* SWIG_LUACODEluaopen_freeswitch_luacode= | |||
10815 | ""; | |||
10816 | ||||
10817 | void SWIG_init_userluaopen_freeswitch_user(lua_State* L) | |||
10818 | { | |||
10819 | /* exec Lua code if applicable */ | |||
10820 | SWIG_Lua_dostring(L,SWIG_LUACODEluaopen_freeswitch_luacode); | |||
10821 | } | |||
10822 | ||||
10823 | #include "mod_lua_extra.c" |