1 /* Code generated from eC source file: DualPipe.ec */
3 #define __runtimePlatform 1
4 #elif defined(__APPLE__)
5 #define __runtimePlatform 3
7 #define __runtimePlatform 2
10 typedef long long int64;
11 typedef unsigned long long uint64;
15 #elif defined(__TINYC__)
17 #define __builtin_va_list va_list
18 #define __builtin_va_start va_start
19 #define __builtin_va_end va_end
21 #define strcasecmp stricmp
22 #define strncasecmp strnicmp
23 #define __declspec(x) __attribute__((x))
27 typedef long long int64;
28 typedef unsigned long long uint64;
30 typedef __int64 int64;
31 typedef unsigned __int64 uint64;
34 #define __ENDIAN_PAD(x) (8 - (x))
36 #define __ENDIAN_PAD(x) 0
39 # if defined(__GNUC__) || defined(__TINYC__)
40 # define ecere_stdcall __attribute__((__stdcall__))
41 # define ecere_gcc_struct __attribute__((gcc_struct))
43 # define ecere_stdcall __stdcall
44 # define ecere_gcc_struct
47 # define ecere_stdcall
48 # define ecere_gcc_struct
51 #include <sys/types.h>
52 typedef __builtin_va_list va_list;
54 typedef struct _DualPipe _DualPipe;
56 void DualPipe_Destructor(_DualPipe * dp);
58 void DualPipe_CloseInput(_DualPipe * dp);
60 void DualPipe_CloseOutput(_DualPipe * dp);
62 int DualPipe_Read(_DualPipe * dp, unsigned char * buffer, unsigned int size, unsigned int count);
64 int DualPipe_Write(_DualPipe * dp, const unsigned char * buffer, unsigned int size, unsigned int count);
66 unsigned int DualPipe_Getc(_DualPipe * dp, char * ch);
68 unsigned int DualPipe_Putc(_DualPipe * dp, char ch);
70 unsigned int DualPipe_Puts(_DualPipe * dp, const char * string);
72 unsigned int DualPipe_Seek(_DualPipe * dp, int pos, int mode);
74 unsigned int DualPipe_Tell(_DualPipe * dp);
76 unsigned int DualPipe_Eof(_DualPipe * dp);
78 unsigned int DualPipe_GetSize(_DualPipe * dp);
80 unsigned int DualPipe_Peek(_DualPipe * dp);
82 void DualPipe_Terminate(_DualPipe * dp);
84 int DualPipe_GetExitCode(_DualPipe * dp);
86 int DualPipe_GetProcessID(_DualPipe * dp);
88 void DualPipe_Wait(_DualPipe * dp);
90 _DualPipe * _DualPipeOpen(unsigned int mode, const char * commandLine, const char * env, void ** inputPtr, void ** outputPtr);
92 struct __ecereNameSpace__ecere__sys__DualPipe
97 extern struct __ecereNameSpace__ecere__com__Property * __ecereProp___ecereNameSpace__ecere__sys__File_input;
99 extern struct __ecereNameSpace__ecere__com__Property * __ecereProp___ecereNameSpace__ecere__sys__File_output;
101 struct __ecereNameSpace__ecere__sys__BTNode;
103 struct __ecereNameSpace__ecere__sys__OldList
112 struct __ecereNameSpace__ecere__com__DataValue
127 } ecere_gcc_struct __anon1;
130 struct __ecereNameSpace__ecere__com__SerialBuffer
132 unsigned char * _buffer;
138 extern void * __ecereNameSpace__ecere__com__eSystem_New(unsigned int size);
140 extern void * __ecereNameSpace__ecere__com__eSystem_New0(unsigned int size);
142 extern void * __ecereNameSpace__ecere__com__eSystem_Renew(void * memory, unsigned int size);
144 extern void * __ecereNameSpace__ecere__com__eSystem_Renew0(void * memory, unsigned int size);
146 extern void __ecereNameSpace__ecere__com__eSystem_Delete(void * memory);
148 extern int vsnprintf(char * , size_t, const char * , __builtin_va_list);
150 struct __ecereNameSpace__ecere__com__BitMember;
152 struct __ecereNameSpace__ecere__com__GlobalFunction;
154 struct __ecereNameSpace__ecere__com__Class;
156 struct __ecereNameSpace__ecere__com__Instance
159 struct __ecereNameSpace__ecere__com__Class * _class;
163 extern long long __ecereNameSpace__ecere__com__eClass_GetProperty(struct __ecereNameSpace__ecere__com__Class * _class, const char * name);
165 extern void __ecereNameSpace__ecere__com__eClass_SetProperty(struct __ecereNameSpace__ecere__com__Class * _class, const char * name, long long value);
167 extern struct __ecereNameSpace__ecere__com__BitMember * __ecereNameSpace__ecere__com__eClass_AddBitMember(struct __ecereNameSpace__ecere__com__Class * _class, const char * name, const char * type, int bitSize, int bitPos, int declMode);
169 extern void * __ecereNameSpace__ecere__com__eInstance_New(struct __ecereNameSpace__ecere__com__Class * _class);
171 extern void __ecereNameSpace__ecere__com__eInstance_SetMethod(struct __ecereNameSpace__ecere__com__Instance * instance, const char * name, void * function);
173 extern void __ecereNameSpace__ecere__com__eInstance_IncRef(struct __ecereNameSpace__ecere__com__Instance * instance);
175 void * __ecereProp___ecereNameSpace__ecere__sys__File_Get_input(struct __ecereNameSpace__ecere__com__Instance * this);
177 void __ecereProp___ecereNameSpace__ecere__sys__File_Set_input(struct __ecereNameSpace__ecere__com__Instance * this, void * value);
179 int __ecereVMethodID___ecereNameSpace__ecere__sys__File_CloseInput;
181 void * __ecereProp___ecereNameSpace__ecere__sys__File_Get_output(struct __ecereNameSpace__ecere__com__Instance * this);
183 void __ecereProp___ecereNameSpace__ecere__sys__File_Set_output(struct __ecereNameSpace__ecere__com__Instance * this, void * value);
185 int __ecereVMethodID___ecereNameSpace__ecere__sys__File_CloseOutput;
187 int __ecereVMethodID___ecereNameSpace__ecere__sys__File_Write;
189 int __ecereVMethodID___ecereNameSpace__ecere__sys__File_Getc;
191 int __ecereVMethodID___ecereNameSpace__ecere__sys__File_Putc;
193 int __ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts;
195 unsigned int __ecereMethod___ecereNameSpace__ecere__sys__File_Flush(struct __ecereNameSpace__ecere__com__Instance * this);
197 int __ecereVMethodID___ecereNameSpace__ecere__sys__File_Seek;
199 int __ecereVMethodID___ecereNameSpace__ecere__sys__File_Tell;
201 int __ecereVMethodID___ecereNameSpace__ecere__sys__File_GetSize;
203 int __ecereVMethodID___ecereNameSpace__ecere__sys__File_Eof;
205 struct __ecereNameSpace__ecere__com__Property;
207 struct __ecereNameSpace__ecere__com__Property
209 struct __ecereNameSpace__ecere__com__Property * prev;
210 struct __ecereNameSpace__ecere__com__Property * next;
212 unsigned int isProperty;
215 struct __ecereNameSpace__ecere__com__Class * _class;
216 const char * dataTypeString;
217 struct __ecereNameSpace__ecere__com__Class * dataTypeClass;
218 struct __ecereNameSpace__ecere__com__Instance * dataType;
219 void (* Set)(void * , int);
220 int (* Get)(void * );
221 unsigned int (* IsSet)(void * );
225 unsigned int conversion;
226 unsigned int watcherOffset;
227 const char * category;
228 unsigned int compiled;
229 unsigned int selfWatchable;
230 unsigned int isWatchable;
233 extern void __ecereNameSpace__ecere__com__eInstance_FireSelfWatchers(struct __ecereNameSpace__ecere__com__Instance * instance, struct __ecereNameSpace__ecere__com__Property * _property);
235 extern void __ecereNameSpace__ecere__com__eInstance_StopWatching(struct __ecereNameSpace__ecere__com__Instance * instance, struct __ecereNameSpace__ecere__com__Property * _property, struct __ecereNameSpace__ecere__com__Instance * object);
237 extern void __ecereNameSpace__ecere__com__eInstance_Watch(void * instance, struct __ecereNameSpace__ecere__com__Property * _property, void * object, void (* callback)(void * , void * ));
239 extern void __ecereNameSpace__ecere__com__eInstance_FireWatchers(struct __ecereNameSpace__ecere__com__Instance * instance, struct __ecereNameSpace__ecere__com__Property * _property);
241 struct __ecereNameSpace__ecere__sys__BinaryTree;
243 struct __ecereNameSpace__ecere__sys__BinaryTree
245 struct __ecereNameSpace__ecere__sys__BTNode * root;
247 int (* CompareKey)(struct __ecereNameSpace__ecere__sys__BinaryTree * tree, uintptr_t a, uintptr_t b);
248 void (* FreeKey)(void * key);
251 struct __ecereNameSpace__ecere__com__Instance * __ecereNameSpace__ecere__sys__DualPipeOpen(unsigned int mode, const char * commandLine);
253 struct __ecereNameSpace__ecere__com__Instance * __ecereNameSpace__ecere__sys__DualPipeOpenf(unsigned int mode, const char * command, ...)
255 char commandLine[1025];
258 __builtin_va_start(args, command);
259 vsnprintf(commandLine, sizeof (commandLine), command, args);
260 commandLine[sizeof (commandLine) - 1] = 0;
261 __builtin_va_end(args);
262 return __ecereNameSpace__ecere__sys__DualPipeOpen(mode, commandLine);
265 struct __ecereNameSpace__ecere__com__Instance * __ecereNameSpace__ecere__sys__DualPipeOpenEnv(unsigned int mode, const char * env, const char * commandLine);
267 struct __ecereNameSpace__ecere__com__Instance * __ecereNameSpace__ecere__sys__DualPipeOpenEnvf(unsigned int mode, const char * env, const char * command, ...)
269 char commandLine[1025];
272 __builtin_va_start(args, command);
273 vsnprintf(commandLine, sizeof (commandLine), command, args);
274 commandLine[sizeof (commandLine) - 1] = 0;
275 __builtin_va_end(args);
276 return __ecereNameSpace__ecere__sys__DualPipeOpenEnv(mode, env, commandLine);
279 struct __ecereNameSpace__ecere__com__Method;
281 struct __ecereNameSpace__ecere__com__Method
284 struct __ecereNameSpace__ecere__com__Method * parent;
285 struct __ecereNameSpace__ecere__com__Method * left;
286 struct __ecereNameSpace__ecere__com__Method * right;
291 struct __ecereNameSpace__ecere__com__Class * _class;
293 const char * dataTypeString;
294 struct __ecereNameSpace__ecere__com__Instance * dataType;
298 extern struct __ecereNameSpace__ecere__com__Method * __ecereNameSpace__ecere__com__eClass_AddMethod(struct __ecereNameSpace__ecere__com__Class * _class, const char * name, const char * type, void * function, int declMode);
300 struct __ecereNameSpace__ecere__com__Module;
302 extern struct __ecereNameSpace__ecere__com__Class * __ecereNameSpace__ecere__com__eSystem_RegisterClass(int type, const char * name, const char * baseName, int size, int sizeClass, unsigned int (* Constructor)(void * ), void (* Destructor)(void * ), struct __ecereNameSpace__ecere__com__Instance * module, int declMode, int inheritanceAccess);
304 extern struct __ecereNameSpace__ecere__com__Instance * __thisModule;
306 extern struct __ecereNameSpace__ecere__com__GlobalFunction * __ecereNameSpace__ecere__com__eSystem_RegisterFunction(const char * name, const char * type, void * func, struct __ecereNameSpace__ecere__com__Instance * module, int declMode);
308 struct __ecereNameSpace__ecere__com__NameSpace;
310 struct __ecereNameSpace__ecere__com__NameSpace
313 struct __ecereNameSpace__ecere__com__NameSpace * btParent;
314 struct __ecereNameSpace__ecere__com__NameSpace * left;
315 struct __ecereNameSpace__ecere__com__NameSpace * right;
317 struct __ecereNameSpace__ecere__com__NameSpace * parent;
318 struct __ecereNameSpace__ecere__sys__BinaryTree nameSpaces;
319 struct __ecereNameSpace__ecere__sys__BinaryTree classes;
320 struct __ecereNameSpace__ecere__sys__BinaryTree defines;
321 struct __ecereNameSpace__ecere__sys__BinaryTree functions;
324 struct __ecereNameSpace__ecere__com__Application
329 unsigned int isGUIApp;
330 struct __ecereNameSpace__ecere__sys__OldList allModules;
331 char * parsedCommand;
332 struct __ecereNameSpace__ecere__com__NameSpace systemNameSpace;
335 struct __ecereNameSpace__ecere__com__Module
337 struct __ecereNameSpace__ecere__com__Instance * application;
338 struct __ecereNameSpace__ecere__sys__OldList classes;
339 struct __ecereNameSpace__ecere__sys__OldList defines;
340 struct __ecereNameSpace__ecere__sys__OldList functions;
341 struct __ecereNameSpace__ecere__sys__OldList modules;
342 struct __ecereNameSpace__ecere__com__Instance * prev;
343 struct __ecereNameSpace__ecere__com__Instance * next;
349 struct __ecereNameSpace__ecere__com__NameSpace privateNameSpace;
350 struct __ecereNameSpace__ecere__com__NameSpace publicNameSpace;
353 void __ecereUnregisterModule_DualPipe(struct __ecereNameSpace__ecere__com__Instance * module)
358 struct __ecereNameSpace__ecere__com__DataMember;
360 struct __ecereNameSpace__ecere__com__ClassTemplateArgument
366 const char * dataTypeString;
367 struct __ecereNameSpace__ecere__com__Class * dataTypeClass;
368 } ecere_gcc_struct __anon1;
369 struct __ecereNameSpace__ecere__com__DataValue expression;
372 const char * memberString;
375 struct __ecereNameSpace__ecere__com__DataMember * member;
376 struct __ecereNameSpace__ecere__com__Property * prop;
377 struct __ecereNameSpace__ecere__com__Method * method;
378 } ecere_gcc_struct __anon1;
379 } ecere_gcc_struct __anon2;
380 } ecere_gcc_struct __anon1;
383 struct __ecereNameSpace__ecere__com__DataMember
385 struct __ecereNameSpace__ecere__com__DataMember * prev;
386 struct __ecereNameSpace__ecere__com__DataMember * next;
388 unsigned int isProperty;
391 struct __ecereNameSpace__ecere__com__Class * _class;
392 const char * dataTypeString;
393 struct __ecereNameSpace__ecere__com__Class * dataTypeClass;
394 struct __ecereNameSpace__ecere__com__Instance * dataType;
398 struct __ecereNameSpace__ecere__sys__OldList members;
399 struct __ecereNameSpace__ecere__sys__BinaryTree membersAlpha;
401 short structAlignment;
402 short pointerAlignment;
405 struct __ecereNameSpace__ecere__com__Class
407 struct __ecereNameSpace__ecere__com__Class * prev;
408 struct __ecereNameSpace__ecere__com__Class * next;
414 unsigned int (* Constructor)(void * );
415 void (* Destructor)(void * );
418 struct __ecereNameSpace__ecere__com__Class * base;
419 struct __ecereNameSpace__ecere__sys__BinaryTree methods;
420 struct __ecereNameSpace__ecere__sys__BinaryTree members;
421 struct __ecereNameSpace__ecere__sys__BinaryTree prop;
422 struct __ecereNameSpace__ecere__sys__OldList membersAndProperties;
423 struct __ecereNameSpace__ecere__sys__BinaryTree classProperties;
424 struct __ecereNameSpace__ecere__sys__OldList derivatives;
428 struct __ecereNameSpace__ecere__com__Instance * module;
429 struct __ecereNameSpace__ecere__com__NameSpace * nameSpace;
430 const char * dataTypeString;
431 struct __ecereNameSpace__ecere__com__Instance * dataType;
433 int defaultAlignment;
434 void (* Initialize)();
436 struct __ecereNameSpace__ecere__sys__OldList selfWatchers;
437 const char * designerClass;
438 unsigned int noExpansion;
439 const char * defaultProperty;
440 unsigned int comRedefinition;
443 unsigned int internalDecl;
445 unsigned int computeSize;
446 short structAlignment;
447 short pointerAlignment;
448 int destructionWatchOffset;
450 struct __ecereNameSpace__ecere__sys__OldList delayedCPValues;
451 int inheritanceAccess;
452 const char * fullName;
454 struct __ecereNameSpace__ecere__sys__OldList conversions;
455 struct __ecereNameSpace__ecere__sys__OldList templateParams;
456 struct __ecereNameSpace__ecere__com__ClassTemplateArgument * templateArgs;
457 struct __ecereNameSpace__ecere__com__Class * templateClass;
458 struct __ecereNameSpace__ecere__sys__OldList templatized;
460 unsigned int isInstanceClass;
461 unsigned int byValueSystemClass;
464 static struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__sys__PipeOpenMode;
466 static struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__sys__DualPipe;
468 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__sys__File;
470 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__Module;
472 void __ecereDestructor___ecereNameSpace__ecere__sys__DualPipe(struct __ecereNameSpace__ecere__com__Instance * this)
474 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
477 DualPipe_Destructor(__ecerePointer___ecereNameSpace__ecere__sys__DualPipe->dp);
481 int __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Read(struct __ecereNameSpace__ecere__com__Instance * this, unsigned char * buffer, unsigned int size, unsigned int count)
483 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
485 return DualPipe_Read(__ecerePointer___ecereNameSpace__ecere__sys__DualPipe->dp, buffer, size, count);
488 unsigned int __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Eof(struct __ecereNameSpace__ecere__com__Instance * this)
490 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
492 return DualPipe_Eof(__ecerePointer___ecereNameSpace__ecere__sys__DualPipe->dp);
495 unsigned int __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Peek(struct __ecereNameSpace__ecere__com__Instance * this)
497 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
499 return DualPipe_Peek(__ecerePointer___ecereNameSpace__ecere__sys__DualPipe->dp);
502 void __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Terminate(struct __ecereNameSpace__ecere__com__Instance * this)
504 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
506 DualPipe_Terminate(__ecerePointer___ecereNameSpace__ecere__sys__DualPipe->dp);
509 int __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_GetExitCode(struct __ecereNameSpace__ecere__com__Instance * this)
511 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
513 return DualPipe_GetExitCode(__ecerePointer___ecereNameSpace__ecere__sys__DualPipe->dp);
516 int __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_GetProcessID(struct __ecereNameSpace__ecere__com__Instance * this)
518 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
520 return DualPipe_GetProcessID(__ecerePointer___ecereNameSpace__ecere__sys__DualPipe->dp);
523 void __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Wait(struct __ecereNameSpace__ecere__com__Instance * this)
525 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
527 DualPipe_Wait(__ecerePointer___ecereNameSpace__ecere__sys__DualPipe->dp);
530 struct __ecereNameSpace__ecere__com__Instance * __ecereNameSpace__ecere__sys__DualPipeOpen(unsigned int mode, const char * commandLine)
532 void * input, * output;
533 void * f = _DualPipeOpen(mode, commandLine, (((void *)0)), &input, &output);
536 return __extension__ ({
537 struct __ecereNameSpace__ecere__com__Instance * __ecereInstance1 = __ecereNameSpace__ecere__com__eInstance_New(__ecereClass___ecereNameSpace__ecere__sys__DualPipe);
539 ((struct __ecereNameSpace__ecere__sys__DualPipe *)(((char *)__ecereInstance1 + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset)))->dp = f, __ecereProp___ecereNameSpace__ecere__sys__File_Set_input(__ecereInstance1, input), __ecereProp___ecereNameSpace__ecere__sys__File_Set_output(__ecereInstance1, output), __ecereInstance1;
541 return (((void *)0));
544 struct __ecereNameSpace__ecere__com__Instance * __ecereNameSpace__ecere__sys__DualPipeOpenEnv(unsigned int mode, const char * env, const char * commandLine)
546 void * input, * output;
547 void * f = _DualPipeOpen(mode, commandLine, env, &input, &output);
550 return __extension__ ({
551 struct __ecereNameSpace__ecere__com__Instance * __ecereInstance1 = __ecereNameSpace__ecere__com__eInstance_New(__ecereClass___ecereNameSpace__ecere__sys__DualPipe);
553 ((struct __ecereNameSpace__ecere__sys__DualPipe *)(((char *)__ecereInstance1 + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset)))->dp = f, __ecereProp___ecereNameSpace__ecere__sys__File_Set_input(__ecereInstance1, input), __ecereProp___ecereNameSpace__ecere__sys__File_Set_output(__ecereInstance1, output), __ecereInstance1;
555 return (((void *)0));
558 void __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_CloseInput(struct __ecereNameSpace__ecere__com__Instance * this)
560 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
562 (__ecereProp___ecereNameSpace__ecere__sys__File_Get_input(this) != (((void *)0))) ? (__extension__ ({
563 void (* __internal_VirtualMethod)(struct __ecereNameSpace__ecere__com__Instance *);
565 __internal_VirtualMethod = ((void (*)(struct __ecereNameSpace__ecere__com__Instance *))__ecereClass___ecereNameSpace__ecere__sys__File->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_CloseInput]);
566 __internal_VirtualMethod ? __internal_VirtualMethod(this) : (void)1;
567 })) : DualPipe_CloseInput(__ecerePointer___ecereNameSpace__ecere__sys__DualPipe->dp);
570 void __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_CloseOutput(struct __ecereNameSpace__ecere__com__Instance * this)
572 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
574 (__ecereProp___ecereNameSpace__ecere__sys__File_Get_output(this) != (((void *)0))) ? (__extension__ ({
575 void (* __internal_VirtualMethod)(struct __ecereNameSpace__ecere__com__Instance *);
577 __internal_VirtualMethod = ((void (*)(struct __ecereNameSpace__ecere__com__Instance *))__ecereClass___ecereNameSpace__ecere__sys__File->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_CloseOutput]);
578 __internal_VirtualMethod ? __internal_VirtualMethod(this) : (void)1;
579 })) : DualPipe_CloseOutput(__ecerePointer___ecereNameSpace__ecere__sys__DualPipe->dp);
582 int __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Write(struct __ecereNameSpace__ecere__com__Instance * this, const unsigned char * buffer, unsigned int size, unsigned int count)
584 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
586 return __ecereProp___ecereNameSpace__ecere__sys__File_Get_output(this) ? (__extension__ ({
587 int (* __internal_VirtualMethod)(struct __ecereNameSpace__ecere__com__Instance *, const void * buffer, unsigned int size, unsigned int count);
589 __internal_VirtualMethod = ((int (*)(struct __ecereNameSpace__ecere__com__Instance *, const void * buffer, unsigned int size, unsigned int count))__ecereClass___ecereNameSpace__ecere__sys__File->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Write]);
590 __internal_VirtualMethod ? __internal_VirtualMethod(this, buffer, size, count) : (int)1;
591 })) : DualPipe_Write(__ecerePointer___ecereNameSpace__ecere__sys__DualPipe->dp, buffer, size, count);
594 unsigned int __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Getc(struct __ecereNameSpace__ecere__com__Instance * this, char * ch)
596 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
598 return __ecereProp___ecereNameSpace__ecere__sys__File_Get_input(this) ? (__extension__ ({
599 unsigned int (* __internal_VirtualMethod)(struct __ecereNameSpace__ecere__com__Instance *, char * ch);
601 __internal_VirtualMethod = ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, char * ch))__ecereClass___ecereNameSpace__ecere__sys__File->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Getc]);
602 __internal_VirtualMethod ? __internal_VirtualMethod(this, ch) : (unsigned int)1;
603 })) : DualPipe_Getc(__ecerePointer___ecereNameSpace__ecere__sys__DualPipe->dp, ch);
606 unsigned int __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Putc(struct __ecereNameSpace__ecere__com__Instance * this, char ch)
608 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
610 return __ecereProp___ecereNameSpace__ecere__sys__File_Get_output(this) ? (__extension__ ({
611 unsigned int (* __internal_VirtualMethod)(struct __ecereNameSpace__ecere__com__Instance *, char ch);
613 __internal_VirtualMethod = ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, char ch))__ecereClass___ecereNameSpace__ecere__sys__File->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Putc]);
614 __internal_VirtualMethod ? __internal_VirtualMethod(this, ch) : (unsigned int)1;
615 })) : DualPipe_Putc(__ecerePointer___ecereNameSpace__ecere__sys__DualPipe->dp, ch);
618 unsigned int __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Puts(struct __ecereNameSpace__ecere__com__Instance * this, const char * string)
620 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
622 return __ecereProp___ecereNameSpace__ecere__sys__File_Get_output(this) ? ((__extension__ ({
623 unsigned int (* __internal_VirtualMethod)(struct __ecereNameSpace__ecere__com__Instance *, const char * string);
625 __internal_VirtualMethod = ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))__ecereClass___ecereNameSpace__ecere__sys__File->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts]);
626 __internal_VirtualMethod ? __internal_VirtualMethod(this, string) : (unsigned int)1;
627 })), __ecereMethod___ecereNameSpace__ecere__sys__File_Flush(this)) : DualPipe_Puts(__ecerePointer___ecereNameSpace__ecere__sys__DualPipe->dp, string);
630 unsigned int __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Seek(struct __ecereNameSpace__ecere__com__Instance * this, int pos, int mode)
632 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
634 return (__ecereProp___ecereNameSpace__ecere__sys__File_Get_input(this) || __ecereProp___ecereNameSpace__ecere__sys__File_Get_output(this)) ? (__extension__ ({
635 unsigned int (* __internal_VirtualMethod)(struct __ecereNameSpace__ecere__com__Instance *, int pos, int mode);
637 __internal_VirtualMethod = ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, int pos, int mode))__ecereClass___ecereNameSpace__ecere__sys__File->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Seek]);
638 __internal_VirtualMethod ? __internal_VirtualMethod(this, pos, mode) : (unsigned int)1;
639 })) : DualPipe_Seek(__ecerePointer___ecereNameSpace__ecere__sys__DualPipe->dp, pos, mode);
642 unsigned int __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Tell(struct __ecereNameSpace__ecere__com__Instance * this)
644 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
646 return (__ecereProp___ecereNameSpace__ecere__sys__File_Get_input(this) || __ecereProp___ecereNameSpace__ecere__sys__File_Get_output(this)) ? (__extension__ ({
647 unsigned int (* __internal_VirtualMethod)(struct __ecereNameSpace__ecere__com__Instance *);
649 __internal_VirtualMethod = ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *))__ecereClass___ecereNameSpace__ecere__sys__File->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Tell]);
650 __internal_VirtualMethod ? __internal_VirtualMethod(this) : (unsigned int)1;
651 })) : DualPipe_Tell(__ecerePointer___ecereNameSpace__ecere__sys__DualPipe->dp);
654 unsigned int __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_GetSize(struct __ecereNameSpace__ecere__com__Instance * this)
656 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
658 return (__ecereProp___ecereNameSpace__ecere__sys__File_Get_input(this) || __ecereProp___ecereNameSpace__ecere__sys__File_Get_output(this)) ? (__extension__ ({
659 unsigned int (* __internal_VirtualMethod)(struct __ecereNameSpace__ecere__com__Instance *);
661 __internal_VirtualMethod = ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *))__ecereClass___ecereNameSpace__ecere__sys__File->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_GetSize]);
662 __internal_VirtualMethod ? __internal_VirtualMethod(this) : (unsigned int)1;
663 })) : DualPipe_GetSize(__ecerePointer___ecereNameSpace__ecere__sys__DualPipe->dp);
666 unsigned int __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_GetLinePeek(struct __ecereNameSpace__ecere__com__Instance * this, char * s, int max, int * charsRead)
668 __attribute__((unused)) struct __ecereNameSpace__ecere__sys__DualPipe * __ecerePointer___ecereNameSpace__ecere__sys__DualPipe = (struct __ecereNameSpace__ecere__sys__DualPipe *)(this ? (((char *)this) + __ecereClass___ecereNameSpace__ecere__sys__DualPipe->offset) : 0);
672 while(c < max - 1 && __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Peek(this) && (__extension__ ({
673 unsigned int (* __internal_VirtualMethod)(struct __ecereNameSpace__ecere__com__Instance *, char * ch);
675 __internal_VirtualMethod = ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, char * ch))__extension__ ({
676 struct __ecereNameSpace__ecere__com__Instance * __internal_ClassInst = this;
678 __internal_ClassInst ? __internal_ClassInst->_vTbl : __ecereClass___ecereNameSpace__ecere__sys__DualPipe->_vTbl;
679 })[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Getc]);
680 __internal_VirtualMethod ? __internal_VirtualMethod(this, &ch) : (unsigned int)1;
686 return (__extension__ ({
687 unsigned int (* __internal_VirtualMethod)(struct __ecereNameSpace__ecere__com__Instance *);
689 __internal_VirtualMethod = ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *))__extension__ ({
690 struct __ecereNameSpace__ecere__com__Instance * __internal_ClassInst = this;
692 __internal_ClassInst ? __internal_ClassInst->_vTbl : __ecereClass___ecereNameSpace__ecere__sys__DualPipe->_vTbl;
693 })[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Eof]);
694 __internal_VirtualMethod ? __internal_VirtualMethod(this) : (unsigned int)1;
698 void __ecereRegisterModule_DualPipe(struct __ecereNameSpace__ecere__com__Instance * module)
700 struct __ecereNameSpace__ecere__com__Class __attribute__((unused)) * class;
702 class = __ecereNameSpace__ecere__com__eSystem_RegisterClass(2, "ecere::sys::PipeOpenMode", 0, 0, 0, (void *)0, (void *)0, module, 1, 1);
703 if(((struct __ecereNameSpace__ecere__com__Module *)(((char *)module + sizeof(struct __ecereNameSpace__ecere__com__Instance))))->application == ((struct __ecereNameSpace__ecere__com__Module *)(((char *)__thisModule + sizeof(struct __ecereNameSpace__ecere__com__Instance))))->application && class)
704 __ecereClass___ecereNameSpace__ecere__sys__PipeOpenMode = class;
705 __ecereNameSpace__ecere__com__eClass_AddBitMember(class, "output", "bool", 1, 0, 1);
706 __ecereNameSpace__ecere__com__eClass_AddBitMember(class, "error", "bool", 1, 1, 1);
707 __ecereNameSpace__ecere__com__eClass_AddBitMember(class, "input", "bool", 1, 2, 1);
708 __ecereNameSpace__ecere__com__eClass_AddBitMember(class, "showWindow", "bool", 1, 3, 1);
709 class = __ecereNameSpace__ecere__com__eSystem_RegisterClass(0, "ecere::sys::DualPipe", "ecere::sys::File", sizeof(struct __ecereNameSpace__ecere__sys__DualPipe), 0, (void *)0, (void *)__ecereDestructor___ecereNameSpace__ecere__sys__DualPipe, module, 1, 1);
710 if(((struct __ecereNameSpace__ecere__com__Module *)(((char *)module + sizeof(struct __ecereNameSpace__ecere__com__Instance))))->application == ((struct __ecereNameSpace__ecere__com__Module *)(((char *)__thisModule + sizeof(struct __ecereNameSpace__ecere__com__Instance))))->application && class)
711 __ecereClass___ecereNameSpace__ecere__sys__DualPipe = class;
712 __ecereNameSpace__ecere__com__eClass_AddMethod(class, "Seek", 0, __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Seek, 1);
713 __ecereNameSpace__ecere__com__eClass_AddMethod(class, "Tell", 0, __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Tell, 1);
714 __ecereNameSpace__ecere__com__eClass_AddMethod(class, "Read", 0, __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Read, 1);
715 __ecereNameSpace__ecere__com__eClass_AddMethod(class, "Write", 0, __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Write, 1);
716 __ecereNameSpace__ecere__com__eClass_AddMethod(class, "Getc", 0, __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Getc, 1);
717 __ecereNameSpace__ecere__com__eClass_AddMethod(class, "Putc", 0, __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Putc, 1);
718 __ecereNameSpace__ecere__com__eClass_AddMethod(class, "Puts", 0, __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Puts, 1);
719 __ecereNameSpace__ecere__com__eClass_AddMethod(class, "Eof", 0, __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Eof, 1);
720 __ecereNameSpace__ecere__com__eClass_AddMethod(class, "GetSize", 0, __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_GetSize, 1);
721 __ecereNameSpace__ecere__com__eClass_AddMethod(class, "CloseInput", 0, __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_CloseInput, 1);
722 __ecereNameSpace__ecere__com__eClass_AddMethod(class, "CloseOutput", 0, __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_CloseOutput, 1);
723 __ecereNameSpace__ecere__com__eClass_AddMethod(class, "GetExitCode", "int GetExitCode()", __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_GetExitCode, 1);
724 __ecereNameSpace__ecere__com__eClass_AddMethod(class, "GetLinePeek", "bool GetLinePeek(char * s, int max, int * charsRead)", __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_GetLinePeek, 1);
725 __ecereNameSpace__ecere__com__eClass_AddMethod(class, "GetProcessID", "int GetProcessID()", __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_GetProcessID, 1);
726 __ecereNameSpace__ecere__com__eClass_AddMethod(class, "Peek", "bool Peek()", __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Peek, 1);
727 __ecereNameSpace__ecere__com__eClass_AddMethod(class, "Terminate", "void Terminate()", __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Terminate, 1);
728 __ecereNameSpace__ecere__com__eClass_AddMethod(class, "Wait", "void Wait()", __ecereMethod___ecereNameSpace__ecere__sys__DualPipe_Wait, 1);
729 __ecereNameSpace__ecere__com__eSystem_RegisterFunction("ecere::sys::DualPipeOpenf", "ecere::sys::DualPipe ecere::sys::DualPipeOpenf(ecere::sys::PipeOpenMode mode, const char * command, ...)", __ecereNameSpace__ecere__sys__DualPipeOpenf, module, 1);
730 __ecereNameSpace__ecere__com__eSystem_RegisterFunction("ecere::sys::DualPipeOpen", "ecere::sys::DualPipe ecere::sys::DualPipeOpen(ecere::sys::PipeOpenMode mode, const char * commandLine)", __ecereNameSpace__ecere__sys__DualPipeOpen, module, 1);
731 __ecereNameSpace__ecere__com__eSystem_RegisterFunction("ecere::sys::DualPipeOpenEnvf", "ecere::sys::DualPipe ecere::sys::DualPipeOpenEnvf(ecere::sys::PipeOpenMode mode, const char * env, const char * command, ...)", __ecereNameSpace__ecere__sys__DualPipeOpenEnvf, module, 1);
732 __ecereNameSpace__ecere__com__eSystem_RegisterFunction("ecere::sys::DualPipeOpenEnv", "ecere::sys::DualPipe ecere::sys::DualPipeOpenEnv(ecere::sys::PipeOpenMode mode, const char * env, const char * commandLine)", __ecereNameSpace__ecere__sys__DualPipeOpenEnv, module, 1);