1 /* ----------------------------------------------------------------------------
2 * This file was automatically generated by SWIG (http://www.swig.org).
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 * ----------------------------------------------------------------------------- */
12 #define SWIG_CASTRANK_MODE
13 /* -----------------------------------------------------------------------------
14 * This section contains generic SWIG labels for method/variable
15 * declarations/attributes, and other compiler dependent labels.
16 * ----------------------------------------------------------------------------- */
18 /* template workaround for compilers that cannot correctly implement the C++ standard */
19 #ifndef SWIGTEMPLATEDISAMBIGUATOR
20 # if defined(__SUNPRO_CC) && (__SUNPRO_CC <= 0x560)
21 # define SWIGTEMPLATEDISAMBIGUATOR template
22 # elif defined(__HP_aCC)
23 /* Needed even with `aCC -AA' when `aCC -V' reports HP ANSI C++ B3910B A.03.55 */
24 /* If we find a maximum version that requires this, the test would be __HP_aCC <= 35500 for A.03.55 */
25 # define SWIGTEMPLATEDISAMBIGUATOR template
27 # define SWIGTEMPLATEDISAMBIGUATOR
31 /* inline attribute */
33 # if defined(__cplusplus) || (defined(__GNUC__) && !defined(__STRICT_ANSI__))
34 # define SWIGINLINE inline
40 /* attribute recognised by some compilers to avoid 'unused' warnings */
42 # if defined(__GNUC__)
43 # if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
44 # define SWIGUNUSED __attribute__ ((__unused__))
49 # define SWIGUNUSED __attribute__ ((__unused__))
55 #ifndef SWIGUNUSEDPARM
57 # define SWIGUNUSEDPARM(p)
59 # define SWIGUNUSEDPARM(p) p SWIGUNUSED
63 /* internal SWIG method */
65 # define SWIGINTERN static SWIGUNUSED
68 /* internal inline SWIG method */
69 #ifndef SWIGINTERNINLINE
70 # define SWIGINTERNINLINE SWIGINTERN SWIGINLINE
73 /* exporting methods */
74 #if (__GNUC__ >= 4) || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)
75 # ifndef GCC_HASCLASSVISIBILITY
76 # define GCC_HASCLASSVISIBILITY
81 # if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
82 # if defined(STATIC_LINKED)
85 # define SWIGEXPORT __declspec(dllexport)
88 # if defined(__GNUC__) && defined(GCC_HASCLASSVISIBILITY)
89 # define SWIGEXPORT __attribute__ ((visibility("default")))
96 /* calling conventions for Windows */
98 # if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
99 # define SWIGSTDCALL __stdcall
105 /* Deal with Microsoft's attempt at deprecating C standard runtime functions */
106 #if !defined(SWIG_NO_CRT_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_CRT_SECURE_NO_DEPRECATE)
107 # define _CRT_SECURE_NO_DEPRECATE
110 /* Deal with Microsoft's attempt at deprecating methods in the standard C++ library */
111 #if !defined(SWIG_NO_SCL_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_SCL_SECURE_NO_DEPRECATE)
112 # define _SCL_SECURE_NO_DEPRECATE
116 /* -----------------------------------------------------------------------------
119 * This file contains generic CAPI SWIG runtime support for pointer
121 * ----------------------------------------------------------------------------- */
123 /* This should only be incremented when either the layout of swig_type_info changes,
124 or for whatever reason, the runtime changes incompatibly */
125 #define SWIG_RUNTIME_VERSION "3"
127 /* define SWIG_TYPE_TABLE_NAME as "SWIG_TYPE_TABLE" */
128 #ifdef SWIG_TYPE_TABLE
129 # define SWIG_QUOTE_STRING(x) #x
130 # define SWIG_EXPAND_AND_QUOTE_STRING(x) SWIG_QUOTE_STRING(x)
131 # define SWIG_TYPE_TABLE_NAME SWIG_EXPAND_AND_QUOTE_STRING(SWIG_TYPE_TABLE)
133 # define SWIG_TYPE_TABLE_NAME
137 You can use the SWIGRUNTIME and SWIGRUNTIMEINLINE macros for
138 creating a static or dynamic library from the swig runtime code.
139 In 99.9% of the cases, swig just needs to declare them as 'static'.
141 But only do this if is strictly necessary, ie, if you have problems
142 with your compiler or so.
146 # define SWIGRUNTIME SWIGINTERN
149 #ifndef SWIGRUNTIMEINLINE
150 # define SWIGRUNTIMEINLINE SWIGRUNTIME SWIGINLINE
153 /* Generic buffer size */
154 #ifndef SWIG_BUFFER_SIZE
155 # define SWIG_BUFFER_SIZE 1024
158 /* Flags for pointer conversions */
159 #define SWIG_POINTER_DISOWN 0x1
161 /* Flags for new pointer objects */
162 #define SWIG_POINTER_OWN 0x1
166 Flags/methods for returning states.
168 The swig conversion methods, as ConvertPtr, return and integer
169 that tells if the conversion was successful or not. And if not,
170 an error code can be returned (see swigerrors.swg for the codes).
172 Use the following macros/flags to set or process the returning
175 In old swig versions, you usually write code as:
177 if (SWIG_ConvertPtr(obj,vptr,ty.flags) != -1) {
183 Now you can be more explicit as:
185 int res = SWIG_ConvertPtr(obj,vptr,ty.flags);
186 if (SWIG_IsOK(res)) {
192 that seems to be the same, but now you can also do
195 int res = SWIG_ConvertPtr(obj,(void **)(&ptr),ty.flags);
196 if (SWIG_IsOK(res)) {
198 if (SWIG_IsNewObj(res) {
208 I.e., now SWIG_ConvertPtr can return new objects and you can
209 identify the case and take care of the deallocation. Of course that
210 requires also to SWIG_ConvertPtr to return new result values, as
212 int SWIG_ConvertPtr(obj, ptr,...) {
214 if (<need new object>) {
215 *ptr = <ptr to new allocated object>;
218 *ptr = <ptr to old object>;
226 Of course, returning the plain '0(success)/-1(fail)' still works, but you can be
227 more explicit by returning SWIG_BADOBJ, SWIG_ERROR or any of the
230 Finally, if the SWIG_CASTRANK_MODE is enabled, the result code
231 allows to return the 'cast rank', for example, if you have this
238 food(1) // cast rank '1' (1 -> 1.0)
239 fooi(1) // cast rank '0'
241 just use the SWIG_AddCast()/SWIG_CheckState()
246 #define SWIG_ERROR (-1)
247 #define SWIG_IsOK(r) (r >= 0)
248 #define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
250 /* The CastRankLimit says how many bits are used for the cast rank */
251 #define SWIG_CASTRANKLIMIT (1 << 8)
252 /* The NewMask denotes the object was created (using new/malloc) */
253 #define SWIG_NEWOBJMASK (SWIG_CASTRANKLIMIT << 1)
254 /* The TmpMask is for in/out typemaps that use temporal objects */
255 #define SWIG_TMPOBJMASK (SWIG_NEWOBJMASK << 1)
256 /* Simple returning values */
257 #define SWIG_BADOBJ (SWIG_ERROR)
258 #define SWIG_OLDOBJ (SWIG_OK)
259 #define SWIG_NEWOBJ (SWIG_OK | SWIG_NEWOBJMASK)
260 #define SWIG_TMPOBJ (SWIG_OK | SWIG_TMPOBJMASK)
261 /* Check, add and del mask methods */
262 #define SWIG_AddNewMask(r) (SWIG_IsOK(r) ? (r | SWIG_NEWOBJMASK) : r)
263 #define SWIG_DelNewMask(r) (SWIG_IsOK(r) ? (r & ~SWIG_NEWOBJMASK) : r)
264 #define SWIG_IsNewObj(r) (SWIG_IsOK(r) && (r & SWIG_NEWOBJMASK))
265 #define SWIG_AddTmpMask(r) (SWIG_IsOK(r) ? (r | SWIG_TMPOBJMASK) : r)
266 #define SWIG_DelTmpMask(r) (SWIG_IsOK(r) ? (r & ~SWIG_TMPOBJMASK) : r)
267 #define SWIG_IsTmpObj(r) (SWIG_IsOK(r) && (r & SWIG_TMPOBJMASK))
271 #if defined(SWIG_CASTRANK_MODE)
272 # ifndef SWIG_TypeRank
273 # define SWIG_TypeRank unsigned long
275 # ifndef SWIG_MAXCASTRANK /* Default cast allowed */
276 # define SWIG_MAXCASTRANK (2)
278 # define SWIG_CASTRANKMASK ((SWIG_CASTRANKLIMIT) -1)
279 # define SWIG_CastRank(r) (r & SWIG_CASTRANKMASK)
280 SWIGINTERNINLINE int SWIG_AddCast(int r) {
281 return SWIG_IsOK(r) ? ((SWIG_CastRank(r) < SWIG_MAXCASTRANK) ? (r + 1) : SWIG_ERROR) : r;
283 SWIGINTERNINLINE int SWIG_CheckState(int r) {
284 return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
286 #else /* no cast-rank mode */
287 # define SWIG_AddCast
288 # define SWIG_CheckState(r) (SWIG_IsOK(r) ? 1 : 0)
300 typedef void *(*swig_converter_func)(void *);
301 typedef struct swig_type_info *(*swig_dycast_func)(void **);
303 /* Structure to store inforomation on one type */
304 typedef struct swig_type_info {
305 const char *name; /* mangled name of this type */
306 const char *str; /* human readable name of this type */
307 swig_dycast_func dcast; /* dynamic cast function down a hierarchy */
308 struct swig_cast_info *cast; /* linked list of types that can cast into this type */
309 void *clientdata; /* language specific type data */
310 int owndata; /* flag if the structure owns the clientdata */
313 /* Structure to store a type and conversion function used for casting */
314 typedef struct swig_cast_info {
315 swig_type_info *type; /* pointer to type that is equivalent to this type */
316 swig_converter_func converter; /* function to cast the void pointers */
317 struct swig_cast_info *next; /* pointer to next cast in linked list */
318 struct swig_cast_info *prev; /* pointer to the previous cast */
321 /* Structure used to store module information
322 * Each module generates one structure like this, and the runtime collects
323 * all of these structures and stores them in a circularly linked list.*/
324 typedef struct swig_module_info {
325 swig_type_info **types; /* Array of pointers to swig_type_info structures that are in this module */
326 size_t size; /* Number of types in this module */
327 struct swig_module_info *next; /* Pointer to next element in circularly linked list */
328 swig_type_info **type_initial; /* Array of initially generated type structures */
329 swig_cast_info **cast_initial; /* Array of initially generated casting structures */
330 void *clientdata; /* Language specific module data */
334 Compare two type names skipping the space characters, therefore
335 "char*" == "char *" and "Class<int>" == "Class<int >", etc.
337 Return 0 when the two name types are equivalent, as in
338 strncmp, but skipping ' '.
341 SWIG_TypeNameComp(const char *f1, const char *l1,
342 const char *f2, const char *l2) {
343 for (;(f1 != l1) && (f2 != l2); ++f1, ++f2) {
344 while ((*f1 == ' ') && (f1 != l1)) ++f1;
345 while ((*f2 == ' ') && (f2 != l2)) ++f2;
346 if (*f1 != *f2) return (*f1 > *f2) ? 1 : -1;
348 return (int)((l1 - f1) - (l2 - f2));
352 Check type equivalence in a name list like <name1>|<name2>|...
353 Return 0 if not equal, 1 if equal
356 SWIG_TypeEquiv(const char *nb, const char *tb) {
358 const char* te = tb + strlen(tb);
360 while (!equiv && *ne) {
361 for (nb = ne; *ne; ++ne) {
362 if (*ne == '|') break;
364 equiv = (SWIG_TypeNameComp(nb, ne, tb, te) == 0) ? 1 : 0;
371 Check type equivalence in a name list like <name1>|<name2>|...
372 Return 0 if equal, -1 if nb < tb, 1 if nb > tb
375 SWIG_TypeCompare(const char *nb, const char *tb) {
377 const char* te = tb + strlen(tb);
379 while (!equiv && *ne) {
380 for (nb = ne; *ne; ++ne) {
381 if (*ne == '|') break;
383 equiv = (SWIG_TypeNameComp(nb, ne, tb, te) == 0) ? 1 : 0;
390 /* think of this as a c++ template<> or a scheme macro */
391 #define SWIG_TypeCheck_Template(comparison, ty) \
393 swig_cast_info *iter = ty->cast; \
396 if (iter == ty->cast) return iter; \
397 /* Move iter to the top of the linked list */ \
398 iter->prev->next = iter->next; \
400 iter->next->prev = iter->prev; \
401 iter->next = ty->cast; \
403 if (ty->cast) ty->cast->prev = iter; \
415 SWIGRUNTIME swig_cast_info *
416 SWIG_TypeCheck(const char *c, swig_type_info *ty) {
417 SWIG_TypeCheck_Template(strcmp(iter->type->name, c) == 0, ty);
420 /* Same as previous function, except strcmp is replaced with a pointer comparison */
421 SWIGRUNTIME swig_cast_info *
422 SWIG_TypeCheckStruct(swig_type_info *from, swig_type_info *into) {
423 SWIG_TypeCheck_Template(iter->type == from, into);
427 Cast a pointer up an inheritance hierarchy
429 SWIGRUNTIMEINLINE void *
430 SWIG_TypeCast(swig_cast_info *ty, void *ptr) {
431 return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr);
435 Dynamic pointer casting. Down an inheritance hierarchy
437 SWIGRUNTIME swig_type_info *
438 SWIG_TypeDynamicCast(swig_type_info *ty, void **ptr) {
439 swig_type_info *lastty = ty;
440 if (!ty || !ty->dcast) return ty;
441 while (ty && (ty->dcast)) {
442 ty = (*ty->dcast)(ptr);
449 Return the name associated with this type
451 SWIGRUNTIMEINLINE const char *
452 SWIG_TypeName(const swig_type_info *ty) {
457 Return the pretty name associated with this type,
458 that is an unmangled type name in a form presentable to the user.
460 SWIGRUNTIME const char *
461 SWIG_TypePrettyName(const swig_type_info *type) {
462 /* The "str" field contains the equivalent pretty names of the
463 type, separated by vertical-bar characters. We choose
464 to print the last name, as it is often (?) the most
466 if (!type) return NULL;
467 if (type->str != NULL) {
468 const char *last_name = type->str;
470 for (s = type->str; *s; s++)
471 if (*s == '|') last_name = s+1;
479 Set the clientdata field for a type
482 SWIG_TypeClientData(swig_type_info *ti, void *clientdata) {
483 swig_cast_info *cast = ti->cast;
484 /* if (ti->clientdata == clientdata) return; */
485 ti->clientdata = clientdata;
488 if (!cast->converter) {
489 swig_type_info *tc = cast->type;
490 if (!tc->clientdata) {
491 SWIG_TypeClientData(tc, clientdata);
498 SWIG_TypeNewClientData(swig_type_info *ti, void *clientdata) {
499 SWIG_TypeClientData(ti, clientdata);
504 Search for a swig_type_info structure only by mangled name
505 Search is a O(log #types)
507 We start searching at module start, and finish searching when start == end.
508 Note: if start == end at the beginning of the function, we go all the way around
511 SWIGRUNTIME swig_type_info *
512 SWIG_MangledTypeQueryModule(swig_module_info *start,
513 swig_module_info *end,
515 swig_module_info *iter = start;
518 register size_t l = 0;
519 register size_t r = iter->size - 1;
521 /* since l+r >= 0, we can (>> 1) instead (/ 2) */
522 register size_t i = (l + r) >> 1;
523 const char *iname = iter->types[i]->name;
525 register int compare = strcmp(name, iname);
527 return iter->types[i];
528 } else if (compare < 0) {
534 } else if (compare > 0) {
538 break; /* should never happen */
543 } while (iter != end);
548 Search for a swig_type_info structure for either a mangled name or a human readable name.
549 It first searches the mangled names of the types, which is a O(log #types)
550 If a type is not found it then searches the human readable names, which is O(#types).
552 We start searching at module start, and finish searching when start == end.
553 Note: if start == end at the beginning of the function, we go all the way around
556 SWIGRUNTIME swig_type_info *
557 SWIG_TypeQueryModule(swig_module_info *start,
558 swig_module_info *end,
560 /* STEP 1: Search the name field using binary search */
561 swig_type_info *ret = SWIG_MangledTypeQueryModule(start, end, name);
565 /* STEP 2: If the type hasn't been found, do a complete search
566 of the str field (the human readable name) */
567 swig_module_info *iter = start;
569 register size_t i = 0;
570 for (; i < iter->size; ++i) {
571 if (iter->types[i]->str && (SWIG_TypeEquiv(iter->types[i]->str, name)))
572 return iter->types[i];
575 } while (iter != end);
578 /* neither found a match */
583 Pack binary data into a string
586 SWIG_PackData(char *c, void *ptr, size_t sz) {
587 static const char hex[17] = "0123456789abcdef";
588 register const unsigned char *u = (unsigned char *) ptr;
589 register const unsigned char *eu = u + sz;
590 for (; u != eu; ++u) {
591 register unsigned char uu = *u;
592 *(c++) = hex[(uu & 0xf0) >> 4];
593 *(c++) = hex[uu & 0xf];
599 Unpack binary data from a string
601 SWIGRUNTIME const char *
602 SWIG_UnpackData(const char *c, void *ptr, size_t sz) {
603 register unsigned char *u = (unsigned char *) ptr;
604 register const unsigned char *eu = u + sz;
605 for (; u != eu; ++u) {
606 register char d = *(c++);
607 register unsigned char uu;
608 if ((d >= '0') && (d <= '9'))
609 uu = ((d - '0') << 4);
610 else if ((d >= 'a') && (d <= 'f'))
611 uu = ((d - ('a'-10)) << 4);
615 if ((d >= '0') && (d <= '9'))
617 else if ((d >= 'a') && (d <= 'f'))
618 uu |= (d - ('a'-10));
627 Pack 'void *' into a string buffer.
630 SWIG_PackVoidPtr(char *buff, void *ptr, const char *name, size_t bsz) {
632 if ((2*sizeof(void *) + 2) > bsz) return 0;
634 r = SWIG_PackData(r,&ptr,sizeof(void *));
635 if (strlen(name) + 1 > (bsz - (r - buff))) return 0;
640 SWIGRUNTIME const char *
641 SWIG_UnpackVoidPtr(const char *c, void **ptr, const char *name) {
643 if (strcmp(c,"NULL") == 0) {
650 return SWIG_UnpackData(++c,ptr,sizeof(void *));
654 SWIG_PackDataName(char *buff, void *ptr, size_t sz, const char *name, size_t bsz) {
656 size_t lname = (name ? strlen(name) : 0);
657 if ((2*sz + 2 + lname) > bsz) return 0;
659 r = SWIG_PackData(r,ptr,sz);
661 strncpy(r,name,lname+1);
668 SWIGRUNTIME const char *
669 SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) {
671 if (strcmp(c,"NULL") == 0) {
678 return SWIG_UnpackData(++c,ptr,sz);
686 #define SWIG_UnknownError -1
687 #define SWIG_IOError -2
688 #define SWIG_RuntimeError -3
689 #define SWIG_IndexError -4
690 #define SWIG_TypeError -5
691 #define SWIG_DivisionByZero -6
692 #define SWIG_OverflowError -7
693 #define SWIG_SyntaxError -8
694 #define SWIG_ValueError -9
695 #define SWIG_SystemError -10
696 #define SWIG_AttributeError -11
697 #define SWIG_MemoryError -12
698 #define SWIG_NullReferenceError -13
703 /* Needed on some windows machines---since MS plays funny games with the header files under C++ */
712 /* Add in functionality missing in older versions of Perl. Much of this is based on Devel-PPPort on cpan. */
714 /* Add PERL_REVISION, PERL_VERSION, PERL_SUBVERSION if missing */
715 #ifndef PERL_REVISION
716 # if !defined(__PATCHLEVEL_H_INCLUDED__) && !(defined(PATCHLEVEL) && defined(SUBVERSION))
717 # define PERL_PATCHLEVEL_H_IMPLICIT
718 # include <patchlevel.h>
720 # if !(defined(PERL_VERSION) || (defined(SUBVERSION) && defined(PATCHLEVEL)))
721 # include <could_not_find_Perl_patchlevel.h>
723 # ifndef PERL_REVISION
724 # define PERL_REVISION (5)
725 # define PERL_VERSION PATCHLEVEL
726 # define PERL_SUBVERSION SUBVERSION
730 #if defined(WIN32) && defined(PERL_OBJECT) && !defined(PerlIO_exportFILE)
731 #define PerlIO_exportFILE(fh,fl) (FILE*)(fh)
735 # define SvIOK_UV(sv) (SvIOK(sv) && (SvUVX(sv) == SvIVX(sv)))
739 # define SvUOK(sv) SvIOK_UV(sv)
742 #if ((PERL_VERSION < 4) || ((PERL_VERSION == 4) && (PERL_SUBVERSION <= 5)))
743 # define PL_sv_undef sv_undef
745 # define PL_errgv errgv
746 # define PL_sv_no sv_no
747 # define PL_sv_yes sv_yes
748 # define PL_markstack_ptr markstack_ptr
753 # define IVSIZE LONGSIZE
755 # define IVSIZE 4 /* A bold guess, but the best we can make. */
760 # if (IVSIZE == PTRSIZE) && (UVSIZE == PTRSIZE)
762 # define INT2PTR(any,d) (any)(d)
764 # if PTRSIZE == LONGSIZE
765 # define PTRV unsigned long
767 # define PTRV unsigned
769 # define INT2PTR(any,d) (any)(PTRV)(d)
772 # define NUM2PTR(any,d) (any)(PTRV)(d)
773 # define PTR2IV(p) INT2PTR(IV,p)
774 # define PTR2UV(p) INT2PTR(UV,p)
775 # define PTR2NV(p) NUM2PTR(NV,p)
777 # if PTRSIZE == LONGSIZE
778 # define PTR2ul(p) (unsigned long)(p)
780 # define PTR2ul(p) INT2PTR(unsigned long,p)
782 #endif /* !INT2PTR */
785 # define SvPV_nolen(x) SvPV(x,PL_na)
789 # define get_sv perl_get_sv
793 # define ERRSV get_sv("@",FALSE)
805 /* -----------------------------------------------------------------------------
807 * ----------------------------------------------------------------------------- */
809 SWIGINTERN const char*
810 SWIG_Perl_ErrorType(int code) {
811 const char* type = 0;
813 case SWIG_MemoryError:
814 type = "MemoryError";
819 case SWIG_RuntimeError:
820 type = "RuntimeError";
822 case SWIG_IndexError:
828 case SWIG_DivisionByZero:
829 type = "ZeroDivisionError";
831 case SWIG_OverflowError:
832 type = "OverflowError";
834 case SWIG_SyntaxError:
835 type = "SyntaxError";
837 case SWIG_ValueError:
840 case SWIG_SystemError:
841 type = "SystemError";
843 case SWIG_AttributeError:
844 type = "AttributeError";
847 type = "RuntimeError";
855 /* -----------------------------------------------------------------------------
858 * This file contains the runtime support for Perl modules
859 * and includes code for managing global variables and pointer
861 * ----------------------------------------------------------------------------- */
864 #define SWIG_PERL_OBJECT_DECL CPerlObj *SWIGUNUSEDPARM(pPerl),
865 #define SWIG_PERL_OBJECT_CALL pPerl,
867 #define SWIG_PERL_OBJECT_DECL
868 #define SWIG_PERL_OBJECT_CALL
871 /* Common SWIG API */
873 /* for raw pointers */
874 #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags)
875 #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags)
877 /* for raw packed data */
878 #define SWIG_ConvertPacked(obj, p, s, type) SWIG_Perl_ConvertPacked(SWIG_PERL_OBJECT_CALL obj, p, s, type)
879 #define SWIG_NewPackedObj(p, s, type) SWIG_Perl_NewPackedObj(SWIG_PERL_OBJECT_CALL p, s, type)
881 /* for class or struct pointers */
882 #define SWIG_ConvertInstance(obj, pptr, type, flags) SWIG_ConvertPtr(obj, pptr, type, flags)
883 #define SWIG_NewInstanceObj(ptr, type, flags) SWIG_NewPointerObj(ptr, type, flags)
885 /* for C or C++ function pointers */
886 #define SWIG_ConvertFunctionPtr(obj, pptr, type) SWIG_ConvertPtr(obj, pptr, type, 0)
887 #define SWIG_NewFunctionPtrObj(ptr, type) SWIG_NewPointerObj(ptr, type, 0)
889 /* for C++ member pointers, ie, member methods */
890 #define SWIG_ConvertMember(obj, ptr, sz, ty) SWIG_ConvertPacked(obj, ptr, sz, ty)
891 #define SWIG_NewMemberObj(ptr, sz, type) SWIG_NewPackedObj(ptr, sz, type)
896 #define SWIG_GetModule(clientdata) SWIG_Perl_GetModule()
897 #define SWIG_SetModule(clientdata, pointer) SWIG_Perl_SetModule(pointer)
900 /* Error manipulation */
902 #define SWIG_ErrorType(code) SWIG_Perl_ErrorType(code)
903 #define SWIG_Error(code, msg) sv_setpvf(GvSV(PL_errgv),"%s %s\n", SWIG_ErrorType(code), msg)
904 #define SWIG_fail goto fail
906 /* Perl-specific SWIG API */
908 #define SWIG_MakePtr(sv, ptr, type, flags) SWIG_Perl_MakePtr(SWIG_PERL_OBJECT_CALL sv, ptr, type, flags)
909 #define SWIG_MakePackedObj(sv, p, s, type) SWIG_Perl_MakePackedObj(SWIG_PERL_OBJECT_CALL sv, p, s, type)
910 #define SWIG_SetError(str) SWIG_Error(SWIG_RuntimeError, str)
913 #define SWIG_PERL_DECL_ARGS_1(arg1) (SWIG_PERL_OBJECT_DECL arg1)
914 #define SWIG_PERL_CALL_ARGS_1(arg1) (SWIG_PERL_OBJECT_CALL arg1)
915 #define SWIG_PERL_DECL_ARGS_2(arg1, arg2) (SWIG_PERL_OBJECT_DECL arg1, arg2)
916 #define SWIG_PERL_CALL_ARGS_2(arg1, arg2) (SWIG_PERL_OBJECT_CALL arg1, arg2)
918 /* -----------------------------------------------------------------------------
919 * pointers/data manipulation
920 * ----------------------------------------------------------------------------- */
922 /* For backward compatibility only */
923 #define SWIG_POINTER_EXCEPTION 0
929 #define SWIG_OWNER SWIG_POINTER_OWN
930 #define SWIG_SHADOW SWIG_OWNER << 1
932 #define SWIG_MAYBE_PERL_OBJECT SWIG_PERL_OBJECT_DECL
934 /* SWIG Perl macros */
936 /* Macro to declare an XS function */
938 # define XSPROTO(name) void name(pTHX_ CV* cv)
941 /* Macro to call an XS function */
943 # define SWIG_CALLXS(_name) _name(cv,pPerl)
945 # ifndef MULTIPLICITY
946 # define SWIG_CALLXS(_name) _name(cv)
948 # define SWIG_CALLXS(_name) _name(PERL_GET_THX, cv)
953 #define MAGIC_PPERL CPerlObj *pPerl = (CPerlObj *) this;
958 typedef int (CPerlObj::*SwigMagicFunc)(SV *, MAGIC *);
963 #define SWIG_MAGIC(a,b) (SV *a, MAGIC *b)
964 #define SWIGCLASS_STATIC
966 #else /* PERL_OBJECT */
969 #define SWIGCLASS_STATIC static SWIGUNUSED
972 #define SWIG_MAGIC(a,b) (SV *a, MAGIC *b)
977 typedef int (*SwigMagicFunc)(SV *, MAGIC *);
982 #else /* MULTIPLICITY */
984 #define SWIG_MAGIC(a,b) (struct interpreter *interp, SV *a, MAGIC *b)
989 typedef int (*SwigMagicFunc)(struct interpreter *, SV *, MAGIC *);
994 #endif /* MULTIPLICITY */
995 #endif /* PERL_OBJECT */
997 /* Workaround for bug in perl 5.6.x croak and earlier */
998 #if (PERL_VERSION < 8)
1000 # define SWIG_croak_null() SWIG_Perl_croak_null(pPerl)
1001 static void SWIG_Perl_croak_null(CPerlObj *pPerl)
1003 static void SWIG_croak_null()
1007 # if (PERL_VERSION < 6)
1010 if (SvOK(err) && !SvROK(err)) croak("%_", err);
1015 # define SWIG_croak_null() croak(Nullch)
1020 Define how strict is the cast between strings and integers/doubles
1021 when overloading between these types occurs.
1023 The default is making it as strict as possible by using SWIG_AddCast
1026 You can use -DSWIG_PERL_NO_STRICT_STR2NUM at compilation time to
1027 disable the SWIG_AddCast, making the casting between string and
1028 numbers less strict.
1030 In the end, we try to solve the overloading between strings and
1031 numerical types in the more natural way, but if you can avoid it,
1032 well, avoid it using %rename, for example.
1034 #ifndef SWIG_PERL_NO_STRICT_STR2NUM
1035 # ifndef SWIG_PERL_STRICT_STR2NUM
1036 # define SWIG_PERL_STRICT_STR2NUM
1039 #ifdef SWIG_PERL_STRICT_STR2NUM
1040 /* string takes precedence */
1041 #define SWIG_Str2NumCast(x) SWIG_AddCast(x)
1043 /* number takes precedence */
1044 #define SWIG_Str2NumCast(x) x
1051 SWIGRUNTIME const char *
1052 SWIG_Perl_TypeProxyName(const swig_type_info *type) {
1053 if (!type) return NULL;
1054 if (type->clientdata != NULL) {
1055 return (const char*) type->clientdata;
1062 SWIGRUNTIME swig_cast_info *
1063 SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) {
1064 SWIG_TypeCheck_Template(( (!iter->type->clientdata && (strcmp((char*)iter->type->name, c) == 0))
1065 || (iter->type->clientdata && (strcmp((char*)iter->type->clientdata, c) == 0))), ty);
1069 /* Function for getting a pointer value */
1072 SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) {
1074 void *voidptr = (void *)0;
1076 /* If magical, apply more magic */
1080 /* Check to see if this is an object */
1081 if (sv_isobject(sv)) {
1083 tsv = (SV*) SvRV(sv);
1084 if ((SvTYPE(tsv) == SVt_PVHV)) {
1086 if (SvMAGICAL(tsv)) {
1087 mg = mg_find(tsv,'P');
1090 if (sv_isobject(sv)) {
1091 tsv = (SV*)SvRV(sv);
1101 voidptr = INT2PTR(void *,tmp);
1102 } else if (! SvOK(sv)) { /* Check for undef */
1103 *(ptr) = (void *) 0;
1105 } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */
1107 *(ptr) = (void *) 0;
1112 } else { /* Don't know what it is */
1116 /* Now see if the types match */
1117 char *_c = HvNAME(SvSTASH(SvRV(sv)));
1118 tc = SWIG_TypeProxyCheck(_c,_t);
1122 *ptr = SWIG_TypeCast(tc,voidptr);
1128 * DISOWN implementation: we need a perl guru to check this one.
1130 if (tsv && (flags & SWIG_POINTER_DISOWN)) {
1132 * almost copy paste code from below SWIG_POINTER_OWN setting
1135 HV *stash = SvSTASH(SvRV(obj));
1136 GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE);
1140 * To set ownership (see below), a newSViv(1) entry is added.
1141 * Hence, to remove ownership, we delete the entry.
1143 if (hv_exists_ent(hv, obj, 0)) {
1144 hv_delete_ent(hv, obj, 0, 0);
1152 SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) {
1153 if (ptr && (flags & SWIG_SHADOW)) {
1158 sv_setref_pv(obj, (char *) SWIG_Perl_TypeProxyName(t), ptr);
1159 stash=SvSTASH(SvRV(obj));
1160 if (flags & SWIG_POINTER_OWN) {
1162 GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE);
1164 gv_init(gv, stash, "OWNER", 5, FALSE);
1166 hv_store_ent(hv, obj, newSViv(1), 0);
1168 sv_magic((SV *)hash, (SV *)obj, 'P', Nullch, 0);
1170 self=newRV_noinc((SV *)hash);
1172 SvREFCNT_dec((SV *)self);
1173 sv_bless(sv, stash);
1176 sv_setref_pv(sv, (char *) SWIG_Perl_TypeProxyName(t), ptr);
1180 SWIGRUNTIMEINLINE SV *
1181 SWIG_Perl_NewPointerObj(SWIG_MAYBE_PERL_OBJECT void *ptr, swig_type_info *t, int flags) {
1182 SV *result = sv_newmortal();
1183 SWIG_MakePtr(result, ptr, t, flags);
1188 SWIG_Perl_MakePackedObj(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, int sz, swig_type_info *type) {
1191 if ((2*sz + 1 + strlen(SWIG_Perl_TypeProxyName(type))) > 1000) return;
1193 r = SWIG_PackData(r,ptr,sz);
1194 strcpy(r,SWIG_Perl_TypeProxyName(type));
1195 sv_setpv(sv, result);
1199 SWIG_Perl_NewPackedObj(SWIG_MAYBE_PERL_OBJECT void *ptr, int sz, swig_type_info *type) {
1200 SV *result = sv_newmortal();
1201 SWIG_Perl_MakePackedObj(result, ptr, sz, type);
1205 /* Convert a packed value value */
1207 SWIG_Perl_ConvertPacked(SWIG_MAYBE_PERL_OBJECT SV *obj, void *ptr, int sz, swig_type_info *ty) {
1211 if ((!obj) || (!SvOK(obj))) return SWIG_ERROR;
1212 c = SvPV_nolen(obj);
1213 /* Pointer values must start with leading underscore */
1214 if (*c != '_') return SWIG_ERROR;
1216 c = SWIG_UnpackData(c,ptr,sz);
1218 tc = SWIG_TypeCheck(c,ty);
1219 if (!tc) return SWIG_ERROR;
1225 /* Macros for low-level exception handling */
1226 #define SWIG_croak(x) { SWIG_Error(SWIG_RuntimeError, x); SWIG_fail; }
1229 typedef XSPROTO(SwigPerlWrapper);
1230 typedef SwigPerlWrapper *SwigPerlWrapperPtr;
1232 /* Structure for command table */
1235 SwigPerlWrapperPtr wrapper;
1236 } swig_command_info;
1238 /* Information for constant table */
1241 #define SWIG_FLOAT 2
1242 #define SWIG_STRING 3
1243 #define SWIG_POINTER 4
1244 #define SWIG_BINARY 5
1246 /* Constant information structure */
1247 typedef struct swig_constant_info {
1253 swig_type_info **ptype;
1254 } swig_constant_info;
1257 /* Structure for variable table */
1262 swig_type_info **type;
1263 } swig_variable_info;
1265 /* Magic variable code */
1267 #define swig_create_magic(s,a,b,c) _swig_create_magic(s,a,b,c)
1268 #ifndef MULTIPLICITY
1269 SWIGRUNTIME void _swig_create_magic(SV *sv, char *name, int (*set)(SV *, MAGIC *), int (*get)(SV *,MAGIC *))
1271 SWIGRUNTIME void _swig_create_magic(SV *sv, char *name, int (*set)(struct interpreter*, SV *, MAGIC *), int (*get)(struct interpreter*, SV *,MAGIC *))
1274 # define swig_create_magic(s,a,b,c) _swig_create_magic(pPerl,s,a,b,c)
1275 SWIGRUNTIME void _swig_create_magic(CPerlObj *pPerl, SV *sv, const char *name, int (CPerlObj::*set)(SV *, MAGIC *), int (CPerlObj::*get)(SV *, MAGIC *))
1279 sv_magic(sv,sv,'U',(char *) name,strlen(name));
1280 mg = mg_find(sv,'U');
1281 mg->mg_virtual = (MGVTBL *) malloc(sizeof(MGVTBL));
1282 mg->mg_virtual->svt_get = (SwigMagicFunc) get;
1283 mg->mg_virtual->svt_set = (SwigMagicFunc) set;
1284 mg->mg_virtual->svt_len = 0;
1285 mg->mg_virtual->svt_clear = 0;
1286 mg->mg_virtual->svt_free = 0;
1290 SWIGRUNTIME swig_module_info *
1291 SWIG_Perl_GetModule(void) {
1292 static void *type_pointer = (void *)0;
1295 /* first check if pointer already created */
1296 if (!type_pointer) {
1297 pointer = get_sv("swig_runtime_data::type_pointer" SWIG_RUNTIME_VERSION SWIG_TYPE_TABLE_NAME, FALSE);
1298 if (pointer && SvOK(pointer)) {
1299 type_pointer = INT2PTR(swig_type_info **, SvIV(pointer));
1303 return (swig_module_info *) type_pointer;
1307 SWIG_Perl_SetModule(swig_module_info *module) {
1310 /* create a new pointer */
1311 pointer = get_sv("swig_runtime_data::type_pointer" SWIG_RUNTIME_VERSION SWIG_TYPE_TABLE_NAME, TRUE);
1312 sv_setiv(pointer, PTR2IV(module));
1319 /* Workaround perl5 global namespace pollution. Note that undefining library
1320 * functions like fopen will not solve the problem on all platforms as fopen
1321 * might be a macro on Windows but not necessarily on other operating systems. */
1415 #define SWIG_exception_fail(code, msg) do { SWIG_Error(code, msg); SWIG_fail; } while(0)
1417 #define SWIG_contract_assert(expr, msg) if (!(expr)) { SWIG_Error(SWIG_RuntimeError, msg); SWIG_fail; } else
1421 #define SWIG_exception(code, msg) do { SWIG_Error(code, msg); SWIG_fail;; } while(0)
1424 /* -------- TYPES TABLE (BEGIN) -------- */
1426 #define SWIGTYPE_p_FILE swig_types[0]
1427 #define SWIGTYPE_p_char swig_types[1]
1428 #define SWIGTYPE_p_double swig_types[2]
1429 #define SWIGTYPE_p_find_result_t swig_types[3]
1430 #define SWIGTYPE_p_float swig_types[4]
1431 #define SWIGTYPE_p_int swig_types[5]
1432 #define SWIGTYPE_p_unsigned_char swig_types[6]
1433 static swig_type_info *swig_types[8];
1434 static swig_module_info swig_module = {swig_types, 7, 0, 0, 0, 0};
1435 #define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name)
1436 #define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name)
1438 /* -------- TYPES TABLE (END) -------- */
1440 #define SWIG_init boot_Amanda__Logfile
1442 #define SWIG_name "Amanda::Logfilec::boot_Amanda__Logfile"
1443 #define SWIG_prefix "Amanda::Logfilec::"
1445 #define SWIGVERSION 0x010333
1446 #define SWIG_VERSION SWIGVERSION
1449 #define SWIG_as_voidptr(a) (void *)((const void *)(a))
1450 #define SWIG_as_voidptrptr(a) ((void)SWIG_as_voidptr(*a),(void**)(a))
1457 #ifndef MULTIPLICITY
1458 SWIGEXPORT void SWIG_init (CV* cv);
1460 SWIGEXPORT void SWIG_init (pTHXo_ CV* cv);
1463 SWIGEXPORT void SWIG_init (CV *cv, CPerlObj *);
1477 #include "logfile.h"
1479 #include "diskfile.h" /* for the gross hack, below */
1482 SWIGINTERNINLINE SV *
1483 SWIG_From_long SWIG_PERL_DECL_ARGS_1(long value)
1485 SV *obj = sv_newmortal();
1486 sv_setiv(obj, (IV) value);
1491 SWIGINTERNINLINE SV *
1492 SWIG_From_int SWIG_PERL_DECL_ARGS_1(int value)
1494 return SWIG_From_long SWIG_PERL_CALL_ARGS_1(value);
1498 /* open_ and close_logfile are both simple wrappers around fopen/fclose. */
1499 typedef FILE loghandle;
1501 loghandle *open_logfile(char *filename) {
1502 return fopen(filename, "r");
1506 SWIGINTERN swig_type_info*
1507 SWIG_pchar_descriptor(void)
1509 static int init = 0;
1510 static swig_type_info* info = 0;
1512 info = SWIG_TypeQuery("_p_char");
1520 SWIG_AsCharPtrAndSize(SV *obj, char** cptr, size_t* psize, int *alloc)
1524 char *cstr = SvPV(obj, len);
1525 size_t size = len + 1;
1528 if (*alloc == SWIG_NEWOBJ) {
1529 *cptr = (char *)memcpy((char *)malloc((size)*sizeof(char)), cstr, sizeof(char)*(size));
1532 *alloc = SWIG_OLDOBJ;
1536 if (psize) *psize = size;
1539 swig_type_info* pchar_descriptor = SWIG_pchar_descriptor();
1540 if (pchar_descriptor) {
1542 if (SWIG_ConvertPtr(obj, (void**)&vptr, pchar_descriptor, 0) == SWIG_OK) {
1543 if (cptr) *cptr = vptr;
1544 if (psize) *psize = vptr ? (strlen(vptr) + 1) : 0;
1545 if (alloc) *alloc = SWIG_OLDOBJ;
1550 return SWIG_TypeError;
1557 void close_logfile(loghandle *logfile) {
1558 if (logfile) fclose(logfile);
1562 typedef int LOGLINE_RETURN;
1564 SWIGINTERN void delete_find_result_t(find_result_t *self){
1565 find_result_t *selfp = self;
1566 free_find_result(&selfp);
1569 SWIGINTERNINLINE SV *
1570 SWIG_FromCharPtrAndSize(const char* carray, size_t size)
1572 SV *obj = sv_newmortal();
1574 sv_setpvn(obj, carray, size);
1576 sv_setsv(obj, &PL_sv_undef);
1582 SWIGINTERNINLINE SV *
1583 SWIG_FromCharPtr(const char *cptr)
1585 return SWIG_FromCharPtrAndSize(cptr, (cptr ? strlen(cptr) : 0));
1589 find_result_t *search_logfile_wrap(char *label, char *datestamp,
1590 char *logfile, int add_missing_disks) {
1591 find_result_t *rv = NULL;
1593 /* We use a static variable to collect any unrecognized disks */
1594 static disklist_t unrecognized_disks = { NULL, NULL };
1596 search_logfile(&rv, label, datestamp, logfile,
1597 add_missing_disks? &unrecognized_disks : NULL);
1604 #if !defined(SWIG_NO_LLONG_MAX)
1605 # if !defined(LLONG_MAX) && defined(__GNUC__) && defined (__LONG_LONG_MAX__)
1606 # define LLONG_MAX __LONG_LONG_MAX__
1607 # define LLONG_MIN (-LLONG_MAX - 1LL)
1608 # define ULLONG_MAX (LLONG_MAX * 2ULL + 1ULL)
1614 SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val)
1617 if (val) *val = SvNV(obj);
1619 } else if (SvIOK(obj)) {
1620 if (val) *val = (double) SvIV(obj);
1621 return SWIG_AddCast(SWIG_OK);
1623 const char *nptr = SvPV_nolen(obj);
1626 double v = strtod(nptr, &endptr);
1627 if (errno == ERANGE) {
1629 return SWIG_OverflowError;
1631 if (*endptr == '\0') {
1633 return SWIG_Str2NumCast(SWIG_OK);
1638 return SWIG_TypeError;
1648 SWIGINTERNINLINE int
1649 SWIG_CanCastAsInteger(double *d, double min, double max) {
1651 if ((min <= x && x <= max)) {
1652 double fx = floor(x);
1653 double cx = ceil(x);
1654 double rd = ((x - fx) < 0.5) ? fx : cx; /* simple rint */
1655 if ((errno == EDOM) || (errno == ERANGE)) {
1658 double summ, reps, diff;
1661 } else if (rd > x) {
1668 if (reps < 8*DBL_EPSILON) {
1679 SWIG_AsVal_long SWIG_PERL_DECL_ARGS_2(SV *obj, long* val)
1682 if (val) *val = SvIV(obj);
1686 const char *nptr = SvPV_nolen(obj);
1691 v = strtol(nptr, &endptr,0);
1692 if (errno == ERANGE) {
1694 return SWIG_OverflowError;
1696 if (*endptr == '\0') {
1698 return SWIG_Str2NumCast(SWIG_OK);
1704 int res = SWIG_AddCast(SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(obj,&d));
1705 if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, LONG_MIN, LONG_MAX)) {
1706 if (val) *val = (long)(d);
1711 return SWIG_TypeError;
1716 SWIG_AsVal_int SWIG_PERL_DECL_ARGS_2(SV * obj, int *val)
1719 int res = SWIG_AsVal_long SWIG_PERL_CALL_ARGS_2(obj, &v);
1720 if (SWIG_IsOK(res)) {
1721 if ((v < INT_MIN || v > INT_MAX)) {
1722 return SWIG_OverflowError;
1724 if (val) *val = (int)(v);
1735 #define MAGIC_CLASS _wrap_Amanda::Logfile_var::
1736 class _wrap_Amanda::Logfile_var : public CPerlObj {
1741 SWIGCLASS_STATIC int swig_magic_readonly(pTHX_ SV *SWIGUNUSEDPARM(sv), MAGIC *SWIGUNUSEDPARM(mg)) {
1743 croak("Value is read-only.");
1759 XS(_wrap_open_logfile) {
1761 char *arg1 = (char *) 0 ;
1762 loghandle *result = 0 ;
1769 if ((items < 1) || (items > 1)) {
1770 SWIG_croak("Usage: open_logfile(filename);");
1772 res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1);
1773 if (!SWIG_IsOK(res1)) {
1774 SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "open_logfile" "', argument " "1"" of type '" "char *""'");
1776 arg1 = (char *)(buf1);
1777 result = (loghandle *)open_logfile(arg1);
1778 ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FILE, 0 | 0); argvi++ ;
1779 if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
1782 if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
1788 XS(_wrap_close_logfile) {
1790 loghandle *arg1 = (loghandle *) 0 ;
1796 if ((items < 1) || (items > 1)) {
1797 SWIG_croak("Usage: close_logfile(logfile);");
1799 res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FILE, 0 | 0 );
1800 if (!SWIG_IsOK(res1)) {
1801 SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "close_logfile" "', argument " "1"" of type '" "loghandle *""'");
1803 arg1 = (loghandle *)(argp1);
1804 close_logfile(arg1);
1815 XS(_wrap_get_logline) {
1817 FILE *arg1 = (FILE *) 0 ;
1818 LOGLINE_RETURN result;
1824 if ((items < 1) || (items > 1)) {
1825 SWIG_croak("Usage: get_logline(logfile);");
1827 res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FILE, 0 | 0 );
1828 if (!SWIG_IsOK(res1)) {
1829 SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "get_logline" "', argument " "1"" of type '" "FILE *""'");
1831 arg1 = (FILE *)(argp1);
1832 result = get_logline(arg1);
1836 ST(argvi) = sv_2mortal(newSViv(curlog));
1838 ST(argvi) = sv_2mortal(newSViv(curprog));
1840 ST(argvi) = sv_2mortal(newSVpv(curstr, 0));
1843 /* otherwise (end of logfile) return an empty list */
1854 XS(_wrap_delete_find_result_t) {
1856 find_result_t *arg1 = (find_result_t *) 0 ;
1862 if ((items < 1) || (items > 1)) {
1863 SWIG_croak("Usage: delete_find_result_t(self);");
1865 res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_find_result_t, SWIG_POINTER_DISOWN | 0 );
1866 if (!SWIG_IsOK(res1)) {
1867 SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_find_result_t" "', argument " "1"" of type '" "find_result_t *""'");
1869 arg1 = (find_result_t *)(argp1);
1870 delete_find_result_t(arg1);
1882 XS(_wrap_find_result_t_timestamp_get) {
1884 find_result_t *arg1 = (find_result_t *) 0 ;
1891 if ((items < 1) || (items > 1)) {
1892 SWIG_croak("Usage: find_result_t_timestamp_get(self);");
1894 res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_find_result_t, 0 | 0 );
1895 if (!SWIG_IsOK(res1)) {
1896 SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "find_result_t_timestamp_get" "', argument " "1"" of type '" "find_result_t *""'");
1898 arg1 = (find_result_t *)(argp1);
1899 result = (char *) ((arg1)->timestamp);
1900 ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ;
1910 XS(_wrap_find_result_t_hostname_get) {
1912 find_result_t *arg1 = (find_result_t *) 0 ;
1919 if ((items < 1) || (items > 1)) {
1920 SWIG_croak("Usage: find_result_t_hostname_get(self);");
1922 res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_find_result_t, 0 | 0 );
1923 if (!SWIG_IsOK(res1)) {
1924 SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "find_result_t_hostname_get" "', argument " "1"" of type '" "find_result_t *""'");
1926 arg1 = (find_result_t *)(argp1);
1927 result = (char *) ((arg1)->hostname);
1928 ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ;
1938 XS(_wrap_find_result_t_diskname_get) {
1940 find_result_t *arg1 = (find_result_t *) 0 ;
1947 if ((items < 1) || (items > 1)) {
1948 SWIG_croak("Usage: find_result_t_diskname_get(self);");
1950 res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_find_result_t, 0 | 0 );
1951 if (!SWIG_IsOK(res1)) {
1952 SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "find_result_t_diskname_get" "', argument " "1"" of type '" "find_result_t *""'");
1954 arg1 = (find_result_t *)(argp1);
1955 result = (char *) ((arg1)->diskname);
1956 ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ;
1966 XS(_wrap_find_result_t_level_get) {
1968 find_result_t *arg1 = (find_result_t *) 0 ;
1975 if ((items < 1) || (items > 1)) {
1976 SWIG_croak("Usage: find_result_t_level_get(self);");
1978 res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_find_result_t, 0 | 0 );
1979 if (!SWIG_IsOK(res1)) {
1980 SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "find_result_t_level_get" "', argument " "1"" of type '" "find_result_t *""'");
1982 arg1 = (find_result_t *)(argp1);
1983 result = (int) ((arg1)->level);
1985 ST(argvi) = sv_2mortal(amglue_newSVi64(result));
1997 XS(_wrap_find_result_t_label_get) {
1999 find_result_t *arg1 = (find_result_t *) 0 ;
2006 if ((items < 1) || (items > 1)) {
2007 SWIG_croak("Usage: find_result_t_label_get(self);");
2009 res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_find_result_t, 0 | 0 );
2010 if (!SWIG_IsOK(res1)) {
2011 SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "find_result_t_label_get" "', argument " "1"" of type '" "find_result_t *""'");
2013 arg1 = (find_result_t *)(argp1);
2014 result = (char *) ((arg1)->label);
2015 ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ;
2025 XS(_wrap_find_result_t_filenum_get) {
2027 find_result_t *arg1 = (find_result_t *) 0 ;
2034 if ((items < 1) || (items > 1)) {
2035 SWIG_croak("Usage: find_result_t_filenum_get(self);");
2037 res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_find_result_t, 0 | 0 );
2038 if (!SWIG_IsOK(res1)) {
2039 SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "find_result_t_filenum_get" "', argument " "1"" of type '" "find_result_t *""'");
2041 arg1 = (find_result_t *)(argp1);
2042 result = ((arg1)->filenum);
2044 ST(argvi) = sv_2mortal(amglue_newSVu64(result));
2056 XS(_wrap_find_result_t_status_get) {
2058 find_result_t *arg1 = (find_result_t *) 0 ;
2065 if ((items < 1) || (items > 1)) {
2066 SWIG_croak("Usage: find_result_t_status_get(self);");
2068 res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_find_result_t, 0 | 0 );
2069 if (!SWIG_IsOK(res1)) {
2070 SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "find_result_t_status_get" "', argument " "1"" of type '" "find_result_t *""'");
2072 arg1 = (find_result_t *)(argp1);
2073 result = (char *) ((arg1)->status);
2074 ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ;
2084 XS(_wrap_find_result_t_partnum_get) {
2086 find_result_t *arg1 = (find_result_t *) 0 ;
2093 if ((items < 1) || (items > 1)) {
2094 SWIG_croak("Usage: find_result_t_partnum_get(self);");
2096 res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_find_result_t, 0 | 0 );
2097 if (!SWIG_IsOK(res1)) {
2098 SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "find_result_t_partnum_get" "', argument " "1"" of type '" "find_result_t *""'");
2100 arg1 = (find_result_t *)(argp1);
2101 result = (char *) ((arg1)->partnum);
2102 ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ;
2112 XS(_wrap_new_find_result_t) {
2114 find_result_t *result = 0 ;
2118 if ((items < 0) || (items > 0)) {
2119 SWIG_croak("Usage: new_find_result_t();");
2121 result = (find_result_t *)(find_result_t *) calloc(1, sizeof(find_result_t));
2122 ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_find_result_t, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
2130 XS(_wrap_find_log) {
2136 if ((items < 0) || (items > 0)) {
2137 SWIG_croak("Usage: find_log();");
2139 result = (char **)find_log();
2144 /* measure the length of the array and make sure perl has enough room */
2145 for (len=0, iter=result; *iter; iter++) len++;
2148 /* now copy it to the perl stack */
2149 for (i=0, iter=result; *iter; iter++, i++) {
2150 ST(argvi) = sv_2mortal(newSVpv(*iter, 0));
2161 XS(_wrap_search_logfile) {
2163 char *arg1 = (char *) 0 ;
2164 char *arg2 = (char *) 0 ;
2165 char *arg3 = (char *) 0 ;
2167 find_result_t *result = 0 ;
2180 if ((items < 4) || (items > 4)) {
2181 SWIG_croak("Usage: search_logfile(label,datestamp,logfile,add_missing_disks);");
2183 res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1);
2184 if (!SWIG_IsOK(res1)) {
2185 SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "search_logfile" "', argument " "1"" of type '" "char *""'");
2187 arg1 = (char *)(buf1);
2188 res2 = SWIG_AsCharPtrAndSize(ST(1), &buf2, NULL, &alloc2);
2189 if (!SWIG_IsOK(res2)) {
2190 SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "search_logfile" "', argument " "2"" of type '" "char *""'");
2192 arg2 = (char *)(buf2);
2193 res3 = SWIG_AsCharPtrAndSize(ST(2), &buf3, NULL, &alloc3);
2194 if (!SWIG_IsOK(res3)) {
2195 SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "search_logfile" "', argument " "3"" of type '" "char *""'");
2197 arg3 = (char *)(buf3);
2199 if (sizeof(signed int) == 1) {
2200 arg4 = amglue_SvI8(ST(3));
2201 } else if (sizeof(signed int) == 2) {
2202 arg4 = amglue_SvI16(ST(3));
2203 } else if (sizeof(signed int) == 4) {
2204 arg4 = amglue_SvI32(ST(3));
2205 } else if (sizeof(signed int) == 8) {
2206 arg4 = amglue_SvI64(ST(3));
2208 g_critical("Unexpected signed int >64 bits?"); /* should be optimized out unless sizeof(signed int) > 8 */
2211 result = (find_result_t *)search_logfile_wrap(arg1,arg2,arg3,arg4);
2213 find_result_t *iter;
2216 /* measure the list and make room on the perl stack */
2217 for (len=0, iter=result; iter; iter=iter->next) len++;
2222 find_result_t *next;
2223 /* Let SWIG take ownership of the object */
2224 ST(argvi) = SWIG_NewPointerObj(iter, SWIGTYPE_p_find_result_t, SWIG_OWNER | SWIG_SHADOW);
2227 /* null out the 'next' field */
2233 if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
2234 if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
2235 if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
2239 if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
2240 if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
2241 if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
2248 XS(_wrap_dumps_match) {
2250 find_result_t *arg1 = (find_result_t *) 0 ;
2251 char *arg2 = (char *) 0 ;
2252 char *arg3 = (char *) 0 ;
2253 char *arg4 = (char *) 0 ;
2254 char *arg5 = (char *) 0 ;
2256 find_result_t *result = 0 ;
2272 if ((items < 6) || (items > 6)) {
2273 SWIG_croak("Usage: dumps_match(output_find,hostname,diskname,datestamp,level,ok);");
2278 find_result_t *head = NULL, *tail = NULL;
2280 if (!SvROK(ST(0)) || SvTYPE(SvRV(ST(0))) != SVt_PVAV) {
2281 SWIG_exception(SWIG_TypeError, "expected an arrayref of find_result_t's");
2284 av = (AV *)SvRV(ST(0));
2285 len = av_len(av) + 1;
2287 for (i = 0; i < len; i++) {
2288 SV **val = av_fetch(av, i, 0);
2291 if (!val || SWIG_ConvertPtr(*val, (void **)&r, SWIGTYPE_p_find_result_t, 0) == -1) {
2292 SWIG_exception(SWIG_TypeError, "array member is not a find_result_t");
2305 /* point to the head of that list */
2308 res2 = SWIG_AsCharPtrAndSize(ST(1), &buf2, NULL, &alloc2);
2309 if (!SWIG_IsOK(res2)) {
2310 SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "dumps_match" "', argument " "2"" of type '" "char *""'");
2312 arg2 = (char *)(buf2);
2313 res3 = SWIG_AsCharPtrAndSize(ST(2), &buf3, NULL, &alloc3);
2314 if (!SWIG_IsOK(res3)) {
2315 SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "dumps_match" "', argument " "3"" of type '" "char *""'");
2317 arg3 = (char *)(buf3);
2318 res4 = SWIG_AsCharPtrAndSize(ST(3), &buf4, NULL, &alloc4);
2319 if (!SWIG_IsOK(res4)) {
2320 SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "dumps_match" "', argument " "4"" of type '" "char *""'");
2322 arg4 = (char *)(buf4);
2323 res5 = SWIG_AsCharPtrAndSize(ST(4), &buf5, NULL, &alloc5);
2324 if (!SWIG_IsOK(res5)) {
2325 SWIG_exception_fail(SWIG_ArgError(res5), "in method '" "dumps_match" "', argument " "5"" of type '" "char *""'");
2327 arg5 = (char *)(buf5);
2329 if (sizeof(signed int) == 1) {
2330 arg6 = amglue_SvI8(ST(5));
2331 } else if (sizeof(signed int) == 2) {
2332 arg6 = amglue_SvI16(ST(5));
2333 } else if (sizeof(signed int) == 4) {
2334 arg6 = amglue_SvI32(ST(5));
2335 } else if (sizeof(signed int) == 8) {
2336 arg6 = amglue_SvI64(ST(5));
2338 g_critical("Unexpected signed int >64 bits?"); /* should be optimized out unless sizeof(signed int) > 8 */
2341 result = (find_result_t *)dumps_match(arg1,arg2,arg3,arg4,arg5,arg6);
2343 find_result_t *iter;
2346 /* measure the list and make room on the perl stack */
2347 for (len=0, iter=result; iter; iter=iter->next) len++;
2352 find_result_t *next;
2353 /* Let SWIG take ownership of the object */
2354 ST(argvi) = SWIG_NewPointerObj(iter, SWIGTYPE_p_find_result_t, SWIG_OWNER | SWIG_SHADOW);
2357 /* null out the 'next' field */
2364 find_result_t *iter = arg1, *next;
2366 /* undo all the links we added earlier */
2373 if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
2374 if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
2375 if (alloc4 == SWIG_NEWOBJ) free((char*)buf4);
2376 if (alloc5 == SWIG_NEWOBJ) free((char*)buf5);
2381 find_result_t *iter = arg1, *next;
2383 /* undo all the links we added earlier */
2390 if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
2391 if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
2392 if (alloc4 == SWIG_NEWOBJ) free((char*)buf4);
2393 if (alloc5 == SWIG_NEWOBJ) free((char*)buf5);
2401 /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */
2403 static swig_type_info _swigt__p_FILE = {"_p_FILE", "FILE *|loghandle *", 0, 0, (void*)0, 0};
2404 static swig_type_info _swigt__p_char = {"_p_char", "gchar *|char *", 0, 0, (void*)0, 0};
2405 static swig_type_info _swigt__p_double = {"_p_double", "double *|gdouble *", 0, 0, (void*)0, 0};
2406 static swig_type_info _swigt__p_find_result_t = {"_p_find_result_t", "find_result_t *", 0, 0, (void*)"Amanda::Logfile::find_result_t", 0};
2407 static swig_type_info _swigt__p_float = {"_p_float", "float *|gfloat *", 0, 0, (void*)0, 0};
2408 static swig_type_info _swigt__p_int = {"_p_int", "int *|logtype_t *|program_t *|gboolean *", 0, 0, (void*)0, 0};
2409 static swig_type_info _swigt__p_unsigned_char = {"_p_unsigned_char", "guchar *|unsigned char *", 0, 0, (void*)0, 0};
2411 static swig_type_info *swig_type_initial[] = {
2415 &_swigt__p_find_result_t,
2418 &_swigt__p_unsigned_char,
2421 static swig_cast_info _swigc__p_FILE[] = { {&_swigt__p_FILE, 0, 0, 0},{0, 0, 0, 0}};
2422 static swig_cast_info _swigc__p_char[] = { {&_swigt__p_char, 0, 0, 0},{0, 0, 0, 0}};
2423 static swig_cast_info _swigc__p_double[] = { {&_swigt__p_double, 0, 0, 0},{0, 0, 0, 0}};
2424 static swig_cast_info _swigc__p_find_result_t[] = { {&_swigt__p_find_result_t, 0, 0, 0},{0, 0, 0, 0}};
2425 static swig_cast_info _swigc__p_float[] = { {&_swigt__p_float, 0, 0, 0},{0, 0, 0, 0}};
2426 static swig_cast_info _swigc__p_int[] = { {&_swigt__p_int, 0, 0, 0},{0, 0, 0, 0}};
2427 static swig_cast_info _swigc__p_unsigned_char[] = { {&_swigt__p_unsigned_char, 0, 0, 0},{0, 0, 0, 0}};
2429 static swig_cast_info *swig_cast_initial[] = {
2433 _swigc__p_find_result_t,
2436 _swigc__p_unsigned_char,
2440 /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (END) -------- */
2442 static swig_constant_info swig_constants[] = {
2448 static swig_variable_info swig_variables[] = {
2451 static swig_command_info swig_commands[] = {
2452 {"Amanda::Logfilec::open_logfile", _wrap_open_logfile},
2453 {"Amanda::Logfilec::close_logfile", _wrap_close_logfile},
2454 {"Amanda::Logfilec::get_logline", _wrap_get_logline},
2455 {"Amanda::Logfilec::delete_find_result_t", _wrap_delete_find_result_t},
2456 {"Amanda::Logfilec::find_result_t_timestamp_get", _wrap_find_result_t_timestamp_get},
2457 {"Amanda::Logfilec::find_result_t_hostname_get", _wrap_find_result_t_hostname_get},
2458 {"Amanda::Logfilec::find_result_t_diskname_get", _wrap_find_result_t_diskname_get},
2459 {"Amanda::Logfilec::find_result_t_level_get", _wrap_find_result_t_level_get},
2460 {"Amanda::Logfilec::find_result_t_label_get", _wrap_find_result_t_label_get},
2461 {"Amanda::Logfilec::find_result_t_filenum_get", _wrap_find_result_t_filenum_get},
2462 {"Amanda::Logfilec::find_result_t_status_get", _wrap_find_result_t_status_get},
2463 {"Amanda::Logfilec::find_result_t_partnum_get", _wrap_find_result_t_partnum_get},
2464 {"Amanda::Logfilec::new_find_result_t", _wrap_new_find_result_t},
2465 {"Amanda::Logfilec::find_log", _wrap_find_log},
2466 {"Amanda::Logfilec::search_logfile", _wrap_search_logfile},
2467 {"Amanda::Logfilec::dumps_match", _wrap_dumps_match},
2470 /* -----------------------------------------------------------------------------
2471 * Type initialization:
2472 * This problem is tough by the requirement that no dynamic
2473 * memory is used. Also, since swig_type_info structures store pointers to
2474 * swig_cast_info structures and swig_cast_info structures store pointers back
2475 * to swig_type_info structures, we need some lookup code at initialization.
2476 * The idea is that swig generates all the structures that are needed.
2477 * The runtime then collects these partially filled structures.
2478 * The SWIG_InitializeModule function takes these initial arrays out of
2479 * swig_module, and does all the lookup, filling in the swig_module.types
2480 * array with the correct data and linking the correct swig_cast_info
2481 * structures together.
2483 * The generated swig_type_info structures are assigned staticly to an initial
2484 * array. We just loop through that array, and handle each type individually.
2485 * First we lookup if this type has been already loaded, and if so, use the
2486 * loaded structure instead of the generated one. Then we have to fill in the
2487 * cast linked list. The cast data is initially stored in something like a
2488 * two-dimensional array. Each row corresponds to a type (there are the same
2489 * number of rows as there are in the swig_type_initial array). Each entry in
2490 * a column is one of the swig_cast_info structures for that type.
2491 * The cast_initial array is actually an array of arrays, because each row has
2492 * a variable number of columns. So to actually build the cast linked list,
2493 * we find the array of casts associated with the type, and loop through it
2494 * adding the casts to the list. The one last trick we need to do is making
2495 * sure the type pointer in the swig_cast_info struct is correct.
2497 * First off, we lookup the cast->type name to see if it is already loaded.
2498 * There are three cases to handle:
2499 * 1) If the cast->type has already been loaded AND the type we are adding
2500 * casting info to has not been loaded (it is in this module), THEN we
2501 * replace the cast->type pointer with the type pointer that has already
2503 * 2) If BOTH types (the one we are adding casting info to, and the
2504 * cast->type) are loaded, THEN the cast info has already been loaded by
2505 * the previous module so we just ignore it.
2506 * 3) Finally, if cast->type has not already been loaded, then we add that
2507 * swig_cast_info to the linked list (because the cast->type) pointer will
2509 * ----------------------------------------------------------------------------- */
2519 #define SWIGRUNTIME_DEBUG
2524 SWIG_InitializeModule(void *clientdata) {
2526 swig_module_info *module_head, *iter;
2529 clientdata = clientdata;
2531 /* check to see if the circular list has been setup, if not, set it up */
2532 if (swig_module.next==0) {
2533 /* Initialize the swig_module */
2534 swig_module.type_initial = swig_type_initial;
2535 swig_module.cast_initial = swig_cast_initial;
2536 swig_module.next = &swig_module;
2539 /* Try and load any already created modules */
2540 module_head = SWIG_GetModule(clientdata);
2542 /* This is the first module loaded for this interpreter */
2543 /* so set the swig module into the interpreter */
2544 SWIG_SetModule(clientdata, &swig_module);
2545 module_head = &swig_module;
2547 /* the interpreter has loaded a SWIG module, but has it loaded this one? */
2551 if (iter==&swig_module) {
2556 } while (iter!= module_head);
2558 /* if the is found in the list, then all is done and we may leave */
2560 /* otherwise we must add out module into the list */
2561 swig_module.next = module_head->next;
2562 module_head->next = &swig_module;
2565 /* Now work on filling in swig_module.types */
2566 #ifdef SWIGRUNTIME_DEBUG
2567 printf("SWIG_InitializeModule: size %d\n", swig_module.size);
2569 for (i = 0; i < swig_module.size; ++i) {
2570 swig_type_info *type = 0;
2571 swig_type_info *ret;
2572 swig_cast_info *cast;
2574 #ifdef SWIGRUNTIME_DEBUG
2575 printf("SWIG_InitializeModule: type %d %s\n", i, swig_module.type_initial[i]->name);
2578 /* if there is another module already loaded */
2579 if (swig_module.next != &swig_module) {
2580 type = SWIG_MangledTypeQueryModule(swig_module.next, &swig_module, swig_module.type_initial[i]->name);
2583 /* Overwrite clientdata field */
2584 #ifdef SWIGRUNTIME_DEBUG
2585 printf("SWIG_InitializeModule: found type %s\n", type->name);
2587 if (swig_module.type_initial[i]->clientdata) {
2588 type->clientdata = swig_module.type_initial[i]->clientdata;
2589 #ifdef SWIGRUNTIME_DEBUG
2590 printf("SWIG_InitializeModule: found and overwrite type %s \n", type->name);
2594 type = swig_module.type_initial[i];
2597 /* Insert casting types */
2598 cast = swig_module.cast_initial[i];
2599 while (cast->type) {
2600 /* Don't need to add information already in the list */
2602 #ifdef SWIGRUNTIME_DEBUG
2603 printf("SWIG_InitializeModule: look cast %s\n", cast->type->name);
2605 if (swig_module.next != &swig_module) {
2606 ret = SWIG_MangledTypeQueryModule(swig_module.next, &swig_module, cast->type->name);
2607 #ifdef SWIGRUNTIME_DEBUG
2608 if (ret) printf("SWIG_InitializeModule: found cast %s\n", ret->name);
2612 if (type == swig_module.type_initial[i]) {
2613 #ifdef SWIGRUNTIME_DEBUG
2614 printf("SWIG_InitializeModule: skip old type %s\n", ret->name);
2619 /* Check for casting already in the list */
2620 swig_cast_info *ocast = SWIG_TypeCheck(ret->name, type);
2621 #ifdef SWIGRUNTIME_DEBUG
2622 if (ocast) printf("SWIG_InitializeModule: skip old cast %s\n", ret->name);
2624 if (!ocast) ret = 0;
2629 #ifdef SWIGRUNTIME_DEBUG
2630 printf("SWIG_InitializeModule: adding cast %s\n", cast->type->name);
2633 type->cast->prev = cast;
2634 cast->next = type->cast;
2640 /* Set entry in modules->types array equal to the type */
2641 swig_module.types[i] = type;
2643 swig_module.types[i] = 0;
2645 #ifdef SWIGRUNTIME_DEBUG
2646 printf("**** SWIG_InitializeModule: Cast List ******\n");
2647 for (i = 0; i < swig_module.size; ++i) {
2649 swig_cast_info *cast = swig_module.cast_initial[i];
2650 printf("SWIG_InitializeModule: type %d %s\n", i, swig_module.type_initial[i]->name);
2651 while (cast->type) {
2652 printf("SWIG_InitializeModule: cast type %s\n", cast->type->name);
2656 printf("---- Total casts: %d\n",j);
2658 printf("**** SWIG_InitializeModule: Cast List ******\n");
2662 /* This function will propagate the clientdata field of type to
2663 * any new swig_type_info structures that have been added into the list
2664 * of equivalent types. It is like calling
2665 * SWIG_TypeClientData(type, clientdata) a second time.
2668 SWIG_PropagateClientData(void) {
2670 swig_cast_info *equiv;
2671 static int init_run = 0;
2673 if (init_run) return;
2676 for (i = 0; i < swig_module.size; i++) {
2677 if (swig_module.types[i]->clientdata) {
2678 equiv = swig_module.types[i]->cast;
2680 if (!equiv->converter) {
2681 if (equiv->type && !equiv->type->clientdata)
2682 SWIG_TypeClientData(equiv->type, swig_module.types[i]->clientdata);
2684 equiv = equiv->next;
2708 SWIG_InitializeModule(0);
2710 /* Install commands */
2711 for (i = 0; swig_commands[i].name; i++) {
2712 newXS((char*) swig_commands[i].name,swig_commands[i].wrapper, (char*)__FILE__);
2715 /* Install variables */
2716 for (i = 0; swig_variables[i].name; i++) {
2718 sv = get_sv((char*) swig_variables[i].name, TRUE | 0x2);
2719 if (swig_variables[i].type) {
2720 SWIG_MakePtr(sv,(void *)1, *swig_variables[i].type,0);
2722 sv_setiv(sv,(IV) 0);
2724 swig_create_magic(sv, (char *) swig_variables[i].name, swig_variables[i].set, swig_variables[i].get);
2727 /* Install constant */
2728 for (i = 0; swig_constants[i].type; i++) {
2730 sv = get_sv((char*)swig_constants[i].name, TRUE | 0x2);
2731 switch(swig_constants[i].type) {
2733 sv_setiv(sv, (IV) swig_constants[i].lvalue);
2736 sv_setnv(sv, (double) swig_constants[i].dvalue);
2739 sv_setpv(sv, (char *) swig_constants[i].pvalue);
2742 SWIG_MakePtr(sv, swig_constants[i].pvalue, *(swig_constants[i].ptype),0);
2745 SWIG_MakePackedObj(sv, swig_constants[i].pvalue, swig_constants[i].lvalue, *(swig_constants[i].ptype));
2753 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2754 SV *sv = get_sv((char*) SWIG_prefix "L_BOGUS", TRUE | 0x2);
2755 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_BOGUS)));
2757 } while(0) /*@SWIG@*/;
2758 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2759 SV *sv = get_sv((char*) SWIG_prefix "L_FATAL", TRUE | 0x2);
2760 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_FATAL)));
2762 } while(0) /*@SWIG@*/;
2763 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2764 SV *sv = get_sv((char*) SWIG_prefix "L_ERROR", TRUE | 0x2);
2765 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_ERROR)));
2767 } while(0) /*@SWIG@*/;
2768 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2769 SV *sv = get_sv((char*) SWIG_prefix "L_WARNING", TRUE | 0x2);
2770 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_WARNING)));
2772 } while(0) /*@SWIG@*/;
2773 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2774 SV *sv = get_sv((char*) SWIG_prefix "L_INFO", TRUE | 0x2);
2775 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_INFO)));
2777 } while(0) /*@SWIG@*/;
2778 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2779 SV *sv = get_sv((char*) SWIG_prefix "L_SUMMARY", TRUE | 0x2);
2780 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_SUMMARY)));
2782 } while(0) /*@SWIG@*/;
2783 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2784 SV *sv = get_sv((char*) SWIG_prefix "L_START", TRUE | 0x2);
2785 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_START)));
2787 } while(0) /*@SWIG@*/;
2788 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2789 SV *sv = get_sv((char*) SWIG_prefix "L_FINISH", TRUE | 0x2);
2790 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_FINISH)));
2792 } while(0) /*@SWIG@*/;
2793 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2794 SV *sv = get_sv((char*) SWIG_prefix "L_DISK", TRUE | 0x2);
2795 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_DISK)));
2797 } while(0) /*@SWIG@*/;
2798 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2799 SV *sv = get_sv((char*) SWIG_prefix "L_DONE", TRUE | 0x2);
2800 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_DONE)));
2802 } while(0) /*@SWIG@*/;
2803 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2804 SV *sv = get_sv((char*) SWIG_prefix "L_PART", TRUE | 0x2);
2805 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_PART)));
2807 } while(0) /*@SWIG@*/;
2808 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2809 SV *sv = get_sv((char*) SWIG_prefix "L_PARTPARTIAL", TRUE | 0x2);
2810 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_PARTPARTIAL)));
2812 } while(0) /*@SWIG@*/;
2813 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2814 SV *sv = get_sv((char*) SWIG_prefix "L_SUCCESS", TRUE | 0x2);
2815 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_SUCCESS)));
2817 } while(0) /*@SWIG@*/;
2818 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2819 SV *sv = get_sv((char*) SWIG_prefix "L_PARTIAL", TRUE | 0x2);
2820 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_PARTIAL)));
2822 } while(0) /*@SWIG@*/;
2823 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2824 SV *sv = get_sv((char*) SWIG_prefix "L_FAIL", TRUE | 0x2);
2825 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_FAIL)));
2827 } while(0) /*@SWIG@*/;
2828 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2829 SV *sv = get_sv((char*) SWIG_prefix "L_STRANGE", TRUE | 0x2);
2830 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_STRANGE)));
2832 } while(0) /*@SWIG@*/;
2833 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2834 SV *sv = get_sv((char*) SWIG_prefix "L_CHUNK", TRUE | 0x2);
2835 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_CHUNK)));
2837 } while(0) /*@SWIG@*/;
2838 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2839 SV *sv = get_sv((char*) SWIG_prefix "L_CHUNKSUCCESS", TRUE | 0x2);
2840 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_CHUNKSUCCESS)));
2842 } while(0) /*@SWIG@*/;
2843 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2844 SV *sv = get_sv((char*) SWIG_prefix "L_STATS", TRUE | 0x2);
2845 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_STATS)));
2847 } while(0) /*@SWIG@*/;
2848 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2849 SV *sv = get_sv((char*) SWIG_prefix "L_MARKER", TRUE | 0x2);
2850 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_MARKER)));
2852 } while(0) /*@SWIG@*/;
2853 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2854 SV *sv = get_sv((char*) SWIG_prefix "L_CONT", TRUE | 0x2);
2855 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_CONT)));
2857 } while(0) /*@SWIG@*/;
2858 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2859 SV *sv = get_sv((char*) SWIG_prefix "P_UNKNOWN", TRUE | 0x2);
2860 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_UNKNOWN)));
2862 } while(0) /*@SWIG@*/;
2863 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2864 SV *sv = get_sv((char*) SWIG_prefix "P_PLANNER", TRUE | 0x2);
2865 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_PLANNER)));
2867 } while(0) /*@SWIG@*/;
2868 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2869 SV *sv = get_sv((char*) SWIG_prefix "P_DRIVER", TRUE | 0x2);
2870 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_DRIVER)));
2872 } while(0) /*@SWIG@*/;
2873 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2874 SV *sv = get_sv((char*) SWIG_prefix "P_REPORTER", TRUE | 0x2);
2875 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_REPORTER)));
2877 } while(0) /*@SWIG@*/;
2878 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2879 SV *sv = get_sv((char*) SWIG_prefix "P_DUMPER", TRUE | 0x2);
2880 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_DUMPER)));
2882 } while(0) /*@SWIG@*/;
2883 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2884 SV *sv = get_sv((char*) SWIG_prefix "P_CHUNKER", TRUE | 0x2);
2885 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_CHUNKER)));
2887 } while(0) /*@SWIG@*/;
2888 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2889 SV *sv = get_sv((char*) SWIG_prefix "P_TAPER", TRUE | 0x2);
2890 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_TAPER)));
2892 } while(0) /*@SWIG@*/;
2893 /*@SWIG:/usr/share/swig/1.3.33/perl5/perltypemaps.swg,64,%set_constant@*/ do {
2894 SV *sv = get_sv((char*) SWIG_prefix "P_AMFLUSH", TRUE | 0x2);
2895 sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_AMFLUSH)));
2897 } while(0) /*@SWIG@*/;
2898 SWIG_TypeClientData(SWIGTYPE_p_find_result_t, (void*) "Amanda::Logfile::find_result_t");