summaryrefslogtreecommitdiffstats
path: root/tdejava/koala/tdejava/TDEProcIO.cpp
blob: e7c008f6dca4188d914a329ff9aaaddcfe865d20 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
//Auto-generated by kalyptus. DO NOT EDIT.
#include <tdeprocess.h>
#include <tqstring.h>
#include <tdeprocio.h>
#include <tqcstring.h>

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

class TDEProcIOJBridge : public TDEProcIO
{
public:
	TDEProcIOJBridge(TQTextCodec* arg1) : TDEProcIO(arg1) {};
	TDEProcIOJBridge() : TDEProcIO() {};
	void protected_controlledEmission() {
		TDEProcIO::controlledEmission();
		return;
	}
	void protected_received(TDEProcess* arg1,char* arg2,int arg3) {
		TDEProcIO::received(arg1,arg2,arg3);
		return;
	}
	void protected_sent(TDEProcess* arg1) {
		TDEProcIO::sent(arg1);
		return;
	}
	~TDEProcIOJBridge() {QtSupport::qtKeyDeleted(this);}
	void removeChild(TQObject* arg1) {
		if (!QtSupport::eventDelegate(this,"removeChild",(void*)arg1,"org.trinitydesktop.qt.TQObject")) {
			TQObject::removeChild(arg1);
		}
		return;
	}
	void customEvent(TQCustomEvent* arg1) {
		if (!QtSupport::eventDelegate(this,"customEvent",(void*)arg1,"org.trinitydesktop.qt.TQCustomEvent")) {
			TQObject::customEvent(arg1);
		}
		return;
	}
	void timerEvent(TQTimerEvent* arg1) {
		if (!QtSupport::eventDelegate(this,"timerEvent",(void*)arg1,"org.trinitydesktop.qt.TQTimerEvent")) {
			TQObject::timerEvent(arg1);
		}
		return;
	}
	void childEvent(TQChildEvent* arg1) {
		if (!QtSupport::eventDelegate(this,"childEvent",(void*)arg1,"org.trinitydesktop.qt.TQChildEvent")) {
			TQObject::childEvent(arg1);
		}
		return;
	}
	void insertChild(TQObject* arg1) {
		if (!QtSupport::eventDelegate(this,"insertChild",(void*)arg1,"org.trinitydesktop.qt.TQObject")) {
			TQObject::insertChild(arg1);
		}
		return;
	}
	void commClose() {
		if (!QtSupport::voidDelegate(this,"org.trinitydesktop.koala.TDEProcIO","commClose")) {
			TDEProcess::commClose();
		}
		return;
	}
	bool eventFilter(TQObject* object,TQEvent* event) {
		if (!QtSupport::eventFilterDelegate(this,"org.trinitydesktop.koala.TDEProcIO",object,event)) {
			return TQObject::eventFilter(object,event);
		} else {
			return TRUE;
		}
	}
};

JNIEXPORT void JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_ackRead(JNIEnv* env, jobject obj)
{
	((TDEProcIO*) QtSupport::getQt(env, obj))->ackRead();
	return;
}

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

JNIEXPORT void JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_closeWhenDone(JNIEnv* env, jobject obj)
{
	((TDEProcIO*) QtSupport::getQt(env, obj))->closeWhenDone();
	return;
}

JNIEXPORT void JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_controlledEmission(JNIEnv* env, jobject obj)
{
	((TDEProcIOJBridge*) QtSupport::getQt(env, obj))->protected_controlledEmission();
	return;
}

JNIEXPORT void JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_dispose(JNIEnv* env, jobject obj)
{
	Java_org_trinitydesktop_koala_TDEProcIO_finalize(env, obj);
	return;
}

JNIEXPORT void JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_enableReadSignals(JNIEnv* env, jobject obj, jboolean enable)
{
	((TDEProcIO*) QtSupport::getQt(env, obj))->enableReadSignals((bool) enable);
	return;
}

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

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

JNIEXPORT jobject JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_metaObject(JNIEnv* env, jobject obj)
{
	jobject xret = QtSupport::objectForQtKey(env, (void*)((TDEProcIO*) QtSupport::getQt(env, obj))->metaObject(), "org.trinitydesktop.qt.TQMetaObject");
	return xret;
}

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

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

JNIEXPORT jint JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_readln__Ljava_lang_StringBuffer_2(JNIEnv* env, jobject obj, jobject line)
{
static TQString* _qstring_line = 0;
	jint xret = (jint) ((TDEProcIO*) QtSupport::getQt(env, obj))->readln((TQString&)*(TQString*) QtSupport::toTQStringFromStringBuffer(env, line, &_qstring_line));
	QtSupport::fromTQStringToStringBuffer(env, _qstring_line, line);
	return xret;
}

JNIEXPORT jint JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_readln__Ljava_lang_StringBuffer_2Z(JNIEnv* env, jobject obj, jobject line, jboolean autoAck)
{
static TQString* _qstring_line = 0;
	jint xret = (jint) ((TDEProcIO*) QtSupport::getQt(env, obj))->readln((TQString&)*(TQString*) QtSupport::toTQStringFromStringBuffer(env, line, &_qstring_line), (bool) autoAck);
	QtSupport::fromTQStringToStringBuffer(env, _qstring_line, line);
	return xret;
}

JNIEXPORT jint JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_readln__Ljava_lang_StringBuffer_2Z_3Z(JNIEnv* env, jobject obj, jobject line, jboolean autoAck, jbooleanArray partial)
{
static TQString* _qstring_line = 0;
	bool* _bool_partial = QtSupport::toBooleanPtr(env, partial);
	jint xret = (jint) ((TDEProcIO*) QtSupport::getQt(env, obj))->readln((TQString&)*(TQString*) QtSupport::toTQStringFromStringBuffer(env, line, &_qstring_line), (bool) autoAck,  (bool*) _bool_partial);
	QtSupport::fromTQStringToStringBuffer(env, _qstring_line, line);
	env->SetBooleanArrayRegion(partial, 0, 1, (jboolean*) _bool_partial);
	return xret;
}

JNIEXPORT void JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_received(JNIEnv* env, jobject obj, jobject proc, jstring buffer, jint buflen)
{
static TQCString* _qstring_buffer = 0;
	((TDEProcIOJBridge*) QtSupport::getQt(env, obj))->protected_received((TDEProcess*) QtSupport::getQt(env, proc), (char*) QtSupport::toCharString(env, buffer, &_qstring_buffer), (int) buflen);
	return;
}

JNIEXPORT void JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_resetAll(JNIEnv* env, jobject obj)
{
	((TDEProcIO*) QtSupport::getQt(env, obj))->resetAll();
	return;
}

JNIEXPORT void JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_sent(JNIEnv* env, jobject obj, jobject arg1)
{
	((TDEProcIOJBridge*) QtSupport::getQt(env, obj))->protected_sent((TDEProcess*) QtSupport::getQt(env, arg1));
	return;
}

JNIEXPORT void JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_setComm(JNIEnv* env, jobject obj, jint comm)
{
	((TDEProcIO*) QtSupport::getQt(env, obj))->setComm((TDEProcess::Communication) comm);
	return;
}

JNIEXPORT jboolean JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_start__(JNIEnv* env, jobject obj)
{
	jboolean xret = (jboolean) ((TDEProcIO*) QtSupport::getQt(env, obj))->start();
	return xret;
}

JNIEXPORT jboolean JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_start__I(JNIEnv* env, jobject obj, jint runmode)
{
	jboolean xret = (jboolean) ((TDEProcIO*) QtSupport::getQt(env, obj))->start((TDEProcess::RunMode) runmode);
	return xret;
}

JNIEXPORT jboolean JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_start__IZ(JNIEnv* env, jobject obj, jint runmode, jboolean includeStderr)
{
	jboolean xret = (jboolean) ((TDEProcIO*) QtSupport::getQt(env, obj))->start((TDEProcess::RunMode) runmode, (bool) includeStderr);
	return xret;
}

JNIEXPORT jboolean JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_writeStdin__Ljava_lang_String_2(JNIEnv* env, jobject obj, jstring line)
{
static TQString* _qstring_line = 0;
	jboolean xret = (jboolean) ((TDEProcIO*) QtSupport::getQt(env, obj))->writeStdin((const TQString&)*(TQString*) QtSupport::toTQString(env, line, &_qstring_line));
	return xret;
}

JNIEXPORT jboolean JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_writeStdin__Ljava_lang_String_2Z(JNIEnv* env, jobject obj, jstring line, jboolean appendnewline)
{
static TQString* _qstring_line = 0;
	jboolean xret = (jboolean) ((TDEProcIO*) QtSupport::getQt(env, obj))->writeStdin((const TQString&)*(TQString*) QtSupport::toTQString(env, line, &_qstring_line), (bool) appendnewline);
	return xret;
}

JNIEXPORT jboolean JNICALL
Java_org_trinitydesktop_koala_TDEProcIO_writeStdin___3B(JNIEnv* env, jobject obj, jbyteArray data)
{
static TQByteArray* _qbyteArray_data = 0;
	jboolean xret = (jboolean) ((TDEProcIO*) QtSupport::getQt(env, obj))->writeStdin((const TQByteArray&)*(TQByteArray*) QtSupport::toTQByteArray(env, data, &_qbyteArray_data));
	return xret;
}