| GNOME Video Arcade Reference Manual | ||||
|---|---|---|---|---|
| Top | Description | ||||
struct GvaMameAsyncData; GvaMameAsyncData * gva_mame_async_data_new (GvaMameCallback callback,gpointer user_data); void gva_mame_async_data_free (GvaMameAsyncData *data); gint gva_mame_command (const gchar *arguments,gchar ***stdout_lines,gchar ***stderr_lines,GError **error);
struct GvaMameAsyncData {
GvaMameCallback callback;
gpointer user_data;
};
This structure is used to pass callback information to asynchronous operations.
GvaMameCallback |
callback function |
| user data to pass to the callback function |
GvaMameAsyncData * gva_mame_async_data_new (GvaMameCallback callback,gpointer user_data);
Creates a new GvaMameAsyncData structure and populates it with callback
and user_data. Call gva_mame_async_data_free() to free it.
|
callback function |
|
user data to pass to the callback function |
Returns : |
a new GvaMameAsyncData |
void gva_mame_async_data_free (GvaMameAsyncData *data);
Frees data.
|
a GvaMameAsyncData |
gint gva_mame_command (const gchar *arguments,gchar ***stdout_lines,gchar ***stderr_lines,GError **error);
Spawns MAME with arguments and blocks until the child process exits.
The line-based output from the stdout and stderr pipes are written to
stdout_lines and stderr_lines, respectively, as NULL-terminated
string arrays. The function returns the exit status of the child
process, or -1 if an error occurred while spawning the process.
|
command line arguments |
|
return location for stdout lines, or NULL
|
|
return location for stderr lines, or NULL
|
|
return locations for a GError, or NULL
|
Returns : |
exit status of the child process or -1 if an error occurred |