rllib
1
Main Page
Classes
Files
File List
File Members
All
Classes
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
lib
rlspawn.h
Go to the documentation of this file.
1
/***************************************************************************
2
rlspawn.h - description
3
-------------------
4
begin : Tue Jan 02 2001
5
copyright : (C) 2001 by R. Lehrig
6
email : lehrig@t-online.de
7
***************************************************************************/
8
9
/***************************************************************************
10
* *
11
* This library is free software; you can redistribute it and/or modify *
12
* it under the terms of the GNU LESSER GENERAL PUBLIC LICENSE as *
13
* published by the Free Software Foundation *
14
* *
15
***************************************************************************/
16
#ifndef _RL_SPAWN_H_
17
#define _RL_SPAWN_H_
18
19
#include "
rldefine.h
"
20
21
#ifndef RLUNIX
22
//#warning This Functionality is only available under Linux/Unix
23
#endif
24
32
class
rlSpawn
33
{
34
public
:
35
rlSpawn
();
36
virtual
~rlSpawn
();
37
44
int
spawn
(
const
char
*command);
45
50
const
char
*
readLine
();
51
56
int
getchar
();
57
63
int
select
(
int
timeout=50);
64
71
int
writeString
(
const
char
*buf);
72
78
int
write
(
const
char
*buf,
int
len);
79
85
int
printf
(
const
char
*format, ...);
86
90
void
printAll
();
91
92
int
pid
;
93
94
private
:
95
void
*
toChild
,*
fromChild
;
96
char
line
[4096];
// adjust this if the buffer is not big enough
97
};
98
99
#endif
Generated by
1.8.2