summaryrefslogtreecommitdiffstats
path: root/qtjava/javalib/qtjava/TQFile.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'qtjava/javalib/qtjava/TQFile.cpp')
-rw-r--r--qtjava/javalib/qtjava/TQFile.cpp278
1 files changed, 278 insertions, 0 deletions
diff --git a/qtjava/javalib/qtjava/TQFile.cpp b/qtjava/javalib/qtjava/TQFile.cpp
new file mode 100644
index 00000000..b1197d90
--- /dev/null
+++ b/qtjava/javalib/qtjava/TQFile.cpp
@@ -0,0 +1,278 @@
+//Auto-generated by kalyptus. DO NOT EDIT.
+#include <tqfile.h>
+#include <tqglobal.h>
+#include <tqiodevice.h>
+#include <tqstring.h>
+#include <tqcstring.h>
+
+#include <qtjava/QtSupport.h>
+#include <qtjava/TQFile.h>
+
+class TQFileJBridge : public TQFile
+{
+public:
+ TQFileJBridge() : TQFile() {};
+ TQFileJBridge(const TQString& arg1) : TQFile(arg1) {};
+ void protected_setErrorString(const TQString& arg1) {
+ TQFile::setErrorString(arg1);
+ return;
+ }
+ ~TQFileJBridge() {QtSupport::qtKeyDeleted(this);}
+};
+
+JNIEXPORT jboolean JNICALL
+Java_org_kde_qt_QFile_atEnd(JNIEnv* env, jobject obj)
+{
+ jboolean xret = (jboolean) ((TQFile*) QtSupport::getQt(env, obj))->atEnd();
+ return xret;
+}
+
+JNIEXPORT jlong JNICALL
+Java_org_kde_qt_QFile_at__(JNIEnv* env, jobject obj)
+{
+ jlong xret = (jlong) ((TQFile*) QtSupport::getQt(env, obj))->at();
+ return xret;
+}
+
+JNIEXPORT jboolean JNICALL
+Java_org_kde_qt_QFile_at__J(JNIEnv* env, jobject obj, jlong arg1)
+{
+ jboolean xret = (jboolean) ((TQFile*) QtSupport::getQt(env, obj))->at((TQIODevice::Offset) arg1);
+ return xret;
+}
+
+JNIEXPORT void JNICALL
+Java_org_kde_qt_QFile_close(JNIEnv* env, jobject obj)
+{
+ ((TQFile*) QtSupport::getQt(env, obj))->close();
+ return;
+}
+
+JNIEXPORT jstring JNICALL
+Java_org_kde_qt_QFile_decodeName(JNIEnv* env, jclass cls, jstring localFileName)
+{
+ TQString _qstring;
+ (void) cls;
+static TQCString* _qcstring_localFileName = 0;
+ _qstring = TQFileJBridge::decodeName((const TQCString&)*(TQCString*) QtSupport::toTQCString(env, localFileName, &_qcstring_localFileName));
+ return QtSupport::fromTQString(env, &_qstring);
+}
+
+JNIEXPORT void JNICALL
+Java_org_kde_qt_QFile_dispose(JNIEnv* env, jobject obj)
+{
+ Java_org_kde_qt_QFile_finalize(env, obj);
+ return;
+}
+
+JNIEXPORT jstring JNICALL
+Java_org_kde_qt_QFile_encodeName(JNIEnv* env, jclass cls, jstring fileName)
+{
+ TQCString _qstring;
+ (void) cls;
+static TQString* _qstring_fileName = 0;
+ _qstring = TQFileJBridge::encodeName((const TQString&)*(TQString*) QtSupport::toTQString(env, fileName, &_qstring_fileName));
+ return QtSupport::fromTQCString(env, &_qstring);
+}
+
+JNIEXPORT jstring JNICALL
+Java_org_kde_qt_QFile_errorString(JNIEnv* env, jobject obj)
+{
+ TQString _qstring;
+ _qstring = ((TQFile*) QtSupport::getQt(env, obj))->errorString();
+ return QtSupport::fromTQString(env, &_qstring);
+}
+
+JNIEXPORT jboolean JNICALL
+Java_org_kde_qt_QFile_exists__(JNIEnv* env, jobject obj)
+{
+ jboolean xret = (jboolean) ((TQFile*) QtSupport::getQt(env, obj))->exists();
+ return xret;
+}
+
+JNIEXPORT jboolean JNICALL
+Java_org_kde_qt_QFile_exists__Ljava_lang_String_2(JNIEnv* env, jclass cls, jstring fileName)
+{
+ (void) cls;
+static TQString* _qstring_fileName = 0;
+ jboolean xret = (jboolean) TQFileJBridge::exists((const TQString&)*(TQString*) QtSupport::toTQString(env, fileName, &_qstring_fileName));
+ return xret;
+}
+
+JNIEXPORT void JNICALL
+Java_org_kde_qt_QFile_finalize(JNIEnv* env, jobject obj)
+{
+ if (QtSupport::allocatedInJavaWorld(env, obj)) {
+ delete (TQFile*)QtSupport::getQt(env, obj);
+ QtSupport::setQt(env, obj, 0);
+ }
+ return;
+}
+
+JNIEXPORT void JNICALL
+Java_org_kde_qt_QFile_flush(JNIEnv* env, jobject obj)
+{
+ ((TQFile*) QtSupport::getQt(env, obj))->flush();
+ return;
+}
+
+JNIEXPORT jint JNICALL
+Java_org_kde_qt_QFile_getch(JNIEnv* env, jobject obj)
+{
+ jint xret = (jint) ((TQFile*) QtSupport::getQt(env, obj))->getch();
+ return xret;
+}
+
+JNIEXPORT jint JNICALL
+Java_org_kde_qt_QFile_handle(JNIEnv* env, jobject obj)
+{
+ jint xret = (jint) ((TQFile*) QtSupport::getQt(env, obj))->handle();
+ return xret;
+}
+
+JNIEXPORT jboolean JNICALL
+Java_org_kde_qt_QFile_isDisposed(JNIEnv* env, jobject obj)
+{
+ return (QtSupport::getQt(env, obj) == 0);
+}
+
+JNIEXPORT jstring JNICALL
+Java_org_kde_qt_QFile_name(JNIEnv* env, jobject obj)
+{
+ TQString _qstring;
+ _qstring = ((TQFile*) QtSupport::getQt(env, obj))->name();
+ return QtSupport::fromTQString(env, &_qstring);
+}
+
+JNIEXPORT void JNICALL
+Java_org_kde_qt_QFile_newTQFile__(JNIEnv* env, jobject obj)
+{
+ if (QtSupport::getQt(env, obj) == 0) {
+ QtSupport::setQt(env, obj, new TQFileJBridge());
+ QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj));
+ }
+ return;
+}
+
+JNIEXPORT void JNICALL
+Java_org_kde_qt_QFile_newTQFile__Ljava_lang_String_2(JNIEnv* env, jobject obj, jstring name)
+{
+static TQString* _qstring_name = 0;
+ if (QtSupport::getQt(env, obj) == 0) {
+ QtSupport::setQt(env, obj, new TQFileJBridge((const TQString&)*(TQString*) QtSupport::toTQString(env, name, &_qstring_name)));
+ QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj));
+ }
+ return;
+}
+
+JNIEXPORT jboolean JNICALL
+Java_org_kde_qt_QFile_open__I(JNIEnv* env, jobject obj, jint arg1)
+{
+ jboolean xret = (jboolean) ((TQFile*) QtSupport::getQt(env, obj))->open((int) arg1);
+ return xret;
+}
+
+JNIEXPORT jboolean JNICALL
+Java_org_kde_qt_QFile_open__II(JNIEnv* env, jobject obj, jint arg1, jint arg2)
+{
+ jboolean xret = (jboolean) ((TQFile*) QtSupport::getQt(env, obj))->open((int) arg1, (int) arg2);
+ return xret;
+}
+
+JNIEXPORT jint JNICALL
+Java_org_kde_qt_QFile_putch(JNIEnv* env, jobject obj, jint arg1)
+{
+ jint xret = (jint) ((TQFile*) QtSupport::getQt(env, obj))->putch((int) arg1);
+ return xret;
+}
+
+JNIEXPORT jlong JNICALL
+Java_org_kde_qt_QFile_readBlock(JNIEnv* env, jobject obj, jobject data, jlong len)
+{
+static TQCString* _qstring_data = 0;
+ if (_qstring_data == 0) { _qstring_data = new TQCString(); }
+ _qstring_data->resize((uint) len);
+ jlong xret = (jlong) ((TQFile*) QtSupport::getQt(env, obj))->readBlock((char*) _qstring_data->data(), (Q_ULONG) len);
+ QtSupport::fromTQCStringToStringBuffer(env, _qstring_data, data);
+ return xret;
+}
+
+JNIEXPORT jlong JNICALL
+Java_org_kde_qt_QFile_readLine__Ljava_lang_StringBuffer_2J(JNIEnv* env, jobject obj, jobject arg1, jlong maxlen)
+{
+static TQString* _qstring_arg1 = 0;
+ jlong xret = (jlong) ((TQFile*) QtSupport::getQt(env, obj))->readLine((TQString&)*(TQString*) QtSupport::toTQStringFromStringBuffer(env, arg1, &_qstring_arg1), (Q_ULONG) maxlen);
+ QtSupport::fromTQStringToStringBuffer(env, _qstring_arg1, arg1);
+ return xret;
+}
+
+JNIEXPORT jlong JNICALL
+Java_org_kde_qt_QFile_readLine__Ljava_lang_String_2J(JNIEnv* env, jobject obj, jstring data, jlong maxlen)
+{
+static TQCString* _qstring_data = 0;
+ jlong xret = (jlong) ((TQFile*) QtSupport::getQt(env, obj))->readLine((char*) QtSupport::toCharString(env, data, &_qstring_data), (Q_ULONG) maxlen);
+ return xret;
+}
+
+JNIEXPORT jboolean JNICALL
+Java_org_kde_qt_QFile_remove__(JNIEnv* env, jobject obj)
+{
+ jboolean xret = (jboolean) ((TQFile*) QtSupport::getQt(env, obj))->remove();
+ return xret;
+}
+
+JNIEXPORT jboolean JNICALL
+Java_org_kde_qt_QFile_remove__Ljava_lang_String_2(JNIEnv* env, jclass cls, jstring fileName)
+{
+ (void) cls;
+static TQString* _qstring_fileName = 0;
+ jboolean xret = (jboolean) TQFileJBridge::remove((const TQString&)*(TQString*) QtSupport::toTQString(env, fileName, &_qstring_fileName));
+ return xret;
+}
+
+JNIEXPORT void JNICALL
+Java_org_kde_qt_QFile_setErrorString(JNIEnv* env, jobject obj, jstring arg1)
+{
+static TQString* _qstring_arg1 = 0;
+ ((TQFileJBridge*) QtSupport::getQt(env, obj))->protected_setErrorString((const TQString&)*(TQString*) QtSupport::toTQString(env, arg1, &_qstring_arg1));
+ return;
+}
+
+JNIEXPORT void JNICALL
+Java_org_kde_qt_QFile_setName(JNIEnv* env, jobject obj, jstring name)
+{
+static TQString* _qstring_name = 0;
+ ((TQFile*) QtSupport::getQt(env, obj))->setName((const TQString&)*(TQString*) QtSupport::toTQString(env, name, &_qstring_name));
+ return;
+}
+
+JNIEXPORT jlong JNICALL
+Java_org_kde_qt_QFile_size(JNIEnv* env, jobject obj)
+{
+ jlong xret = (jlong) ((TQFile*) QtSupport::getQt(env, obj))->size();
+ return xret;
+}
+
+JNIEXPORT jint JNICALL
+Java_org_kde_qt_QFile_ungetch(JNIEnv* env, jobject obj, jint arg1)
+{
+ jint xret = (jint) ((TQFile*) QtSupport::getQt(env, obj))->ungetch((int) arg1);
+ return xret;
+}
+
+JNIEXPORT jlong JNICALL
+Java_org_kde_qt_QFile_writeBlock__Ljava_lang_String_2J(JNIEnv* env, jobject obj, jstring data, jlong len)
+{
+static TQCString* _qstring_data = 0;
+ jlong xret = (jlong) ((TQFile*) QtSupport::getQt(env, obj))->writeBlock((const char*) QtSupport::toCharString(env, data, &_qstring_data), (Q_ULONG) len);
+ return xret;
+}
+
+JNIEXPORT jlong JNICALL
+Java_org_kde_qt_QFile_writeBlock___3B(JNIEnv* env, jobject obj, jbyteArray data)
+{
+static TQByteArray* _qbyteArray_data = 0;
+ jlong xret = (jlong) ((TQFile*) QtSupport::getQt(env, obj))->writeBlock((const TQByteArray&)*(TQByteArray*) QtSupport::toTQByteArray(env, data, &_qbyteArray_data));
+ return xret;
+}
+