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

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

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KShell_homeDir(JNIEnv* env, jclass cls, jstring user)
{
	QString  _qstring;
	(void) cls;
static QString* _qstring_user = 0;
	_qstring = KShell::homeDir((const QString&)*(QString*) QtSupport::toQString(env, user, &_qstring_user));
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KShell_joinArgsDQ(JNIEnv* env, jclass cls, jobjectArray args)
{
	QString  _qstring;
	(void) cls;
static QStringList* _qlist_args = 0;
	_qstring = KShell::joinArgsDQ((const QStringList&)*(QStringList*) QtSupport::toQStringList(env, args, &_qlist_args));
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KShell_joinArgs(JNIEnv* env, jclass cls, jobjectArray args)
{
	QString  _qstring;
	(void) cls;
static QStringList* _qlist_args = 0;
	_qstring = KShell::joinArgs((const QStringList&)*(QStringList*) QtSupport::toQStringList(env, args, &_qlist_args));
	return QtSupport::fromQString(env, &_qstring);
}

JNIEXPORT jobject JNICALL
Java_org_kde_koala_KShell_splitArgs__Ljava_lang_String_2(JNIEnv* env, jclass cls, jstring cmd)
{
	QStringList  _qlist;
	(void) cls;
static QString* _qstring_cmd = 0;
	_qlist = KShell::splitArgs((const QString&)*(QString*) QtSupport::toQString(env, cmd, &_qstring_cmd));
	return (jobject) QtSupport::arrayWithQStringList(env, (QStringList*) &_qlist);
}

JNIEXPORT jobject JNICALL
Java_org_kde_koala_KShell_splitArgs__Ljava_lang_String_2I(JNIEnv* env, jclass cls, jstring cmd, jint flags)
{
	QStringList  _qlist;
	(void) cls;
static QString* _qstring_cmd = 0;
	_qlist = KShell::splitArgs((const QString&)*(QString*) QtSupport::toQString(env, cmd, &_qstring_cmd), (int) flags);
	return (jobject) QtSupport::arrayWithQStringList(env, (QStringList*) &_qlist);
}

JNIEXPORT jobject JNICALL
Java_org_kde_koala_KShell_splitArgs__Ljava_lang_String_2I_3I(JNIEnv* env, jclass cls, jstring cmd, jint flags, jintArray err)
{
	QStringList  _qlist;
	(void) cls;
static QString* _qstring_cmd = 0;
	int* _int_err = QtSupport::toIntPtr(env, err);
	_qlist = KShell::splitArgs((const QString&)*(QString*) QtSupport::toQString(env, cmd, &_qstring_cmd), (int) flags,  (int*) _int_err);
	env->SetIntArrayRegion(err, 0, 1, (jint *) _int_err);
	return (jobject) QtSupport::arrayWithQStringList(env, (QStringList*) &_qlist);
}

JNIEXPORT jstring JNICALL
Java_org_kde_koala_KShell_tildeExpand(JNIEnv* env, jclass cls, jstring path)
{
	QString  _qstring;
	(void) cls;
static QString* _qstring_path = 0;
	_qstring = KShell::tildeExpand((const QString&)*(QString*) QtSupport::toQString(env, path, &_qstring_path));
	return QtSupport::fromQString(env, &_qstring);
}

