//Auto-generated by kalyptus. DO NOT EDIT.
#include <dom/dom_text.h>
#include <dom/dom_node.h>

#include <qtjava/QtSupport.h>
#include <tdejava/TDESupport.h>
#include <tdejava/Text.h>

class TextJBridge : public DOM::Text
{
public:
	TextJBridge() : DOM::Text() {};
	TextJBridge(const DOM::Text& arg1) : DOM::Text(arg1) {};
	TextJBridge(const DOM::Node& arg1) : DOM::Text(arg1) {};
};

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

JNIEXPORT void JNICALL
Java_org_trinitydesktop_koala_Text_newText__Lorg_trinitydesktop_koala_Node_2(JNIEnv* env, jobject obj, jobject other)
{
	if (QtSupport::getQt(env, obj) == 0) {
		QtSupport::setQt(env, obj, new TextJBridge((const DOM::Node&)*(const DOM::Node*) QtSupport::getQt(env, other)));
		QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj));
	}
	return;
}

JNIEXPORT void JNICALL
Java_org_trinitydesktop_koala_Text_newText__Lorg_trinitydesktop_koala_Text_2(JNIEnv* env, jobject obj, jobject other)
{
	if (QtSupport::getQt(env, obj) == 0) {
		QtSupport::setQt(env, obj, new TextJBridge((const DOM::Text&)*(const DOM::Text*) QtSupport::getQt(env, other)));
		QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj));
	}
	return;
}

JNIEXPORT jobject JNICALL
Java_org_trinitydesktop_koala_Text_splitText(JNIEnv* env, jobject obj, jlong offset)
{
	jobject xret = QtSupport::objectForQtKey(env, (void*)new DOM::Text(((DOM::Text*) QtSupport::getQt(env, obj))->splitText((const unsigned long) offset)), "org.trinitydesktop.koala.Text", TRUE);
	return xret;
}

