/* ----------------------------------------------------------------------------
 * This file was automatically generated by SWIG (http://www.swig.org).
 * Version 1.3.25
 * 
 * This file is not intended to be easily readable and contains a number of 
 * coding conventions designed to improve portability and efficiency. Do not make
 * changes to this file unless you know what you are doing--modify the SWIG 
 * interface file instead. 
 * ----------------------------------------------------------------------------- */


#ifdef __cplusplus
template<class T> class SwigValueWrapper {
    T *tt;
public:
    SwigValueWrapper() : tt(0) { }
    SwigValueWrapper(const SwigValueWrapper<T>& rhs) : tt(new T(*rhs.tt)) { }
    SwigValueWrapper(const T& t) : tt(new T(t)) { }
    ~SwigValueWrapper() { delete tt; } 
    SwigValueWrapper& operator=(const T& t) { delete tt; tt = new T(t); return *this; }
    operator T&() const { return *tt; }
    T *operator&() { return tt; }
private:
    SwigValueWrapper& operator=(const SwigValueWrapper<T>& rhs);
};
#endif

/***********************************************************************
 *
 *  This section contains generic SWIG labels for method/variable
 *  declarations/attributes, and other compiler dependent labels.
 *
 ************************************************************************/

/* template workaround for compilers that cannot correctly implement the C++ standard */
#ifndef SWIGTEMPLATEDISAMBIGUATOR
#  if defined(__SUNPRO_CC) && (__SUNPRO_CC <= 0x560)
#    define SWIGTEMPLATEDISAMBIGUATOR template
#  else
#    define SWIGTEMPLATEDISAMBIGUATOR 
#  endif
#endif

/* inline attribute */
#ifndef SWIGINLINE
# if defined(__cplusplus) || (defined(__GNUC__) && !defined(__STRICT_ANSI__))
#   define SWIGINLINE inline
# else
#   define SWIGINLINE
# endif
#endif

/* attribute recognised by some compilers to avoid 'unused' warnings */
#ifndef SWIGUNUSED
# if defined(__GNUC__) || defined(__ICC)
#   define SWIGUNUSED __attribute__ ((unused)) 
# else
#   define SWIGUNUSED 
# endif
#endif

/* internal SWIG method */
#ifndef SWIGINTERN
# define SWIGINTERN static SWIGUNUSED
#endif

/* internal inline SWIG method */
#ifndef SWIGINTERNINLINE
# define SWIGINTERNINLINE SWIGINTERN SWIGINLINE
#endif

/* exporting methods for Windows DLLs */
#ifndef SWIGEXPORT
# if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
#   if defined(STATIC_LINKED)
#     define SWIGEXPORT
#   else
#     define SWIGEXPORT __declspec(dllexport)
#   endif
# else
#   define SWIGEXPORT
# endif
#endif

/* calling conventions for Windows */
#ifndef SWIGSTDCALL
# if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
#   define SWIGSTDCALL __stdcall
# else
#   define SWIGSTDCALL
# endif 
#endif



#if defined(__GNUC__)
    typedef long long __int64; /*For gcc on Windows */
#endif

/* fix for 'jlong' on x86_64 */
#if defined(__x86_64)
#ifdef _LP64 /* 64-bit Solaris */
#undef _LP64
#endif
#endif

#include <jni.h>
#include <stdlib.h>
#include <string.h>


/* Support for throwing Java exceptions */
typedef enum {
  SWIG_JavaOutOfMemoryError = 1, 
  SWIG_JavaIOException, 
  SWIG_JavaRuntimeException, 
  SWIG_JavaIndexOutOfBoundsException,
  SWIG_JavaArithmeticException,
  SWIG_JavaIllegalArgumentException,
  SWIG_JavaNullPointerException,
  SWIG_JavaDirectorPureVirtual,
  SWIG_JavaUnknownError
} SWIG_JavaExceptionCodes;

typedef struct {
  SWIG_JavaExceptionCodes code;
  const char *java_exception;
} SWIG_JavaExceptions_t;


static void SWIG_JavaThrowException(JNIEnv *jenv, SWIG_JavaExceptionCodes code, const char *msg) {
  jclass excep;
  static const SWIG_JavaExceptions_t java_exceptions[] = {
    { SWIG_JavaOutOfMemoryError, "java/lang/OutOfMemoryError" },
    { SWIG_JavaIOException, "java/io/IOException" },
    { SWIG_JavaRuntimeException, "java/lang/RuntimeException" },
    { SWIG_JavaIndexOutOfBoundsException, "java/lang/IndexOutOfBoundsException" },
    { SWIG_JavaArithmeticException, "java/lang/ArithmeticException" },
    { SWIG_JavaIllegalArgumentException, "java/lang/IllegalArgumentException" },
    { SWIG_JavaNullPointerException, "java/lang/NullPointerException" },
    { SWIG_JavaDirectorPureVirtual, "java/lang/RuntimeException" },
    { SWIG_JavaUnknownError,  "java/lang/UnknownError" },
    { (SWIG_JavaExceptionCodes)0,  "java/lang/UnknownError" } };
  const SWIG_JavaExceptions_t *except_ptr = java_exceptions;

  while (except_ptr->code != code && except_ptr->code)
    except_ptr++;

  jenv->ExceptionClear();
  excep = jenv->FindClass(except_ptr->java_exception);
  if (excep)
    jenv->ThrowNew(excep, msg);
}


/* Contract support */

#define SWIG_contract_assert(nullreturn, expr, msg) if (!(expr)) {SWIG_JavaThrowException(jenv, SWIG_JavaIllegalArgumentException, msg); return nullreturn; } else


/* clucene.i: the CLucene scripting interface. */

 //include clucene header
 #include "CLucene.h"

 //we need to fool the swig preprocessor, otherwise it expands these directives
 #define ___FILE___ __FILE__
 #define ___LINE___ __LINE__
 //#pragma SWIG nowarn=501,505,401
 
 #define _CATCHALL(null_value,dummy) catch (CLuceneError& e) { \
		char buf[250]; \
		_snprintf(buf,250,"%s in %s at %d",e.what(),___FILE___,___LINE___); \
		SWIG_exception(null_value,SWIG_RuntimeError,buf); \
		return null_value; \
    } catch (...) { \
		char buf[250]; \
		_snprintf(buf,250,"UNKNOWN exception in %s at %d",___FILE___,___LINE___); \
		SWIG_exception(null_value,SWIG_RuntimeError,buf); \
		return null_value; \
    }




#define  SWIG_MemoryError    1
#define  SWIG_IOError        2
#define  SWIG_RuntimeError   3
#define  SWIG_IndexError     4
#define  SWIG_TypeError      5
#define  SWIG_DivisionByZero 6
#define  SWIG_OverflowError  7
#define  SWIG_SyntaxError    8
#define  SWIG_ValueError     9
#define  SWIG_SystemError   10
#define  SWIG_UnknownError  99


SWIGINTERN void SWIG_JavaException(JNIEnv *jenv, int code, const char *msg) {
  SWIG_JavaExceptionCodes exception_code = SWIG_JavaUnknownError;
  switch(code) {
  case SWIG_MemoryError:
    exception_code = SWIG_JavaOutOfMemoryError;
    break;
  case SWIG_IOError:
    exception_code = SWIG_JavaIOException;
    break;
  case SWIG_SystemError:
  case SWIG_RuntimeError:
    exception_code = SWIG_JavaRuntimeException;
    break;
  case SWIG_OverflowError:
  case SWIG_IndexError:
    exception_code = SWIG_JavaIndexOutOfBoundsException;
    break;
  case SWIG_DivisionByZero:
    exception_code = SWIG_JavaArithmeticException;
    break;
  case SWIG_SyntaxError:
  case SWIG_ValueError:
  case SWIG_TypeError:
    exception_code = SWIG_JavaIllegalArgumentException;
    break;
  case SWIG_UnknownError:
  default:
    exception_code = SWIG_JavaUnknownError;
    break;
  }
  SWIG_JavaThrowException(jenv, exception_code, msg);
}
#define SWIG_exception(nullreturn, code, msg) { SWIG_JavaException(jenv, code, msg); return nullreturn; }


#include <stdexcept>


/* csharp/local_util.i: the CLucene scripting csharp interface helpers.
 *
 */


/* java/local_extra.i: CLucene scripting java interface additional code.
 */
 
//no easy support for arrays, so add our own support in
#include "clucene_arrays.h"
#include "local_arrays.h"


	






	#include "CLucene/document/Document.h"
	#include "CLucene/document/Field.h"
	#include "CLucene/document/DateField.h"


	#include "CLucene/store/Directory.h"
	#include "CLucene/store/FSDirectory.h"
	#include "CLucene/store/RAMDirectory.h"


	#include "CLucene/analysis/AnalysisHeader.h"
	#include "CLucene/analysis/Analyzers.h"


	#include "CLucene/index/DocumentWriter.h"
	#include "CLucene/index/SegmentMerger.h"
	#include "CLucene/index/TermVector.h"





	#include "CLucene/queryParser/QueryParser.h"


#ifdef __cplusplus
extern "C" {
#endif

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1_1CL_1p_1uint8_1tArray(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    _CL_p_uint8_tArray *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (_CL_p_uint8_tArray *)_CLNEW _CL_p_uint8_tArray();
            
        }_CATCHALL(0,);
    }
    *(_CL_p_uint8_tArray **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1_1CL_1p_1uint8_1tArray(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    _CL_p_uint8_tArray *arg1 = (_CL_p_uint8_tArray *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_uint8_tArray **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1uint8_1tArray_1length(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    _CL_p_uint8_tArray *arg1 = (_CL_p_uint8_tArray *) 0 ;
    int result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_uint8_tArray **)(void *)&jarg1; 
    {
        try {
            result = (int)(arg1)->length();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1uint8_1tArray_1init(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    _CL_p_uint8_tArray *arg1 = (_CL_p_uint8_tArray *) 0 ;
    int arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_uint8_tArray **)(void *)&jarg1; 
    arg2 = (int)jarg2; 
    {
        try {
            (arg1)->init(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jshort JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1uint8_1tArray_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jshort jresult = 0 ;
    _CL_p_uint8_tArray *arg1 = (_CL_p_uint8_tArray *) 0 ;
    int arg2 ;
    uint8_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_uint8_tArray **)(void *)&jarg1; 
    arg2 = (int)jarg2; 
    {
        try {
            result = ((_CL_p_uint8_tArray const *)arg1)->get(arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jshort)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1uint8_1tArray_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jshort jarg2, jint jarg3) {
    _CL_p_uint8_tArray *arg1 = (_CL_p_uint8_tArray *) 0 ;
    uint8_t arg2 ;
    int arg3 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_uint8_tArray **)(void *)&jarg1; 
    arg2 = (uint8_t)jarg2; 
    arg3 = (int)jarg3; 
    {
        try {
            (arg1)->set(arg2,arg3);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1_1CL_1p_1int32_1tArray(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    _CL_p_int32_tArray *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (_CL_p_int32_tArray *)_CLNEW _CL_p_int32_tArray();
            
        }_CATCHALL(0,);
    }
    *(_CL_p_int32_tArray **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1_1CL_1p_1int32_1tArray(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    _CL_p_int32_tArray *arg1 = (_CL_p_int32_tArray *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_int32_tArray **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1int32_1tArray_1length(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    _CL_p_int32_tArray *arg1 = (_CL_p_int32_tArray *) 0 ;
    int result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_int32_tArray **)(void *)&jarg1; 
    {
        try {
            result = (int)(arg1)->length();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1int32_1tArray_1init(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    _CL_p_int32_tArray *arg1 = (_CL_p_int32_tArray *) 0 ;
    int arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_int32_tArray **)(void *)&jarg1; 
    arg2 = (int)jarg2; 
    {
        try {
            (arg1)->init(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1int32_1tArray_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jint jresult = 0 ;
    _CL_p_int32_tArray *arg1 = (_CL_p_int32_tArray *) 0 ;
    int arg2 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_int32_tArray **)(void *)&jarg1; 
    arg2 = (int)jarg2; 
    {
        try {
            result = ((_CL_p_int32_tArray const *)arg1)->get(arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1int32_1tArray_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2, jint jarg3) {
    _CL_p_int32_tArray *arg1 = (_CL_p_int32_tArray *) 0 ;
    int32_t arg2 ;
    int arg3 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_int32_tArray **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    arg3 = (int)jarg3; 
    {
        try {
            (arg1)->set(arg2,arg3);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1_1CL_1p_1p_1lucene_1_1index_1_1IndexReaderArray(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    _CL_p_p_lucene__index__IndexReaderArray *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (_CL_p_p_lucene__index__IndexReaderArray *)_CLNEW _CL_p_p_lucene__index__IndexReaderArray();
            
        }_CATCHALL(0,);
    }
    *(_CL_p_p_lucene__index__IndexReaderArray **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1_1CL_1p_1p_1lucene_1_1index_1_1IndexReaderArray(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    _CL_p_p_lucene__index__IndexReaderArray *arg1 = (_CL_p_p_lucene__index__IndexReaderArray *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__index__IndexReaderArray **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1p_1lucene_1_1index_1_1IndexReaderArray_1length(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    _CL_p_p_lucene__index__IndexReaderArray *arg1 = (_CL_p_p_lucene__index__IndexReaderArray *) 0 ;
    int result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__index__IndexReaderArray **)(void *)&jarg1; 
    {
        try {
            result = (int)(arg1)->length();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1p_1lucene_1_1index_1_1IndexReaderArray_1init(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    _CL_p_p_lucene__index__IndexReaderArray *arg1 = (_CL_p_p_lucene__index__IndexReaderArray *) 0 ;
    int arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__index__IndexReaderArray **)(void *)&jarg1; 
    arg2 = (int)jarg2; 
    {
        try {
            (arg1)->init(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1p_1lucene_1_1index_1_1IndexReaderArray_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jlong jresult = 0 ;
    _CL_p_p_lucene__index__IndexReaderArray *arg1 = (_CL_p_p_lucene__index__IndexReaderArray *) 0 ;
    int arg2 ;
    lucene::index::IndexReader *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__index__IndexReaderArray **)(void *)&jarg1; 
    arg2 = (int)jarg2; 
    {
        try {
            result = (lucene::index::IndexReader *)((_CL_p_p_lucene__index__IndexReaderArray const *)arg1)->get(arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::index::IndexReader **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1p_1lucene_1_1index_1_1IndexReaderArray_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2, jint jarg3) {
    _CL_p_p_lucene__index__IndexReaderArray *arg1 = (_CL_p_p_lucene__index__IndexReaderArray *) 0 ;
    lucene::index::IndexReader *arg2 = (lucene::index::IndexReader *) 0 ;
    int arg3 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__index__IndexReaderArray **)(void *)&jarg1; 
    arg2 = *(lucene::index::IndexReader **)(void *)&jarg2; 
    arg3 = (int)jarg3; 
    {
        try {
            (arg1)->set(arg2,arg3);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1_1CL_1p_1p_1lucene_1_1index_1_1TermFreqVectorArray(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    _CL_p_p_lucene__index__TermFreqVectorArray *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (_CL_p_p_lucene__index__TermFreqVectorArray *)_CLNEW _CL_p_p_lucene__index__TermFreqVectorArray();
            
        }_CATCHALL(0,);
    }
    *(_CL_p_p_lucene__index__TermFreqVectorArray **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1_1CL_1p_1p_1lucene_1_1index_1_1TermFreqVectorArray(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    _CL_p_p_lucene__index__TermFreqVectorArray *arg1 = (_CL_p_p_lucene__index__TermFreqVectorArray *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__index__TermFreqVectorArray **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1p_1lucene_1_1index_1_1TermFreqVectorArray_1length(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    _CL_p_p_lucene__index__TermFreqVectorArray *arg1 = (_CL_p_p_lucene__index__TermFreqVectorArray *) 0 ;
    int result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__index__TermFreqVectorArray **)(void *)&jarg1; 
    {
        try {
            result = (int)(arg1)->length();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1p_1lucene_1_1index_1_1TermFreqVectorArray_1init(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    _CL_p_p_lucene__index__TermFreqVectorArray *arg1 = (_CL_p_p_lucene__index__TermFreqVectorArray *) 0 ;
    int arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__index__TermFreqVectorArray **)(void *)&jarg1; 
    arg2 = (int)jarg2; 
    {
        try {
            (arg1)->init(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1p_1lucene_1_1index_1_1TermFreqVectorArray_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jlong jresult = 0 ;
    _CL_p_p_lucene__index__TermFreqVectorArray *arg1 = (_CL_p_p_lucene__index__TermFreqVectorArray *) 0 ;
    int arg2 ;
    lucene::index::TermFreqVector *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__index__TermFreqVectorArray **)(void *)&jarg1; 
    arg2 = (int)jarg2; 
    {
        try {
            result = (lucene::index::TermFreqVector *)((_CL_p_p_lucene__index__TermFreqVectorArray const *)arg1)->get(arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::index::TermFreqVector **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1p_1lucene_1_1index_1_1TermFreqVectorArray_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2, jint jarg3) {
    _CL_p_p_lucene__index__TermFreqVectorArray *arg1 = (_CL_p_p_lucene__index__TermFreqVectorArray *) 0 ;
    lucene::index::TermFreqVector *arg2 = (lucene::index::TermFreqVector *) 0 ;
    int arg3 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__index__TermFreqVectorArray **)(void *)&jarg1; 
    arg2 = *(lucene::index::TermFreqVector **)(void *)&jarg2; 
    arg3 = (int)jarg3; 
    {
        try {
            (arg1)->set(arg2,arg3);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1_1CL_1p_1p_1lucene_1_1search_1_1SortFieldArray(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    _CL_p_p_lucene__search__SortFieldArray *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (_CL_p_p_lucene__search__SortFieldArray *)_CLNEW _CL_p_p_lucene__search__SortFieldArray();
            
        }_CATCHALL(0,);
    }
    *(_CL_p_p_lucene__search__SortFieldArray **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1_1CL_1p_1p_1lucene_1_1search_1_1SortFieldArray(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    _CL_p_p_lucene__search__SortFieldArray *arg1 = (_CL_p_p_lucene__search__SortFieldArray *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__search__SortFieldArray **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1p_1lucene_1_1search_1_1SortFieldArray_1length(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    _CL_p_p_lucene__search__SortFieldArray *arg1 = (_CL_p_p_lucene__search__SortFieldArray *) 0 ;
    int result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__search__SortFieldArray **)(void *)&jarg1; 
    {
        try {
            result = (int)(arg1)->length();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1p_1lucene_1_1search_1_1SortFieldArray_1init(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    _CL_p_p_lucene__search__SortFieldArray *arg1 = (_CL_p_p_lucene__search__SortFieldArray *) 0 ;
    int arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__search__SortFieldArray **)(void *)&jarg1; 
    arg2 = (int)jarg2; 
    {
        try {
            (arg1)->init(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1p_1lucene_1_1search_1_1SortFieldArray_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jlong jresult = 0 ;
    _CL_p_p_lucene__search__SortFieldArray *arg1 = (_CL_p_p_lucene__search__SortFieldArray *) 0 ;
    int arg2 ;
    lucene::search::SortField *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__search__SortFieldArray **)(void *)&jarg1; 
    arg2 = (int)jarg2; 
    {
        try {
            result = (lucene::search::SortField *)((_CL_p_p_lucene__search__SortFieldArray const *)arg1)->get(arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::SortField **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1p_1lucene_1_1search_1_1SortFieldArray_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2, jint jarg3) {
    _CL_p_p_lucene__search__SortFieldArray *arg1 = (_CL_p_p_lucene__search__SortFieldArray *) 0 ;
    lucene::search::SortField *arg2 = (lucene::search::SortField *) 0 ;
    int arg3 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__search__SortFieldArray **)(void *)&jarg1; 
    arg2 = *(lucene::search::SortField **)(void *)&jarg2; 
    arg3 = (int)jarg3; 
    {
        try {
            (arg1)->set(arg2,arg3);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1_1CL_1p_1p_1lucene_1_1search_1_1SearchableArray(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    _CL_p_p_lucene__search__SearchableArray *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (_CL_p_p_lucene__search__SearchableArray *)_CLNEW _CL_p_p_lucene__search__SearchableArray();
            
        }_CATCHALL(0,);
    }
    *(_CL_p_p_lucene__search__SearchableArray **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1_1CL_1p_1p_1lucene_1_1search_1_1SearchableArray(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    _CL_p_p_lucene__search__SearchableArray *arg1 = (_CL_p_p_lucene__search__SearchableArray *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__search__SearchableArray **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1p_1lucene_1_1search_1_1SearchableArray_1length(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    _CL_p_p_lucene__search__SearchableArray *arg1 = (_CL_p_p_lucene__search__SearchableArray *) 0 ;
    int result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__search__SearchableArray **)(void *)&jarg1; 
    {
        try {
            result = (int)(arg1)->length();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1p_1lucene_1_1search_1_1SearchableArray_1init(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    _CL_p_p_lucene__search__SearchableArray *arg1 = (_CL_p_p_lucene__search__SearchableArray *) 0 ;
    int arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__search__SearchableArray **)(void *)&jarg1; 
    arg2 = (int)jarg2; 
    {
        try {
            (arg1)->init(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1p_1lucene_1_1search_1_1SearchableArray_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jlong jresult = 0 ;
    _CL_p_p_lucene__search__SearchableArray *arg1 = (_CL_p_p_lucene__search__SearchableArray *) 0 ;
    int arg2 ;
    lucene::search::Searchable *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__search__SearchableArray **)(void *)&jarg1; 
    arg2 = (int)jarg2; 
    {
        try {
            result = (lucene::search::Searchable *)((_CL_p_p_lucene__search__SearchableArray const *)arg1)->get(arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Searchable **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI__1CL_1p_1p_1lucene_1_1search_1_1SearchableArray_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2, jint jarg3) {
    _CL_p_p_lucene__search__SearchableArray *arg1 = (_CL_p_p_lucene__search__SearchableArray *) 0 ;
    lucene::search::Searchable *arg2 = (lucene::search::Searchable *) 0 ;
    int arg3 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(_CL_p_p_lucene__search__SearchableArray **)(void *)&jarg1; 
    arg2 = *(lucene::search::Searchable **)(void *)&jarg2; 
    arg3 = (int)jarg3; 
    {
        try {
            (arg1)->set(arg2,arg3);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_lucene_1utf8towc(JNIEnv *jenv, jclass jcls, jlong jarg1, jstring jarg2, jint jarg3) {
    jint jresult = 0 ;
    wchar_t *arg1 = (wchar_t *) 0 ;
    char *arg2 = (char *) 0 ;
    long arg3 ;
    long result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(wchar_t **)(void *)&jarg1; 
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    arg3 = (long)jarg3; 
    {
        try {
            result = (long)lucene_utf8towc(arg1,(char const *)arg2,arg3);
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_lucene_1utf8towcs(JNIEnv *jenv, jclass jcls, jlong jarg1, jstring jarg2, jint jarg3) {
    jint jresult = 0 ;
    wchar_t *arg1 = (wchar_t *) 0 ;
    char *arg2 = (char *) 0 ;
    long arg3 ;
    long result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(wchar_t **)(void *)&jarg1; 
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    arg3 = (long)jarg3; 
    {
        try {
            result = (long)lucene_utf8towcs(arg1,(char const *)arg2,arg3);
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_lucene_1wctoutf8(JNIEnv *jenv, jclass jcls, jstring jarg1, jlong jarg2) {
    jint jresult = 0 ;
    char *arg1 = (char *) 0 ;
    wchar_t arg2 ;
    long result;
    wchar_t const *argp2 ;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    argp2 = *(wchar_t **)(void *)&jarg2; 
    if (!argp2) {
        SWIG_JavaThrowException(jenv, SWIG_JavaNullPointerException, "Attempt to dereference null wchar_t const");
        return 0;
    }
    arg2 = *argp2; 
    {
        try {
            result = (long)lucene_wctoutf8(arg1,arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_lucene_1wcstoutf8(JNIEnv *jenv, jclass jcls, jstring jarg1, jlong jarg2, jint jarg3) {
    jint jresult = 0 ;
    char *arg1 = (char *) 0 ;
    wchar_t *arg2 = (wchar_t *) 0 ;
    long arg3 ;
    long result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = *(wchar_t **)(void *)&jarg2; 
    arg3 = (long)jarg3; 
    {
        try {
            result = (long)lucene_wcstoutf8(arg1,(wchar_t const *)arg2,arg3);
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_get_1READER_1ENCODING_1UCS2(JNIEnv *jenv, jclass jcls) {
    jstring jresult = 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (char *) "UCS2_LITTLE";
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Reader_1close(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::util::Reader *arg1 = (lucene::util::Reader *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::util::Reader **)(void *)&jarg1; 
    {
        try {
            (arg1)->close();
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1Reader(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::util::Reader *arg1 = (lucene::util::Reader *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::util::Reader **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1StringReader(JNIEnv *jenv, jclass jcls, jstring jarg1) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    lucene::util::StringReader *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        try {
            arg1= lucenestrdup(arg1 );  	  result = (lucene::util::StringReader *)_CLNEW lucene::util::StringReader((char const *)arg1);
        }_CATCHALL(0,);   
    }
    *(lucene::util::StringReader **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1StringReader(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::util::StringReader *arg1 = (lucene::util::StringReader *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::util::StringReader **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1FileReader_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jstring jarg1, jstring jarg2, jint jarg3, jint jarg4) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    char *arg2 = (char *) 0 ;
    int32_t arg3 ;
    int32_t arg4 ;
    lucene::util::FileReader *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    arg3 = (int32_t)jarg3; 
    arg4 = (int32_t)jarg4; 
    {
        try {
            result = (lucene::util::FileReader *)_CLNEW lucene::util::FileReader((char const *)arg1,(char const *)arg2,arg3,arg4);
            
        }_CATCHALL(0,);
    }
    *(lucene::util::FileReader **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1FileReader_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jstring jarg1, jstring jarg2, jint jarg3) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    char *arg2 = (char *) 0 ;
    int32_t arg3 ;
    lucene::util::FileReader *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    arg3 = (int32_t)jarg3; 
    {
        try {
            result = (lucene::util::FileReader *)_CLNEW lucene::util::FileReader((char const *)arg1,(char const *)arg2,arg3);
            
        }_CATCHALL(0,);
    }
    *(lucene::util::FileReader **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1FileReader_1_1SWIG_12(JNIEnv *jenv, jclass jcls, jstring jarg1, jstring jarg2) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    char *arg2 = (char *) 0 ;
    lucene::util::FileReader *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    {
        try {
            result = (lucene::util::FileReader *)_CLNEW lucene::util::FileReader((char const *)arg1,(char const *)arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::util::FileReader **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1FileReader_1_1SWIG_13(JNIEnv *jenv, jclass jcls, jstring jarg1) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    lucene::util::FileReader *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        try {
            result = (lucene::util::FileReader *)_CLNEW lucene::util::FileReader((char const *)arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::util::FileReader **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1FileReader(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::util::FileReader *arg1 = (lucene::util::FileReader *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::util::FileReader **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1BitSet(JNIEnv *jenv, jclass jcls, jint jarg1) {
    jlong jresult = 0 ;
    int32_t arg1 ;
    lucene::util::BitSet *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = (int32_t)jarg1; 
    {
        try {
            result = (lucene::util::BitSet *)_CLNEW lucene::util::BitSet(arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::util::BitSet **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1BitSet(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::util::BitSet *arg1 = (lucene::util::BitSet *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::util::BitSet **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_BitSet_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jboolean jresult = 0 ;
    lucene::util::BitSet *arg1 = (lucene::util::BitSet *) 0 ;
    int32_t arg2 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::util::BitSet **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            result = (bool)((lucene::util::BitSet const *)arg1)->get(arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_BitSet_1set(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    lucene::util::BitSet *arg1 = (lucene::util::BitSet *) 0 ;
    int32_t arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::util::BitSet **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            (arg1)->set(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_BitSet_1size(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::util::BitSet *arg1 = (lucene::util::BitSet *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::util::BitSet **)(void *)&jarg1; 
    {
        try {
            result = ((lucene::util::BitSet const *)arg1)->size();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1Field_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jstring jarg1, jstring jarg2, jboolean jarg3, jboolean jarg4, jboolean jarg5, jboolean jarg6) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    char *arg2 = (char *) 0 ;
    bool arg3 ;
    bool arg4 ;
    bool arg5 ;
    bool arg6 ;
    lucene::document::Field *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    arg3 = jarg3 ? true : false; 
    arg4 = jarg4 ? true : false; 
    arg5 = jarg5 ? true : false; 
    arg6 = jarg6 ? true : false; 
    {
        try {
            result = (lucene::document::Field *)_CLNEW lucene::document::Field((char const *)arg1,(char const *)arg2,arg3,arg4,arg5,arg6);
            
        }_CATCHALL(0,);
    }
    *(lucene::document::Field **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1Field_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jstring jarg1, jstring jarg2, jboolean jarg3, jboolean jarg4, jboolean jarg5) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    char *arg2 = (char *) 0 ;
    bool arg3 ;
    bool arg4 ;
    bool arg5 ;
    lucene::document::Field *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    arg3 = jarg3 ? true : false; 
    arg4 = jarg4 ? true : false; 
    arg5 = jarg5 ? true : false; 
    {
        try {
            result = (lucene::document::Field *)_CLNEW lucene::document::Field((char const *)arg1,(char const *)arg2,arg3,arg4,arg5);
            
        }_CATCHALL(0,);
    }
    *(lucene::document::Field **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1Field_1_1SWIG_12(JNIEnv *jenv, jclass jcls, jstring jarg1, jlong jarg2, jboolean jarg3, jboolean jarg4, jboolean jarg5, jboolean jarg6) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    lucene::util::Reader *arg2 = (lucene::util::Reader *) 0 ;
    bool arg3 ;
    bool arg4 ;
    bool arg5 ;
    bool arg6 ;
    lucene::document::Field *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = *(lucene::util::Reader **)(void *)&jarg2; 
    arg3 = jarg3 ? true : false; 
    arg4 = jarg4 ? true : false; 
    arg5 = jarg5 ? true : false; 
    arg6 = jarg6 ? true : false; 
    {
        try {
            arg2->__cl_addref();  	result = (lucene::document::Field *)_CLNEW lucene::document::Field((char const *)arg1,arg2,arg3,arg4,arg5,arg6);
        }_CATCHALL(0,);   
    }
    *(lucene::document::Field **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1Field_1_1SWIG_13(JNIEnv *jenv, jclass jcls, jstring jarg1, jlong jarg2, jboolean jarg3, jboolean jarg4, jboolean jarg5) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    lucene::util::Reader *arg2 = (lucene::util::Reader *) 0 ;
    bool arg3 ;
    bool arg4 ;
    bool arg5 ;
    lucene::document::Field *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = *(lucene::util::Reader **)(void *)&jarg2; 
    arg3 = jarg3 ? true : false; 
    arg4 = jarg4 ? true : false; 
    arg5 = jarg5 ? true : false; 
    {
        try {
            arg2->__cl_addref();  	result = (lucene::document::Field *)_CLNEW lucene::document::Field((char const *)arg1,arg2,arg3,arg4,arg5);
        }_CATCHALL(0,);   
    }
    *(lucene::document::Field **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1Field_1_1SWIG_14(JNIEnv *jenv, jclass jcls, jstring jarg1, jlong jarg2, jboolean jarg3) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    lucene::util::Reader *arg2 = (lucene::util::Reader *) 0 ;
    bool arg3 ;
    lucene::document::Field *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = *(lucene::util::Reader **)(void *)&jarg2; 
    arg3 = jarg3 ? true : false; 
    {
        try {
            arg2->__cl_addref();  	result = (lucene::document::Field *)_CLNEW lucene::document::Field((char const *)arg1,arg2,arg3);
        }_CATCHALL(0,);   
    }
    *(lucene::document::Field **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1Field_1_1SWIG_15(JNIEnv *jenv, jclass jcls, jstring jarg1, jlong jarg2) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    lucene::util::Reader *arg2 = (lucene::util::Reader *) 0 ;
    lucene::document::Field *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = *(lucene::util::Reader **)(void *)&jarg2; 
    {
        try {
            arg2->__cl_addref();  	result = (lucene::document::Field *)_CLNEW lucene::document::Field((char const *)arg1,arg2);
        }_CATCHALL(0,);   
    }
    *(lucene::document::Field **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1Field(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::document::Field *arg1 = (lucene::document::Field *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Field **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Field_1Keyword(JNIEnv *jenv, jclass jcls, jstring jarg1, jstring jarg2) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    char *arg2 = (char *) 0 ;
    lucene::document::Field *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    {
        try {
            result = (lucene::document::Field *)lucene::document::Field::Keyword((char const *)arg1,(char const *)arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::document::Field **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Field_1UnIndexed(JNIEnv *jenv, jclass jcls, jstring jarg1, jstring jarg2) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    char *arg2 = (char *) 0 ;
    lucene::document::Field *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    {
        try {
            result = (lucene::document::Field *)lucene::document::Field::UnIndexed((char const *)arg1,(char const *)arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::document::Field **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Field_1Text_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jstring jarg1, jstring jarg2, jboolean jarg3) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    char *arg2 = (char *) 0 ;
    bool arg3 ;
    lucene::document::Field *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    arg3 = jarg3 ? true : false; 
    {
        try {
            result = (lucene::document::Field *)lucene::document::Field::Text((char const *)arg1,(char const *)arg2,arg3);
            
        }_CATCHALL(0,);
    }
    *(lucene::document::Field **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Field_1Text_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jstring jarg1, jstring jarg2) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    char *arg2 = (char *) 0 ;
    lucene::document::Field *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    {
        try {
            result = (lucene::document::Field *)lucene::document::Field::Text((char const *)arg1,(char const *)arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::document::Field **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Field_1UnStored_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jstring jarg1, jstring jarg2, jboolean jarg3) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    char *arg2 = (char *) 0 ;
    bool arg3 ;
    lucene::document::Field *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    arg3 = jarg3 ? true : false; 
    {
        try {
            result = (lucene::document::Field *)lucene::document::Field::UnStored((char const *)arg1,(char const *)arg2,arg3);
            
        }_CATCHALL(0,);
    }
    *(lucene::document::Field **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Field_1UnStored_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jstring jarg1, jstring jarg2) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    char *arg2 = (char *) 0 ;
    lucene::document::Field *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    {
        try {
            result = (lucene::document::Field *)lucene::document::Field::UnStored((char const *)arg1,(char const *)arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::document::Field **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Field_1Text_1_1SWIG_12(JNIEnv *jenv, jclass jcls, jstring jarg1, jlong jarg2, jboolean jarg3) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    lucene::util::Reader *arg2 = (lucene::util::Reader *) 0 ;
    bool arg3 ;
    lucene::document::Field *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = *(lucene::util::Reader **)(void *)&jarg2; 
    arg3 = jarg3 ? true : false; 
    {
        try {
            arg2->__cl_addref();  	result = (lucene::document::Field *)lucene::document::Field::Text((char const *)arg1,arg2,arg3);
        }_CATCHALL(0,);   
    }
    *(lucene::document::Field **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Field_1Text_1_1SWIG_13(JNIEnv *jenv, jclass jcls, jstring jarg1, jlong jarg2) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    lucene::util::Reader *arg2 = (lucene::util::Reader *) 0 ;
    lucene::document::Field *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = *(lucene::util::Reader **)(void *)&jarg2; 
    {
        try {
            arg2->__cl_addref();  	result = (lucene::document::Field *)lucene::document::Field::Text((char const *)arg1,arg2);
        }_CATCHALL(0,);   
    }
    *(lucene::document::Field **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_Field_1name(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::document::Field *arg1 = (lucene::document::Field *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Field **)(void *)&jarg1; 
    {
        try {
            result = (char *)(arg1)->name();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    return jresult;
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_Field_1stringValue(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::document::Field *arg1 = (lucene::document::Field *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Field **)(void *)&jarg1; 
    {
        try {
            result = (char *)(arg1)->stringValue();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Field_1readerValue(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::document::Field *arg1 = (lucene::document::Field *) 0 ;
    lucene::util::Reader *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Field **)(void *)&jarg1; 
    {
        try {
            result = (lucene::util::Reader *)(arg1)->readerValue();
            
        }_CATCHALL(0,);
    }
    *(lucene::util::Reader **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_Field_1isStored(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jboolean jresult = 0 ;
    lucene::document::Field *arg1 = (lucene::document::Field *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Field **)(void *)&jarg1; 
    {
        try {
            result = (bool)(arg1)->isStored();
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_Field_1isIndexed(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jboolean jresult = 0 ;
    lucene::document::Field *arg1 = (lucene::document::Field *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Field **)(void *)&jarg1; 
    {
        try {
            result = (bool)(arg1)->isIndexed();
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_Field_1isTokenized(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jboolean jresult = 0 ;
    lucene::document::Field *arg1 = (lucene::document::Field *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Field **)(void *)&jarg1; 
    {
        try {
            result = (bool)(arg1)->isTokenized();
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_Field_1isTermVectorStored(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jboolean jresult = 0 ;
    lucene::document::Field *arg1 = (lucene::document::Field *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Field **)(void *)&jarg1; 
    {
        try {
            result = (bool)(arg1)->isTermVectorStored();
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT jdouble JNICALL Java_CLjava_CLjavaJNI_Field_1getBoost(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jdouble jresult = 0 ;
    lucene::document::Field *arg1 = (lucene::document::Field *) 0 ;
    float_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Field **)(void *)&jarg1; 
    {
        try {
            result = (arg1)->getBoost();
            
        }_CATCHALL(0,);
    }
    jresult = (jdouble)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Field_1setBoost(JNIEnv *jenv, jclass jcls, jlong jarg1, jdouble jarg2) {
    lucene::document::Field *arg1 = (lucene::document::Field *) 0 ;
    float_t arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Field **)(void *)&jarg1; 
    arg2 = (float_t)jarg2; 
    {
        try {
            (arg1)->setBoost(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_Field_1toString(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::document::Field *arg1 = (lucene::document::Field *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Field **)(void *)&jarg1; 
    {
        try {
            result = (char *)(arg1)->toString();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    _CLDELETE_CaARRAY(result);
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1DateField(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::document::DateField *arg1 = (lucene::document::DateField *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::DateField **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_DateField_1timeToString(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    int64_t arg1 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = (int64_t)jarg1; 
    {
        try {
            result = (char *)lucene::document::DateField::timeToString(arg1);
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_DateField_1stringToTime(JNIEnv *jenv, jclass jcls, jstring jarg1) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    int64_t result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        try {
            result = lucene::document::DateField::stringToTime((char const *)arg1);
            
        }_CATCHALL(0,);
    }
    jresult = (jlong)result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1DateField(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    lucene::document::DateField *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (lucene::document::DateField *)_CLNEW lucene::document::DateField();
            
        }_CATCHALL(0,);
    }
    *(lucene::document::DateField **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1DocumentFieldEnumeration(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::document::DocumentFieldEnumeration *arg1 = (lucene::document::DocumentFieldEnumeration *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::DocumentFieldEnumeration **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_DocumentFieldEnumeration_1hasMoreElements(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jboolean jresult = 0 ;
    lucene::document::DocumentFieldEnumeration *arg1 = (lucene::document::DocumentFieldEnumeration *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::DocumentFieldEnumeration **)(void *)&jarg1; 
    {
        try {
            result = (bool)((lucene::document::DocumentFieldEnumeration const *)arg1)->hasMoreElements();
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_DocumentFieldEnumeration_1nextElement(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::document::DocumentFieldEnumeration *arg1 = (lucene::document::DocumentFieldEnumeration *) 0 ;
    lucene::document::Field *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::DocumentFieldEnumeration **)(void *)&jarg1; 
    {
        try {
            result = (lucene::document::Field *)(arg1)->nextElement();
            
        }_CATCHALL(0,);
    }
    *(lucene::document::Field **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1Document(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    lucene::document::Document *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (lucene::document::Document *)_CLNEW lucene::document::Document();
            
        }_CATCHALL(0,);
    }
    *(lucene::document::Document **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1Document(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::document::Document *arg1 = (lucene::document::Document *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Document **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Document_1add(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    lucene::document::Document *arg1 = (lucene::document::Document *) 0 ;
    lucene::document::Field *arg2 = 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Document **)(void *)&jarg1; 
    arg2 = *(lucene::document::Field **)(void *)&jarg2;
    if(!arg2) {
        SWIG_JavaThrowException(jenv, SWIG_JavaNullPointerException, "lucene::document::Field & reference is null");
        return ;
    } 
    {
        try {
            arg2->__cl_addref();  	(arg1)->add(*arg2);
        }_CATCHALL(,);   
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Document_1getField(JNIEnv *jenv, jclass jcls, jlong jarg1, jstring jarg2) {
    jlong jresult = 0 ;
    lucene::document::Document *arg1 = (lucene::document::Document *) 0 ;
    char *arg2 = (char *) 0 ;
    lucene::document::Field *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Document **)(void *)&jarg1; 
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    {
        try {
            result = (lucene::document::Field *)((lucene::document::Document const *)arg1)->getField((char const *)arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::document::Field **)(void *)&jresult = result; 
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_Document_1get(JNIEnv *jenv, jclass jcls, jlong jarg1, jstring jarg2) {
    jstring jresult = 0 ;
    lucene::document::Document *arg1 = (lucene::document::Document *) 0 ;
    char *arg2 = (char *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Document **)(void *)&jarg1; 
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    {
        try {
            result = (char *)((lucene::document::Document const *)arg1)->get((char const *)arg2);
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Document_1fields(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::document::Document *arg1 = (lucene::document::Document *) 0 ;
    lucene::document::DocumentFieldEnumeration *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Document **)(void *)&jarg1; 
    {
        try {
            result = (lucene::document::DocumentFieldEnumeration *)((lucene::document::Document const *)arg1)->fields();
            
        }_CATCHALL(0,);
    }
    *(lucene::document::DocumentFieldEnumeration **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_Document_1toString(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::document::Document *arg1 = (lucene::document::Document *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Document **)(void *)&jarg1; 
    {
        try {
            result = (char *)((lucene::document::Document const *)arg1)->toString();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    _CLDELETE_CaARRAY(result);
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Document_1setBoost(JNIEnv *jenv, jclass jcls, jlong jarg1, jdouble jarg2) {
    lucene::document::Document *arg1 = (lucene::document::Document *) 0 ;
    float_t arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Document **)(void *)&jarg1; 
    arg2 = (float_t)jarg2; 
    {
        try {
            (arg1)->setBoost(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jdouble JNICALL Java_CLjava_CLjavaJNI_Document_1getBoost(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jdouble jresult = 0 ;
    lucene::document::Document *arg1 = (lucene::document::Document *) 0 ;
    float_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Document **)(void *)&jarg1; 
    {
        try {
            result = ((lucene::document::Document const *)arg1)->getBoost();
            
        }_CATCHALL(0,);
    }
    jresult = (jdouble)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Document_1removeField(JNIEnv *jenv, jclass jcls, jlong jarg1, jstring jarg2) {
    lucene::document::Document *arg1 = (lucene::document::Document *) 0 ;
    char *arg2 = (char *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Document **)(void *)&jarg1; 
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return ;
        }
    }
    {
        try {
            (arg1)->removeField((char const *)arg2);
            
        }_CATCHALL(,);
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Document_1removeFields(JNIEnv *jenv, jclass jcls, jlong jarg1, jstring jarg2) {
    lucene::document::Document *arg1 = (lucene::document::Document *) 0 ;
    char *arg2 = (char *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Document **)(void *)&jarg1; 
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return ;
        }
    }
    {
        try {
            (arg1)->removeFields((char const *)arg2);
            
        }_CATCHALL(,);
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
}


JNIEXPORT jobjectArray JNICALL Java_CLjava_CLjavaJNI_Document_1getValues(JNIEnv *jenv, jclass jcls, jlong jarg1, jstring jarg2) {
    jobjectArray jresult = 0 ;
    lucene::document::Document *arg1 = (lucene::document::Document *) 0 ;
    char *arg2 = (char *) 0 ;
    char **result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::document::Document **)(void *)&jarg1; 
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    {
        try {
            result = (char **)(arg1)->getValues((char const *)arg2);
            
        }_CATCHALL(0,);
    }
    {
        int i;
        int len=0;
        jstring temp_string;
        const jclass clazz = jenv->FindClass("java/lang/String");
        
        while (result[len]) len++;    
        jresult = jenv->NewObjectArray(len, clazz, NULL);
        /* exception checking omitted */
        
        for (i=0; i<len; i++) {
            temp_string = jenv->NewStringUTF(*result++);
            jenv->SetObjectArrayElement(jresult, i, temp_string);
            jenv->DeleteLocalRef(temp_string);
        }
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1Directory(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::store::Directory *arg1 = (lucene::store::Directory *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::store::Directory **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Directory_1close(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::store::Directory *arg1 = (lucene::store::Directory *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::store::Directory **)(void *)&jarg1; 
    {
        try {
            (arg1)->close();
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1FSDirectory(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::store::FSDirectory *arg1 = (lucene::store::FSDirectory *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::store::FSDirectory **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_FSDirectory_1getDirName(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::store::FSDirectory *arg1 = (lucene::store::FSDirectory *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::store::FSDirectory **)(void *)&jarg1; 
    {
        try {
            result = (char *)((lucene::store::FSDirectory const *)arg1)->getDirName();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_FSDirectory_1getDirectory(JNIEnv *jenv, jclass jcls, jstring jarg1, jboolean jarg2) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    bool arg2 ;
    lucene::store::FSDirectory *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = jarg2 ? true : false; 
    {
        try {
            result = (lucene::store::FSDirectory *)lucene::store::FSDirectory::getDirectory((char const *)arg1,arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::store::FSDirectory **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1RAMDirectory_1_1SWIG_10(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    lucene::store::RAMDirectory *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (lucene::store::RAMDirectory *)_CLNEW lucene::store::RAMDirectory();
            
        }_CATCHALL(0,);
    }
    *(lucene::store::RAMDirectory **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1RAMDirectory(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::store::RAMDirectory *arg1 = (lucene::store::RAMDirectory *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::store::RAMDirectory **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1RAMDirectory_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::store::Directory *arg1 = (lucene::store::Directory *) 0 ;
    lucene::store::RAMDirectory *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::store::Directory **)(void *)&jarg1; 
    {
        try {
            result = (lucene::store::RAMDirectory *)_CLNEW lucene::store::RAMDirectory(arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::store::RAMDirectory **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1RAMDirectory_1_1SWIG_12(JNIEnv *jenv, jclass jcls, jstring jarg1) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    lucene::store::RAMDirectory *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        try {
            result = (lucene::store::RAMDirectory *)_CLNEW lucene::store::RAMDirectory((char const *)arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::store::RAMDirectory **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1Token(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::analysis::Token *arg1 = (lucene::analysis::Token *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::Token **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1Token_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jstring jarg1, jint jarg2, jint jarg3, jstring jarg4) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    int32_t arg2 ;
    int32_t arg3 ;
    char *arg4 = (char *) 0 ;
    lucene::analysis::Token *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = (int32_t)jarg2; 
    arg3 = (int32_t)jarg3; 
    {
        arg4 = 0;
        if (jarg4) {
            arg4 = (char *)jenv->GetStringUTFChars(jarg4, 0);
            if (!arg4) return 0;
        }
    }
    {
        try {
            result = (lucene::analysis::Token *)_CLNEW lucene::analysis::Token((char const *)arg1,arg2,arg3,(char const *)arg4);
            
        }_CATCHALL(0,);
    }
    *(lucene::analysis::Token **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    {
        if (arg4) jenv->ReleaseStringUTFChars(jarg4, arg4); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1Token_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jstring jarg1, jint jarg2, jint jarg3) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    int32_t arg2 ;
    int32_t arg3 ;
    lucene::analysis::Token *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = (int32_t)jarg2; 
    arg3 = (int32_t)jarg3; 
    {
        try {
            result = (lucene::analysis::Token *)_CLNEW lucene::analysis::Token((char const *)arg1,arg2,arg3);
            
        }_CATCHALL(0,);
    }
    *(lucene::analysis::Token **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Token_1setPositionIncrement(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    lucene::analysis::Token *arg1 = (lucene::analysis::Token *) 0 ;
    int32_t arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::Token **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            (arg1)->setPositionIncrement(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_Token_1getPositionIncrement(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::analysis::Token *arg1 = (lucene::analysis::Token *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::Token **)(void *)&jarg1; 
    {
        try {
            result = (arg1)->getPositionIncrement();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_Token_1termText(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::analysis::Token *arg1 = (lucene::analysis::Token *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::Token **)(void *)&jarg1; 
    {
        try {
            result = (char *)(arg1)->termText();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_Token_1startOffset(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::analysis::Token *arg1 = (lucene::analysis::Token *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::Token **)(void *)&jarg1; 
    {
        try {
            result = ((lucene::analysis::Token const *)arg1)->startOffset();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_Token_1endOffset(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::analysis::Token *arg1 = (lucene::analysis::Token *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::Token **)(void *)&jarg1; 
    {
        try {
            result = ((lucene::analysis::Token const *)arg1)->endOffset();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_Token_1type(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::analysis::Token *arg1 = (lucene::analysis::Token *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::Token **)(void *)&jarg1; 
    {
        try {
            result = (char *)((lucene::analysis::Token const *)arg1)->type();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_TokenStream_1close(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::analysis::TokenStream *arg1 = (lucene::analysis::TokenStream *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::TokenStream **)(void *)&jarg1; 
    {
        try {
            (arg1)->close();
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1TokenStream(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::analysis::TokenStream *arg1 = (lucene::analysis::TokenStream *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::TokenStream **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_TokenStream_1next(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::analysis::TokenStream *arg1 = (lucene::analysis::TokenStream *) 0 ;
    lucene::analysis::Token *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::TokenStream **)(void *)&jarg1; 
    {
        try {
            result = (lucene::analysis::Token *)(arg1)->next();
            
        }_CATCHALL(0,);
    }
    *(lucene::analysis::Token **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Analyzer_1tokenStream(JNIEnv *jenv, jclass jcls, jlong jarg1, jstring jarg2, jlong jarg3) {
    jlong jresult = 0 ;
    lucene::analysis::Analyzer *arg1 = (lucene::analysis::Analyzer *) 0 ;
    char *arg2 = (char *) 0 ;
    lucene::util::Reader *arg3 = (lucene::util::Reader *) 0 ;
    lucene::analysis::TokenStream *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::Analyzer **)(void *)&jarg1; 
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    arg3 = *(lucene::util::Reader **)(void *)&jarg3; 
    {
        try {
            result = (lucene::analysis::TokenStream *)(arg1)->tokenStream((char const *)arg2,arg3);
            
        }_CATCHALL(0,);
    }
    *(lucene::analysis::TokenStream **)(void *)&jresult = result; 
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1Analyzer(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::analysis::Analyzer *arg1 = (lucene::analysis::Analyzer *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::Analyzer **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1WhitespaceAnalyzer(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::analysis::WhitespaceAnalyzer *arg1 = (lucene::analysis::WhitespaceAnalyzer *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::WhitespaceAnalyzer **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1WhitespaceAnalyzer(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    lucene::analysis::WhitespaceAnalyzer *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (lucene::analysis::WhitespaceAnalyzer *)_CLNEW lucene::analysis::WhitespaceAnalyzer();
            
        }_CATCHALL(0,);
    }
    *(lucene::analysis::WhitespaceAnalyzer **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1SimpleAnalyzer(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::analysis::SimpleAnalyzer *arg1 = (lucene::analysis::SimpleAnalyzer *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::SimpleAnalyzer **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1SimpleAnalyzer(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    lucene::analysis::SimpleAnalyzer *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (lucene::analysis::SimpleAnalyzer *)_CLNEW lucene::analysis::SimpleAnalyzer();
            
        }_CATCHALL(0,);
    }
    *(lucene::analysis::SimpleAnalyzer **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1StopAnalyzer_1_1SWIG_10(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    lucene::analysis::StopAnalyzer *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (lucene::analysis::StopAnalyzer *)_CLNEW lucene::analysis::StopAnalyzer();
            
        }_CATCHALL(0,);
    }
    *(lucene::analysis::StopAnalyzer **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1StopAnalyzer(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::analysis::StopAnalyzer *arg1 = (lucene::analysis::StopAnalyzer *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::StopAnalyzer **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1StopAnalyzer_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jobjectArray jarg1) {
    jlong jresult = 0 ;
    char **arg1 = (char **) 0 ;
    lucene::analysis::StopAnalyzer *result;
    jint size1 ;
    
    (void)jenv;
    (void)jcls;
    {
        int i = 0;
        size1 = jenv->GetArrayLength(jarg1);
        
        arg1 = _CLNEW char*[size1+1];
        
        
        
        for (i = 0; i<size1; i++) {
            jstring j_string = (jstring)jenv->GetObjectArrayElement(jarg1, i);
            const char *c_string = jenv->GetStringUTFChars(j_string, 0);
            
            arg1[i] = _CLNEW char [strlen(c_string)+1];
            
            
            
            strcpy(arg1[i], c_string);
            jenv->ReleaseStringUTFChars(j_string, c_string);
            jenv->DeleteLocalRef(j_string);
        }
        arg1[i] = 0;
    }
    {
        try {
            result = (lucene::analysis::StopAnalyzer *)_CLNEW lucene::analysis::StopAnalyzer(arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::analysis::StopAnalyzer **)(void *)&jresult = result; 
    {
        int i;
        for (i=0; i<size1-1; i++)
        
        delete[] arg1[i];
        delete[] arg1;
        
        
        
        
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1PerFieldAnalyzerWrapper(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::analysis::Analyzer *arg1 = (lucene::analysis::Analyzer *) 0 ;
    lucene::analysis::PerFieldAnalyzerWrapper *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::Analyzer **)(void *)&jarg1; 
    {
        try {
            result = (lucene::analysis::PerFieldAnalyzerWrapper *)_CLNEW lucene::analysis::PerFieldAnalyzerWrapper(arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::analysis::PerFieldAnalyzerWrapper **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1PerFieldAnalyzerWrapper(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::analysis::PerFieldAnalyzerWrapper *arg1 = (lucene::analysis::PerFieldAnalyzerWrapper *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::PerFieldAnalyzerWrapper **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_PerFieldAnalyzerWrapper_1addAnalyzer(JNIEnv *jenv, jclass jcls, jlong jarg1, jstring jarg2, jlong jarg3) {
    lucene::analysis::PerFieldAnalyzerWrapper *arg1 = (lucene::analysis::PerFieldAnalyzerWrapper *) 0 ;
    char *arg2 = (char *) 0 ;
    lucene::analysis::Analyzer *arg3 = (lucene::analysis::Analyzer *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::PerFieldAnalyzerWrapper **)(void *)&jarg1; 
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return ;
        }
    }
    arg3 = *(lucene::analysis::Analyzer **)(void *)&jarg3; 
    {
        try {
            (arg1)->addAnalyzer((char const *)arg2,arg3);
            
        }_CATCHALL(,);
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1StandardAnalyzer_1_1SWIG_10(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    lucene::analysis::standard::StandardAnalyzer *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (lucene::analysis::standard::StandardAnalyzer *)_CLNEW lucene::analysis::standard::StandardAnalyzer();
            
        }_CATCHALL(0,);
    }
    *(lucene::analysis::standard::StandardAnalyzer **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1StandardAnalyzer_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jobjectArray jarg1) {
    jlong jresult = 0 ;
    char **arg1 = (char **) 0 ;
    lucene::analysis::standard::StandardAnalyzer *result;
    jint size1 ;
    
    (void)jenv;
    (void)jcls;
    {
        int i = 0;
        size1 = jenv->GetArrayLength(jarg1);
        
        arg1 = _CLNEW char*[size1+1];
        
        
        
        for (i = 0; i<size1; i++) {
            jstring j_string = (jstring)jenv->GetObjectArrayElement(jarg1, i);
            const char *c_string = jenv->GetStringUTFChars(j_string, 0);
            
            arg1[i] = _CLNEW char [strlen(c_string)+1];
            
            
            
            strcpy(arg1[i], c_string);
            jenv->ReleaseStringUTFChars(j_string, c_string);
            jenv->DeleteLocalRef(j_string);
        }
        arg1[i] = 0;
    }
    {
        try {
            result = (lucene::analysis::standard::StandardAnalyzer *)_CLNEW lucene::analysis::standard::StandardAnalyzer(arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::analysis::standard::StandardAnalyzer **)(void *)&jresult = result; 
    {
        int i;
        for (i=0; i<size1-1; i++)
        
        delete[] arg1[i];
        delete[] arg1;
        
        
        
        
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1StandardAnalyzer(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::analysis::standard::StandardAnalyzer *arg1 = (lucene::analysis::standard::StandardAnalyzer *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::analysis::standard::StandardAnalyzer **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1Term(JNIEnv *jenv, jclass jcls, jstring jarg1, jstring jarg2) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    char *arg2 = (char *) 0 ;
    lucene::index::Term *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    {
        try {
            result = (lucene::index::Term *)_CLNEW lucene::index::Term((char const *)arg1,(char const *)arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::index::Term **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1Term(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::index::Term *arg1 = (lucene::index::Term *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::Term **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_Term_1field(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::index::Term *arg1 = (lucene::index::Term *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::Term **)(void *)&jarg1; 
    {
        try {
            result = (char *)((lucene::index::Term const *)arg1)->field();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    return jresult;
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_Term_1text(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::index::Term *arg1 = (lucene::index::Term *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::Term **)(void *)&jarg1; 
    {
        try {
            result = (char *)((lucene::index::Term const *)arg1)->text();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_Term_1compareTo(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    jint jresult = 0 ;
    lucene::index::Term *arg1 = (lucene::index::Term *) 0 ;
    lucene::index::Term *arg2 = (lucene::index::Term *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::Term **)(void *)&jarg1; 
    arg2 = *(lucene::index::Term **)(void *)&jarg2; 
    {
        try {
            result = ((lucene::index::Term const *)arg1)->compareTo((lucene::index::Term const *)arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_Term_1equals(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    jboolean jresult = 0 ;
    lucene::index::Term *arg1 = (lucene::index::Term *) 0 ;
    lucene::index::Term *arg2 = (lucene::index::Term *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::Term **)(void *)&jarg1; 
    arg2 = *(lucene::index::Term **)(void *)&jarg2; 
    {
        try {
            result = (bool)((lucene::index::Term const *)arg1)->equals((lucene::index::Term const *)arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_Term_1toString(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::index::Term *arg1 = (lucene::index::Term *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::Term **)(void *)&jarg1; 
    {
        try {
            result = (char *)((lucene::index::Term const *)arg1)->toString();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    _CLDELETE_CaARRAY(result);
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_Term_1hashCode(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::index::Term *arg1 = (lucene::index::Term *) 0 ;
    long result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::Term **)(void *)&jarg1; 
    {
        try {
            result = (long)(arg1)->hashCode();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1TermDocs(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::index::TermDocs *arg1 = (lucene::index::TermDocs *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermDocs **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_TermDocs_1seek_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    lucene::index::TermDocs *arg1 = (lucene::index::TermDocs *) 0 ;
    lucene::index::Term *arg2 = (lucene::index::Term *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermDocs **)(void *)&jarg1; 
    arg2 = *(lucene::index::Term **)(void *)&jarg2; 
    {
        try {
            (arg1)->seek(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_TermDocs_1seek_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    lucene::index::TermDocs *arg1 = (lucene::index::TermDocs *) 0 ;
    lucene::index::TermEnum *arg2 = (lucene::index::TermEnum *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermDocs **)(void *)&jarg1; 
    arg2 = *(lucene::index::TermEnum **)(void *)&jarg2; 
    {
        try {
            (arg1)->seek(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_TermDocs_1doc(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::index::TermDocs *arg1 = (lucene::index::TermDocs *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermDocs **)(void *)&jarg1; 
    {
        try {
            result = ((lucene::index::TermDocs const *)arg1)->doc();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_TermDocs_1freq(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::index::TermDocs *arg1 = (lucene::index::TermDocs *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermDocs **)(void *)&jarg1; 
    {
        try {
            result = ((lucene::index::TermDocs const *)arg1)->freq();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_TermDocs_1next(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jboolean jresult = 0 ;
    lucene::index::TermDocs *arg1 = (lucene::index::TermDocs *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermDocs **)(void *)&jarg1; 
    {
        try {
            result = (bool)(arg1)->next();
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_TermDocs_1skipTo(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jboolean jresult = 0 ;
    lucene::index::TermDocs *arg1 = (lucene::index::TermDocs *) 0 ;
    int32_t arg2 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermDocs **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            result = (bool)(arg1)->skipTo(arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_TermDocs_1close(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::index::TermDocs *arg1 = (lucene::index::TermDocs *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermDocs **)(void *)&jarg1; 
    {
        try {
            (arg1)->close();
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_TermEnum_1next(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jboolean jresult = 0 ;
    lucene::index::TermEnum *arg1 = (lucene::index::TermEnum *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermEnum **)(void *)&jarg1; 
    {
        try {
            result = (bool)(arg1)->next();
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_TermEnum_1term(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::index::TermEnum *arg1 = (lucene::index::TermEnum *) 0 ;
    lucene::index::Term *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermEnum **)(void *)&jarg1; 
    {
        try {
            result = (lucene::index::Term *)(arg1)->term();
            
        }_CATCHALL(0,);
    }
    *(lucene::index::Term **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_TermEnum_1docFreq(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::index::TermEnum *arg1 = (lucene::index::TermEnum *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermEnum **)(void *)&jarg1; 
    {
        try {
            result = ((lucene::index::TermEnum const *)arg1)->docFreq();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_TermEnum_1close(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::index::TermEnum *arg1 = (lucene::index::TermEnum *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermEnum **)(void *)&jarg1; 
    {
        try {
            (arg1)->close();
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1TermEnum(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::index::TermEnum *arg1 = (lucene::index::TermEnum *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermEnum **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_TermEnum_1skipTo(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    jboolean jresult = 0 ;
    lucene::index::TermEnum *arg1 = (lucene::index::TermEnum *) 0 ;
    lucene::index::Term *arg2 = (lucene::index::Term *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermEnum **)(void *)&jarg1; 
    arg2 = *(lucene::index::Term **)(void *)&jarg2; 
    {
        try {
            result = (bool)(arg1)->skipTo(arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_TermPositions_1nextPosition(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::index::TermPositions *arg1 = (lucene::index::TermPositions *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermPositions **)(void *)&jarg1; 
    {
        try {
            result = (arg1)->nextPosition();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1TermPositions(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::index::TermPositions *arg1 = (lucene::index::TermPositions *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermPositions **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1TermFreqVector(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::index::TermFreqVector *arg1 = (lucene::index::TermFreqVector *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermFreqVector **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_TermFreqVector_1getField(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::index::TermFreqVector *arg1 = (lucene::index::TermFreqVector *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermFreqVector **)(void *)&jarg1; 
    {
        try {
            result = (char *)(arg1)->getField();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_TermFreqVector_1size(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::index::TermFreqVector *arg1 = (lucene::index::TermFreqVector *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermFreqVector **)(void *)&jarg1; 
    {
        try {
            result = (arg1)->size();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jobjectArray JNICALL Java_CLjava_CLjavaJNI_TermFreqVector_1getTerms(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jobjectArray jresult = 0 ;
    lucene::index::TermFreqVector *arg1 = (lucene::index::TermFreqVector *) 0 ;
    char **result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermFreqVector **)(void *)&jarg1; 
    {
        try {
            result = (char **)(arg1)->getTerms();
            
        }_CATCHALL(0,);
    }
    {
        int i;
        int len=0;
        jstring temp_string;
        const jclass clazz = jenv->FindClass("java/lang/String");
        
        while (result[len]) len++;    
        jresult = jenv->NewObjectArray(len, clazz, NULL);
        /* exception checking omitted */
        
        for (i=0; i<len; i++) {
            temp_string = jenv->NewStringUTF(*result++);
            jenv->SetObjectArrayElement(jresult, i, temp_string);
            jenv->DeleteLocalRef(temp_string);
        }
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_TermFreqVector_1getTermFrequencies(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::index::TermFreqVector *arg1 = (lucene::index::TermFreqVector *) 0 ;
    int32_t *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermFreqVector **)(void *)&jarg1; 
    {
        try {
            result = (int32_t *)(arg1)->getTermFrequencies();
            
        }_CATCHALL(0,);
    }
    
    _CL_p_int32_tArray* _obj_result = _CLNEW _CL_p_int32_tArray(result);
    jresult=(jlong)_obj_result;
    
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_TermFreqVector_1indexOf(JNIEnv *jenv, jclass jcls, jlong jarg1, jstring jarg2) {
    jint jresult = 0 ;
    lucene::index::TermFreqVector *arg1 = (lucene::index::TermFreqVector *) 0 ;
    char *arg2 = (char *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::TermFreqVector **)(void *)&jarg1; 
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    {
        try {
            result = (arg1)->indexOf((char const *)arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_IndexReader_1commit(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    {
        try {
            (arg1)->commit();
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_IndexReader_1undeleteAll(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    {
        try {
            (arg1)->undeleteAll();
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jobjectArray JNICALL Java_CLjava_CLjavaJNI_IndexReader_1getIndexedFieldNames(JNIEnv *jenv, jclass jcls, jlong jarg1, jboolean jarg2) {
    jobjectArray jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    bool arg2 ;
    char **result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    arg2 = jarg2 ? true : false; 
    {
        try {
            result = (char **)(arg1)->getIndexedFieldNames(arg2);
            
        }_CATCHALL(0,);
    }
    {
        int i;
        int len=0;
        jstring temp_string;
        const jclass clazz = jenv->FindClass("java/lang/String");
        
        while (result[len]) len++;    
        jresult = jenv->NewObjectArray(len, clazz, NULL);
        /* exception checking omitted */
        
        for (i=0; i<len; i++) {
            temp_string = jenv->NewStringUTF(*result++);
            jenv->SetObjectArrayElement(jresult, i, temp_string);
            jenv->DeleteLocalRef(temp_string);
        }
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1norms(JNIEnv *jenv, jclass jcls, jlong jarg1, jstring jarg2) {
    jlong jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    char *arg2 = (char *) 0 ;
    uint8_t *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    {
        try {
            result = (uint8_t *)(arg1)->norms((char const *)arg2);
            
        }_CATCHALL(0,);
    }
    
    _CL_p_uint8_tArray* _obj_result = _CLNEW _CL_p_uint8_tArray(result);
    jresult=(jlong)_obj_result;
    
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_IndexReader_1setNorm_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2, jstring jarg3, jdouble jarg4) {
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    int32_t arg2 ;
    char *arg3 = (char *) 0 ;
    float_t arg4 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        arg3 = 0;
        if (jarg3) {
            arg3 = (char *)jenv->GetStringUTFChars(jarg3, 0);
            if (!arg3) return ;
        }
    }
    arg4 = (float_t)jarg4; 
    {
        try {
            (arg1)->setNorm(arg2,(char const *)arg3,arg4);
            
        }_CATCHALL(,);
    }
    {
        if (arg3) jenv->ReleaseStringUTFChars(jarg3, arg3); 
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_IndexReader_1setNorm_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2, jstring jarg3, jshort jarg4) {
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    int32_t arg2 ;
    char *arg3 = (char *) 0 ;
    uint8_t arg4 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        arg3 = 0;
        if (jarg3) {
            arg3 = (char *)jenv->GetStringUTFChars(jarg3, 0);
            if (!arg3) return ;
        }
    }
    arg4 = (uint8_t)jarg4; 
    {
        try {
            (arg1)->setNorm(arg2,(char const *)arg3,arg4);
            
        }_CATCHALL(,);
    }
    {
        if (arg3) jenv->ReleaseStringUTFChars(jarg3, arg3); 
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1IndexReader(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1open_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jstring jarg1) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    lucene::index::IndexReader *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        try {
            result = (lucene::index::IndexReader *)lucene::index::IndexReader::open((char const *)arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::index::IndexReader **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1open_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jlong jarg1, jboolean jarg2) {
    jlong jresult = 0 ;
    lucene::store::Directory *arg1 = (lucene::store::Directory *) 0 ;
    bool arg2 ;
    lucene::index::IndexReader *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::store::Directory **)(void *)&jarg1; 
    arg2 = jarg2 ? true : false; 
    {
        try {
            result = (lucene::index::IndexReader *)lucene::index::IndexReader::open(arg1,arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::index::IndexReader **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1open_1_1SWIG_12(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::store::Directory *arg1 = (lucene::store::Directory *) 0 ;
    lucene::index::IndexReader *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::store::Directory **)(void *)&jarg1; 
    {
        try {
            result = (lucene::index::IndexReader *)lucene::index::IndexReader::open(arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::index::IndexReader **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1lastModified_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jstring jarg1) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    int64_t result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        try {
            result = lucene::index::IndexReader::lastModified((char const *)arg1);
            
        }_CATCHALL(0,);
    }
    jresult = (jlong)result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1lastModified_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::store::Directory *arg1 = (lucene::store::Directory *) 0 ;
    int64_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::store::Directory **)(void *)&jarg1; 
    {
        try {
            result = lucene::index::IndexReader::lastModified((lucene::store::Directory const *)arg1);
            
        }_CATCHALL(0,);
    }
    jresult = (jlong)result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1getCurrentVersion_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::store::Directory *arg1 = (lucene::store::Directory *) 0 ;
    int64_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::store::Directory **)(void *)&jarg1; 
    {
        try {
            result = lucene::index::IndexReader::getCurrentVersion(arg1);
            
        }_CATCHALL(0,);
    }
    jresult = (jlong)result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1getCurrentVersion_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jstring jarg1) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    int64_t result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        try {
            result = lucene::index::IndexReader::getCurrentVersion((char const *)arg1);
            
        }_CATCHALL(0,);
    }
    jresult = (jlong)result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1getTermFreqVectors(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jlong jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    int32_t arg2 ;
    lucene::index::TermFreqVector **result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            result = (lucene::index::TermFreqVector **)(arg1)->getTermFreqVectors(arg2);
            
        }_CATCHALL(0,);
    }
    
    _CL_p_p_lucene__index__TermFreqVectorArray* _obj_result = _CLNEW _CL_p_p_lucene__index__TermFreqVectorArray(result);
    jresult=(jlong)_obj_result;
    
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1getTermFreqVector(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2, jstring jarg3) {
    jlong jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    int32_t arg2 ;
    char *arg3 = (char *) 0 ;
    lucene::index::TermFreqVector *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        arg3 = 0;
        if (jarg3) {
            arg3 = (char *)jenv->GetStringUTFChars(jarg3, 0);
            if (!arg3) return 0;
        }
    }
    {
        try {
            result = (lucene::index::TermFreqVector *)(arg1)->getTermFreqVector(arg2,(char const *)arg3);
            
        }_CATCHALL(0,);
    }
    *(lucene::index::TermFreqVector **)(void *)&jresult = result; 
    {
        if (arg3) jenv->ReleaseStringUTFChars(jarg3, arg3); 
    }
    return jresult;
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_IndexReader_1indexExists_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jstring jarg1) {
    jboolean jresult = 0 ;
    char *arg1 = (char *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        try {
            result = (bool)lucene::index::IndexReader::indexExists((char const *)arg1);
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_IndexReader_1indexExists_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jboolean jresult = 0 ;
    lucene::store::Directory *arg1 = (lucene::store::Directory *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::store::Directory **)(void *)&jarg1; 
    {
        try {
            result = (bool)lucene::index::IndexReader::indexExists((lucene::store::Directory const *)arg1);
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_IndexReader_1numDocs(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    {
        try {
            result = (arg1)->numDocs();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_IndexReader_1maxDoc(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    {
        try {
            result = ((lucene::index::IndexReader const *)arg1)->maxDoc();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1document(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jlong jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    int32_t arg2 ;
    lucene::document::Document *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            result = (lucene::document::Document *)(arg1)->document(arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::document::Document **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_IndexReader_1isDeleted(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jboolean jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    int32_t arg2 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            result = (bool)(arg1)->isDeleted(arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_IndexReader_1hasDeletions(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jboolean jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    {
        try {
            result = (bool)(arg1)->hasDeletions();
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1terms_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    lucene::index::TermEnum *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    {
        try {
            result = (lucene::index::TermEnum *)((lucene::index::IndexReader const *)arg1)->terms();
            
        }_CATCHALL(0,);
    }
    *(lucene::index::TermEnum **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1terms_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    jlong jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    lucene::index::Term *arg2 = (lucene::index::Term *) 0 ;
    lucene::index::TermEnum *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    arg2 = *(lucene::index::Term **)(void *)&jarg2; 
    {
        try {
            result = (lucene::index::TermEnum *)((lucene::index::IndexReader const *)arg1)->terms((lucene::index::Term const *)arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::index::TermEnum **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_IndexReader_1docFreq(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    jint jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    lucene::index::Term *arg2 = (lucene::index::Term *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    arg2 = *(lucene::index::Term **)(void *)&jarg2; 
    {
        try {
            result = ((lucene::index::IndexReader const *)arg1)->docFreq((lucene::index::Term const *)arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1termPositions_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    lucene::index::TermPositions *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    {
        try {
            result = (lucene::index::TermPositions *)((lucene::index::IndexReader const *)arg1)->termPositions();
            
        }_CATCHALL(0,);
    }
    *(lucene::index::TermPositions **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1termPositions_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    jlong jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    lucene::index::Term *arg2 = (lucene::index::Term *) 0 ;
    lucene::index::TermPositions *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    arg2 = *(lucene::index::Term **)(void *)&jarg2; 
    {
        try {
            result = (lucene::index::TermPositions *)(arg1)->termPositions(arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::index::TermPositions **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1termDocs_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    lucene::index::TermDocs *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    {
        try {
            result = (lucene::index::TermDocs *)((lucene::index::IndexReader const *)arg1)->termDocs();
            
        }_CATCHALL(0,);
    }
    *(lucene::index::TermDocs **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1termDocs_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    jlong jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    lucene::index::Term *arg2 = (lucene::index::Term *) 0 ;
    lucene::index::TermDocs *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    arg2 = *(lucene::index::Term **)(void *)&jarg2; 
    {
        try {
            result = (lucene::index::TermDocs *)((lucene::index::IndexReader const *)arg1)->termDocs(arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::index::TermDocs **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_IndexReader_1Delete_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    int32_t arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            (arg1)->deleteDoc(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_IndexReader_1Delete_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    jint jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    lucene::index::Term *arg2 = (lucene::index::Term *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    arg2 = *(lucene::index::Term **)(void *)&jarg2; 
    {
        try {
            result = (arg1)->deleteTerm(arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_IndexReader_1close(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    {
        try {
            (arg1)->close();
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_IndexReader_1isLocked_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jboolean jresult = 0 ;
    lucene::store::Directory *arg1 = (lucene::store::Directory *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::store::Directory **)(void *)&jarg1; 
    {
        try {
            result = (bool)lucene::index::IndexReader::isLocked(arg1);
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_IndexReader_1isLocked_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jstring jarg1) {
    jboolean jresult = 0 ;
    char *arg1 = (char *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        try {
            result = (bool)lucene::index::IndexReader::isLocked((char const *)arg1);
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_IndexReader_1unlock_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::store::Directory *arg1 = (lucene::store::Directory *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::store::Directory **)(void *)&jarg1; 
    {
        try {
            lucene::index::IndexReader::unlock(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_IndexReader_1unlock_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jstring jarg1) {
    char *arg1 = (char *) 0 ;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return ;
        }
    }
    {
        try {
            lucene::index::IndexReader::unlock((char const *)arg1);
            
        }_CATCHALL(,);
    }
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexReader_1getDirectory(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    lucene::store::Directory *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    {
        try {
            result = (lucene::store::Directory *)(arg1)->getDirectory();
            
        }_CATCHALL(0,);
    }
    *(lucene::store::Directory **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1MultiReader(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::index::IndexReader **arg1 = (lucene::index::IndexReader **) 0 ;
    lucene::index::MultiReader *result;
    
    (void)jenv;
    (void)jcls;
    
    _CL_p_p_lucene__index__IndexReaderArray* _obj_arg1 =($symname Array)jarg1;xxx
    arg1 = _obj_arg1->array;
    
    {
        try {
            result = (lucene::index::MultiReader *)_CLNEW lucene::index::MultiReader(arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::index::MultiReader **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1MultiReader(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::index::MultiReader *arg1 = (lucene::index::MultiReader *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::MultiReader **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1IndexWriter(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1getMaxFieldLength(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    {
        try {
            result = (arg1)->getMaxFieldLength();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1setMaxFieldLength(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    int32_t arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            (arg1)->setMaxFieldLength(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1getMergeFactor(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    {
        try {
            result = (arg1)->getMergeFactor();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1setMergeFactor(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    int32_t arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            (arg1)->setMergeFactor(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1getMinMergeDocs(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    {
        try {
            result = (arg1)->getMinMergeDocs();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1setMinMergeDocs(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    int32_t arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            (arg1)->setMinMergeDocs(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1getMaxMergeDocs(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    {
        try {
            result = (arg1)->getMaxMergeDocs();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1setMaxMergeDocs(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    int32_t arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            (arg1)->setMaxMergeDocs(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1IndexWriter_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jstring jarg1, jlong jarg2, jboolean jarg3, jboolean jarg4) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    lucene::analysis::Analyzer *arg2 = (lucene::analysis::Analyzer *) 0 ;
    bool arg3 ;
    bool arg4 ;
    lucene::index::IndexWriter *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = *(lucene::analysis::Analyzer **)(void *)&jarg2; 
    arg3 = jarg3 ? true : false; 
    arg4 = jarg4 ? true : false; 
    {
        try {
            result = (lucene::index::IndexWriter *)_CLNEW lucene::index::IndexWriter((char const *)arg1,arg2,arg3,arg4);
            
        }_CATCHALL(0,);
    }
    *(lucene::index::IndexWriter **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1IndexWriter_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jstring jarg1, jlong jarg2, jboolean jarg3) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    lucene::analysis::Analyzer *arg2 = (lucene::analysis::Analyzer *) 0 ;
    bool arg3 ;
    lucene::index::IndexWriter *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = *(lucene::analysis::Analyzer **)(void *)&jarg2; 
    arg3 = jarg3 ? true : false; 
    {
        try {
            result = (lucene::index::IndexWriter *)_CLNEW lucene::index::IndexWriter((char const *)arg1,arg2,arg3);
            
        }_CATCHALL(0,);
    }
    *(lucene::index::IndexWriter **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1IndexWriter_1_1SWIG_12(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2, jboolean jarg3, jboolean jarg4) {
    jlong jresult = 0 ;
    lucene::store::Directory *arg1 = (lucene::store::Directory *) 0 ;
    lucene::analysis::Analyzer *arg2 = (lucene::analysis::Analyzer *) 0 ;
    bool arg3 ;
    bool arg4 ;
    lucene::index::IndexWriter *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::store::Directory **)(void *)&jarg1; 
    arg2 = *(lucene::analysis::Analyzer **)(void *)&jarg2; 
    arg3 = jarg3 ? true : false; 
    arg4 = jarg4 ? true : false; 
    {
        try {
            result = (lucene::index::IndexWriter *)_CLNEW lucene::index::IndexWriter(arg1,arg2,arg3,arg4);
            
        }_CATCHALL(0,);
    }
    *(lucene::index::IndexWriter **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1IndexWriter_1_1SWIG_13(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2, jboolean jarg3) {
    jlong jresult = 0 ;
    lucene::store::Directory *arg1 = (lucene::store::Directory *) 0 ;
    lucene::analysis::Analyzer *arg2 = (lucene::analysis::Analyzer *) 0 ;
    bool arg3 ;
    lucene::index::IndexWriter *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::store::Directory **)(void *)&jarg1; 
    arg2 = *(lucene::analysis::Analyzer **)(void *)&jarg2; 
    arg3 = jarg3 ? true : false; 
    {
        try {
            result = (lucene::index::IndexWriter *)_CLNEW lucene::index::IndexWriter(arg1,arg2,arg3);
            
        }_CATCHALL(0,);
    }
    *(lucene::index::IndexWriter **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1close(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    {
        try {
            (arg1)->close();
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1docCount(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    {
        try {
            result = (arg1)->docCount();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1addDocument(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    lucene::document::Document *arg2 = (lucene::document::Document *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    arg2 = *(lucene::document::Document **)(void *)&jarg2; 
    {
        try {
            (arg1)->addDocument(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1optimize(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    {
        try {
            (arg1)->optimize();
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1getDirectory(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    lucene::store::Directory *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    {
        try {
            result = (lucene::store::Directory *)(arg1)->getDirectory();
            
        }_CATCHALL(0,);
    }
    *(lucene::store::Directory **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1getUseCompoundFile(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jboolean jresult = 0 ;
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    {
        try {
            result = (bool)(arg1)->getUseCompoundFile();
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1setUseCompoundFile(JNIEnv *jenv, jclass jcls, jlong jarg1, jboolean jarg2) {
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    bool arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    arg2 = jarg2 ? true : false; 
    {
        try {
            (arg1)->setUseCompoundFile(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1setSimilarity(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    lucene::search::Similarity *arg2 = (lucene::search::Similarity *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    arg2 = *(lucene::search::Similarity **)(void *)&jarg2; 
    {
        try {
            (arg1)->setSimilarity(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1getSimilarity(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    lucene::search::Similarity *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    {
        try {
            result = (lucene::search::Similarity *)(arg1)->getSimilarity();
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Similarity **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexWriter_1getAnalyzer(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::index::IndexWriter *arg1 = (lucene::index::IndexWriter *) 0 ;
    lucene::analysis::Analyzer *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexWriter **)(void *)&jarg1; 
    {
        try {
            result = (lucene::analysis::Analyzer *)(arg1)->getAnalyzer();
            
        }_CATCHALL(0,);
    }
    *(lucene::analysis::Analyzer **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1Filter(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::Filter *arg1 = (lucene::search::Filter *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Filter **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Filter_1bits(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    jlong jresult = 0 ;
    lucene::search::Filter *arg1 = (lucene::search::Filter *) 0 ;
    lucene::index::IndexReader *arg2 = (lucene::index::IndexReader *) 0 ;
    lucene::util::BitSet *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Filter **)(void *)&jarg1; 
    arg2 = *(lucene::index::IndexReader **)(void *)&jarg2; 
    {
        try {
            result = (lucene::util::BitSet *)((lucene::search::Filter const *)arg1)->bits(arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::util::BitSet **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_Filter_1toString(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::search::Filter *arg1 = (lucene::search::Filter *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Filter **)(void *)&jarg1; 
    {
        try {
            result = (char *)(arg1)->toString();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    _CLDELETE_CaARRAY(result);
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1DateFilter(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::DateFilter *arg1 = (lucene::search::DateFilter *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::DateFilter **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1DateFilter(JNIEnv *jenv, jclass jcls, jstring jarg1, jlong jarg2, jlong jarg3) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    int64_t arg2 ;
    int64_t arg3 ;
    lucene::search::DateFilter *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = (int64_t)jarg2; 
    arg3 = (int64_t)jarg3; 
    {
        try {
            result = (lucene::search::DateFilter *)_CLNEW lucene::search::DateFilter((char const *)arg1,arg2,arg3);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::DateFilter **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_DateFilter_1Before(JNIEnv *jenv, jclass jcls, jstring jarg1, jlong jarg2) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    int64_t arg2 ;
    lucene::search::DateFilter *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = (int64_t)jarg2; 
    {
        try {
            result = (lucene::search::DateFilter *)lucene::search::DateFilter::Before((char const *)arg1,arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::DateFilter **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_DateFilter_1After(JNIEnv *jenv, jclass jcls, jstring jarg1, jlong jarg2) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    int64_t arg2 ;
    lucene::search::DateFilter *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = (int64_t)jarg2; 
    {
        try {
            result = (lucene::search::DateFilter *)lucene::search::DateFilter::After((char const *)arg1,arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::DateFilter **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1Similarity(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::Similarity *arg1 = (lucene::search::Similarity *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Similarity **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Similarity_1setDefault(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::Similarity *arg1 = (lucene::search::Similarity *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Similarity **)(void *)&jarg1; 
    {
        try {
            lucene::search::Similarity::setDefault(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Similarity_1getDefault(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    lucene::search::Similarity *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (lucene::search::Similarity *)lucene::search::Similarity::getDefault();
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Similarity **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jshort JNICALL Java_CLjava_CLjavaJNI_Similarity_1encodeNorm(JNIEnv *jenv, jclass jcls, jdouble jarg1) {
    jshort jresult = 0 ;
    float_t arg1 ;
    uint8_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = (float_t)jarg1; 
    {
        try {
            result = lucene::search::Similarity::encodeNorm(arg1);
            
        }_CATCHALL(0,);
    }
    jresult = (jshort)result; 
    return jresult;
}


JNIEXPORT jdouble JNICALL Java_CLjava_CLjavaJNI_Similarity_1decodeNorm(JNIEnv *jenv, jclass jcls, jshort jarg1) {
    jdouble jresult = 0 ;
    uint8_t arg1 ;
    float_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = (uint8_t)jarg1; 
    {
        try {
            result = lucene::search::Similarity::decodeNorm(arg1);
            
        }_CATCHALL(0,);
    }
    jresult = (jdouble)result; 
    return jresult;
}


JNIEXPORT jshort JNICALL Java_CLjava_CLjavaJNI_Similarity_1floatToByte(JNIEnv *jenv, jclass jcls, jdouble jarg1) {
    jshort jresult = 0 ;
    float_t arg1 ;
    uint8_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = (float_t)jarg1; 
    {
        try {
            result = lucene::search::Similarity::floatToByte(arg1);
            
        }_CATCHALL(0,);
    }
    jresult = (jshort)result; 
    return jresult;
}


JNIEXPORT jdouble JNICALL Java_CLjava_CLjavaJNI_Similarity_1byteToFloat(JNIEnv *jenv, jclass jcls, jshort jarg1) {
    jdouble jresult = 0 ;
    uint8_t arg1 ;
    float_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = (uint8_t)jarg1; 
    {
        try {
            result = lucene::search::Similarity::byteToFloat(arg1);
            
        }_CATCHALL(0,);
    }
    jresult = (jdouble)result; 
    return jresult;
}


JNIEXPORT jdouble JNICALL Java_CLjava_CLjavaJNI_Similarity_1lengthNorm(JNIEnv *jenv, jclass jcls, jlong jarg1, jstring jarg2, jint jarg3) {
    jdouble jresult = 0 ;
    lucene::search::Similarity *arg1 = (lucene::search::Similarity *) 0 ;
    char *arg2 = (char *) 0 ;
    int32_t arg3 ;
    float_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Similarity **)(void *)&jarg1; 
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    arg3 = (int32_t)jarg3; 
    {
        try {
            result = (arg1)->lengthNorm((char const *)arg2,arg3);
            
        }_CATCHALL(0,);
    }
    jresult = (jdouble)result; 
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jdouble JNICALL Java_CLjava_CLjavaJNI_Similarity_1queryNorm(JNIEnv *jenv, jclass jcls, jlong jarg1, jdouble jarg2) {
    jdouble jresult = 0 ;
    lucene::search::Similarity *arg1 = (lucene::search::Similarity *) 0 ;
    float_t arg2 ;
    float_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Similarity **)(void *)&jarg1; 
    arg2 = (float_t)jarg2; 
    {
        try {
            result = (arg1)->queryNorm(arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jdouble)result; 
    return jresult;
}


JNIEXPORT jdouble JNICALL Java_CLjava_CLjavaJNI_Similarity_1sloppyFreq(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jdouble jresult = 0 ;
    lucene::search::Similarity *arg1 = (lucene::search::Similarity *) 0 ;
    int32_t arg2 ;
    float_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Similarity **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            result = (arg1)->sloppyFreq(arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jdouble)result; 
    return jresult;
}


JNIEXPORT jdouble JNICALL Java_CLjava_CLjavaJNI_Similarity_1coord(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2, jint jarg3) {
    jdouble jresult = 0 ;
    lucene::search::Similarity *arg1 = (lucene::search::Similarity *) 0 ;
    int32_t arg2 ;
    int32_t arg3 ;
    float_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Similarity **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    arg3 = (int32_t)jarg3; 
    {
        try {
            result = (arg1)->coord(arg2,arg3);
            
        }_CATCHALL(0,);
    }
    jresult = (jdouble)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1SortField(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::SortField *arg1 = (lucene::search::SortField *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::SortField **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_get_1SortField_1SCORE(JNIEnv *jenv, jclass jcls) {
    jint jresult = 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = lucene::search::SortField::SCORE;
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_get_1SortField_1DOC(JNIEnv *jenv, jclass jcls) {
    jint jresult = 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = lucene::search::SortField::DOC;
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_get_1SortField_1AUTO(JNIEnv *jenv, jclass jcls) {
    jint jresult = 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = lucene::search::SortField::AUTO;
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_get_1SortField_1STRING(JNIEnv *jenv, jclass jcls) {
    jint jresult = 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = lucene::search::SortField::STRING;
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_get_1SortField_1INT(JNIEnv *jenv, jclass jcls) {
    jint jresult = 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = lucene::search::SortField::INT;
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_get_1SortField_1FLOAT(JNIEnv *jenv, jclass jcls) {
    jint jresult = 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = lucene::search::SortField::FLOAT;
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_get_1SortField_1CUSTOM(JNIEnv *jenv, jclass jcls) {
    jint jresult = 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = lucene::search::SortField::CUSTOM;
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_get_1SortField_1FIELD_1SCORE(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    lucene::search::SortField *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (lucene::search::SortField *)lucene::search::SortField::FIELD_SCORE;
            
        }_CATCHALL(0,);
    }
    *(lucene::search::SortField **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_get_1SortField_1FIELD_1DOC(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    lucene::search::SortField *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (lucene::search::SortField *)lucene::search::SortField::FIELD_DOC;
            
        }_CATCHALL(0,);
    }
    *(lucene::search::SortField **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1SortField_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jstring jarg1) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    lucene::search::SortField *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        try {
            result = (lucene::search::SortField *)_CLNEW lucene::search::SortField((char const *)arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::SortField **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1SortField_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jstring jarg1, jboolean jarg2) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    bool arg2 ;
    lucene::search::SortField *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = jarg2 ? true : false; 
    {
        try {
            result = (lucene::search::SortField *)_CLNEW lucene::search::SortField((char const *)arg1,arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::SortField **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1SortField_1_1SWIG_12(JNIEnv *jenv, jclass jcls, jstring jarg1, jint jarg2, jboolean jarg3) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    int32_t arg2 ;
    bool arg3 ;
    lucene::search::SortField *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = (int32_t)jarg2; 
    arg3 = jarg3 ? true : false; 
    {
        try {
            result = (lucene::search::SortField *)_CLNEW lucene::search::SortField((char const *)arg1,arg2,arg3);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::SortField **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_SortField_1getField(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::search::SortField *arg1 = (lucene::search::SortField *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::SortField **)(void *)&jarg1; 
    {
        try {
            result = (char *)(arg1)->getField();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_SortField_1getType(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::search::SortField *arg1 = (lucene::search::SortField *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::SortField **)(void *)&jarg1; 
    {
        try {
            result = (arg1)->getType();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_SortField_1getReverse(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jboolean jresult = 0 ;
    lucene::search::SortField *arg1 = (lucene::search::SortField *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::SortField **)(void *)&jarg1; 
    {
        try {
            result = (bool)(arg1)->getReverse();
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_SortField_1toString(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::search::SortField *arg1 = (lucene::search::SortField *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::SortField **)(void *)&jarg1; 
    {
        try {
            result = (char *)((lucene::search::SortField const *)arg1)->toString();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    _CLDELETE_CaARRAY(result);
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1Sort(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::Sort *arg1 = (lucene::search::Sort *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Sort **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_get_1Sort_1RELEVANCE(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    lucene::search::Sort *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (lucene::search::Sort *)lucene::search::Sort::RELEVANCE;
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Sort **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_get_1Sort_1INDEXORDER(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    lucene::search::Sort *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (lucene::search::Sort *)lucene::search::Sort::INDEXORDER;
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Sort **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1Sort_1_1SWIG_10(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    lucene::search::Sort *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (lucene::search::Sort *)_CLNEW lucene::search::Sort();
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Sort **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1Sort_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jstring jarg1, jboolean jarg2) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    bool arg2 ;
    lucene::search::Sort *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = jarg2 ? true : false; 
    {
        try {
            result = (lucene::search::Sort *)_CLNEW lucene::search::Sort((char const *)arg1,arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Sort **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1Sort_1_1SWIG_12(JNIEnv *jenv, jclass jcls, jstring jarg1) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    lucene::search::Sort *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        try {
            result = (lucene::search::Sort *)_CLNEW lucene::search::Sort((char const *)arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Sort **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1Sort_1_1SWIG_13(JNIEnv *jenv, jclass jcls, jobjectArray jarg1) {
    jlong jresult = 0 ;
    char **arg1 = (char **) 0 ;
    lucene::search::Sort *result;
    jint size1 ;
    
    (void)jenv;
    (void)jcls;
    {
        int i = 0;
        size1 = jenv->GetArrayLength(jarg1);
        
        arg1 = _CLNEW char*[size1+1];
        
        
        
        for (i = 0; i<size1; i++) {
            jstring j_string = (jstring)jenv->GetObjectArrayElement(jarg1, i);
            const char *c_string = jenv->GetStringUTFChars(j_string, 0);
            
            arg1[i] = _CLNEW char [strlen(c_string)+1];
            
            
            
            strcpy(arg1[i], c_string);
            jenv->ReleaseStringUTFChars(j_string, c_string);
            jenv->DeleteLocalRef(j_string);
        }
        arg1[i] = 0;
    }
    {
        try {
            result = (lucene::search::Sort *)_CLNEW lucene::search::Sort((char const **)arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Sort **)(void *)&jresult = result; 
    {
        int i;
        for (i=0; i<size1-1; i++)
        
        delete[] arg1[i];
        delete[] arg1;
        
        
        
        
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1Sort_1_1SWIG_14(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::search::SortField *arg1 = (lucene::search::SortField *) 0 ;
    lucene::search::Sort *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::SortField **)(void *)&jarg1; 
    {
        try {
            arg1->__cl_addref();  	result = (lucene::search::Sort *)_CLNEW lucene::search::Sort(arg1);
        }_CATCHALL(0,);   
    }
    *(lucene::search::Sort **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1Sort_1_1SWIG_15(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::search::SortField **arg1 = (lucene::search::SortField **) 0 ;
    lucene::search::Sort *result;
    
    (void)jenv;
    (void)jcls;
    
    _CL_p_p_lucene__search__SortFieldArray* _obj_arg1 =($symname Array)jarg1;xxx
    arg1 = _obj_arg1->array;
    
    {
        try{
            int i=0;    	int32_t arg1plen=0;    	while(arg1[arg1plen]!=NULL) arg1plen++;    	lucene::search::SortField** arg1p = _CLNEW lucene::search::SortField*[arg1plen+1];    	for ( int i=0;i<arg1plen;i++ )arg1p[i]=(arg1p[i]->__cl_addref()>=0?arg1p[i]:arg1p[i]);   	arg1p[arg1plen]=NULL; arg1=arg1p;  	  result = (lucene::search::Sort *)_CLNEW lucene::search::Sort(arg1);
        }_CATCHALL(0,);   
    }
    *(lucene::search::Sort **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Sort_1setSort_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jlong jarg1, jstring jarg2, jboolean jarg3) {
    lucene::search::Sort *arg1 = (lucene::search::Sort *) 0 ;
    char *arg2 = (char *) 0 ;
    bool arg3 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Sort **)(void *)&jarg1; 
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return ;
        }
    }
    arg3 = jarg3 ? true : false; 
    {
        try {
            (arg1)->setSort((char const *)arg2,arg3);
            
        }_CATCHALL(,);
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Sort_1setSort_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jlong jarg1, jstring jarg2) {
    lucene::search::Sort *arg1 = (lucene::search::Sort *) 0 ;
    char *arg2 = (char *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Sort **)(void *)&jarg1; 
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return ;
        }
    }
    {
        try {
            (arg1)->setSort((char const *)arg2);
            
        }_CATCHALL(,);
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Sort_1setSort_1_1SWIG_12(JNIEnv *jenv, jclass jcls, jlong jarg1, jobjectArray jarg2) {
    lucene::search::Sort *arg1 = (lucene::search::Sort *) 0 ;
    char **arg2 = (char **) 0 ;
    jint size2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Sort **)(void *)&jarg1; 
    {
        int i = 0;
        size2 = jenv->GetArrayLength(jarg2);
        
        arg2 = _CLNEW char*[size2+1];
        
        
        
        for (i = 0; i<size2; i++) {
            jstring j_string = (jstring)jenv->GetObjectArrayElement(jarg2, i);
            const char *c_string = jenv->GetStringUTFChars(j_string, 0);
            
            arg2[i] = _CLNEW char [strlen(c_string)+1];
            
            
            
            strcpy(arg2[i], c_string);
            jenv->ReleaseStringUTFChars(j_string, c_string);
            jenv->DeleteLocalRef(j_string);
        }
        arg2[i] = 0;
    }
    {
        try {
            (arg1)->setSort((char const **)arg2);
            
        }_CATCHALL(,);
    }
    {
        int i;
        for (i=0; i<size2-1; i++)
        
        delete[] arg2[i];
        delete[] arg2;
        
        
        
        
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Sort_1setSort_1_1SWIG_13(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    lucene::search::Sort *arg1 = (lucene::search::Sort *) 0 ;
    lucene::search::SortField *arg2 = (lucene::search::SortField *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Sort **)(void *)&jarg1; 
    arg2 = *(lucene::search::SortField **)(void *)&jarg2; 
    {
        try {
            arg2->__cl_addref();  	(arg1)->setSort(arg2);
        }_CATCHALL(,);   
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Sort_1setSort_1_1SWIG_14(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    lucene::search::Sort *arg1 = (lucene::search::Sort *) 0 ;
    lucene::search::SortField **arg2 = (lucene::search::SortField **) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Sort **)(void *)&jarg1; 
    
    _CL_p_p_lucene__search__SortFieldArray* _obj_arg2 =($symname Array)jarg2;xxx
    arg2 = _obj_arg2->array;
    
    {
        try{
            int i=0;    	int32_t arg2plen=0;    	while(arg2[arg2plen]!=NULL) arg2plen++;    	lucene::search::SortField** arg2p = _CLNEW lucene::search::SortField*[arg2plen+1];    	for ( int i=0;i<arg2plen;i++ )arg2p[i]=(arg2p[i]->__cl_addref()>=0?arg2p[i]:arg2p[i]);   	arg2p[arg2plen]=NULL; arg2=arg2p;  	  (arg1)->setSort(arg2);
        }_CATCHALL(,);   
    }
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_Sort_1toString(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::search::Sort *arg1 = (lucene::search::Sort *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Sort **)(void *)&jarg1; 
    {
        try {
            result = (char *)((lucene::search::Sort const *)arg1)->toString();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    _CLDELETE_CaARRAY(result);
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1Explanation(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::Explanation *arg1 = (lucene::search::Explanation *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Explanation **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jdouble JNICALL Java_CLjava_CLjavaJNI_Explanation_1getValue(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jdouble jresult = 0 ;
    lucene::search::Explanation *arg1 = (lucene::search::Explanation *) 0 ;
    float_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Explanation **)(void *)&jarg1; 
    {
        try {
            result = (arg1)->getValue();
            
        }_CATCHALL(0,);
    }
    jresult = (jdouble)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Explanation_1setValue(JNIEnv *jenv, jclass jcls, jlong jarg1, jdouble jarg2) {
    lucene::search::Explanation *arg1 = (lucene::search::Explanation *) 0 ;
    float_t arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Explanation **)(void *)&jarg1; 
    arg2 = (float_t)jarg2; 
    {
        try {
            (arg1)->setValue(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_Explanation_1getDescription(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::search::Explanation *arg1 = (lucene::search::Explanation *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Explanation **)(void *)&jarg1; 
    {
        try {
            result = (char *)(arg1)->getDescription();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Explanation_1addDetail(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    lucene::search::Explanation *arg1 = (lucene::search::Explanation *) 0 ;
    lucene::search::Explanation *arg2 = (lucene::search::Explanation *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Explanation **)(void *)&jarg1; 
    arg2 = *(lucene::search::Explanation **)(void *)&jarg2; 
    {
        try {
            (arg1)->addDetail(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_Explanation_1toString(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::search::Explanation *arg1 = (lucene::search::Explanation *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Explanation **)(void *)&jarg1; 
    {
        try {
            result = (char *)(arg1)->toString();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    _CLDELETE_CaARRAY(result);
    return jresult;
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_Explanation_1toHtml(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::search::Explanation *arg1 = (lucene::search::Explanation *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Explanation **)(void *)&jarg1; 
    {
        try {
            result = (char *)(arg1)->toHtml();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1Hits(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::Hits *arg1 = (lucene::search::Hits *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Hits **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_Hits_1length(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::search::Hits *arg1 = (lucene::search::Hits *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Hits **)(void *)&jarg1; 
    {
        try {
            result = ((lucene::search::Hits const *)arg1)->length();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Hits_1doc(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jlong jresult = 0 ;
    lucene::search::Hits *arg1 = (lucene::search::Hits *) 0 ;
    int32_t arg2 ;
    lucene::document::Document *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Hits **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            {
                lucene::document::Document &_result_ref = (arg1)->doc(arg2);
                result = (lucene::document::Document *) &_result_ref;
            }
            
        }_CATCHALL(0,);
    }
    *(lucene::document::Document **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_Hits_1id(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jint jresult = 0 ;
    lucene::search::Hits *arg1 = (lucene::search::Hits *) 0 ;
    int32_t arg2 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Hits **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            result = (arg1)->id(arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jdouble JNICALL Java_CLjava_CLjavaJNI_Hits_1score(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jdouble jresult = 0 ;
    lucene::search::Hits *arg1 = (lucene::search::Hits *) 0 ;
    int32_t arg2 ;
    float_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Hits **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            result = (arg1)->score(arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jdouble)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1Searchable(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::Searchable *arg1 = (lucene::search::Searchable *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Searchable **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Searchable_1close(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::Searchable *arg1 = (lucene::search::Searchable *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Searchable **)(void *)&jarg1; 
    {
        try {
            (arg1)->close();
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_Searchable_1docFreq(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    jint jresult = 0 ;
    lucene::search::Searchable *arg1 = (lucene::search::Searchable *) 0 ;
    lucene::index::Term *arg2 = (lucene::index::Term *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Searchable **)(void *)&jarg1; 
    arg2 = *(lucene::index::Term **)(void *)&jarg2; 
    {
        try {
            result = ((lucene::search::Searchable const *)arg1)->docFreq((lucene::index::Term const *)arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_Searchable_1maxDoc(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::search::Searchable *arg1 = (lucene::search::Searchable *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Searchable **)(void *)&jarg1; 
    {
        try {
            result = ((lucene::search::Searchable const *)arg1)->maxDoc();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Searchable_1doc(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jlong jresult = 0 ;
    lucene::search::Searchable *arg1 = (lucene::search::Searchable *) 0 ;
    int32_t arg2 ;
    lucene::document::Document *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Searchable **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            result = (lucene::document::Document *)(arg1)->doc(arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::document::Document **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Searchable_1explain(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2, jint jarg3) {
    jlong jresult = 0 ;
    lucene::search::Searchable *arg1 = (lucene::search::Searchable *) 0 ;
    lucene::search::Query *arg2 = (lucene::search::Query *) 0 ;
    int32_t arg3 ;
    lucene::search::Explanation *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Searchable **)(void *)&jarg1; 
    arg2 = *(lucene::search::Query **)(void *)&jarg2; 
    arg3 = (int32_t)jarg3; 
    {
        try {
            result = (lucene::search::Explanation *)(arg1)->explain(arg2,arg3);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Explanation **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1Searcher(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::Searcher *arg1 = (lucene::search::Searcher *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Searcher **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Searcher_1search_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    jlong jresult = 0 ;
    lucene::search::Searcher *arg1 = (lucene::search::Searcher *) 0 ;
    lucene::search::Query *arg2 = (lucene::search::Query *) 0 ;
    lucene::search::Hits *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Searcher **)(void *)&jarg1; 
    arg2 = *(lucene::search::Query **)(void *)&jarg2; 
    {
        try {
            result = (lucene::search::Hits *)(arg1)->search(arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Hits **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Searcher_1search_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2, jlong jarg3) {
    jlong jresult = 0 ;
    lucene::search::Searcher *arg1 = (lucene::search::Searcher *) 0 ;
    lucene::search::Query *arg2 = (lucene::search::Query *) 0 ;
    lucene::search::Filter *arg3 = (lucene::search::Filter *) 0 ;
    lucene::search::Hits *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Searcher **)(void *)&jarg1; 
    arg2 = *(lucene::search::Query **)(void *)&jarg2; 
    arg3 = *(lucene::search::Filter **)(void *)&jarg3; 
    {
        try {
            result = (lucene::search::Hits *)(arg1)->search(arg2,(lucene::search::Filter const *)arg3);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Hits **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Searcher_1search_1_1SWIG_12(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2, jlong jarg3) {
    jlong jresult = 0 ;
    lucene::search::Searcher *arg1 = (lucene::search::Searcher *) 0 ;
    lucene::search::Query *arg2 = (lucene::search::Query *) 0 ;
    lucene::search::Sort *arg3 = (lucene::search::Sort *) 0 ;
    lucene::search::Hits *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Searcher **)(void *)&jarg1; 
    arg2 = *(lucene::search::Query **)(void *)&jarg2; 
    arg3 = *(lucene::search::Sort **)(void *)&jarg3; 
    {
        try {
            result = (lucene::search::Hits *)(arg1)->search(arg2,(lucene::search::Sort const *)arg3);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Hits **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Searcher_1search_1_1SWIG_13(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2, jlong jarg3, jlong jarg4) {
    jlong jresult = 0 ;
    lucene::search::Searcher *arg1 = (lucene::search::Searcher *) 0 ;
    lucene::search::Query *arg2 = (lucene::search::Query *) 0 ;
    lucene::search::Filter *arg3 = (lucene::search::Filter *) 0 ;
    lucene::search::Sort *arg4 = (lucene::search::Sort *) 0 ;
    lucene::search::Hits *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Searcher **)(void *)&jarg1; 
    arg2 = *(lucene::search::Query **)(void *)&jarg2; 
    arg3 = *(lucene::search::Filter **)(void *)&jarg3; 
    arg4 = *(lucene::search::Sort **)(void *)&jarg4; 
    {
        try {
            result = (lucene::search::Hits *)(arg1)->search(arg2,(lucene::search::Filter const *)arg3,(lucene::search::Sort const *)arg4);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Hits **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Searcher_1setSimilarity(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    lucene::search::Searcher *arg1 = (lucene::search::Searcher *) 0 ;
    lucene::search::Similarity *arg2 = (lucene::search::Similarity *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Searcher **)(void *)&jarg1; 
    arg2 = *(lucene::search::Similarity **)(void *)&jarg2; 
    {
        try {
            (arg1)->setSimilarity(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Searcher_1getSimilarity(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::search::Searcher *arg1 = (lucene::search::Searcher *) 0 ;
    lucene::search::Similarity *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Searcher **)(void *)&jarg1; 
    {
        try {
            result = (lucene::search::Similarity *)(arg1)->getSimilarity();
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Similarity **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1Query(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::Query *arg1 = (lucene::search::Query *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Query **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_Query_1setBoost(JNIEnv *jenv, jclass jcls, jlong jarg1, jdouble jarg2) {
    lucene::search::Query *arg1 = (lucene::search::Query *) 0 ;
    float_t arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Query **)(void *)&jarg1; 
    arg2 = (float_t)jarg2; 
    {
        try {
            (arg1)->setBoost(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jdouble JNICALL Java_CLjava_CLjavaJNI_Query_1getBoost(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jdouble jresult = 0 ;
    lucene::search::Query *arg1 = (lucene::search::Query *) 0 ;
    float_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Query **)(void *)&jarg1; 
    {
        try {
            result = ((lucene::search::Query const *)arg1)->getBoost();
            
        }_CATCHALL(0,);
    }
    jresult = (jdouble)result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Query_1rewrite(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    jlong jresult = 0 ;
    lucene::search::Query *arg1 = (lucene::search::Query *) 0 ;
    lucene::index::IndexReader *arg2 = (lucene::index::IndexReader *) 0 ;
    lucene::search::Query *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Query **)(void *)&jarg1; 
    arg2 = *(lucene::index::IndexReader **)(void *)&jarg2; 
    {
        try {
            result = (lucene::search::Query *)(arg1)->rewrite(arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Query **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Query_1getSimilarity(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    jlong jresult = 0 ;
    lucene::search::Query *arg1 = (lucene::search::Query *) 0 ;
    lucene::search::Searcher *arg2 = (lucene::search::Searcher *) 0 ;
    lucene::search::Similarity *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Query **)(void *)&jarg1; 
    arg2 = *(lucene::search::Searcher **)(void *)&jarg2; 
    {
        try {
            result = (lucene::search::Similarity *)(arg1)->getSimilarity(arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Similarity **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_Query_1clone(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::search::Query *arg1 = (lucene::search::Query *) 0 ;
    lucene::search::Query *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Query **)(void *)&jarg1; 
    {
        try {
            result = (lucene::search::Query *)(arg1)->clone();
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Query **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_Query_1toString_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jlong jarg1, jstring jarg2) {
    jstring jresult = 0 ;
    lucene::search::Query *arg1 = (lucene::search::Query *) 0 ;
    char *arg2 = (char *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Query **)(void *)&jarg1; 
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    {
        try {
            result = (char *)(arg1)->toString((char const *)arg2);
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    _CLDELETE_CaARRAY(result);
    return jresult;
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_Query_1equals(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    jboolean jresult = 0 ;
    lucene::search::Query *arg1 = (lucene::search::Query *) 0 ;
    lucene::search::Query *arg2 = (lucene::search::Query *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Query **)(void *)&jarg1; 
    arg2 = *(lucene::search::Query **)(void *)&jarg2; 
    {
        try {
            result = (bool)((lucene::search::Query const *)arg1)->equals(arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_Query_1hashCode(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::search::Query *arg1 = (lucene::search::Query *) 0 ;
    long result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Query **)(void *)&jarg1; 
    {
        try {
            result = (long)((lucene::search::Query const *)arg1)->hashCode();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_Query_1toString_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::search::Query *arg1 = (lucene::search::Query *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::Query **)(void *)&jarg1; 
    {
        try {
            result = (char *)(arg1)->toString();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    _CLDELETE_CaARRAY(result);
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1IndexSearcher_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jstring jarg1) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    lucene::search::IndexSearcher *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        try {
            result = (lucene::search::IndexSearcher *)_CLNEW lucene::search::IndexSearcher((char const *)arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::IndexSearcher **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1IndexSearcher_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::store::Directory *arg1 = (lucene::store::Directory *) 0 ;
    lucene::search::IndexSearcher *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::store::Directory **)(void *)&jarg1; 
    {
        try {
            result = (lucene::search::IndexSearcher *)_CLNEW lucene::search::IndexSearcher(arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::IndexSearcher **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1IndexSearcher_1_1SWIG_12(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::index::IndexReader *arg1 = (lucene::index::IndexReader *) 0 ;
    lucene::search::IndexSearcher *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::IndexReader **)(void *)&jarg1; 
    {
        try {
            result = (lucene::search::IndexSearcher *)_CLNEW lucene::search::IndexSearcher(arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::IndexSearcher **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1IndexSearcher(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::IndexSearcher *arg1 = (lucene::search::IndexSearcher *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::IndexSearcher **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_IndexSearcher_1getReader(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::search::IndexSearcher *arg1 = (lucene::search::IndexSearcher *) 0 ;
    lucene::index::IndexReader *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::IndexSearcher **)(void *)&jarg1; 
    {
        try {
            result = (lucene::index::IndexReader *)(arg1)->getReader();
            
        }_CATCHALL(0,);
    }
    *(lucene::index::IndexReader **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1MultiSearcher(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::search::Searchable **arg1 = (lucene::search::Searchable **) 0 ;
    lucene::search::MultiSearcher *result;
    
    (void)jenv;
    (void)jcls;
    
    _CL_p_p_lucene__search__SearchableArray* _obj_arg1 =($symname Array)jarg1;xxx
    arg1 = _obj_arg1->array;
    
    {
        try {
            result = (lucene::search::MultiSearcher *)_CLNEW lucene::search::MultiSearcher(arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::MultiSearcher **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1MultiSearcher(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::MultiSearcher *arg1 = (lucene::search::MultiSearcher *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::MultiSearcher **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_MultiSearcher_1searcherIndex(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jint jresult = 0 ;
    lucene::search::MultiSearcher *arg1 = (lucene::search::MultiSearcher *) 0 ;
    int32_t arg2 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::MultiSearcher **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            result = (arg1)->searcherIndex(arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_MultiSearcher_1subSearcher(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jint jresult = 0 ;
    lucene::search::MultiSearcher *arg1 = (lucene::search::MultiSearcher *) 0 ;
    int32_t arg2 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::MultiSearcher **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            result = (arg1)->subSearcher(arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_MultiSearcher_1subDoc(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    jint jresult = 0 ;
    lucene::search::MultiSearcher *arg1 = (lucene::search::MultiSearcher *) 0 ;
    int32_t arg2 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::MultiSearcher **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            result = (arg1)->subDoc(arg2);
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1BooleanQuery(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    lucene::search::BooleanQuery *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (lucene::search::BooleanQuery *)_CLNEW lucene::search::BooleanQuery();
            
        }_CATCHALL(0,);
    }
    *(lucene::search::BooleanQuery **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1BooleanQuery(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::BooleanQuery *arg1 = (lucene::search::BooleanQuery *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::BooleanQuery **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_BooleanQuery_1getMaxClauseCount(JNIEnv *jenv, jclass jcls) {
    jint jresult = 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = lucene::search::BooleanQuery::getMaxClauseCount();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_BooleanQuery_1setMaxClauseCount(JNIEnv *jenv, jclass jcls, jint jarg1) {
    int32_t arg1 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = (int32_t)jarg1; 
    {
        try {
            lucene::search::BooleanQuery::setMaxClauseCount(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_BooleanQuery_1add(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2, jboolean jarg3, jboolean jarg4) {
    lucene::search::BooleanQuery *arg1 = (lucene::search::BooleanQuery *) 0 ;
    lucene::search::Query *arg2 = (lucene::search::Query *) 0 ;
    bool arg3 ;
    bool arg4 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::BooleanQuery **)(void *)&jarg1; 
    arg2 = *(lucene::search::Query **)(void *)&jarg2; 
    arg3 = jarg3 ? true : false; 
    arg4 = jarg4 ? true : false; 
    {
        try {
            arg2->__cl_addref();  	(arg1)->add(arg2,arg3,arg4);
        }_CATCHALL(,);   
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_BooleanQuery_1getClauseCount(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::search::BooleanQuery *arg1 = (lucene::search::BooleanQuery *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::BooleanQuery **)(void *)&jarg1; 
    {
        try {
            result = (arg1)->getClauseCount();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1TermQuery(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::index::Term *arg1 = (lucene::index::Term *) 0 ;
    lucene::search::TermQuery *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::Term **)(void *)&jarg1; 
    {
        try {
            result = (lucene::search::TermQuery *)_CLNEW lucene::search::TermQuery(arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::TermQuery **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1TermQuery(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::TermQuery *arg1 = (lucene::search::TermQuery *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::TermQuery **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_TermQuery_1getTerm(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::search::TermQuery *arg1 = (lucene::search::TermQuery *) 0 ;
    lucene::index::Term *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::TermQuery **)(void *)&jarg1; 
    {
        try {
            result = (lucene::index::Term *)(arg1)->getTerm();
            
        }_CATCHALL(0,);
    }
    *(lucene::index::Term **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1PhraseQuery(JNIEnv *jenv, jclass jcls) {
    jlong jresult = 0 ;
    lucene::search::PhraseQuery *result;
    
    (void)jenv;
    (void)jcls;
    {
        try {
            result = (lucene::search::PhraseQuery *)_CLNEW lucene::search::PhraseQuery();
            
        }_CATCHALL(0,);
    }
    *(lucene::search::PhraseQuery **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1PhraseQuery(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::PhraseQuery *arg1 = (lucene::search::PhraseQuery *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::PhraseQuery **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_PhraseQuery_1setSlop(JNIEnv *jenv, jclass jcls, jlong jarg1, jint jarg2) {
    lucene::search::PhraseQuery *arg1 = (lucene::search::PhraseQuery *) 0 ;
    int32_t arg2 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::PhraseQuery **)(void *)&jarg1; 
    arg2 = (int32_t)jarg2; 
    {
        try {
            (arg1)->setSlop(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jint JNICALL Java_CLjava_CLjavaJNI_PhraseQuery_1getSlop(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jint jresult = 0 ;
    lucene::search::PhraseQuery *arg1 = (lucene::search::PhraseQuery *) 0 ;
    int32_t result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::PhraseQuery **)(void *)&jarg1; 
    {
        try {
            result = (arg1)->getSlop();
            
        }_CATCHALL(0,);
    }
    jresult = (jint)result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_PhraseQuery_1add_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    lucene::search::PhraseQuery *arg1 = (lucene::search::PhraseQuery *) 0 ;
    lucene::index::Term *arg2 = (lucene::index::Term *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::PhraseQuery **)(void *)&jarg1; 
    arg2 = *(lucene::index::Term **)(void *)&jarg2; 
    {
        try {
            (arg1)->add(arg2);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_PhraseQuery_1add_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2, jint jarg3) {
    lucene::search::PhraseQuery *arg1 = (lucene::search::PhraseQuery *) 0 ;
    lucene::index::Term *arg2 = (lucene::index::Term *) 0 ;
    int32_t arg3 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::PhraseQuery **)(void *)&jarg1; 
    arg2 = *(lucene::index::Term **)(void *)&jarg2; 
    arg3 = (int32_t)jarg3; 
    {
        try {
            (arg1)->add(arg2,arg3);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1MultiTermQuery(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::MultiTermQuery *arg1 = (lucene::search::MultiTermQuery *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::MultiTermQuery **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_MultiTermQuery_1getTerm(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::search::MultiTermQuery *arg1 = (lucene::search::MultiTermQuery *) 0 ;
    lucene::index::Term *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::MultiTermQuery **)(void *)&jarg1; 
    {
        try {
            result = (lucene::index::Term *)((lucene::search::MultiTermQuery const *)arg1)->getTerm();
            
        }_CATCHALL(0,);
    }
    *(lucene::index::Term **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1WildcardQuery(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::index::Term *arg1 = (lucene::index::Term *) 0 ;
    lucene::search::WildcardQuery *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::Term **)(void *)&jarg1; 
    {
        try {
            result = (lucene::search::WildcardQuery *)_CLNEW lucene::search::WildcardQuery(arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::WildcardQuery **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1WildcardQuery(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::WildcardQuery *arg1 = (lucene::search::WildcardQuery *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::WildcardQuery **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1RangeQuery(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2, jboolean jarg3) {
    jlong jresult = 0 ;
    lucene::index::Term *arg1 = (lucene::index::Term *) 0 ;
    lucene::index::Term *arg2 = (lucene::index::Term *) 0 ;
    bool arg3 ;
    lucene::search::RangeQuery *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::Term **)(void *)&jarg1; 
    arg2 = *(lucene::index::Term **)(void *)&jarg2; 
    arg3 = jarg3 ? true : false; 
    {
        try {
            result = (lucene::search::RangeQuery *)_CLNEW lucene::search::RangeQuery(arg1,arg2,arg3);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::RangeQuery **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1RangeQuery(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::RangeQuery *arg1 = (lucene::search::RangeQuery *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::RangeQuery **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_RangeQuery_1getLowerTerm(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::search::RangeQuery *arg1 = (lucene::search::RangeQuery *) 0 ;
    lucene::index::Term *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::RangeQuery **)(void *)&jarg1; 
    {
        try {
            result = (lucene::index::Term *)((lucene::search::RangeQuery const *)arg1)->getLowerTerm();
            
        }_CATCHALL(0,);
    }
    *(lucene::index::Term **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_RangeQuery_1getUpperTerm(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::search::RangeQuery *arg1 = (lucene::search::RangeQuery *) 0 ;
    lucene::index::Term *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::RangeQuery **)(void *)&jarg1; 
    {
        try {
            result = (lucene::index::Term *)((lucene::search::RangeQuery const *)arg1)->getUpperTerm();
            
        }_CATCHALL(0,);
    }
    *(lucene::index::Term **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jboolean JNICALL Java_CLjava_CLjavaJNI_RangeQuery_1isInclusive(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jboolean jresult = 0 ;
    lucene::search::RangeQuery *arg1 = (lucene::search::RangeQuery *) 0 ;
    bool result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::RangeQuery **)(void *)&jarg1; 
    {
        try {
            result = (bool)((lucene::search::RangeQuery const *)arg1)->isInclusive();
            
        }_CATCHALL(0,);
    }
    jresult = (jboolean)result; 
    return jresult;
}


JNIEXPORT jstring JNICALL Java_CLjava_CLjavaJNI_RangeQuery_1getField(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jstring jresult = 0 ;
    lucene::search::RangeQuery *arg1 = (lucene::search::RangeQuery *) 0 ;
    char *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::RangeQuery **)(void *)&jarg1; 
    {
        try {
            result = (char *)((lucene::search::RangeQuery const *)arg1)->getField();
            
        }_CATCHALL(0,);
    }
    {
        if(result) jresult = jenv->NewStringUTF(result); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1PrefixQuery(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::index::Term *arg1 = (lucene::index::Term *) 0 ;
    lucene::search::PrefixQuery *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::index::Term **)(void *)&jarg1; 
    {
        try {
            result = (lucene::search::PrefixQuery *)_CLNEW lucene::search::PrefixQuery(arg1);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::PrefixQuery **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1PrefixQuery(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::search::PrefixQuery *arg1 = (lucene::search::PrefixQuery *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::PrefixQuery **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_PrefixQuery_1getPrefix(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong jresult = 0 ;
    lucene::search::PrefixQuery *arg1 = (lucene::search::PrefixQuery *) 0 ;
    lucene::index::Term *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::search::PrefixQuery **)(void *)&jarg1; 
    {
        try {
            result = (lucene::index::Term *)(arg1)->getPrefix();
            
        }_CATCHALL(0,);
    }
    *(lucene::index::Term **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_new_1QueryParser(JNIEnv *jenv, jclass jcls, jstring jarg1, jlong jarg2) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    lucene::analysis::Analyzer *arg2 = (lucene::analysis::Analyzer *) 0 ;
    lucene::queryParser::QueryParser *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    arg2 = *(lucene::analysis::Analyzer **)(void *)&jarg2; 
    {
        try {
            result = (lucene::queryParser::QueryParser *)_CLNEW lucene::queryParser::QueryParser((char const *)arg1,arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::queryParser::QueryParser **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    return jresult;
}


JNIEXPORT void JNICALL Java_CLjava_CLjavaJNI_delete_1QueryParser(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    lucene::queryParser::QueryParser *arg1 = (lucene::queryParser::QueryParser *) 0 ;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::queryParser::QueryParser **)(void *)&jarg1; 
    {
        try {
            _CLDECDELETE(arg1);
            
        }_CATCHALL(,);
    }
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_QueryParser_1parse_1_1SWIG_10(JNIEnv *jenv, jclass jcls, jlong jarg1, jstring jarg2) {
    jlong jresult = 0 ;
    lucene::queryParser::QueryParser *arg1 = (lucene::queryParser::QueryParser *) 0 ;
    char *arg2 = (char *) 0 ;
    lucene::search::Query *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::queryParser::QueryParser **)(void *)&jarg1; 
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    {
        try {
            result = (lucene::search::Query *)(arg1)->parse((char const *)arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Query **)(void *)&jresult = result; 
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_QueryParser_1parse_1_1SWIG_11(JNIEnv *jenv, jclass jcls, jlong jarg1, jlong jarg2) {
    jlong jresult = 0 ;
    lucene::queryParser::QueryParser *arg1 = (lucene::queryParser::QueryParser *) 0 ;
    lucene::util::Reader *arg2 = (lucene::util::Reader *) 0 ;
    lucene::search::Query *result;
    
    (void)jenv;
    (void)jcls;
    arg1 = *(lucene::queryParser::QueryParser **)(void *)&jarg1; 
    arg2 = *(lucene::util::Reader **)(void *)&jarg2; 
    {
        try {
            result = (lucene::search::Query *)(arg1)->parse(arg2);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Query **)(void *)&jresult = result; 
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_QueryParser_1parse_1_1SWIG_12(JNIEnv *jenv, jclass jcls, jstring jarg1, jstring jarg2, jlong jarg3) {
    jlong jresult = 0 ;
    char *arg1 = (char *) 0 ;
    char *arg2 = (char *) 0 ;
    lucene::analysis::Analyzer *arg3 = (lucene::analysis::Analyzer *) 0 ;
    lucene::search::Query *result;
    
    (void)jenv;
    (void)jcls;
    {
        arg1 = 0;
        if (jarg1) {
            arg1 = (char *)jenv->GetStringUTFChars(jarg1, 0);
            if (!arg1) return 0;
        }
    }
    {
        arg2 = 0;
        if (jarg2) {
            arg2 = (char *)jenv->GetStringUTFChars(jarg2, 0);
            if (!arg2) return 0;
        }
    }
    arg3 = *(lucene::analysis::Analyzer **)(void *)&jarg3; 
    {
        try {
            result = (lucene::search::Query *)lucene::queryParser::QueryParser::parse((char const *)arg1,(char const *)arg2,arg3);
            
        }_CATCHALL(0,);
    }
    *(lucene::search::Query **)(void *)&jresult = result; 
    {
        if (arg1) jenv->ReleaseStringUTFChars(jarg1, arg1); 
    }
    {
        if (arg2) jenv->ReleaseStringUTFChars(jarg2, arg2); 
    }
    return jresult;
}


JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGStringReaderUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::util::Reader **)(void *)&baseptr = *(lucene::util::StringReader **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGFileReaderUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::util::Reader **)(void *)&baseptr = *(lucene::util::FileReader **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGFSDirectoryUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::store::Directory **)(void *)&baseptr = *(lucene::store::FSDirectory **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGRAMDirectoryUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::store::Directory **)(void *)&baseptr = *(lucene::store::RAMDirectory **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGWhitespaceAnalyzerUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::analysis::Analyzer **)(void *)&baseptr = *(lucene::analysis::WhitespaceAnalyzer **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGSimpleAnalyzerUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::analysis::Analyzer **)(void *)&baseptr = *(lucene::analysis::SimpleAnalyzer **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGStopAnalyzerUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::analysis::Analyzer **)(void *)&baseptr = *(lucene::analysis::StopAnalyzer **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGPerFieldAnalyzerWrapperUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::analysis::Analyzer **)(void *)&baseptr = *(lucene::analysis::PerFieldAnalyzerWrapper **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGStandardAnalyzerUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::analysis::Analyzer **)(void *)&baseptr = *(lucene::analysis::standard::StandardAnalyzer **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGTermPositionsUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::index::TermDocs **)(void *)&baseptr = *(lucene::index::TermPositions **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGMultiReaderUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::index::IndexReader **)(void *)&baseptr = *(lucene::index::MultiReader **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGDateFilterUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::search::Filter **)(void *)&baseptr = *(lucene::search::DateFilter **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGSearcherUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::search::Searchable **)(void *)&baseptr = *(lucene::search::Searcher **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGIndexSearcherUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::search::Searcher **)(void *)&baseptr = *(lucene::search::IndexSearcher **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGMultiSearcherUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::search::Searcher **)(void *)&baseptr = *(lucene::search::MultiSearcher **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGBooleanQueryUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::search::Query **)(void *)&baseptr = *(lucene::search::BooleanQuery **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGTermQueryUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::search::Query **)(void *)&baseptr = *(lucene::search::TermQuery **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGPhraseQueryUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::search::Query **)(void *)&baseptr = *(lucene::search::PhraseQuery **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGMultiTermQueryUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::search::Query **)(void *)&baseptr = *(lucene::search::MultiTermQuery **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGWildcardQueryUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::search::MultiTermQuery **)(void *)&baseptr = *(lucene::search::WildcardQuery **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGRangeQueryUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::search::Query **)(void *)&baseptr = *(lucene::search::RangeQuery **)(void *)&jarg1;
    return baseptr;
}

JNIEXPORT jlong JNICALL Java_CLjava_CLjavaJNI_SWIGPrefixQueryUpcast(JNIEnv *jenv, jclass jcls, jlong jarg1) {
    jlong baseptr = 0;
    (void)jenv;
    (void)jcls;
    *(lucene::search::Query **)(void *)&baseptr = *(lucene::search::PrefixQuery **)(void *)&jarg1;
    return baseptr;
}

#ifdef __cplusplus
}
#endif

