//Auto-generated by kalyptus. DO NOT EDIT.
#include <qregexp.h>
#include <kfind.h>
#include <qstring.h>

#include <qtjava/QtSupport.h>
#include <kdejava/KDESupport.h>
#include <kdejava/KFind.h>

class KFindJBridge : public KFind
{
public:
	KFindJBridge(const QString& arg1,long arg2,QWidget* arg3) : KFind(arg1,arg2,arg3) {};
	void public_resetCounts() {
		KFind::resetCounts();
		return;
	}
	void public_displayFinalDialog() {
		KFind::displayFinalDialog();
		return;
	}
	QWidget* protected_parentWidget() {
		return (QWidget*) KFind::parentWidget();
	}
	QWidget* protected_dialogsParent() {
		return (QWidget*) KFind::dialogsParent();
	}
	void protected_slotFindNext() {
		KFind::slotFindNext();
		return;
	}
	void protected_slotDialogClosed() {
		KFind::slotDialogClosed();
		return;
	}
	~KFindJBridge() {QtSupport::qtKeyDeleted(this);}
	void displayFinalDialog() {
		if (!QtSupport::voidDelegate(this,"org.kde.koala.KFind","displayFinalDialog")) {
			KFind::displayFinalDialog();
		}
		return;
	}
	void resetCounts() {
		if (!QtSupport::voidDelegate(this,"org.kde.koala.KFind","resetCounts")) {
			KFind::resetCounts();
		}
		return;
	}
	void removeChild(QObject* arg1) {
		if (!QtSupport::eventDelegate(this,"removeChild",(void*)arg1,"org.kde.qt.QObject")) {
			QObject::removeChild(arg1);
		}
		return;
	}
	void customEvent(QCustomEvent* arg1) {
		if (!QtSupport::eventDelegate(this,"customEvent",(void*)arg1,"org.kde.qt.QCustomEvent")) {
			QObject::customEvent(arg1);
		}
		return;
	}
	void timerEvent(QTimerEvent* arg1) {
		if (!QtSupport::eventDelegate(this,"timerEvent",(void*)arg1,"org.kde.qt.QTimerEvent")) {
			QObject::timerEvent(arg1);
		}
		return;
	}
	void childEvent(QChildEvent* arg1) {
		if (!QtSupport::eventDelegate(this,"childEvent",(void*)arg1,"org.kde.qt.QChildEvent")) {
			QObject::childEvent(arg1);
		}
		return;
	}
	void insertChild(QObject* arg1) {
		if (!QtSupport::eventDelegate(this,"insertChild",(void*)arg1,"org.kde.qt.QObject")) {
			QObject::insertChild(arg1);
		}
		return;
	}
	bool eventFilter(QObject* object,QEvent* event) {
		if (!QtSupport::eventFilterDelegate(this,"org.kde.koala.KFind",object,event)) {
			return QObject::eventFilter(object,event);
		} else {
			return TRUE;
		}
	}
};

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KFind_className(JNIEnv* env, jobject obj)
{
	const char* _qstring;
	_qstring = ((KFind*) QtSupport::getQt(env, obj))->className();
	return QtSupport::fromCharString(env, (char *) _qstring);
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KFind_closeFindNextDialog(JNIEnv* env, jobject obj)
{
	((KFind*) QtSupport::getQt(env, obj))->closeFindNextDialog();
	return;
}

JNIEXPORT jobject JNICALL
Java_org_kde_koala_KFind_dialogsParent(JNIEnv* env, jobject obj)
{
	jobject xret = QtSupport::objectForQtKey(env, (void*)((KFindJBridge*) QtSupport::getQt(env, obj))->protected_dialogsParent(), "org.kde.qt.QWidget");
	return xret;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KFind_displayFinalDialog(JNIEnv* env, jobject obj)
{
	((KFindJBridge*) QtSupport::getQt(env, obj))->public_displayFinalDialog();
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KFind_dispose(JNIEnv* env, jobject obj)
{
	Java_org_kde_koala_KFind_finalize(env, obj);
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KFind_finalize(JNIEnv* env, jobject obj)
{
	if (QtSupport::allocatedInJavaWorld(env, obj) && ((KFind*)QtSupport::getQt(env, obj))->parent() == 0) {
		delete (KFind*)QtSupport::getQt(env, obj);
		QtSupport::setQt(env, obj, 0);
	}
	return;
}

JNIEXPORT jobject JNICALL
Java_org_kde_koala_KFind_findNextDialog__(JNIEnv* env, jobject obj)
{
	jobject xret = QtSupport::objectForQtKey(env, (void*)((KFind*) QtSupport::getQt(env, obj))->findNextDialog(), "org.kde.koala.KDialogBase");
	return xret;
}

JNIEXPORT jobject JNICALL
Java_org_kde_koala_KFind_findNextDialog__Z(JNIEnv* env, jobject obj, jboolean create)
{
	jobject xret = QtSupport::objectForQtKey(env, (void*)((KFind*) QtSupport::getQt(env, obj))->findNextDialog((bool) create), "org.kde.koala.KDialogBase");
	return xret;
}

JNIEXPORT jint JNICALL
Java_org_kde_koala_KFind_find__(JNIEnv* env, jobject obj)
{
	jint xret = (jint) ((KFind*) QtSupport::getQt(env, obj))->find();
	return xret;
}

JNIEXPORT jint JNICALL
Java_org_kde_koala_KFind_find__Ljava_lang_String_2Ljava_lang_String_2IJ_3I(JNIEnv* env, jclass cls, jstring text, jstring pattern, jint index, jlong options, jintArray matchedlength)
{
	(void) cls;
static QString* _qstring_text = 0;
static QString* _qstring_pattern = 0;
	int* _int_matchedlength = QtSupport::toIntPtr(env, matchedlength);
	jint xret = (jint) KFindJBridge::find((const QString&)*(QString*) QtSupport::toQString(env, text, &_qstring_text), (const QString&)*(QString*) QtSupport::toQString(env, pattern, &_qstring_pattern), (int) index, (long) options,  (int*) _int_matchedlength);
	env->SetIntArrayRegion(matchedlength, 0, 1, (jint *) _int_matchedlength);
	return xret;
}

JNIEXPORT jint JNICALL
Java_org_kde_koala_KFind_find__Ljava_lang_String_2Lorg_kde_qt_QRegExp_2IJ_3I(JNIEnv* env, jclass cls, jstring text, jobject pattern, jint index, jlong options, jintArray matchedlength)
{
	(void) cls;
static QString* _qstring_text = 0;
	int* _int_matchedlength = QtSupport::toIntPtr(env, matchedlength);
	jint xret = (jint) KFindJBridge::find((const QString&)*(QString*) QtSupport::toQString(env, text, &_qstring_text), (const QRegExp&)*(const QRegExp*) QtSupport::getQt(env, pattern), (int) index, (long) options,  (int*) _int_matchedlength);
	env->SetIntArrayRegion(matchedlength, 0, 1, (jint *) _int_matchedlength);
	return xret;
}

JNIEXPORT jint JNICALL
Java_org_kde_koala_KFind_index(JNIEnv* env, jobject obj)
{
	jint xret = (jint) ((KFind*) QtSupport::getQt(env, obj))->index();
	return xret;
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KFind_isDisposed(JNIEnv* env, jobject obj)
{
	return (QtSupport::getQt(env, obj) == 0);
}

JNIEXPORT jobject JNICALL
Java_org_kde_koala_KFind_metaObject(JNIEnv* env, jobject obj)
{
	jobject xret = QtSupport::objectForQtKey(env, (void*)((KFind*) QtSupport::getQt(env, obj))->metaObject(), "org.kde.qt.QMetaObject");
	return xret;
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KFind_needData(JNIEnv* env, jobject obj)
{
	jboolean xret = (jboolean) ((KFind*) QtSupport::getQt(env, obj))->needData();
	return xret;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KFind_newKFind(JNIEnv* env, jobject obj, jstring pattern, jlong options, jobject parent)
{
static QString* _qstring_pattern = 0;
	if (QtSupport::getQt(env, obj) == 0) {
		QtSupport::setQt(env, obj, new KFindJBridge((const QString&)*(QString*) QtSupport::toQString(env, pattern, &_qstring_pattern), (long) options, (QWidget*) QtSupport::getQt(env, parent)));
		QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj));
	}
	return;
}

JNIEXPORT jint JNICALL
Java_org_kde_koala_KFind_numMatches(JNIEnv* env, jobject obj)
{
	jint xret = (jint) ((KFind*) QtSupport::getQt(env, obj))->numMatches();
	return xret;
}

JNIEXPORT jlong JNICALL
Java_org_kde_koala_KFind_options(JNIEnv* env, jobject obj)
{
	jlong xret = (jlong) ((KFind*) QtSupport::getQt(env, obj))->options();
	return xret;
}

JNIEXPORT jobject JNICALL
Java_org_kde_koala_KFind_parentWidget(JNIEnv* env, jobject obj)
{
	jobject xret = QtSupport::objectForQtKey(env, (void*)((KFindJBridge*) QtSupport::getQt(env, obj))->protected_parentWidget(), "org.kde.qt.QWidget");
	return xret;
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KFind_pattern(JNIEnv* env, jobject obj)
{
	QString  _qstring;
	_qstring = ((KFind*) QtSupport::getQt(env, obj))->pattern();
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KFind_resetCounts(JNIEnv* env, jobject obj)
{
	((KFindJBridge*) QtSupport::getQt(env, obj))->public_resetCounts();
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KFind_setData__ILjava_lang_String_2(JNIEnv* env, jobject obj, jint id, jstring data)
{
static QString* _qstring_data = 0;
	((KFind*) QtSupport::getQt(env, obj))->setData((int) id, (const QString&)*(QString*) QtSupport::toQString(env, data, &_qstring_data));
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KFind_setData__ILjava_lang_String_2I(JNIEnv* env, jobject obj, jint id, jstring data, jint startPos)
{
static QString* _qstring_data = 0;
	((KFind*) QtSupport::getQt(env, obj))->setData((int) id, (const QString&)*(QString*) QtSupport::toQString(env, data, &_qstring_data), (int) startPos);
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KFind_setData__Ljava_lang_String_2(JNIEnv* env, jobject obj, jstring data)
{
static QString* _qstring_data = 0;
	((KFind*) QtSupport::getQt(env, obj))->setData((const QString&)*(QString*) QtSupport::toQString(env, data, &_qstring_data));
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KFind_setData__Ljava_lang_String_2I(JNIEnv* env, jobject obj, jstring data, jint startPos)
{
static QString* _qstring_data = 0;
	((KFind*) QtSupport::getQt(env, obj))->setData((const QString&)*(QString*) QtSupport::toQString(env, data, &_qstring_data), (int) startPos);
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KFind_setOptions(JNIEnv* env, jobject obj, jlong options)
{
	((KFind*) QtSupport::getQt(env, obj))->setOptions((long) options);
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KFind_setPattern(JNIEnv* env, jobject obj, jstring pattern)
{
static QString* _qstring_pattern = 0;
	((KFind*) QtSupport::getQt(env, obj))->setPattern((const QString&)*(QString*) QtSupport::toQString(env, pattern, &_qstring_pattern));
	return;
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KFind_shouldRestart__(JNIEnv* env, jobject obj)
{
	jboolean xret = (jboolean) ((KFind*) QtSupport::getQt(env, obj))->shouldRestart();
	return xret;
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KFind_shouldRestart__Z(JNIEnv* env, jobject obj, jboolean forceAsking)
{
	jboolean xret = (jboolean) ((KFind*) QtSupport::getQt(env, obj))->shouldRestart((bool) forceAsking);
	return xret;
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KFind_shouldRestart__ZZ(JNIEnv* env, jobject obj, jboolean forceAsking, jboolean showNumMatches)
{
	jboolean xret = (jboolean) ((KFind*) QtSupport::getQt(env, obj))->shouldRestart((bool) forceAsking, (bool) showNumMatches);
	return xret;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KFind_slotDialogClosed(JNIEnv* env, jobject obj)
{
	((KFindJBridge*) QtSupport::getQt(env, obj))->protected_slotDialogClosed();
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KFind_slotFindNext(JNIEnv* env, jobject obj)
{
	((KFindJBridge*) QtSupport::getQt(env, obj))->protected_slotFindNext();
	return;
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KFind_validateMatch(JNIEnv* env, jobject obj, jstring text, jint index, jint matchedlength)
{
static QString* _qstring_text = 0;
	jboolean xret = (jboolean) ((KFind*) QtSupport::getQt(env, obj))->validateMatch((const QString&)*(QString*) QtSupport::toQString(env, text, &_qstring_text), (int) index, (int) matchedlength);
	return xret;
}

