summaryrefslogtreecommitdiff
path: root/src/lib/ecore/ecore_exe.eo
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/ecore/ecore_exe.eo')
-rw-r--r--src/lib/ecore/ecore_exe.eo87
1 files changed, 0 insertions, 87 deletions
diff --git a/src/lib/ecore/ecore_exe.eo b/src/lib/ecore/ecore_exe.eo
deleted file mode 100644
index 899d8a0..0000000
--- a/src/lib/ecore/ecore_exe.eo
+++ /dev/null
@@ -1,87 +0,0 @@
1/* FIXME: The structures are not namespaced correctly. */
2
3struct Ecore.Exe.Event_Data.Line
4{
5 [[A structure which stores information on lines data from a child process.]]
6 line: ptr(char); [[The bytes of a line of buffered data]]
7 size: int; [[The size of the line buffer in bytes]]
8}
9
10/**
11 * @struct _Ecore_Exe_Event_Data
12 * @brief A structure that stores information of data from a child process event.
13 */
14struct Ecore.Exe.Event_Data
15{
16 [[Ecore exe event data structure]]
17 exe: Efl.Object; [[The handle to the process. FIXME: should actually be Ecore.Exe, workaround cyclic]]
18 data: void_ptr; [[The raw binary data from the child process received]]
19 size: int; [[The size of this data in bytes]]
20 lines: ptr(Ecore.Exe.Event_Data.Line); [[An array of line data if line buffered. The last one has its line member set to $NULL]]
21}
22
23enum Ecore.Exe_Flags
24{
25 [[Flags for executing a child with its stdin and/or stdout piped back.]]
26 legacy: ECORE_EXE;
27
28 none = 0, [[No exe flags at all]]
29 pipe_read = 1, [[Exe Pipe Read mask]]
30 pipe_write = 2, [[Exe Pipe Write mask]]
31 pipe_error = 4, [[Exe Pipe error mask]]
32 pipe_read_line_buffered = 8, [[Reads are buffered until a newline and split 1 line per Ecore_Exe_Event_Data_Line]]
33 pipe_error_line_buffered = 16, [[Errors are buffered until a newline and split 1 line per Ecore_Exe_Event_Data_Line]]
34 pipe_auto = 32, [[stdout and stderr are buffered automatically]]
35 respawn = 64, [[FIXME: Exe is restarted if it dies]]
36 use_sh = 128, [[Use /bin/sh to run the command.]]
37 not_leader = 256, [[Do not use setsid() to set the executed process as its own session leader]]
38 term_with_parent = 512, [[Makes child receive SIGTERM when parent dies.]]
39 isolate_io = 1024, [[Try and isolate stdin/out and err of the process so it isn't shared with the parent.]]
40}
41
42class Ecore.Exe extends Efl.Object implements Efl.Control
43{
44 [[Ecore.Exe is responsible for managing portable process spawning.
45
46 With this module you are able to spawn, pause and quit spawned processes.
47 Interaction between your process and those spawned is possible using pipes or signals.
48 ]]
49
50 legacy_prefix: ecore_exe;
51 eo_prefix: ecore_obj_exe;
52 event_prefix: ecore_exe;
53 methods {
54 @property command {
55 [[Controls the command that's executed. FIXME: May need a split/rename.]]
56 set {
57 legacy: null;
58 }
59 get {
60 legacy: null;
61 }
62 values {
63 exe_cmd: string; [[The command to execute.]]
64 flags: Ecore.Exe_Flags; [[The execution flags.]]
65 }
66 }
67 }
68 implements {
69 Efl.Object.destructor;
70 Efl.Object.finalize;
71 Efl.Control.suspend { set; }
72 }
73 constructors {
74 .command;
75 }
76 events {
77 data,get: Ecore.Exe.Event_Data; [[Data received event from the child process]]
78 data,error: Ecore.Exe.Event_Data; [[Error received event from the child process]]
79 }
80}
81
82/* FIXME: Notes:
83 Should run_priority be a class function?
84 Instead of having quit, interrupt, bla bla bla, just have an enum and one function? As it's essentially a signal send.
85
86 Rename the events.
87*/