]> git.lyx.org Git - features.git/blob - src/support/syscall.h
64bcab242c4241a25368552a7898192f68dda39c
[features.git] / src / support / syscall.h
1 // -*- C++ -*-
2 /**
3  *  \file syscall.h
4  *  Copyright 2002 the LyX Team
5  *  Read the file COPYING
6  *
7  * \author Asger Alstrup
8  *
9  * Interface cleaned up by
10  * \author Angus Leeming <a.leeming@ic.ac.uk>
11  *
12  * Class Systemcalls uses "system" to launch the child process.
13  * The user can choose to wait or not wait for the process to complete, but no
14  * callback is invoked upon completion of the child.
15  *
16  * The child process is not killed when the Systemcall instance goes out of
17  * scope.
18  */
19
20 #ifndef SYSCALL_H
21 #define SYSCALL_H
22
23 #include "LString.h"
24
25 #ifdef __GNUG__
26 #pragma interface
27 #endif
28
29 class Systemcalls {
30 public:
31         ///
32         enum Starttype {
33                 ///
34                 Wait,
35                 ///
36                 DontWait
37         };
38         
39         ///
40         Systemcalls() {}
41
42 #if 0
43         /** Generate instance and start child process.
44          *  The string "what" contains a commandline with arguments separated 
45          *  by spaces.
46          */
47         Systemcalls(Starttype how, string const & what);
48 #endif
49         
50         /** Start child process.
51          *  This is for reuse of the Systemcalls instance.
52          */
53         int startscript(Starttype how, string const & what);
54 };
55
56 #endif // SYSCALL_H