1#ifndef LAUNCH_PROCESS_CLASS
2#define LAUNCH_PROCESS_CLASS
34 for (
int i = 0; i <
length(); i++) {
85 static void exiting_child_signal_handler(
int sig_num);
91 / *!< this is a very general poll and will retrieve any message that's
92 available for the current thread. the message is actually processed
93 here also, by calling translate and dispatch. the returned structure
94 is mainly interesting for knowing what was done. * /
Represents a sequential, ordered, contiguous collection of objects.
@ EXPONE
synonym for EXPONENTIAL_GROWTH.
@ SIMPLE_COPY
the contents can be memcpy'd and are not deep.
@ FLUSH_INVISIBLE
blanks out allocated but inaccessible elements.
int length() const
Returns the current reported length of the allocated C array.
char * & use(int index)
A non-constant version of get(); the returned object can be modified.
array(int number=0, const char * *init=NULL_POINTER, int flags=EXPONENTIAL_GROWTH|FLUSH_INVISIBLE)
Constructs an array with room for "number" objects.
Provides a dynamically resizable ASCII character string.
Root object for any class that knows its own name.
a simple wrapper of an array of char *, used by launch_process::break_line().
Provides the capability to start processes in a variety of ways to run other applications.
DEFINE_CLASS_NAME("launch_process")
virtual ~launch_process()
static char_star_array break_line(basis::astring &app, const basis::astring ¶meters)
prepares an "app" to launch with the "parameters" (via exec).
@ RETURN_IMMEDIATELY
starts the application and comes right back to the caller.
@ AWAIT_VIA_POLLING
launches the app but polls and doesn't block on its exit.
@ AWAIT_APP_EXIT
stays in the function until the launched application has exited.
@ HIDE_APP_WINDOW
launches the application invisibly if possible.
@ SHELL_EXECUTE
only valid on windows–uses ShellExecute instead of CreateProcess.
static basis::un_int run(const basis::astring &app_name, const basis::astring &command_line, int flag, basis::un_int &child_id)
starts an application using the "app_name" as the executable to run.
Constants and objects used throughout HOOPLE.
#define NULL_POINTER
The value representing a pointer to nothing.
The guards collection helps in testing preconditions and reporting errors.
unsigned int un_int
Abbreviated name for unsigned integers.