Advertisement
Guest User

ngspicemodule_wrap.c

a guest
Oct 16th, 2013
136
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 39.37 KB | None | 0 0
  1. /* ----------------------------------------------------------------------------
  2.  * This file was automatically generated by SWIG (http://www.swig.org).
  3.  * Version 2.0.11
  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. #define SWIGJAVA
  12.  
  13. /* -----------------------------------------------------------------------------
  14.  *  This section contains generic SWIG labels for method/variable
  15.  *  declarations/attributes, and other compiler dependent labels.
  16.  * ----------------------------------------------------------------------------- */
  17.  
  18. /* template workaround for compilers that cannot correctly implement the C++ standard */
  19. #ifndef SWIGTEMPLATEDISAMBIGUATOR
  20. # if defined(__SUNPRO_CC) && (__SUNPRO_CC <= 0x560)
  21. #  define SWIGTEMPLATEDISAMBIGUATOR template
  22. # elif defined(__HP_aCC)
  23. /* Needed even with `aCC -AA' when `aCC -V' reports HP ANSI C++ B3910B A.03.55 */
  24. /* If we find a maximum version that requires this, the test would be __HP_aCC <= 35500 for A.03.55 */
  25. #  define SWIGTEMPLATEDISAMBIGUATOR template
  26. # else
  27. #  define SWIGTEMPLATEDISAMBIGUATOR
  28. # endif
  29. #endif
  30.  
  31. /* inline attribute */
  32. #ifndef SWIGINLINE
  33. # if defined(__cplusplus) || (defined(__GNUC__) && !defined(__STRICT_ANSI__))
  34. #   define SWIGINLINE inline
  35. # else
  36. #   define SWIGINLINE
  37. # endif
  38. #endif
  39.  
  40. /* attribute recognised by some compilers to avoid 'unused' warnings */
  41. #ifndef SWIGUNUSED
  42. # if defined(__GNUC__)
  43. #   if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
  44. #     define SWIGUNUSED __attribute__ ((__unused__))
  45. #   else
  46. #     define SWIGUNUSED
  47. #   endif
  48. # elif defined(__ICC)
  49. #   define SWIGUNUSED __attribute__ ((__unused__))
  50. # else
  51. #   define SWIGUNUSED
  52. # endif
  53. #endif
  54.  
  55. #ifndef SWIG_MSC_UNSUPPRESS_4505
  56. # if defined(_MSC_VER)
  57. #   pragma warning(disable : 4505) /* unreferenced local function has been removed */
  58. # endif
  59. #endif
  60.  
  61. #ifndef SWIGUNUSEDPARM
  62. # ifdef __cplusplus
  63. #   define SWIGUNUSEDPARM(p)
  64. # else
  65. #   define SWIGUNUSEDPARM(p) p SWIGUNUSED
  66. # endif
  67. #endif
  68.  
  69. /* internal SWIG method */
  70. #ifndef SWIGINTERN
  71. # define SWIGINTERN static SWIGUNUSED
  72. #endif
  73.  
  74. /* internal inline SWIG method */
  75. #ifndef SWIGINTERNINLINE
  76. # define SWIGINTERNINLINE SWIGINTERN SWIGINLINE
  77. #endif
  78.  
  79. /* exporting methods */
  80. #if (__GNUC__ >= 4) || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)
  81. #  ifndef GCC_HASCLASSVISIBILITY
  82. #    define GCC_HASCLASSVISIBILITY
  83. #  endif
  84. #endif
  85.  
  86. #ifndef SWIGEXPORT
  87. # if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
  88. #   if defined(STATIC_LINKED)
  89. #     define SWIGEXPORT
  90. #   else
  91. #     define SWIGEXPORT __declspec(dllexport)
  92. #   endif
  93. # else
  94. #   if defined(__GNUC__) && defined(GCC_HASCLASSVISIBILITY)
  95. #     define SWIGEXPORT __attribute__ ((visibility("default")))
  96. #   else
  97. #     define SWIGEXPORT
  98. #   endif
  99. # endif
  100. #endif
  101.  
  102. /* calling conventions for Windows */
  103. #ifndef SWIGSTDCALL
  104. # if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
  105. #   define SWIGSTDCALL __stdcall
  106. # else
  107. #   define SWIGSTDCALL
  108. # endif
  109. #endif
  110.  
  111. /* Deal with Microsoft's attempt at deprecating C standard runtime functions */
  112. #if !defined(SWIG_NO_CRT_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_CRT_SECURE_NO_DEPRECATE)
  113. # define _CRT_SECURE_NO_DEPRECATE
  114. #endif
  115.  
  116. /* Deal with Microsoft's attempt at deprecating methods in the standard C++ library */
  117. #if !defined(SWIG_NO_SCL_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_SCL_SECURE_NO_DEPRECATE)
  118. # define _SCL_SECURE_NO_DEPRECATE
  119. #endif
  120.  
  121.  
  122.  
  123. /* Fix for jlong on some versions of gcc on Windows */
  124. #if defined(__GNUC__) && !defined(__INTEL_COMPILER)
  125.   typedef long long __int64;
  126. #endif
  127.  
  128. /* Fix for jlong on 64-bit x86 Solaris */
  129. #if defined(__x86_64)
  130. # ifdef _LP64
  131. #   undef _LP64
  132. # endif
  133. #endif
  134.  
  135. #include <jni.h>
  136. #include <stdlib.h>
  137. #include <string.h>
  138. #include <stdbool.h>
  139.  
  140. /* Support for throwing Java exceptions */
  141. typedef enum {
  142.   SWIG_JavaOutOfMemoryError = 1,
  143.   SWIG_JavaIOException,
  144.   SWIG_JavaRuntimeException,
  145.   SWIG_JavaIndexOutOfBoundsException,
  146.   SWIG_JavaArithmeticException,
  147.   SWIG_JavaIllegalArgumentException,
  148.   SWIG_JavaNullPointerException,
  149.   SWIG_JavaDirectorPureVirtual,
  150.   SWIG_JavaUnknownError
  151. } SWIG_JavaExceptionCodes;
  152.  
  153. typedef struct {
  154.   SWIG_JavaExceptionCodes code;
  155.   const char *java_exception;
  156. } SWIG_JavaExceptions_t;
  157.  
  158.  
  159. static void SWIGUNUSED SWIG_JavaThrowException(JNIEnv *jenv, SWIG_JavaExceptionCodes code, const char *msg) {
  160.   jclass excep;
  161.   static const SWIG_JavaExceptions_t java_exceptions[] = {
  162.     { SWIG_JavaOutOfMemoryError, "java/lang/OutOfMemoryError" },
  163.     { SWIG_JavaIOException, "java/io/IOException" },
  164.     { SWIG_JavaRuntimeException, "java/lang/RuntimeException" },
  165.     { SWIG_JavaIndexOutOfBoundsException, "java/lang/IndexOutOfBoundsException" },
  166.     { SWIG_JavaArithmeticException, "java/lang/ArithmeticException" },
  167.     { SWIG_JavaIllegalArgumentException, "java/lang/IllegalArgumentException" },
  168.     { SWIG_JavaNullPointerException, "java/lang/NullPointerException" },
  169.     { SWIG_JavaDirectorPureVirtual, "java/lang/RuntimeException" },
  170.     { SWIG_JavaUnknownError,  "java/lang/UnknownError" },
  171.     { (SWIG_JavaExceptionCodes)0,  "java/lang/UnknownError" }
  172.   };
  173.   const SWIG_JavaExceptions_t *except_ptr = java_exceptions;
  174.  
  175.   while (except_ptr->code != code && except_ptr->code)
  176.     except_ptr++;
  177.  
  178.   (*jenv)->ExceptionClear(jenv);
  179.   excep = (*jenv)->FindClass(jenv, except_ptr->java_exception);
  180.   if (excep)
  181.     (*jenv)->ThrowNew(jenv, excep, msg);
  182. }
  183.  
  184.  
  185. /* Contract support */
  186.  
  187. #define SWIG_contract_assert(nullreturn, expr, msg) if (!(expr)) {SWIG_JavaThrowException(jenv, SWIG_JavaIllegalArgumentException, msg); return nullreturn; } else
  188.  
  189. /* Includes the header in the wrapper code */
  190. //#include "include/ngspice/sharedspice.h"
  191. #include "ngspice/sharedspice.h"
  192.  
  193. #ifdef __cplusplus
  194. extern "C" {
  195. #endif
  196.  
  197. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_ngcomplex_1cx_1real_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jdouble jarg2) {
  198.   struct ngcomplex *arg1 = (struct ngcomplex *) 0 ;
  199.   double arg2 ;
  200.  
  201.   (void)jenv;
  202.   (void)jcls;
  203.   (void)jarg1_;
  204.   arg1 = *(struct ngcomplex **)&jarg1;
  205.   arg2 = (double)jarg2;
  206.   if (arg1) (arg1)->cx_real = arg2;
  207. }
  208.  
  209.  
  210. SWIGEXPORT jdouble JNICALL Java_com_testo_datte_NGSpiceModuleJNI_ngcomplex_1cx_1real_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  211.   jdouble jresult = 0 ;
  212.   struct ngcomplex *arg1 = (struct ngcomplex *) 0 ;
  213.   double result;
  214.  
  215.   (void)jenv;
  216.   (void)jcls;
  217.   (void)jarg1_;
  218.   arg1 = *(struct ngcomplex **)&jarg1;
  219.   result = (double) ((arg1)->cx_real);
  220.   jresult = (jdouble)result;
  221.   return jresult;
  222. }
  223.  
  224.  
  225. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_ngcomplex_1cx_1imag_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jdouble jarg2) {
  226.   struct ngcomplex *arg1 = (struct ngcomplex *) 0 ;
  227.   double arg2 ;
  228.  
  229.   (void)jenv;
  230.   (void)jcls;
  231.   (void)jarg1_;
  232.   arg1 = *(struct ngcomplex **)&jarg1;
  233.   arg2 = (double)jarg2;
  234.   if (arg1) (arg1)->cx_imag = arg2;
  235. }
  236.  
  237.  
  238. SWIGEXPORT jdouble JNICALL Java_com_testo_datte_NGSpiceModuleJNI_ngcomplex_1cx_1imag_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  239.   jdouble jresult = 0 ;
  240.   struct ngcomplex *arg1 = (struct ngcomplex *) 0 ;
  241.   double result;
  242.  
  243.   (void)jenv;
  244.   (void)jcls;
  245.   (void)jarg1_;
  246.   arg1 = *(struct ngcomplex **)&jarg1;
  247.   result = (double) ((arg1)->cx_imag);
  248.   jresult = (jdouble)result;
  249.   return jresult;
  250. }
  251.  
  252.  
  253. SWIGEXPORT jlong JNICALL Java_com_testo_datte_NGSpiceModuleJNI_new_1ngcomplex(JNIEnv *jenv, jclass jcls) {
  254.   jlong jresult = 0 ;
  255.   struct ngcomplex *result = 0 ;
  256.  
  257.   (void)jenv;
  258.   (void)jcls;
  259.   result = (struct ngcomplex *)calloc(1, sizeof(struct ngcomplex));
  260.   *(struct ngcomplex **)&jresult = result;
  261.   return jresult;
  262. }
  263.  
  264.  
  265. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_delete_1ngcomplex(JNIEnv *jenv, jclass jcls, jlong jarg1) {
  266.   struct ngcomplex *arg1 = (struct ngcomplex *) 0 ;
  267.  
  268.   (void)jenv;
  269.   (void)jcls;
  270.   arg1 = *(struct ngcomplex **)&jarg1;
  271.   free((char *) arg1);
  272. }
  273.  
  274.  
  275. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vector_1info_1v_1name_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jstring jarg2) {
  276.   struct vector_info *arg1 = (struct vector_info *) 0 ;
  277.   char *arg2 = (char *) 0 ;
  278.  
  279.   (void)jenv;
  280.   (void)jcls;
  281.   (void)jarg1_;
  282.   arg1 = *(struct vector_info **)&jarg1;
  283.   arg2 = 0;
  284.   if (jarg2) {
  285.     arg2 = (char *)(*jenv)->GetStringUTFChars(jenv, jarg2, 0);
  286.     if (!arg2) return ;
  287.   }
  288.   {
  289.     free(arg1->v_name);
  290.     if (arg2) {
  291.       arg1->v_name = (char *) malloc(strlen((const char *)arg2)+1);
  292.       strcpy((char *)arg1->v_name, (const char *)arg2);
  293.     } else {
  294.       arg1->v_name = 0;
  295.     }
  296.   }
  297.   if (arg2) (*jenv)->ReleaseStringUTFChars(jenv, jarg2, (const char *)arg2);
  298. }
  299.  
  300.  
  301. SWIGEXPORT jstring JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vector_1info_1v_1name_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  302.   jstring jresult = 0 ;
  303.   struct vector_info *arg1 = (struct vector_info *) 0 ;
  304.   char *result = 0 ;
  305.  
  306.   (void)jenv;
  307.   (void)jcls;
  308.   (void)jarg1_;
  309.   arg1 = *(struct vector_info **)&jarg1;
  310.   result = (char *) ((arg1)->v_name);
  311.   if (result) jresult = (*jenv)->NewStringUTF(jenv, (const char *)result);
  312.   return jresult;
  313. }
  314.  
  315.  
  316. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vector_1info_1v_1type_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jint jarg2) {
  317.   struct vector_info *arg1 = (struct vector_info *) 0 ;
  318.   int arg2 ;
  319.  
  320.   (void)jenv;
  321.   (void)jcls;
  322.   (void)jarg1_;
  323.   arg1 = *(struct vector_info **)&jarg1;
  324.   arg2 = (int)jarg2;
  325.   if (arg1) (arg1)->v_type = arg2;
  326. }
  327.  
  328.  
  329. SWIGEXPORT jint JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vector_1info_1v_1type_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  330.   jint jresult = 0 ;
  331.   struct vector_info *arg1 = (struct vector_info *) 0 ;
  332.   int result;
  333.  
  334.   (void)jenv;
  335.   (void)jcls;
  336.   (void)jarg1_;
  337.   arg1 = *(struct vector_info **)&jarg1;
  338.   result = (int) ((arg1)->v_type);
  339.   jresult = (jint)result;
  340.   return jresult;
  341. }
  342.  
  343.  
  344. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vector_1info_1v_1flags_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jshort jarg2) {
  345.   struct vector_info *arg1 = (struct vector_info *) 0 ;
  346.   short arg2 ;
  347.  
  348.   (void)jenv;
  349.   (void)jcls;
  350.   (void)jarg1_;
  351.   arg1 = *(struct vector_info **)&jarg1;
  352.   arg2 = (short)jarg2;
  353.   if (arg1) (arg1)->v_flags = arg2;
  354. }
  355.  
  356.  
  357. SWIGEXPORT jshort JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vector_1info_1v_1flags_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  358.   jshort jresult = 0 ;
  359.   struct vector_info *arg1 = (struct vector_info *) 0 ;
  360.   short result;
  361.  
  362.   (void)jenv;
  363.   (void)jcls;
  364.   (void)jarg1_;
  365.   arg1 = *(struct vector_info **)&jarg1;
  366.   result = (short) ((arg1)->v_flags);
  367.   jresult = (jshort)result;
  368.   return jresult;
  369. }
  370.  
  371.  
  372. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vector_1info_1v_1realdata_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jlong jarg2) {
  373.   struct vector_info *arg1 = (struct vector_info *) 0 ;
  374.   double *arg2 = (double *) 0 ;
  375.  
  376.   (void)jenv;
  377.   (void)jcls;
  378.   (void)jarg1_;
  379.   arg1 = *(struct vector_info **)&jarg1;
  380.   arg2 = *(double **)&jarg2;
  381.   if (arg1) (arg1)->v_realdata = arg2;
  382. }
  383.  
  384.  
  385. SWIGEXPORT jlong JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vector_1info_1v_1realdata_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  386.   jlong jresult = 0 ;
  387.   struct vector_info *arg1 = (struct vector_info *) 0 ;
  388.   double *result = 0 ;
  389.  
  390.   (void)jenv;
  391.   (void)jcls;
  392.   (void)jarg1_;
  393.   arg1 = *(struct vector_info **)&jarg1;
  394.   result = (double *) ((arg1)->v_realdata);
  395.   *(double **)&jresult = result;
  396.   return jresult;
  397. }
  398.  
  399.  
  400. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vector_1info_1v_1compdata_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jlong jarg2, jobject jarg2_) {
  401.   struct vector_info *arg1 = (struct vector_info *) 0 ;
  402.   ngcomplex_t *arg2 = (ngcomplex_t *) 0 ;
  403.  
  404.   (void)jenv;
  405.   (void)jcls;
  406.   (void)jarg1_;
  407.   (void)jarg2_;
  408.   arg1 = *(struct vector_info **)&jarg1;
  409.   arg2 = *(ngcomplex_t **)&jarg2;
  410.   if (arg1) (arg1)->v_compdata = arg2;
  411. }
  412.  
  413.  
  414. SWIGEXPORT jlong JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vector_1info_1v_1compdata_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  415.   jlong jresult = 0 ;
  416.   struct vector_info *arg1 = (struct vector_info *) 0 ;
  417.   ngcomplex_t *result = 0 ;
  418.  
  419.   (void)jenv;
  420.   (void)jcls;
  421.   (void)jarg1_;
  422.   arg1 = *(struct vector_info **)&jarg1;
  423.   result = (ngcomplex_t *) ((arg1)->v_compdata);
  424.   *(ngcomplex_t **)&jresult = result;
  425.   return jresult;
  426. }
  427.  
  428.  
  429. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vector_1info_1v_1length_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jint jarg2) {
  430.   struct vector_info *arg1 = (struct vector_info *) 0 ;
  431.   int arg2 ;
  432.  
  433.   (void)jenv;
  434.   (void)jcls;
  435.   (void)jarg1_;
  436.   arg1 = *(struct vector_info **)&jarg1;
  437.   arg2 = (int)jarg2;
  438.   if (arg1) (arg1)->v_length = arg2;
  439. }
  440.  
  441.  
  442. SWIGEXPORT jint JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vector_1info_1v_1length_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  443.   jint jresult = 0 ;
  444.   struct vector_info *arg1 = (struct vector_info *) 0 ;
  445.   int result;
  446.  
  447.   (void)jenv;
  448.   (void)jcls;
  449.   (void)jarg1_;
  450.   arg1 = *(struct vector_info **)&jarg1;
  451.   result = (int) ((arg1)->v_length);
  452.   jresult = (jint)result;
  453.   return jresult;
  454. }
  455.  
  456.  
  457. SWIGEXPORT jlong JNICALL Java_com_testo_datte_NGSpiceModuleJNI_new_1vector_1info(JNIEnv *jenv, jclass jcls) {
  458.   jlong jresult = 0 ;
  459.   struct vector_info *result = 0 ;
  460.  
  461.   (void)jenv;
  462.   (void)jcls;
  463.   result = (struct vector_info *)calloc(1, sizeof(struct vector_info));
  464.   *(struct vector_info **)&jresult = result;
  465.   return jresult;
  466. }
  467.  
  468.  
  469. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_delete_1vector_1info(JNIEnv *jenv, jclass jcls, jlong jarg1) {
  470.   struct vector_info *arg1 = (struct vector_info *) 0 ;
  471.  
  472.   (void)jenv;
  473.   (void)jcls;
  474.   arg1 = *(struct vector_info **)&jarg1;
  475.   free((char *) arg1);
  476. }
  477.  
  478.  
  479. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecvalues_1name_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jstring jarg2) {
  480.   struct vecvalues *arg1 = (struct vecvalues *) 0 ;
  481.   char *arg2 = (char *) 0 ;
  482.  
  483.   (void)jenv;
  484.   (void)jcls;
  485.   (void)jarg1_;
  486.   arg1 = *(struct vecvalues **)&jarg1;
  487.   arg2 = 0;
  488.   if (jarg2) {
  489.     arg2 = (char *)(*jenv)->GetStringUTFChars(jenv, jarg2, 0);
  490.     if (!arg2) return ;
  491.   }
  492.   {
  493.     free(arg1->name);
  494.     if (arg2) {
  495.       arg1->name = (char *) malloc(strlen((const char *)arg2)+1);
  496.       strcpy((char *)arg1->name, (const char *)arg2);
  497.     } else {
  498.       arg1->name = 0;
  499.     }
  500.   }
  501.   if (arg2) (*jenv)->ReleaseStringUTFChars(jenv, jarg2, (const char *)arg2);
  502. }
  503.  
  504.  
  505. SWIGEXPORT jstring JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecvalues_1name_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  506.   jstring jresult = 0 ;
  507.   struct vecvalues *arg1 = (struct vecvalues *) 0 ;
  508.   char *result = 0 ;
  509.  
  510.   (void)jenv;
  511.   (void)jcls;
  512.   (void)jarg1_;
  513.   arg1 = *(struct vecvalues **)&jarg1;
  514.   result = (char *) ((arg1)->name);
  515.   if (result) jresult = (*jenv)->NewStringUTF(jenv, (const char *)result);
  516.   return jresult;
  517. }
  518.  
  519.  
  520. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecvalues_1creal_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jdouble jarg2) {
  521.   struct vecvalues *arg1 = (struct vecvalues *) 0 ;
  522.   double arg2 ;
  523.  
  524.   (void)jenv;
  525.   (void)jcls;
  526.   (void)jarg1_;
  527.   arg1 = *(struct vecvalues **)&jarg1;
  528.   arg2 = (double)jarg2;
  529.   if (arg1) (arg1)->creal = arg2;
  530. }
  531.  
  532.  
  533. SWIGEXPORT jdouble JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecvalues_1creal_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  534.   jdouble jresult = 0 ;
  535.   struct vecvalues *arg1 = (struct vecvalues *) 0 ;
  536.   double result;
  537.  
  538.   (void)jenv;
  539.   (void)jcls;
  540.   (void)jarg1_;
  541.   arg1 = *(struct vecvalues **)&jarg1;
  542.   result = (double) ((arg1)->creal);
  543.   jresult = (jdouble)result;
  544.   return jresult;
  545. }
  546.  
  547.  
  548. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecvalues_1cimag_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jdouble jarg2) {
  549.   struct vecvalues *arg1 = (struct vecvalues *) 0 ;
  550.   double arg2 ;
  551.  
  552.   (void)jenv;
  553.   (void)jcls;
  554.   (void)jarg1_;
  555.   arg1 = *(struct vecvalues **)&jarg1;
  556.   arg2 = (double)jarg2;
  557.   if (arg1) (arg1)->cimag = arg2;
  558. }
  559.  
  560.  
  561. SWIGEXPORT jdouble JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecvalues_1cimag_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  562.   jdouble jresult = 0 ;
  563.   struct vecvalues *arg1 = (struct vecvalues *) 0 ;
  564.   double result;
  565.  
  566.   (void)jenv;
  567.   (void)jcls;
  568.   (void)jarg1_;
  569.   arg1 = *(struct vecvalues **)&jarg1;
  570.   result = (double) ((arg1)->cimag);
  571.   jresult = (jdouble)result;
  572.   return jresult;
  573. }
  574.  
  575.  
  576. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecvalues_1is_1scale_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jboolean jarg2) {
  577.   struct vecvalues *arg1 = (struct vecvalues *) 0 ;
  578.   bool arg2 ;
  579.  
  580.   (void)jenv;
  581.   (void)jcls;
  582.   (void)jarg1_;
  583.   arg1 = *(struct vecvalues **)&jarg1;
  584.   arg2 = jarg2 ? true : false;
  585.   if (arg1) (arg1)->is_scale = arg2;
  586. }
  587.  
  588.  
  589. SWIGEXPORT jboolean JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecvalues_1is_1scale_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  590.   jboolean jresult = 0 ;
  591.   struct vecvalues *arg1 = (struct vecvalues *) 0 ;
  592.   bool result;
  593.  
  594.   (void)jenv;
  595.   (void)jcls;
  596.   (void)jarg1_;
  597.   arg1 = *(struct vecvalues **)&jarg1;
  598.   result = (bool) ((arg1)->is_scale);
  599.   jresult = (jboolean)result;
  600.   return jresult;
  601. }
  602.  
  603.  
  604. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecvalues_1is_1complex_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jboolean jarg2) {
  605.   struct vecvalues *arg1 = (struct vecvalues *) 0 ;
  606.   bool arg2 ;
  607.  
  608.   (void)jenv;
  609.   (void)jcls;
  610.   (void)jarg1_;
  611.   arg1 = *(struct vecvalues **)&jarg1;
  612.   arg2 = jarg2 ? true : false;
  613.   if (arg1) (arg1)->is_complex = arg2;
  614. }
  615.  
  616.  
  617. SWIGEXPORT jboolean JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecvalues_1is_1complex_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  618.   jboolean jresult = 0 ;
  619.   struct vecvalues *arg1 = (struct vecvalues *) 0 ;
  620.   bool result;
  621.  
  622.   (void)jenv;
  623.   (void)jcls;
  624.   (void)jarg1_;
  625.   arg1 = *(struct vecvalues **)&jarg1;
  626.   result = (bool) ((arg1)->is_complex);
  627.   jresult = (jboolean)result;
  628.   return jresult;
  629. }
  630.  
  631.  
  632. SWIGEXPORT jlong JNICALL Java_com_testo_datte_NGSpiceModuleJNI_new_1vecvalues(JNIEnv *jenv, jclass jcls) {
  633.   jlong jresult = 0 ;
  634.   struct vecvalues *result = 0 ;
  635.  
  636.   (void)jenv;
  637.   (void)jcls;
  638.   result = (struct vecvalues *)calloc(1, sizeof(struct vecvalues));
  639.   *(struct vecvalues **)&jresult = result;
  640.   return jresult;
  641. }
  642.  
  643.  
  644. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_delete_1vecvalues(JNIEnv *jenv, jclass jcls, jlong jarg1) {
  645.   struct vecvalues *arg1 = (struct vecvalues *) 0 ;
  646.  
  647.   (void)jenv;
  648.   (void)jcls;
  649.   arg1 = *(struct vecvalues **)&jarg1;
  650.   free((char *) arg1);
  651. }
  652.  
  653.  
  654. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecvaluesall_1veccount_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jint jarg2) {
  655.   struct vecvaluesall *arg1 = (struct vecvaluesall *) 0 ;
  656.   int arg2 ;
  657.  
  658.   (void)jenv;
  659.   (void)jcls;
  660.   (void)jarg1_;
  661.   arg1 = *(struct vecvaluesall **)&jarg1;
  662.   arg2 = (int)jarg2;
  663.   if (arg1) (arg1)->veccount = arg2;
  664. }
  665.  
  666.  
  667. SWIGEXPORT jint JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecvaluesall_1veccount_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  668.   jint jresult = 0 ;
  669.   struct vecvaluesall *arg1 = (struct vecvaluesall *) 0 ;
  670.   int result;
  671.  
  672.   (void)jenv;
  673.   (void)jcls;
  674.   (void)jarg1_;
  675.   arg1 = *(struct vecvaluesall **)&jarg1;
  676.   result = (int) ((arg1)->veccount);
  677.   jresult = (jint)result;
  678.   return jresult;
  679. }
  680.  
  681.  
  682. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecvaluesall_1vecindex_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jint jarg2) {
  683.   struct vecvaluesall *arg1 = (struct vecvaluesall *) 0 ;
  684.   int arg2 ;
  685.  
  686.   (void)jenv;
  687.   (void)jcls;
  688.   (void)jarg1_;
  689.   arg1 = *(struct vecvaluesall **)&jarg1;
  690.   arg2 = (int)jarg2;
  691.   if (arg1) (arg1)->vecindex = arg2;
  692. }
  693.  
  694.  
  695. SWIGEXPORT jint JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecvaluesall_1vecindex_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  696.   jint jresult = 0 ;
  697.   struct vecvaluesall *arg1 = (struct vecvaluesall *) 0 ;
  698.   int result;
  699.  
  700.   (void)jenv;
  701.   (void)jcls;
  702.   (void)jarg1_;
  703.   arg1 = *(struct vecvaluesall **)&jarg1;
  704.   result = (int) ((arg1)->vecindex);
  705.   jresult = (jint)result;
  706.   return jresult;
  707. }
  708.  
  709.  
  710. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecvaluesall_1vecsa_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jlong jarg2) {
  711.   struct vecvaluesall *arg1 = (struct vecvaluesall *) 0 ;
  712.   pvecvalues *arg2 = (pvecvalues *) 0 ;
  713.  
  714.   (void)jenv;
  715.   (void)jcls;
  716.   (void)jarg1_;
  717.   arg1 = *(struct vecvaluesall **)&jarg1;
  718.   arg2 = *(pvecvalues **)&jarg2;
  719.   if (arg1) (arg1)->vecsa = arg2;
  720. }
  721.  
  722.  
  723. SWIGEXPORT jlong JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecvaluesall_1vecsa_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  724.   jlong jresult = 0 ;
  725.   struct vecvaluesall *arg1 = (struct vecvaluesall *) 0 ;
  726.   pvecvalues *result = 0 ;
  727.  
  728.   (void)jenv;
  729.   (void)jcls;
  730.   (void)jarg1_;
  731.   arg1 = *(struct vecvaluesall **)&jarg1;
  732.   result = (pvecvalues *) ((arg1)->vecsa);
  733.   *(pvecvalues **)&jresult = result;
  734.   return jresult;
  735. }
  736.  
  737.  
  738. SWIGEXPORT jlong JNICALL Java_com_testo_datte_NGSpiceModuleJNI_new_1vecvaluesall(JNIEnv *jenv, jclass jcls) {
  739.   jlong jresult = 0 ;
  740.   struct vecvaluesall *result = 0 ;
  741.  
  742.   (void)jenv;
  743.   (void)jcls;
  744.   result = (struct vecvaluesall *)calloc(1, sizeof(struct vecvaluesall));
  745.   *(struct vecvaluesall **)&jresult = result;
  746.   return jresult;
  747. }
  748.  
  749.  
  750. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_delete_1vecvaluesall(JNIEnv *jenv, jclass jcls, jlong jarg1) {
  751.   struct vecvaluesall *arg1 = (struct vecvaluesall *) 0 ;
  752.  
  753.   (void)jenv;
  754.   (void)jcls;
  755.   arg1 = *(struct vecvaluesall **)&jarg1;
  756.   free((char *) arg1);
  757. }
  758.  
  759.  
  760. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfo_1number_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jint jarg2) {
  761.   struct vecinfo *arg1 = (struct vecinfo *) 0 ;
  762.   int arg2 ;
  763.  
  764.   (void)jenv;
  765.   (void)jcls;
  766.   (void)jarg1_;
  767.   arg1 = *(struct vecinfo **)&jarg1;
  768.   arg2 = (int)jarg2;
  769.   if (arg1) (arg1)->number = arg2;
  770. }
  771.  
  772.  
  773. SWIGEXPORT jint JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfo_1number_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  774.   jint jresult = 0 ;
  775.   struct vecinfo *arg1 = (struct vecinfo *) 0 ;
  776.   int result;
  777.  
  778.   (void)jenv;
  779.   (void)jcls;
  780.   (void)jarg1_;
  781.   arg1 = *(struct vecinfo **)&jarg1;
  782.   result = (int) ((arg1)->number);
  783.   jresult = (jint)result;
  784.   return jresult;
  785. }
  786.  
  787.  
  788. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfo_1vecname_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jstring jarg2) {
  789.   struct vecinfo *arg1 = (struct vecinfo *) 0 ;
  790.   char *arg2 = (char *) 0 ;
  791.  
  792.   (void)jenv;
  793.   (void)jcls;
  794.   (void)jarg1_;
  795.   arg1 = *(struct vecinfo **)&jarg1;
  796.   arg2 = 0;
  797.   if (jarg2) {
  798.     arg2 = (char *)(*jenv)->GetStringUTFChars(jenv, jarg2, 0);
  799.     if (!arg2) return ;
  800.   }
  801.   {
  802.     free(arg1->vecname);
  803.     if (arg2) {
  804.       arg1->vecname = (char *) malloc(strlen((const char *)arg2)+1);
  805.       strcpy((char *)arg1->vecname, (const char *)arg2);
  806.     } else {
  807.       arg1->vecname = 0;
  808.     }
  809.   }
  810.   if (arg2) (*jenv)->ReleaseStringUTFChars(jenv, jarg2, (const char *)arg2);
  811. }
  812.  
  813.  
  814. SWIGEXPORT jstring JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfo_1vecname_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  815.   jstring jresult = 0 ;
  816.   struct vecinfo *arg1 = (struct vecinfo *) 0 ;
  817.   char *result = 0 ;
  818.  
  819.   (void)jenv;
  820.   (void)jcls;
  821.   (void)jarg1_;
  822.   arg1 = *(struct vecinfo **)&jarg1;
  823.   result = (char *) ((arg1)->vecname);
  824.   if (result) jresult = (*jenv)->NewStringUTF(jenv, (const char *)result);
  825.   return jresult;
  826. }
  827.  
  828.  
  829. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfo_1is_1real_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jboolean jarg2) {
  830.   struct vecinfo *arg1 = (struct vecinfo *) 0 ;
  831.   bool arg2 ;
  832.  
  833.   (void)jenv;
  834.   (void)jcls;
  835.   (void)jarg1_;
  836.   arg1 = *(struct vecinfo **)&jarg1;
  837.   arg2 = jarg2 ? true : false;
  838.   if (arg1) (arg1)->is_real = arg2;
  839. }
  840.  
  841.  
  842. SWIGEXPORT jboolean JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfo_1is_1real_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  843.   jboolean jresult = 0 ;
  844.   struct vecinfo *arg1 = (struct vecinfo *) 0 ;
  845.   bool result;
  846.  
  847.   (void)jenv;
  848.   (void)jcls;
  849.   (void)jarg1_;
  850.   arg1 = *(struct vecinfo **)&jarg1;
  851.   result = (bool) ((arg1)->is_real);
  852.   jresult = (jboolean)result;
  853.   return jresult;
  854. }
  855.  
  856.  
  857. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfo_1pdvec_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jlong jarg2) {
  858.   struct vecinfo *arg1 = (struct vecinfo *) 0 ;
  859.   void *arg2 = (void *) 0 ;
  860.  
  861.   (void)jenv;
  862.   (void)jcls;
  863.   (void)jarg1_;
  864.   arg1 = *(struct vecinfo **)&jarg1;
  865.   arg2 = *(void **)&jarg2;
  866.   if (arg1) (arg1)->pdvec = arg2;
  867. }
  868.  
  869.  
  870. SWIGEXPORT jlong JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfo_1pdvec_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  871.   jlong jresult = 0 ;
  872.   struct vecinfo *arg1 = (struct vecinfo *) 0 ;
  873.   void *result = 0 ;
  874.  
  875.   (void)jenv;
  876.   (void)jcls;
  877.   (void)jarg1_;
  878.   arg1 = *(struct vecinfo **)&jarg1;
  879.   result = (void *) ((arg1)->pdvec);
  880.   *(void **)&jresult = result;
  881.   return jresult;
  882. }
  883.  
  884.  
  885. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfo_1pdvecscale_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jlong jarg2) {
  886.   struct vecinfo *arg1 = (struct vecinfo *) 0 ;
  887.   void *arg2 = (void *) 0 ;
  888.  
  889.   (void)jenv;
  890.   (void)jcls;
  891.   (void)jarg1_;
  892.   arg1 = *(struct vecinfo **)&jarg1;
  893.   arg2 = *(void **)&jarg2;
  894.   if (arg1) (arg1)->pdvecscale = arg2;
  895. }
  896.  
  897.  
  898. SWIGEXPORT jlong JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfo_1pdvecscale_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  899.   jlong jresult = 0 ;
  900.   struct vecinfo *arg1 = (struct vecinfo *) 0 ;
  901.   void *result = 0 ;
  902.  
  903.   (void)jenv;
  904.   (void)jcls;
  905.   (void)jarg1_;
  906.   arg1 = *(struct vecinfo **)&jarg1;
  907.   result = (void *) ((arg1)->pdvecscale);
  908.   *(void **)&jresult = result;
  909.   return jresult;
  910. }
  911.  
  912.  
  913. SWIGEXPORT jlong JNICALL Java_com_testo_datte_NGSpiceModuleJNI_new_1vecinfo(JNIEnv *jenv, jclass jcls) {
  914.   jlong jresult = 0 ;
  915.   struct vecinfo *result = 0 ;
  916.  
  917.   (void)jenv;
  918.   (void)jcls;
  919.   result = (struct vecinfo *)calloc(1, sizeof(struct vecinfo));
  920.   *(struct vecinfo **)&jresult = result;
  921.   return jresult;
  922. }
  923.  
  924.  
  925. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_delete_1vecinfo(JNIEnv *jenv, jclass jcls, jlong jarg1) {
  926.   struct vecinfo *arg1 = (struct vecinfo *) 0 ;
  927.  
  928.   (void)jenv;
  929.   (void)jcls;
  930.   arg1 = *(struct vecinfo **)&jarg1;
  931.   free((char *) arg1);
  932. }
  933.  
  934.  
  935. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfoall_1name_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jstring jarg2) {
  936.   struct vecinfoall *arg1 = (struct vecinfoall *) 0 ;
  937.   char *arg2 = (char *) 0 ;
  938.  
  939.   (void)jenv;
  940.   (void)jcls;
  941.   (void)jarg1_;
  942.   arg1 = *(struct vecinfoall **)&jarg1;
  943.   arg2 = 0;
  944.   if (jarg2) {
  945.     arg2 = (char *)(*jenv)->GetStringUTFChars(jenv, jarg2, 0);
  946.     if (!arg2) return ;
  947.   }
  948.   {
  949.     free(arg1->name);
  950.     if (arg2) {
  951.       arg1->name = (char *) malloc(strlen((const char *)arg2)+1);
  952.       strcpy((char *)arg1->name, (const char *)arg2);
  953.     } else {
  954.       arg1->name = 0;
  955.     }
  956.   }
  957.   if (arg2) (*jenv)->ReleaseStringUTFChars(jenv, jarg2, (const char *)arg2);
  958. }
  959.  
  960.  
  961. SWIGEXPORT jstring JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfoall_1name_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  962.   jstring jresult = 0 ;
  963.   struct vecinfoall *arg1 = (struct vecinfoall *) 0 ;
  964.   char *result = 0 ;
  965.  
  966.   (void)jenv;
  967.   (void)jcls;
  968.   (void)jarg1_;
  969.   arg1 = *(struct vecinfoall **)&jarg1;
  970.   result = (char *) ((arg1)->name);
  971.   if (result) jresult = (*jenv)->NewStringUTF(jenv, (const char *)result);
  972.   return jresult;
  973. }
  974.  
  975.  
  976. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfoall_1title_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jstring jarg2) {
  977.   struct vecinfoall *arg1 = (struct vecinfoall *) 0 ;
  978.   char *arg2 = (char *) 0 ;
  979.  
  980.   (void)jenv;
  981.   (void)jcls;
  982.   (void)jarg1_;
  983.   arg1 = *(struct vecinfoall **)&jarg1;
  984.   arg2 = 0;
  985.   if (jarg2) {
  986.     arg2 = (char *)(*jenv)->GetStringUTFChars(jenv, jarg2, 0);
  987.     if (!arg2) return ;
  988.   }
  989.   {
  990.     free(arg1->title);
  991.     if (arg2) {
  992.       arg1->title = (char *) malloc(strlen((const char *)arg2)+1);
  993.       strcpy((char *)arg1->title, (const char *)arg2);
  994.     } else {
  995.       arg1->title = 0;
  996.     }
  997.   }
  998.   if (arg2) (*jenv)->ReleaseStringUTFChars(jenv, jarg2, (const char *)arg2);
  999. }
  1000.  
  1001.  
  1002. SWIGEXPORT jstring JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfoall_1title_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  1003.   jstring jresult = 0 ;
  1004.   struct vecinfoall *arg1 = (struct vecinfoall *) 0 ;
  1005.   char *result = 0 ;
  1006.  
  1007.   (void)jenv;
  1008.   (void)jcls;
  1009.   (void)jarg1_;
  1010.   arg1 = *(struct vecinfoall **)&jarg1;
  1011.   result = (char *) ((arg1)->title);
  1012.   if (result) jresult = (*jenv)->NewStringUTF(jenv, (const char *)result);
  1013.   return jresult;
  1014. }
  1015.  
  1016.  
  1017. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfoall_1date_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jstring jarg2) {
  1018.   struct vecinfoall *arg1 = (struct vecinfoall *) 0 ;
  1019.   char *arg2 = (char *) 0 ;
  1020.  
  1021.   (void)jenv;
  1022.   (void)jcls;
  1023.   (void)jarg1_;
  1024.   arg1 = *(struct vecinfoall **)&jarg1;
  1025.   arg2 = 0;
  1026.   if (jarg2) {
  1027.     arg2 = (char *)(*jenv)->GetStringUTFChars(jenv, jarg2, 0);
  1028.     if (!arg2) return ;
  1029.   }
  1030.   {
  1031.     free(arg1->date);
  1032.     if (arg2) {
  1033.       arg1->date = (char *) malloc(strlen((const char *)arg2)+1);
  1034.       strcpy((char *)arg1->date, (const char *)arg2);
  1035.     } else {
  1036.       arg1->date = 0;
  1037.     }
  1038.   }
  1039.   if (arg2) (*jenv)->ReleaseStringUTFChars(jenv, jarg2, (const char *)arg2);
  1040. }
  1041.  
  1042.  
  1043. SWIGEXPORT jstring JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfoall_1date_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  1044.   jstring jresult = 0 ;
  1045.   struct vecinfoall *arg1 = (struct vecinfoall *) 0 ;
  1046.   char *result = 0 ;
  1047.  
  1048.   (void)jenv;
  1049.   (void)jcls;
  1050.   (void)jarg1_;
  1051.   arg1 = *(struct vecinfoall **)&jarg1;
  1052.   result = (char *) ((arg1)->date);
  1053.   if (result) jresult = (*jenv)->NewStringUTF(jenv, (const char *)result);
  1054.   return jresult;
  1055. }
  1056.  
  1057.  
  1058. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfoall_1type_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jstring jarg2) {
  1059.   struct vecinfoall *arg1 = (struct vecinfoall *) 0 ;
  1060.   char *arg2 = (char *) 0 ;
  1061.  
  1062.   (void)jenv;
  1063.   (void)jcls;
  1064.   (void)jarg1_;
  1065.   arg1 = *(struct vecinfoall **)&jarg1;
  1066.   arg2 = 0;
  1067.   if (jarg2) {
  1068.     arg2 = (char *)(*jenv)->GetStringUTFChars(jenv, jarg2, 0);
  1069.     if (!arg2) return ;
  1070.   }
  1071.   {
  1072.     free(arg1->type);
  1073.     if (arg2) {
  1074.       arg1->type = (char *) malloc(strlen((const char *)arg2)+1);
  1075.       strcpy((char *)arg1->type, (const char *)arg2);
  1076.     } else {
  1077.       arg1->type = 0;
  1078.     }
  1079.   }
  1080.   if (arg2) (*jenv)->ReleaseStringUTFChars(jenv, jarg2, (const char *)arg2);
  1081. }
  1082.  
  1083.  
  1084. SWIGEXPORT jstring JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfoall_1type_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  1085.   jstring jresult = 0 ;
  1086.   struct vecinfoall *arg1 = (struct vecinfoall *) 0 ;
  1087.   char *result = 0 ;
  1088.  
  1089.   (void)jenv;
  1090.   (void)jcls;
  1091.   (void)jarg1_;
  1092.   arg1 = *(struct vecinfoall **)&jarg1;
  1093.   result = (char *) ((arg1)->type);
  1094.   if (result) jresult = (*jenv)->NewStringUTF(jenv, (const char *)result);
  1095.   return jresult;
  1096. }
  1097.  
  1098.  
  1099. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfoall_1veccount_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jint jarg2) {
  1100.   struct vecinfoall *arg1 = (struct vecinfoall *) 0 ;
  1101.   int arg2 ;
  1102.  
  1103.   (void)jenv;
  1104.   (void)jcls;
  1105.   (void)jarg1_;
  1106.   arg1 = *(struct vecinfoall **)&jarg1;
  1107.   arg2 = (int)jarg2;
  1108.   if (arg1) (arg1)->veccount = arg2;
  1109. }
  1110.  
  1111.  
  1112. SWIGEXPORT jint JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfoall_1veccount_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  1113.   jint jresult = 0 ;
  1114.   struct vecinfoall *arg1 = (struct vecinfoall *) 0 ;
  1115.   int result;
  1116.  
  1117.   (void)jenv;
  1118.   (void)jcls;
  1119.   (void)jarg1_;
  1120.   arg1 = *(struct vecinfoall **)&jarg1;
  1121.   result = (int) ((arg1)->veccount);
  1122.   jresult = (jint)result;
  1123.   return jresult;
  1124. }
  1125.  
  1126.  
  1127. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfoall_1vecs_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_, jlong jarg2) {
  1128.   struct vecinfoall *arg1 = (struct vecinfoall *) 0 ;
  1129.   pvecinfo *arg2 = (pvecinfo *) 0 ;
  1130.  
  1131.   (void)jenv;
  1132.   (void)jcls;
  1133.   (void)jarg1_;
  1134.   arg1 = *(struct vecinfoall **)&jarg1;
  1135.   arg2 = *(pvecinfo **)&jarg2;
  1136.   if (arg1) (arg1)->vecs = arg2;
  1137. }
  1138.  
  1139.  
  1140. SWIGEXPORT jlong JNICALL Java_com_testo_datte_NGSpiceModuleJNI_vecinfoall_1vecs_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
  1141.   jlong jresult = 0 ;
  1142.   struct vecinfoall *arg1 = (struct vecinfoall *) 0 ;
  1143.   pvecinfo *result = 0 ;
  1144.  
  1145.   (void)jenv;
  1146.   (void)jcls;
  1147.   (void)jarg1_;
  1148.   arg1 = *(struct vecinfoall **)&jarg1;
  1149.   result = (pvecinfo *) ((arg1)->vecs);
  1150.   *(pvecinfo **)&jresult = result;
  1151.   return jresult;
  1152. }
  1153.  
  1154.  
  1155. SWIGEXPORT jlong JNICALL Java_com_testo_datte_NGSpiceModuleJNI_new_1vecinfoall(JNIEnv *jenv, jclass jcls) {
  1156.   jlong jresult = 0 ;
  1157.   struct vecinfoall *result = 0 ;
  1158.  
  1159.   (void)jenv;
  1160.   (void)jcls;
  1161.   result = (struct vecinfoall *)calloc(1, sizeof(struct vecinfoall));
  1162.   *(struct vecinfoall **)&jresult = result;
  1163.   return jresult;
  1164. }
  1165.  
  1166.  
  1167. SWIGEXPORT void JNICALL Java_com_testo_datte_NGSpiceModuleJNI_delete_1vecinfoall(JNIEnv *jenv, jclass jcls, jlong jarg1) {
  1168.   struct vecinfoall *arg1 = (struct vecinfoall *) 0 ;
  1169.  
  1170.   (void)jenv;
  1171.   (void)jcls;
  1172.   arg1 = *(struct vecinfoall **)&jarg1;
  1173.   free((char *) arg1);
  1174. }
  1175.  
  1176.  
  1177. SWIGEXPORT jint JNICALL Java_com_testo_datte_NGSpiceModuleJNI_ngSpice_1Init(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2, jlong jarg3, jlong jarg4, jlong jarg5, jlong jarg6, jlong jarg7) {
  1178.   jint jresult = 0 ;
  1179.   SendChar *arg1 = (SendChar *) 0 ;
  1180.   SendStat *arg2 = (SendStat *) 0 ;
  1181.   ControlledExit *arg3 = (ControlledExit *) 0 ;
  1182.   SendData *arg4 = (SendData *) 0 ;
  1183.   SendInitData *arg5 = (SendInitData *) 0 ;
  1184.   BGThreadRunning *arg6 = (BGThreadRunning *) 0 ;
  1185.   void *arg7 = (void *) 0 ;
  1186.   int result;
  1187.  
  1188.   (void)jenv;
  1189.   (void)jcls;
  1190.   arg1 = *(SendChar **)&jarg1;
  1191.   arg2 = *(SendStat **)&jarg2;
  1192.   arg3 = *(ControlledExit **)&jarg3;
  1193.   arg4 = *(SendData **)&jarg4;
  1194.   arg5 = *(SendInitData **)&jarg5;
  1195.   arg6 = *(BGThreadRunning **)&jarg6;
  1196.   arg7 = *(void **)&jarg7;
  1197.   result = (int)ngSpice_Init(arg1,arg2,arg3,arg4,arg5,arg6,arg7);
  1198.   jresult = (jint)result;
  1199.   return jresult;
  1200. }
  1201.  
  1202.  
  1203. SWIGEXPORT jint JNICALL Java_com_testo_datte_NGSpiceModuleJNI_ngSpice_1Init_1Sync(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2, jlong jarg3, jlong jarg4, jlong jarg5) {
  1204.   jint jresult = 0 ;
  1205.   GetVSRCData *arg1 = (GetVSRCData *) 0 ;
  1206.   GetISRCData *arg2 = (GetISRCData *) 0 ;
  1207.   GetSyncData *arg3 = (GetSyncData *) 0 ;
  1208.   int *arg4 = (int *) 0 ;
  1209.   void *arg5 = (void *) 0 ;
  1210.   int result;
  1211.  
  1212.   (void)jenv;
  1213.   (void)jcls;
  1214.   arg1 = *(GetVSRCData **)&jarg1;
  1215.   arg2 = *(GetISRCData **)&jarg2;
  1216.   arg3 = *(GetSyncData **)&jarg3;
  1217.   arg4 = *(int **)&jarg4;
  1218.   arg5 = *(void **)&jarg5;
  1219.   result = (int)ngSpice_Init_Sync(arg1,arg2,arg3,arg4,arg5);
  1220.   jresult = (jint)result;
  1221.   return jresult;
  1222. }
  1223.  
  1224.  
  1225. SWIGEXPORT jint JNICALL Java_com_testo_datte_NGSpiceModuleJNI_ngSpice_1Command(JNIEnv *jenv, jclass jcls, jstring jarg1) {
  1226.   jint jresult = 0 ;
  1227.   char *arg1 = (char *) 0 ;
  1228.   int result;
  1229.  
  1230.   (void)jenv;
  1231.   (void)jcls;
  1232.   arg1 = 0;
  1233.   if (jarg1) {
  1234.     arg1 = (char *)(*jenv)->GetStringUTFChars(jenv, jarg1, 0);
  1235.     if (!arg1) return 0;
  1236.   }
  1237.   result = (int)ngSpice_Command(arg1);
  1238.   jresult = (jint)result;
  1239.   if (arg1) (*jenv)->ReleaseStringUTFChars(jenv, jarg1, (const char *)arg1);
  1240.   return jresult;
  1241. }
  1242.  
  1243.  
  1244. SWIGEXPORT jlong JNICALL Java_com_testo_datte_NGSpiceModuleJNI_ngGet_1Vec_1Info(JNIEnv *jenv, jclass jcls, jstring jarg1) {
  1245.   jlong jresult = 0 ;
  1246.   char *arg1 = (char *) 0 ;
  1247.   pvector_info result;
  1248.  
  1249.   (void)jenv;
  1250.   (void)jcls;
  1251.   arg1 = 0;
  1252.   if (jarg1) {
  1253.     arg1 = (char *)(*jenv)->GetStringUTFChars(jenv, jarg1, 0);
  1254.     if (!arg1) return 0;
  1255.   }
  1256.   result = (pvector_info)ngGet_Vec_Info(arg1);
  1257.   *(pvector_info *)&jresult = result;
  1258.   if (arg1) (*jenv)->ReleaseStringUTFChars(jenv, jarg1, (const char *)arg1);
  1259.   return jresult;
  1260. }
  1261.  
  1262.  
  1263. SWIGEXPORT jint JNICALL Java_com_testo_datte_NGSpiceModuleJNI_ngSpice_1Circ(JNIEnv *jenv, jclass jcls, jlong jarg1) {
  1264.   jint jresult = 0 ;
  1265.   char **arg1 = (char **) 0 ;
  1266.   int result;
  1267.  
  1268.   (void)jenv;
  1269.   (void)jcls;
  1270.   arg1 = *(char ***)&jarg1;
  1271.   result = (int)ngSpice_Circ(arg1);
  1272.   jresult = (jint)result;
  1273.   return jresult;
  1274. }
  1275.  
  1276.  
  1277. SWIGEXPORT jstring JNICALL Java_com_testo_datte_NGSpiceModuleJNI_ngSpice_1CurPlot(JNIEnv *jenv, jclass jcls) {
  1278.   jstring jresult = 0 ;
  1279.   char *result = 0 ;
  1280.  
  1281.   (void)jenv;
  1282.   (void)jcls;
  1283.   result = (char *)ngSpice_CurPlot();
  1284.   if (result) jresult = (*jenv)->NewStringUTF(jenv, (const char *)result);
  1285.   return jresult;
  1286. }
  1287.  
  1288.  
  1289. SWIGEXPORT jlong JNICALL Java_com_testo_datte_NGSpiceModuleJNI_ngSpice_1AllPlots(JNIEnv *jenv, jclass jcls) {
  1290.   jlong jresult = 0 ;
  1291.   char **result = 0 ;
  1292.  
  1293.   (void)jenv;
  1294.   (void)jcls;
  1295.   result = (char **)ngSpice_AllPlots();
  1296.   *(char ***)&jresult = result;
  1297.   return jresult;
  1298. }
  1299.  
  1300.  
  1301. SWIGEXPORT jlong JNICALL Java_com_testo_datte_NGSpiceModuleJNI_ngSpice_1AllVecs(JNIEnv *jenv, jclass jcls, jstring jarg1) {
  1302.   jlong jresult = 0 ;
  1303.   char *arg1 = (char *) 0 ;
  1304.   char **result = 0 ;
  1305.  
  1306.   (void)jenv;
  1307.   (void)jcls;
  1308.   arg1 = 0;
  1309.   if (jarg1) {
  1310.     arg1 = (char *)(*jenv)->GetStringUTFChars(jenv, jarg1, 0);
  1311.     if (!arg1) return 0;
  1312.   }
  1313.   result = (char **)ngSpice_AllVecs(arg1);
  1314.   *(char ***)&jresult = result;
  1315.   if (arg1) (*jenv)->ReleaseStringUTFChars(jenv, jarg1, (const char *)arg1);
  1316.   return jresult;
  1317. }
  1318.  
  1319.  
  1320. SWIGEXPORT jboolean JNICALL Java_com_testo_datte_NGSpiceModuleJNI_ngSpice_1running(JNIEnv *jenv, jclass jcls) {
  1321.   jboolean jresult = 0 ;
  1322.   bool result;
  1323.  
  1324.   (void)jenv;
  1325.   (void)jcls;
  1326.   result = (bool)ngSpice_running();
  1327.   jresult = (jboolean)result;
  1328.   return jresult;
  1329. }
  1330.  
  1331.  
  1332. SWIGEXPORT jboolean JNICALL Java_com_testo_datte_NGSpiceModuleJNI_ngSpice_1SetBkpt(JNIEnv *jenv, jclass jcls, jdouble jarg1) {
  1333.   jboolean jresult = 0 ;
  1334.   double arg1 ;
  1335.   bool result;
  1336.  
  1337.   (void)jenv;
  1338.   (void)jcls;
  1339.   arg1 = (double)jarg1;
  1340.   result = (bool)ngSpice_SetBkpt(arg1);
  1341.   jresult = (jboolean)result;
  1342.   return jresult;
  1343. }
  1344.  
  1345.  
  1346. #ifdef __cplusplus
  1347. }
  1348. #endif
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement