Line data Source code
1 : /* ----------------------------------------------------------------------------
2 : * This file was automatically generated by SWIG (http://www.swig.org).
3 : * Version 4.0.1
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 SWIGPYTHON
13 : #define SWIGPYTHON
14 : #define SED_HACKS
15 : #endif
16 :
17 : #define SWIG_PYTHON_THREADS
18 : #define SWIG_PYTHON_DIRECTOR_NO_VTABLE
19 :
20 : /* -----------------------------------------------------------------------------
21 : * This section contains generic SWIG labels for method/variable
22 : * declarations/attributes, and other compiler dependent labels.
23 : * ----------------------------------------------------------------------------- */
24 :
25 : /* template workaround for compilers that cannot correctly implement the C++ standard */
26 : #ifndef SWIGTEMPLATEDISAMBIGUATOR
27 : # if defined(__SUNPRO_CC) && (__SUNPRO_CC <= 0x560)
28 : # define SWIGTEMPLATEDISAMBIGUATOR template
29 : # elif defined(__HP_aCC)
30 : /* Needed even with `aCC -AA' when `aCC -V' reports HP ANSI C++ B3910B A.03.55 */
31 : /* If we find a maximum version that requires this, the test would be __HP_aCC <= 35500 for A.03.55 */
32 : # define SWIGTEMPLATEDISAMBIGUATOR template
33 : # else
34 : # define SWIGTEMPLATEDISAMBIGUATOR
35 : # endif
36 : #endif
37 :
38 : /* inline attribute */
39 : #ifndef SWIGINLINE
40 : # if defined(__cplusplus) || (defined(__GNUC__) && !defined(__STRICT_ANSI__))
41 : # define SWIGINLINE inline
42 : # else
43 : # define SWIGINLINE
44 : # endif
45 : #endif
46 :
47 : /* attribute recognised by some compilers to avoid 'unused' warnings */
48 : #ifndef SWIGUNUSED
49 : # if defined(__GNUC__)
50 : # if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
51 : # define SWIGUNUSED __attribute__ ((__unused__))
52 : # else
53 : # define SWIGUNUSED
54 : # endif
55 : # elif defined(__ICC)
56 : # define SWIGUNUSED __attribute__ ((__unused__))
57 : # else
58 : # define SWIGUNUSED
59 : # endif
60 : #endif
61 :
62 : #ifndef SWIG_MSC_UNSUPPRESS_4505
63 : # if defined(_MSC_VER)
64 : # pragma warning(disable : 4505) /* unreferenced local function has been removed */
65 : # endif
66 : #endif
67 :
68 : #ifndef SWIGUNUSEDPARM
69 : # ifdef __cplusplus
70 : # define SWIGUNUSEDPARM(p)
71 : # else
72 : # define SWIGUNUSEDPARM(p) p SWIGUNUSED
73 : # endif
74 : #endif
75 :
76 : /* internal SWIG method */
77 : #ifndef SWIGINTERN
78 : # define SWIGINTERN static SWIGUNUSED
79 : #endif
80 :
81 : /* internal inline SWIG method */
82 : #ifndef SWIGINTERNINLINE
83 : # define SWIGINTERNINLINE SWIGINTERN SWIGINLINE
84 : #endif
85 :
86 : /* exporting methods */
87 : #if defined(__GNUC__)
88 : # if (__GNUC__ >= 4) || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)
89 : # ifndef GCC_HASCLASSVISIBILITY
90 : # define GCC_HASCLASSVISIBILITY
91 : # endif
92 : # endif
93 : #endif
94 :
95 : #ifndef SWIGEXPORT
96 : # if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
97 : # if defined(STATIC_LINKED)
98 : # define SWIGEXPORT
99 : # else
100 : # define SWIGEXPORT __declspec(dllexport)
101 : # endif
102 : # else
103 : # if defined(__GNUC__) && defined(GCC_HASCLASSVISIBILITY)
104 : # define SWIGEXPORT __attribute__ ((visibility("default")))
105 : # else
106 : # define SWIGEXPORT
107 : # endif
108 : # endif
109 : #endif
110 :
111 : /* calling conventions for Windows */
112 : #ifndef SWIGSTDCALL
113 : # if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
114 : # define SWIGSTDCALL __stdcall
115 : # else
116 : # define SWIGSTDCALL
117 : # endif
118 : #endif
119 :
120 : /* Deal with Microsoft's attempt at deprecating C standard runtime functions */
121 : #if !defined(SWIG_NO_CRT_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_CRT_SECURE_NO_DEPRECATE)
122 : # define _CRT_SECURE_NO_DEPRECATE
123 : #endif
124 :
125 : /* Deal with Microsoft's attempt at deprecating methods in the standard C++ library */
126 : #if !defined(SWIG_NO_SCL_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_SCL_SECURE_NO_DEPRECATE)
127 : # define _SCL_SECURE_NO_DEPRECATE
128 : #endif
129 :
130 : /* Deal with Apple's deprecated 'AssertMacros.h' from Carbon-framework */
131 : #if defined(__APPLE__) && !defined(__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES)
132 : # define __ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES 0
133 : #endif
134 :
135 : /* Intel's compiler complains if a variable which was never initialised is
136 : * cast to void, which is a common idiom which we use to indicate that we
137 : * are aware a variable isn't used. So we just silence that warning.
138 : * See: https://github.com/swig/swig/issues/192 for more discussion.
139 : */
140 : #ifdef __INTEL_COMPILER
141 : # pragma warning disable 592
142 : #endif
143 :
144 :
145 : #if defined(__GNUC__) && defined(_WIN32) && !defined(SWIG_PYTHON_NO_HYPOT_WORKAROUND)
146 : /* Workaround for '::hypot' has not been declared', see https://bugs.python.org/issue11566 */
147 : # include <math.h>
148 : #endif
149 :
150 : #if defined(_DEBUG) && defined(SWIG_PYTHON_INTERPRETER_NO_DEBUG)
151 : /* Use debug wrappers with the Python release dll */
152 : # undef _DEBUG
153 : # include <Python.h>
154 : # define _DEBUG 1
155 : #else
156 : # include <Python.h>
157 : #endif
158 :
159 : /* -----------------------------------------------------------------------------
160 : * swigrun.swg
161 : *
162 : * This file contains generic C API SWIG runtime support for pointer
163 : * type checking.
164 : * ----------------------------------------------------------------------------- */
165 :
166 : /* This should only be incremented when either the layout of swig_type_info changes,
167 : or for whatever reason, the runtime changes incompatibly */
168 : #define SWIG_RUNTIME_VERSION "4"
169 :
170 : /* define SWIG_TYPE_TABLE_NAME as "SWIG_TYPE_TABLE" */
171 : #ifdef SWIG_TYPE_TABLE
172 : # define SWIG_QUOTE_STRING(x) #x
173 : # define SWIG_EXPAND_AND_QUOTE_STRING(x) SWIG_QUOTE_STRING(x)
174 : # define SWIG_TYPE_TABLE_NAME SWIG_EXPAND_AND_QUOTE_STRING(SWIG_TYPE_TABLE)
175 : #else
176 : # define SWIG_TYPE_TABLE_NAME
177 : #endif
178 :
179 : /*
180 : You can use the SWIGRUNTIME and SWIGRUNTIMEINLINE macros for
181 : creating a static or dynamic library from the SWIG runtime code.
182 : In 99.9% of the cases, SWIG just needs to declare them as 'static'.
183 :
184 : But only do this if strictly necessary, ie, if you have problems
185 : with your compiler or suchlike.
186 : */
187 :
188 : #ifndef SWIGRUNTIME
189 : # define SWIGRUNTIME SWIGINTERN
190 : #endif
191 :
192 : #ifndef SWIGRUNTIMEINLINE
193 : # define SWIGRUNTIMEINLINE SWIGRUNTIME SWIGINLINE
194 : #endif
195 :
196 : /* Generic buffer size */
197 : #ifndef SWIG_BUFFER_SIZE
198 : # define SWIG_BUFFER_SIZE 1024
199 : #endif
200 :
201 : /* Flags for pointer conversions */
202 : #define SWIG_POINTER_DISOWN 0x1
203 : #define SWIG_CAST_NEW_MEMORY 0x2
204 : #define SWIG_POINTER_NO_NULL 0x4
205 :
206 : /* Flags for new pointer objects */
207 : #define SWIG_POINTER_OWN 0x1
208 :
209 :
210 : /*
211 : Flags/methods for returning states.
212 :
213 : The SWIG conversion methods, as ConvertPtr, return an integer
214 : that tells if the conversion was successful or not. And if not,
215 : an error code can be returned (see swigerrors.swg for the codes).
216 :
217 : Use the following macros/flags to set or process the returning
218 : states.
219 :
220 : In old versions of SWIG, code such as the following was usually written:
221 :
222 : if (SWIG_ConvertPtr(obj,vptr,ty.flags) != -1) {
223 : // success code
224 : } else {
225 : //fail code
226 : }
227 :
228 : Now you can be more explicit:
229 :
230 : int res = SWIG_ConvertPtr(obj,vptr,ty.flags);
231 : if (SWIG_IsOK(res)) {
232 : // success code
233 : } else {
234 : // fail code
235 : }
236 :
237 : which is the same really, but now you can also do
238 :
239 : Type *ptr;
240 : int res = SWIG_ConvertPtr(obj,(void **)(&ptr),ty.flags);
241 : if (SWIG_IsOK(res)) {
242 : // success code
243 : if (SWIG_IsNewObj(res) {
244 : ...
245 : delete *ptr;
246 : } else {
247 : ...
248 : }
249 : } else {
250 : // fail code
251 : }
252 :
253 : I.e., now SWIG_ConvertPtr can return new objects and you can
254 : identify the case and take care of the deallocation. Of course that
255 : also requires SWIG_ConvertPtr to return new result values, such as
256 :
257 : int SWIG_ConvertPtr(obj, ptr,...) {
258 : if (<obj is ok>) {
259 : if (<need new object>) {
260 : *ptr = <ptr to new allocated object>;
261 : return SWIG_NEWOBJ;
262 : } else {
263 : *ptr = <ptr to old object>;
264 : return SWIG_OLDOBJ;
265 : }
266 : } else {
267 : return SWIG_BADOBJ;
268 : }
269 : }
270 :
271 : Of course, returning the plain '0(success)/-1(fail)' still works, but you can be
272 : more explicit by returning SWIG_BADOBJ, SWIG_ERROR or any of the
273 : SWIG errors code.
274 :
275 : Finally, if the SWIG_CASTRANK_MODE is enabled, the result code
276 : allows to return the 'cast rank', for example, if you have this
277 :
278 : int food(double)
279 : int fooi(int);
280 :
281 : and you call
282 :
283 : food(1) // cast rank '1' (1 -> 1.0)
284 : fooi(1) // cast rank '0'
285 :
286 : just use the SWIG_AddCast()/SWIG_CheckState()
287 : */
288 :
289 : #define SWIG_OK (0)
290 : #define SWIG_ERROR (-1)
291 : #define SWIG_IsOK(r) (r >= 0)
292 : #define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
293 :
294 : /* The CastRankLimit says how many bits are used for the cast rank */
295 : #define SWIG_CASTRANKLIMIT (1 << 8)
296 : /* The NewMask denotes the object was created (using new/malloc) */
297 : #define SWIG_NEWOBJMASK (SWIG_CASTRANKLIMIT << 1)
298 : /* The TmpMask is for in/out typemaps that use temporal objects */
299 : #define SWIG_TMPOBJMASK (SWIG_NEWOBJMASK << 1)
300 : /* Simple returning values */
301 : #define SWIG_BADOBJ (SWIG_ERROR)
302 : #define SWIG_OLDOBJ (SWIG_OK)
303 : #define SWIG_NEWOBJ (SWIG_OK | SWIG_NEWOBJMASK)
304 : #define SWIG_TMPOBJ (SWIG_OK | SWIG_TMPOBJMASK)
305 : /* Check, add and del mask methods */
306 : #define SWIG_AddNewMask(r) (SWIG_IsOK(r) ? (r | SWIG_NEWOBJMASK) : r)
307 : #define SWIG_DelNewMask(r) (SWIG_IsOK(r) ? (r & ~SWIG_NEWOBJMASK) : r)
308 : #define SWIG_IsNewObj(r) (SWIG_IsOK(r) && (r & SWIG_NEWOBJMASK))
309 : #define SWIG_AddTmpMask(r) (SWIG_IsOK(r) ? (r | SWIG_TMPOBJMASK) : r)
310 : #define SWIG_DelTmpMask(r) (SWIG_IsOK(r) ? (r & ~SWIG_TMPOBJMASK) : r)
311 : #define SWIG_IsTmpObj(r) (SWIG_IsOK(r) && (r & SWIG_TMPOBJMASK))
312 :
313 : /* Cast-Rank Mode */
314 : #if defined(SWIG_CASTRANK_MODE)
315 : # ifndef SWIG_TypeRank
316 : # define SWIG_TypeRank unsigned long
317 : # endif
318 : # ifndef SWIG_MAXCASTRANK /* Default cast allowed */
319 : # define SWIG_MAXCASTRANK (2)
320 : # endif
321 : # define SWIG_CASTRANKMASK ((SWIG_CASTRANKLIMIT) -1)
322 : # define SWIG_CastRank(r) (r & SWIG_CASTRANKMASK)
323 : SWIGINTERNINLINE int SWIG_AddCast(int r) {
324 : return SWIG_IsOK(r) ? ((SWIG_CastRank(r) < SWIG_MAXCASTRANK) ? (r + 1) : SWIG_ERROR) : r;
325 : }
326 : SWIGINTERNINLINE int SWIG_CheckState(int r) {
327 : return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
328 : }
329 : #else /* no cast-rank mode */
330 : # define SWIG_AddCast(r) (r)
331 : # define SWIG_CheckState(r) (SWIG_IsOK(r) ? 1 : 0)
332 : #endif
333 :
334 :
335 : #include <string.h>
336 :
337 : #ifdef __cplusplus
338 : extern "C" {
339 : #endif
340 :
341 : typedef void *(*swig_converter_func)(void *, int *);
342 : typedef struct swig_type_info *(*swig_dycast_func)(void **);
343 :
344 : /* Structure to store information on one type */
345 : typedef struct swig_type_info {
346 : const char *name; /* mangled name of this type */
347 : const char *str; /* human readable name of this type */
348 : swig_dycast_func dcast; /* dynamic cast function down a hierarchy */
349 : struct swig_cast_info *cast; /* linked list of types that can cast into this type */
350 : void *clientdata; /* language specific type data */
351 : int owndata; /* flag if the structure owns the clientdata */
352 : } swig_type_info;
353 :
354 : /* Structure to store a type and conversion function used for casting */
355 : typedef struct swig_cast_info {
356 : swig_type_info *type; /* pointer to type that is equivalent to this type */
357 : swig_converter_func converter; /* function to cast the void pointers */
358 : struct swig_cast_info *next; /* pointer to next cast in linked list */
359 : struct swig_cast_info *prev; /* pointer to the previous cast */
360 : } swig_cast_info;
361 :
362 : /* Structure used to store module information
363 : * Each module generates one structure like this, and the runtime collects
364 : * all of these structures and stores them in a circularly linked list.*/
365 : typedef struct swig_module_info {
366 : swig_type_info **types; /* Array of pointers to swig_type_info structures that are in this module */
367 : size_t size; /* Number of types in this module */
368 : struct swig_module_info *next; /* Pointer to next element in circularly linked list */
369 : swig_type_info **type_initial; /* Array of initially generated type structures */
370 : swig_cast_info **cast_initial; /* Array of initially generated casting structures */
371 : void *clientdata; /* Language specific module data */
372 : } swig_module_info;
373 :
374 : /*
375 : Compare two type names skipping the space characters, therefore
376 : "char*" == "char *" and "Class<int>" == "Class<int >", etc.
377 :
378 : Return 0 when the two name types are equivalent, as in
379 : strncmp, but skipping ' '.
380 : */
381 : SWIGRUNTIME int
382 0 : SWIG_TypeNameComp(const char *f1, const char *l1,
383 : const char *f2, const char *l2) {
384 0 : for (;(f1 != l1) && (f2 != l2); ++f1, ++f2) {
385 0 : while ((*f1 == ' ') && (f1 != l1)) ++f1;
386 0 : while ((*f2 == ' ') && (f2 != l2)) ++f2;
387 0 : if (*f1 != *f2) return (*f1 > *f2) ? 1 : -1;
388 : }
389 0 : return (int)((l1 - f1) - (l2 - f2));
390 : }
391 :
392 : /*
393 : Check type equivalence in a name list like <name1>|<name2>|...
394 : Return 0 if equal, -1 if nb < tb, 1 if nb > tb
395 : */
396 : SWIGRUNTIME int
397 0 : SWIG_TypeCmp(const char *nb, const char *tb) {
398 0 : int equiv = 1;
399 0 : const char* te = tb + strlen(tb);
400 0 : const char* ne = nb;
401 0 : while (equiv != 0 && *ne) {
402 0 : for (nb = ne; *ne; ++ne) {
403 0 : if (*ne == '|') break;
404 : }
405 0 : equiv = SWIG_TypeNameComp(nb, ne, tb, te);
406 0 : if (*ne) ++ne;
407 : }
408 0 : return equiv;
409 : }
410 :
411 : /*
412 : Check type equivalence in a name list like <name1>|<name2>|...
413 : Return 0 if not equal, 1 if equal
414 : */
415 : SWIGRUNTIME int
416 0 : SWIG_TypeEquiv(const char *nb, const char *tb) {
417 0 : return SWIG_TypeCmp(nb, tb) == 0 ? 1 : 0;
418 : }
419 :
420 : /*
421 : Check the typename
422 : */
423 : SWIGRUNTIME swig_cast_info *
424 275 : SWIG_TypeCheck(const char *c, swig_type_info *ty) {
425 275 : if (ty) {
426 275 : swig_cast_info *iter = ty->cast;
427 275 : while (iter) {
428 275 : if (strcmp(iter->type->name, c) == 0) {
429 275 : if (iter == ty->cast)
430 : return iter;
431 : /* Move iter to the top of the linked list */
432 0 : iter->prev->next = iter->next;
433 0 : if (iter->next)
434 0 : iter->next->prev = iter->prev;
435 0 : iter->next = ty->cast;
436 0 : iter->prev = 0;
437 0 : if (ty->cast) ty->cast->prev = iter;
438 0 : ty->cast = iter;
439 0 : return iter;
440 : }
441 0 : iter = iter->next;
442 : }
443 : }
444 : return 0;
445 : }
446 :
447 : /*
448 : Identical to SWIG_TypeCheck, except strcmp is replaced with a pointer comparison
449 : */
450 : SWIGRUNTIME swig_cast_info *
451 : SWIG_TypeCheckStruct(swig_type_info *from, swig_type_info *ty) {
452 : if (ty) {
453 : swig_cast_info *iter = ty->cast;
454 : while (iter) {
455 : if (iter->type == from) {
456 : if (iter == ty->cast)
457 : return iter;
458 : /* Move iter to the top of the linked list */
459 : iter->prev->next = iter->next;
460 : if (iter->next)
461 : iter->next->prev = iter->prev;
462 : iter->next = ty->cast;
463 : iter->prev = 0;
464 : if (ty->cast) ty->cast->prev = iter;
465 : ty->cast = iter;
466 : return iter;
467 : }
468 : iter = iter->next;
469 : }
470 : }
471 : return 0;
472 : }
473 :
474 : /*
475 : Cast a pointer up an inheritance hierarchy
476 : */
477 : SWIGRUNTIMEINLINE void *
478 : SWIG_TypeCast(swig_cast_info *ty, void *ptr, int *newmemory) {
479 : return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr, newmemory);
480 : }
481 :
482 : /*
483 : Dynamic pointer casting. Down an inheritance hierarchy
484 : */
485 : SWIGRUNTIME swig_type_info *
486 : SWIG_TypeDynamicCast(swig_type_info *ty, void **ptr) {
487 : swig_type_info *lastty = ty;
488 : if (!ty || !ty->dcast) return ty;
489 : while (ty && (ty->dcast)) {
490 : ty = (*ty->dcast)(ptr);
491 : if (ty) lastty = ty;
492 : }
493 : return lastty;
494 : }
495 :
496 : /*
497 : Return the name associated with this type
498 : */
499 : SWIGRUNTIMEINLINE const char *
500 : SWIG_TypeName(const swig_type_info *ty) {
501 : return ty->name;
502 : }
503 :
504 : /*
505 : Return the pretty name associated with this type,
506 : that is an unmangled type name in a form presentable to the user.
507 : */
508 : SWIGRUNTIME const char *
509 0 : SWIG_TypePrettyName(const swig_type_info *type) {
510 : /* The "str" field contains the equivalent pretty names of the
511 : type, separated by vertical-bar characters. We choose
512 : to print the last name, as it is often (?) the most
513 : specific. */
514 0 : if (!type) return NULL;
515 0 : if (type->str != NULL) {
516 : const char *last_name = type->str;
517 : const char *s;
518 0 : for (s = type->str; *s; s++)
519 0 : if (*s == '|') last_name = s+1;
520 : return last_name;
521 : }
522 : else
523 0 : return type->name;
524 : }
525 :
526 : /*
527 : Set the clientdata field for a type
528 : */
529 : SWIGRUNTIME void
530 : SWIG_TypeClientData(swig_type_info *ti, void *clientdata) {
531 : swig_cast_info *cast = ti->cast;
532 : /* if (ti->clientdata == clientdata) return; */
533 : ti->clientdata = clientdata;
534 :
535 : while (cast) {
536 : if (!cast->converter) {
537 : swig_type_info *tc = cast->type;
538 : if (!tc->clientdata) {
539 : SWIG_TypeClientData(tc, clientdata);
540 : }
541 : }
542 : cast = cast->next;
543 : }
544 : }
545 : SWIGRUNTIME void
546 : SWIG_TypeNewClientData(swig_type_info *ti, void *clientdata) {
547 : SWIG_TypeClientData(ti, clientdata);
548 : ti->owndata = 1;
549 : }
550 :
551 : /*
552 : Search for a swig_type_info structure only by mangled name
553 : Search is a O(log #types)
554 :
555 : We start searching at module start, and finish searching when start == end.
556 : Note: if start == end at the beginning of the function, we go all the way around
557 : the circular list.
558 : */
559 : SWIGRUNTIME swig_type_info *
560 550 : SWIG_MangledTypeQueryModule(swig_module_info *start,
561 : swig_module_info *end,
562 : const char *name) {
563 550 : swig_module_info *iter = start;
564 550 : do {
565 550 : if (iter->size) {
566 550 : size_t l = 0;
567 550 : size_t r = iter->size - 1;
568 3292 : do {
569 : /* since l+r >= 0, we can (>> 1) instead (/ 2) */
570 3292 : size_t i = (l + r) >> 1;
571 3292 : const char *iname = iter->types[i]->name;
572 3292 : if (iname) {
573 3292 : int compare = strcmp(name, iname);
574 3292 : if (compare == 0) {
575 550 : return iter->types[i];
576 2742 : } else if (compare < 0) {
577 1096 : if (i) {
578 1096 : r = i - 1;
579 : } else {
580 : break;
581 : }
582 1646 : } else if (compare > 0) {
583 1646 : l = i + 1;
584 : }
585 : } else {
586 : break; /* should never happen */
587 : }
588 2742 : } while (l <= r);
589 : }
590 0 : iter = iter->next;
591 0 : } while (iter != end);
592 : return 0;
593 : }
594 :
595 : /*
596 : Search for a swig_type_info structure for either a mangled name or a human readable name.
597 : It first searches the mangled names of the types, which is a O(log #types)
598 : If a type is not found it then searches the human readable names, which is O(#types).
599 :
600 : We start searching at module start, and finish searching when start == end.
601 : Note: if start == end at the beginning of the function, we go all the way around
602 : the circular list.
603 : */
604 : SWIGRUNTIME swig_type_info *
605 0 : SWIG_TypeQueryModule(swig_module_info *start,
606 : swig_module_info *end,
607 : const char *name) {
608 : /* STEP 1: Search the name field using binary search */
609 0 : swig_type_info *ret = SWIG_MangledTypeQueryModule(start, end, name);
610 0 : if (ret) {
611 : return ret;
612 : } else {
613 : /* STEP 2: If the type hasn't been found, do a complete search
614 : of the str field (the human readable name) */
615 : swig_module_info *iter = start;
616 0 : do {
617 0 : size_t i = 0;
618 0 : for (; i < iter->size; ++i) {
619 0 : if (iter->types[i]->str && (SWIG_TypeEquiv(iter->types[i]->str, name)))
620 0 : return iter->types[i];
621 : }
622 0 : iter = iter->next;
623 0 : } while (iter != end);
624 : }
625 :
626 : /* neither found a match */
627 : return 0;
628 : }
629 :
630 : /*
631 : Pack binary data into a string
632 : */
633 : SWIGRUNTIME char *
634 0 : SWIG_PackData(char *c, void *ptr, size_t sz) {
635 0 : static const char hex[17] = "0123456789abcdef";
636 0 : const unsigned char *u = (unsigned char *) ptr;
637 0 : const unsigned char *eu = u + sz;
638 0 : for (; u != eu; ++u) {
639 0 : unsigned char uu = *u;
640 0 : *(c++) = hex[(uu & 0xf0) >> 4];
641 0 : *(c++) = hex[uu & 0xf];
642 : }
643 0 : return c;
644 : }
645 :
646 : /*
647 : Unpack binary data from a string
648 : */
649 : SWIGRUNTIME const char *
650 : SWIG_UnpackData(const char *c, void *ptr, size_t sz) {
651 : unsigned char *u = (unsigned char *) ptr;
652 : const unsigned char *eu = u + sz;
653 : for (; u != eu; ++u) {
654 : char d = *(c++);
655 : unsigned char uu;
656 : if ((d >= '0') && (d <= '9'))
657 : uu = (unsigned char)((d - '0') << 4);
658 : else if ((d >= 'a') && (d <= 'f'))
659 : uu = (unsigned char)((d - ('a'-10)) << 4);
660 : else
661 : return (char *) 0;
662 : d = *(c++);
663 : if ((d >= '0') && (d <= '9'))
664 : uu |= (unsigned char)(d - '0');
665 : else if ((d >= 'a') && (d <= 'f'))
666 : uu |= (unsigned char)(d - ('a'-10));
667 : else
668 : return (char *) 0;
669 : *u = uu;
670 : }
671 : return c;
672 : }
673 :
674 : /*
675 : Pack 'void *' into a string buffer.
676 : */
677 : SWIGRUNTIME char *
678 0 : SWIG_PackVoidPtr(char *buff, void *ptr, const char *name, size_t bsz) {
679 0 : char *r = buff;
680 0 : if ((2*sizeof(void *) + 2) > bsz) return 0;
681 0 : *(r++) = '_';
682 0 : r = SWIG_PackData(r,&ptr,sizeof(void *));
683 0 : if (strlen(name) + 1 > (bsz - (r - buff))) return 0;
684 0 : strcpy(r,name);
685 0 : return buff;
686 : }
687 :
688 : SWIGRUNTIME const char *
689 : SWIG_UnpackVoidPtr(const char *c, void **ptr, const char *name) {
690 : if (*c != '_') {
691 : if (strcmp(c,"NULL") == 0) {
692 : *ptr = (void *) 0;
693 : return name;
694 : } else {
695 : return 0;
696 : }
697 : }
698 : return SWIG_UnpackData(++c,ptr,sizeof(void *));
699 : }
700 :
701 : SWIGRUNTIME char *
702 0 : SWIG_PackDataName(char *buff, void *ptr, size_t sz, const char *name, size_t bsz) {
703 0 : char *r = buff;
704 0 : size_t lname = (name ? strlen(name) : 0);
705 0 : if ((2*sz + 2 + lname) > bsz) return 0;
706 0 : *(r++) = '_';
707 0 : r = SWIG_PackData(r,ptr,sz);
708 0 : if (lname) {
709 0 : strncpy(r,name,lname+1);
710 : } else {
711 0 : *r = 0;
712 : }
713 : return buff;
714 : }
715 :
716 : SWIGRUNTIME const char *
717 : SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) {
718 : if (*c != '_') {
719 : if (strcmp(c,"NULL") == 0) {
720 : memset(ptr,0,sz);
721 : return name;
722 : } else {
723 : return 0;
724 : }
725 : }
726 : return SWIG_UnpackData(++c,ptr,sz);
727 : }
728 :
729 : #ifdef __cplusplus
730 : }
731 : #endif
732 :
733 : /* Errors in SWIG */
734 : #define SWIG_UnknownError -1
735 : #define SWIG_IOError -2
736 : #define SWIG_RuntimeError -3
737 : #define SWIG_IndexError -4
738 : #define SWIG_TypeError -5
739 : #define SWIG_DivisionByZero -6
740 : #define SWIG_OverflowError -7
741 : #define SWIG_SyntaxError -8
742 : #define SWIG_ValueError -9
743 : #define SWIG_SystemError -10
744 : #define SWIG_AttributeError -11
745 : #define SWIG_MemoryError -12
746 : #define SWIG_NullReferenceError -13
747 :
748 :
749 :
750 : /* Compatibility macros for Python 3 */
751 : #if PY_VERSION_HEX >= 0x03000000
752 :
753 : #define PyClass_Check(obj) PyObject_IsInstance(obj, (PyObject *)&PyType_Type)
754 : #define PyInt_Check(x) PyLong_Check(x)
755 : #define PyInt_AsLong(x) PyLong_AsLong(x)
756 : #define PyInt_FromLong(x) PyLong_FromLong(x)
757 : #define PyInt_FromSize_t(x) PyLong_FromSize_t(x)
758 : #define PyString_Check(name) PyBytes_Check(name)
759 : #define PyString_FromString(x) PyUnicode_FromString(x)
760 : #define PyString_Format(fmt, args) PyUnicode_Format(fmt, args)
761 : #define PyString_AsString(str) PyBytes_AsString(str)
762 : #define PyString_Size(str) PyBytes_Size(str)
763 : #define PyString_InternFromString(key) PyUnicode_InternFromString(key)
764 : #define Py_TPFLAGS_HAVE_CLASS Py_TPFLAGS_BASETYPE
765 : #define PyString_AS_STRING(x) PyUnicode_AS_STRING(x)
766 : #define _PyLong_FromSsize_t(x) PyLong_FromSsize_t(x)
767 :
768 : #endif
769 :
770 : #ifndef Py_TYPE
771 : # define Py_TYPE(op) ((op)->ob_type)
772 : #endif
773 :
774 : /* SWIG APIs for compatibility of both Python 2 & 3 */
775 :
776 : #if PY_VERSION_HEX >= 0x03000000
777 : # define SWIG_Python_str_FromFormat PyUnicode_FromFormat
778 : #else
779 : # define SWIG_Python_str_FromFormat PyString_FromFormat
780 : #endif
781 :
782 :
783 : /* Warning: This function will allocate a new string in Python 3,
784 : * so please call SWIG_Python_str_DelForPy3(x) to free the space.
785 : */
786 : SWIGINTERN char*
787 : SWIG_Python_str_AsChar(PyObject *str)
788 : {
789 : #if PY_VERSION_HEX >= 0x03000000
790 : char *newstr = 0;
791 : str = PyUnicode_AsUTF8String(str);
792 : if (str) {
793 : char *cstr;
794 : Py_ssize_t len;
795 : PyBytes_AsStringAndSize(str, &cstr, &len);
796 : newstr = (char *) malloc(len+1);
797 : memcpy(newstr, cstr, len+1);
798 : Py_XDECREF(str);
799 : }
800 : return newstr;
801 : #else
802 : return PyString_AsString(str);
803 : #endif
804 : }
805 :
806 : #if PY_VERSION_HEX >= 0x03000000
807 : # define SWIG_Python_str_DelForPy3(x) free( (void*) (x) )
808 : #else
809 : # define SWIG_Python_str_DelForPy3(x)
810 : #endif
811 :
812 :
813 : SWIGINTERN PyObject*
814 275 : SWIG_Python_str_FromChar(const char *c)
815 : {
816 : #if PY_VERSION_HEX >= 0x03000000
817 275 : return PyUnicode_FromString(c);
818 : #else
819 : return PyString_FromString(c);
820 : #endif
821 : }
822 :
823 : #ifndef PyObject_DEL
824 : # define PyObject_DEL PyObject_Del
825 : #endif
826 :
827 : // SWIGPY_USE_CAPSULE is no longer used within SWIG itself, but some user
828 : // interface files check for it.
829 : # define SWIGPY_USE_CAPSULE
830 : # define SWIGPY_CAPSULE_NAME ("swig_runtime_data" SWIG_RUNTIME_VERSION ".type_pointer_capsule" SWIG_TYPE_TABLE_NAME)
831 :
832 : #if PY_VERSION_HEX < 0x03020000
833 : #define PyDescr_TYPE(x) (((PyDescrObject *)(x))->d_type)
834 : #define PyDescr_NAME(x) (((PyDescrObject *)(x))->d_name)
835 : #define Py_hash_t long
836 : #endif
837 :
838 : /* -----------------------------------------------------------------------------
839 : * error manipulation
840 : * ----------------------------------------------------------------------------- */
841 :
842 : SWIGRUNTIME PyObject*
843 : SWIG_Python_ErrorType(int code) {
844 : PyObject* type = 0;
845 : switch(code) {
846 : case SWIG_MemoryError:
847 : type = PyExc_MemoryError;
848 : break;
849 : case SWIG_IOError:
850 : type = PyExc_IOError;
851 : break;
852 : case SWIG_RuntimeError:
853 : type = PyExc_RuntimeError;
854 : break;
855 : case SWIG_IndexError:
856 : type = PyExc_IndexError;
857 : break;
858 : case SWIG_TypeError:
859 : type = PyExc_TypeError;
860 : break;
861 : case SWIG_DivisionByZero:
862 : type = PyExc_ZeroDivisionError;
863 : break;
864 : case SWIG_OverflowError:
865 : type = PyExc_OverflowError;
866 : break;
867 : case SWIG_SyntaxError:
868 : type = PyExc_SyntaxError;
869 : break;
870 : case SWIG_ValueError:
871 : type = PyExc_ValueError;
872 : break;
873 : case SWIG_SystemError:
874 : type = PyExc_SystemError;
875 : break;
876 : case SWIG_AttributeError:
877 : type = PyExc_AttributeError;
878 : break;
879 : default:
880 : type = PyExc_RuntimeError;
881 : }
882 : return type;
883 : }
884 :
885 :
886 : SWIGRUNTIME void
887 : SWIG_Python_AddErrorMsg(const char* mesg)
888 : {
889 : PyObject *type = 0;
890 : PyObject *value = 0;
891 : PyObject *traceback = 0;
892 :
893 : if (PyErr_Occurred())
894 : PyErr_Fetch(&type, &value, &traceback);
895 : if (value) {
896 : PyObject *old_str = PyObject_Str(value);
897 : const char *tmp = SWIG_Python_str_AsChar(old_str);
898 : PyErr_Clear();
899 : Py_XINCREF(type);
900 : if (tmp)
901 : PyErr_Format(type, "%s %s", tmp, mesg);
902 : else
903 : PyErr_Format(type, "%s", mesg);
904 : SWIG_Python_str_DelForPy3(tmp);
905 : Py_DECREF(old_str);
906 : Py_DECREF(value);
907 : } else {
908 : PyErr_SetString(PyExc_RuntimeError, mesg);
909 : }
910 : }
911 :
912 : SWIGRUNTIME int
913 : SWIG_Python_TypeErrorOccurred(PyObject *obj)
914 : {
915 : PyObject *error;
916 : if (obj)
917 : return 0;
918 : error = PyErr_Occurred();
919 : return error && PyErr_GivenExceptionMatches(error, PyExc_TypeError);
920 : }
921 :
922 : SWIGRUNTIME void
923 : SWIG_Python_RaiseOrModifyTypeError(const char *message)
924 : {
925 : if (SWIG_Python_TypeErrorOccurred(NULL)) {
926 : /* Use existing TypeError to preserve stacktrace and enhance with given message */
927 : PyObject *newvalue;
928 : PyObject *type = NULL, *value = NULL, *traceback = NULL;
929 : PyErr_Fetch(&type, &value, &traceback);
930 : #if PY_VERSION_HEX >= 0x03000000
931 : newvalue = PyUnicode_FromFormat("%S\nAdditional information:\n%s", value, message);
932 : #else
933 : newvalue = PyString_FromFormat("%s\nAdditional information:\n%s", PyString_AsString(value), message);
934 : #endif
935 : Py_XDECREF(value);
936 : PyErr_Restore(type, newvalue, traceback);
937 : } else {
938 : /* Raise TypeError using given message */
939 : PyErr_SetString(PyExc_TypeError, message);
940 : }
941 : }
942 :
943 : #if defined(SWIG_PYTHON_NO_THREADS)
944 : # if defined(SWIG_PYTHON_THREADS)
945 : # undef SWIG_PYTHON_THREADS
946 : # endif
947 : #endif
948 : #if defined(SWIG_PYTHON_THREADS) /* Threading support is enabled */
949 : # if !defined(SWIG_PYTHON_USE_GIL) && !defined(SWIG_PYTHON_NO_USE_GIL)
950 : # define SWIG_PYTHON_USE_GIL
951 : # endif
952 : # if defined(SWIG_PYTHON_USE_GIL) /* Use PyGILState threads calls */
953 : # ifndef SWIG_PYTHON_INITIALIZE_THREADS
954 : # define SWIG_PYTHON_INITIALIZE_THREADS PyEval_InitThreads()
955 : # endif
956 : # ifdef __cplusplus /* C++ code */
957 : class SWIG_Python_Thread_Block {
958 : bool status;
959 : PyGILState_STATE state;
960 : public:
961 : void end() { if (status) { PyGILState_Release(state); status = false;} }
962 : SWIG_Python_Thread_Block() : status(true), state(PyGILState_Ensure()) {}
963 : ~SWIG_Python_Thread_Block() { end(); }
964 : };
965 : class SWIG_Python_Thread_Allow {
966 : bool status;
967 : PyThreadState *save;
968 : public:
969 : void end() { if (status) { PyEval_RestoreThread(save); status = false; }}
970 : SWIG_Python_Thread_Allow() : status(true), save(PyEval_SaveThread()) {}
971 : ~SWIG_Python_Thread_Allow() { end(); }
972 : };
973 : # define SWIG_PYTHON_THREAD_BEGIN_BLOCK SWIG_Python_Thread_Block _swig_thread_block
974 : # define SWIG_PYTHON_THREAD_END_BLOCK _swig_thread_block.end()
975 : # define SWIG_PYTHON_THREAD_BEGIN_ALLOW SWIG_Python_Thread_Allow _swig_thread_allow
976 : # define SWIG_PYTHON_THREAD_END_ALLOW _swig_thread_allow.end()
977 : # else /* C code */
978 : # define SWIG_PYTHON_THREAD_BEGIN_BLOCK PyGILState_STATE _swig_thread_block = PyGILState_Ensure()
979 : # define SWIG_PYTHON_THREAD_END_BLOCK PyGILState_Release(_swig_thread_block)
980 : # define SWIG_PYTHON_THREAD_BEGIN_ALLOW PyThreadState *_swig_thread_allow = PyEval_SaveThread()
981 : # define SWIG_PYTHON_THREAD_END_ALLOW PyEval_RestoreThread(_swig_thread_allow)
982 : # endif
983 : # else /* Old thread way, not implemented, user must provide it */
984 : # if !defined(SWIG_PYTHON_INITIALIZE_THREADS)
985 : # define SWIG_PYTHON_INITIALIZE_THREADS
986 : # endif
987 : # if !defined(SWIG_PYTHON_THREAD_BEGIN_BLOCK)
988 : # define SWIG_PYTHON_THREAD_BEGIN_BLOCK
989 : # endif
990 : # if !defined(SWIG_PYTHON_THREAD_END_BLOCK)
991 : # define SWIG_PYTHON_THREAD_END_BLOCK
992 : # endif
993 : # if !defined(SWIG_PYTHON_THREAD_BEGIN_ALLOW)
994 : # define SWIG_PYTHON_THREAD_BEGIN_ALLOW
995 : # endif
996 : # if !defined(SWIG_PYTHON_THREAD_END_ALLOW)
997 : # define SWIG_PYTHON_THREAD_END_ALLOW
998 : # endif
999 : # endif
1000 : #else /* No thread support */
1001 : # define SWIG_PYTHON_INITIALIZE_THREADS
1002 : # define SWIG_PYTHON_THREAD_BEGIN_BLOCK
1003 : # define SWIG_PYTHON_THREAD_END_BLOCK
1004 : # define SWIG_PYTHON_THREAD_BEGIN_ALLOW
1005 : # define SWIG_PYTHON_THREAD_END_ALLOW
1006 : #endif
1007 :
1008 : /* -----------------------------------------------------------------------------
1009 : * Python API portion that goes into the runtime
1010 : * ----------------------------------------------------------------------------- */
1011 :
1012 : #ifdef __cplusplus
1013 : extern "C" {
1014 : #endif
1015 :
1016 : /* -----------------------------------------------------------------------------
1017 : * Constant declarations
1018 : * ----------------------------------------------------------------------------- */
1019 :
1020 : /* Constant Types */
1021 : #define SWIG_PY_POINTER 4
1022 : #define SWIG_PY_BINARY 5
1023 :
1024 : /* Constant information structure */
1025 : typedef struct swig_const_info {
1026 : int type;
1027 : const char *name;
1028 : long lvalue;
1029 : double dvalue;
1030 : void *pvalue;
1031 : swig_type_info **ptype;
1032 : } swig_const_info;
1033 :
1034 : #ifdef __cplusplus
1035 : }
1036 : #endif
1037 :
1038 :
1039 : /* -----------------------------------------------------------------------------
1040 : * pyrun.swg
1041 : *
1042 : * This file contains the runtime support for Python modules
1043 : * and includes code for managing global variables and pointer
1044 : * type checking.
1045 : *
1046 : * ----------------------------------------------------------------------------- */
1047 :
1048 : #if PY_VERSION_HEX < 0x02070000 /* 2.7.0 */
1049 : # error "This version of SWIG only supports Python >= 2.7"
1050 : #endif
1051 :
1052 : #if PY_VERSION_HEX >= 0x03000000 && PY_VERSION_HEX < 0x03020000
1053 : # error "This version of SWIG only supports Python 3 >= 3.2"
1054 : #endif
1055 :
1056 : /* Common SWIG API */
1057 :
1058 : /* for raw pointers */
1059 : #define SWIG_Python_ConvertPtr(obj, pptr, type, flags) SWIG_Python_ConvertPtrAndOwn(obj, pptr, type, flags, 0)
1060 : #define SWIG_ConvertPtr(obj, pptr, type, flags) SWIG_Python_ConvertPtr(obj, pptr, type, flags)
1061 : #define SWIG_ConvertPtrAndOwn(obj,pptr,type,flags,own) SWIG_Python_ConvertPtrAndOwn(obj, pptr, type, flags, own)
1062 :
1063 : #ifdef SWIGPYTHON_BUILTIN
1064 : #define SWIG_NewPointerObj(ptr, type, flags) SWIG_Python_NewPointerObj(self, ptr, type, flags)
1065 : #else
1066 : #define SWIG_NewPointerObj(ptr, type, flags) SWIG_Python_NewPointerObj(NULL, ptr, type, flags)
1067 : #endif
1068 :
1069 : #define SWIG_InternalNewPointerObj(ptr, type, flags) SWIG_Python_NewPointerObj(NULL, ptr, type, flags)
1070 :
1071 : #define SWIG_CheckImplicit(ty) SWIG_Python_CheckImplicit(ty)
1072 : #define SWIG_AcquirePtr(ptr, src) SWIG_Python_AcquirePtr(ptr, src)
1073 : #define swig_owntype int
1074 :
1075 : /* for raw packed data */
1076 : #define SWIG_ConvertPacked(obj, ptr, sz, ty) SWIG_Python_ConvertPacked(obj, ptr, sz, ty)
1077 : #define SWIG_NewPackedObj(ptr, sz, type) SWIG_Python_NewPackedObj(ptr, sz, type)
1078 :
1079 : /* for class or struct pointers */
1080 : #define SWIG_ConvertInstance(obj, pptr, type, flags) SWIG_ConvertPtr(obj, pptr, type, flags)
1081 : #define SWIG_NewInstanceObj(ptr, type, flags) SWIG_NewPointerObj(ptr, type, flags)
1082 :
1083 : /* for C or C++ function pointers */
1084 : #define SWIG_ConvertFunctionPtr(obj, pptr, type) SWIG_Python_ConvertFunctionPtr(obj, pptr, type)
1085 : #define SWIG_NewFunctionPtrObj(ptr, type) SWIG_Python_NewPointerObj(NULL, ptr, type, 0)
1086 :
1087 : /* for C++ member pointers, ie, member methods */
1088 : #define SWIG_ConvertMember(obj, ptr, sz, ty) SWIG_Python_ConvertPacked(obj, ptr, sz, ty)
1089 : #define SWIG_NewMemberObj(ptr, sz, type) SWIG_Python_NewPackedObj(ptr, sz, type)
1090 :
1091 :
1092 : /* Runtime API */
1093 :
1094 : #define SWIG_GetModule(clientdata) SWIG_Python_GetModule(clientdata)
1095 : #define SWIG_SetModule(clientdata, pointer) SWIG_Python_SetModule(pointer)
1096 : #define SWIG_NewClientData(obj) SwigPyClientData_New(obj)
1097 :
1098 : #define SWIG_SetErrorObj SWIG_Python_SetErrorObj
1099 : #define SWIG_SetErrorMsg SWIG_Python_SetErrorMsg
1100 : #define SWIG_ErrorType(code) SWIG_Python_ErrorType(code)
1101 : #define SWIG_Error(code, msg) SWIG_Python_SetErrorMsg(SWIG_ErrorType(code), msg)
1102 : #define SWIG_fail goto fail
1103 :
1104 :
1105 : /* Runtime API implementation */
1106 :
1107 : /* Error manipulation */
1108 :
1109 : SWIGINTERN void
1110 : SWIG_Python_SetErrorObj(PyObject *errtype, PyObject *obj) {
1111 : SWIG_PYTHON_THREAD_BEGIN_BLOCK;
1112 : PyErr_SetObject(errtype, obj);
1113 : Py_DECREF(obj);
1114 : SWIG_PYTHON_THREAD_END_BLOCK;
1115 : }
1116 :
1117 : SWIGINTERN void
1118 : SWIG_Python_SetErrorMsg(PyObject *errtype, const char *msg) {
1119 : SWIG_PYTHON_THREAD_BEGIN_BLOCK;
1120 : PyErr_SetString(errtype, msg);
1121 : SWIG_PYTHON_THREAD_END_BLOCK;
1122 : }
1123 :
1124 : #define SWIG_Python_Raise(obj, type, desc) SWIG_Python_SetErrorObj(SWIG_Python_ExceptionType(desc), obj)
1125 :
1126 : /* Set a constant value */
1127 :
1128 : #if defined(SWIGPYTHON_BUILTIN)
1129 :
1130 : SWIGINTERN void
1131 : SwigPyBuiltin_AddPublicSymbol(PyObject *seq, const char *key) {
1132 : PyObject *s = PyString_InternFromString(key);
1133 : PyList_Append(seq, s);
1134 : Py_DECREF(s);
1135 : }
1136 :
1137 : SWIGINTERN void
1138 : SWIG_Python_SetConstant(PyObject *d, PyObject *public_interface, const char *name, PyObject *obj) {
1139 : PyDict_SetItemString(d, name, obj);
1140 : Py_DECREF(obj);
1141 : if (public_interface)
1142 : SwigPyBuiltin_AddPublicSymbol(public_interface, name);
1143 : }
1144 :
1145 : #else
1146 :
1147 : SWIGINTERN void
1148 68200 : SWIG_Python_SetConstant(PyObject *d, const char *name, PyObject *obj) {
1149 68200 : PyDict_SetItemString(d, name, obj);
1150 68200 : Py_DECREF(obj);
1151 68200 : }
1152 :
1153 : #endif
1154 :
1155 : /* Append a value to the result obj */
1156 :
1157 : SWIGINTERN PyObject*
1158 : SWIG_Python_AppendOutput(PyObject* result, PyObject* obj) {
1159 : if (!result) {
1160 : result = obj;
1161 : } else if (result == Py_None) {
1162 : Py_DECREF(result);
1163 : result = obj;
1164 : } else {
1165 : if (!PyList_Check(result)) {
1166 : PyObject *o2 = result;
1167 : result = PyList_New(1);
1168 : PyList_SetItem(result, 0, o2);
1169 : }
1170 : PyList_Append(result,obj);
1171 : Py_DECREF(obj);
1172 : }
1173 : return result;
1174 : }
1175 :
1176 : /* Unpack the argument tuple */
1177 :
1178 : SWIGINTERN Py_ssize_t
1179 : SWIG_Python_UnpackTuple(PyObject *args, const char *name, Py_ssize_t min, Py_ssize_t max, PyObject **objs)
1180 : {
1181 : if (!args) {
1182 : if (!min && !max) {
1183 : return 1;
1184 : } else {
1185 : PyErr_Format(PyExc_TypeError, "%s expected %s%d arguments, got none",
1186 : name, (min == max ? "" : "at least "), (int)min);
1187 : return 0;
1188 : }
1189 : }
1190 : if (!PyTuple_Check(args)) {
1191 : if (min <= 1 && max >= 1) {
1192 : Py_ssize_t i;
1193 : objs[0] = args;
1194 : for (i = 1; i < max; ++i) {
1195 : objs[i] = 0;
1196 : }
1197 : return 2;
1198 : }
1199 : PyErr_SetString(PyExc_SystemError, "UnpackTuple() argument list is not a tuple");
1200 : return 0;
1201 : } else {
1202 : Py_ssize_t l = PyTuple_GET_SIZE(args);
1203 : if (l < min) {
1204 : PyErr_Format(PyExc_TypeError, "%s expected %s%d arguments, got %d",
1205 : name, (min == max ? "" : "at least "), (int)min, (int)l);
1206 : return 0;
1207 : } else if (l > max) {
1208 : PyErr_Format(PyExc_TypeError, "%s expected %s%d arguments, got %d",
1209 : name, (min == max ? "" : "at most "), (int)max, (int)l);
1210 : return 0;
1211 : } else {
1212 : Py_ssize_t i;
1213 : for (i = 0; i < l; ++i) {
1214 : objs[i] = PyTuple_GET_ITEM(args, i);
1215 : }
1216 : for (; l < max; ++l) {
1217 : objs[l] = 0;
1218 : }
1219 : return i + 1;
1220 : }
1221 : }
1222 : }
1223 :
1224 : /* A functor is a function object with one single object argument */
1225 : #define SWIG_Python_CallFunctor(functor, obj) PyObject_CallFunctionObjArgs(functor, obj, NULL);
1226 :
1227 : /*
1228 : Helper for static pointer initialization for both C and C++ code, for example
1229 : static PyObject *SWIG_STATIC_POINTER(MyVar) = NewSomething(...);
1230 : */
1231 : #ifdef __cplusplus
1232 : #define SWIG_STATIC_POINTER(var) var
1233 : #else
1234 : #define SWIG_STATIC_POINTER(var) var = 0; if (!var) var
1235 : #endif
1236 :
1237 : /* -----------------------------------------------------------------------------
1238 : * Pointer declarations
1239 : * ----------------------------------------------------------------------------- */
1240 :
1241 : /* Flags for new pointer objects */
1242 : #define SWIG_POINTER_NOSHADOW (SWIG_POINTER_OWN << 1)
1243 : #define SWIG_POINTER_NEW (SWIG_POINTER_NOSHADOW | SWIG_POINTER_OWN)
1244 :
1245 : #define SWIG_POINTER_IMPLICIT_CONV (SWIG_POINTER_DISOWN << 1)
1246 :
1247 : #define SWIG_BUILTIN_TP_INIT (SWIG_POINTER_OWN << 2)
1248 : #define SWIG_BUILTIN_INIT (SWIG_BUILTIN_TP_INIT | SWIG_POINTER_OWN)
1249 :
1250 : #ifdef __cplusplus
1251 : extern "C" {
1252 : #endif
1253 :
1254 : /* The python void return value */
1255 :
1256 : SWIGRUNTIMEINLINE PyObject *
1257 0 : SWIG_Py_Void(void)
1258 : {
1259 0 : PyObject *none = Py_None;
1260 0 : Py_INCREF(none);
1261 0 : return none;
1262 : }
1263 :
1264 : /* SwigPyClientData */
1265 :
1266 : typedef struct {
1267 : PyObject *klass;
1268 : PyObject *newraw;
1269 : PyObject *newargs;
1270 : PyObject *destroy;
1271 : int delargs;
1272 : int implicitconv;
1273 : PyTypeObject *pytype;
1274 : } SwigPyClientData;
1275 :
1276 : SWIGRUNTIMEINLINE int
1277 : SWIG_Python_CheckImplicit(swig_type_info *ty)
1278 : {
1279 : SwigPyClientData *data = (SwigPyClientData *)ty->clientdata;
1280 : int fail = data ? data->implicitconv : 0;
1281 : if (fail)
1282 : PyErr_SetString(PyExc_TypeError, "Implicit conversion is prohibited for explicit constructors.");
1283 : return fail;
1284 : }
1285 :
1286 : SWIGRUNTIMEINLINE PyObject *
1287 : SWIG_Python_ExceptionType(swig_type_info *desc) {
1288 : SwigPyClientData *data = desc ? (SwigPyClientData *) desc->clientdata : 0;
1289 : PyObject *klass = data ? data->klass : 0;
1290 : return (klass ? klass : PyExc_RuntimeError);
1291 : }
1292 :
1293 :
1294 : SWIGRUNTIME SwigPyClientData *
1295 : SwigPyClientData_New(PyObject* obj)
1296 : {
1297 : if (!obj) {
1298 : return 0;
1299 : } else {
1300 : SwigPyClientData *data = (SwigPyClientData *)malloc(sizeof(SwigPyClientData));
1301 : /* the klass element */
1302 : data->klass = obj;
1303 : Py_INCREF(data->klass);
1304 : /* the newraw method and newargs arguments used to create a new raw instance */
1305 : if (PyClass_Check(obj)) {
1306 : data->newraw = 0;
1307 : data->newargs = obj;
1308 : Py_INCREF(obj);
1309 : } else {
1310 : data->newraw = PyObject_GetAttrString(data->klass, "__new__");
1311 : if (data->newraw) {
1312 : Py_INCREF(data->newraw);
1313 : data->newargs = PyTuple_New(1);
1314 : PyTuple_SetItem(data->newargs, 0, obj);
1315 : } else {
1316 : data->newargs = obj;
1317 : }
1318 : Py_INCREF(data->newargs);
1319 : }
1320 : /* the destroy method, aka as the C++ delete method */
1321 : data->destroy = PyObject_GetAttrString(data->klass, "__swig_destroy__");
1322 : if (PyErr_Occurred()) {
1323 : PyErr_Clear();
1324 : data->destroy = 0;
1325 : }
1326 : if (data->destroy) {
1327 : int flags;
1328 : Py_INCREF(data->destroy);
1329 : flags = PyCFunction_GET_FLAGS(data->destroy);
1330 : data->delargs = !(flags & (METH_O));
1331 : } else {
1332 : data->delargs = 0;
1333 : }
1334 : data->implicitconv = 0;
1335 : data->pytype = 0;
1336 : return data;
1337 : }
1338 : }
1339 :
1340 : SWIGRUNTIME void
1341 0 : SwigPyClientData_Del(SwigPyClientData *data) {
1342 0 : Py_XDECREF(data->newraw);
1343 0 : Py_XDECREF(data->newargs);
1344 0 : Py_XDECREF(data->destroy);
1345 0 : }
1346 :
1347 : /* =============== SwigPyObject =====================*/
1348 :
1349 : typedef struct {
1350 : PyObject_HEAD
1351 : void *ptr;
1352 : swig_type_info *ty;
1353 : int own;
1354 : PyObject *next;
1355 : #ifdef SWIGPYTHON_BUILTIN
1356 : PyObject *dict;
1357 : #endif
1358 : } SwigPyObject;
1359 :
1360 :
1361 : #ifdef SWIGPYTHON_BUILTIN
1362 :
1363 : SWIGRUNTIME PyObject *
1364 : SwigPyObject_get___dict__(PyObject *v, PyObject *SWIGUNUSEDPARM(args))
1365 : {
1366 : SwigPyObject *sobj = (SwigPyObject *)v;
1367 :
1368 : if (!sobj->dict)
1369 : sobj->dict = PyDict_New();
1370 :
1371 : Py_INCREF(sobj->dict);
1372 : return sobj->dict;
1373 : }
1374 :
1375 : #endif
1376 :
1377 : SWIGRUNTIME PyObject *
1378 0 : SwigPyObject_long(SwigPyObject *v)
1379 : {
1380 0 : return PyLong_FromVoidPtr(v->ptr);
1381 : }
1382 :
1383 : SWIGRUNTIME PyObject *
1384 : SwigPyObject_format(const char* fmt, SwigPyObject *v)
1385 : {
1386 : PyObject *res = NULL;
1387 : PyObject *args = PyTuple_New(1);
1388 : if (args) {
1389 : if (PyTuple_SetItem(args, 0, SwigPyObject_long(v)) == 0) {
1390 : PyObject *ofmt = SWIG_Python_str_FromChar(fmt);
1391 : if (ofmt) {
1392 : #if PY_VERSION_HEX >= 0x03000000
1393 : res = PyUnicode_Format(ofmt,args);
1394 : #else
1395 : res = PyString_Format(ofmt,args);
1396 : #endif
1397 : Py_DECREF(ofmt);
1398 : }
1399 : Py_DECREF(args);
1400 : }
1401 : }
1402 : return res;
1403 : }
1404 :
1405 : SWIGRUNTIME PyObject *
1406 : SwigPyObject_oct(SwigPyObject *v)
1407 : {
1408 : return SwigPyObject_format("%o",v);
1409 : }
1410 :
1411 : SWIGRUNTIME PyObject *
1412 : SwigPyObject_hex(SwigPyObject *v)
1413 : {
1414 : return SwigPyObject_format("%x",v);
1415 : }
1416 :
1417 : SWIGRUNTIME PyObject *
1418 0 : SwigPyObject_repr(SwigPyObject *v)
1419 : {
1420 0 : const char *name = SWIG_TypePrettyName(v->ty);
1421 0 : PyObject *repr = SWIG_Python_str_FromFormat("<Swig Object of type '%s' at %p>", (name ? name : "unknown"), (void *)v);
1422 0 : if (v->next) {
1423 0 : PyObject *nrep = SwigPyObject_repr((SwigPyObject *)v->next);
1424 : # if PY_VERSION_HEX >= 0x03000000
1425 0 : PyObject *joined = PyUnicode_Concat(repr, nrep);
1426 0 : Py_DecRef(repr);
1427 0 : Py_DecRef(nrep);
1428 0 : repr = joined;
1429 : # else
1430 : PyString_ConcatAndDel(&repr,nrep);
1431 : # endif
1432 : }
1433 0 : return repr;
1434 : }
1435 :
1436 : /* We need a version taking two PyObject* parameters so it's a valid
1437 : * PyCFunction to use in swigobject_methods[]. */
1438 : SWIGRUNTIME PyObject *
1439 0 : SwigPyObject_repr2(PyObject *v, PyObject *SWIGUNUSEDPARM(args))
1440 : {
1441 0 : return SwigPyObject_repr((SwigPyObject*)v);
1442 : }
1443 :
1444 : SWIGRUNTIME int
1445 0 : SwigPyObject_compare(SwigPyObject *v, SwigPyObject *w)
1446 : {
1447 0 : void *i = v->ptr;
1448 0 : void *j = w->ptr;
1449 0 : return (i < j) ? -1 : ((i > j) ? 1 : 0);
1450 : }
1451 :
1452 : /* Added for Python 3.x, would it also be useful for Python 2.x? */
1453 : SWIGRUNTIME PyObject*
1454 0 : SwigPyObject_richcompare(SwigPyObject *v, SwigPyObject *w, int op)
1455 : {
1456 0 : PyObject* res;
1457 0 : if( op != Py_EQ && op != Py_NE ) {
1458 0 : Py_INCREF(Py_NotImplemented);
1459 0 : return Py_NotImplemented;
1460 : }
1461 0 : res = PyBool_FromLong( (SwigPyObject_compare(v, w)==0) == (op == Py_EQ) ? 1 : 0);
1462 0 : return res;
1463 : }
1464 :
1465 :
1466 : SWIGRUNTIME PyTypeObject* SwigPyObject_TypeOnce(void);
1467 :
1468 : #ifdef SWIGPYTHON_BUILTIN
1469 : static swig_type_info *SwigPyObject_stype = 0;
1470 : SWIGRUNTIME PyTypeObject*
1471 : SwigPyObject_type(void) {
1472 : SwigPyClientData *cd;
1473 : assert(SwigPyObject_stype);
1474 : cd = (SwigPyClientData*) SwigPyObject_stype->clientdata;
1475 : assert(cd);
1476 : assert(cd->pytype);
1477 : return cd->pytype;
1478 : }
1479 : #else
1480 : SWIGRUNTIME PyTypeObject*
1481 275 : SwigPyObject_type(void) {
1482 275 : static PyTypeObject *SWIG_STATIC_POINTER(type) = SwigPyObject_TypeOnce();
1483 0 : return type;
1484 : }
1485 : #endif
1486 :
1487 : SWIGRUNTIMEINLINE int
1488 : SwigPyObject_Check(PyObject *op) {
1489 : #ifdef SWIGPYTHON_BUILTIN
1490 : PyTypeObject *target_tp = SwigPyObject_type();
1491 : if (PyType_IsSubtype(op->ob_type, target_tp))
1492 : return 1;
1493 : return (strcmp(op->ob_type->tp_name, "SwigPyObject") == 0);
1494 : #else
1495 : return (Py_TYPE(op) == SwigPyObject_type())
1496 : || (strcmp(Py_TYPE(op)->tp_name,"SwigPyObject") == 0);
1497 : #endif
1498 : }
1499 :
1500 : SWIGRUNTIME PyObject *
1501 : SwigPyObject_New(void *ptr, swig_type_info *ty, int own);
1502 :
1503 : SWIGRUNTIME void
1504 0 : SwigPyObject_dealloc(PyObject *v)
1505 : {
1506 0 : SwigPyObject *sobj = (SwigPyObject *) v;
1507 0 : PyObject *next = sobj->next;
1508 0 : if (sobj->own == SWIG_POINTER_OWN) {
1509 0 : swig_type_info *ty = sobj->ty;
1510 0 : SwigPyClientData *data = ty ? (SwigPyClientData *) ty->clientdata : 0;
1511 0 : PyObject *destroy = data ? data->destroy : 0;
1512 0 : if (destroy) {
1513 : /* destroy is always a VARARGS method */
1514 0 : PyObject *res;
1515 :
1516 : /* PyObject_CallFunction() has the potential to silently drop
1517 : the active exception. In cases of unnamed temporary
1518 : variable or where we just finished iterating over a generator
1519 : StopIteration will be active right now, and this needs to
1520 : remain true upon return from SwigPyObject_dealloc. So save
1521 : and restore. */
1522 :
1523 0 : PyObject *type = NULL, *value = NULL, *traceback = NULL;
1524 0 : PyErr_Fetch(&type, &value, &traceback);
1525 :
1526 0 : if (data->delargs) {
1527 : /* we need to create a temporary object to carry the destroy operation */
1528 0 : PyObject *tmp = SwigPyObject_New(sobj->ptr, ty, 0);
1529 0 : res = SWIG_Python_CallFunctor(destroy, tmp);
1530 0 : Py_DECREF(tmp);
1531 : } else {
1532 0 : PyCFunction meth = PyCFunction_GET_FUNCTION(destroy);
1533 0 : PyObject *mself = PyCFunction_GET_SELF(destroy);
1534 0 : res = ((*meth)(mself, v));
1535 : }
1536 0 : if (!res)
1537 0 : PyErr_WriteUnraisable(destroy);
1538 :
1539 0 : PyErr_Restore(type, value, traceback);
1540 :
1541 0 : Py_XDECREF(res);
1542 : }
1543 : #if !defined(SWIG_PYTHON_SILENT_MEMLEAK)
1544 : else {
1545 : const char *name = SWIG_TypePrettyName(ty);
1546 : printf("swig/python detected a memory leak of type '%s', no destructor found.\n", (name ? name : "unknown"));
1547 : }
1548 : #endif
1549 : }
1550 0 : Py_XDECREF(next);
1551 0 : PyObject_DEL(v);
1552 0 : }
1553 :
1554 : SWIGRUNTIME PyObject*
1555 0 : SwigPyObject_append(PyObject* v, PyObject* next)
1556 : {
1557 0 : SwigPyObject *sobj = (SwigPyObject *) v;
1558 0 : if (!SwigPyObject_Check(next)) {
1559 0 : PyErr_SetString(PyExc_TypeError, "Attempt to append a non SwigPyObject");
1560 0 : return NULL;
1561 : }
1562 0 : sobj->next = next;
1563 0 : Py_INCREF(next);
1564 0 : return SWIG_Py_Void();
1565 : }
1566 :
1567 : SWIGRUNTIME PyObject*
1568 0 : SwigPyObject_next(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
1569 : {
1570 0 : SwigPyObject *sobj = (SwigPyObject *) v;
1571 0 : if (sobj->next) {
1572 0 : Py_INCREF(sobj->next);
1573 0 : return sobj->next;
1574 : } else {
1575 0 : return SWIG_Py_Void();
1576 : }
1577 : }
1578 :
1579 : SWIGINTERN PyObject*
1580 0 : SwigPyObject_disown(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
1581 : {
1582 0 : SwigPyObject *sobj = (SwigPyObject *)v;
1583 0 : sobj->own = 0;
1584 0 : return SWIG_Py_Void();
1585 : }
1586 :
1587 : SWIGINTERN PyObject*
1588 0 : SwigPyObject_acquire(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
1589 : {
1590 0 : SwigPyObject *sobj = (SwigPyObject *)v;
1591 0 : sobj->own = SWIG_POINTER_OWN;
1592 0 : return SWIG_Py_Void();
1593 : }
1594 :
1595 : SWIGINTERN PyObject*
1596 0 : SwigPyObject_own(PyObject *v, PyObject *args)
1597 : {
1598 0 : PyObject *val = 0;
1599 0 : if (!PyArg_UnpackTuple(args, "own", 0, 1, &val)) {
1600 : return NULL;
1601 : } else {
1602 0 : SwigPyObject *sobj = (SwigPyObject *)v;
1603 0 : PyObject *obj = PyBool_FromLong(sobj->own);
1604 0 : if (val) {
1605 0 : if (PyObject_IsTrue(val)) {
1606 0 : SwigPyObject_acquire(v,args);
1607 : } else {
1608 0 : SwigPyObject_disown(v,args);
1609 : }
1610 : }
1611 0 : return obj;
1612 : }
1613 : }
1614 :
1615 : static PyMethodDef
1616 : swigobject_methods[] = {
1617 : {"disown", SwigPyObject_disown, METH_NOARGS, "releases ownership of the pointer"},
1618 : {"acquire", SwigPyObject_acquire, METH_NOARGS, "acquires ownership of the pointer"},
1619 : {"own", SwigPyObject_own, METH_VARARGS, "returns/sets ownership of the pointer"},
1620 : {"append", SwigPyObject_append, METH_O, "appends another 'this' object"},
1621 : {"next", SwigPyObject_next, METH_NOARGS, "returns the next 'this' object"},
1622 : {"__repr__",SwigPyObject_repr2, METH_NOARGS, "returns object representation"},
1623 : {0, 0, 0, 0}
1624 : };
1625 :
1626 : SWIGRUNTIME PyTypeObject*
1627 275 : SwigPyObject_TypeOnce(void) {
1628 275 : static char swigobject_doc[] = "Swig object carries a C/C++ instance pointer";
1629 :
1630 275 : static PyNumberMethods SwigPyObject_as_number = {
1631 : (binaryfunc)0, /*nb_add*/
1632 : (binaryfunc)0, /*nb_subtract*/
1633 : (binaryfunc)0, /*nb_multiply*/
1634 : /* nb_divide removed in Python 3 */
1635 : #if PY_VERSION_HEX < 0x03000000
1636 : (binaryfunc)0, /*nb_divide*/
1637 : #endif
1638 : (binaryfunc)0, /*nb_remainder*/
1639 : (binaryfunc)0, /*nb_divmod*/
1640 : (ternaryfunc)0,/*nb_power*/
1641 : (unaryfunc)0, /*nb_negative*/
1642 : (unaryfunc)0, /*nb_positive*/
1643 : (unaryfunc)0, /*nb_absolute*/
1644 : (inquiry)0, /*nb_nonzero*/
1645 : 0, /*nb_invert*/
1646 : 0, /*nb_lshift*/
1647 : 0, /*nb_rshift*/
1648 : 0, /*nb_and*/
1649 : 0, /*nb_xor*/
1650 : 0, /*nb_or*/
1651 : #if PY_VERSION_HEX < 0x03000000
1652 : 0, /*nb_coerce*/
1653 : #endif
1654 : (unaryfunc)SwigPyObject_long, /*nb_int*/
1655 : #if PY_VERSION_HEX < 0x03000000
1656 : (unaryfunc)SwigPyObject_long, /*nb_long*/
1657 : #else
1658 : 0, /*nb_reserved*/
1659 : #endif
1660 : (unaryfunc)0, /*nb_float*/
1661 : #if PY_VERSION_HEX < 0x03000000
1662 : (unaryfunc)SwigPyObject_oct, /*nb_oct*/
1663 : (unaryfunc)SwigPyObject_hex, /*nb_hex*/
1664 : #endif
1665 : #if PY_VERSION_HEX >= 0x03050000 /* 3.5 */
1666 : 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_inplace_matrix_multiply */
1667 : #elif PY_VERSION_HEX >= 0x03000000 /* 3.0 */
1668 : 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_index, nb_inplace_divide removed */
1669 : #else
1670 : 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_index */
1671 : #endif
1672 : };
1673 :
1674 275 : static PyTypeObject swigpyobject_type;
1675 275 : static int type_init = 0;
1676 275 : if (!type_init) {
1677 275 : const PyTypeObject tmp = {
1678 : #if PY_VERSION_HEX >= 0x03000000
1679 : PyVarObject_HEAD_INIT(NULL, 0)
1680 : #else
1681 : PyObject_HEAD_INIT(NULL)
1682 : 0, /* ob_size */
1683 : #endif
1684 : "SwigPyObject", /* tp_name */
1685 : sizeof(SwigPyObject), /* tp_basicsize */
1686 : 0, /* tp_itemsize */
1687 : (destructor)SwigPyObject_dealloc, /* tp_dealloc */
1688 : 0, /* tp_print */
1689 : (getattrfunc)0, /* tp_getattr */
1690 : (setattrfunc)0, /* tp_setattr */
1691 : #if PY_VERSION_HEX >= 0x03000000
1692 : 0, /* tp_reserved in 3.0.1, tp_compare in 3.0.0 but not used */
1693 : #else
1694 : (cmpfunc)SwigPyObject_compare, /* tp_compare */
1695 : #endif
1696 : (reprfunc)SwigPyObject_repr, /* tp_repr */
1697 : &SwigPyObject_as_number, /* tp_as_number */
1698 : 0, /* tp_as_sequence */
1699 : 0, /* tp_as_mapping */
1700 : (hashfunc)0, /* tp_hash */
1701 : (ternaryfunc)0, /* tp_call */
1702 : 0, /* tp_str */
1703 : PyObject_GenericGetAttr, /* tp_getattro */
1704 : 0, /* tp_setattro */
1705 : 0, /* tp_as_buffer */
1706 : Py_TPFLAGS_DEFAULT, /* tp_flags */
1707 : swigobject_doc, /* tp_doc */
1708 : 0, /* tp_traverse */
1709 : 0, /* tp_clear */
1710 : (richcmpfunc)SwigPyObject_richcompare,/* tp_richcompare */
1711 : 0, /* tp_weaklistoffset */
1712 : 0, /* tp_iter */
1713 : 0, /* tp_iternext */
1714 : swigobject_methods, /* tp_methods */
1715 : 0, /* tp_members */
1716 : 0, /* tp_getset */
1717 : 0, /* tp_base */
1718 : 0, /* tp_dict */
1719 : 0, /* tp_descr_get */
1720 : 0, /* tp_descr_set */
1721 : 0, /* tp_dictoffset */
1722 : 0, /* tp_init */
1723 : 0, /* tp_alloc */
1724 : 0, /* tp_new */
1725 : 0, /* tp_free */
1726 : 0, /* tp_is_gc */
1727 : 0, /* tp_bases */
1728 : 0, /* tp_mro */
1729 : 0, /* tp_cache */
1730 : 0, /* tp_subclasses */
1731 : 0, /* tp_weaklist */
1732 : 0, /* tp_del */
1733 : 0, /* tp_version_tag */
1734 : #if PY_VERSION_HEX >= 0x03040000
1735 : 0, /* tp_finalize */
1736 : #endif
1737 : #ifdef COUNT_ALLOCS
1738 : 0, /* tp_allocs */
1739 : 0, /* tp_frees */
1740 : 0, /* tp_maxalloc */
1741 : 0, /* tp_prev */
1742 : 0 /* tp_next */
1743 : #endif
1744 : };
1745 275 : swigpyobject_type = tmp;
1746 275 : type_init = 1;
1747 275 : if (PyType_Ready(&swigpyobject_type) < 0)
1748 0 : return NULL;
1749 : }
1750 : return &swigpyobject_type;
1751 : }
1752 :
1753 : SWIGRUNTIME PyObject *
1754 0 : SwigPyObject_New(void *ptr, swig_type_info *ty, int own)
1755 : {
1756 0 : SwigPyObject *sobj = PyObject_NEW(SwigPyObject, SwigPyObject_type());
1757 0 : if (sobj) {
1758 0 : sobj->ptr = ptr;
1759 0 : sobj->ty = ty;
1760 0 : sobj->own = own;
1761 0 : sobj->next = 0;
1762 : }
1763 0 : return (PyObject *)sobj;
1764 : }
1765 :
1766 : /* -----------------------------------------------------------------------------
1767 : * Implements a simple Swig Packed type, and use it instead of string
1768 : * ----------------------------------------------------------------------------- */
1769 :
1770 : typedef struct {
1771 : PyObject_HEAD
1772 : void *pack;
1773 : swig_type_info *ty;
1774 : size_t size;
1775 : } SwigPyPacked;
1776 :
1777 : SWIGRUNTIME PyObject *
1778 0 : SwigPyPacked_repr(SwigPyPacked *v)
1779 : {
1780 0 : char result[SWIG_BUFFER_SIZE];
1781 0 : if (SWIG_PackDataName(result, v->pack, v->size, 0, sizeof(result))) {
1782 0 : return SWIG_Python_str_FromFormat("<Swig Packed at %s%s>", result, v->ty->name);
1783 : } else {
1784 0 : return SWIG_Python_str_FromFormat("<Swig Packed %s>", v->ty->name);
1785 : }
1786 : }
1787 :
1788 : SWIGRUNTIME PyObject *
1789 0 : SwigPyPacked_str(SwigPyPacked *v)
1790 : {
1791 0 : char result[SWIG_BUFFER_SIZE];
1792 0 : if (SWIG_PackDataName(result, v->pack, v->size, 0, sizeof(result))){
1793 0 : return SWIG_Python_str_FromFormat("%s%s", result, v->ty->name);
1794 : } else {
1795 0 : return SWIG_Python_str_FromChar(v->ty->name);
1796 : }
1797 : }
1798 :
1799 : SWIGRUNTIME int
1800 : SwigPyPacked_compare(SwigPyPacked *v, SwigPyPacked *w)
1801 : {
1802 : size_t i = v->size;
1803 : size_t j = w->size;
1804 : int s = (i < j) ? -1 : ((i > j) ? 1 : 0);
1805 : return s ? s : strncmp((const char *)v->pack, (const char *)w->pack, 2*v->size);
1806 : }
1807 :
1808 : SWIGRUNTIME PyTypeObject* SwigPyPacked_TypeOnce(void);
1809 :
1810 : SWIGRUNTIME PyTypeObject*
1811 275 : SwigPyPacked_type(void) {
1812 275 : static PyTypeObject *SWIG_STATIC_POINTER(type) = SwigPyPacked_TypeOnce();
1813 0 : return type;
1814 : }
1815 :
1816 : SWIGRUNTIMEINLINE int
1817 : SwigPyPacked_Check(PyObject *op) {
1818 : return ((op)->ob_type == SwigPyPacked_TypeOnce())
1819 : || (strcmp((op)->ob_type->tp_name,"SwigPyPacked") == 0);
1820 : }
1821 :
1822 : SWIGRUNTIME void
1823 0 : SwigPyPacked_dealloc(PyObject *v)
1824 : {
1825 0 : if (SwigPyPacked_Check(v)) {
1826 0 : SwigPyPacked *sobj = (SwigPyPacked *) v;
1827 0 : free(sobj->pack);
1828 : }
1829 0 : PyObject_DEL(v);
1830 0 : }
1831 :
1832 : SWIGRUNTIME PyTypeObject*
1833 275 : SwigPyPacked_TypeOnce(void) {
1834 275 : static char swigpacked_doc[] = "Swig object carries a C/C++ instance pointer";
1835 275 : static PyTypeObject swigpypacked_type;
1836 275 : static int type_init = 0;
1837 275 : if (!type_init) {
1838 275 : const PyTypeObject tmp = {
1839 : #if PY_VERSION_HEX>=0x03000000
1840 : PyVarObject_HEAD_INIT(NULL, 0)
1841 : #else
1842 : PyObject_HEAD_INIT(NULL)
1843 : 0, /* ob_size */
1844 : #endif
1845 : "SwigPyPacked", /* tp_name */
1846 : sizeof(SwigPyPacked), /* tp_basicsize */
1847 : 0, /* tp_itemsize */
1848 : (destructor)SwigPyPacked_dealloc, /* tp_dealloc */
1849 : 0, /* tp_print */
1850 : (getattrfunc)0, /* tp_getattr */
1851 : (setattrfunc)0, /* tp_setattr */
1852 : #if PY_VERSION_HEX>=0x03000000
1853 : 0, /* tp_reserved in 3.0.1 */
1854 : #else
1855 : (cmpfunc)SwigPyPacked_compare, /* tp_compare */
1856 : #endif
1857 : (reprfunc)SwigPyPacked_repr, /* tp_repr */
1858 : 0, /* tp_as_number */
1859 : 0, /* tp_as_sequence */
1860 : 0, /* tp_as_mapping */
1861 : (hashfunc)0, /* tp_hash */
1862 : (ternaryfunc)0, /* tp_call */
1863 : (reprfunc)SwigPyPacked_str, /* tp_str */
1864 : PyObject_GenericGetAttr, /* tp_getattro */
1865 : 0, /* tp_setattro */
1866 : 0, /* tp_as_buffer */
1867 : Py_TPFLAGS_DEFAULT, /* tp_flags */
1868 : swigpacked_doc, /* tp_doc */
1869 : 0, /* tp_traverse */
1870 : 0, /* tp_clear */
1871 : 0, /* tp_richcompare */
1872 : 0, /* tp_weaklistoffset */
1873 : 0, /* tp_iter */
1874 : 0, /* tp_iternext */
1875 : 0, /* tp_methods */
1876 : 0, /* tp_members */
1877 : 0, /* tp_getset */
1878 : 0, /* tp_base */
1879 : 0, /* tp_dict */
1880 : 0, /* tp_descr_get */
1881 : 0, /* tp_descr_set */
1882 : 0, /* tp_dictoffset */
1883 : 0, /* tp_init */
1884 : 0, /* tp_alloc */
1885 : 0, /* tp_new */
1886 : 0, /* tp_free */
1887 : 0, /* tp_is_gc */
1888 : 0, /* tp_bases */
1889 : 0, /* tp_mro */
1890 : 0, /* tp_cache */
1891 : 0, /* tp_subclasses */
1892 : 0, /* tp_weaklist */
1893 : 0, /* tp_del */
1894 : 0, /* tp_version_tag */
1895 : #if PY_VERSION_HEX >= 0x03040000
1896 : 0, /* tp_finalize */
1897 : #endif
1898 : #ifdef COUNT_ALLOCS
1899 : 0, /* tp_allocs */
1900 : 0, /* tp_frees */
1901 : 0, /* tp_maxalloc */
1902 : 0, /* tp_prev */
1903 : 0 /* tp_next */
1904 : #endif
1905 : };
1906 275 : swigpypacked_type = tmp;
1907 275 : type_init = 1;
1908 275 : if (PyType_Ready(&swigpypacked_type) < 0)
1909 0 : return NULL;
1910 : }
1911 : return &swigpypacked_type;
1912 : }
1913 :
1914 : SWIGRUNTIME PyObject *
1915 0 : SwigPyPacked_New(void *ptr, size_t size, swig_type_info *ty)
1916 : {
1917 0 : SwigPyPacked *sobj = PyObject_NEW(SwigPyPacked, SwigPyPacked_type());
1918 0 : if (sobj) {
1919 0 : void *pack = malloc(size);
1920 0 : if (pack) {
1921 0 : memcpy(pack, ptr, size);
1922 0 : sobj->pack = pack;
1923 0 : sobj->ty = ty;
1924 0 : sobj->size = size;
1925 : } else {
1926 0 : PyObject_DEL((PyObject *) sobj);
1927 0 : sobj = 0;
1928 : }
1929 : }
1930 0 : return (PyObject *) sobj;
1931 : }
1932 :
1933 : SWIGRUNTIME swig_type_info *
1934 : SwigPyPacked_UnpackData(PyObject *obj, void *ptr, size_t size)
1935 : {
1936 : if (SwigPyPacked_Check(obj)) {
1937 : SwigPyPacked *sobj = (SwigPyPacked *)obj;
1938 : if (sobj->size != size) return 0;
1939 : memcpy(ptr, sobj->pack, size);
1940 : return sobj->ty;
1941 : } else {
1942 : return 0;
1943 : }
1944 : }
1945 :
1946 : /* -----------------------------------------------------------------------------
1947 : * pointers/data manipulation
1948 : * ----------------------------------------------------------------------------- */
1949 :
1950 : static PyObject *Swig_This_global = NULL;
1951 :
1952 : SWIGRUNTIME PyObject *
1953 275 : SWIG_This(void)
1954 : {
1955 275 : if (Swig_This_global == NULL)
1956 275 : Swig_This_global = SWIG_Python_str_FromChar("this");
1957 275 : return Swig_This_global;
1958 : }
1959 :
1960 : /* #define SWIG_PYTHON_SLOW_GETSET_THIS */
1961 :
1962 : /* TODO: I don't know how to implement the fast getset in Python 3 right now */
1963 : #if PY_VERSION_HEX>=0x03000000
1964 : #define SWIG_PYTHON_SLOW_GETSET_THIS
1965 : #endif
1966 :
1967 : SWIGRUNTIME SwigPyObject *
1968 : SWIG_Python_GetSwigThis(PyObject *pyobj)
1969 : {
1970 : PyObject *obj;
1971 :
1972 : if (SwigPyObject_Check(pyobj))
1973 : return (SwigPyObject *) pyobj;
1974 :
1975 : #ifdef SWIGPYTHON_BUILTIN
1976 : (void)obj;
1977 : # ifdef PyWeakref_CheckProxy
1978 : if (PyWeakref_CheckProxy(pyobj)) {
1979 : pyobj = PyWeakref_GET_OBJECT(pyobj);
1980 : if (pyobj && SwigPyObject_Check(pyobj))
1981 : return (SwigPyObject*) pyobj;
1982 : }
1983 : # endif
1984 : return NULL;
1985 : #else
1986 :
1987 : obj = 0;
1988 :
1989 : #if !defined(SWIG_PYTHON_SLOW_GETSET_THIS)
1990 : if (PyInstance_Check(pyobj)) {
1991 : obj = _PyInstance_Lookup(pyobj, SWIG_This());
1992 : } else {
1993 : PyObject **dictptr = _PyObject_GetDictPtr(pyobj);
1994 : if (dictptr != NULL) {
1995 : PyObject *dict = *dictptr;
1996 : obj = dict ? PyDict_GetItem(dict, SWIG_This()) : 0;
1997 : } else {
1998 : #ifdef PyWeakref_CheckProxy
1999 : if (PyWeakref_CheckProxy(pyobj)) {
2000 : PyObject *wobj = PyWeakref_GET_OBJECT(pyobj);
2001 : return wobj ? SWIG_Python_GetSwigThis(wobj) : 0;
2002 : }
2003 : #endif
2004 : obj = PyObject_GetAttr(pyobj,SWIG_This());
2005 : if (obj) {
2006 : Py_DECREF(obj);
2007 : } else {
2008 : if (PyErr_Occurred()) PyErr_Clear();
2009 : return 0;
2010 : }
2011 : }
2012 : }
2013 : #else
2014 : obj = PyObject_GetAttr(pyobj,SWIG_This());
2015 : if (obj) {
2016 : Py_DECREF(obj);
2017 : } else {
2018 : if (PyErr_Occurred()) PyErr_Clear();
2019 : return 0;
2020 : }
2021 : #endif
2022 : if (obj && !SwigPyObject_Check(obj)) {
2023 : /* a PyObject is called 'this', try to get the 'real this'
2024 : SwigPyObject from it */
2025 : return SWIG_Python_GetSwigThis(obj);
2026 : }
2027 : return (SwigPyObject *)obj;
2028 : #endif
2029 : }
2030 :
2031 : /* Acquire a pointer value */
2032 :
2033 : SWIGRUNTIME int
2034 : SWIG_Python_AcquirePtr(PyObject *obj, int own) {
2035 : if (own == SWIG_POINTER_OWN) {
2036 : SwigPyObject *sobj = SWIG_Python_GetSwigThis(obj);
2037 : if (sobj) {
2038 : int oldown = sobj->own;
2039 : sobj->own = own;
2040 : return oldown;
2041 : }
2042 : }
2043 : return 0;
2044 : }
2045 :
2046 : /* Convert a pointer value */
2047 :
2048 : SWIGRUNTIME int
2049 : SWIG_Python_ConvertPtrAndOwn(PyObject *obj, void **ptr, swig_type_info *ty, int flags, int *own) {
2050 : int res;
2051 : SwigPyObject *sobj;
2052 : int implicit_conv = (flags & SWIG_POINTER_IMPLICIT_CONV) != 0;
2053 :
2054 : if (!obj)
2055 : return SWIG_ERROR;
2056 : if (obj == Py_None && !implicit_conv) {
2057 : if (ptr)
2058 : *ptr = 0;
2059 : return (flags & SWIG_POINTER_NO_NULL) ? SWIG_NullReferenceError : SWIG_OK;
2060 : }
2061 :
2062 : res = SWIG_ERROR;
2063 :
2064 : sobj = SWIG_Python_GetSwigThis(obj);
2065 : if (own)
2066 : *own = 0;
2067 : while (sobj) {
2068 : void *vptr = sobj->ptr;
2069 : if (ty) {
2070 : swig_type_info *to = sobj->ty;
2071 : if (to == ty) {
2072 : /* no type cast needed */
2073 : if (ptr) *ptr = vptr;
2074 : break;
2075 : } else {
2076 : swig_cast_info *tc = SWIG_TypeCheck(to->name,ty);
2077 : if (!tc) {
2078 : sobj = (SwigPyObject *)sobj->next;
2079 : } else {
2080 : if (ptr) {
2081 : int newmemory = 0;
2082 : *ptr = SWIG_TypeCast(tc,vptr,&newmemory);
2083 : if (newmemory == SWIG_CAST_NEW_MEMORY) {
2084 : assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */
2085 : if (own)
2086 : *own = *own | SWIG_CAST_NEW_MEMORY;
2087 : }
2088 : }
2089 : break;
2090 : }
2091 : }
2092 : } else {
2093 : if (ptr) *ptr = vptr;
2094 : break;
2095 : }
2096 : }
2097 : if (sobj) {
2098 : if (own)
2099 : *own = *own | sobj->own;
2100 : if (flags & SWIG_POINTER_DISOWN) {
2101 : sobj->own = 0;
2102 : }
2103 : res = SWIG_OK;
2104 : } else {
2105 : if (implicit_conv) {
2106 : SwigPyClientData *data = ty ? (SwigPyClientData *) ty->clientdata : 0;
2107 : if (data && !data->implicitconv) {
2108 : PyObject *klass = data->klass;
2109 : if (klass) {
2110 : PyObject *impconv;
2111 : data->implicitconv = 1; /* avoid recursion and call 'explicit' constructors*/
2112 : impconv = SWIG_Python_CallFunctor(klass, obj);
2113 : data->implicitconv = 0;
2114 : if (PyErr_Occurred()) {
2115 : PyErr_Clear();
2116 : impconv = 0;
2117 : }
2118 : if (impconv) {
2119 : SwigPyObject *iobj = SWIG_Python_GetSwigThis(impconv);
2120 : if (iobj) {
2121 : void *vptr;
2122 : res = SWIG_Python_ConvertPtrAndOwn((PyObject*)iobj, &vptr, ty, 0, 0);
2123 : if (SWIG_IsOK(res)) {
2124 : if (ptr) {
2125 : *ptr = vptr;
2126 : /* transfer the ownership to 'ptr' */
2127 : iobj->own = 0;
2128 : res = SWIG_AddCast(res);
2129 : res = SWIG_AddNewMask(res);
2130 : } else {
2131 : res = SWIG_AddCast(res);
2132 : }
2133 : }
2134 : }
2135 : Py_DECREF(impconv);
2136 : }
2137 : }
2138 : }
2139 : if (!SWIG_IsOK(res) && obj == Py_None) {
2140 : if (ptr)
2141 : *ptr = 0;
2142 : if (PyErr_Occurred())
2143 : PyErr_Clear();
2144 : res = SWIG_OK;
2145 : }
2146 : }
2147 : }
2148 : return res;
2149 : }
2150 :
2151 : /* Convert a function ptr value */
2152 :
2153 : SWIGRUNTIME int
2154 : SWIG_Python_ConvertFunctionPtr(PyObject *obj, void **ptr, swig_type_info *ty) {
2155 : if (!PyCFunction_Check(obj)) {
2156 : return SWIG_ConvertPtr(obj, ptr, ty, 0);
2157 : } else {
2158 : void *vptr = 0;
2159 : swig_cast_info *tc;
2160 :
2161 : /* here we get the method pointer for callbacks */
2162 : const char *doc = (((PyCFunctionObject *)obj) -> m_ml -> ml_doc);
2163 : const char *desc = doc ? strstr(doc, "swig_ptr: ") : 0;
2164 : if (desc)
2165 : desc = ty ? SWIG_UnpackVoidPtr(desc + 10, &vptr, ty->name) : 0;
2166 : if (!desc)
2167 : return SWIG_ERROR;
2168 : tc = SWIG_TypeCheck(desc,ty);
2169 : if (tc) {
2170 : int newmemory = 0;
2171 : *ptr = SWIG_TypeCast(tc,vptr,&newmemory);
2172 : assert(!newmemory); /* newmemory handling not yet implemented */
2173 : } else {
2174 : return SWIG_ERROR;
2175 : }
2176 : return SWIG_OK;
2177 : }
2178 : }
2179 :
2180 : /* Convert a packed pointer value */
2181 :
2182 : SWIGRUNTIME int
2183 : SWIG_Python_ConvertPacked(PyObject *obj, void *ptr, size_t sz, swig_type_info *ty) {
2184 : swig_type_info *to = SwigPyPacked_UnpackData(obj, ptr, sz);
2185 : if (!to) return SWIG_ERROR;
2186 : if (ty) {
2187 : if (to != ty) {
2188 : /* check type cast? */
2189 : swig_cast_info *tc = SWIG_TypeCheck(to->name,ty);
2190 : if (!tc) return SWIG_ERROR;
2191 : }
2192 : }
2193 : return SWIG_OK;
2194 : }
2195 :
2196 : /* -----------------------------------------------------------------------------
2197 : * Create a new pointer object
2198 : * ----------------------------------------------------------------------------- */
2199 :
2200 : /*
2201 : Create a new instance object, without calling __init__, and set the
2202 : 'this' attribute.
2203 : */
2204 :
2205 : SWIGRUNTIME PyObject*
2206 : SWIG_Python_NewShadowInstance(SwigPyClientData *data, PyObject *swig_this)
2207 : {
2208 : PyObject *inst = 0;
2209 : PyObject *newraw = data->newraw;
2210 : if (newraw) {
2211 : inst = PyObject_Call(newraw, data->newargs, NULL);
2212 : if (inst) {
2213 : #if !defined(SWIG_PYTHON_SLOW_GETSET_THIS)
2214 : PyObject **dictptr = _PyObject_GetDictPtr(inst);
2215 : if (dictptr != NULL) {
2216 : PyObject *dict = *dictptr;
2217 : if (dict == NULL) {
2218 : dict = PyDict_New();
2219 : *dictptr = dict;
2220 : PyDict_SetItem(dict, SWIG_This(), swig_this);
2221 : }
2222 : }
2223 : #else
2224 : PyObject *key = SWIG_This();
2225 : PyObject_SetAttr(inst, key, swig_this);
2226 : #endif
2227 : }
2228 : } else {
2229 : #if PY_VERSION_HEX >= 0x03000000
2230 : PyObject *empty_args = PyTuple_New(0);
2231 : if (empty_args) {
2232 : PyObject *empty_kwargs = PyDict_New();
2233 : if (empty_kwargs) {
2234 : inst = ((PyTypeObject *)data->newargs)->tp_new((PyTypeObject *)data->newargs, empty_args, empty_kwargs);
2235 : Py_DECREF(empty_kwargs);
2236 : if (inst) {
2237 : PyObject_SetAttr(inst, SWIG_This(), swig_this);
2238 : Py_TYPE(inst)->tp_flags &= ~Py_TPFLAGS_VALID_VERSION_TAG;
2239 : }
2240 : }
2241 : Py_DECREF(empty_args);
2242 : }
2243 : #else
2244 : PyObject *dict = PyDict_New();
2245 : if (dict) {
2246 : PyDict_SetItem(dict, SWIG_This(), swig_this);
2247 : inst = PyInstance_NewRaw(data->newargs, dict);
2248 : Py_DECREF(dict);
2249 : }
2250 : #endif
2251 : }
2252 : return inst;
2253 : }
2254 :
2255 : SWIGRUNTIME void
2256 : SWIG_Python_SetSwigThis(PyObject *inst, PyObject *swig_this)
2257 : {
2258 : PyObject *dict;
2259 : #if !defined(SWIG_PYTHON_SLOW_GETSET_THIS)
2260 : PyObject **dictptr = _PyObject_GetDictPtr(inst);
2261 : if (dictptr != NULL) {
2262 : dict = *dictptr;
2263 : if (dict == NULL) {
2264 : dict = PyDict_New();
2265 : *dictptr = dict;
2266 : }
2267 : PyDict_SetItem(dict, SWIG_This(), swig_this);
2268 : return;
2269 : }
2270 : #endif
2271 : dict = PyObject_GetAttrString(inst, "__dict__");
2272 : PyDict_SetItem(dict, SWIG_This(), swig_this);
2273 : Py_DECREF(dict);
2274 : }
2275 :
2276 :
2277 : SWIGINTERN PyObject *
2278 : SWIG_Python_InitShadowInstance(PyObject *args) {
2279 : PyObject *obj[2];
2280 : if (!SWIG_Python_UnpackTuple(args, "swiginit", 2, 2, obj)) {
2281 : return NULL;
2282 : } else {
2283 : SwigPyObject *sthis = SWIG_Python_GetSwigThis(obj[0]);
2284 : if (sthis) {
2285 : SwigPyObject_append((PyObject*) sthis, obj[1]);
2286 : } else {
2287 : SWIG_Python_SetSwigThis(obj[0], obj[1]);
2288 : }
2289 : return SWIG_Py_Void();
2290 : }
2291 : }
2292 :
2293 : /* Create a new pointer object */
2294 :
2295 : SWIGRUNTIME PyObject *
2296 0 : SWIG_Python_NewPointerObj(PyObject *self, void *ptr, swig_type_info *type, int flags) {
2297 0 : SwigPyClientData *clientdata;
2298 0 : PyObject * robj;
2299 0 : int own;
2300 :
2301 0 : if (!ptr)
2302 0 : return SWIG_Py_Void();
2303 :
2304 0 : clientdata = type ? (SwigPyClientData *)(type->clientdata) : 0;
2305 0 : own = (flags & SWIG_POINTER_OWN) ? SWIG_POINTER_OWN : 0;
2306 0 : if (clientdata && clientdata->pytype) {
2307 0 : SwigPyObject *newobj;
2308 0 : if (flags & SWIG_BUILTIN_TP_INIT) {
2309 0 : newobj = (SwigPyObject*) self;
2310 0 : if (newobj->ptr) {
2311 0 : PyObject *next_self = clientdata->pytype->tp_alloc(clientdata->pytype, 0);
2312 0 : while (newobj->next)
2313 : newobj = (SwigPyObject *) newobj->next;
2314 0 : newobj->next = next_self;
2315 0 : newobj = (SwigPyObject *)next_self;
2316 : #ifdef SWIGPYTHON_BUILTIN
2317 : newobj->dict = 0;
2318 : #endif
2319 : }
2320 : } else {
2321 0 : newobj = PyObject_New(SwigPyObject, clientdata->pytype);
2322 : #ifdef SWIGPYTHON_BUILTIN
2323 : newobj->dict = 0;
2324 : #endif
2325 : }
2326 0 : if (newobj) {
2327 0 : newobj->ptr = ptr;
2328 0 : newobj->ty = type;
2329 0 : newobj->own = own;
2330 0 : newobj->next = 0;
2331 0 : return (PyObject*) newobj;
2332 : }
2333 0 : return SWIG_Py_Void();
2334 : }
2335 :
2336 0 : assert(!(flags & SWIG_BUILTIN_TP_INIT));
2337 :
2338 0 : robj = SwigPyObject_New(ptr, type, own);
2339 0 : if (robj && clientdata && !(flags & SWIG_POINTER_NOSHADOW)) {
2340 0 : PyObject *inst = SWIG_Python_NewShadowInstance(clientdata, robj);
2341 0 : Py_DECREF(robj);
2342 : robj = inst;
2343 : }
2344 : return robj;
2345 : }
2346 :
2347 : /* Create a new packed object */
2348 :
2349 : SWIGRUNTIMEINLINE PyObject *
2350 0 : SWIG_Python_NewPackedObj(void *ptr, size_t sz, swig_type_info *type) {
2351 0 : return ptr ? SwigPyPacked_New((void *) ptr, sz, type) : SWIG_Py_Void();
2352 : }
2353 :
2354 : /* -----------------------------------------------------------------------------*
2355 : * Get type list
2356 : * -----------------------------------------------------------------------------*/
2357 :
2358 : #ifdef SWIG_LINK_RUNTIME
2359 : void *SWIG_ReturnGlobalTypeList(void *);
2360 : #endif
2361 :
2362 : SWIGRUNTIME swig_module_info *
2363 : SWIG_Python_GetModule(void *SWIGUNUSEDPARM(clientdata)) {
2364 : static void *type_pointer = (void *)0;
2365 : /* first check if module already created */
2366 : if (!type_pointer) {
2367 : #ifdef SWIG_LINK_RUNTIME
2368 : type_pointer = SWIG_ReturnGlobalTypeList((void *)0);
2369 : #else
2370 : type_pointer = PyCapsule_Import(SWIGPY_CAPSULE_NAME, 0);
2371 : if (PyErr_Occurred()) {
2372 : PyErr_Clear();
2373 : type_pointer = (void *)0;
2374 : }
2375 : #endif
2376 : }
2377 : return (swig_module_info *) type_pointer;
2378 : }
2379 :
2380 : SWIGRUNTIME void
2381 0 : SWIG_Python_DestroyModule(PyObject *obj)
2382 : {
2383 0 : swig_module_info *swig_module = (swig_module_info *) PyCapsule_GetPointer(obj, SWIGPY_CAPSULE_NAME);
2384 0 : swig_type_info **types = swig_module->types;
2385 0 : size_t i;
2386 0 : for (i =0; i < swig_module->size; ++i) {
2387 0 : swig_type_info *ty = types[i];
2388 0 : if (ty->owndata) {
2389 0 : SwigPyClientData *data = (SwigPyClientData *) ty->clientdata;
2390 0 : if (data) SwigPyClientData_Del(data);
2391 : }
2392 : }
2393 0 : Py_DECREF(SWIG_This());
2394 0 : Swig_This_global = NULL;
2395 0 : }
2396 :
2397 : SWIGRUNTIME void
2398 0 : SWIG_Python_SetModule(swig_module_info *swig_module) {
2399 : #if PY_VERSION_HEX >= 0x03000000
2400 : /* Add a dummy module object into sys.modules */
2401 0 : PyObject *module = PyImport_AddModule("swig_runtime_data" SWIG_RUNTIME_VERSION);
2402 : #else
2403 : static PyMethodDef swig_empty_runtime_method_table[] = { {NULL, NULL, 0, NULL} }; /* Sentinel */
2404 : PyObject *module = Py_InitModule("swig_runtime_data" SWIG_RUNTIME_VERSION, swig_empty_runtime_method_table);
2405 : #endif
2406 0 : PyObject *pointer = PyCapsule_New((void *) swig_module, SWIGPY_CAPSULE_NAME, SWIG_Python_DestroyModule);
2407 0 : if (pointer && module) {
2408 0 : PyModule_AddObject(module, "type_pointer_capsule" SWIG_TYPE_TABLE_NAME, pointer);
2409 : } else {
2410 0 : Py_XDECREF(pointer);
2411 : }
2412 0 : }
2413 :
2414 : /* The python cached type query */
2415 : SWIGRUNTIME PyObject *
2416 275 : SWIG_Python_TypeCache(void) {
2417 275 : static PyObject *SWIG_STATIC_POINTER(cache) = PyDict_New();
2418 275 : return cache;
2419 : }
2420 :
2421 : SWIGRUNTIME swig_type_info *
2422 0 : SWIG_Python_TypeQuery(const char *type)
2423 : {
2424 0 : PyObject *cache = SWIG_Python_TypeCache();
2425 0 : PyObject *key = SWIG_Python_str_FromChar(type);
2426 0 : PyObject *obj = PyDict_GetItem(cache, key);
2427 0 : swig_type_info *descriptor;
2428 0 : if (obj) {
2429 0 : descriptor = (swig_type_info *) PyCapsule_GetPointer(obj, NULL);
2430 : } else {
2431 0 : swig_module_info *swig_module = SWIG_GetModule(0);
2432 0 : descriptor = SWIG_TypeQueryModule(swig_module, swig_module, type);
2433 0 : if (descriptor) {
2434 0 : obj = PyCapsule_New((void*) descriptor, NULL, NULL);
2435 0 : PyDict_SetItem(cache, key, obj);
2436 0 : Py_DECREF(obj);
2437 : }
2438 : }
2439 0 : Py_DECREF(key);
2440 0 : return descriptor;
2441 : }
2442 :
2443 : /*
2444 : For backward compatibility only
2445 : */
2446 : #define SWIG_POINTER_EXCEPTION 0
2447 : #define SWIG_arg_fail(arg) SWIG_Python_ArgFail(arg)
2448 : #define SWIG_MustGetPtr(p, type, argnum, flags) SWIG_Python_MustGetPtr(p, type, argnum, flags)
2449 :
2450 : SWIGRUNTIME int
2451 : SWIG_Python_AddErrMesg(const char* mesg, int infront)
2452 : {
2453 : if (PyErr_Occurred()) {
2454 : PyObject *type = 0;
2455 : PyObject *value = 0;
2456 : PyObject *traceback = 0;
2457 : PyErr_Fetch(&type, &value, &traceback);
2458 : if (value) {
2459 : PyObject *old_str = PyObject_Str(value);
2460 : const char *tmp = SWIG_Python_str_AsChar(old_str);
2461 : const char *errmesg = tmp ? tmp : "Invalid error message";
2462 : Py_XINCREF(type);
2463 : PyErr_Clear();
2464 : if (infront) {
2465 : PyErr_Format(type, "%s %s", mesg, errmesg);
2466 : } else {
2467 : PyErr_Format(type, "%s %s", errmesg, mesg);
2468 : }
2469 : SWIG_Python_str_DelForPy3(tmp);
2470 : Py_DECREF(old_str);
2471 : }
2472 : return 1;
2473 : } else {
2474 : return 0;
2475 : }
2476 : }
2477 :
2478 : SWIGRUNTIME int
2479 : SWIG_Python_ArgFail(int argnum)
2480 : {
2481 : if (PyErr_Occurred()) {
2482 : /* add information about failing argument */
2483 : char mesg[256];
2484 : PyOS_snprintf(mesg, sizeof(mesg), "argument number %d:", argnum);
2485 : return SWIG_Python_AddErrMesg(mesg, 1);
2486 : } else {
2487 : return 0;
2488 : }
2489 : }
2490 :
2491 : SWIGRUNTIMEINLINE const char *
2492 : SwigPyObject_GetDesc(PyObject *self)
2493 : {
2494 : SwigPyObject *v = (SwigPyObject *)self;
2495 : swig_type_info *ty = v ? v->ty : 0;
2496 : return ty ? ty->str : "";
2497 : }
2498 :
2499 : SWIGRUNTIME void
2500 : SWIG_Python_TypeError(const char *type, PyObject *obj)
2501 : {
2502 : if (type) {
2503 : #if defined(SWIG_COBJECT_TYPES)
2504 : if (obj && SwigPyObject_Check(obj)) {
2505 : const char *otype = (const char *) SwigPyObject_GetDesc(obj);
2506 : if (otype) {
2507 : PyErr_Format(PyExc_TypeError, "a '%s' is expected, 'SwigPyObject(%s)' is received",
2508 : type, otype);
2509 : return;
2510 : }
2511 : } else
2512 : #endif
2513 : {
2514 : const char *otype = (obj ? obj->ob_type->tp_name : 0);
2515 : if (otype) {
2516 : PyObject *str = PyObject_Str(obj);
2517 : const char *cstr = str ? SWIG_Python_str_AsChar(str) : 0;
2518 : if (cstr) {
2519 : PyErr_Format(PyExc_TypeError, "a '%s' is expected, '%s(%s)' is received",
2520 : type, otype, cstr);
2521 : SWIG_Python_str_DelForPy3(cstr);
2522 : } else {
2523 : PyErr_Format(PyExc_TypeError, "a '%s' is expected, '%s' is received",
2524 : type, otype);
2525 : }
2526 : Py_XDECREF(str);
2527 : return;
2528 : }
2529 : }
2530 : PyErr_Format(PyExc_TypeError, "a '%s' is expected", type);
2531 : } else {
2532 : PyErr_Format(PyExc_TypeError, "unexpected type is received");
2533 : }
2534 : }
2535 :
2536 :
2537 : /* Convert a pointer value, signal an exception on a type mismatch */
2538 : SWIGRUNTIME void *
2539 : SWIG_Python_MustGetPtr(PyObject *obj, swig_type_info *ty, int SWIGUNUSEDPARM(argnum), int flags) {
2540 : void *result;
2541 : if (SWIG_Python_ConvertPtr(obj, &result, ty, flags) == -1) {
2542 : PyErr_Clear();
2543 : #if SWIG_POINTER_EXCEPTION
2544 : if (flags) {
2545 : SWIG_Python_TypeError(SWIG_TypePrettyName(ty), obj);
2546 : SWIG_Python_ArgFail(argnum);
2547 : }
2548 : #endif
2549 : }
2550 : return result;
2551 : }
2552 :
2553 : #ifdef SWIGPYTHON_BUILTIN
2554 : SWIGRUNTIME int
2555 : SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) {
2556 : PyTypeObject *tp = obj->ob_type;
2557 : PyObject *descr;
2558 : PyObject *encoded_name;
2559 : descrsetfunc f;
2560 : int res = -1;
2561 :
2562 : # ifdef Py_USING_UNICODE
2563 : if (PyString_Check(name)) {
2564 : name = PyUnicode_Decode(PyString_AsString(name), PyString_Size(name), NULL, NULL);
2565 : if (!name)
2566 : return -1;
2567 : } else if (!PyUnicode_Check(name))
2568 : # else
2569 : if (!PyString_Check(name))
2570 : # endif
2571 : {
2572 : PyErr_Format(PyExc_TypeError, "attribute name must be string, not '%.200s'", name->ob_type->tp_name);
2573 : return -1;
2574 : } else {
2575 : Py_INCREF(name);
2576 : }
2577 :
2578 : if (!tp->tp_dict) {
2579 : if (PyType_Ready(tp) < 0)
2580 : goto done;
2581 : }
2582 :
2583 : descr = _PyType_Lookup(tp, name);
2584 : f = NULL;
2585 : if (descr != NULL)
2586 : f = descr->ob_type->tp_descr_set;
2587 : if (!f) {
2588 : if (PyString_Check(name)) {
2589 : encoded_name = name;
2590 : Py_INCREF(name);
2591 : } else {
2592 : encoded_name = PyUnicode_AsUTF8String(name);
2593 : if (!encoded_name)
2594 : return -1;
2595 : }
2596 : PyErr_Format(PyExc_AttributeError, "'%.100s' object has no attribute '%.200s'", tp->tp_name, PyString_AsString(encoded_name));
2597 : Py_DECREF(encoded_name);
2598 : } else {
2599 : res = f(descr, obj, value);
2600 : }
2601 :
2602 : done:
2603 : Py_DECREF(name);
2604 : return res;
2605 : }
2606 : #endif
2607 :
2608 :
2609 : #ifdef __cplusplus
2610 : }
2611 : #endif
2612 :
2613 :
2614 :
2615 : #define SWIG_exception_fail(code, msg) do { SWIG_Error(code, msg); SWIG_fail; } while(0)
2616 :
2617 : #define SWIG_contract_assert(expr, msg) if (!(expr)) { SWIG_Error(SWIG_RuntimeError, msg); SWIG_fail; } else
2618 :
2619 :
2620 :
2621 : #ifdef __cplusplus
2622 : extern "C" {
2623 : #endif
2624 :
2625 : /* Method creation and docstring support functions */
2626 :
2627 : SWIGINTERN PyMethodDef *SWIG_PythonGetProxyDoc(const char *name);
2628 : SWIGINTERN PyObject *SWIG_PyInstanceMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func);
2629 : SWIGINTERN PyObject *SWIG_PyStaticMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func);
2630 :
2631 : #ifdef __cplusplus
2632 : }
2633 : #endif
2634 :
2635 :
2636 : /* -------- TYPES TABLE (BEGIN) -------- */
2637 :
2638 : #define SWIGTYPE_p_char swig_types[0]
2639 : static swig_type_info *swig_types[2];
2640 : static swig_module_info swig_module = {swig_types, 1, 0, 0, 0, 0};
2641 : #define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name)
2642 : #define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name)
2643 :
2644 : /* -------- TYPES TABLE (END) -------- */
2645 :
2646 : #ifdef SWIG_TypeQuery
2647 : # undef SWIG_TypeQuery
2648 : #endif
2649 : #define SWIG_TypeQuery SWIG_Python_TypeQuery
2650 :
2651 : /*-----------------------------------------------
2652 : @(target):= _gdalconst.so
2653 : ------------------------------------------------*/
2654 : #if PY_VERSION_HEX >= 0x03000000
2655 : # define SWIG_init PyInit__gdalconst
2656 :
2657 : #else
2658 : # define SWIG_init init_gdalconst
2659 :
2660 : #endif
2661 : #define SWIG_name "_gdalconst"
2662 :
2663 : #define SWIGVERSION 0x040001
2664 : #define SWIG_VERSION SWIGVERSION
2665 :
2666 :
2667 : #define SWIG_as_voidptr(a) (void *)((const void *)(a))
2668 : #define SWIG_as_voidptrptr(a) ((void)SWIG_as_voidptr(*a),(void**)(a))
2669 :
2670 :
2671 : #include "gdal.h"
2672 : #include "gdalwarper.h"
2673 : #include "cpl_string.h"
2674 : #include "cpl_minixml.h"
2675 :
2676 :
2677 : SWIGINTERNINLINE PyObject*
2678 48125 : SWIG_From_int (int value)
2679 : {
2680 48125 : return PyInt_FromLong((long) value);
2681 : }
2682 :
2683 :
2684 : SWIGINTERN swig_type_info*
2685 0 : SWIG_pchar_descriptor(void)
2686 : {
2687 0 : static int init = 0;
2688 0 : static swig_type_info* info = 0;
2689 0 : if (!init) {
2690 0 : info = SWIG_TypeQuery("_p_char");
2691 0 : init = 1;
2692 : }
2693 0 : return info;
2694 : }
2695 :
2696 :
2697 : SWIGINTERNINLINE PyObject *
2698 20075 : SWIG_FromCharPtrAndSize(const char* carray, size_t size)
2699 : {
2700 20075 : if (carray) {
2701 20075 : if (size > INT_MAX) {
2702 0 : swig_type_info* pchar_descriptor = SWIG_pchar_descriptor();
2703 0 : return pchar_descriptor ?
2704 0 : SWIG_InternalNewPointerObj((char *)(carray), pchar_descriptor, 0) : SWIG_Py_Void();
2705 : } else {
2706 : #if PY_VERSION_HEX >= 0x03000000
2707 : #if defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
2708 : return PyBytes_FromStringAndSize(carray, (Py_ssize_t)(size));
2709 : #else
2710 20075 : return PyUnicode_DecodeUTF8(carray, (Py_ssize_t)(size), "surrogateescape");
2711 : #endif
2712 : #else
2713 : return PyString_FromStringAndSize(carray, (Py_ssize_t)(size));
2714 : #endif
2715 : }
2716 : } else {
2717 0 : return SWIG_Py_Void();
2718 : }
2719 : }
2720 :
2721 :
2722 : SWIGINTERNINLINE PyObject *
2723 20075 : SWIG_FromCharPtr(const char *cptr)
2724 : {
2725 20075 : return SWIG_FromCharPtrAndSize(cptr, (cptr ? strlen(cptr) : 0));
2726 : }
2727 :
2728 : #ifdef __cplusplus
2729 : extern "C" {
2730 : #endif
2731 : static PyMethodDef SwigMethods[] = {
2732 : { "SWIG_PyInstanceMethod_New", SWIG_PyInstanceMethod_New, METH_O, NULL},
2733 : { NULL, NULL, 0, NULL }
2734 : };
2735 :
2736 : static PyMethodDef SwigMethods_proxydocs[] = {
2737 : { NULL, NULL, 0, NULL }
2738 : };
2739 :
2740 :
2741 : /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */
2742 :
2743 : static swig_type_info _swigt__p_char = {"_p_char", "char *", 0, 0, (void*)0, 0};
2744 :
2745 : static swig_type_info *swig_type_initial[] = {
2746 : &_swigt__p_char,
2747 : };
2748 :
2749 : static swig_cast_info _swigc__p_char[] = { {&_swigt__p_char, 0, 0, 0},{0, 0, 0, 0}};
2750 :
2751 : static swig_cast_info *swig_cast_initial[] = {
2752 : _swigc__p_char,
2753 : };
2754 :
2755 :
2756 : /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (END) -------- */
2757 :
2758 : static swig_const_info swig_const_table[] = {
2759 : {0, 0, 0, 0.0, 0, 0}};
2760 :
2761 : #ifdef __cplusplus
2762 : }
2763 : #endif
2764 : /* -----------------------------------------------------------------------------
2765 : * Type initialization:
2766 : * This problem is tough by the requirement that no dynamic
2767 : * memory is used. Also, since swig_type_info structures store pointers to
2768 : * swig_cast_info structures and swig_cast_info structures store pointers back
2769 : * to swig_type_info structures, we need some lookup code at initialization.
2770 : * The idea is that swig generates all the structures that are needed.
2771 : * The runtime then collects these partially filled structures.
2772 : * The SWIG_InitializeModule function takes these initial arrays out of
2773 : * swig_module, and does all the lookup, filling in the swig_module.types
2774 : * array with the correct data and linking the correct swig_cast_info
2775 : * structures together.
2776 : *
2777 : * The generated swig_type_info structures are assigned statically to an initial
2778 : * array. We just loop through that array, and handle each type individually.
2779 : * First we lookup if this type has been already loaded, and if so, use the
2780 : * loaded structure instead of the generated one. Then we have to fill in the
2781 : * cast linked list. The cast data is initially stored in something like a
2782 : * two-dimensional array. Each row corresponds to a type (there are the same
2783 : * number of rows as there are in the swig_type_initial array). Each entry in
2784 : * a column is one of the swig_cast_info structures for that type.
2785 : * The cast_initial array is actually an array of arrays, because each row has
2786 : * a variable number of columns. So to actually build the cast linked list,
2787 : * we find the array of casts associated with the type, and loop through it
2788 : * adding the casts to the list. The one last trick we need to do is making
2789 : * sure the type pointer in the swig_cast_info struct is correct.
2790 : *
2791 : * First off, we lookup the cast->type name to see if it is already loaded.
2792 : * There are three cases to handle:
2793 : * 1) If the cast->type has already been loaded AND the type we are adding
2794 : * casting info to has not been loaded (it is in this module), THEN we
2795 : * replace the cast->type pointer with the type pointer that has already
2796 : * been loaded.
2797 : * 2) If BOTH types (the one we are adding casting info to, and the
2798 : * cast->type) are loaded, THEN the cast info has already been loaded by
2799 : * the previous module so we just ignore it.
2800 : * 3) Finally, if cast->type has not already been loaded, then we add that
2801 : * swig_cast_info to the linked list (because the cast->type) pointer will
2802 : * be correct.
2803 : * ----------------------------------------------------------------------------- */
2804 :
2805 : #ifdef __cplusplus
2806 : extern "C" {
2807 : #if 0
2808 : } /* c-mode */
2809 : #endif
2810 : #endif
2811 :
2812 : #if 0
2813 : #define SWIGRUNTIME_DEBUG
2814 : #endif
2815 :
2816 :
2817 : SWIGRUNTIME void
2818 : SWIG_InitializeModule(void *clientdata) {
2819 : size_t i;
2820 : swig_module_info *module_head, *iter;
2821 : int init;
2822 :
2823 : /* check to see if the circular list has been setup, if not, set it up */
2824 : if (swig_module.next==0) {
2825 : /* Initialize the swig_module */
2826 : swig_module.type_initial = swig_type_initial;
2827 : swig_module.cast_initial = swig_cast_initial;
2828 : swig_module.next = &swig_module;
2829 : init = 1;
2830 : } else {
2831 : init = 0;
2832 : }
2833 :
2834 : /* Try and load any already created modules */
2835 : module_head = SWIG_GetModule(clientdata);
2836 : if (!module_head) {
2837 : /* This is the first module loaded for this interpreter */
2838 : /* so set the swig module into the interpreter */
2839 : SWIG_SetModule(clientdata, &swig_module);
2840 : } else {
2841 : /* the interpreter has loaded a SWIG module, but has it loaded this one? */
2842 : iter=module_head;
2843 : do {
2844 : if (iter==&swig_module) {
2845 : /* Our module is already in the list, so there's nothing more to do. */
2846 : return;
2847 : }
2848 : iter=iter->next;
2849 : } while (iter!= module_head);
2850 :
2851 : /* otherwise we must add our module into the list */
2852 : swig_module.next = module_head->next;
2853 : module_head->next = &swig_module;
2854 : }
2855 :
2856 : /* When multiple interpreters are used, a module could have already been initialized in
2857 : a different interpreter, but not yet have a pointer in this interpreter.
2858 : In this case, we do not want to continue adding types... everything should be
2859 : set up already */
2860 : if (init == 0) return;
2861 :
2862 : /* Now work on filling in swig_module.types */
2863 : #ifdef SWIGRUNTIME_DEBUG
2864 : printf("SWIG_InitializeModule: size %lu\n", (unsigned long)swig_module.size);
2865 : #endif
2866 : for (i = 0; i < swig_module.size; ++i) {
2867 : swig_type_info *type = 0;
2868 : swig_type_info *ret;
2869 : swig_cast_info *cast;
2870 :
2871 : #ifdef SWIGRUNTIME_DEBUG
2872 : printf("SWIG_InitializeModule: type %lu %s\n", (unsigned long)i, swig_module.type_initial[i]->name);
2873 : #endif
2874 :
2875 : /* if there is another module already loaded */
2876 : if (swig_module.next != &swig_module) {
2877 : type = SWIG_MangledTypeQueryModule(swig_module.next, &swig_module, swig_module.type_initial[i]->name);
2878 : }
2879 : if (type) {
2880 : /* Overwrite clientdata field */
2881 : #ifdef SWIGRUNTIME_DEBUG
2882 : printf("SWIG_InitializeModule: found type %s\n", type->name);
2883 : #endif
2884 : if (swig_module.type_initial[i]->clientdata) {
2885 : type->clientdata = swig_module.type_initial[i]->clientdata;
2886 : #ifdef SWIGRUNTIME_DEBUG
2887 : printf("SWIG_InitializeModule: found and overwrite type %s \n", type->name);
2888 : #endif
2889 : }
2890 : } else {
2891 : type = swig_module.type_initial[i];
2892 : }
2893 :
2894 : /* Insert casting types */
2895 : cast = swig_module.cast_initial[i];
2896 : while (cast->type) {
2897 : /* Don't need to add information already in the list */
2898 : ret = 0;
2899 : #ifdef SWIGRUNTIME_DEBUG
2900 : printf("SWIG_InitializeModule: look cast %s\n", cast->type->name);
2901 : #endif
2902 : if (swig_module.next != &swig_module) {
2903 : ret = SWIG_MangledTypeQueryModule(swig_module.next, &swig_module, cast->type->name);
2904 : #ifdef SWIGRUNTIME_DEBUG
2905 : if (ret) printf("SWIG_InitializeModule: found cast %s\n", ret->name);
2906 : #endif
2907 : }
2908 : if (ret) {
2909 : if (type == swig_module.type_initial[i]) {
2910 : #ifdef SWIGRUNTIME_DEBUG
2911 : printf("SWIG_InitializeModule: skip old type %s\n", ret->name);
2912 : #endif
2913 : cast->type = ret;
2914 : ret = 0;
2915 : } else {
2916 : /* Check for casting already in the list */
2917 : swig_cast_info *ocast = SWIG_TypeCheck(ret->name, type);
2918 : #ifdef SWIGRUNTIME_DEBUG
2919 : if (ocast) printf("SWIG_InitializeModule: skip old cast %s\n", ret->name);
2920 : #endif
2921 : if (!ocast) ret = 0;
2922 : }
2923 : }
2924 :
2925 : if (!ret) {
2926 : #ifdef SWIGRUNTIME_DEBUG
2927 : printf("SWIG_InitializeModule: adding cast %s\n", cast->type->name);
2928 : #endif
2929 : if (type->cast) {
2930 : type->cast->prev = cast;
2931 : cast->next = type->cast;
2932 : }
2933 : type->cast = cast;
2934 : }
2935 : cast++;
2936 : }
2937 : /* Set entry in modules->types array equal to the type */
2938 : swig_module.types[i] = type;
2939 : }
2940 : swig_module.types[i] = 0;
2941 :
2942 : #ifdef SWIGRUNTIME_DEBUG
2943 : printf("**** SWIG_InitializeModule: Cast List ******\n");
2944 : for (i = 0; i < swig_module.size; ++i) {
2945 : int j = 0;
2946 : swig_cast_info *cast = swig_module.cast_initial[i];
2947 : printf("SWIG_InitializeModule: type %lu %s\n", (unsigned long)i, swig_module.type_initial[i]->name);
2948 : while (cast->type) {
2949 : printf("SWIG_InitializeModule: cast type %s\n", cast->type->name);
2950 : cast++;
2951 : ++j;
2952 : }
2953 : printf("---- Total casts: %d\n",j);
2954 : }
2955 : printf("**** SWIG_InitializeModule: Cast List ******\n");
2956 : #endif
2957 : }
2958 :
2959 : /* This function will propagate the clientdata field of type to
2960 : * any new swig_type_info structures that have been added into the list
2961 : * of equivalent types. It is like calling
2962 : * SWIG_TypeClientData(type, clientdata) a second time.
2963 : */
2964 : SWIGRUNTIME void
2965 : SWIG_PropagateClientData(void) {
2966 : size_t i;
2967 : swig_cast_info *equiv;
2968 : static int init_run = 0;
2969 :
2970 : if (init_run) return;
2971 : init_run = 1;
2972 :
2973 : for (i = 0; i < swig_module.size; i++) {
2974 : if (swig_module.types[i]->clientdata) {
2975 : equiv = swig_module.types[i]->cast;
2976 : while (equiv) {
2977 : if (!equiv->converter) {
2978 : if (equiv->type && !equiv->type->clientdata)
2979 : SWIG_TypeClientData(equiv->type, swig_module.types[i]->clientdata);
2980 : }
2981 : equiv = equiv->next;
2982 : }
2983 : }
2984 : }
2985 : }
2986 :
2987 : #ifdef __cplusplus
2988 : #if 0
2989 : {
2990 : /* c-mode */
2991 : #endif
2992 : }
2993 : #endif
2994 :
2995 :
2996 :
2997 : #ifdef __cplusplus
2998 : extern "C" {
2999 : #endif
3000 :
3001 : /* Python-specific SWIG API */
3002 : #define SWIG_newvarlink() SWIG_Python_newvarlink()
3003 : #define SWIG_addvarlink(p, name, get_attr, set_attr) SWIG_Python_addvarlink(p, name, get_attr, set_attr)
3004 : #define SWIG_InstallConstants(d, constants) SWIG_Python_InstallConstants(d, constants)
3005 :
3006 : /* -----------------------------------------------------------------------------
3007 : * global variable support code.
3008 : * ----------------------------------------------------------------------------- */
3009 :
3010 : typedef struct swig_globalvar {
3011 : char *name; /* Name of global variable */
3012 : PyObject *(*get_attr)(void); /* Return the current value */
3013 : int (*set_attr)(PyObject *); /* Set the value */
3014 : struct swig_globalvar *next;
3015 : } swig_globalvar;
3016 :
3017 : typedef struct swig_varlinkobject {
3018 : PyObject_HEAD
3019 : swig_globalvar *vars;
3020 : } swig_varlinkobject;
3021 :
3022 : SWIGINTERN PyObject *
3023 : swig_varlink_repr(swig_varlinkobject *SWIGUNUSEDPARM(v)) {
3024 : #if PY_VERSION_HEX >= 0x03000000
3025 : return PyUnicode_InternFromString("<Swig global variables>");
3026 : #else
3027 : return PyString_FromString("<Swig global variables>");
3028 : #endif
3029 : }
3030 :
3031 : SWIGINTERN PyObject *
3032 : swig_varlink_str(swig_varlinkobject *v) {
3033 : #if PY_VERSION_HEX >= 0x03000000
3034 : PyObject *str = PyUnicode_InternFromString("(");
3035 : PyObject *tail;
3036 : PyObject *joined;
3037 : swig_globalvar *var;
3038 : for (var = v->vars; var; var=var->next) {
3039 : tail = PyUnicode_FromString(var->name);
3040 : joined = PyUnicode_Concat(str, tail);
3041 : Py_DecRef(str);
3042 : Py_DecRef(tail);
3043 : str = joined;
3044 : if (var->next) {
3045 : tail = PyUnicode_InternFromString(", ");
3046 : joined = PyUnicode_Concat(str, tail);
3047 : Py_DecRef(str);
3048 : Py_DecRef(tail);
3049 : str = joined;
3050 : }
3051 : }
3052 : tail = PyUnicode_InternFromString(")");
3053 : joined = PyUnicode_Concat(str, tail);
3054 : Py_DecRef(str);
3055 : Py_DecRef(tail);
3056 : str = joined;
3057 : #else
3058 : PyObject *str = PyString_FromString("(");
3059 : swig_globalvar *var;
3060 : for (var = v->vars; var; var=var->next) {
3061 : PyString_ConcatAndDel(&str,PyString_FromString(var->name));
3062 : if (var->next) PyString_ConcatAndDel(&str,PyString_FromString(", "));
3063 : }
3064 : PyString_ConcatAndDel(&str,PyString_FromString(")"));
3065 : #endif
3066 : return str;
3067 : }
3068 :
3069 : SWIGINTERN void
3070 : swig_varlink_dealloc(swig_varlinkobject *v) {
3071 : swig_globalvar *var = v->vars;
3072 : while (var) {
3073 : swig_globalvar *n = var->next;
3074 : free(var->name);
3075 : free(var);
3076 : var = n;
3077 : }
3078 : }
3079 :
3080 : SWIGINTERN PyObject *
3081 : swig_varlink_getattr(swig_varlinkobject *v, char *n) {
3082 : PyObject *res = NULL;
3083 : swig_globalvar *var = v->vars;
3084 : while (var) {
3085 : if (strcmp(var->name,n) == 0) {
3086 : res = (*var->get_attr)();
3087 : break;
3088 : }
3089 : var = var->next;
3090 : }
3091 : if (res == NULL && !PyErr_Occurred()) {
3092 : PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n);
3093 : }
3094 : return res;
3095 : }
3096 :
3097 : SWIGINTERN int
3098 : swig_varlink_setattr(swig_varlinkobject *v, char *n, PyObject *p) {
3099 : int res = 1;
3100 : swig_globalvar *var = v->vars;
3101 : while (var) {
3102 : if (strcmp(var->name,n) == 0) {
3103 : res = (*var->set_attr)(p);
3104 : break;
3105 : }
3106 : var = var->next;
3107 : }
3108 : if (res == 1 && !PyErr_Occurred()) {
3109 : PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n);
3110 : }
3111 : return res;
3112 : }
3113 :
3114 : SWIGINTERN PyTypeObject*
3115 : swig_varlink_type(void) {
3116 : static char varlink__doc__[] = "Swig var link object";
3117 : static PyTypeObject varlink_type;
3118 : static int type_init = 0;
3119 : if (!type_init) {
3120 : const PyTypeObject tmp = {
3121 : #if PY_VERSION_HEX >= 0x03000000
3122 : PyVarObject_HEAD_INIT(NULL, 0)
3123 : #else
3124 : PyObject_HEAD_INIT(NULL)
3125 : 0, /* ob_size */
3126 : #endif
3127 : "swigvarlink", /* tp_name */
3128 : sizeof(swig_varlinkobject), /* tp_basicsize */
3129 : 0, /* tp_itemsize */
3130 : (destructor) swig_varlink_dealloc, /* tp_dealloc */
3131 : 0, /* tp_print */
3132 : (getattrfunc) swig_varlink_getattr, /* tp_getattr */
3133 : (setattrfunc) swig_varlink_setattr, /* tp_setattr */
3134 : 0, /* tp_compare */
3135 : (reprfunc) swig_varlink_repr, /* tp_repr */
3136 : 0, /* tp_as_number */
3137 : 0, /* tp_as_sequence */
3138 : 0, /* tp_as_mapping */
3139 : 0, /* tp_hash */
3140 : 0, /* tp_call */
3141 : (reprfunc) swig_varlink_str, /* tp_str */
3142 : 0, /* tp_getattro */
3143 : 0, /* tp_setattro */
3144 : 0, /* tp_as_buffer */
3145 : 0, /* tp_flags */
3146 : varlink__doc__, /* tp_doc */
3147 : 0, /* tp_traverse */
3148 : 0, /* tp_clear */
3149 : 0, /* tp_richcompare */
3150 : 0, /* tp_weaklistoffset */
3151 : 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* tp_iter -> tp_weaklist */
3152 : 0, /* tp_del */
3153 : 0, /* tp_version_tag */
3154 : #if PY_VERSION_HEX >= 0x03040000
3155 : 0, /* tp_finalize */
3156 : #endif
3157 : #ifdef COUNT_ALLOCS
3158 : 0, /* tp_allocs */
3159 : 0, /* tp_frees */
3160 : 0, /* tp_maxalloc */
3161 : 0, /* tp_prev */
3162 : 0 /* tp_next */
3163 : #endif
3164 : };
3165 : varlink_type = tmp;
3166 : type_init = 1;
3167 : if (PyType_Ready(&varlink_type) < 0)
3168 : return NULL;
3169 : }
3170 : return &varlink_type;
3171 : }
3172 :
3173 : /* Create a variable linking object for use later */
3174 : SWIGINTERN PyObject *
3175 : SWIG_Python_newvarlink(void) {
3176 : swig_varlinkobject *result = PyObject_NEW(swig_varlinkobject, swig_varlink_type());
3177 : if (result) {
3178 : result->vars = 0;
3179 : }
3180 : return ((PyObject*) result);
3181 : }
3182 :
3183 : SWIGINTERN void
3184 : SWIG_Python_addvarlink(PyObject *p, const char *name, PyObject *(*get_attr)(void), int (*set_attr)(PyObject *p)) {
3185 : swig_varlinkobject *v = (swig_varlinkobject *) p;
3186 : swig_globalvar *gv = (swig_globalvar *) malloc(sizeof(swig_globalvar));
3187 : if (gv) {
3188 : size_t size = strlen(name)+1;
3189 : gv->name = (char *)malloc(size);
3190 : if (gv->name) {
3191 : memcpy(gv->name, name, size);
3192 : gv->get_attr = get_attr;
3193 : gv->set_attr = set_attr;
3194 : gv->next = v->vars;
3195 : }
3196 : }
3197 : v->vars = gv;
3198 : }
3199 :
3200 : SWIGINTERN PyObject *
3201 : SWIG_globals(void) {
3202 : static PyObject *globals = 0;
3203 : if (!globals) {
3204 : globals = SWIG_newvarlink();
3205 : }
3206 : return globals;
3207 : }
3208 :
3209 : /* -----------------------------------------------------------------------------
3210 : * constants/methods manipulation
3211 : * ----------------------------------------------------------------------------- */
3212 :
3213 : /* Install Constants */
3214 : SWIGINTERN void
3215 275 : SWIG_Python_InstallConstants(PyObject *d, swig_const_info constants[]) {
3216 275 : PyObject *obj = 0;
3217 275 : size_t i;
3218 275 : for (i = 0; constants[i].type; ++i) {
3219 0 : switch(constants[i].type) {
3220 0 : case SWIG_PY_POINTER:
3221 0 : obj = SWIG_InternalNewPointerObj(constants[i].pvalue, *(constants[i]).ptype,0);
3222 0 : break;
3223 0 : case SWIG_PY_BINARY:
3224 0 : obj = SWIG_NewPackedObj(constants[i].pvalue, constants[i].lvalue, *(constants[i].ptype));
3225 : break;
3226 : default:
3227 : obj = 0;
3228 : break;
3229 : }
3230 0 : if (obj) {
3231 0 : PyDict_SetItemString(d, constants[i].name, obj);
3232 0 : Py_DECREF(obj);
3233 : }
3234 : }
3235 275 : }
3236 :
3237 : /* -----------------------------------------------------------------------------*/
3238 : /* Fix SwigMethods to carry the callback ptrs when needed */
3239 : /* -----------------------------------------------------------------------------*/
3240 :
3241 : SWIGINTERN void
3242 275 : SWIG_Python_FixMethods(PyMethodDef *methods,
3243 : swig_const_info *const_table,
3244 : swig_type_info **types,
3245 : swig_type_info **types_initial) {
3246 275 : size_t i;
3247 550 : for (i = 0; methods[i].ml_name; ++i) {
3248 275 : const char *c = methods[i].ml_doc;
3249 275 : if (!c) continue;
3250 0 : c = strstr(c, "swig_ptr: ");
3251 0 : if (c) {
3252 0 : int j;
3253 0 : swig_const_info *ci = 0;
3254 0 : const char *name = c + 10;
3255 0 : for (j = 0; const_table[j].type; ++j) {
3256 0 : if (strncmp(const_table[j].name, name,
3257 : strlen(const_table[j].name)) == 0) {
3258 : ci = &(const_table[j]);
3259 : break;
3260 : }
3261 : }
3262 0 : if (ci) {
3263 275 : void *ptr = (ci->type == SWIG_PY_POINTER) ? ci->pvalue : 0;
3264 0 : if (ptr) {
3265 0 : size_t shift = (ci->ptype) - types;
3266 0 : swig_type_info *ty = types_initial[shift];
3267 0 : size_t ldoc = (c - methods[i].ml_doc);
3268 0 : size_t lptr = strlen(ty->name)+2*sizeof(void*)+2;
3269 0 : char *ndoc = (char*)malloc(ldoc + lptr + 10);
3270 0 : if (ndoc) {
3271 0 : char *buff = ndoc;
3272 0 : memcpy(buff, methods[i].ml_doc, ldoc);
3273 0 : buff += ldoc;
3274 0 : memcpy(buff, "swig_ptr: ", 10);
3275 0 : buff += 10;
3276 0 : SWIG_PackVoidPtr(buff, ptr, ty->name, lptr);
3277 0 : methods[i].ml_doc = ndoc;
3278 : }
3279 : }
3280 : }
3281 : }
3282 : }
3283 275 : }
3284 :
3285 : /* -----------------------------------------------------------------------------
3286 : * Method creation and docstring support functions
3287 : * ----------------------------------------------------------------------------- */
3288 :
3289 : /* -----------------------------------------------------------------------------
3290 : * Function to find the method definition with the correct docstring for the
3291 : * proxy module as opposed to the low-level API
3292 : * ----------------------------------------------------------------------------- */
3293 :
3294 0 : SWIGINTERN PyMethodDef *SWIG_PythonGetProxyDoc(const char *name) {
3295 : /* Find the function in the modified method table */
3296 0 : size_t offset = 0;
3297 0 : int found = 0;
3298 0 : while (SwigMethods_proxydocs[offset].ml_meth != NULL) {
3299 0 : if (strcmp(SwigMethods_proxydocs[offset].ml_name, name) == 0) {
3300 : found = 1;
3301 : break;
3302 : }
3303 0 : offset++;
3304 : }
3305 : /* Use the copy with the modified docstring if available */
3306 0 : return found ? &SwigMethods_proxydocs[offset] : NULL;
3307 : }
3308 :
3309 : /* -----------------------------------------------------------------------------
3310 : * Wrapper of PyInstanceMethod_New() used in Python 3
3311 : * It is exported to the generated module, used for -fastproxy
3312 : * ----------------------------------------------------------------------------- */
3313 :
3314 0 : SWIGINTERN PyObject *SWIG_PyInstanceMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func) {
3315 0 : if (PyCFunction_Check(func)) {
3316 0 : PyCFunctionObject *funcobj = (PyCFunctionObject *)func;
3317 0 : PyMethodDef *ml = SWIG_PythonGetProxyDoc(funcobj->m_ml->ml_name);
3318 0 : if (ml)
3319 0 : func = PyCFunction_NewEx(ml, funcobj->m_self, funcobj->m_module);
3320 : }
3321 : #if PY_VERSION_HEX >= 0x03000000
3322 0 : return PyInstanceMethod_New(func);
3323 : #else
3324 : return PyMethod_New(func, NULL, NULL);
3325 : #endif
3326 : }
3327 :
3328 : /* -----------------------------------------------------------------------------
3329 : * Wrapper of PyStaticMethod_New()
3330 : * It is exported to the generated module, used for -fastproxy
3331 : * ----------------------------------------------------------------------------- */
3332 :
3333 : SWIGINTERN PyObject *SWIG_PyStaticMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func) {
3334 : if (PyCFunction_Check(func)) {
3335 : PyCFunctionObject *funcobj = (PyCFunctionObject *)func;
3336 : PyMethodDef *ml = SWIG_PythonGetProxyDoc(funcobj->m_ml->ml_name);
3337 : if (ml)
3338 : func = PyCFunction_NewEx(ml, funcobj->m_self, funcobj->m_module);
3339 : }
3340 : return PyStaticMethod_New(func);
3341 : }
3342 :
3343 : #ifdef __cplusplus
3344 : }
3345 : #endif
3346 :
3347 : /* -----------------------------------------------------------------------------*
3348 : * Partial Init method
3349 : * -----------------------------------------------------------------------------*/
3350 :
3351 : #ifdef __cplusplus
3352 : extern "C"
3353 : #endif
3354 :
3355 : SWIGEXPORT
3356 : #if PY_VERSION_HEX >= 0x03000000
3357 : PyObject*
3358 : #else
3359 : void
3360 : #endif
3361 275 : SWIG_init(void) {
3362 275 : PyObject *m, *d, *md, *globals;
3363 :
3364 : #if PY_VERSION_HEX >= 0x03000000
3365 275 : static struct PyModuleDef SWIG_module = {
3366 : PyModuleDef_HEAD_INIT,
3367 : SWIG_name,
3368 : NULL,
3369 : -1,
3370 : SwigMethods,
3371 : NULL,
3372 : NULL,
3373 : NULL,
3374 : NULL
3375 : };
3376 : #endif
3377 :
3378 : #if defined(SWIGPYTHON_BUILTIN)
3379 : static SwigPyClientData SwigPyObject_clientdata = {
3380 : 0, 0, 0, 0, 0, 0, 0
3381 : };
3382 : static PyGetSetDef this_getset_def = {
3383 : (char *)"this", &SwigPyBuiltin_ThisClosure, NULL, NULL, NULL
3384 : };
3385 : static SwigPyGetSet thisown_getset_closure = {
3386 : SwigPyObject_own,
3387 : SwigPyObject_own
3388 : };
3389 : static PyGetSetDef thisown_getset_def = {
3390 : (char *)"thisown", SwigPyBuiltin_GetterClosure, SwigPyBuiltin_SetterClosure, NULL, &thisown_getset_closure
3391 : };
3392 : PyTypeObject *builtin_pytype;
3393 : int builtin_base_count;
3394 : swig_type_info *builtin_basetype;
3395 : PyObject *tuple;
3396 : PyGetSetDescrObject *static_getset;
3397 : PyTypeObject *metatype;
3398 : PyTypeObject *swigpyobject;
3399 : SwigPyClientData *cd;
3400 : PyObject *public_interface, *public_symbol;
3401 : PyObject *this_descr;
3402 : PyObject *thisown_descr;
3403 : PyObject *self = 0;
3404 : int i;
3405 :
3406 : (void)builtin_pytype;
3407 : (void)builtin_base_count;
3408 : (void)builtin_basetype;
3409 : (void)tuple;
3410 : (void)static_getset;
3411 : (void)self;
3412 :
3413 : /* Metaclass is used to implement static member variables */
3414 : metatype = SwigPyObjectType();
3415 : assert(metatype);
3416 : #endif
3417 :
3418 275 : (void)globals;
3419 :
3420 : /* Create singletons now to avoid potential deadlocks with multi-threaded usage after module initialization */
3421 275 : SWIG_This();
3422 275 : SWIG_Python_TypeCache();
3423 275 : SwigPyPacked_type();
3424 : #ifndef SWIGPYTHON_BUILTIN
3425 275 : SwigPyObject_type();
3426 : #endif
3427 :
3428 : /* Fix SwigMethods to carry the callback ptrs when needed */
3429 275 : SWIG_Python_FixMethods(SwigMethods, swig_const_table, swig_types, swig_type_initial);
3430 :
3431 : #if PY_VERSION_HEX >= 0x03000000
3432 275 : m = PyModule_Create(&SWIG_module);
3433 : #else
3434 : m = Py_InitModule(SWIG_name, SwigMethods);
3435 : #endif
3436 :
3437 275 : md = d = PyModule_GetDict(m);
3438 275 : (void)md;
3439 :
3440 275 : SWIG_InitializeModule(0);
3441 :
3442 : #ifdef SWIGPYTHON_BUILTIN
3443 : swigpyobject = SwigPyObject_TypeOnce();
3444 :
3445 : SwigPyObject_stype = SWIG_MangledTypeQuery("_p_SwigPyObject");
3446 : assert(SwigPyObject_stype);
3447 : cd = (SwigPyClientData*) SwigPyObject_stype->clientdata;
3448 : if (!cd) {
3449 : SwigPyObject_stype->clientdata = &SwigPyObject_clientdata;
3450 : SwigPyObject_clientdata.pytype = swigpyobject;
3451 : } else if (swigpyobject->tp_basicsize != cd->pytype->tp_basicsize) {
3452 : PyErr_SetString(PyExc_RuntimeError, "Import error: attempted to load two incompatible swig-generated modules.");
3453 : # if PY_VERSION_HEX >= 0x03000000
3454 : return NULL;
3455 : # else
3456 : return;
3457 : # endif
3458 : }
3459 :
3460 : /* All objects have a 'this' attribute */
3461 : this_descr = PyDescr_NewGetSet(SwigPyObject_type(), &this_getset_def);
3462 : (void)this_descr;
3463 :
3464 : /* All objects have a 'thisown' attribute */
3465 : thisown_descr = PyDescr_NewGetSet(SwigPyObject_type(), &thisown_getset_def);
3466 : (void)thisown_descr;
3467 :
3468 : public_interface = PyList_New(0);
3469 : public_symbol = 0;
3470 : (void)public_symbol;
3471 :
3472 : PyDict_SetItemString(md, "__all__", public_interface);
3473 : Py_DECREF(public_interface);
3474 : for (i = 0; SwigMethods[i].ml_name != NULL; ++i)
3475 : SwigPyBuiltin_AddPublicSymbol(public_interface, SwigMethods[i].ml_name);
3476 : for (i = 0; swig_const_table[i].name != 0; ++i)
3477 : SwigPyBuiltin_AddPublicSymbol(public_interface, swig_const_table[i].name);
3478 : #endif
3479 :
3480 275 : SWIG_InstallConstants(d,swig_const_table);
3481 :
3482 275 : SWIG_Python_SetConstant(d, "GDT_Unknown",SWIG_From_int((int)(GDT_Unknown)));
3483 275 : SWIG_Python_SetConstant(d, "GDT_Byte",SWIG_From_int((int)(GDT_Byte)));
3484 275 : SWIG_Python_SetConstant(d, "GDT_Int8",SWIG_From_int((int)(GDT_Int8)));
3485 275 : SWIG_Python_SetConstant(d, "GDT_UInt16",SWIG_From_int((int)(GDT_UInt16)));
3486 275 : SWIG_Python_SetConstant(d, "GDT_Int16",SWIG_From_int((int)(GDT_Int16)));
3487 275 : SWIG_Python_SetConstant(d, "GDT_UInt32",SWIG_From_int((int)(GDT_UInt32)));
3488 275 : SWIG_Python_SetConstant(d, "GDT_Int32",SWIG_From_int((int)(GDT_Int32)));
3489 275 : SWIG_Python_SetConstant(d, "GDT_UInt64",SWIG_From_int((int)(GDT_UInt64)));
3490 275 : SWIG_Python_SetConstant(d, "GDT_Int64",SWIG_From_int((int)(GDT_Int64)));
3491 275 : SWIG_Python_SetConstant(d, "GDT_Float32",SWIG_From_int((int)(GDT_Float32)));
3492 275 : SWIG_Python_SetConstant(d, "GDT_Float64",SWIG_From_int((int)(GDT_Float64)));
3493 275 : SWIG_Python_SetConstant(d, "GDT_CInt16",SWIG_From_int((int)(GDT_CInt16)));
3494 275 : SWIG_Python_SetConstant(d, "GDT_CInt32",SWIG_From_int((int)(GDT_CInt32)));
3495 275 : SWIG_Python_SetConstant(d, "GDT_CFloat32",SWIG_From_int((int)(GDT_CFloat32)));
3496 275 : SWIG_Python_SetConstant(d, "GDT_CFloat64",SWIG_From_int((int)(GDT_CFloat64)));
3497 275 : SWIG_Python_SetConstant(d, "GDT_TypeCount",SWIG_From_int((int)(GDT_TypeCount)));
3498 275 : SWIG_Python_SetConstant(d, "GA_ReadOnly",SWIG_From_int((int)(GA_ReadOnly)));
3499 275 : SWIG_Python_SetConstant(d, "GA_Update",SWIG_From_int((int)(GA_Update)));
3500 275 : SWIG_Python_SetConstant(d, "GF_Read",SWIG_From_int((int)(GF_Read)));
3501 275 : SWIG_Python_SetConstant(d, "GF_Write",SWIG_From_int((int)(GF_Write)));
3502 275 : SWIG_Python_SetConstant(d, "GRIORA_NearestNeighbour",SWIG_From_int((int)(GRIORA_NearestNeighbour)));
3503 275 : SWIG_Python_SetConstant(d, "GRIORA_Bilinear",SWIG_From_int((int)(GRIORA_Bilinear)));
3504 275 : SWIG_Python_SetConstant(d, "GRIORA_Cubic",SWIG_From_int((int)(GRIORA_Cubic)));
3505 275 : SWIG_Python_SetConstant(d, "GRIORA_CubicSpline",SWIG_From_int((int)(GRIORA_CubicSpline)));
3506 275 : SWIG_Python_SetConstant(d, "GRIORA_Lanczos",SWIG_From_int((int)(GRIORA_Lanczos)));
3507 275 : SWIG_Python_SetConstant(d, "GRIORA_Average",SWIG_From_int((int)(GRIORA_Average)));
3508 275 : SWIG_Python_SetConstant(d, "GRIORA_RMS",SWIG_From_int((int)(GRIORA_RMS)));
3509 275 : SWIG_Python_SetConstant(d, "GRIORA_Mode",SWIG_From_int((int)(GRIORA_Mode)));
3510 275 : SWIG_Python_SetConstant(d, "GRIORA_Gauss",SWIG_From_int((int)(GRIORA_Gauss)));
3511 275 : SWIG_Python_SetConstant(d, "GCI_Undefined",SWIG_From_int((int)(GCI_Undefined)));
3512 275 : SWIG_Python_SetConstant(d, "GCI_GrayIndex",SWIG_From_int((int)(GCI_GrayIndex)));
3513 275 : SWIG_Python_SetConstant(d, "GCI_PaletteIndex",SWIG_From_int((int)(GCI_PaletteIndex)));
3514 275 : SWIG_Python_SetConstant(d, "GCI_RedBand",SWIG_From_int((int)(GCI_RedBand)));
3515 275 : SWIG_Python_SetConstant(d, "GCI_GreenBand",SWIG_From_int((int)(GCI_GreenBand)));
3516 275 : SWIG_Python_SetConstant(d, "GCI_BlueBand",SWIG_From_int((int)(GCI_BlueBand)));
3517 275 : SWIG_Python_SetConstant(d, "GCI_AlphaBand",SWIG_From_int((int)(GCI_AlphaBand)));
3518 275 : SWIG_Python_SetConstant(d, "GCI_HueBand",SWIG_From_int((int)(GCI_HueBand)));
3519 275 : SWIG_Python_SetConstant(d, "GCI_SaturationBand",SWIG_From_int((int)(GCI_SaturationBand)));
3520 275 : SWIG_Python_SetConstant(d, "GCI_LightnessBand",SWIG_From_int((int)(GCI_LightnessBand)));
3521 275 : SWIG_Python_SetConstant(d, "GCI_CyanBand",SWIG_From_int((int)(GCI_CyanBand)));
3522 275 : SWIG_Python_SetConstant(d, "GCI_MagentaBand",SWIG_From_int((int)(GCI_MagentaBand)));
3523 275 : SWIG_Python_SetConstant(d, "GCI_YellowBand",SWIG_From_int((int)(GCI_YellowBand)));
3524 275 : SWIG_Python_SetConstant(d, "GCI_BlackBand",SWIG_From_int((int)(GCI_BlackBand)));
3525 275 : SWIG_Python_SetConstant(d, "GCI_YCbCr_YBand",SWIG_From_int((int)(GCI_YCbCr_YBand)));
3526 275 : SWIG_Python_SetConstant(d, "GCI_YCbCr_CrBand",SWIG_From_int((int)(GCI_YCbCr_CrBand)));
3527 275 : SWIG_Python_SetConstant(d, "GCI_YCbCr_CbBand",SWIG_From_int((int)(GCI_YCbCr_CbBand)));
3528 275 : SWIG_Python_SetConstant(d, "GCI_PanBand",SWIG_From_int((int)(GCI_PanBand)));
3529 275 : SWIG_Python_SetConstant(d, "GCI_CoastalBand",SWIG_From_int((int)(GCI_CoastalBand)));
3530 275 : SWIG_Python_SetConstant(d, "GCI_RedEdgeBand",SWIG_From_int((int)(GCI_RedEdgeBand)));
3531 275 : SWIG_Python_SetConstant(d, "GCI_IR_Start",SWIG_From_int((int)(GCI_IR_Start)));
3532 275 : SWIG_Python_SetConstant(d, "GCI_NIRBand",SWIG_From_int((int)(GCI_NIRBand)));
3533 275 : SWIG_Python_SetConstant(d, "GCI_SWIRBand",SWIG_From_int((int)(GCI_SWIRBand)));
3534 275 : SWIG_Python_SetConstant(d, "GCI_MWIRBand",SWIG_From_int((int)(GCI_MWIRBand)));
3535 275 : SWIG_Python_SetConstant(d, "GCI_LWIRBand",SWIG_From_int((int)(GCI_LWIRBand)));
3536 275 : SWIG_Python_SetConstant(d, "GCI_TIRBand",SWIG_From_int((int)(GCI_TIRBand)));
3537 275 : SWIG_Python_SetConstant(d, "GCI_OtherIRBand",SWIG_From_int((int)(GCI_OtherIRBand)));
3538 275 : SWIG_Python_SetConstant(d, "GCI_IR_End",SWIG_From_int((int)(GCI_IR_End)));
3539 275 : SWIG_Python_SetConstant(d, "GCI_SAR_Start",SWIG_From_int((int)(GCI_SAR_Start)));
3540 275 : SWIG_Python_SetConstant(d, "GCI_SAR_Ka_Band",SWIG_From_int((int)(GCI_SAR_Ka_Band)));
3541 275 : SWIG_Python_SetConstant(d, "GCI_SAR_K_Band",SWIG_From_int((int)(GCI_SAR_K_Band)));
3542 275 : SWIG_Python_SetConstant(d, "GCI_SAR_Ku_Band",SWIG_From_int((int)(GCI_SAR_Ku_Band)));
3543 275 : SWIG_Python_SetConstant(d, "GCI_SAR_X_Band",SWIG_From_int((int)(GCI_SAR_X_Band)));
3544 275 : SWIG_Python_SetConstant(d, "GCI_SAR_C_Band",SWIG_From_int((int)(GCI_SAR_C_Band)));
3545 275 : SWIG_Python_SetConstant(d, "GCI_SAR_S_Band",SWIG_From_int((int)(GCI_SAR_S_Band)));
3546 275 : SWIG_Python_SetConstant(d, "GCI_SAR_L_Band",SWIG_From_int((int)(GCI_SAR_L_Band)));
3547 275 : SWIG_Python_SetConstant(d, "GCI_SAR_P_Band",SWIG_From_int((int)(GCI_SAR_P_Band)));
3548 275 : SWIG_Python_SetConstant(d, "GCI_SAR_End",SWIG_From_int((int)(GCI_SAR_End)));
3549 275 : SWIG_Python_SetConstant(d, "GCI_Max",SWIG_From_int((int)(GCI_Max)));
3550 275 : SWIG_Python_SetConstant(d, "GRA_NearestNeighbour",SWIG_From_int((int)(GRA_NearestNeighbour)));
3551 275 : SWIG_Python_SetConstant(d, "GRA_Bilinear",SWIG_From_int((int)(GRA_Bilinear)));
3552 275 : SWIG_Python_SetConstant(d, "GRA_Cubic",SWIG_From_int((int)(GRA_Cubic)));
3553 275 : SWIG_Python_SetConstant(d, "GRA_CubicSpline",SWIG_From_int((int)(GRA_CubicSpline)));
3554 275 : SWIG_Python_SetConstant(d, "GRA_Lanczos",SWIG_From_int((int)(GRA_Lanczos)));
3555 275 : SWIG_Python_SetConstant(d, "GRA_Average",SWIG_From_int((int)(GRA_Average)));
3556 275 : SWIG_Python_SetConstant(d, "GRA_RMS",SWIG_From_int((int)(GRA_RMS)));
3557 275 : SWIG_Python_SetConstant(d, "GRA_Mode",SWIG_From_int((int)(GRA_Mode)));
3558 275 : SWIG_Python_SetConstant(d, "GRA_Max",SWIG_From_int((int)(GRA_Max)));
3559 275 : SWIG_Python_SetConstant(d, "GRA_Min",SWIG_From_int((int)(GRA_Min)));
3560 275 : SWIG_Python_SetConstant(d, "GRA_Med",SWIG_From_int((int)(GRA_Med)));
3561 275 : SWIG_Python_SetConstant(d, "GRA_Q1",SWIG_From_int((int)(GRA_Q1)));
3562 275 : SWIG_Python_SetConstant(d, "GRA_Q3",SWIG_From_int((int)(GRA_Q3)));
3563 275 : SWIG_Python_SetConstant(d, "GRA_Sum",SWIG_From_int((int)(GRA_Sum)));
3564 275 : SWIG_Python_SetConstant(d, "GPI_Gray",SWIG_From_int((int)(GPI_Gray)));
3565 275 : SWIG_Python_SetConstant(d, "GPI_RGB",SWIG_From_int((int)(GPI_RGB)));
3566 275 : SWIG_Python_SetConstant(d, "GPI_CMYK",SWIG_From_int((int)(GPI_CMYK)));
3567 275 : SWIG_Python_SetConstant(d, "GPI_HLS",SWIG_From_int((int)(GPI_HLS)));
3568 275 : SWIG_Python_SetConstant(d, "CXT_Element",SWIG_From_int((int)(CXT_Element)));
3569 275 : SWIG_Python_SetConstant(d, "CXT_Text",SWIG_From_int((int)(CXT_Text)));
3570 275 : SWIG_Python_SetConstant(d, "CXT_Attribute",SWIG_From_int((int)(CXT_Attribute)));
3571 275 : SWIG_Python_SetConstant(d, "CXT_Comment",SWIG_From_int((int)(CXT_Comment)));
3572 275 : SWIG_Python_SetConstant(d, "CXT_Literal",SWIG_From_int((int)(CXT_Literal)));
3573 275 : SWIG_Python_SetConstant(d, "CE_None",SWIG_From_int((int)(CE_None)));
3574 275 : SWIG_Python_SetConstant(d, "CE_Debug",SWIG_From_int((int)(CE_Debug)));
3575 275 : SWIG_Python_SetConstant(d, "CE_Warning",SWIG_From_int((int)(CE_Warning)));
3576 275 : SWIG_Python_SetConstant(d, "CE_Failure",SWIG_From_int((int)(CE_Failure)));
3577 275 : SWIG_Python_SetConstant(d, "CE_Fatal",SWIG_From_int((int)(CE_Fatal)));
3578 275 : SWIG_Python_SetConstant(d, "CPLE_None",SWIG_From_int((int)(CPLE_None)));
3579 275 : SWIG_Python_SetConstant(d, "CPLE_AppDefined",SWIG_From_int((int)(CPLE_AppDefined)));
3580 275 : SWIG_Python_SetConstant(d, "CPLE_OutOfMemory",SWIG_From_int((int)(CPLE_OutOfMemory)));
3581 275 : SWIG_Python_SetConstant(d, "CPLE_FileIO",SWIG_From_int((int)(CPLE_FileIO)));
3582 275 : SWIG_Python_SetConstant(d, "CPLE_OpenFailed",SWIG_From_int((int)(CPLE_OpenFailed)));
3583 275 : SWIG_Python_SetConstant(d, "CPLE_IllegalArg",SWIG_From_int((int)(CPLE_IllegalArg)));
3584 275 : SWIG_Python_SetConstant(d, "CPLE_NotSupported",SWIG_From_int((int)(CPLE_NotSupported)));
3585 275 : SWIG_Python_SetConstant(d, "CPLE_AssertionFailed",SWIG_From_int((int)(CPLE_AssertionFailed)));
3586 275 : SWIG_Python_SetConstant(d, "CPLE_NoWriteAccess",SWIG_From_int((int)(CPLE_NoWriteAccess)));
3587 275 : SWIG_Python_SetConstant(d, "CPLE_UserInterrupt",SWIG_From_int((int)(CPLE_UserInterrupt)));
3588 275 : SWIG_Python_SetConstant(d, "CPLE_ObjectNull",SWIG_From_int((int)(CPLE_ObjectNull)));
3589 275 : SWIG_Python_SetConstant(d, "CPLE_HttpResponse",SWIG_From_int((int)(CPLE_HttpResponse)));
3590 275 : SWIG_Python_SetConstant(d, "CPLE_AWSBucketNotFound",SWIG_From_int((int)(CPLE_AWSBucketNotFound)));
3591 275 : SWIG_Python_SetConstant(d, "CPLE_AWSObjectNotFound",SWIG_From_int((int)(CPLE_AWSObjectNotFound)));
3592 275 : SWIG_Python_SetConstant(d, "CPLE_AWSAccessDenied",SWIG_From_int((int)(CPLE_AWSAccessDenied)));
3593 275 : SWIG_Python_SetConstant(d, "CPLE_AWSInvalidCredentials",SWIG_From_int((int)(CPLE_AWSInvalidCredentials)));
3594 275 : SWIG_Python_SetConstant(d, "CPLE_AWSSignatureDoesNotMatch",SWIG_From_int((int)(CPLE_AWSSignatureDoesNotMatch)));
3595 275 : SWIG_Python_SetConstant(d, "OF_ALL",SWIG_From_int((int)(GDAL_OF_ALL)));
3596 275 : SWIG_Python_SetConstant(d, "OF_RASTER",SWIG_From_int((int)(GDAL_OF_RASTER)));
3597 275 : SWIG_Python_SetConstant(d, "OF_VECTOR",SWIG_From_int((int)(GDAL_OF_VECTOR)));
3598 275 : SWIG_Python_SetConstant(d, "OF_GNM",SWIG_From_int((int)(GDAL_OF_GNM)));
3599 275 : SWIG_Python_SetConstant(d, "OF_MULTIDIM_RASTER",SWIG_From_int((int)(GDAL_OF_MULTIDIM_RASTER)));
3600 275 : SWIG_Python_SetConstant(d, "OF_READONLY",SWIG_From_int((int)(GDAL_OF_READONLY)));
3601 275 : SWIG_Python_SetConstant(d, "OF_UPDATE",SWIG_From_int((int)(GDAL_OF_UPDATE)));
3602 275 : SWIG_Python_SetConstant(d, "OF_SHARED",SWIG_From_int((int)(GDAL_OF_SHARED)));
3603 275 : SWIG_Python_SetConstant(d, "OF_VERBOSE_ERROR",SWIG_From_int((int)(GDAL_OF_VERBOSE_ERROR)));
3604 275 : SWIG_Python_SetConstant(d, "OF_THREAD_SAFE",SWIG_From_int((int)(GDAL_OF_THREAD_SAFE)));
3605 275 : SWIG_Python_SetConstant(d, "DMD_LONGNAME",SWIG_FromCharPtr(GDAL_DMD_LONGNAME));
3606 275 : SWIG_Python_SetConstant(d, "DMD_HELPTOPIC",SWIG_FromCharPtr(GDAL_DMD_HELPTOPIC));
3607 275 : SWIG_Python_SetConstant(d, "DMD_MIMETYPE",SWIG_FromCharPtr(GDAL_DMD_MIMETYPE));
3608 275 : SWIG_Python_SetConstant(d, "DMD_EXTENSION",SWIG_FromCharPtr(GDAL_DMD_EXTENSION));
3609 275 : SWIG_Python_SetConstant(d, "DMD_CONNECTION_PREFIX",SWIG_FromCharPtr(GDAL_DMD_CONNECTION_PREFIX));
3610 275 : SWIG_Python_SetConstant(d, "DMD_EXTENSIONS",SWIG_FromCharPtr(GDAL_DMD_EXTENSIONS));
3611 275 : SWIG_Python_SetConstant(d, "DMD_CREATIONOPTIONLIST",SWIG_FromCharPtr(GDAL_DMD_CREATIONOPTIONLIST));
3612 275 : SWIG_Python_SetConstant(d, "DMD_MULTIDIM_DATASET_CREATIONOPTIONLIST",SWIG_FromCharPtr(GDAL_DMD_MULTIDIM_DATASET_CREATIONOPTIONLIST));
3613 275 : SWIG_Python_SetConstant(d, "DMD_MULTIDIM_GROUP_CREATIONOPTIONLIST",SWIG_FromCharPtr(GDAL_DMD_MULTIDIM_GROUP_CREATIONOPTIONLIST));
3614 275 : SWIG_Python_SetConstant(d, "DMD_MULTIDIM_DIMENSION_CREATIONOPTIONLIST",SWIG_FromCharPtr(GDAL_DMD_MULTIDIM_DIMENSION_CREATIONOPTIONLIST));
3615 275 : SWIG_Python_SetConstant(d, "DMD_MULTIDIM_ARRAY_CREATIONOPTIONLIST",SWIG_FromCharPtr(GDAL_DMD_MULTIDIM_ARRAY_CREATIONOPTIONLIST));
3616 275 : SWIG_Python_SetConstant(d, "DMD_MULTIDIM_ARRAY_OPENOPTIONLIST",SWIG_FromCharPtr(GDAL_DMD_MULTIDIM_ARRAY_OPENOPTIONLIST));
3617 275 : SWIG_Python_SetConstant(d, "DMD_MULTIDIM_ATTRIBUTE_CREATIONOPTIONLIST",SWIG_FromCharPtr(GDAL_DMD_MULTIDIM_ATTRIBUTE_CREATIONOPTIONLIST));
3618 275 : SWIG_Python_SetConstant(d, "DMD_OPENOPTIONLIST",SWIG_FromCharPtr(GDAL_DMD_OPENOPTIONLIST));
3619 275 : SWIG_Python_SetConstant(d, "DMD_CREATIONDATATYPES",SWIG_FromCharPtr(GDAL_DMD_CREATIONDATATYPES));
3620 275 : SWIG_Python_SetConstant(d, "DMD_CREATIONFIELDDATATYPES",SWIG_FromCharPtr(GDAL_DMD_CREATIONFIELDDATATYPES));
3621 275 : SWIG_Python_SetConstant(d, "DMD_CREATIONFIELDDATASUBTYPES",SWIG_FromCharPtr(GDAL_DMD_CREATIONFIELDDATASUBTYPES));
3622 275 : SWIG_Python_SetConstant(d, "DMD_CREATION_FIELD_DEFN_FLAGS",SWIG_FromCharPtr(GDAL_DMD_CREATION_FIELD_DEFN_FLAGS));
3623 275 : SWIG_Python_SetConstant(d, "DMD_SUBDATASETS",SWIG_FromCharPtr(GDAL_DMD_SUBDATASETS));
3624 275 : SWIG_Python_SetConstant(d, "DMD_CREATION_FIELD_DOMAIN_TYPES",SWIG_FromCharPtr(GDAL_DMD_CREATION_FIELD_DOMAIN_TYPES));
3625 275 : SWIG_Python_SetConstant(d, "DMD_ALTER_GEOM_FIELD_DEFN_FLAGS",SWIG_FromCharPtr(GDAL_DMD_ALTER_GEOM_FIELD_DEFN_FLAGS));
3626 275 : SWIG_Python_SetConstant(d, "DMD_SUPPORTED_SQL_DIALECTS",SWIG_FromCharPtr(GDAL_DMD_SUPPORTED_SQL_DIALECTS));
3627 275 : SWIG_Python_SetConstant(d, "DMD_NUMERIC_FIELD_WIDTH_INCLUDES_DECIMAL_SEPARATOR",SWIG_FromCharPtr(GDAL_DMD_NUMERIC_FIELD_WIDTH_INCLUDES_DECIMAL_SEPARATOR));
3628 275 : SWIG_Python_SetConstant(d, "DMD_NUMERIC_FIELD_WIDTH_INCLUDES_SIGN",SWIG_FromCharPtr(GDAL_DMD_NUMERIC_FIELD_WIDTH_INCLUDES_SIGN));
3629 275 : SWIG_Python_SetConstant(d, "DCAP_OPEN",SWIG_FromCharPtr(GDAL_DCAP_OPEN));
3630 275 : SWIG_Python_SetConstant(d, "DCAP_CREATE",SWIG_FromCharPtr(GDAL_DCAP_CREATE));
3631 275 : SWIG_Python_SetConstant(d, "DCAP_CREATE_MULTIDIMENSIONAL",SWIG_FromCharPtr(GDAL_DCAP_CREATE_MULTIDIMENSIONAL));
3632 275 : SWIG_Python_SetConstant(d, "DCAP_CREATECOPY",SWIG_FromCharPtr(GDAL_DCAP_CREATECOPY));
3633 275 : SWIG_Python_SetConstant(d, "DCAP_CREATECOPY_MULTIDIMENSIONAL",SWIG_FromCharPtr(GDAL_DCAP_CREATECOPY_MULTIDIMENSIONAL));
3634 275 : SWIG_Python_SetConstant(d, "DCAP_MULTIDIM_RASTER",SWIG_FromCharPtr(GDAL_DCAP_MULTIDIM_RASTER));
3635 275 : SWIG_Python_SetConstant(d, "DCAP_SUBCREATECOPY",SWIG_FromCharPtr(GDAL_DCAP_SUBCREATECOPY));
3636 275 : SWIG_Python_SetConstant(d, "DCAP_VIRTUALIO",SWIG_FromCharPtr(GDAL_DCAP_VIRTUALIO));
3637 275 : SWIG_Python_SetConstant(d, "DCAP_RASTER",SWIG_FromCharPtr(GDAL_DCAP_RASTER));
3638 275 : SWIG_Python_SetConstant(d, "DCAP_VECTOR",SWIG_FromCharPtr(GDAL_DCAP_VECTOR));
3639 275 : SWIG_Python_SetConstant(d, "DCAP_GNM",SWIG_FromCharPtr(GDAL_DCAP_GNM));
3640 275 : SWIG_Python_SetConstant(d, "DCAP_CREATE_LAYER",SWIG_FromCharPtr(GDAL_DCAP_CREATE_LAYER));
3641 275 : SWIG_Python_SetConstant(d, "DCAP_DELETE_LAYER",SWIG_FromCharPtr(GDAL_DCAP_DELETE_LAYER));
3642 275 : SWIG_Python_SetConstant(d, "DCAP_CREATE_FIELD",SWIG_FromCharPtr(GDAL_DCAP_CREATE_FIELD));
3643 275 : SWIG_Python_SetConstant(d, "DCAP_DELETE_FIELD",SWIG_FromCharPtr(GDAL_DCAP_DELETE_FIELD));
3644 275 : SWIG_Python_SetConstant(d, "DCAP_REORDER_FIELDS",SWIG_FromCharPtr(GDAL_DCAP_REORDER_FIELDS));
3645 275 : SWIG_Python_SetConstant(d, "DMD_ALTER_FIELD_DEFN_FLAGS",SWIG_FromCharPtr(GDAL_DMD_ALTER_FIELD_DEFN_FLAGS));
3646 275 : SWIG_Python_SetConstant(d, "DMD_ILLEGAL_FIELD_NAMES",SWIG_FromCharPtr(GDAL_DMD_ILLEGAL_FIELD_NAMES));
3647 275 : SWIG_Python_SetConstant(d, "DCAP_NOTNULL_FIELDS",SWIG_FromCharPtr(GDAL_DCAP_NOTNULL_FIELDS));
3648 275 : SWIG_Python_SetConstant(d, "DCAP_UNIQUE_FIELDS",SWIG_FromCharPtr(GDAL_DCAP_UNIQUE_FIELDS));
3649 275 : SWIG_Python_SetConstant(d, "DCAP_DEFAULT_FIELDS",SWIG_FromCharPtr(GDAL_DCAP_DEFAULT_FIELDS));
3650 275 : SWIG_Python_SetConstant(d, "DCAP_NOTNULL_GEOMFIELDS",SWIG_FromCharPtr(GDAL_DCAP_NOTNULL_GEOMFIELDS));
3651 275 : SWIG_Python_SetConstant(d, "DCAP_NONSPATIAL",SWIG_FromCharPtr(GDAL_DCAP_NONSPATIAL));
3652 275 : SWIG_Python_SetConstant(d, "DCAP_CURVE_GEOMETRIES",SWIG_FromCharPtr(GDAL_DCAP_CURVE_GEOMETRIES));
3653 275 : SWIG_Python_SetConstant(d, "DCAP_MEASURED_GEOMETRIES",SWIG_FromCharPtr(GDAL_DCAP_MEASURED_GEOMETRIES));
3654 275 : SWIG_Python_SetConstant(d, "DCAP_Z_GEOMETRIES",SWIG_FromCharPtr(GDAL_DCAP_Z_GEOMETRIES));
3655 275 : SWIG_Python_SetConstant(d, "DMD_GEOMETRY_FLAGS",SWIG_FromCharPtr(GDAL_DMD_GEOMETRY_FLAGS));
3656 275 : SWIG_Python_SetConstant(d, "DCAP_FEATURE_STYLES",SWIG_FromCharPtr(GDAL_DCAP_FEATURE_STYLES));
3657 275 : SWIG_Python_SetConstant(d, "DCAP_FEATURE_STYLES_READ",SWIG_FromCharPtr(GDAL_DCAP_FEATURE_STYLES_READ));
3658 275 : SWIG_Python_SetConstant(d, "DCAP_FEATURE_STYLES_WRITE",SWIG_FromCharPtr(GDAL_DCAP_FEATURE_STYLES_WRITE));
3659 275 : SWIG_Python_SetConstant(d, "DCAP_COORDINATE_EPOCH",SWIG_FromCharPtr(GDAL_DCAP_COORDINATE_EPOCH));
3660 275 : SWIG_Python_SetConstant(d, "DCAP_MULTIPLE_VECTOR_LAYERS",SWIG_FromCharPtr(GDAL_DCAP_MULTIPLE_VECTOR_LAYERS));
3661 275 : SWIG_Python_SetConstant(d, "DCAP_FIELD_DOMAINS",SWIG_FromCharPtr(GDAL_DCAP_FIELD_DOMAINS));
3662 275 : SWIG_Python_SetConstant(d, "DCAP_RELATIONSHIPS",SWIG_FromCharPtr(GDAL_DCAP_RELATIONSHIPS));
3663 275 : SWIG_Python_SetConstant(d, "GDAL_DCAP_CREATE_RELATIONSHIP",SWIG_FromCharPtr(GDAL_DCAP_CREATE_RELATIONSHIP));
3664 275 : SWIG_Python_SetConstant(d, "GDAL_DCAP_DELETE_RELATIONSHIP",SWIG_FromCharPtr(GDAL_DCAP_DELETE_RELATIONSHIP));
3665 275 : SWIG_Python_SetConstant(d, "GDAL_DCAP_UPDATE_RELATIONSHIP",SWIG_FromCharPtr(GDAL_DCAP_UPDATE_RELATIONSHIP));
3666 275 : SWIG_Python_SetConstant(d, "GDAL_DMD_RELATIONSHIP_FLAGS",SWIG_FromCharPtr(GDAL_DMD_RELATIONSHIP_FLAGS));
3667 275 : SWIG_Python_SetConstant(d, "GDAL_DMD_RELATIONSHIP_RELATED_TABLE_TYPES",SWIG_FromCharPtr(GDAL_DMD_RELATIONSHIP_RELATED_TABLE_TYPES));
3668 275 : SWIG_Python_SetConstant(d, "DCAP_RENAME_LAYERS",SWIG_FromCharPtr(GDAL_DCAP_RENAME_LAYERS));
3669 275 : SWIG_Python_SetConstant(d, "DCAP_FLUSHCACHE_CONSISTENT_STATE",SWIG_FromCharPtr(GDAL_DCAP_FLUSHCACHE_CONSISTENT_STATE));
3670 275 : SWIG_Python_SetConstant(d, "DIM_TYPE_HORIZONTAL_X",SWIG_FromCharPtr(GDAL_DIM_TYPE_HORIZONTAL_X));
3671 275 : SWIG_Python_SetConstant(d, "DIM_TYPE_HORIZONTAL_Y",SWIG_FromCharPtr(GDAL_DIM_TYPE_HORIZONTAL_Y));
3672 275 : SWIG_Python_SetConstant(d, "DIM_TYPE_VERTICAL",SWIG_FromCharPtr(GDAL_DIM_TYPE_VERTICAL));
3673 275 : SWIG_Python_SetConstant(d, "DIM_TYPE_TEMPORAL",SWIG_FromCharPtr(GDAL_DIM_TYPE_TEMPORAL));
3674 275 : SWIG_Python_SetConstant(d, "DIM_TYPE_PARAMETRIC",SWIG_FromCharPtr(GDAL_DIM_TYPE_PARAMETRIC));
3675 275 : SWIG_Python_SetConstant(d, "GDsCAddRelationship",SWIG_FromCharPtr("AddRelationship"));
3676 275 : SWIG_Python_SetConstant(d, "GDsCDeleteRelationship",SWIG_FromCharPtr("DeleteRelationship"));
3677 275 : SWIG_Python_SetConstant(d, "GDsCUpdateRelationship",SWIG_FromCharPtr("UpdateRelationship"));
3678 275 : SWIG_Python_SetConstant(d, "CPLES_BackslashQuotable",SWIG_From_int((int)(CPLES_BackslashQuotable)));
3679 275 : SWIG_Python_SetConstant(d, "CPLES_XML",SWIG_From_int((int)(CPLES_XML)));
3680 275 : SWIG_Python_SetConstant(d, "CPLES_XML_BUT_QUOTES",SWIG_From_int((int)(CPLES_XML_BUT_QUOTES)));
3681 275 : SWIG_Python_SetConstant(d, "CPLES_URL",SWIG_From_int((int)(CPLES_URL)));
3682 275 : SWIG_Python_SetConstant(d, "CPLES_SQL",SWIG_From_int((int)(CPLES_SQL)));
3683 275 : SWIG_Python_SetConstant(d, "CPLES_SQLI",SWIG_From_int((int)(CPLES_SQLI)));
3684 275 : SWIG_Python_SetConstant(d, "CPLES_CSV",SWIG_From_int((int)(CPLES_CSV)));
3685 275 : SWIG_Python_SetConstant(d, "GFT_Integer",SWIG_From_int((int)(GFT_Integer)));
3686 275 : SWIG_Python_SetConstant(d, "GFT_Real",SWIG_From_int((int)(GFT_Real)));
3687 275 : SWIG_Python_SetConstant(d, "GFT_String",SWIG_From_int((int)(GFT_String)));
3688 275 : SWIG_Python_SetConstant(d, "GFU_Generic",SWIG_From_int((int)(GFU_Generic)));
3689 275 : SWIG_Python_SetConstant(d, "GFU_PixelCount",SWIG_From_int((int)(GFU_PixelCount)));
3690 275 : SWIG_Python_SetConstant(d, "GFU_Name",SWIG_From_int((int)(GFU_Name)));
3691 275 : SWIG_Python_SetConstant(d, "GFU_Min",SWIG_From_int((int)(GFU_Min)));
3692 275 : SWIG_Python_SetConstant(d, "GFU_Max",SWIG_From_int((int)(GFU_Max)));
3693 275 : SWIG_Python_SetConstant(d, "GFU_MinMax",SWIG_From_int((int)(GFU_MinMax)));
3694 275 : SWIG_Python_SetConstant(d, "GFU_Red",SWIG_From_int((int)(GFU_Red)));
3695 275 : SWIG_Python_SetConstant(d, "GFU_Green",SWIG_From_int((int)(GFU_Green)));
3696 275 : SWIG_Python_SetConstant(d, "GFU_Blue",SWIG_From_int((int)(GFU_Blue)));
3697 275 : SWIG_Python_SetConstant(d, "GFU_Alpha",SWIG_From_int((int)(GFU_Alpha)));
3698 275 : SWIG_Python_SetConstant(d, "GFU_RedMin",SWIG_From_int((int)(GFU_RedMin)));
3699 275 : SWIG_Python_SetConstant(d, "GFU_GreenMin",SWIG_From_int((int)(GFU_GreenMin)));
3700 275 : SWIG_Python_SetConstant(d, "GFU_BlueMin",SWIG_From_int((int)(GFU_BlueMin)));
3701 275 : SWIG_Python_SetConstant(d, "GFU_AlphaMin",SWIG_From_int((int)(GFU_AlphaMin)));
3702 275 : SWIG_Python_SetConstant(d, "GFU_RedMax",SWIG_From_int((int)(GFU_RedMax)));
3703 275 : SWIG_Python_SetConstant(d, "GFU_GreenMax",SWIG_From_int((int)(GFU_GreenMax)));
3704 275 : SWIG_Python_SetConstant(d, "GFU_BlueMax",SWIG_From_int((int)(GFU_BlueMax)));
3705 275 : SWIG_Python_SetConstant(d, "GFU_AlphaMax",SWIG_From_int((int)(GFU_AlphaMax)));
3706 275 : SWIG_Python_SetConstant(d, "GFU_MaxCount",SWIG_From_int((int)(GFU_MaxCount)));
3707 275 : SWIG_Python_SetConstant(d, "GRTT_THEMATIC",SWIG_From_int((int)(GRTT_THEMATIC)));
3708 275 : SWIG_Python_SetConstant(d, "GRTT_ATHEMATIC",SWIG_From_int((int)(GRTT_ATHEMATIC)));
3709 275 : SWIG_Python_SetConstant(d, "GMF_ALL_VALID",SWIG_From_int((int)(0x01)));
3710 275 : SWIG_Python_SetConstant(d, "GMF_PER_DATASET",SWIG_From_int((int)(0x02)));
3711 275 : SWIG_Python_SetConstant(d, "GMF_ALPHA",SWIG_From_int((int)(0x04)));
3712 275 : SWIG_Python_SetConstant(d, "GMF_NODATA",SWIG_From_int((int)(0x08)));
3713 275 : SWIG_Python_SetConstant(d, "GDAL_DATA_COVERAGE_STATUS_UNIMPLEMENTED",SWIG_From_int((int)(0x01)));
3714 275 : SWIG_Python_SetConstant(d, "GDAL_DATA_COVERAGE_STATUS_DATA",SWIG_From_int((int)(0x02)));
3715 275 : SWIG_Python_SetConstant(d, "GDAL_DATA_COVERAGE_STATUS_EMPTY",SWIG_From_int((int)(0x04)));
3716 275 : SWIG_Python_SetConstant(d, "GARIO_PENDING",SWIG_From_int((int)(GARIO_PENDING)));
3717 275 : SWIG_Python_SetConstant(d, "GARIO_UPDATE",SWIG_From_int((int)(GARIO_UPDATE)));
3718 275 : SWIG_Python_SetConstant(d, "GARIO_ERROR",SWIG_From_int((int)(GARIO_ERROR)));
3719 275 : SWIG_Python_SetConstant(d, "GARIO_COMPLETE",SWIG_From_int((int)(GARIO_COMPLETE)));
3720 275 : SWIG_Python_SetConstant(d, "GTO_TIP",SWIG_From_int((int)(GTO_TIP)));
3721 275 : SWIG_Python_SetConstant(d, "GTO_BIT",SWIG_From_int((int)(GTO_BIT)));
3722 275 : SWIG_Python_SetConstant(d, "GTO_BSQ",SWIG_From_int((int)(GTO_BSQ)));
3723 275 : SWIG_Python_SetConstant(d, "GRC_ONE_TO_ONE",SWIG_From_int((int)(GRC_ONE_TO_ONE)));
3724 275 : SWIG_Python_SetConstant(d, "GRC_ONE_TO_MANY",SWIG_From_int((int)(GRC_ONE_TO_MANY)));
3725 275 : SWIG_Python_SetConstant(d, "GRC_MANY_TO_ONE",SWIG_From_int((int)(GRC_MANY_TO_ONE)));
3726 275 : SWIG_Python_SetConstant(d, "GRC_MANY_TO_MANY",SWIG_From_int((int)(GRC_MANY_TO_MANY)));
3727 275 : SWIG_Python_SetConstant(d, "GRT_COMPOSITE",SWIG_From_int((int)(GRT_COMPOSITE)));
3728 275 : SWIG_Python_SetConstant(d, "GRT_ASSOCIATION",SWIG_From_int((int)(GRT_ASSOCIATION)));
3729 275 : SWIG_Python_SetConstant(d, "GRT_AGGREGATION",SWIG_From_int((int)(GRT_AGGREGATION)));
3730 :
3731 : /* Initialize threading */
3732 275 : SWIG_PYTHON_INITIALIZE_THREADS;
3733 : #if PY_VERSION_HEX >= 0x03000000
3734 275 : return m;
3735 : #else
3736 : return;
3737 : #endif
3738 : }
3739 :
|