Points&Forces (core)
Software tools facilitating the task of surveying architecture
a_unit_libTCL8_wrap.cxx
Go to the documentation of this file.
1 /* ----------------------------------------------------------------------------
2  * This file was automatically generated by SWIG (http://www.swig.org).
3  * Version 4.0.2
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 SWIGTCL
13 #define SWIGTCL
14 #endif
15 
16 
17 #ifdef __cplusplus
18 /* SwigValueWrapper is described in swig.swg */
19 template<typename T> class SwigValueWrapper {
20  struct SwigMovePointer {
21  T *ptr;
22  SwigMovePointer(T *p) : ptr(p) { }
23  ~SwigMovePointer() { delete ptr; }
24  SwigMovePointer& operator=(SwigMovePointer& rhs) { T* oldptr = ptr; ptr = 0; delete oldptr; ptr = rhs.ptr; rhs.ptr = 0; return *this; }
25  } pointer;
26  SwigValueWrapper& operator=(const SwigValueWrapper<T>& rhs);
27  SwigValueWrapper(const SwigValueWrapper<T>& rhs);
28 public:
29  SwigValueWrapper() : pointer(0) { }
30  SwigValueWrapper& operator=(const T& t) { SwigMovePointer tmp(new T(t)); pointer = tmp; return *this; }
31  operator T&() const { return *pointer.ptr; }
32  T *operator&() { return pointer.ptr; }
33 };
34 
35 template <typename T> T SwigValueInit() {
36  return T();
37 }
38 #endif
39 
40 /* -----------------------------------------------------------------------------
41  * This section contains generic SWIG labels for method/variable
42  * declarations/attributes, and other compiler dependent labels.
43  * ----------------------------------------------------------------------------- */
44 
45 /* template workaround for compilers that cannot correctly implement the C++ standard */
46 #ifndef SWIGTEMPLATEDISAMBIGUATOR
47 # if defined(__SUNPRO_CC) && (__SUNPRO_CC <= 0x560)
48 # define SWIGTEMPLATEDISAMBIGUATOR template
49 # elif defined(__HP_aCC)
50 /* Needed even with `aCC -AA' when `aCC -V' reports HP ANSI C++ B3910B A.03.55 */
51 /* If we find a maximum version that requires this, the test would be __HP_aCC <= 35500 for A.03.55 */
52 # define SWIGTEMPLATEDISAMBIGUATOR template
53 # else
54 # define SWIGTEMPLATEDISAMBIGUATOR
55 # endif
56 #endif
57 
58 /* inline attribute */
59 #ifndef SWIGINLINE
60 # if defined(__cplusplus) || (defined(__GNUC__) && !defined(__STRICT_ANSI__))
61 # define SWIGINLINE inline
62 # else
63 # define SWIGINLINE
64 # endif
65 #endif
66 
67 /* attribute recognised by some compilers to avoid 'unused' warnings */
68 #ifndef SWIGUNUSED
69 # if defined(__GNUC__)
70 # if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
71 # define SWIGUNUSED __attribute__ ((__unused__))
72 # else
73 # define SWIGUNUSED
74 # endif
75 # elif defined(__ICC)
76 # define SWIGUNUSED __attribute__ ((__unused__))
77 # else
78 # define SWIGUNUSED
79 # endif
80 #endif
81 
82 #ifndef SWIG_MSC_UNSUPPRESS_4505
83 # if defined(_MSC_VER)
84 # pragma warning(disable : 4505) /* unreferenced local function has been removed */
85 # endif
86 #endif
87 
88 #ifndef SWIGUNUSEDPARM
89 # ifdef __cplusplus
90 # define SWIGUNUSEDPARM(p)
91 # else
92 # define SWIGUNUSEDPARM(p) p SWIGUNUSED
93 # endif
94 #endif
95 
96 /* internal SWIG method */
97 #ifndef SWIGINTERN
98 # define SWIGINTERN static SWIGUNUSED
99 #endif
100 
101 /* internal inline SWIG method */
102 #ifndef SWIGINTERNINLINE
103 # define SWIGINTERNINLINE SWIGINTERN SWIGINLINE
104 #endif
105 
106 /* exporting methods */
107 #if defined(__GNUC__)
108 # if (__GNUC__ >= 4) || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)
109 # ifndef GCC_HASCLASSVISIBILITY
110 # define GCC_HASCLASSVISIBILITY
111 # endif
112 # endif
113 #endif
114 
115 #ifndef SWIGEXPORT
116 # if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
117 # if defined(STATIC_LINKED)
118 # define SWIGEXPORT
119 # else
120 # define SWIGEXPORT __declspec(dllexport)
121 # endif
122 # else
123 # if defined(__GNUC__) && defined(GCC_HASCLASSVISIBILITY)
124 # define SWIGEXPORT __attribute__ ((visibility("default")))
125 # else
126 # define SWIGEXPORT
127 # endif
128 # endif
129 #endif
130 
131 /* calling conventions for Windows */
132 #ifndef SWIGSTDCALL
133 # if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
134 # define SWIGSTDCALL __stdcall
135 # else
136 # define SWIGSTDCALL
137 # endif
138 #endif
139 
140 /* Deal with Microsoft's attempt at deprecating C standard runtime functions */
141 #if !defined(SWIG_NO_CRT_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_CRT_SECURE_NO_DEPRECATE)
142 # define _CRT_SECURE_NO_DEPRECATE
143 #endif
144 
145 /* Deal with Microsoft's attempt at deprecating methods in the standard C++ library */
146 #if !defined(SWIG_NO_SCL_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_SCL_SECURE_NO_DEPRECATE)
147 # define _SCL_SECURE_NO_DEPRECATE
148 #endif
149 
150 /* Deal with Apple's deprecated 'AssertMacros.h' from Carbon-framework */
151 #if defined(__APPLE__) && !defined(__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES)
152 # define __ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES 0
153 #endif
154 
155 /* Intel's compiler complains if a variable which was never initialised is
156  * cast to void, which is a common idiom which we use to indicate that we
157  * are aware a variable isn't used. So we just silence that warning.
158  * See: https://github.com/swig/swig/issues/192 for more discussion.
159  */
160 #ifdef __INTEL_COMPILER
161 # pragma warning disable 592
162 #endif
163 
164 
165 #include <stdio.h>
166 #include <tcl.h>
167 #include <errno.h>
168 #include <stdlib.h>
169 #include <stdarg.h>
170 #include <ctype.h>
171 
172 /* -----------------------------------------------------------------------------
173  * swigrun.swg
174  *
175  * This file contains generic C API SWIG runtime support for pointer
176  * type checking.
177  * ----------------------------------------------------------------------------- */
178 
179 /* This should only be incremented when either the layout of swig_type_info changes,
180  or for whatever reason, the runtime changes incompatibly */
181 #define SWIG_RUNTIME_VERSION "4"
182 
183 /* define SWIG_TYPE_TABLE_NAME as "SWIG_TYPE_TABLE" */
184 #ifdef SWIG_TYPE_TABLE
185 # define SWIG_QUOTE_STRING(x) #x
186 # define SWIG_EXPAND_AND_QUOTE_STRING(x) SWIG_QUOTE_STRING(x)
187 # define SWIG_TYPE_TABLE_NAME SWIG_EXPAND_AND_QUOTE_STRING(SWIG_TYPE_TABLE)
188 #else
189 # define SWIG_TYPE_TABLE_NAME
190 #endif
191 
192 /*
193  You can use the SWIGRUNTIME and SWIGRUNTIMEINLINE macros for
194  creating a static or dynamic library from the SWIG runtime code.
195  In 99.9% of the cases, SWIG just needs to declare them as 'static'.
196 
197  But only do this if strictly necessary, ie, if you have problems
198  with your compiler or suchlike.
199 */
200 
201 #ifndef SWIGRUNTIME
202 # define SWIGRUNTIME SWIGINTERN
203 #endif
204 
205 #ifndef SWIGRUNTIMEINLINE
206 # define SWIGRUNTIMEINLINE SWIGRUNTIME SWIGINLINE
207 #endif
208 
209 /* Generic buffer size */
210 #ifndef SWIG_BUFFER_SIZE
211 # define SWIG_BUFFER_SIZE 1024
212 #endif
213 
214 /* Flags for pointer conversions */
215 #define SWIG_POINTER_DISOWN 0x1
216 #define SWIG_CAST_NEW_MEMORY 0x2
217 #define SWIG_POINTER_NO_NULL 0x4
218 
219 /* Flags for new pointer objects */
220 #define SWIG_POINTER_OWN 0x1
221 
222 
223 /*
224  Flags/methods for returning states.
225 
226  The SWIG conversion methods, as ConvertPtr, return an integer
227  that tells if the conversion was successful or not. And if not,
228  an error code can be returned (see swigerrors.swg for the codes).
229 
230  Use the following macros/flags to set or process the returning
231  states.
232 
233  In old versions of SWIG, code such as the following was usually written:
234 
235  if (SWIG_ConvertPtr(obj,vptr,ty.flags) != -1) {
236  // success code
237  } else {
238  //fail code
239  }
240 
241  Now you can be more explicit:
242 
243  int res = SWIG_ConvertPtr(obj,vptr,ty.flags);
244  if (SWIG_IsOK(res)) {
245  // success code
246  } else {
247  // fail code
248  }
249 
250  which is the same really, but now you can also do
251 
252  Type *ptr;
253  int res = SWIG_ConvertPtr(obj,(void **)(&ptr),ty.flags);
254  if (SWIG_IsOK(res)) {
255  // success code
256  if (SWIG_IsNewObj(res) {
257  ...
258  delete *ptr;
259  } else {
260  ...
261  }
262  } else {
263  // fail code
264  }
265 
266  I.e., now SWIG_ConvertPtr can return new objects and you can
267  identify the case and take care of the deallocation. Of course that
268  also requires SWIG_ConvertPtr to return new result values, such as
269 
270  int SWIG_ConvertPtr(obj, ptr,...) {
271  if (<obj is ok>) {
272  if (<need new object>) {
273  *ptr = <ptr to new allocated object>;
274  return SWIG_NEWOBJ;
275  } else {
276  *ptr = <ptr to old object>;
277  return SWIG_OLDOBJ;
278  }
279  } else {
280  return SWIG_BADOBJ;
281  }
282  }
283 
284  Of course, returning the plain '0(success)/-1(fail)' still works, but you can be
285  more explicit by returning SWIG_BADOBJ, SWIG_ERROR or any of the
286  SWIG errors code.
287 
288  Finally, if the SWIG_CASTRANK_MODE is enabled, the result code
289  allows to return the 'cast rank', for example, if you have this
290 
291  int food(double)
292  int fooi(int);
293 
294  and you call
295 
296  food(1) // cast rank '1' (1 -> 1.0)
297  fooi(1) // cast rank '0'
298 
299  just use the SWIG_AddCast()/SWIG_CheckState()
300 */
301 
302 #define SWIG_OK (0)
303 #define SWIG_ERROR (-1)
304 #define SWIG_IsOK(r) (r >= 0)
305 #define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
306 
307 /* The CastRankLimit says how many bits are used for the cast rank */
308 #define SWIG_CASTRANKLIMIT (1 << 8)
309 /* The NewMask denotes the object was created (using new/malloc) */
310 #define SWIG_NEWOBJMASK (SWIG_CASTRANKLIMIT << 1)
311 /* The TmpMask is for in/out typemaps that use temporal objects */
312 #define SWIG_TMPOBJMASK (SWIG_NEWOBJMASK << 1)
313 /* Simple returning values */
314 #define SWIG_BADOBJ (SWIG_ERROR)
315 #define SWIG_OLDOBJ (SWIG_OK)
316 #define SWIG_NEWOBJ (SWIG_OK | SWIG_NEWOBJMASK)
317 #define SWIG_TMPOBJ (SWIG_OK | SWIG_TMPOBJMASK)
318 /* Check, add and del mask methods */
319 #define SWIG_AddNewMask(r) (SWIG_IsOK(r) ? (r | SWIG_NEWOBJMASK) : r)
320 #define SWIG_DelNewMask(r) (SWIG_IsOK(r) ? (r & ~SWIG_NEWOBJMASK) : r)
321 #define SWIG_IsNewObj(r) (SWIG_IsOK(r) && (r & SWIG_NEWOBJMASK))
322 #define SWIG_AddTmpMask(r) (SWIG_IsOK(r) ? (r | SWIG_TMPOBJMASK) : r)
323 #define SWIG_DelTmpMask(r) (SWIG_IsOK(r) ? (r & ~SWIG_TMPOBJMASK) : r)
324 #define SWIG_IsTmpObj(r) (SWIG_IsOK(r) && (r & SWIG_TMPOBJMASK))
325 
326 /* Cast-Rank Mode */
327 #if defined(SWIG_CASTRANK_MODE)
328 # ifndef SWIG_TypeRank
329 # define SWIG_TypeRank unsigned long
330 # endif
331 # ifndef SWIG_MAXCASTRANK /* Default cast allowed */
332 # define SWIG_MAXCASTRANK (2)
333 # endif
334 # define SWIG_CASTRANKMASK ((SWIG_CASTRANKLIMIT) -1)
335 # define SWIG_CastRank(r) (r & SWIG_CASTRANKMASK)
336 SWIGINTERNINLINE int SWIG_AddCast(int r) {
337  return SWIG_IsOK(r) ? ((SWIG_CastRank(r) < SWIG_MAXCASTRANK) ? (r + 1) : SWIG_ERROR) : r;
338 }
340  return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
341 }
342 #else /* no cast-rank mode */
343 # define SWIG_AddCast(r) (r)
344 # define SWIG_CheckState(r) (SWIG_IsOK(r) ? 1 : 0)
345 #endif
346 
347 
348 #include <string.h>
349 
350 #ifdef __cplusplus
351 extern "C" {
352 #endif
353 
354 typedef void *(*swig_converter_func)(void *, int *);
355 typedef struct swig_type_info *(*swig_dycast_func)(void **);
356 
357 /* Structure to store information on one type */
358 typedef struct swig_type_info {
359  const char *name; /* mangled name of this type */
360  const char *str; /* human readable name of this type */
361  swig_dycast_func dcast; /* dynamic cast function down a hierarchy */
362  struct swig_cast_info *cast; /* linked list of types that can cast into this type */
363  void *clientdata; /* language specific type data */
364  int owndata; /* flag if the structure owns the clientdata */
366 
367 /* Structure to store a type and conversion function used for casting */
368 typedef struct swig_cast_info {
369  swig_type_info *type; /* pointer to type that is equivalent to this type */
370  swig_converter_func converter; /* function to cast the void pointers */
371  struct swig_cast_info *next; /* pointer to next cast in linked list */
372  struct swig_cast_info *prev; /* pointer to the previous cast */
374 
375 /* Structure used to store module information
376  * Each module generates one structure like this, and the runtime collects
377  * all of these structures and stores them in a circularly linked list.*/
378 typedef struct swig_module_info {
379  swig_type_info **types; /* Array of pointers to swig_type_info structures that are in this module */
380  size_t size; /* Number of types in this module */
381  struct swig_module_info *next; /* Pointer to next element in circularly linked list */
382  swig_type_info **type_initial; /* Array of initially generated type structures */
383  swig_cast_info **cast_initial; /* Array of initially generated casting structures */
384  void *clientdata; /* Language specific module data */
386 
387 /*
388  Compare two type names skipping the space characters, therefore
389  "char*" == "char *" and "Class<int>" == "Class<int >", etc.
390 
391  Return 0 when the two name types are equivalent, as in
392  strncmp, but skipping ' '.
393 */
394 SWIGRUNTIME int
395 SWIG_TypeNameComp(const char *f1, const char *l1,
396  const char *f2, const char *l2) {
397  for (;(f1 != l1) && (f2 != l2); ++f1, ++f2) {
398  while ((*f1 == ' ') && (f1 != l1)) ++f1;
399  while ((*f2 == ' ') && (f2 != l2)) ++f2;
400  if (*f1 != *f2) return (*f1 > *f2) ? 1 : -1;
401  }
402  return (int)((l1 - f1) - (l2 - f2));
403 }
404 
405 /*
406  Check type equivalence in a name list like <name1>|<name2>|...
407  Return 0 if equal, -1 if nb < tb, 1 if nb > tb
408 */
409 SWIGRUNTIME int
410 SWIG_TypeCmp(const char *nb, const char *tb) {
411  int equiv = 1;
412  const char* te = tb + strlen(tb);
413  const char* ne = nb;
414  while (equiv != 0 && *ne) {
415  for (nb = ne; *ne; ++ne) {
416  if (*ne == '|') break;
417  }
418  equiv = SWIG_TypeNameComp(nb, ne, tb, te);
419  if (*ne) ++ne;
420  }
421  return equiv;
422 }
423 
424 /*
425  Check type equivalence in a name list like <name1>|<name2>|...
426  Return 0 if not equal, 1 if equal
427 */
428 SWIGRUNTIME int
429 SWIG_TypeEquiv(const char *nb, const char *tb) {
430  return SWIG_TypeCmp(nb, tb) == 0 ? 1 : 0;
431 }
432 
433 /*
434  Check the typename
435 */
437 SWIG_TypeCheck(const char *c, swig_type_info *ty) {
438  if (ty) {
439  swig_cast_info *iter = ty->cast;
440  while (iter) {
441  if (strcmp(iter->type->name, c) == 0) {
442  if (iter == ty->cast)
443  return iter;
444  /* Move iter to the top of the linked list */
445  iter->prev->next = iter->next;
446  if (iter->next)
447  iter->next->prev = iter->prev;
448  iter->next = ty->cast;
449  iter->prev = 0;
450  if (ty->cast) ty->cast->prev = iter;
451  ty->cast = iter;
452  return iter;
453  }
454  iter = iter->next;
455  }
456  }
457  return 0;
458 }
459 
460 /*
461  Identical to SWIG_TypeCheck, except strcmp is replaced with a pointer comparison
462 */
465  if (ty) {
466  swig_cast_info *iter = ty->cast;
467  while (iter) {
468  if (iter->type == from) {
469  if (iter == ty->cast)
470  return iter;
471  /* Move iter to the top of the linked list */
472  iter->prev->next = iter->next;
473  if (iter->next)
474  iter->next->prev = iter->prev;
475  iter->next = ty->cast;
476  iter->prev = 0;
477  if (ty->cast) ty->cast->prev = iter;
478  ty->cast = iter;
479  return iter;
480  }
481  iter = iter->next;
482  }
483  }
484  return 0;
485 }
486 
487 /*
488  Cast a pointer up an inheritance hierarchy
489 */
490 SWIGRUNTIMEINLINE void *
491 SWIG_TypeCast(swig_cast_info *ty, void *ptr, int *newmemory) {
492  return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr, newmemory);
493 }
494 
495 /*
496  Dynamic pointer casting. Down an inheritance hierarchy
497 */
500  swig_type_info *lastty = ty;
501  if (!ty || !ty->dcast) return ty;
502  while (ty && (ty->dcast)) {
503  ty = (*ty->dcast)(ptr);
504  if (ty) lastty = ty;
505  }
506  return lastty;
507 }
508 
509 /*
510  Return the name associated with this type
511 */
512 SWIGRUNTIMEINLINE const char *
514  return ty->name;
515 }
516 
517 /*
518  Return the pretty name associated with this type,
519  that is an unmangled type name in a form presentable to the user.
520 */
521 SWIGRUNTIME const char *
523  /* The "str" field contains the equivalent pretty names of the
524  type, separated by vertical-bar characters. We choose
525  to print the last name, as it is often (?) the most
526  specific. */
527  if (!type) return NULL;
528  if (type->str != NULL) {
529  const char *last_name = type->str;
530  const char *s;
531  for (s = type->str; *s; s++)
532  if (*s == '|') last_name = s+1;
533  return last_name;
534  }
535  else
536  return type->name;
537 }
538 
539 /*
540  Set the clientdata field for a type
541 */
542 SWIGRUNTIME void
544  swig_cast_info *cast = ti->cast;
545  /* if (ti->clientdata == clientdata) return; */
546  ti->clientdata = clientdata;
547 
548  while (cast) {
549  if (!cast->converter) {
550  swig_type_info *tc = cast->type;
551  if (!tc->clientdata) {
553  }
554  }
555  cast = cast->next;
556  }
557 }
558 SWIGRUNTIME void
561  ti->owndata = 1;
562 }
563 
564 /*
565  Search for a swig_type_info structure only by mangled name
566  Search is a O(log #types)
567 
568  We start searching at module start, and finish searching when start == end.
569  Note: if start == end at the beginning of the function, we go all the way around
570  the circular list.
571 */
574  swig_module_info *end,
575  const char *name) {
576  swig_module_info *iter = start;
577  do {
578  if (iter->size) {
579  size_t l = 0;
580  size_t r = iter->size - 1;
581  do {
582  /* since l+r >= 0, we can (>> 1) instead (/ 2) */
583  size_t i = (l + r) >> 1;
584  const char *iname = iter->types[i]->name;
585  if (iname) {
586  int compare = strcmp(name, iname);
587  if (compare == 0) {
588  return iter->types[i];
589  } else if (compare < 0) {
590  if (i) {
591  r = i - 1;
592  } else {
593  break;
594  }
595  } else if (compare > 0) {
596  l = i + 1;
597  }
598  } else {
599  break; /* should never happen */
600  }
601  } while (l <= r);
602  }
603  iter = iter->next;
604  } while (iter != end);
605  return 0;
606 }
607 
608 /*
609  Search for a swig_type_info structure for either a mangled name or a human readable name.
610  It first searches the mangled names of the types, which is a O(log #types)
611  If a type is not found it then searches the human readable names, which is O(#types).
612 
613  We start searching at module start, and finish searching when start == end.
614  Note: if start == end at the beginning of the function, we go all the way around
615  the circular list.
616 */
619  swig_module_info *end,
620  const char *name) {
621  /* STEP 1: Search the name field using binary search */
622  swig_type_info *ret = SWIG_MangledTypeQueryModule(start, end, name);
623  if (ret) {
624  return ret;
625  } else {
626  /* STEP 2: If the type hasn't been found, do a complete search
627  of the str field (the human readable name) */
628  swig_module_info *iter = start;
629  do {
630  size_t i = 0;
631  for (; i < iter->size; ++i) {
632  if (iter->types[i]->str && (SWIG_TypeEquiv(iter->types[i]->str, name)))
633  return iter->types[i];
634  }
635  iter = iter->next;
636  } while (iter != end);
637  }
638 
639  /* neither found a match */
640  return 0;
641 }
642 
643 /*
644  Pack binary data into a string
645 */
646 SWIGRUNTIME char *
647 SWIG_PackData(char *c, void *ptr, size_t sz) {
648  static const char hex[17] = "0123456789abcdef";
649  const unsigned char *u = (unsigned char *) ptr;
650  const unsigned char *eu = u + sz;
651  for (; u != eu; ++u) {
652  unsigned char uu = *u;
653  *(c++) = hex[(uu & 0xf0) >> 4];
654  *(c++) = hex[uu & 0xf];
655  }
656  return c;
657 }
658 
659 /*
660  Unpack binary data from a string
661 */
662 SWIGRUNTIME const char *
663 SWIG_UnpackData(const char *c, void *ptr, size_t sz) {
664  unsigned char *u = (unsigned char *) ptr;
665  const unsigned char *eu = u + sz;
666  for (; u != eu; ++u) {
667  char d = *(c++);
668  unsigned char uu;
669  if ((d >= '0') && (d <= '9'))
670  uu = (unsigned char)((d - '0') << 4);
671  else if ((d >= 'a') && (d <= 'f'))
672  uu = (unsigned char)((d - ('a'-10)) << 4);
673  else
674  return (char *) 0;
675  d = *(c++);
676  if ((d >= '0') && (d <= '9'))
677  uu |= (unsigned char)(d - '0');
678  else if ((d >= 'a') && (d <= 'f'))
679  uu |= (unsigned char)(d - ('a'-10));
680  else
681  return (char *) 0;
682  *u = uu;
683  }
684  return c;
685 }
686 
687 /*
688  Pack 'void *' into a string buffer.
689 */
690 SWIGRUNTIME char *
691 SWIG_PackVoidPtr(char *buff, void *ptr, const char *name, size_t bsz) {
692  char *r = buff;
693  if ((2*sizeof(void *) + 2) > bsz) return 0;
694  *(r++) = '_';
695  r = SWIG_PackData(r,&ptr,sizeof(void *));
696  if (strlen(name) + 1 > (bsz - (r - buff))) return 0;
697  strcpy(r,name);
698  return buff;
699 }
700 
701 SWIGRUNTIME const char *
702 SWIG_UnpackVoidPtr(const char *c, void **ptr, const char *name) {
703  if (*c != '_') {
704  if (strcmp(c,"NULL") == 0) {
705  *ptr = (void *) 0;
706  return name;
707  } else {
708  return 0;
709  }
710  }
711  return SWIG_UnpackData(++c,ptr,sizeof(void *));
712 }
713 
714 SWIGRUNTIME char *
715 SWIG_PackDataName(char *buff, void *ptr, size_t sz, const char *name, size_t bsz) {
716  char *r = buff;
717  size_t lname = (name ? strlen(name) : 0);
718  if ((2*sz + 2 + lname) > bsz) return 0;
719  *(r++) = '_';
720  r = SWIG_PackData(r,ptr,sz);
721  if (lname) {
722  strncpy(r,name,lname+1);
723  } else {
724  *r = 0;
725  }
726  return buff;
727 }
728 
729 SWIGRUNTIME const char *
730 SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) {
731  if (*c != '_') {
732  if (strcmp(c,"NULL") == 0) {
733  memset(ptr,0,sz);
734  return name;
735  } else {
736  return 0;
737  }
738  }
739  return SWIG_UnpackData(++c,ptr,sz);
740 }
741 
742 #ifdef __cplusplus
743 }
744 #endif
745 
746 /* Errors in SWIG */
747 #define SWIG_UnknownError -1
748 #define SWIG_IOError -2
749 #define SWIG_RuntimeError -3
750 #define SWIG_IndexError -4
751 #define SWIG_TypeError -5
752 #define SWIG_DivisionByZero -6
753 #define SWIG_OverflowError -7
754 #define SWIG_SyntaxError -8
755 #define SWIG_ValueError -9
756 #define SWIG_SystemError -10
757 #define SWIG_AttributeError -11
758 #define SWIG_MemoryError -12
759 #define SWIG_NullReferenceError -13
760 
761 
762 
763 /* -----------------------------------------------------------------------------
764  * error manipulation
765  * ----------------------------------------------------------------------------- */
766 
767 SWIGINTERN const char*
769  const char* type = 0;
770  switch(code) {
771  case SWIG_MemoryError:
772  type = "MemoryError";
773  break;
774  case SWIG_IOError:
775  type = "IOError";
776  break;
777  case SWIG_RuntimeError:
778  type = "RuntimeError";
779  break;
780  case SWIG_IndexError:
781  type = "IndexError";
782  break;
783  case SWIG_TypeError:
784  type = "TypeError";
785  break;
786  case SWIG_DivisionByZero:
787  type = "ZeroDivisionError";
788  break;
789  case SWIG_OverflowError:
790  type = "OverflowError";
791  break;
792  case SWIG_SyntaxError:
793  type = "SyntaxError";
794  break;
795  case SWIG_ValueError:
796  type = "ValueError";
797  break;
798  case SWIG_SystemError:
799  type = "SystemError";
800  break;
801  case SWIG_AttributeError:
802  type = "AttributeError";
803  break;
804  default:
805  type = "RuntimeError";
806  }
807  return type;
808 }
809 
810 
811 SWIGINTERN void
812 SWIG_Tcl_SetErrorObj(Tcl_Interp *interp, const char *ctype, Tcl_Obj *obj)
813 {
814  Tcl_ResetResult(interp);
815  Tcl_SetObjResult(interp, obj);
816  Tcl_SetErrorCode(interp, "SWIG", ctype, NULL);
817 }
818 
819 SWIGINTERN void
820 SWIG_Tcl_SetErrorMsg(Tcl_Interp *interp, const char *ctype, const char *mesg)
821 {
822  Tcl_ResetResult(interp);
823  Tcl_SetErrorCode(interp, "SWIG", ctype, NULL);
824  Tcl_AppendResult(interp, ctype, " ", mesg, NULL);
825  /*
826  Tcl_AddErrorInfo(interp, ctype);
827  Tcl_AddErrorInfo(interp, " ");
828  Tcl_AddErrorInfo(interp, mesg);
829  */
830 }
831 
832 SWIGINTERNINLINE void
833 SWIG_Tcl_AddErrorMsg(Tcl_Interp *interp, const char* mesg)
834 {
835  Tcl_AddErrorInfo(interp, mesg);
836 }
837 
838 
839 
840 /* -----------------------------------------------------------------------------
841  * SWIG API. Portion that goes into the runtime
842  * ----------------------------------------------------------------------------- */
843 #ifdef __cplusplus
844 extern "C" {
845 #endif
846 
847 /* -----------------------------------------------------------------------------
848  * Constant declarations
849  * ----------------------------------------------------------------------------- */
850 
851 /* Constant Types */
852 #define SWIG_TCL_POINTER 4
853 #define SWIG_TCL_BINARY 5
854 
855 /* Constant information structure */
856 typedef struct swig_const_info {
857  int type;
858  const char *name;
859  long lvalue;
860  double dvalue;
861  void *pvalue;
864 
865 typedef int (*swig_wrapper)(ClientData, Tcl_Interp *, int, Tcl_Obj *CONST []);
866 typedef int (*swig_wrapper_func)(ClientData, Tcl_Interp *, int, Tcl_Obj *CONST []);
867 typedef char *(*swig_variable_func)(ClientData, Tcl_Interp *, char *, char *, int);
868 typedef void (*swig_delete_func)(ClientData);
869 
870 typedef struct swig_method {
871  const char *name;
874 
875 typedef struct swig_attribute {
876  const char *name;
880 
881 typedef struct swig_class {
882  const char *name;
885  void (*destructor)(void *);
888  struct swig_class **bases;
889  const char **base_names;
891  Tcl_HashTable hashtable;
893 
894 typedef struct swig_instance {
895  Tcl_Obj *thisptr;
896  void *thisvalue;
898  int destroy;
899  Tcl_Command cmdtok;
901 
902 /* Structure for command table */
903 typedef struct {
904  const char *name;
905  int (*wrapper)(ClientData, Tcl_Interp *, int, Tcl_Obj *CONST []);
906  ClientData clientdata;
908 
909 /* Structure for variable linking table */
910 typedef struct {
911  const char *name;
912  void *addr;
913  char * (*get)(ClientData, Tcl_Interp *, char *, char *, int);
914  char * (*set)(ClientData, Tcl_Interp *, char *, char *, int);
915 } swig_var_info;
916 
917 
918 /* -----------------------------------------------------------------------------*
919  * Install a constant object
920  * -----------------------------------------------------------------------------*/
921 
922 static Tcl_HashTable swigconstTable;
923 static int swigconstTableinit = 0;
924 
925 SWIGINTERN void
926 SWIG_Tcl_SetConstantObj(Tcl_Interp *interp, const char* name, Tcl_Obj *obj) {
927  int newobj;
928  Tcl_ObjSetVar2(interp,Tcl_NewStringObj(name,-1), NULL, obj, TCL_GLOBAL_ONLY);
929  Tcl_SetHashValue(Tcl_CreateHashEntry(&swigconstTable, name, &newobj), (ClientData) obj);
930 }
931 
932 SWIGINTERN Tcl_Obj *
933 SWIG_Tcl_GetConstantObj(const char *key) {
934  Tcl_HashEntry *entryPtr;
935  if (!swigconstTableinit) return 0;
936  entryPtr = Tcl_FindHashEntry(&swigconstTable, key);
937  if (entryPtr) {
938  return (Tcl_Obj *) Tcl_GetHashValue(entryPtr);
939  }
940  return 0;
941 }
942 
943 #ifdef __cplusplus
944 }
945 #endif
946 
947 
948 
949 /* -----------------------------------------------------------------------------
950  * tclrun.swg
951  *
952  * This file contains the runtime support for Tcl modules and includes
953  * code for managing global variables and pointer type checking.
954  * ----------------------------------------------------------------------------- */
955 
956 /* Common SWIG API */
957 
958 /* for raw pointers */
959 #define SWIG_ConvertPtr(oc, ptr, ty, flags) SWIG_Tcl_ConvertPtr(interp, oc, ptr, ty, flags)
960 #define SWIG_NewPointerObj(ptr, type, flags) SWIG_Tcl_NewPointerObj(ptr, type, flags)
961 
962 /* for raw packed data */
963 #define SWIG_ConvertPacked(obj, ptr, sz, ty) SWIG_Tcl_ConvertPacked(interp, obj, ptr, sz, ty)
964 #define SWIG_NewPackedObj(ptr, sz, type) SWIG_Tcl_NewPackedObj(ptr, sz, type)
965 
966 /* for class or struct pointers */
967 #define SWIG_ConvertInstance(obj, pptr, type, flags) SWIG_Tcl_ConvertPtr(interp, obj, pptr, type, flags)
968 #define SWIG_NewInstanceObj(thisvalue, type, flags) SWIG_Tcl_NewInstanceObj(interp, thisvalue, type, flags)
969 
970 /* for C or C++ function pointers */
971 #define SWIG_ConvertFunctionPtr(obj, pptr, type) SWIG_Tcl_ConvertPtr(interp, obj, pptr, type, 0)
972 #define SWIG_NewFunctionPtrObj(ptr, type) SWIG_Tcl_NewPointerObj(ptr, type, 0)
973 
974 /* for C++ member pointers, ie, member methods */
975 #define SWIG_ConvertMember(obj, ptr, sz, ty) SWIG_Tcl_ConvertPacked(interp,obj, ptr, sz, ty)
976 #define SWIG_NewMemberObj(ptr, sz, type) SWIG_Tcl_NewPackedObj(ptr, sz, type)
977 
978 
979 /* Runtime API */
980 
981 #define SWIG_GetModule(clientdata) SWIG_Tcl_GetModule((Tcl_Interp *) (clientdata))
982 #define SWIG_SetModule(clientdata, pointer) SWIG_Tcl_SetModule((Tcl_Interp *) (clientdata), pointer)
983 
984 
985 /* Error manipulation */
986 
987 #define SWIG_ErrorType(code) SWIG_Tcl_ErrorType(code)
988 #define SWIG_Error(code, msg) SWIG_Tcl_SetErrorMsg(interp, SWIG_Tcl_ErrorType(code), msg)
989 #define SWIG_fail goto fail
990 
991 
992 /* Tcl-specific SWIG API */
993 
994 #define SWIG_Acquire(ptr) SWIG_Tcl_Acquire(ptr)
995 #define SWIG_MethodCommand SWIG_Tcl_MethodCommand
996 #define SWIG_Disown(ptr) SWIG_Tcl_Disown(ptr)
997 #define SWIG_ConvertPtrFromString(c, ptr, ty, flags) SWIG_Tcl_ConvertPtrFromString(interp, c, ptr, ty, flags)
998 #define SWIG_MakePtr(c, ptr, ty, flags) SWIG_Tcl_MakePtr(c, ptr, ty, flags)
999 #define SWIG_PointerTypeFromString(c) SWIG_Tcl_PointerTypeFromString(c)
1000 #define SWIG_GetArgs SWIG_Tcl_GetArgs
1001 #define SWIG_GetConstantObj(key) SWIG_Tcl_GetConstantObj(key)
1002 #define SWIG_ObjectConstructor SWIG_Tcl_ObjectConstructor
1003 #define SWIG_Thisown(ptr) SWIG_Tcl_Thisown(ptr)
1004 #define SWIG_ObjectDelete SWIG_Tcl_ObjectDelete
1005 
1006 
1007 #define SWIG_TCL_DECL_ARGS_2(arg1, arg2) (Tcl_Interp *interp SWIGUNUSED, arg1, arg2)
1008 #define SWIG_TCL_CALL_ARGS_2(arg1, arg2) (interp, arg1, arg2)
1009 /* -----------------------------------------------------------------------------
1010  * pointers/data manipulation
1011  * ----------------------------------------------------------------------------- */
1012 
1013 /* For backward compatibility only */
1014 #define SWIG_POINTER_EXCEPTION 0
1015 #define SWIG_GetConstant SWIG_GetConstantObj
1016 #define SWIG_Tcl_GetConstant SWIG_Tcl_GetConstantObj
1017 
1018 #if TCL_MAJOR_VERSION >= 8 && TCL_MINOR_VERSION >= 5
1019 #define SWIG_TCL_HASHTABLE_INIT {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
1020 #else
1021 #define SWIG_TCL_HASHTABLE_INIT {0}
1022 #endif
1023 
1024 #include "assert.h"
1025 
1026 #ifdef __cplusplus
1027 extern "C" {
1028 #endif
1029 
1030 /* Object support */
1031 
1032 SWIGRUNTIME Tcl_HashTable*
1034  static Tcl_HashTable swigobjectTable;
1035  static int swigobjectTableinit = 0;
1036  if (!swigobjectTableinit) {
1037  Tcl_InitHashTable(&swigobjectTable, TCL_ONE_WORD_KEYS);
1038  swigobjectTableinit = 1;
1039  }
1040  return &swigobjectTable;
1041 }
1042 
1043 /* Acquire ownership of a pointer */
1044 SWIGRUNTIME void
1045 SWIG_Tcl_Acquire(void *ptr) {
1046  int newobj;
1047  Tcl_CreateHashEntry(SWIG_Tcl_ObjectTable(), (char *) ptr, &newobj);
1048 }
1049 
1050 SWIGRUNTIME int
1051 SWIG_Tcl_Thisown(void *ptr) {
1052  if (Tcl_FindHashEntry(SWIG_Tcl_ObjectTable(), (char *) ptr)) {
1053  return 1;
1054  }
1055  return 0;
1056 }
1057 
1058 /* Disown a pointer. Returns 1 if we owned it to begin with */
1059 SWIGRUNTIME int
1060 SWIG_Tcl_Disown(void *ptr) {
1061  Tcl_HashEntry *entryPtr = Tcl_FindHashEntry(SWIG_Tcl_ObjectTable(), (char *) ptr);
1062  if (entryPtr) {
1063  Tcl_DeleteHashEntry(entryPtr);
1064  return 1;
1065  }
1066  return 0;
1067 }
1068 
1069 /* Convert a pointer value */
1070 SWIGRUNTIME int
1071 SWIG_Tcl_ConvertPtrFromString(Tcl_Interp *interp, const char *c, void **ptr, swig_type_info *ty, int flags) {
1072  swig_cast_info *tc;
1073  /* Pointer values must start with leading underscore */
1074  while (*c != '_') {
1075  *ptr = (void *) 0;
1076  if (strcmp(c,"NULL") == 0)
1078 
1079  /* Empty string: not a pointer */
1080  if (*c == 0) return SWIG_ERROR;
1081 
1082  /* Hmmm. It could be an object name. */
1083 
1084  /* Check if this is a command at all. Prevents <c> cget -this */
1085  /* from being called when c is not a command, firing the unknown proc */
1086  if (Tcl_VarEval(interp,"info commands ", c, (char *) NULL) == TCL_OK) {
1087  Tcl_Obj *result = Tcl_GetObjResult(interp);
1088  if (*(Tcl_GetStringFromObj(result, NULL)) == 0) {
1089  /* It's not a command, so it can't be a pointer */
1090  Tcl_ResetResult(interp);
1091  return SWIG_ERROR;
1092  }
1093  } else {
1094  /* This will only fail if the argument is multiple words. */
1095  /* Multiple words are also not commands. */
1096  Tcl_ResetResult(interp);
1097  return SWIG_ERROR;
1098  }
1099 
1100  /* Check if this is really a SWIG pointer */
1101  if (Tcl_VarEval(interp,c," cget -this", (char *) NULL) != TCL_OK) {
1102  Tcl_ResetResult(interp);
1103  return SWIG_ERROR;
1104  }
1105 
1106  c = Tcl_GetStringFromObj(Tcl_GetObjResult(interp), NULL);
1107  }
1108 
1109  c++;
1110  c = SWIG_UnpackData(c,ptr,sizeof(void *));
1111  if (ty) {
1112  tc = c ? SWIG_TypeCheck(c,ty) : 0;
1113  if (!tc) {
1114  return SWIG_ERROR;
1115  }
1116  if (flags & SWIG_POINTER_DISOWN) {
1117  SWIG_Disown((void *) *ptr);
1118  }
1119  {
1120  int newmemory = 0;
1121  *ptr = SWIG_TypeCast(tc,(void *) *ptr,&newmemory);
1122  assert(!newmemory); /* newmemory handling not yet implemented */
1123  }
1124  }
1125  return SWIG_OK;
1126 }
1127 
1128 /* Convert a pointer value */
1130 SWIG_Tcl_ConvertPtr(Tcl_Interp *interp, Tcl_Obj *oc, void **ptr, swig_type_info *ty, int flags) {
1131  return SWIG_Tcl_ConvertPtrFromString(interp, Tcl_GetStringFromObj(oc,NULL), ptr, ty, flags);
1132 }
1133 
1134 /* Convert a pointer value */
1135 SWIGRUNTIME char *
1137  char d;
1138  /* Pointer values must start with leading underscore. NULL has no type */
1139  if (*c != '_') {
1140  return 0;
1141  }
1142  c++;
1143  /* Extract hex value from pointer */
1144  while ((d = *c)) {
1145  if (!(((d >= '0') && (d <= '9')) || ((d >= 'a') && (d <= 'f')))) break;
1146  c++;
1147  }
1148  return c;
1149 }
1150 
1151 /* Convert a packed pointer value */
1152 SWIGRUNTIME int
1153 SWIG_Tcl_ConvertPacked(Tcl_Interp *SWIGUNUSEDPARM(interp) , Tcl_Obj *obj, void *ptr, int sz, swig_type_info *ty) {
1154  swig_cast_info *tc;
1155  const char *c;
1156 
1157  if (!obj) goto type_error;
1158  c = Tcl_GetStringFromObj(obj,NULL);
1159  /* Pointer values must start with leading underscore */
1160  if (*c != '_') goto type_error;
1161  c++;
1162  c = SWIG_UnpackData(c,ptr,sz);
1163  if (ty) {
1164  tc = SWIG_TypeCheck(c,ty);
1165  if (!tc) goto type_error;
1166  }
1167  return SWIG_OK;
1168 
1169  type_error:
1170 
1171  return SWIG_ERROR;
1172 }
1173 
1174 
1175 /* Take a pointer and convert it to a string */
1176 SWIGRUNTIME void
1177 SWIG_Tcl_MakePtr(char *c, void *ptr, swig_type_info *ty, int SWIGUNUSEDPARM(flags)) {
1178  if (ptr) {
1179  *(c++) = '_';
1180  c = SWIG_PackData(c,&ptr,sizeof(void *));
1181  strcpy(c,ty->name);
1182  } else {
1183  strcpy(c,"NULL");
1184  }
1185 }
1186 
1187 /* Create a new pointer object */
1188 SWIGRUNTIMEINLINE Tcl_Obj *
1189 SWIG_Tcl_NewPointerObj(void *ptr, swig_type_info *type, int flags) {
1190  Tcl_Obj *robj;
1191  char result[SWIG_BUFFER_SIZE];
1192  SWIG_MakePtr(result,ptr,type,flags);
1193  robj = Tcl_NewStringObj(result,-1);
1194  return robj;
1195 }
1196 
1197 SWIGRUNTIME Tcl_Obj *
1198 SWIG_Tcl_NewPackedObj(void *ptr, int sz, swig_type_info *type) {
1199  char result[1024];
1200  char *r = result;
1201  if ((2*sz + 1 + strlen(type->name)) > 1000) return 0;
1202  *(r++) = '_';
1203  r = SWIG_PackData(r,ptr,sz);
1204  strcpy(r,type->name);
1205  return Tcl_NewStringObj(result,-1);
1206 }
1207 
1208 /* -----------------------------------------------------------------------------*
1209  * Get type list
1210  * -----------------------------------------------------------------------------*/
1211 
1213 SWIG_Tcl_GetModule(Tcl_Interp *interp) {
1214  const char *data;
1215  swig_module_info *ret = 0;
1216 
1217  /* first check if pointer already created */
1218  data = Tcl_GetVar(interp, (char *)"swig_runtime_data_type_pointer" SWIG_RUNTIME_VERSION SWIG_TYPE_TABLE_NAME, TCL_GLOBAL_ONLY);
1219  if (data) {
1220  SWIG_UnpackData(data, &ret, sizeof(swig_type_info **));
1221  }
1222 
1223  return ret;
1224 }
1225 
1226 SWIGRUNTIME void
1227 SWIG_Tcl_SetModule(Tcl_Interp *interp, swig_module_info *module) {
1228  char buf[SWIG_BUFFER_SIZE];
1229  char *data;
1230 
1231  /* create a new pointer */
1232  data = SWIG_PackData(buf, &module, sizeof(swig_type_info **));
1233  *data = 0;
1234  Tcl_SetVar(interp, (char *)"swig_runtime_data_type_pointer" SWIG_RUNTIME_VERSION SWIG_TYPE_TABLE_NAME, buf, TCL_GLOBAL_ONLY);
1235 }
1236 
1237 /* -----------------------------------------------------------------------------*
1238  * Object auxiliaries
1239  * -----------------------------------------------------------------------------*/
1240 
1241 
1242 SWIGRUNTIME void
1243 SWIG_Tcl_ObjectDelete(ClientData clientData) {
1244  swig_instance *si = (swig_instance *) clientData;
1245  if (!si) return;
1246  if (si->destroy && SWIG_Disown(si->thisvalue)) {
1247  if (si->classptr->destructor) {
1248  (si->classptr->destructor)(si->thisvalue);
1249  }
1250  }
1251  Tcl_DecrRefCount(si->thisptr);
1252  free(si);
1253 }
1254 
1255 /* Function to invoke object methods given an instance */
1256 SWIGRUNTIME int
1257 SWIG_Tcl_MethodCommand(ClientData clientData, Tcl_Interp *interp, int objc, Tcl_Obj *CONST _objv[]) {
1258  char *method, *attrname;
1259  swig_instance *inst = (swig_instance *) clientData;
1260  swig_method *meth;
1261  swig_attribute *attr;
1262  Tcl_Obj *oldarg;
1263  Tcl_Obj **objv;
1264  int rcode;
1265  swig_class *cls;
1266  swig_class *cls_stack[64];
1267  int cls_stack_bi[64];
1268  int cls_stack_top = 0;
1269  int numconf = 2;
1270  int bi;
1271 
1272  objv = (Tcl_Obj **) _objv;
1273  if (objc < 2) {
1274  Tcl_SetResult(interp, (char *) "wrong # args.", TCL_STATIC);
1275  return TCL_ERROR;
1276  }
1277  method = Tcl_GetStringFromObj(objv[1],NULL);
1278  if (strcmp(method,"-acquire") == 0) {
1279  inst->destroy = 1;
1280  SWIG_Acquire(inst->thisvalue);
1281  return TCL_OK;
1282  }
1283  if (strcmp(method,"-disown") == 0) {
1284  if (inst->destroy) {
1285  SWIG_Disown(inst->thisvalue);
1286  }
1287  inst->destroy = 0;
1288  return TCL_OK;
1289  }
1290  if (strcmp(method,"-delete") == 0) {
1291  Tcl_DeleteCommandFromToken(interp,inst->cmdtok);
1292  return TCL_OK;
1293  }
1294  cls_stack[cls_stack_top] = inst->classptr;
1295  cls_stack_bi[cls_stack_top] = -1;
1296  while (1) {
1297  Tcl_HashEntry* hashentry;
1298  bi = cls_stack_bi[cls_stack_top];
1299  cls = cls_stack[cls_stack_top];
1300  if (bi != -1) {
1301  if (!cls->bases[bi] && cls->base_names[bi]) {
1302  /* lookup and cache the base class */
1303  swig_type_info *info = SWIG_TypeQueryModule(cls->module, cls->module, cls->base_names[bi]);
1304  if (info) cls->bases[bi] = (swig_class *) info->clientdata;
1305  }
1306  cls = cls->bases[bi];
1307  if (cls) {
1308  cls_stack_bi[cls_stack_top]++;
1309  cls_stack_top++;
1310  cls_stack[cls_stack_top] = cls;
1311  cls_stack_bi[cls_stack_top] = -1;
1312  continue;
1313  }
1314  }
1315  if (!cls) {
1316  cls_stack_top--;
1317  if (cls_stack_top < 0) break;
1318  else continue;
1319  }
1320  cls_stack_bi[cls_stack_top]++;
1321 
1322  hashentry = Tcl_FindHashEntry(&(cls->hashtable), method);
1323  if (hashentry) {
1324  ClientData cd = Tcl_GetHashValue(hashentry);
1325  swig_wrapper method_wrapper = (swig_wrapper)cd;
1326  oldarg = objv[1];
1327  objv[1] = inst->thisptr;
1328  Tcl_IncrRefCount(inst->thisptr);
1329  rcode = (method_wrapper)(clientData,interp,objc,objv);
1330  objv[1] = oldarg;
1331  Tcl_DecrRefCount(inst->thisptr);
1332  return rcode;
1333  }
1334  /* Check class methods for a match */
1335  if (strcmp(method,"cget") == 0) {
1336  if (objc < 3) {
1337  Tcl_SetResult(interp, (char *) "wrong # args.", TCL_STATIC);
1338  return TCL_ERROR;
1339  }
1340  attrname = Tcl_GetStringFromObj(objv[2],NULL);
1341  attr = cls->attributes;
1342  while (attr && attr->name) {
1343  if ((strcmp(attr->name, attrname) == 0) && (attr->getmethod)) {
1344  oldarg = objv[1];
1345  objv[1] = inst->thisptr;
1346  Tcl_IncrRefCount(inst->thisptr);
1347  rcode = (*attr->getmethod)(clientData,interp,2, objv);
1348  objv[1] = oldarg;
1349  Tcl_DecrRefCount(inst->thisptr);
1350  return rcode;
1351  }
1352  attr++;
1353  }
1354  if (strcmp(attrname, "-this") == 0) {
1355  Tcl_SetObjResult(interp, Tcl_DuplicateObj(inst->thisptr));
1356  return TCL_OK;
1357  }
1358  if (strcmp(attrname, "-thisown") == 0) {
1359  if (SWIG_Thisown(inst->thisvalue)) {
1360  Tcl_SetResult(interp,(char*)"1",TCL_STATIC);
1361  } else {
1362  Tcl_SetResult(interp,(char*)"0",TCL_STATIC);
1363  }
1364  return TCL_OK;
1365  }
1366  } else if (strcmp(method, "configure") == 0) {
1367  int i;
1368  if (objc < 4) {
1369  Tcl_SetResult(interp, (char *) "wrong # args.", TCL_STATIC);
1370  return TCL_ERROR;
1371  }
1372  i = 2;
1373  while (i < objc) {
1374  attrname = Tcl_GetStringFromObj(objv[i],NULL);
1375  attr = cls->attributes;
1376  while (attr && attr->name) {
1377  if ((strcmp(attr->name, attrname) == 0) && (attr->setmethod)) {
1378  oldarg = objv[i];
1379  objv[i] = inst->thisptr;
1380  Tcl_IncrRefCount(inst->thisptr);
1381  rcode = (*attr->setmethod)(clientData,interp,3, &objv[i-1]);
1382  objv[i] = oldarg;
1383  Tcl_DecrRefCount(inst->thisptr);
1384  if (rcode != TCL_OK) return rcode;
1385  numconf += 2;
1386  }
1387  attr++;
1388  }
1389  i+=2;
1390  }
1391  }
1392  }
1393  if (strcmp(method,"configure") == 0) {
1394  if (numconf >= objc) {
1395  return TCL_OK;
1396  } else {
1397  Tcl_SetResult(interp,(char *) "Invalid attribute name.", TCL_STATIC);
1398  return TCL_ERROR;
1399  }
1400  }
1401  if (strcmp(method,"cget") == 0) {
1402  Tcl_SetResult(interp,(char *) "Invalid attribute name.", TCL_STATIC);
1403  return TCL_ERROR;
1404  }
1405  Tcl_SetResult(interp, (char *) "Invalid method. Must be one of: configure cget -acquire -disown -delete", TCL_STATIC);
1406  cls = inst->classptr;
1407  bi = 0;
1408  while (cls) {
1409  meth = cls->methods;
1410  while (meth && meth->name) {
1411  char *cr = (char *) Tcl_GetStringResult(interp);
1412  size_t meth_len = strlen(meth->name);
1413  char* where = strchr(cr,':');
1414  while(where) {
1415  where = strstr(where, meth->name);
1416  if(where) {
1417  if(where[-1] == ' ' && (where[meth_len] == ' ' || where[meth_len]==0)) {
1418  break;
1419  } else {
1420  where++;
1421  }
1422  }
1423  }
1424 
1425  if (!where)
1426  Tcl_AppendElement(interp, (char *) meth->name);
1427  meth++;
1428  }
1429  cls = inst->classptr->bases[bi++];
1430  }
1431  return TCL_ERROR;
1432 }
1433 
1434 /* This function takes the current result and turns it into an object command */
1435 SWIGRUNTIME Tcl_Obj *
1436 SWIG_Tcl_NewInstanceObj(Tcl_Interp *interp, void *thisvalue, swig_type_info *type, int flags) {
1437  Tcl_Obj *robj = SWIG_NewPointerObj(thisvalue, type,0);
1438  /* Check to see if this pointer belongs to a class or not */
1439  if (thisvalue && (type->clientdata) && (interp)) {
1440  Tcl_CmdInfo ci;
1441  char *name;
1442  name = Tcl_GetStringFromObj(robj,NULL);
1443  if (!Tcl_GetCommandInfo(interp,name, &ci) || (flags)) {
1444  swig_instance *newinst = (swig_instance *) malloc(sizeof(swig_instance));
1445  newinst->thisptr = Tcl_DuplicateObj(robj);
1446  Tcl_IncrRefCount(newinst->thisptr);
1447  newinst->thisvalue = thisvalue;
1448  newinst->classptr = (swig_class *) type->clientdata;
1449  newinst->destroy = flags;
1450  newinst->cmdtok = Tcl_CreateObjCommand(interp, Tcl_GetStringFromObj(robj,NULL), (swig_wrapper_func) SWIG_MethodCommand, (ClientData) newinst, (swig_delete_func) SWIG_ObjectDelete);
1451  if (flags) {
1452  SWIG_Acquire(thisvalue);
1453  }
1454  }
1455  }
1456  return robj;
1457 }
1458 
1459 /* Function to create objects */
1460 SWIGRUNTIME int
1461 SWIG_Tcl_ObjectConstructor(ClientData clientData, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
1462  Tcl_Obj *newObj = 0;
1463  void *thisvalue = 0;
1464  swig_instance *newinst = 0;
1465  swig_class *classptr = (swig_class *) clientData;
1466  swig_wrapper cons = 0;
1467  char *name = 0;
1468  int firstarg = 0;
1469  int thisarg = 0;
1470  int destroy = 1;
1471 
1472  if (!classptr) {
1473  Tcl_SetResult(interp, (char *) "swig: internal runtime error. No class object defined.", TCL_STATIC);
1474  return TCL_ERROR;
1475  }
1476  cons = classptr->constructor;
1477  if (objc > 1) {
1478  char *s = Tcl_GetStringFromObj(objv[1],NULL);
1479  if (strcmp(s,"-this") == 0) {
1480  thisarg = 2;
1481  cons = 0;
1482  } else if (strcmp(s,"-args") == 0) {
1483  firstarg = 1;
1484  } else if (objc == 2) {
1485  firstarg = 1;
1486  name = s;
1487  } else if (objc >= 3) {
1488  char *s1;
1489  name = s;
1490  s1 = Tcl_GetStringFromObj(objv[2],NULL);
1491  if (strcmp(s1,"-this") == 0) {
1492  thisarg = 3;
1493  cons = 0;
1494  } else {
1495  firstarg = 1;
1496  }
1497  }
1498  }
1499  if (cons) {
1500  int result;
1501  result = (*cons)(0, interp, objc-firstarg, &objv[firstarg]);
1502  if (result != TCL_OK) {
1503  return result;
1504  }
1505  newObj = Tcl_DuplicateObj(Tcl_GetObjResult(interp));
1506  if (!name) name = Tcl_GetStringFromObj(newObj,NULL);
1507  } else if (thisarg > 0) {
1508  if (thisarg < objc) {
1509  destroy = 0;
1510  newObj = Tcl_DuplicateObj(objv[thisarg]);
1511  if (!name) name = Tcl_GetStringFromObj(newObj,NULL);
1512  } else {
1513  Tcl_SetResult(interp, (char *) "wrong # args.", TCL_STATIC);
1514  return TCL_ERROR;
1515  }
1516  } else {
1517  Tcl_SetResult(interp, (char *) "No constructor available.", TCL_STATIC);
1518  return TCL_ERROR;
1519  }
1520  if (SWIG_Tcl_ConvertPtr(interp,newObj, (void **) &thisvalue, *(classptr->type), 0) != SWIG_OK) {
1521  Tcl_DecrRefCount(newObj);
1522  return TCL_ERROR;
1523  }
1524  newinst = (swig_instance *) malloc(sizeof(swig_instance));
1525  newinst->thisptr = newObj;
1526  Tcl_IncrRefCount(newObj);
1527  newinst->thisvalue = thisvalue;
1528  newinst->classptr = classptr;
1529  newinst->destroy = destroy;
1530  if (destroy) {
1531  SWIG_Acquire(thisvalue);
1532  }
1533  newinst->cmdtok = Tcl_CreateObjCommand(interp,name, (swig_wrapper) SWIG_MethodCommand, (ClientData) newinst, (swig_delete_func) SWIG_ObjectDelete);
1534  return TCL_OK;
1535 }
1536 
1537 /* -----------------------------------------------------------------------------*
1538  * Get arguments
1539  * -----------------------------------------------------------------------------*/
1540 SWIGRUNTIME int
1541 SWIG_Tcl_GetArgs(Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[], const char *fmt, ...) {
1542  int argno = 0, opt = 0;
1543  long tempi;
1544  double tempd;
1545  const char *c;
1546  va_list ap;
1547  void *vptr;
1548  Tcl_Obj *obj = 0;
1549  swig_type_info *ty;
1550 
1551  va_start(ap,fmt);
1552  for (c = fmt; (*c && (*c != ':') && (*c != ';')); c++,argno++) {
1553  if (*c == '|') {
1554  opt = 1;
1555  c++;
1556  }
1557  if (argno >= (objc-1)) {
1558  if (!opt) {
1559  Tcl_SetResult(interp, (char *) "Wrong number of arguments ", TCL_STATIC);
1560  goto argerror;
1561  } else {
1562  va_end(ap);
1563  return TCL_OK;
1564  }
1565  }
1566 
1567  vptr = va_arg(ap,void *);
1568  if (vptr) {
1569  if (isupper(*c)) {
1570  obj = SWIG_Tcl_GetConstantObj(Tcl_GetStringFromObj(objv[argno+1],0));
1571  if (!obj) obj = objv[argno+1];
1572  } else {
1573  obj = objv[argno+1];
1574  }
1575  switch(*c) {
1576  case 'i': case 'I':
1577  case 'l': case 'L':
1578  case 'h': case 'H':
1579  case 'b': case 'B':
1580  if (Tcl_GetLongFromObj(interp,obj,&tempi) != TCL_OK) goto argerror;
1581  if ((*c == 'i') || (*c == 'I')) *((int *)vptr) = (int)tempi;
1582  else if ((*c == 'l') || (*c == 'L')) *((long *)vptr) = (long)tempi;
1583  else if ((*c == 'h') || (*c == 'H')) *((short*)vptr) = (short)tempi;
1584  else if ((*c == 'b') || (*c == 'B')) *((unsigned char *)vptr) = (unsigned char)tempi;
1585  break;
1586  case 'f': case 'F':
1587  case 'd': case 'D':
1588  if (Tcl_GetDoubleFromObj(interp,obj,&tempd) != TCL_OK) goto argerror;
1589  if ((*c == 'f') || (*c == 'F')) *((float *) vptr) = (float)tempd;
1590  else if ((*c == 'd') || (*c == 'D')) *((double*) vptr) = tempd;
1591  break;
1592  case 's': case 'S':
1593  if (*(c+1) == '#') {
1594  int *vlptr = (int *) va_arg(ap, void *);
1595  *((char **) vptr) = Tcl_GetStringFromObj(obj, vlptr);
1596  c++;
1597  } else {
1598  *((char **)vptr) = Tcl_GetStringFromObj(obj,NULL);
1599  }
1600  break;
1601  case 'c': case 'C':
1602  *((char *)vptr) = *(Tcl_GetStringFromObj(obj,NULL));
1603  break;
1604  case 'p': case 'P':
1605  ty = (swig_type_info *) va_arg(ap, void *);
1606  if (SWIG_Tcl_ConvertPtr(interp, obj, (void **) vptr, ty, 0) != SWIG_OK) goto argerror;
1607  break;
1608  case 'o': case 'O':
1609  *((Tcl_Obj **)vptr) = objv[argno+1];
1610  break;
1611  default:
1612  break;
1613  }
1614  }
1615  }
1616 
1617  if ((*c != ';') && ((objc-1) > argno)) {
1618  Tcl_SetResult(interp, (char *) "Wrong # args.", TCL_STATIC);
1619  goto argerror;
1620  }
1621  va_end(ap);
1622  return TCL_OK;
1623 
1624  argerror:
1625  {
1626  char temp[32];
1627  sprintf(temp,"%d", argno+1);
1628  c = strchr(fmt,':');
1629  if (!c) c = strchr(fmt,';');
1630  if (!c) c = (char *)"";
1631  Tcl_AppendResult(interp,c," argument ", temp, NULL);
1632  va_end(ap);
1633  return TCL_ERROR;
1634  }
1635 }
1636 
1637 #ifdef __cplusplus
1638 }
1639 #endif
1640 
1641 
1642 
1643 #define SWIG_exception_fail(code, msg) do { SWIG_Error(code, msg); SWIG_fail; } while(0)
1644 
1645 #define SWIG_contract_assert(expr, msg) if (!(expr)) { SWIG_Error(SWIG_RuntimeError, msg); SWIG_fail; } else
1646 
1647 
1648 
1649 /* -------- TYPES TABLE (BEGIN) -------- */
1650 
1651 #define SWIGTYPE_p_a_base swig_types[0]
1652 #define SWIGTYPE_p_a_point swig_types[1]
1653 #define SWIGTYPE_p_a_unit swig_types[2]
1654 #define SWIGTYPE_p_a_unit_base swig_types[3]
1655 #define SWIGTYPE_p_a_unit_system swig_types[4]
1656 #define SWIGTYPE_p_char swig_types[5]
1658 static swig_module_info swig_module = {swig_types, 6, 0, 0, 0, 0};
1659 #define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name)
1660 #define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name)
1661 
1662 /* -------- TYPES TABLE (END) -------- */
1663 
1664 #define SWIG_init A_unit_Init
1665 #define SWIG_name "a_unit"
1666 #define SWIG_prefix ""
1667 #define SWIG_version "0.0"
1668 
1669 #define SWIGVERSION 0x040002
1670 #define SWIG_VERSION SWIGVERSION
1671 
1672 
1673 #define SWIG_as_voidptr(a) const_cast< void * >(static_cast< const void * >(a))
1674 #define SWIG_as_voidptrptr(a) ((void)SWIG_as_voidptr(*a),reinterpret_cast< void** >(a))
1675 
1676 
1677 #include <stdexcept>
1678 
1679 
1680 
1681 #ifdef __cplusplus
1682 extern "C" {
1683 #endif
1684 #ifdef MAC_TCL
1685 #pragma export on
1686 #endif
1687 SWIGEXPORT int SWIG_init(Tcl_Interp *);
1688 #ifdef MAC_TCL
1689 #pragma export off
1690 #endif
1691 #ifdef __cplusplus
1692 }
1693 #endif
1694 
1695 /* Compatibility version for TCL stubs */
1696 #ifndef SWIG_TCL_STUBS_VERSION
1697 #define SWIG_TCL_STUBS_VERSION "8.1"
1698 #endif
1699 
1700 
1701 
1702 #include <string>
1703 
1704 
1705 #include "a_base.h"
1706 #include <iostream>
1707 #include <sstream>
1708 
1709 
1710 #include <limits.h>
1711 #if !defined(SWIG_NO_LLONG_MAX)
1712 # if !defined(LLONG_MAX) && defined(__GNUC__) && defined (__LONG_LONG_MAX__)
1713 # define LLONG_MAX __LONG_LONG_MAX__
1714 # define LLONG_MIN (-LLONG_MAX - 1LL)
1715 # define ULLONG_MAX (LLONG_MAX * 2ULL + 1ULL)
1716 # endif
1717 #endif
1718 
1719 
1720 SWIGINTERNINLINE Tcl_Obj *
1721 SWIG_FromCharPtrAndSize(const char* carray, size_t size)
1722 {
1723  return (size < INT_MAX) ? Tcl_NewStringObj(carray, static_cast< int >(size)) : NULL;
1724 }
1725 
1726 
1727 SWIGINTERNINLINE Tcl_Obj *
1728 SWIG_From_std_string (const std::string& s)
1729 {
1730  return SWIG_FromCharPtrAndSize(s.data(), s.size());
1731 }
1732 
1733 
1734 SWIGINTERN int
1735 SWIG_AsVal_double SWIG_TCL_DECL_ARGS_2(Tcl_Obj *obj, double *val)
1736 {
1737  double v;
1738  if (Tcl_GetDoubleFromObj(0, obj, &v) == TCL_OK) {
1739  if (val) *val = v;
1740  return SWIG_OK;
1741  }
1742  return SWIG_TypeError;
1743 }
1744 
1745 
1746  #define SWIG_From_double Tcl_NewDoubleObj
1747 
1748 SWIGINTERN std::string a_base_print(a_base *self){
1749  std::ostringstream out;
1750  out << *self;
1751  return out.str();
1752  }
1753 
1754 #include "a_unit_base.h"
1755 
1756 
1757 SWIGINTERN int
1758 SWIG_AsCharPtrAndSize(Tcl_Obj *obj, char** cptr, size_t* psize, int *alloc)
1759 {
1760  int len = 0;
1761  char *cstr = Tcl_GetStringFromObj(obj, &len);
1762  if (cstr) {
1763  if (cptr) *cptr = cstr;
1764  if (psize) *psize = len + 1;
1765  if (alloc) *alloc = SWIG_OLDOBJ;
1766  return SWIG_OK;
1767  }
1768  return SWIG_TypeError;
1769 }
1770 
1771 
1772 SWIGINTERN int
1773 SWIG_AsPtr_std_string SWIG_TCL_DECL_ARGS_2(Tcl_Obj * obj, std::string **val)
1774 {
1775  char* buf = 0 ; size_t size = 0; int alloc = SWIG_OLDOBJ;
1776  if (SWIG_IsOK((SWIG_AsCharPtrAndSize(obj, &buf, &size, &alloc)))) {
1777  if (buf) {
1778  if (val) *val = new std::string(buf, size - 1);
1779  if (alloc == SWIG_NEWOBJ) delete[] buf;
1780  return SWIG_NEWOBJ;
1781  } else {
1782  if (val) *val = 0;
1783  return SWIG_OLDOBJ;
1784  }
1785  } else {
1786  static int init = 0;
1787  static swig_type_info* descriptor = 0;
1788  if (!init) {
1789  descriptor = SWIG_TypeQuery("std::string" " *");
1790  init = 1;
1791  }
1792  if (descriptor) {
1793  std::string *vptr;
1794  int res = SWIG_ConvertPtr(obj, (void**)&vptr, descriptor, 0);
1795  if (SWIG_IsOK(res) && val) *val = vptr;
1796  return res;
1797  }
1798  }
1799  return SWIG_ERROR;
1800 }
1801 
1802 
1803 #include "a_unit.h"
1804 
1805 
1806 #include "a_unit_system.h"
1807 
1808 
1809 SWIGINTERN int
1810 SWIG_AsVal_long SWIG_TCL_DECL_ARGS_2(Tcl_Obj *obj, long* val)
1811 {
1812  long v;
1813  if (Tcl_GetLongFromObj(0,obj, &v) == TCL_OK) {
1814  if (val) *val = (long) v;
1815  return SWIG_OK;
1816  }
1817  return SWIG_TypeError;
1818 }
1819 
1820 
1821 SWIGINTERN int
1822 SWIG_AsVal_int SWIG_TCL_DECL_ARGS_2(Tcl_Obj * obj, int *val)
1823 {
1824  long v;
1825  int res = SWIG_AsVal_long SWIG_TCL_CALL_ARGS_2(obj, &v);
1826  if (SWIG_IsOK(res)) {
1827  if ((v < INT_MIN || v > INT_MAX)) {
1828  return SWIG_OverflowError;
1829  } else {
1830  if (val) *val = static_cast< int >(v);
1831  }
1832  }
1833  return res;
1834 }
1835 
1836 
1837 SWIGINTERNINLINE Tcl_Obj*
1838 SWIG_From_long (long value)
1839 {
1840  if (((long) INT_MIN <= value) && (value <= (long) INT_MAX)) {
1841  return Tcl_NewIntObj(static_cast< int >(value));
1842  } else {
1843  return Tcl_NewLongObj(value);
1844  }
1845 }
1846 
1847 
1848 SWIGINTERNINLINE Tcl_Obj *
1849 SWIG_From_int (int value)
1850 {
1851  return SWIG_From_long (value);
1852 }
1853 
1854 #ifdef __cplusplus
1855 extern "C" {
1856 #endif
1857 SWIGINTERN int
1858 _wrap_a_base_classname(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
1859  a_base *arg1 = (a_base *) 0 ;
1860  void *argp1 = 0 ;
1861  int res1 = 0 ;
1862  std::string result;
1863 
1864  if (SWIG_GetArgs(interp, objc, objv,"o:a_base_classname self ",(void *)0) == TCL_ERROR) SWIG_fail;
1865  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_base, 0 | 0 );
1866  if (!SWIG_IsOK(res1)) {
1867  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_base_classname" "', argument " "1"" of type '" "a_base *""'");
1868  }
1869  arg1 = reinterpret_cast< a_base * >(argp1);
1870  result = (arg1)->classname();
1871  Tcl_SetObjResult(interp,SWIG_From_std_string(static_cast< std::string >(result)));
1872  return TCL_OK;
1873 fail:
1874  return TCL_ERROR;
1875 }
1876 
1877 
1878 SWIGINTERN int
1879 _wrap_a_base_help(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
1880  std::string result;
1881 
1882  if (SWIG_GetArgs(interp, objc, objv,":a_base_help ") == TCL_ERROR) SWIG_fail;
1883  result = a_base::help();
1884  Tcl_SetObjResult(interp,SWIG_From_std_string(static_cast< std::string >(result)));
1885  return TCL_OK;
1886 fail:
1887  return TCL_ERROR;
1888 }
1889 
1890 
1891 SWIGINTERN int
1892 _wrap_a_base_small__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
1893  a_base *arg1 = (a_base *) 0 ;
1894  double arg2 ;
1895  void *argp1 = 0 ;
1896  int res1 = 0 ;
1897  double val2 ;
1898  int ecode2 = 0 ;
1899 
1900  if (SWIG_GetArgs(interp, objc, objv,"oo:a_base_small self tol ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
1901  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_base, 0 | 0 );
1902  if (!SWIG_IsOK(res1)) {
1903  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_base_small" "', argument " "1"" of type '" "a_base *""'");
1904  }
1905  arg1 = reinterpret_cast< a_base * >(argp1);
1906  ecode2 = SWIG_AsVal_double SWIG_TCL_CALL_ARGS_2(objv[2], &val2);
1907  if (!SWIG_IsOK(ecode2)) {
1908  SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "a_base_small" "', argument " "2"" of type '" "double""'");
1909  }
1910  arg2 = static_cast< double >(val2);
1911  (arg1)->small(arg2);
1912 
1913  return TCL_OK;
1914 fail:
1915  return TCL_ERROR;
1916 }
1917 
1918 
1919 SWIGINTERN int
1920 _wrap_a_base_small__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
1921  a_base *arg1 = (a_base *) 0 ;
1922  void *argp1 = 0 ;
1923  int res1 = 0 ;
1924  double result;
1925 
1926  if (SWIG_GetArgs(interp, objc, objv,"o:a_base_small self ",(void *)0) == TCL_ERROR) SWIG_fail;
1927  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_base, 0 | 0 );
1928  if (!SWIG_IsOK(res1)) {
1929  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_base_small" "', argument " "1"" of type '" "a_base const *""'");
1930  }
1931  arg1 = reinterpret_cast< a_base * >(argp1);
1932  result = (double)((a_base const *)arg1)->small();
1933  Tcl_SetObjResult(interp,SWIG_From_double(static_cast< double >(result)));
1934  return TCL_OK;
1935 fail:
1936  return TCL_ERROR;
1937 }
1938 
1939 
1940 SWIGINTERN int
1941 _wrap_a_base_small(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
1942  Tcl_Obj *CONST *argv = objv+1;
1943  int argc = objc-1;
1944  if (argc == 1) {
1945  int _v;
1946  void *vptr = 0;
1947  int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_a_base, 0);
1948  _v = SWIG_CheckState(res);
1949  if (_v) {
1950  return _wrap_a_base_small__SWIG_1(clientData, interp, objc, argv - 1);
1951  }
1952  }
1953  if (argc == 2) {
1954  int _v;
1955  void *vptr = 0;
1956  int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_a_base, 0);
1957  _v = SWIG_CheckState(res);
1958  if (_v) {
1959  {
1960  int res = SWIG_AsVal_double SWIG_TCL_CALL_ARGS_2(argv[1], NULL);
1961  _v = SWIG_CheckState(res);
1962  }
1963  if (_v) {
1964  return _wrap_a_base_small__SWIG_0(clientData, interp, objc, argv - 1);
1965  }
1966  }
1967  }
1968 
1969  Tcl_SetResult(interp,(char *) "Wrong number or type of arguments for overloaded function 'a_base_small'.\n"
1970  " Possible C/C++ prototypes are:\n"
1971  " a_base::small(double)\n"
1972  " a_base::small() const\n", TCL_STATIC);
1973  return TCL_ERROR;
1974 }
1975 
1976 
1977 SWIGINTERN int
1978 _wrap_a_base_print(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
1979  a_base *arg1 = (a_base *) 0 ;
1980  void *argp1 = 0 ;
1981  int res1 = 0 ;
1982  std::string result;
1983 
1984  if (SWIG_GetArgs(interp, objc, objv,"o:a_base_print self ",(void *)0) == TCL_ERROR) SWIG_fail;
1985  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_base, 0 | 0 );
1986  if (!SWIG_IsOK(res1)) {
1987  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_base_print" "', argument " "1"" of type '" "a_base *""'");
1988  }
1989  arg1 = reinterpret_cast< a_base * >(argp1);
1990  result = a_base_print(arg1);
1991  Tcl_SetObjResult(interp,SWIG_From_std_string(static_cast< std::string >(result)));
1992  return TCL_OK;
1993 fail:
1994  return TCL_ERROR;
1995 }
1996 
1997 
1998 SWIGINTERN int
1999 _wrap_new_a_base(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2000  a_base *result = 0 ;
2001 
2002  if (SWIG_GetArgs(interp, objc, objv,":new_a_base ") == TCL_ERROR) SWIG_fail;
2003  result = (a_base *)new a_base();
2004  Tcl_SetObjResult(interp, SWIG_NewInstanceObj( SWIG_as_voidptr(result), SWIGTYPE_p_a_base,0));
2005  return TCL_OK;
2006 fail:
2007  return TCL_ERROR;
2008 }
2009 
2010 
2011 SWIGINTERN int
2012 _wrap_delete_a_base(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2013  a_base *arg1 = (a_base *) 0 ;
2014  void *argp1 = 0 ;
2015  int res1 = 0 ;
2016 
2017  if (SWIG_GetArgs(interp, objc, objv,"o:delete_a_base self ",(void *)0) == TCL_ERROR) SWIG_fail;
2018  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_base, SWIG_POINTER_DISOWN | 0 );
2019  if (!SWIG_IsOK(res1)) {
2020  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_a_base" "', argument " "1"" of type '" "a_base *""'");
2021  }
2022  arg1 = reinterpret_cast< a_base * >(argp1);
2023  delete arg1;
2024 
2025  return TCL_OK;
2026 fail:
2027  return TCL_ERROR;
2028 }
2029 
2030 
2032 a_base *arg1 = (a_base *) obj;
2033 delete arg1;
2034 }
2036  {"classname", _wrap_a_base_classname},
2037  {"small", _wrap_a_base_small},
2038  {"print", _wrap_a_base_print},
2039  {0,0}
2040 };
2042  {0,0,0}
2043 };
2045 static const char * swig_a_base_base_names[] = {0};
2047 SWIGINTERN int
2048 _wrap_a_unit_base_classname(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2049  a_unit_base *arg1 = (a_unit_base *) 0 ;
2050  void *argp1 = 0 ;
2051  int res1 = 0 ;
2052  std::string result;
2053 
2054  if (SWIG_GetArgs(interp, objc, objv,"o:a_unit_base_classname self ",(void *)0) == TCL_ERROR) SWIG_fail;
2055  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_base, 0 | 0 );
2056  if (!SWIG_IsOK(res1)) {
2057  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_base_classname" "', argument " "1"" of type '" "a_unit_base *""'");
2058  }
2059  arg1 = reinterpret_cast< a_unit_base * >(argp1);
2060  result = (arg1)->classname();
2061  Tcl_SetObjResult(interp,SWIG_From_std_string(static_cast< std::string >(result)));
2062  return TCL_OK;
2063 fail:
2064  return TCL_ERROR;
2065 }
2066 
2067 
2068 SWIGINTERN int
2069 _wrap_a_unit_base_help(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2070  std::string result;
2071 
2072  if (SWIG_GetArgs(interp, objc, objv,":a_unit_base_help ") == TCL_ERROR) SWIG_fail;
2073  result = a_unit_base::help();
2074  Tcl_SetObjResult(interp,SWIG_From_std_string(static_cast< std::string >(result)));
2075  return TCL_OK;
2076 fail:
2077  return TCL_ERROR;
2078 }
2079 
2080 
2081 SWIGINTERN int
2082 _wrap_a_unit_base_read(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2083  a_unit_base *arg1 = (a_unit_base *) 0 ;
2084  std::string *arg2 = 0 ;
2085  void *argp1 = 0 ;
2086  int res1 = 0 ;
2087  int res2 = SWIG_OLDOBJ ;
2088 
2089  if (SWIG_GetArgs(interp, objc, objv,"oo:a_unit_base_read self file_in ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
2090  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_base, 0 | 0 );
2091  if (!SWIG_IsOK(res1)) {
2092  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_base_read" "', argument " "1"" of type '" "a_unit_base *""'");
2093  }
2094  arg1 = reinterpret_cast< a_unit_base * >(argp1);
2095  {
2096  std::string *ptr = (std::string *)0;
2097  res2 = SWIG_AsPtr_std_string SWIG_TCL_CALL_ARGS_2(objv[2], &ptr);
2098  if (!SWIG_IsOK(res2)) {
2099  SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "a_unit_base_read" "', argument " "2"" of type '" "std::string const &""'");
2100  }
2101  if (!ptr) {
2102  SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "a_unit_base_read" "', argument " "2"" of type '" "std::string const &""'");
2103  }
2104  arg2 = ptr;
2105  }
2106  (arg1)->read((std::string const &)*arg2);
2107 
2108  if (SWIG_IsNewObj(res2)) delete arg2;
2109  return TCL_OK;
2110 fail:
2111  if (SWIG_IsNewObj(res2)) delete arg2;
2112  return TCL_ERROR;
2113 }
2114 
2115 
2116 SWIGINTERN int
2117 _wrap_a_unit_base_write(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2118  a_unit_base *arg1 = (a_unit_base *) 0 ;
2119  std::string *arg2 = 0 ;
2120  void *argp1 = 0 ;
2121  int res1 = 0 ;
2122  int res2 = SWIG_OLDOBJ ;
2123 
2124  if (SWIG_GetArgs(interp, objc, objv,"oo:a_unit_base_write self file_out ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
2125  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_base, 0 | 0 );
2126  if (!SWIG_IsOK(res1)) {
2127  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_base_write" "', argument " "1"" of type '" "a_unit_base const *""'");
2128  }
2129  arg1 = reinterpret_cast< a_unit_base * >(argp1);
2130  {
2131  std::string *ptr = (std::string *)0;
2132  res2 = SWIG_AsPtr_std_string SWIG_TCL_CALL_ARGS_2(objv[2], &ptr);
2133  if (!SWIG_IsOK(res2)) {
2134  SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "a_unit_base_write" "', argument " "2"" of type '" "std::string const &""'");
2135  }
2136  if (!ptr) {
2137  SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "a_unit_base_write" "', argument " "2"" of type '" "std::string const &""'");
2138  }
2139  arg2 = ptr;
2140  }
2141  ((a_unit_base const *)arg1)->write((std::string const &)*arg2);
2142 
2143  if (SWIG_IsNewObj(res2)) delete arg2;
2144  return TCL_OK;
2145 fail:
2146  if (SWIG_IsNewObj(res2)) delete arg2;
2147  return TCL_ERROR;
2148 }
2149 
2150 
2151 SWIGINTERN int
2152 _wrap_new_a_unit_base(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2153  a_unit_base *result = 0 ;
2154 
2155  if (SWIG_GetArgs(interp, objc, objv,":new_a_unit_base ") == TCL_ERROR) SWIG_fail;
2156  result = (a_unit_base *)new a_unit_base();
2157  Tcl_SetObjResult(interp, SWIG_NewInstanceObj( SWIG_as_voidptr(result), SWIGTYPE_p_a_unit_base,0));
2158  return TCL_OK;
2159 fail:
2160  return TCL_ERROR;
2161 }
2162 
2163 
2164 SWIGINTERN int
2165 _wrap_delete_a_unit_base(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2166  a_unit_base *arg1 = (a_unit_base *) 0 ;
2167  void *argp1 = 0 ;
2168  int res1 = 0 ;
2169 
2170  if (SWIG_GetArgs(interp, objc, objv,"o:delete_a_unit_base self ",(void *)0) == TCL_ERROR) SWIG_fail;
2171  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_base, SWIG_POINTER_DISOWN | 0 );
2172  if (!SWIG_IsOK(res1)) {
2173  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_a_unit_base" "', argument " "1"" of type '" "a_unit_base *""'");
2174  }
2175  arg1 = reinterpret_cast< a_unit_base * >(argp1);
2176  delete arg1;
2177 
2178  return TCL_OK;
2179 fail:
2180  return TCL_ERROR;
2181 }
2182 
2183 
2185 a_unit_base *arg1 = (a_unit_base *) obj;
2186 delete arg1;
2187 }
2189  {"classname", _wrap_a_unit_base_classname},
2190  {"read", _wrap_a_unit_base_read},
2191  {"write", _wrap_a_unit_base_write},
2192  {0,0}
2193 };
2195  {0,0,0}
2196 };
2198 static const char * swig_a_unit_base_base_names[] = {"a_base *",0};
2200 SWIGINTERN int
2201 _wrap_new_a_unit__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2202  a_unit *result = 0 ;
2203 
2204  if (SWIG_GetArgs(interp, objc, objv,":new_a_unit ") == TCL_ERROR) SWIG_fail;
2205  result = (a_unit *)new a_unit();
2206  Tcl_SetObjResult(interp, SWIG_NewInstanceObj( SWIG_as_voidptr(result), SWIGTYPE_p_a_unit,0));
2207  return TCL_OK;
2208 fail:
2209  return TCL_ERROR;
2210 }
2211 
2212 
2213 SWIGINTERN int
2214 _wrap_new_a_unit__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2215  a_unit *arg1 = 0 ;
2216  void *argp1 ;
2217  int res1 = 0 ;
2218  a_unit *result = 0 ;
2219 
2220  if (SWIG_GetArgs(interp, objc, objv,"o:new_a_unit a_unit const & ",(void *)0) == TCL_ERROR) SWIG_fail;
2221  res1 = SWIG_ConvertPtr(objv[1], &argp1, SWIGTYPE_p_a_unit, 0 );
2222  if (!SWIG_IsOK(res1)) {
2223  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_a_unit" "', argument " "1"" of type '" "a_unit const &""'");
2224  }
2225  if (!argp1) {
2226  SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_a_unit" "', argument " "1"" of type '" "a_unit const &""'");
2227  }
2228  arg1 = reinterpret_cast< a_unit * >(argp1);
2229  result = (a_unit *)new a_unit((a_unit const &)*arg1);
2230  Tcl_SetObjResult(interp, SWIG_NewInstanceObj( SWIG_as_voidptr(result), SWIGTYPE_p_a_unit,0));
2231  return TCL_OK;
2232 fail:
2233  return TCL_ERROR;
2234 }
2235 
2236 
2237 SWIGINTERN int
2238 _wrap_new_a_unit__SWIG_2(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2239  std::string arg1 ;
2240  std::string arg2 ;
2241  double arg3 ;
2242  double val3 ;
2243  int ecode3 = 0 ;
2244  a_unit *result = 0 ;
2245 
2246  if (SWIG_GetArgs(interp, objc, objv,"ooo:new_a_unit n ns r ",(void *)0,(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
2247  {
2248  std::string *ptr = (std::string *)0;
2249  int res = SWIG_AsPtr_std_string SWIG_TCL_CALL_ARGS_2(objv[1], &ptr);
2250  if (!SWIG_IsOK(res) || !ptr) {
2251  SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_a_unit" "', argument " "1"" of type '" "std::string""'");
2252  }
2253  arg1 = *ptr;
2254  if (SWIG_IsNewObj(res)) delete ptr;
2255  }
2256  {
2257  std::string *ptr = (std::string *)0;
2258  int res = SWIG_AsPtr_std_string SWIG_TCL_CALL_ARGS_2(objv[2], &ptr);
2259  if (!SWIG_IsOK(res) || !ptr) {
2260  SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_a_unit" "', argument " "2"" of type '" "std::string""'");
2261  }
2262  arg2 = *ptr;
2263  if (SWIG_IsNewObj(res)) delete ptr;
2264  }
2265  ecode3 = SWIG_AsVal_double SWIG_TCL_CALL_ARGS_2(objv[3], &val3);
2266  if (!SWIG_IsOK(ecode3)) {
2267  SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_a_unit" "', argument " "3"" of type '" "double""'");
2268  }
2269  arg3 = static_cast< double >(val3);
2270  result = (a_unit *)new a_unit(arg1,arg2,arg3);
2271  Tcl_SetObjResult(interp, SWIG_NewInstanceObj( SWIG_as_voidptr(result), SWIGTYPE_p_a_unit,0));
2272  return TCL_OK;
2273 fail:
2274  return TCL_ERROR;
2275 }
2276 
2277 
2278 SWIGINTERN int
2279 _wrap_new_a_unit(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2280  Tcl_Obj *CONST *argv = objv+1;
2281  int argc = objc-1;
2282  if (argc == 0) {
2283  return _wrap_new_a_unit__SWIG_0(clientData, interp, objc, argv - 1);
2284  }
2285  if (argc == 1) {
2286  int _v;
2287  void *vptr = 0;
2288  int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_a_unit, SWIG_POINTER_NO_NULL);
2289  _v = SWIG_CheckState(res);
2290  if (_v) {
2291  return _wrap_new_a_unit__SWIG_1(clientData, interp, objc, argv - 1);
2292  }
2293  }
2294  if (argc == 3) {
2295  int _v;
2296  int res = SWIG_AsPtr_std_string SWIG_TCL_CALL_ARGS_2(argv[0], (std::string**)(0));
2297  _v = SWIG_CheckState(res);
2298  if (_v) {
2299  int res = SWIG_AsPtr_std_string SWIG_TCL_CALL_ARGS_2(argv[1], (std::string**)(0));
2300  _v = SWIG_CheckState(res);
2301  if (_v) {
2302  {
2303  int res = SWIG_AsVal_double SWIG_TCL_CALL_ARGS_2(argv[2], NULL);
2304  _v = SWIG_CheckState(res);
2305  }
2306  if (_v) {
2307  return _wrap_new_a_unit__SWIG_2(clientData, interp, objc, argv - 1);
2308  }
2309  }
2310  }
2311  }
2312 
2313  Tcl_SetResult(interp,(char *) "Wrong number or type of arguments for overloaded function 'new_a_unit'.\n"
2314  " Possible C/C++ prototypes are:\n"
2315  " a_unit::a_unit()\n"
2316  " a_unit::a_unit(a_unit const &)\n"
2317  " a_unit::a_unit(std::string,std::string,double)\n", TCL_STATIC);
2318  return TCL_ERROR;
2319 }
2320 
2321 
2322 SWIGINTERN int
2323 _wrap_a_unit_classname(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2324  a_unit *arg1 = (a_unit *) 0 ;
2325  void *argp1 = 0 ;
2326  int res1 = 0 ;
2327  std::string result;
2328 
2329  if (SWIG_GetArgs(interp, objc, objv,"o:a_unit_classname self ",(void *)0) == TCL_ERROR) SWIG_fail;
2330  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit, 0 | 0 );
2331  if (!SWIG_IsOK(res1)) {
2332  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_classname" "', argument " "1"" of type '" "a_unit *""'");
2333  }
2334  arg1 = reinterpret_cast< a_unit * >(argp1);
2335  result = (arg1)->classname();
2336  Tcl_SetObjResult(interp,SWIG_From_std_string(static_cast< std::string >(result)));
2337  return TCL_OK;
2338 fail:
2339  return TCL_ERROR;
2340 }
2341 
2342 
2343 SWIGINTERN int
2344 _wrap_a_unit_help(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2345  std::string result;
2346 
2347  if (SWIG_GetArgs(interp, objc, objv,":a_unit_help ") == TCL_ERROR) SWIG_fail;
2348  result = a_unit::help();
2349  Tcl_SetObjResult(interp,SWIG_From_std_string(static_cast< std::string >(result)));
2350  return TCL_OK;
2351 fail:
2352  return TCL_ERROR;
2353 }
2354 
2355 
2356 SWIGINTERN int
2357 _wrap_a_unit_name__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2358  a_unit *arg1 = (a_unit *) 0 ;
2359  void *argp1 = 0 ;
2360  int res1 = 0 ;
2361  std::string result;
2362 
2363  if (SWIG_GetArgs(interp, objc, objv,"o:a_unit_name self ",(void *)0) == TCL_ERROR) SWIG_fail;
2364  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit, 0 | 0 );
2365  if (!SWIG_IsOK(res1)) {
2366  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_name" "', argument " "1"" of type '" "a_unit const *""'");
2367  }
2368  arg1 = reinterpret_cast< a_unit * >(argp1);
2369  result = ((a_unit const *)arg1)->name();
2370  Tcl_SetObjResult(interp,SWIG_From_std_string(static_cast< std::string >(result)));
2371  return TCL_OK;
2372 fail:
2373  return TCL_ERROR;
2374 }
2375 
2376 
2377 SWIGINTERN int
2378 _wrap_a_unit_name__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2379  a_unit *arg1 = (a_unit *) 0 ;
2380  std::string arg2 ;
2381  void *argp1 = 0 ;
2382  int res1 = 0 ;
2383 
2384  if (SWIG_GetArgs(interp, objc, objv,"oo:a_unit_name self name ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
2385  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit, 0 | 0 );
2386  if (!SWIG_IsOK(res1)) {
2387  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_name" "', argument " "1"" of type '" "a_unit *""'");
2388  }
2389  arg1 = reinterpret_cast< a_unit * >(argp1);
2390  {
2391  std::string *ptr = (std::string *)0;
2392  int res = SWIG_AsPtr_std_string SWIG_TCL_CALL_ARGS_2(objv[2], &ptr);
2393  if (!SWIG_IsOK(res) || !ptr) {
2394  SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "a_unit_name" "', argument " "2"" of type '" "std::string const""'");
2395  }
2396  arg2 = *ptr;
2397  if (SWIG_IsNewObj(res)) delete ptr;
2398  }
2399  (arg1)->name(arg2);
2400 
2401  return TCL_OK;
2402 fail:
2403  return TCL_ERROR;
2404 }
2405 
2406 
2407 SWIGINTERN int
2408 _wrap_a_unit_name(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2409  Tcl_Obj *CONST *argv = objv+1;
2410  int argc = objc-1;
2411  if (argc == 1) {
2412  int _v;
2413  void *vptr = 0;
2414  int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_a_unit, 0);
2415  _v = SWIG_CheckState(res);
2416  if (_v) {
2417  return _wrap_a_unit_name__SWIG_0(clientData, interp, objc, argv - 1);
2418  }
2419  }
2420  if (argc == 2) {
2421  int _v;
2422  void *vptr = 0;
2423  int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_a_unit, 0);
2424  _v = SWIG_CheckState(res);
2425  if (_v) {
2426  int res = SWIG_AsPtr_std_string SWIG_TCL_CALL_ARGS_2(argv[1], (std::string**)(0));
2427  _v = SWIG_CheckState(res);
2428  if (_v) {
2429  return _wrap_a_unit_name__SWIG_1(clientData, interp, objc, argv - 1);
2430  }
2431  }
2432  }
2433 
2434  Tcl_SetResult(interp,(char *) "Wrong number or type of arguments for overloaded function 'a_unit_name'.\n"
2435  " Possible C/C++ prototypes are:\n"
2436  " a_unit::name() const\n"
2437  " a_unit::name(std::string const)\n", TCL_STATIC);
2438  return TCL_ERROR;
2439 }
2440 
2441 
2442 SWIGINTERN int
2443 _wrap_a_unit_short_name__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2444  a_unit *arg1 = (a_unit *) 0 ;
2445  void *argp1 = 0 ;
2446  int res1 = 0 ;
2447  std::string result;
2448 
2449  if (SWIG_GetArgs(interp, objc, objv,"o:a_unit_short_name self ",(void *)0) == TCL_ERROR) SWIG_fail;
2450  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit, 0 | 0 );
2451  if (!SWIG_IsOK(res1)) {
2452  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_short_name" "', argument " "1"" of type '" "a_unit const *""'");
2453  }
2454  arg1 = reinterpret_cast< a_unit * >(argp1);
2455  result = ((a_unit const *)arg1)->short_name();
2456  Tcl_SetObjResult(interp,SWIG_From_std_string(static_cast< std::string >(result)));
2457  return TCL_OK;
2458 fail:
2459  return TCL_ERROR;
2460 }
2461 
2462 
2463 SWIGINTERN int
2464 _wrap_a_unit_short_name__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2465  a_unit *arg1 = (a_unit *) 0 ;
2466  std::string arg2 ;
2467  void *argp1 = 0 ;
2468  int res1 = 0 ;
2469 
2470  if (SWIG_GetArgs(interp, objc, objv,"oo:a_unit_short_name self name ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
2471  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit, 0 | 0 );
2472  if (!SWIG_IsOK(res1)) {
2473  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_short_name" "', argument " "1"" of type '" "a_unit *""'");
2474  }
2475  arg1 = reinterpret_cast< a_unit * >(argp1);
2476  {
2477  std::string *ptr = (std::string *)0;
2478  int res = SWIG_AsPtr_std_string SWIG_TCL_CALL_ARGS_2(objv[2], &ptr);
2479  if (!SWIG_IsOK(res) || !ptr) {
2480  SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "a_unit_short_name" "', argument " "2"" of type '" "std::string const""'");
2481  }
2482  arg2 = *ptr;
2483  if (SWIG_IsNewObj(res)) delete ptr;
2484  }
2485  (arg1)->short_name(arg2);
2486 
2487  return TCL_OK;
2488 fail:
2489  return TCL_ERROR;
2490 }
2491 
2492 
2493 SWIGINTERN int
2494 _wrap_a_unit_short_name(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2495  Tcl_Obj *CONST *argv = objv+1;
2496  int argc = objc-1;
2497  if (argc == 1) {
2498  int _v;
2499  void *vptr = 0;
2500  int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_a_unit, 0);
2501  _v = SWIG_CheckState(res);
2502  if (_v) {
2503  return _wrap_a_unit_short_name__SWIG_0(clientData, interp, objc, argv - 1);
2504  }
2505  }
2506  if (argc == 2) {
2507  int _v;
2508  void *vptr = 0;
2509  int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_a_unit, 0);
2510  _v = SWIG_CheckState(res);
2511  if (_v) {
2512  int res = SWIG_AsPtr_std_string SWIG_TCL_CALL_ARGS_2(argv[1], (std::string**)(0));
2513  _v = SWIG_CheckState(res);
2514  if (_v) {
2515  return _wrap_a_unit_short_name__SWIG_1(clientData, interp, objc, argv - 1);
2516  }
2517  }
2518  }
2519 
2520  Tcl_SetResult(interp,(char *) "Wrong number or type of arguments for overloaded function 'a_unit_short_name'.\n"
2521  " Possible C/C++ prototypes are:\n"
2522  " a_unit::short_name() const\n"
2523  " a_unit::short_name(std::string const)\n", TCL_STATIC);
2524  return TCL_ERROR;
2525 }
2526 
2527 
2528 SWIGINTERN int
2529 _wrap_a_unit_ratio__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2530  a_unit *arg1 = (a_unit *) 0 ;
2531  void *argp1 = 0 ;
2532  int res1 = 0 ;
2533  double result;
2534 
2535  if (SWIG_GetArgs(interp, objc, objv,"o:a_unit_ratio self ",(void *)0) == TCL_ERROR) SWIG_fail;
2536  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit, 0 | 0 );
2537  if (!SWIG_IsOK(res1)) {
2538  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_ratio" "', argument " "1"" of type '" "a_unit const *""'");
2539  }
2540  arg1 = reinterpret_cast< a_unit * >(argp1);
2541  result = (double)((a_unit const *)arg1)->ratio();
2542  Tcl_SetObjResult(interp,SWIG_From_double(static_cast< double >(result)));
2543  return TCL_OK;
2544 fail:
2545  return TCL_ERROR;
2546 }
2547 
2548 
2549 SWIGINTERN int
2550 _wrap_a_unit_ratio__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2551  a_unit *arg1 = (a_unit *) 0 ;
2552  double arg2 ;
2553  void *argp1 = 0 ;
2554  int res1 = 0 ;
2555  double val2 ;
2556  int ecode2 = 0 ;
2557 
2558  if (SWIG_GetArgs(interp, objc, objv,"oo:a_unit_ratio self ratio ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
2559  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit, 0 | 0 );
2560  if (!SWIG_IsOK(res1)) {
2561  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_ratio" "', argument " "1"" of type '" "a_unit *""'");
2562  }
2563  arg1 = reinterpret_cast< a_unit * >(argp1);
2564  ecode2 = SWIG_AsVal_double SWIG_TCL_CALL_ARGS_2(objv[2], &val2);
2565  if (!SWIG_IsOK(ecode2)) {
2566  SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "a_unit_ratio" "', argument " "2"" of type '" "double""'");
2567  }
2568  arg2 = static_cast< double >(val2);
2569  (arg1)->ratio(arg2);
2570 
2571  return TCL_OK;
2572 fail:
2573  return TCL_ERROR;
2574 }
2575 
2576 
2577 SWIGINTERN int
2578 _wrap_a_unit_ratio(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2579  Tcl_Obj *CONST *argv = objv+1;
2580  int argc = objc-1;
2581  if (argc == 1) {
2582  int _v;
2583  void *vptr = 0;
2584  int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_a_unit, 0);
2585  _v = SWIG_CheckState(res);
2586  if (_v) {
2587  return _wrap_a_unit_ratio__SWIG_0(clientData, interp, objc, argv - 1);
2588  }
2589  }
2590  if (argc == 2) {
2591  int _v;
2592  void *vptr = 0;
2593  int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_a_unit, 0);
2594  _v = SWIG_CheckState(res);
2595  if (_v) {
2596  {
2597  int res = SWIG_AsVal_double SWIG_TCL_CALL_ARGS_2(argv[1], NULL);
2598  _v = SWIG_CheckState(res);
2599  }
2600  if (_v) {
2601  return _wrap_a_unit_ratio__SWIG_1(clientData, interp, objc, argv - 1);
2602  }
2603  }
2604  }
2605 
2606  Tcl_SetResult(interp,(char *) "Wrong number or type of arguments for overloaded function 'a_unit_ratio'.\n"
2607  " Possible C/C++ prototypes are:\n"
2608  " a_unit::ratio() const\n"
2609  " a_unit::ratio(double const)\n", TCL_STATIC);
2610  return TCL_ERROR;
2611 }
2612 
2613 
2614 SWIGINTERN int
2615 _wrap_delete_a_unit(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2616  a_unit *arg1 = (a_unit *) 0 ;
2617  void *argp1 = 0 ;
2618  int res1 = 0 ;
2619 
2620  if (SWIG_GetArgs(interp, objc, objv,"o:delete_a_unit self ",(void *)0) == TCL_ERROR) SWIG_fail;
2621  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit, SWIG_POINTER_DISOWN | 0 );
2622  if (!SWIG_IsOK(res1)) {
2623  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_a_unit" "', argument " "1"" of type '" "a_unit *""'");
2624  }
2625  arg1 = reinterpret_cast< a_unit * >(argp1);
2626  delete arg1;
2627 
2628  return TCL_OK;
2629 fail:
2630  return TCL_ERROR;
2631 }
2632 
2633 
2635 a_unit *arg1 = (a_unit *) obj;
2636 delete arg1;
2637 }
2639  {"classname", _wrap_a_unit_classname},
2640  {"name", _wrap_a_unit_name},
2641  {"short_name", _wrap_a_unit_short_name},
2642  {"ratio", _wrap_a_unit_ratio},
2643  {0,0}
2644 };
2646  {0,0,0}
2647 };
2648 static swig_class *swig_a_unit_bases[] = {0,0};
2649 static const char * swig_a_unit_base_names[] = {"a_unit_base *",0};
2651 SWIGINTERN int
2652 _wrap_new_a_unit_system(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2653  a_unit_system *result = 0 ;
2654 
2655  if (SWIG_GetArgs(interp, objc, objv,":new_a_unit_system ") == TCL_ERROR) SWIG_fail;
2656  result = (a_unit_system *)new a_unit_system();
2657  Tcl_SetObjResult(interp, SWIG_NewInstanceObj( SWIG_as_voidptr(result), SWIGTYPE_p_a_unit_system,0));
2658  return TCL_OK;
2659 fail:
2660  return TCL_ERROR;
2661 }
2662 
2663 
2664 SWIGINTERN int
2665 _wrap_a_unit_system_help(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2666  std::string result;
2667 
2668  if (SWIG_GetArgs(interp, objc, objv,":a_unit_system_help ") == TCL_ERROR) SWIG_fail;
2669  result = a_unit_system::help();
2670  Tcl_SetObjResult(interp,SWIG_From_std_string(static_cast< std::string >(result)));
2671  return TCL_OK;
2672 fail:
2673  return TCL_ERROR;
2674 }
2675 
2676 
2677 SWIGINTERN int
2678 _wrap_a_unit_system_name__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2679  a_unit_system *arg1 = (a_unit_system *) 0 ;
2680  std::string arg2 ;
2681  void *argp1 = 0 ;
2682  int res1 = 0 ;
2683 
2684  if (SWIG_GetArgs(interp, objc, objv,"oo:a_unit_system_name self name ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
2685  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, 0 | 0 );
2686  if (!SWIG_IsOK(res1)) {
2687  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_system_name" "', argument " "1"" of type '" "a_unit_system *""'");
2688  }
2689  arg1 = reinterpret_cast< a_unit_system * >(argp1);
2690  {
2691  std::string *ptr = (std::string *)0;
2692  int res = SWIG_AsPtr_std_string SWIG_TCL_CALL_ARGS_2(objv[2], &ptr);
2693  if (!SWIG_IsOK(res) || !ptr) {
2694  SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "a_unit_system_name" "', argument " "2"" of type '" "std::string const""'");
2695  }
2696  arg2 = *ptr;
2697  if (SWIG_IsNewObj(res)) delete ptr;
2698  }
2699  (arg1)->name(arg2);
2700 
2701  return TCL_OK;
2702 fail:
2703  return TCL_ERROR;
2704 }
2705 
2706 
2707 SWIGINTERN int
2708 _wrap_a_unit_system_name__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2709  a_unit_system *arg1 = (a_unit_system *) 0 ;
2710  void *argp1 = 0 ;
2711  int res1 = 0 ;
2712  std::string result;
2713 
2714  if (SWIG_GetArgs(interp, objc, objv,"o:a_unit_system_name self ",(void *)0) == TCL_ERROR) SWIG_fail;
2715  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, 0 | 0 );
2716  if (!SWIG_IsOK(res1)) {
2717  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_system_name" "', argument " "1"" of type '" "a_unit_system const *""'");
2718  }
2719  arg1 = reinterpret_cast< a_unit_system * >(argp1);
2720  result = ((a_unit_system const *)arg1)->name();
2721  Tcl_SetObjResult(interp,SWIG_From_std_string(static_cast< std::string >(result)));
2722  return TCL_OK;
2723 fail:
2724  return TCL_ERROR;
2725 }
2726 
2727 
2728 SWIGINTERN int
2729 _wrap_a_unit_system_name(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2730  Tcl_Obj *CONST *argv = objv+1;
2731  int argc = objc-1;
2732  if (argc == 1) {
2733  int _v;
2734  void *vptr = 0;
2735  int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_a_unit_system, 0);
2736  _v = SWIG_CheckState(res);
2737  if (_v) {
2738  return _wrap_a_unit_system_name__SWIG_1(clientData, interp, objc, argv - 1);
2739  }
2740  }
2741  if (argc == 2) {
2742  int _v;
2743  void *vptr = 0;
2744  int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_a_unit_system, 0);
2745  _v = SWIG_CheckState(res);
2746  if (_v) {
2747  int res = SWIG_AsPtr_std_string SWIG_TCL_CALL_ARGS_2(argv[1], (std::string**)(0));
2748  _v = SWIG_CheckState(res);
2749  if (_v) {
2750  return _wrap_a_unit_system_name__SWIG_0(clientData, interp, objc, argv - 1);
2751  }
2752  }
2753  }
2754 
2755  Tcl_SetResult(interp,(char *) "Wrong number or type of arguments for overloaded function 'a_unit_system_name'.\n"
2756  " Possible C/C++ prototypes are:\n"
2757  " a_unit_system::name(std::string const)\n"
2758  " a_unit_system::name() const\n", TCL_STATIC);
2759  return TCL_ERROR;
2760 }
2761 
2762 
2763 SWIGINTERN int
2764 _wrap_a_unit_system_decimals1__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2765  a_unit_system *arg1 = (a_unit_system *) 0 ;
2766  int arg2 ;
2767  void *argp1 = 0 ;
2768  int res1 = 0 ;
2769  int val2 ;
2770  int ecode2 = 0 ;
2771 
2772  if (SWIG_GetArgs(interp, objc, objv,"oo:a_unit_system_decimals1 self val ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
2773  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, 0 | 0 );
2774  if (!SWIG_IsOK(res1)) {
2775  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_system_decimals1" "', argument " "1"" of type '" "a_unit_system *""'");
2776  }
2777  arg1 = reinterpret_cast< a_unit_system * >(argp1);
2778  ecode2 = SWIG_AsVal_int SWIG_TCL_CALL_ARGS_2(objv[2], &val2);
2779  if (!SWIG_IsOK(ecode2)) {
2780  SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "a_unit_system_decimals1" "', argument " "2"" of type '" "int""'");
2781  }
2782  arg2 = static_cast< int >(val2);
2783  (arg1)->decimals1(arg2);
2784 
2785  return TCL_OK;
2786 fail:
2787  return TCL_ERROR;
2788 }
2789 
2790 
2791 SWIGINTERN int
2792 _wrap_a_unit_system_decimals1__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2793  a_unit_system *arg1 = (a_unit_system *) 0 ;
2794  void *argp1 = 0 ;
2795  int res1 = 0 ;
2796  int result;
2797 
2798  if (SWIG_GetArgs(interp, objc, objv,"o:a_unit_system_decimals1 self ",(void *)0) == TCL_ERROR) SWIG_fail;
2799  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, 0 | 0 );
2800  if (!SWIG_IsOK(res1)) {
2801  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_system_decimals1" "', argument " "1"" of type '" "a_unit_system const *""'");
2802  }
2803  arg1 = reinterpret_cast< a_unit_system * >(argp1);
2804  result = (int)((a_unit_system const *)arg1)->decimals1();
2805  Tcl_SetObjResult(interp,SWIG_From_int(static_cast< int >(result)));
2806  return TCL_OK;
2807 fail:
2808  return TCL_ERROR;
2809 }
2810 
2811 
2812 SWIGINTERN int
2813 _wrap_a_unit_system_decimals1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2814  Tcl_Obj *CONST *argv = objv+1;
2815  int argc = objc-1;
2816  if (argc == 1) {
2817  int _v;
2818  void *vptr = 0;
2819  int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_a_unit_system, 0);
2820  _v = SWIG_CheckState(res);
2821  if (_v) {
2822  return _wrap_a_unit_system_decimals1__SWIG_1(clientData, interp, objc, argv - 1);
2823  }
2824  }
2825  if (argc == 2) {
2826  int _v;
2827  void *vptr = 0;
2828  int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_a_unit_system, 0);
2829  _v = SWIG_CheckState(res);
2830  if (_v) {
2831  {
2832  int res = SWIG_AsVal_int SWIG_TCL_CALL_ARGS_2(argv[1], NULL);
2833  _v = SWIG_CheckState(res);
2834  }
2835  if (_v) {
2836  return _wrap_a_unit_system_decimals1__SWIG_0(clientData, interp, objc, argv - 1);
2837  }
2838  }
2839  }
2840 
2841  Tcl_SetResult(interp,(char *) "Wrong number or type of arguments for overloaded function 'a_unit_system_decimals1'.\n"
2842  " Possible C/C++ prototypes are:\n"
2843  " a_unit_system::decimals1(int const)\n"
2844  " a_unit_system::decimals1() const\n", TCL_STATIC);
2845  return TCL_ERROR;
2846 }
2847 
2848 
2849 SWIGINTERN int
2850 _wrap_a_unit_system_decimals2__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2851  a_unit_system *arg1 = (a_unit_system *) 0 ;
2852  int arg2 ;
2853  void *argp1 = 0 ;
2854  int res1 = 0 ;
2855  int val2 ;
2856  int ecode2 = 0 ;
2857 
2858  if (SWIG_GetArgs(interp, objc, objv,"oo:a_unit_system_decimals2 self val ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
2859  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, 0 | 0 );
2860  if (!SWIG_IsOK(res1)) {
2861  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_system_decimals2" "', argument " "1"" of type '" "a_unit_system *""'");
2862  }
2863  arg1 = reinterpret_cast< a_unit_system * >(argp1);
2864  ecode2 = SWIG_AsVal_int SWIG_TCL_CALL_ARGS_2(objv[2], &val2);
2865  if (!SWIG_IsOK(ecode2)) {
2866  SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "a_unit_system_decimals2" "', argument " "2"" of type '" "int""'");
2867  }
2868  arg2 = static_cast< int >(val2);
2869  (arg1)->decimals2(arg2);
2870 
2871  return TCL_OK;
2872 fail:
2873  return TCL_ERROR;
2874 }
2875 
2876 
2877 SWIGINTERN int
2878 _wrap_a_unit_system_decimals2__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2879  a_unit_system *arg1 = (a_unit_system *) 0 ;
2880  void *argp1 = 0 ;
2881  int res1 = 0 ;
2882  int result;
2883 
2884  if (SWIG_GetArgs(interp, objc, objv,"o:a_unit_system_decimals2 self ",(void *)0) == TCL_ERROR) SWIG_fail;
2885  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, 0 | 0 );
2886  if (!SWIG_IsOK(res1)) {
2887  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_system_decimals2" "', argument " "1"" of type '" "a_unit_system const *""'");
2888  }
2889  arg1 = reinterpret_cast< a_unit_system * >(argp1);
2890  result = (int)((a_unit_system const *)arg1)->decimals2();
2891  Tcl_SetObjResult(interp,SWIG_From_int(static_cast< int >(result)));
2892  return TCL_OK;
2893 fail:
2894  return TCL_ERROR;
2895 }
2896 
2897 
2898 SWIGINTERN int
2899 _wrap_a_unit_system_decimals2(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2900  Tcl_Obj *CONST *argv = objv+1;
2901  int argc = objc-1;
2902  if (argc == 1) {
2903  int _v;
2904  void *vptr = 0;
2905  int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_a_unit_system, 0);
2906  _v = SWIG_CheckState(res);
2907  if (_v) {
2908  return _wrap_a_unit_system_decimals2__SWIG_1(clientData, interp, objc, argv - 1);
2909  }
2910  }
2911  if (argc == 2) {
2912  int _v;
2913  void *vptr = 0;
2914  int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_a_unit_system, 0);
2915  _v = SWIG_CheckState(res);
2916  if (_v) {
2917  {
2918  int res = SWIG_AsVal_int SWIG_TCL_CALL_ARGS_2(argv[1], NULL);
2919  _v = SWIG_CheckState(res);
2920  }
2921  if (_v) {
2922  return _wrap_a_unit_system_decimals2__SWIG_0(clientData, interp, objc, argv - 1);
2923  }
2924  }
2925  }
2926 
2927  Tcl_SetResult(interp,(char *) "Wrong number or type of arguments for overloaded function 'a_unit_system_decimals2'.\n"
2928  " Possible C/C++ prototypes are:\n"
2929  " a_unit_system::decimals2(int const)\n"
2930  " a_unit_system::decimals2() const\n", TCL_STATIC);
2931  return TCL_ERROR;
2932 }
2933 
2934 
2935 SWIGINTERN int
2936 _wrap_a_unit_system_levels1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2937  a_unit_system *arg1 = (a_unit_system *) 0 ;
2938  void *argp1 = 0 ;
2939  int res1 = 0 ;
2940  int result;
2941 
2942  if (SWIG_GetArgs(interp, objc, objv,"o:a_unit_system_levels1 self ",(void *)0) == TCL_ERROR) SWIG_fail;
2943  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, 0 | 0 );
2944  if (!SWIG_IsOK(res1)) {
2945  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_system_levels1" "', argument " "1"" of type '" "a_unit_system const *""'");
2946  }
2947  arg1 = reinterpret_cast< a_unit_system * >(argp1);
2948  result = (int)((a_unit_system const *)arg1)->levels1();
2949  Tcl_SetObjResult(interp,SWIG_From_int(static_cast< int >(result)));
2950  return TCL_OK;
2951 fail:
2952  return TCL_ERROR;
2953 }
2954 
2955 
2956 SWIGINTERN int
2957 _wrap_a_unit_system_levels2(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2958  a_unit_system *arg1 = (a_unit_system *) 0 ;
2959  void *argp1 = 0 ;
2960  int res1 = 0 ;
2961  int result;
2962 
2963  if (SWIG_GetArgs(interp, objc, objv,"o:a_unit_system_levels2 self ",(void *)0) == TCL_ERROR) SWIG_fail;
2964  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, 0 | 0 );
2965  if (!SWIG_IsOK(res1)) {
2966  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_system_levels2" "', argument " "1"" of type '" "a_unit_system const *""'");
2967  }
2968  arg1 = reinterpret_cast< a_unit_system * >(argp1);
2969  result = (int)((a_unit_system const *)arg1)->levels2();
2970  Tcl_SetObjResult(interp,SWIG_From_int(static_cast< int >(result)));
2971  return TCL_OK;
2972 fail:
2973  return TCL_ERROR;
2974 }
2975 
2976 
2977 SWIGINTERN int
2978 _wrap_a_unit_system_addlevel1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
2979  a_unit_system *arg1 = (a_unit_system *) 0 ;
2980  a_unit *arg2 = 0 ;
2981  void *argp1 = 0 ;
2982  int res1 = 0 ;
2983  void *argp2 = 0 ;
2984  int res2 = 0 ;
2985 
2986  if (SWIG_GetArgs(interp, objc, objv,"oo:a_unit_system_addlevel1 self u ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
2987  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, 0 | 0 );
2988  if (!SWIG_IsOK(res1)) {
2989  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_system_addlevel1" "', argument " "1"" of type '" "a_unit_system *""'");
2990  }
2991  arg1 = reinterpret_cast< a_unit_system * >(argp1);
2992  res2 = SWIG_ConvertPtr(objv[2], &argp2, SWIGTYPE_p_a_unit, 0 );
2993  if (!SWIG_IsOK(res2)) {
2994  SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "a_unit_system_addlevel1" "', argument " "2"" of type '" "a_unit &""'");
2995  }
2996  if (!argp2) {
2997  SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "a_unit_system_addlevel1" "', argument " "2"" of type '" "a_unit &""'");
2998  }
2999  arg2 = reinterpret_cast< a_unit * >(argp2);
3000  (arg1)->addlevel1(*arg2);
3001 
3002  return TCL_OK;
3003 fail:
3004  return TCL_ERROR;
3005 }
3006 
3007 
3008 SWIGINTERN int
3009 _wrap_a_unit_system_addlevel2(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
3010  a_unit_system *arg1 = (a_unit_system *) 0 ;
3011  a_unit *arg2 = 0 ;
3012  void *argp1 = 0 ;
3013  int res1 = 0 ;
3014  void *argp2 = 0 ;
3015  int res2 = 0 ;
3016 
3017  if (SWIG_GetArgs(interp, objc, objv,"oo:a_unit_system_addlevel2 self u ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
3018  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, 0 | 0 );
3019  if (!SWIG_IsOK(res1)) {
3020  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_system_addlevel2" "', argument " "1"" of type '" "a_unit_system *""'");
3021  }
3022  arg1 = reinterpret_cast< a_unit_system * >(argp1);
3023  res2 = SWIG_ConvertPtr(objv[2], &argp2, SWIGTYPE_p_a_unit, 0 );
3024  if (!SWIG_IsOK(res2)) {
3025  SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "a_unit_system_addlevel2" "', argument " "2"" of type '" "a_unit &""'");
3026  }
3027  if (!argp2) {
3028  SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "a_unit_system_addlevel2" "', argument " "2"" of type '" "a_unit &""'");
3029  }
3030  arg2 = reinterpret_cast< a_unit * >(argp2);
3031  (arg1)->addlevel2(*arg2);
3032 
3033  return TCL_OK;
3034 fail:
3035  return TCL_ERROR;
3036 }
3037 
3038 
3039 SWIGINTERN int
3040 _wrap_a_unit_system_level1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
3041  a_unit_system *arg1 = (a_unit_system *) 0 ;
3042  int arg2 ;
3043  void *argp1 = 0 ;
3044  int res1 = 0 ;
3045  int val2 ;
3046  int ecode2 = 0 ;
3047  a_unit *result = 0 ;
3048 
3049  if (SWIG_GetArgs(interp, objc, objv,"oo:a_unit_system_level1 self n ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
3050  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, 0 | 0 );
3051  if (!SWIG_IsOK(res1)) {
3052  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_system_level1" "', argument " "1"" of type '" "a_unit_system const *""'");
3053  }
3054  arg1 = reinterpret_cast< a_unit_system * >(argp1);
3055  ecode2 = SWIG_AsVal_int SWIG_TCL_CALL_ARGS_2(objv[2], &val2);
3056  if (!SWIG_IsOK(ecode2)) {
3057  SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "a_unit_system_level1" "', argument " "2"" of type '" "int""'");
3058  }
3059  arg2 = static_cast< int >(val2);
3060  result = (a_unit *)((a_unit_system const *)arg1)->level1(arg2);
3061  Tcl_SetObjResult(interp, SWIG_NewInstanceObj( SWIG_as_voidptr(result), SWIGTYPE_p_a_unit,0));
3062  return TCL_OK;
3063 fail:
3064  return TCL_ERROR;
3065 }
3066 
3067 
3068 SWIGINTERN int
3069 _wrap_a_unit_system_level2(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
3070  a_unit_system *arg1 = (a_unit_system *) 0 ;
3071  int arg2 ;
3072  void *argp1 = 0 ;
3073  int res1 = 0 ;
3074  int val2 ;
3075  int ecode2 = 0 ;
3076  a_unit *result = 0 ;
3077 
3078  if (SWIG_GetArgs(interp, objc, objv,"oo:a_unit_system_level2 self n ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
3079  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, 0 | 0 );
3080  if (!SWIG_IsOK(res1)) {
3081  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_system_level2" "', argument " "1"" of type '" "a_unit_system const *""'");
3082  }
3083  arg1 = reinterpret_cast< a_unit_system * >(argp1);
3084  ecode2 = SWIG_AsVal_int SWIG_TCL_CALL_ARGS_2(objv[2], &val2);
3085  if (!SWIG_IsOK(ecode2)) {
3086  SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "a_unit_system_level2" "', argument " "2"" of type '" "int""'");
3087  }
3088  arg2 = static_cast< int >(val2);
3089  result = (a_unit *)((a_unit_system const *)arg1)->level2(arg2);
3090  Tcl_SetObjResult(interp, SWIG_NewInstanceObj( SWIG_as_voidptr(result), SWIGTYPE_p_a_unit,0));
3091  return TCL_OK;
3092 fail:
3093  return TCL_ERROR;
3094 }
3095 
3096 
3097 SWIGINTERN int
3098 _wrap_a_unit_system_dim1__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
3099  a_unit_system *arg1 = (a_unit_system *) 0 ;
3100  double arg2 ;
3101  void *argp1 = 0 ;
3102  int res1 = 0 ;
3103  double val2 ;
3104  int ecode2 = 0 ;
3105  std::string result;
3106 
3107  if (SWIG_GetArgs(interp, objc, objv,"oo:a_unit_system_dim1 self v ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
3108  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, 0 | 0 );
3109  if (!SWIG_IsOK(res1)) {
3110  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_system_dim1" "', argument " "1"" of type '" "a_unit_system *""'");
3111  }
3112  arg1 = reinterpret_cast< a_unit_system * >(argp1);
3113  ecode2 = SWIG_AsVal_double SWIG_TCL_CALL_ARGS_2(objv[2], &val2);
3114  if (!SWIG_IsOK(ecode2)) {
3115  SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "a_unit_system_dim1" "', argument " "2"" of type '" "double""'");
3116  }
3117  arg2 = static_cast< double >(val2);
3118  result = (arg1)->dim1(arg2);
3119  Tcl_SetObjResult(interp,SWIG_From_std_string(static_cast< std::string >(result)));
3120  return TCL_OK;
3121 fail:
3122  return TCL_ERROR;
3123 }
3124 
3125 
3126 SWIGINTERN int
3127 _wrap_a_unit_system_dim1_det(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
3128  a_unit_system *arg1 = (a_unit_system *) 0 ;
3129  double arg2 ;
3130  void *argp1 = 0 ;
3131  int res1 = 0 ;
3132  double val2 ;
3133  int ecode2 = 0 ;
3134  std::string result;
3135 
3136  if (SWIG_GetArgs(interp, objc, objv,"oo:a_unit_system_dim1_det self v ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
3137  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, 0 | 0 );
3138  if (!SWIG_IsOK(res1)) {
3139  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_system_dim1_det" "', argument " "1"" of type '" "a_unit_system *""'");
3140  }
3141  arg1 = reinterpret_cast< a_unit_system * >(argp1);
3142  ecode2 = SWIG_AsVal_double SWIG_TCL_CALL_ARGS_2(objv[2], &val2);
3143  if (!SWIG_IsOK(ecode2)) {
3144  SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "a_unit_system_dim1_det" "', argument " "2"" of type '" "double""'");
3145  }
3146  arg2 = static_cast< double >(val2);
3147  result = (arg1)->dim1_det(arg2);
3148  Tcl_SetObjResult(interp,SWIG_From_std_string(static_cast< std::string >(result)));
3149  return TCL_OK;
3150 fail:
3151  return TCL_ERROR;
3152 }
3153 
3154 
3155 SWIGINTERN int
3156 _wrap_a_unit_system_dim2(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
3157  a_unit_system *arg1 = (a_unit_system *) 0 ;
3158  double arg2 ;
3159  void *argp1 = 0 ;
3160  int res1 = 0 ;
3161  double val2 ;
3162  int ecode2 = 0 ;
3163  std::string result;
3164 
3165  if (SWIG_GetArgs(interp, objc, objv,"oo:a_unit_system_dim2 self v ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
3166  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, 0 | 0 );
3167  if (!SWIG_IsOK(res1)) {
3168  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_system_dim2" "', argument " "1"" of type '" "a_unit_system *""'");
3169  }
3170  arg1 = reinterpret_cast< a_unit_system * >(argp1);
3171  ecode2 = SWIG_AsVal_double SWIG_TCL_CALL_ARGS_2(objv[2], &val2);
3172  if (!SWIG_IsOK(ecode2)) {
3173  SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "a_unit_system_dim2" "', argument " "2"" of type '" "double""'");
3174  }
3175  arg2 = static_cast< double >(val2);
3176  result = (arg1)->dim2(arg2);
3177  Tcl_SetObjResult(interp,SWIG_From_std_string(static_cast< std::string >(result)));
3178  return TCL_OK;
3179 fail:
3180  return TCL_ERROR;
3181 }
3182 
3183 
3184 SWIGINTERN int
3185 _wrap_a_unit_system_dim2_det(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
3186  a_unit_system *arg1 = (a_unit_system *) 0 ;
3187  double arg2 ;
3188  void *argp1 = 0 ;
3189  int res1 = 0 ;
3190  double val2 ;
3191  int ecode2 = 0 ;
3192  std::string result;
3193 
3194  if (SWIG_GetArgs(interp, objc, objv,"oo:a_unit_system_dim2_det self v ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
3195  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, 0 | 0 );
3196  if (!SWIG_IsOK(res1)) {
3197  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_system_dim2_det" "', argument " "1"" of type '" "a_unit_system *""'");
3198  }
3199  arg1 = reinterpret_cast< a_unit_system * >(argp1);
3200  ecode2 = SWIG_AsVal_double SWIG_TCL_CALL_ARGS_2(objv[2], &val2);
3201  if (!SWIG_IsOK(ecode2)) {
3202  SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "a_unit_system_dim2_det" "', argument " "2"" of type '" "double""'");
3203  }
3204  arg2 = static_cast< double >(val2);
3205  result = (arg1)->dim2_det(arg2);
3206  Tcl_SetObjResult(interp,SWIG_From_std_string(static_cast< std::string >(result)));
3207  return TCL_OK;
3208 fail:
3209  return TCL_ERROR;
3210 }
3211 
3212 
3213 SWIGINTERN int
3214 _wrap_a_unit_system_dim1__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
3215  a_unit_system *arg1 = (a_unit_system *) 0 ;
3216  a_point *arg2 = 0 ;
3217  void *argp1 = 0 ;
3218  int res1 = 0 ;
3219  void *argp2 ;
3220  int res2 = 0 ;
3221  std::string result;
3222 
3223  if (SWIG_GetArgs(interp, objc, objv,"oo:a_unit_system_dim1 self a_point const & ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
3224  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, 0 | 0 );
3225  if (!SWIG_IsOK(res1)) {
3226  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "a_unit_system_dim1" "', argument " "1"" of type '" "a_unit_system *""'");
3227  }
3228  arg1 = reinterpret_cast< a_unit_system * >(argp1);
3229  res2 = SWIG_ConvertPtr(objv[2], &argp2, SWIGTYPE_p_a_point, 0 );
3230  if (!SWIG_IsOK(res2)) {
3231  SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "a_unit_system_dim1" "', argument " "2"" of type '" "a_point const &""'");
3232  }
3233  if (!argp2) {
3234  SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "a_unit_system_dim1" "', argument " "2"" of type '" "a_point const &""'");
3235  }
3236  arg2 = reinterpret_cast< a_point * >(argp2);
3237  result = (arg1)->dim1((a_point const &)*arg2);
3238  Tcl_SetObjResult(interp,SWIG_From_std_string(static_cast< std::string >(result)));
3239  return TCL_OK;
3240 fail:
3241  return TCL_ERROR;
3242 }
3243 
3244 
3245 SWIGINTERN int
3246 _wrap_a_unit_system_dim1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
3247  Tcl_Obj *CONST *argv = objv+1;
3248  int argc = objc-1;
3249  if (argc == 2) {
3250  int _v;
3251  void *vptr = 0;
3252  int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_a_unit_system, 0);
3253  _v = SWIG_CheckState(res);
3254  if (_v) {
3255  void *vptr = 0;
3256  int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_a_point, SWIG_POINTER_NO_NULL);
3257  _v = SWIG_CheckState(res);
3258  if (_v) {
3259  return _wrap_a_unit_system_dim1__SWIG_1(clientData, interp, objc, argv - 1);
3260  }
3261  }
3262  }
3263  if (argc == 2) {
3264  int _v;
3265  void *vptr = 0;
3266  int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_a_unit_system, 0);
3267  _v = SWIG_CheckState(res);
3268  if (_v) {
3269  {
3270  int res = SWIG_AsVal_double SWIG_TCL_CALL_ARGS_2(argv[1], NULL);
3271  _v = SWIG_CheckState(res);
3272  }
3273  if (_v) {
3274  return _wrap_a_unit_system_dim1__SWIG_0(clientData, interp, objc, argv - 1);
3275  }
3276  }
3277  }
3278 
3279  Tcl_SetResult(interp,(char *) "Wrong number or type of arguments for overloaded function 'a_unit_system_dim1'.\n"
3280  " Possible C/C++ prototypes are:\n"
3281  " a_unit_system::dim1(double const)\n"
3282  " a_unit_system::dim1(a_point const &)\n", TCL_STATIC);
3283  return TCL_ERROR;
3284 }
3285 
3286 
3287 SWIGINTERN int
3288 _wrap_delete_a_unit_system(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
3289  a_unit_system *arg1 = (a_unit_system *) 0 ;
3290  void *argp1 = 0 ;
3291  int res1 = 0 ;
3292 
3293  if (SWIG_GetArgs(interp, objc, objv,"o:delete_a_unit_system self ",(void *)0) == TCL_ERROR) SWIG_fail;
3294  res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_a_unit_system, SWIG_POINTER_DISOWN | 0 );
3295  if (!SWIG_IsOK(res1)) {
3296  SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_a_unit_system" "', argument " "1"" of type '" "a_unit_system *""'");
3297  }
3298  arg1 = reinterpret_cast< a_unit_system * >(argp1);
3299  delete arg1;
3300 
3301  return TCL_OK;
3302 fail:
3303  return TCL_ERROR;
3304 }
3305 
3306 
3308 a_unit_system *arg1 = (a_unit_system *) obj;
3309 delete arg1;
3310 }
3312  {"name", _wrap_a_unit_system_name},
3313  {"decimals1", _wrap_a_unit_system_decimals1},
3314  {"decimals2", _wrap_a_unit_system_decimals2},
3315  {"levels1", _wrap_a_unit_system_levels1},
3316  {"levels2", _wrap_a_unit_system_levels2},
3317  {"addlevel1", _wrap_a_unit_system_addlevel1},
3318  {"addlevel2", _wrap_a_unit_system_addlevel2},
3319  {"level1", _wrap_a_unit_system_level1},
3320  {"level2", _wrap_a_unit_system_level2},
3321  {"dim1_det", _wrap_a_unit_system_dim1_det},
3322  {"dim2", _wrap_a_unit_system_dim2},
3323  {"dim2_det", _wrap_a_unit_system_dim2_det},
3324  {"dim1", _wrap_a_unit_system_dim1},
3325  {0,0}
3326 };
3328  {0,0,0}
3329 };
3331 static const char * swig_a_unit_system_base_names[] = {"a_unit_base *",0};
3333 
3335  { SWIG_prefix "a_base_classname", (swig_wrapper_func) _wrap_a_base_classname, NULL},
3336  { SWIG_prefix "a_base_help", (swig_wrapper_func) _wrap_a_base_help, NULL},
3337  { SWIG_prefix "a_base_small", (swig_wrapper_func) _wrap_a_base_small, NULL},
3338  { SWIG_prefix "a_base_print", (swig_wrapper_func) _wrap_a_base_print, NULL},
3339  { SWIG_prefix "new_a_base", (swig_wrapper_func) _wrap_new_a_base, NULL},
3340  { SWIG_prefix "delete_a_base", (swig_wrapper_func) _wrap_delete_a_base, NULL},
3342  { SWIG_prefix "a_unit_base_classname", (swig_wrapper_func) _wrap_a_unit_base_classname, NULL},
3343  { SWIG_prefix "a_unit_base_help", (swig_wrapper_func) _wrap_a_unit_base_help, NULL},
3344  { SWIG_prefix "a_unit_base_read", (swig_wrapper_func) _wrap_a_unit_base_read, NULL},
3345  { SWIG_prefix "a_unit_base_write", (swig_wrapper_func) _wrap_a_unit_base_write, NULL},
3346  { SWIG_prefix "new_a_unit_base", (swig_wrapper_func) _wrap_new_a_unit_base, NULL},
3347  { SWIG_prefix "delete_a_unit_base", (swig_wrapper_func) _wrap_delete_a_unit_base, NULL},
3349  { SWIG_prefix "new_a_unit", (swig_wrapper_func) _wrap_new_a_unit, NULL},
3350  { SWIG_prefix "a_unit_classname", (swig_wrapper_func) _wrap_a_unit_classname, NULL},
3351  { SWIG_prefix "a_unit_help", (swig_wrapper_func) _wrap_a_unit_help, NULL},
3352  { SWIG_prefix "a_unit_name", (swig_wrapper_func) _wrap_a_unit_name, NULL},
3353  { SWIG_prefix "a_unit_short_name", (swig_wrapper_func) _wrap_a_unit_short_name, NULL},
3354  { SWIG_prefix "a_unit_ratio", (swig_wrapper_func) _wrap_a_unit_ratio, NULL},
3355  { SWIG_prefix "delete_a_unit", (swig_wrapper_func) _wrap_delete_a_unit, NULL},
3357  { SWIG_prefix "new_a_unit_system", (swig_wrapper_func) _wrap_new_a_unit_system, NULL},
3358  { SWIG_prefix "a_unit_system_help", (swig_wrapper_func) _wrap_a_unit_system_help, NULL},
3359  { SWIG_prefix "a_unit_system_name", (swig_wrapper_func) _wrap_a_unit_system_name, NULL},
3360  { SWIG_prefix "a_unit_system_decimals1", (swig_wrapper_func) _wrap_a_unit_system_decimals1, NULL},
3361  { SWIG_prefix "a_unit_system_decimals2", (swig_wrapper_func) _wrap_a_unit_system_decimals2, NULL},
3362  { SWIG_prefix "a_unit_system_levels1", (swig_wrapper_func) _wrap_a_unit_system_levels1, NULL},
3363  { SWIG_prefix "a_unit_system_levels2", (swig_wrapper_func) _wrap_a_unit_system_levels2, NULL},
3364  { SWIG_prefix "a_unit_system_addlevel1", (swig_wrapper_func) _wrap_a_unit_system_addlevel1, NULL},
3365  { SWIG_prefix "a_unit_system_addlevel2", (swig_wrapper_func) _wrap_a_unit_system_addlevel2, NULL},
3366  { SWIG_prefix "a_unit_system_level1", (swig_wrapper_func) _wrap_a_unit_system_level1, NULL},
3367  { SWIG_prefix "a_unit_system_level2", (swig_wrapper_func) _wrap_a_unit_system_level2, NULL},
3368  { SWIG_prefix "a_unit_system_dim1_det", (swig_wrapper_func) _wrap_a_unit_system_dim1_det, NULL},
3369  { SWIG_prefix "a_unit_system_dim2", (swig_wrapper_func) _wrap_a_unit_system_dim2, NULL},
3370  { SWIG_prefix "a_unit_system_dim2_det", (swig_wrapper_func) _wrap_a_unit_system_dim2_det, NULL},
3371  { SWIG_prefix "a_unit_system_dim1", (swig_wrapper_func) _wrap_a_unit_system_dim1, NULL},
3372  { SWIG_prefix "delete_a_unit_system", (swig_wrapper_func) _wrap_delete_a_unit_system, NULL},
3374  {0, 0, 0}
3375 };
3376 
3378  {0,0,0,0}
3379 };
3380 
3382  {0,0,0,0,0,0}
3383 };
3384 
3385 /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */
3386 
3387 static void *_p_a_unitTo_p_a_base(void *x, int *SWIGUNUSEDPARM(newmemory)) {
3388  return (void *)((a_base *) (a_unit_base *) ((a_unit *) x));
3389 }
3390 static void *_p_a_unit_systemTo_p_a_base(void *x, int *SWIGUNUSEDPARM(newmemory)) {
3391  return (void *)((a_base *) (a_unit_base *) ((a_unit_system *) x));
3392 }
3393 static void *_p_a_unit_baseTo_p_a_base(void *x, int *SWIGUNUSEDPARM(newmemory)) {
3394  return (void *)((a_base *) ((a_unit_base *) x));
3395 }
3396 static void *_p_a_unitTo_p_a_unit_base(void *x, int *SWIGUNUSEDPARM(newmemory)) {
3397  return (void *)((a_unit_base *) ((a_unit *) x));
3398 }
3399 static void *_p_a_unit_systemTo_p_a_unit_base(void *x, int *SWIGUNUSEDPARM(newmemory)) {
3400  return (void *)((a_unit_base *) ((a_unit_system *) x));
3401 }
3402 static swig_type_info _swigt__p_a_base = {"_p_a_base", "a_base *", 0, 0, (void*)&_wrap_class_a_base, 0};
3403 static swig_type_info _swigt__p_a_point = {"_p_a_point", "a_point *", 0, 0, (void*)0, 0};
3404 static swig_type_info _swigt__p_a_unit = {"_p_a_unit", "a_unit *", 0, 0, (void*)&_wrap_class_a_unit, 0};
3405 static swig_type_info _swigt__p_a_unit_base = {"_p_a_unit_base", "a_unit_base *", 0, 0, (void*)&_wrap_class_a_unit_base, 0};
3406 static swig_type_info _swigt__p_a_unit_system = {"_p_a_unit_system", "a_unit_system *", 0, 0, (void*)&_wrap_class_a_unit_system, 0};
3407 static swig_type_info _swigt__p_char = {"_p_char", "char *", 0, 0, (void*)0, 0};
3408 
3415  &_swigt__p_char,
3416 };
3417 
3419 static swig_cast_info _swigc__p_a_point[] = { {&_swigt__p_a_point, 0, 0, 0},{0, 0, 0, 0}};
3420 static swig_cast_info _swigc__p_a_unit[] = { {&_swigt__p_a_unit, 0, 0, 0},{0, 0, 0, 0}};
3422 static swig_cast_info _swigc__p_a_unit_system[] = { {&_swigt__p_a_unit_system, 0, 0, 0},{0, 0, 0, 0}};
3423 static swig_cast_info _swigc__p_char[] = { {&_swigt__p_char, 0, 0, 0},{0, 0, 0, 0}};
3424 
3432 };
3433 
3434 
3435 /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (END) -------- */
3436 
3437 #ifdef __cplusplus
3438 }
3439 #endif
3440 /* -----------------------------------------------------------------------------
3441  * Type initialization:
3442  * This problem is tough by the requirement that no dynamic
3443  * memory is used. Also, since swig_type_info structures store pointers to
3444  * swig_cast_info structures and swig_cast_info structures store pointers back
3445  * to swig_type_info structures, we need some lookup code at initialization.
3446  * The idea is that swig generates all the structures that are needed.
3447  * The runtime then collects these partially filled structures.
3448  * The SWIG_InitializeModule function takes these initial arrays out of
3449  * swig_module, and does all the lookup, filling in the swig_module.types
3450  * array with the correct data and linking the correct swig_cast_info
3451  * structures together.
3452  *
3453  * The generated swig_type_info structures are assigned statically to an initial
3454  * array. We just loop through that array, and handle each type individually.
3455  * First we lookup if this type has been already loaded, and if so, use the
3456  * loaded structure instead of the generated one. Then we have to fill in the
3457  * cast linked list. The cast data is initially stored in something like a
3458  * two-dimensional array. Each row corresponds to a type (there are the same
3459  * number of rows as there are in the swig_type_initial array). Each entry in
3460  * a column is one of the swig_cast_info structures for that type.
3461  * The cast_initial array is actually an array of arrays, because each row has
3462  * a variable number of columns. So to actually build the cast linked list,
3463  * we find the array of casts associated with the type, and loop through it
3464  * adding the casts to the list. The one last trick we need to do is making
3465  * sure the type pointer in the swig_cast_info struct is correct.
3466  *
3467  * First off, we lookup the cast->type name to see if it is already loaded.
3468  * There are three cases to handle:
3469  * 1) If the cast->type has already been loaded AND the type we are adding
3470  * casting info to has not been loaded (it is in this module), THEN we
3471  * replace the cast->type pointer with the type pointer that has already
3472  * been loaded.
3473  * 2) If BOTH types (the one we are adding casting info to, and the
3474  * cast->type) are loaded, THEN the cast info has already been loaded by
3475  * the previous module so we just ignore it.
3476  * 3) Finally, if cast->type has not already been loaded, then we add that
3477  * swig_cast_info to the linked list (because the cast->type) pointer will
3478  * be correct.
3479  * ----------------------------------------------------------------------------- */
3480 
3481 #ifdef __cplusplus
3482 extern "C" {
3483 #if 0
3484 } /* c-mode */
3485 #endif
3486 #endif
3487 
3488 #if 0
3489 #define SWIGRUNTIME_DEBUG
3490 #endif
3491 
3492 
3493 SWIGRUNTIME void
3494 SWIG_InitializeModule(void *clientdata) {
3495  size_t i;
3496  swig_module_info *module_head, *iter;
3497  int init;
3498 
3499  /* check to see if the circular list has been setup, if not, set it up */
3500  if (swig_module.next==0) {
3501  /* Initialize the swig_module */
3505  init = 1;
3506  } else {
3507  init = 0;
3508  }
3509 
3510  /* Try and load any already created modules */
3511  module_head = SWIG_GetModule(clientdata);
3512  if (!module_head) {
3513  /* This is the first module loaded for this interpreter */
3514  /* so set the swig module into the interpreter */
3515  SWIG_SetModule(clientdata, &swig_module);
3516  } else {
3517  /* the interpreter has loaded a SWIG module, but has it loaded this one? */
3518  iter=module_head;
3519  do {
3520  if (iter==&swig_module) {
3521  /* Our module is already in the list, so there's nothing more to do. */
3522  return;
3523  }
3524  iter=iter->next;
3525  } while (iter!= module_head);
3526 
3527  /* otherwise we must add our module into the list */
3528  swig_module.next = module_head->next;
3529  module_head->next = &swig_module;
3530  }
3531 
3532  /* When multiple interpreters are used, a module could have already been initialized in
3533  a different interpreter, but not yet have a pointer in this interpreter.
3534  In this case, we do not want to continue adding types... everything should be
3535  set up already */
3536  if (init == 0) return;
3537 
3538  /* Now work on filling in swig_module.types */
3539 #ifdef SWIGRUNTIME_DEBUG
3540  printf("SWIG_InitializeModule: size %lu\n", (unsigned long)swig_module.size);
3541 #endif
3542  for (i = 0; i < swig_module.size; ++i) {
3543  swig_type_info *type = 0;
3544  swig_type_info *ret;
3545  swig_cast_info *cast;
3546 
3547 #ifdef SWIGRUNTIME_DEBUG
3548  printf("SWIG_InitializeModule: type %lu %s\n", (unsigned long)i, swig_module.type_initial[i]->name);
3549 #endif
3550 
3551  /* if there is another module already loaded */
3552  if (swig_module.next != &swig_module) {
3554  }
3555  if (type) {
3556  /* Overwrite clientdata field */
3557 #ifdef SWIGRUNTIME_DEBUG
3558  printf("SWIG_InitializeModule: found type %s\n", type->name);
3559 #endif
3562 #ifdef SWIGRUNTIME_DEBUG
3563  printf("SWIG_InitializeModule: found and overwrite type %s \n", type->name);
3564 #endif
3565  }
3566  } else {
3567  type = swig_module.type_initial[i];
3568  }
3569 
3570  /* Insert casting types */
3571  cast = swig_module.cast_initial[i];
3572  while (cast->type) {
3573  /* Don't need to add information already in the list */
3574  ret = 0;
3575 #ifdef SWIGRUNTIME_DEBUG
3576  printf("SWIG_InitializeModule: look cast %s\n", cast->type->name);
3577 #endif
3578  if (swig_module.next != &swig_module) {
3580 #ifdef SWIGRUNTIME_DEBUG
3581  if (ret) printf("SWIG_InitializeModule: found cast %s\n", ret->name);
3582 #endif
3583  }
3584  if (ret) {
3585  if (type == swig_module.type_initial[i]) {
3586 #ifdef SWIGRUNTIME_DEBUG
3587  printf("SWIG_InitializeModule: skip old type %s\n", ret->name);
3588 #endif
3589  cast->type = ret;
3590  ret = 0;
3591  } else {
3592  /* Check for casting already in the list */
3593  swig_cast_info *ocast = SWIG_TypeCheck(ret->name, type);
3594 #ifdef SWIGRUNTIME_DEBUG
3595  if (ocast) printf("SWIG_InitializeModule: skip old cast %s\n", ret->name);
3596 #endif
3597  if (!ocast) ret = 0;
3598  }
3599  }
3600 
3601  if (!ret) {
3602 #ifdef SWIGRUNTIME_DEBUG
3603  printf("SWIG_InitializeModule: adding cast %s\n", cast->type->name);
3604 #endif
3605  if (type->cast) {
3606  type->cast->prev = cast;
3607  cast->next = type->cast;
3608  }
3609  type->cast = cast;
3610  }
3611  cast++;
3612  }
3613  /* Set entry in modules->types array equal to the type */
3614  swig_module.types[i] = type;
3615  }
3616  swig_module.types[i] = 0;
3617 
3618 #ifdef SWIGRUNTIME_DEBUG
3619  printf("**** SWIG_InitializeModule: Cast List ******\n");
3620  for (i = 0; i < swig_module.size; ++i) {
3621  int j = 0;
3623  printf("SWIG_InitializeModule: type %lu %s\n", (unsigned long)i, swig_module.type_initial[i]->name);
3624  while (cast->type) {
3625  printf("SWIG_InitializeModule: cast type %s\n", cast->type->name);
3626  cast++;
3627  ++j;
3628  }
3629  printf("---- Total casts: %d\n",j);
3630  }
3631  printf("**** SWIG_InitializeModule: Cast List ******\n");
3632 #endif
3633 }
3634 
3635 /* This function will propagate the clientdata field of type to
3636 * any new swig_type_info structures that have been added into the list
3637 * of equivalent types. It is like calling
3638 * SWIG_TypeClientData(type, clientdata) a second time.
3639 */
3640 SWIGRUNTIME void
3642  size_t i;
3643  swig_cast_info *equiv;
3644  static int init_run = 0;
3645 
3646  if (init_run) return;
3647  init_run = 1;
3648 
3649  for (i = 0; i < swig_module.size; i++) {
3650  if (swig_module.types[i]->clientdata) {
3651  equiv = swig_module.types[i]->cast;
3652  while (equiv) {
3653  if (!equiv->converter) {
3654  if (equiv->type && !equiv->type->clientdata)
3656  }
3657  equiv = equiv->next;
3658  }
3659  }
3660  }
3661 }
3662 
3663 #ifdef __cplusplus
3664 #if 0
3665 {
3666  /* c-mode */
3667 #endif
3668 }
3669 #endif
3670 
3671 
3672 #ifdef __cplusplus
3673 extern "C" {
3674 #endif
3675 
3676  /* -----------------------------------------------------------------------------
3677  * constants/methods manipulation
3678  * ----------------------------------------------------------------------------- */
3679 
3680  /* Install Constants */
3681 
3682  SWIGINTERN void
3683  SWIG_Tcl_InstallConstants(Tcl_Interp *interp, swig_const_info constants[]) {
3684  size_t i;
3685  Tcl_Obj *obj;
3686 
3687  if (!swigconstTableinit) {
3688  Tcl_InitHashTable(&swigconstTable, TCL_STRING_KEYS);
3689  swigconstTableinit = 1;
3690  }
3691  for (i = 0; constants[i].type; i++) {
3692  switch(constants[i].type) {
3693  case SWIG_TCL_POINTER:
3694  obj = SWIG_NewPointerObj(constants[i].pvalue, *(constants[i]).ptype,0);
3695  break;
3696  case SWIG_TCL_BINARY:
3697  obj = SWIG_NewPackedObj(constants[i].pvalue, constants[i].lvalue, *(constants[i].ptype));
3698  break;
3699  default:
3700  obj = 0;
3701  break;
3702  }
3703  if (obj) {
3704  SWIG_Tcl_SetConstantObj(interp, constants[i].name, obj);
3705  }
3706  }
3707  }
3708 
3709  /* Create fast method lookup tables */
3710 
3711  SWIGINTERN void
3713  size_t i;
3714 
3715  for (i = 0; i < swig_module.size; ++i) {
3717  if (type->clientdata) {
3718  swig_class* klass = (swig_class*) type->clientdata;
3719  swig_method* meth;
3720  Tcl_InitHashTable(&(klass->hashtable), TCL_STRING_KEYS);
3721  for (meth = klass->methods; meth && meth->name; ++meth) {
3722  int newEntry;
3723  Tcl_HashEntry* hashentry = Tcl_CreateHashEntry(&(klass->hashtable), meth->name, &newEntry);
3724  Tcl_SetHashValue(hashentry, (ClientData)meth->method);
3725  }
3726  }
3727  }
3728  }
3729 
3730 #ifdef __cplusplus
3731 }
3732 #endif
3733 
3734 /* -----------------------------------------------------------------------------*
3735  * Partial Init method
3736  * -----------------------------------------------------------------------------*/
3737 
3738 SWIGEXPORT int SWIG_init(Tcl_Interp *interp) {
3739  size_t i;
3740  if (interp == 0) return TCL_ERROR;
3741 #ifdef USE_TCL_STUBS
3742  /* (char*) cast is required to avoid compiler warning/error for Tcl < 8.4. */
3743  if (Tcl_InitStubs(interp, (char*)SWIG_TCL_STUBS_VERSION, 0) == NULL) {
3744  return TCL_ERROR;
3745  }
3746 #endif
3747 #ifdef USE_TK_STUBS
3748  /* (char*) cast is required to avoid compiler warning/error. */
3749  if (Tk_InitStubs(interp, (char*)SWIG_TCL_STUBS_VERSION, 0) == NULL) {
3750  return TCL_ERROR;
3751  }
3752 #endif
3753 
3754  Tcl_PkgProvide(interp, (char*)SWIG_name, (char*)SWIG_version);
3755 
3756 #ifdef SWIG_namespace
3757  Tcl_Eval(interp, "namespace eval " SWIG_namespace " { }");
3758 #endif
3759 
3760  SWIG_InitializeModule((void *) interp);
3762 
3763  for (i = 0; swig_commands[i].name; i++) {
3764  Tcl_CreateObjCommand(interp, (char *) swig_commands[i].name, (swig_wrapper_func) swig_commands[i].wrapper,
3765  swig_commands[i].clientdata, NULL);
3766  }
3767  for (i = 0; swig_variables[i].name; i++) {
3768  Tcl_SetVar(interp, (char *) swig_variables[i].name, (char *) "", TCL_GLOBAL_ONLY);
3769  Tcl_TraceVar(interp, (char *) swig_variables[i].name, TCL_TRACE_READS | TCL_GLOBAL_ONLY,
3770  (Tcl_VarTraceProc *) swig_variables[i].get, (ClientData) swig_variables[i].addr);
3771  Tcl_TraceVar(interp, (char *) swig_variables[i].name, TCL_TRACE_WRITES | TCL_GLOBAL_ONLY,
3772  (Tcl_VarTraceProc *) swig_variables[i].set, (ClientData) swig_variables[i].addr);
3773  }
3774 
3777 
3778 
3779 
3780  printf("Points&forces a_module.\n");
3781  printf("Type a_unit_base_help for an introduction.\n");
3782 
3783  return TCL_OK;
3784 }
3785 SWIGEXPORT int A_unit_SafeInit(Tcl_Interp *interp) {
3786  return SWIG_init(interp);
3787 }
3788 
SWIGRUNTIME char * SWIG_PackData(char *c, void *ptr, size_t sz)
static swig_var_info swig_variables[]
SWIGINTERNINLINE Tcl_Obj * SWIG_From_std_string(const std::string &s)
static swig_cast_info * swig_cast_initial[]
SWIGRUNTIME int SWIG_Tcl_ObjectConstructor(ClientData clientData, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
static swig_class _wrap_class_a_unit_system
SWIGRUNTIME char * SWIG_PackVoidPtr(char *buff, void *ptr, const char *name, size_t bsz)
SWIGINTERN int _wrap_a_unit_system_name__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
static swig_class * swig_a_unit_base_bases[]
#define SWIG_MakePtr(c, ptr, ty, flags)
SWIGINTERN int _wrap_new_a_unit__SWIG_2(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGINTERN int _wrap_a_unit_base_help(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGINTERN void SWIG_Tcl_InstallConstants(Tcl_Interp *interp, swig_const_info constants[])
#define SWIG_TypeQuery(name)
static swig_const_info swig_constants[]
#define SWIGTYPE_p_a_unit
#define SWIG_SyntaxError
#define SWIG_ConvertPtr(oc, ptr, ty, flags)
#define SWIG_CheckState(r)
SWIGINTERN int _wrap_delete_a_unit_system(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGINTERN int _wrap_a_unit_system_name__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGINTERN void swig_delete_a_unit(void *obj)
SWIGRUNTIME void SWIG_Tcl_Acquire(void *ptr)
SWIGRUNTIME int SWIG_TypeEquiv(const char *nb, const char *tb)
SWIGINTERN std::string a_base_print(a_base *self)
static swig_class * swig_a_unit_system_bases[]
#define SWIG_BUFFER_SIZE
struct swig_instance swig_instance
#define SWIG_TypeError
SWIGINTERNINLINE void SWIG_Tcl_AddErrorMsg(Tcl_Interp *interp, const char *mesg)
SWIGINTERN void SWIG_Tcl_SetErrorMsg(Tcl_Interp *interp, const char *ctype, const char *mesg)
static void * _p_a_unit_baseTo_p_a_base(void *x, int *SWIGUNUSEDPARM(newmemory))
struct swig_cast_info swig_cast_info
#define SWIG_init
SWIGRUNTIME Tcl_Obj * SWIG_Tcl_NewPackedObj(void *ptr, int sz, swig_type_info *type)
SWIGRUNTIME int SWIG_Tcl_MethodCommand(ClientData clientData, Tcl_Interp *interp, int objc, Tcl_Obj *CONST _objv[])
SWIGINTERN int _wrap_a_unit_system_name(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGRUNTIME int SWIG_TypeNameComp(const char *f1, const char *l1, const char *f2, const char *l2)
SWIGINTERN int _wrap_a_unit_system_addlevel2(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGINTERN int _wrap_a_unit_name__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGINTERN int _wrap_a_unit_ratio__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGRUNTIMEINLINE void * SWIG_TypeCast(swig_cast_info *ty, void *ptr, int *newmemory)
#define SWIG_RuntimeError
#define SWIG_GetArgs
SWIGINTERN int _wrap_a_base_help(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
static swig_command_info swig_commands[]
SWIGINTERN int _wrap_a_base_small__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGINTERN int _wrap_a_unit_system_dim1_det(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
static swig_attribute swig_a_unit_system_attributes[]
SWIGINTERN int _wrap_new_a_unit_base(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
int(* swig_wrapper_func)(ClientData, Tcl_Interp *, int, Tcl_Obj *CONST[])
static swig_class _wrap_class_a_unit
SWIGINTERN const char * SWIG_Tcl_ErrorType(int code)
SWIGRUNTIME const char * SWIG_TypePrettyName(const swig_type_info *type)
SWIGINTERN void swig_delete_a_unit_base(void *obj)
static swig_method swig_a_base_methods[]
#define SWIGRUNTIME
SWIGINTERN int _wrap_new_a_unit__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
static swig_cast_info _swigc__p_a_unit_system[]
SWIGINTERN int SWIG_AsCharPtrAndSize(Tcl_Obj *obj, char **cptr, size_t *psize, int *alloc)
#define SWIG_version
#define SWIG_RUNTIME_VERSION
#define SWIGTYPE_p_a_unit_system
SWIGINTERN void SWIG_Tcl_SetErrorObj(Tcl_Interp *interp, const char *ctype, Tcl_Obj *obj)
#define SWIG_OLDOBJ
SWIGRUNTIME void SWIG_TypeClientData(swig_type_info *ti, void *clientdata)
static Tcl_HashTable swigconstTable
SWIGINTERN int _wrap_a_unit_system_decimals1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
#define SWIG_MethodCommand
#define SWIG_ValueError
SWIGRUNTIME int SWIG_Tcl_GetArgs(Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[], const char *fmt,...)
SWIGINTERNINLINE Tcl_Obj * SWIG_From_int(int value)
SWIGINTERN int _wrap_a_unit_system_levels2(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
#define SWIG_AddCast(r)
#define SWIG_IsNewObj(r)
#define SWIG_exception_fail(code, msg)
SWIGINTERN int _wrap_a_base_small(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
static swig_type_info _swigt__p_a_unit_system
SWIGRUNTIME swig_type_info * SWIG_TypeQueryModule(swig_module_info *start, swig_module_info *end, const char *name)
static swig_cast_info _swigc__p_a_base[]
#define SWIG_AttributeError
SWIGINTERN int _wrap_a_unit_base_classname(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGINTERN int _wrap_a_unit_system_dim2_det(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
static swig_module_info swig_module
SWIGINTERN int _wrap_a_base_small__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGINTERN int _wrap_a_unit_system_levels1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGINTERN int _wrap_a_unit_system_decimals2__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
#define SWIG_SetModule(clientdata, pointer)
SWIGINTERN int _wrap_a_unit_short_name(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGRUNTIMEINLINE const char * SWIG_TypeName(const swig_type_info *ty)
SWIGINTERN int _wrap_delete_a_unit(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
#define SWIGUNUSEDPARM(p)
SWIGINTERN int _wrap_new_a_base(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
struct swig_class swig_class
#define SWIG_as_voidptr(a)
#define SWIGUNUSED
static swig_method swig_a_unit_methods[]
SWIGINTERN void swig_delete_a_base(void *obj)
SWIGRUNTIME void SWIG_TypeNewClientData(swig_type_info *ti, void *clientdata)
SWIGRUNTIME void SWIG_Tcl_SetModule(Tcl_Interp *interp, swig_module_info *module)
SWIGRUNTIME int SWIG_TypeCmp(const char *nb, const char *tb)
SWIGRUNTIMEINLINE int SWIG_Tcl_ConvertPtr(Tcl_Interp *interp, Tcl_Obj *oc, void **ptr, swig_type_info *ty, int flags)
static const char * swig_a_unit_base_base_names[]
SWIGINTERN int _wrap_a_unit_ratio__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
struct swig_const_info swig_const_info
static swig_cast_info _swigc__p_a_unit[]
SWIGRUNTIME int SWIG_Tcl_Thisown(void *ptr)
SWIGRUNTIME void SWIG_InitializeModule(void *clientdata)
static swig_class * swig_a_unit_bases[]
SWIGRUNTIME const char * SWIG_UnpackData(const char *c, void *ptr, size_t sz)
SWIGINTERN int _wrap_a_unit_ratio(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
static swig_type_info * swig_types[7]
static swig_type_info _swigt__p_a_point
SWIGINTERN void SWIG_Tcl_SetConstantObj(Tcl_Interp *interp, const char *name, Tcl_Obj *obj)
SWIGINTERN int _wrap_a_unit_system_level1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGINTERN int _wrap_a_unit_name__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGRUNTIMEINLINE Tcl_Obj * SWIG_Tcl_NewPointerObj(void *ptr, swig_type_info *type, int flags)
static swig_cast_info _swigc__p_char[]
SWIGRUNTIME swig_cast_info * SWIG_TypeCheckStruct(swig_type_info *from, swig_type_info *ty)
SWIGINTERN int _wrap_a_unit_base_read(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGINTERN int _wrap_a_base_print(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
static swig_class _wrap_class_a_unit_base
static swig_type_info _swigt__p_a_unit
#define SWIGINTERN
SWIGINTERN int _wrap_a_unit_base_write(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
#define SWIG_From_double
#define SWIG_ArgError(r)
#define SWIG_NewPointerObj(ptr, type, flags)
#define SWIGTYPE_p_a_unit_base
#define SWIG_Thisown(ptr)
SWIGINTERN int _wrap_a_unit_system_dim2(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGRUNTIME const char * SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name)
SWIGINTERN int _wrap_delete_a_unit_base(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
void *(* swig_converter_func)(void *, int *)
#define SWIG_POINTER_NO_NULL
#define SWIG_IOError
SWIGRUNTIME Tcl_Obj * SWIG_Tcl_NewInstanceObj(Tcl_Interp *interp, void *thisvalue, swig_type_info *type, int flags)
#define SWIG_NullReferenceError
SWIGINTERN int _wrap_delete_a_base(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGEXPORT int A_unit_SafeInit(Tcl_Interp *interp)
static swig_method swig_a_unit_base_methods[]
#define SWIG_POINTER_DISOWN
struct swig_type_info swig_type_info
SWIGINTERN int _wrap_a_unit_system_decimals1__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGINTERN int _wrap_a_unit_classname(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGRUNTIME char * SWIG_Tcl_PointerTypeFromString(char *c)
SWIGINTERN int _wrap_a_unit_system_decimals2(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
static void * _p_a_unitTo_p_a_base(void *x, int *SWIGUNUSEDPARM(newmemory))
SWIGINTERN int _wrap_a_unit_name(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
#define SWIG_NEWOBJ
SWIGRUNTIME int SWIG_Tcl_Disown(void *ptr)
#define SWIG_ObjectDelete
#define SWIG_NewPackedObj(ptr, sz, type)
#define SWIG_GetModule(clientdata)
SWIGINTERN int _wrap_a_unit_system_dim1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
#define SWIG_fail
SWIGRUNTIME void SWIG_PropagateClientData(void)
SWIGINTERN int _wrap_a_unit_system_decimals2__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGRUNTIME swig_cast_info * SWIG_TypeCheck(const char *c, swig_type_info *ty)
static swig_cast_info _swigc__p_a_point[]
SWIGINTERN Tcl_Obj * SWIG_Tcl_GetConstantObj(const char *key)
SWIGINTERN int _wrap_a_unit_system_addlevel1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
#define SWIGTYPE_p_a_point
SWIGINTERNINLINE Tcl_Obj * SWIG_FromCharPtrAndSize(const char *carray, size_t size)
static swig_cast_info _swigc__p_a_unit_base[]
#define SWIG_TYPE_TABLE_NAME
static const char * swig_a_unit_base_names[]
SWIGRUNTIME swig_type_info * SWIG_MangledTypeQueryModule(swig_module_info *start, swig_module_info *end, const char *name)
SWIGINTERN int _wrap_a_base_classname(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGINTERN int _wrap_new_a_unit(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
#define SWIGTYPE_p_a_base
SWIGINTERN int _wrap_a_unit_system_help(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
static const char * swig_a_base_base_names[]
SWIGRUNTIME swig_module_info * SWIG_Tcl_GetModule(Tcl_Interp *interp)
struct swig_module_info swig_module_info
static swig_type_info _swigt__p_a_unit_base
#define SWIG_TCL_POINTER
static swig_class _wrap_class_a_base
#define SWIG_Acquire(ptr)
static const char * swig_a_unit_system_base_names[]
SWIGINTERN int _wrap_a_unit_short_name__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGRUNTIME void SWIG_Tcl_ObjectDelete(ClientData clientData)
#define SWIG_ERROR
#define SWIG_TCL_HASHTABLE_INIT
#define SWIG_name
SWIGRUNTIME int SWIG_Tcl_ConvertPacked(Tcl_Interp *SWIGUNUSEDPARM(interp), Tcl_Obj *obj, void *ptr, int sz, swig_type_info *ty)
#define SWIG_ObjectConstructor
static swig_type_info _swigt__p_a_base
#define SWIG_NewInstanceObj(thisvalue, type, flags)
#define SWIG_Disown(ptr)
static swig_type_info * swig_type_initial[]
static int swigconstTableinit
struct swig_attribute swig_attribute
void(* swig_delete_func)(ClientData)
SWIGRUNTIME Tcl_HashTable * SWIG_Tcl_ObjectTable(void)
SWIGINTERN int _wrap_a_unit_system_decimals1__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGRUNTIME int SWIG_Tcl_ConvertPtrFromString(Tcl_Interp *interp, const char *c, void **ptr, swig_type_info *ty, int flags)
SWIGRUNTIME swig_type_info * SWIG_TypeDynamicCast(swig_type_info *ty, void **ptr)
SWIGINTERN int _wrap_new_a_unit_system(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
#define SWIG_MemoryError
SWIGINTERN int _wrap_a_unit_system_dim1__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGRUNTIME const char * SWIG_UnpackVoidPtr(const char *c, void **ptr, const char *name)
#define SWIG_SystemError
#define SWIG_DivisionByZero
static swig_type_info _swigt__p_char
struct swig_method swig_method
#define SWIG_TCL_DECL_ARGS_2(arg1, arg2)
#define SWIG_OverflowError
#define SWIGEXPORT
#define SWIG_IsOK(r)
int(* swig_wrapper)(ClientData, Tcl_Interp *, int, Tcl_Obj *CONST[])
SWIGINTERNINLINE Tcl_Obj * SWIG_From_long(long value)
SWIGRUNTIME void SWIG_Tcl_MakePtr(char *c, void *ptr, swig_type_info *ty, int SWIGUNUSEDPARM(flags))
static void * _p_a_unit_systemTo_p_a_base(void *x, int *SWIGUNUSEDPARM(newmemory))
struct swig_type_info *(* swig_dycast_func)(void **)
#define SWIG_TCL_CALL_ARGS_2(arg1, arg2)
static void * _p_a_unitTo_p_a_unit_base(void *x, int *SWIGUNUSEDPARM(newmemory))
static swig_class * swig_a_base_bases[]
#define SWIG_IndexError
SWIGINTERN void SWIG_Tcl_InstallMethodLookupTables(void)
#define SWIG_TCL_STUBS_VERSION
#define SWIG_prefix
static void * _p_a_unit_systemTo_p_a_unit_base(void *x, int *SWIGUNUSEDPARM(newmemory))
SWIGINTERN void swig_delete_a_unit_system(void *obj)
SWIGINTERN int _wrap_new_a_unit__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
static swig_attribute swig_a_unit_attributes[]
SWIGINTERN int _wrap_a_unit_short_name__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
static swig_method swig_a_unit_system_methods[]
SWIGINTERN int _wrap_a_unit_system_dim1__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
#define SWIG_TCL_BINARY
static swig_attribute swig_a_unit_base_attributes[]
SWIGRUNTIME char * SWIG_PackDataName(char *buff, void *ptr, size_t sz, const char *name, size_t bsz)
#define SWIG_OK
#define SWIGINTERNINLINE
SWIGINTERN int _wrap_a_unit_system_level2(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
SWIGINTERN int _wrap_a_unit_help(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
static swig_attribute swig_a_base_attributes[]
#define SWIGRUNTIMEINLINE
Definition: a_base.h:28
static const std::string help()
Definition: a_base.cxx:21
static const std::string help()
Definition: a_unit_base.cxx:21
unit system
Definition: a_unit_system.h:34
static const std::string help()
void name(const std::string name)
Definition: a_unit_system.h:42
unit
Definition: a_unit.h:29
static const std::string help()
Definition: a_unit.cxx:6
std::string short_name() const
Definition: a_unit.h:38
std::string name() const
Definition: a_unit.h:36
char buf[256]
Definition: copy.h:17
int val
swig_type_info * type
struct swig_cast_info * prev
struct swig_cast_info * next
swig_converter_func converter
swig_method * methods
swig_type_info ** type
Tcl_HashTable hashtable
struct swig_class ** bases
swig_module_info * module
void(* destructor)(void *)
swig_wrapper constructor
swig_attribute * attributes
const char ** base_names
swig_type_info ** ptype
swig_type_info ** types
swig_cast_info ** cast_initial
swig_type_info ** type_initial
struct swig_module_info * next
swig_dycast_func dcast
struct swig_cast_info * cast