/***************************************************************************
                            KURL.cpp -  description
                             -------------------
    begin                : Sun Jan 27 16:22:17 2002
    copyright            : (C) 2000-2001 Lost Highway Ltd.
    email                : Richard_Dale@tipitina.demon.co.uk
    generated by         : duke@tipitina on Sun Jan 27 16:22:17 2002, using kalyptus 0.9.
 ***************************************************************************/

/***************************************************************************
 *                                                                         *
 *   This program is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU General Public License as published by  *
 *   the Free Software Foundation; either version 2 of the License, or     *
 *   (at your option) any later version.                                   *
 *                                                                         *
***************************************************************************/

#define _BOOL_H_
#include <kurl.h>
#include <qstring.h>
#include <qcstring.h>

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

class KURLJBridge : public KURL
{
public:
	KURLJBridge() : KURL() {}
	~KURLJBridge() {QtSupport::qtKeyDeleted(this);}
	KURLJBridge(const QString& url, int encoding_hint) : KURL(url, encoding_hint) {}
	KURLJBridge(const char* url, int encoding_hint) : KURL(url, encoding_hint) {}
	KURLJBridge(const QCString& url, int encoding_hint) : KURL(url, encoding_hint) {}
	KURLJBridge(const KURL& u) : KURL(u) {}
	KURLJBridge(const QUrl& u) : KURL(u) {}
	KURLJBridge(const KURL& _baseurl, const QString& _rel_url, int encoding_hint) : KURL(_baseurl, _rel_url, encoding_hint) {}
	void protected_reset() {
		KURL::reset();
		return;
	}
	void protected_parse(const QString& _url, int encoding_hint) {
		KURL::parse(_url, encoding_hint);
		return;
	}
};


JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_newKURL__(JNIEnv *env, jobject obj)
{
	if (QtSupport::getQt(env, obj) == 0) {
		QtSupport::setQt(env, obj, new KURLJBridge());
		QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj));
	}
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_finalize(JNIEnv *env, jobject obj)
{
	if (QtSupport::allocatedInJavaWorld(env, obj)) {
		delete (KURL*)QtSupport::getQt(env, obj);
		QtSupport::setQt(env, obj, 0);
	}
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_dispose(JNIEnv *env, jobject obj)
{
	Java_org_kde_koala_KURL_finalize(env, obj);
	return;
}

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

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_newKURL__Ljava_lang_String_2I(JNIEnv *env, jobject obj, jstring url, jint encoding_hint)
{
static QString * _qstring_url = 0;
	if (QtSupport::getQt(env, obj) == 0) {
		QtSupport::setQt(env, obj, new KURLJBridge((QString&) * (QString *) QtSupport::toQString(env, url, &_qstring_url), (int) encoding_hint));
		QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj));
	}
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_newKURL__Ljava_lang_String_2(JNIEnv *env, jobject obj, jstring url)
{
static QString * _qstring_url = 0;
	if (QtSupport::getQt(env, obj) == 0) {
		QtSupport::setQt(env, obj, new KURLJBridge((QString&) * (QString *) QtSupport::toQString(env, url, &_qstring_url), 0));
		QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj));
	}
	return;
}

//JNIEXPORT void JNICALL
//Java_org_kde_koala_KURL_newKURL__Ljava_lang_String_2I(JNIEnv *env, jobject obj, jstring url, jint encoding_hint)
//{
//static QCString * _qstring_url = 0;
//	if (QtSupport::getQt(env, obj) == 0) {
//		QtSupport::setQt(env, obj, new KURLJBridge((char*) QtSupport::toCharString(env, url, &_qstring_url), (int) encoding_hint));
//		QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj));
//	}
//	return;
//}

//JNIEXPORT void JNICALL
//Java_org_kde_koala_KURL_newKURL__Ljava_lang_String_2(JNIEnv *env, jobject obj, jstring url)
//{
//static QCString * _qstring_url = 0;
//	if (QtSupport::getQt(env, obj) == 0) {
//		QtSupport::setQt(env, obj, new KURLJBridge((char*) QtSupport::toCharString(env, url, &_qstring_url), 0));
//		QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj));
//	}
//	return;
//}

//JNIEXPORT void JNICALL
//Java_org_kde_koala_KURL_newKURL__Ljava_lang_String_2I(JNIEnv *env, jobject obj, jstring url, jint encoding_hint)
//{
//static QCString * _qcstring_url = 0;
//	if (QtSupport::getQt(env, obj) == 0) {
//		QtSupport::setQt(env, obj, new KURLJBridge((QCString&) * (QCString *) QtSupport::toQCString(env, url, &_qcstring_url), (int) encoding_hint));
//		QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj));
//	}
//	return;
//}

//JNIEXPORT void JNICALL
//Java_org_kde_koala_KURL_newKURL__Ljava_lang_String_2(JNIEnv *env, jobject obj, jstring url)
//{
//static QCString * _qcstring_url = 0;
//	if (QtSupport::getQt(env, obj) == 0) {
//		QtSupport::setQt(env, obj, new KURLJBridge((QCString&) * (QCString *) QtSupport::toQCString(env, url, &_qcstring_url), 0));
//		QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj));
//	}
//	return;
//}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_newKURL__Lorg_kde_koala_KURL_2(JNIEnv *env, jobject obj, jobject u)
{
	if (QtSupport::getQt(env, obj) == 0) {
		QtSupport::setQt(env, obj, new KURLJBridge((KURL&) *(KURL *) QtSupport::getQt(env, u)));
		QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj));
	}
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_newKURL__Lorg_kde_qt_QUrlInterface_2(JNIEnv *env, jobject obj, jobject u)
{
	if (QtSupport::getQt(env, obj) == 0) {
		QtSupport::setQt(env, obj, new KURLJBridge((QUrl&) *(QUrl *) QtSupport::getQt(env, u)));
		QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj));
	}
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_newKURL__Lorg_kde_koala_KURL_2Ljava_lang_String_2I(JNIEnv *env, jobject obj, jobject _baseurl, jstring _rel_url, jint encoding_hint)
{
static QString * _qstring__rel_url = 0;
	if (QtSupport::getQt(env, obj) == 0) {
		QtSupport::setQt(env, obj, new KURLJBridge((KURL&) *(KURL *) QtSupport::getQt(env, _baseurl), (QString&) * (QString *) QtSupport::toQString(env, _rel_url, &_qstring__rel_url), (int) encoding_hint));
		QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj));
	}
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_newKURL__Lorg_kde_koala_KURL_2Ljava_lang_String_2(JNIEnv *env, jobject obj, jobject _baseurl, jstring _rel_url)
{
static QString * _qstring__rel_url = 0;
	if (QtSupport::getQt(env, obj) == 0) {
		QtSupport::setQt(env, obj, new KURLJBridge((KURL&) *(KURL *) QtSupport::getQt(env, _baseurl), (QString&) * (QString *) QtSupport::toQString(env, _rel_url, &_qstring__rel_url), 0));
		QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj));
	}
	return;
}

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

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_setProtocol(JNIEnv *env, jobject obj, jstring _txt)
{
static QString * _qstring__txt = 0;
	((KURL*) QtSupport::getQt(env, obj))->setProtocol((QString&) * (QString *) QtSupport::toQString(env, _txt, &_qstring__txt));
	return;
}

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

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_setUser(JNIEnv *env, jobject obj, jstring _txt)
{
static QString * _qstring__txt = 0;
	((KURL*) QtSupport::getQt(env, obj))->setUser((QString&) * (QString *) QtSupport::toQString(env, _txt, &_qstring__txt));
	return;
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KURL_hasUser(JNIEnv *env, jobject obj)
{
	return (jboolean) ((KURL*) QtSupport::getQt(env, obj))->hasUser();
}

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

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_setPass(JNIEnv *env, jobject obj, jstring _txt)
{
static QString * _qstring__txt = 0;
	((KURL*) QtSupport::getQt(env, obj))->setPass((QString&) * (QString *) QtSupport::toQString(env, _txt, &_qstring__txt));
	return;
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KURL_hasPass(JNIEnv *env, jobject obj)
{
	return (jboolean) ((KURL*) QtSupport::getQt(env, obj))->hasPass();
}

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

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_setHost(JNIEnv *env, jobject obj, jstring _txt)
{
static QString * _qstring__txt = 0;
	((KURL*) QtSupport::getQt(env, obj))->setHost((QString&) * (QString *) QtSupport::toQString(env, _txt, &_qstring__txt));
	return;
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KURL_hasHost(JNIEnv *env, jobject obj)
{
	return (jboolean) ((KURL*) QtSupport::getQt(env, obj))->hasHost();
}

JNIEXPORT jshort JNICALL
Java_org_kde_koala_KURL_port(JNIEnv *env, jobject obj)
{
	return (jshort) ((KURL*) QtSupport::getQt(env, obj))->port();
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_setPort(JNIEnv *env, jobject obj, jshort _p)
{
	((KURL*) QtSupport::getQt(env, obj))->setPort((unsigned short int) _p);
	return;
}

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

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_path__I(JNIEnv *env, jobject obj, jint _trailing)
{
	QString  _qstring;
	_qstring = ((KURL*) QtSupport::getQt(env, obj))->path((int) _trailing);
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_setPath(JNIEnv *env, jobject obj, jstring path)
{
static QString * _qstring_path = 0;
	((KURL*) QtSupport::getQt(env, obj))->setPath((QString&) * (QString *) QtSupport::toQString(env, path, &_qstring_path));
	return;
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KURL_hasPath(JNIEnv *env, jobject obj)
{
	return (jboolean) ((KURL*) QtSupport::getQt(env, obj))->hasPath();
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_cleanPath__Z(JNIEnv *env, jobject obj, jboolean cleanDirSeparator)
{
	((KURL*) QtSupport::getQt(env, obj))->cleanPath((bool) cleanDirSeparator);
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_cleanPath__(JNIEnv *env, jobject obj)
{
	((KURL*) QtSupport::getQt(env, obj))->cleanPath(true);
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_setEncodedPathAndQuery__Ljava_lang_String_2I(JNIEnv *env, jobject obj, jstring _txt, jint encoding_hint)
{
static QString * _qstring__txt = 0;
	((KURL*) QtSupport::getQt(env, obj))->setEncodedPathAndQuery((QString&) * (QString *) QtSupport::toQString(env, _txt, &_qstring__txt), (int) encoding_hint);
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_setEncodedPathAndQuery__Ljava_lang_String_2(JNIEnv *env, jobject obj, jstring _txt)
{
static QString * _qstring__txt = 0;
	((KURL*) QtSupport::getQt(env, obj))->setEncodedPathAndQuery((QString&) * (QString *) QtSupport::toQString(env, _txt, &_qstring__txt), 0);
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_setEncodedPath__Ljava_lang_String_2I(JNIEnv *env, jobject obj, jstring _txt, jint encoding_hint)
{
static QString * _qstring__txt = 0;
	((KURL*) QtSupport::getQt(env, obj))->setEncodedPath((QString&) * (QString *) QtSupport::toQString(env, _txt, &_qstring__txt), (int) encoding_hint);
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_setEncodedPath__Ljava_lang_String_2(JNIEnv *env, jobject obj, jstring _txt)
{
static QString * _qstring__txt = 0;
	((KURL*) QtSupport::getQt(env, obj))->setEncodedPath((QString&) * (QString *) QtSupport::toQString(env, _txt, &_qstring__txt), 0);
	return;
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_encodedPathAndQuery(JNIEnv *env, jobject obj, jint _trailing, jboolean _no_empty_path, jint encoding_hint)
{
	QString  _qstring;
	_qstring = ((KURL*) QtSupport::getQt(env, obj))->encodedPathAndQuery((int) _trailing, (bool) _no_empty_path, (int) encoding_hint);
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_encodedPathAndQuery__(JNIEnv *env, jobject obj)
{
	QString _qstring;
	_qstring = ((KURL*) QtSupport::getQt(env, obj))->encodedPathAndQuery(0, false, 0);
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_setQuery__Ljava_lang_String_2I(JNIEnv *env, jobject obj, jstring _txt, jint encoding_hint)
{
static QString * _qstring__txt = 0;
	((KURL*) QtSupport::getQt(env, obj))->setQuery((QString&) * (QString *) QtSupport::toQString(env, _txt, &_qstring__txt), (int) encoding_hint);
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_setQuery__Ljava_lang_String_2(JNIEnv *env, jobject obj, jstring _txt)
{
static QString * _qstring__txt = 0;
	((KURL*) QtSupport::getQt(env, obj))->setQuery((QString&) * (QString *) QtSupport::toQString(env, _txt, &_qstring__txt), 0);
	return;
}

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

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

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_setRef(JNIEnv *env, jobject obj, jstring _txt)
{
static QString * _qstring__txt = 0;
	((KURL*) QtSupport::getQt(env, obj))->setRef((QString&) * (QString *) QtSupport::toQString(env, _txt, &_qstring__txt));
	return;
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KURL_hasRef(JNIEnv *env, jobject obj)
{
	return (jboolean) ((KURL*) QtSupport::getQt(env, obj))->hasRef();
}

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

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

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_setHTMLRef(JNIEnv *env, jobject obj, jstring _ref)
{
static QString * _qstring__ref = 0;
	((KURL*) QtSupport::getQt(env, obj))->setHTMLRef((QString&) * (QString *) QtSupport::toQString(env, _ref, &_qstring__ref));
	return;
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KURL_hasHTMLRef(JNIEnv *env, jobject obj)
{
	return (jboolean) ((KURL*) QtSupport::getQt(env, obj))->hasHTMLRef();
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KURL_isValid(JNIEnv *env, jobject obj)
{
	return (jboolean) ((KURL*) QtSupport::getQt(env, obj))->isValid();
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KURL_isMalformed(JNIEnv *env, jobject obj)
{
	return (jboolean) ((KURL*) QtSupport::getQt(env, obj))->isMalformed();
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KURL_isLocalFile(JNIEnv *env, jobject obj)
{
	return (jboolean) ((KURL*) QtSupport::getQt(env, obj))->isLocalFile();
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_setFileEncoding(JNIEnv *env, jobject obj, jstring encoding)
{
static QString * _qstring_encoding = 0;
	((KURL*) QtSupport::getQt(env, obj))->setFileEncoding((QString&) * (QString *) QtSupport::toQString(env, encoding, &_qstring_encoding));
	return;
}

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

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KURL_hasSubURL(JNIEnv *env, jobject obj)
{
	return (jboolean) ((KURL*) QtSupport::getQt(env, obj))->hasSubURL();
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_addPath(JNIEnv *env, jobject obj, jstring _txt)
{
static QString * _qstring__txt = 0;
	((KURL*) QtSupport::getQt(env, obj))->addPath((QString&) * (QString *) QtSupport::toQString(env, _txt, &_qstring__txt));
	return;
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_queryItem(JNIEnv *env, jobject obj, jstring _item)
{
	QString  _qstring;
static QString * _qstring__item = 0;
	_qstring = ((KURL*) QtSupport::getQt(env, obj))->queryItem((QString&) * (QString *) QtSupport::toQString(env, _item, &_qstring__item));
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_setFileName(JNIEnv *env, jobject obj, jstring _txt)
{
static QString * _qstring__txt = 0;
	((KURL*) QtSupport::getQt(env, obj))->setFileName((QString&) * (QString *) QtSupport::toQString(env, _txt, &_qstring__txt));
	return;
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_fileName__Z(JNIEnv *env, jobject obj, jboolean _ignore_trailing_slash_in_path)
{
	QString  _qstring;
	_qstring = ((KURL*) QtSupport::getQt(env, obj))->fileName((bool) _ignore_trailing_slash_in_path);
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_fileName__(JNIEnv *env, jobject obj)
{
	QString _qstring;
	_qstring = ((KURL*) QtSupport::getQt(env, obj))->fileName(true);
	return QtSupport::fromQString(env, &_qstring);
}

//JNIEXPORT jstring JNICALL
//Java_org_kde_koala_KURL_fileName__(JNIEnv *env, jobject obj)
//{
//	QString  _qstring;
//	_qstring = ((KURLJBridge*) QtSupport::getQt(env, obj))->fileName(true);
//	return QtSupport::fromQString(env, &_qstring);
//}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_directory__ZZ(JNIEnv *env, jobject obj, jboolean _strip_trailing_slash_from_result, jboolean _ignore_trailing_slash_in_path)
{
	QString  _qstring;
	_qstring = ((KURL*) QtSupport::getQt(env, obj))->directory((bool) _strip_trailing_slash_from_result, (bool) _ignore_trailing_slash_in_path);
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_directory__(JNIEnv *env, jobject obj)
{
	QString _qstring;
	_qstring = ((KURL*) QtSupport::getQt(env, obj))->directory(true, true);
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KURL_cd(JNIEnv *env, jobject obj, jstring _dir)
{
static QString * _qstring__dir = 0;
	return (jboolean) ((KURL*) QtSupport::getQt(env, obj))->cd((QString&) * (QString *) QtSupport::toQString(env, _dir, &_qstring__dir));
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_url(JNIEnv *env, jobject obj, jint _trailing, jint encoding_hint)
{
	QString  _qstring;
	_qstring = ((KURL*) QtSupport::getQt(env, obj))->url((int) _trailing, (int) encoding_hint);
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_url__(JNIEnv *env, jobject obj)
{
	QString _qstring;
	_qstring = ((KURL*) QtSupport::getQt(env, obj))->url(0, 0);
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_prettyURL__I(JNIEnv *env, jobject obj, jint _trailing)
{
	QString  _qstring;
	_qstring = ((KURL*) QtSupport::getQt(env, obj))->prettyURL((int) _trailing);
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_prettyURL__(JNIEnv *env, jobject obj)
{
	QString _qstring;
	_qstring = ((KURL*) QtSupport::getQt(env, obj))->prettyURL(0);
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KURL_isEmpty(JNIEnv *env, jobject obj)
{
	return (jboolean) ((KURL*) QtSupport::getQt(env, obj))->isEmpty();
}

JNIEXPORT jobject JNICALL
Java_org_kde_koala_KURL_upURL(JNIEnv *env, jobject obj)
{
	return (jobject) QtSupport::objectForQtKey(env, (void *)new KURL (((KURL*) QtSupport::getQt(env, obj))->upURL()), "org.kde.koala.KURL", TRUE);
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KURL_cmp__Lorg_kde_koala_KURL_2Z(JNIEnv *env, jobject obj, jobject u, jboolean ignore_trailing)
{
	return (jboolean) ((KURL*) QtSupport::getQt(env, obj))->cmp((KURL&) *(KURL *) QtSupport::getQt(env, u), (bool) ignore_trailing);
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KURL_cmp__Lorg_kde_koala_KURL_2(JNIEnv *env, jobject obj, jobject u)
{
	return (jboolean) ((KURL*) QtSupport::getQt(env, obj))->cmp((KURL&) *(KURL *) QtSupport::getQt(env, u), false);
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KURL_isParentOf(JNIEnv *env, jobject obj, jobject u)
{
	return (jboolean) ((KURL*) QtSupport::getQt(env, obj))->isParentOf((KURL&) *(KURL *) QtSupport::getQt(env, u));
}

JNIEXPORT jobject JNICALL
Java_org_kde_koala_KURL_split__Ljava_lang_String_2(JNIEnv *env, jclass obj, jstring _url)
{
static QString * _qstring__url = 0;
	return (jobject) QtSupport::objectForQtKey(env, (void *)new  KURL::List (KURLJBridge::split((QString&) * (QString *) QtSupport::toQString(env, _url, &_qstring__url))), "org.kde.koala.List", TRUE);
}

JNIEXPORT jobject JNICALL
Java_org_kde_koala_KURL_split__Lorg_kde_koala_KURL_2(JNIEnv *env, jclass obj, jobject _url)
{
	return (jobject) QtSupport::objectForQtKey(env, (void *)new  KURL::List (KURLJBridge::split((KURL&) *(KURL *) QtSupport::getQt(env, _url))), "org.kde.koala.List", TRUE);
}

JNIEXPORT jobject JNICALL
Java_org_kde_koala_KURL_join(JNIEnv *env, jclass obj, jobject _list)
{
	return (jobject) QtSupport::objectForQtKey(env, (void *)new  KURL (KURLJBridge::join((KURL::List&) *(KURL::List *) QtSupport::getQt(env, _list))), "org.kde.koala.KURL", TRUE);
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_encode_1string(JNIEnv *env, jclass obj, jstring str, jint encoding_hint)
{
	QString  _qstring;
static QString * _qstring_str = 0;
	_qstring = KURLJBridge::encode_string((QString&) * (QString *) QtSupport::toQString(env, str, &_qstring_str), (int) encoding_hint);
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_encode_1string__Ljava_lang_String_2(JNIEnv *env, jclass obj, jstring str)
{
static QString * _qstring_str = 0;
	QString _qstring;
	_qstring = KURLJBridge::encode_string((QString&) * (QString *) QtSupport::toQString(env, str, &_qstring_str), 0);
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_encode_1string_1no_1slash(JNIEnv *env, jclass obj, jstring str, jint encoding_hint)
{
	QString  _qstring;
static QString * _qstring_str = 0;
	_qstring = KURLJBridge::encode_string_no_slash((QString&) * (QString *) QtSupport::toQString(env, str, &_qstring_str), (int) encoding_hint);
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_encode_1string_1no_1slash__Ljava_lang_String_2(JNIEnv *env, jclass obj, jstring str)
{
static QString * _qstring_str = 0;
	QString _qstring;
	_qstring = KURLJBridge::encode_string_no_slash((QString&) * (QString *) QtSupport::toQString(env, str, &_qstring_str), 0);
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_decode_1string(JNIEnv *env, jclass obj, jstring str, jint encoding_hint)
{
	QString  _qstring;
static QString * _qstring_str = 0;
	_qstring = KURLJBridge::decode_string((QString&) * (QString *) QtSupport::toQString(env, str, &_qstring_str), (int) encoding_hint);
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KURL_decode_1string__Ljava_lang_String_2(JNIEnv *env, jclass obj, jstring str)
{
static QString * _qstring_str = 0;
	QString _qstring;
	_qstring = KURLJBridge::decode_string((QString&) * (QString *) QtSupport::toQString(env, str, &_qstring_str), 0);
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KURL_isRelativeURL(JNIEnv *env, jclass obj, jstring _url)
{
static QString * _qstring__url = 0;
	return (jboolean) KURLJBridge::isRelativeURL((QString&) * (QString *) QtSupport::toQString(env, _url, &_qstring__url));
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_reset(JNIEnv *env, jobject obj)
{
	((KURLJBridge*) QtSupport::getQt(env, obj))->protected_reset();
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_parse__Ljava_lang_String_2I(JNIEnv *env, jobject obj, jstring _url, jint encoding_hint)
{
static QString * _qstring__url = 0;
	((KURLJBridge*) QtSupport::getQt(env, obj))->protected_parse((QString&) * (QString *) QtSupport::toQString(env, _url, &_qstring__url), (int) encoding_hint);
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURL_parse__Ljava_lang_String_2(JNIEnv *env, jobject obj, jstring _url)
{
static QString * _qstring__url = 0;
	((KURLJBridge*) QtSupport::getQt(env, obj))->protected_parse((QString&) * (QString *) QtSupport::toQString(env, _url, &_qstring__url), 0);
	return;
}

