dbus-spawn.h

00001 /* -*- mode: C; c-file-style: "gnu" -*- */
00002 /* dbus-spawn.h Wrapper around fork/exec
00003  * 
00004  * Copyright (C) 2002, 2003  Red Hat, Inc.
00005  * Copyright (C) 2003 CodeFactory AB
00006  *
00007  * Licensed under the Academic Free License version 2.1
00008  * 
00009  * This program is free software; you can redistribute it and/or modify
00010  * it under the terms of the GNU General Public License as published by
00011  * the Free Software Foundation; either version 2 of the License, or
00012  * (at your option) any later version.
00013  *
00014  * This program is distributed in the hope that it will be useful,
00015  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00016  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00017  * GNU General Public License for more details.
00018  * 
00019  * You should have received a copy of the GNU General Public License
00020  * along with this program; if not, write to the Free Software
00021  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00022  *
00023  */
00024 
00025 #ifndef DBUS_SPAWN_H
00026 #define DBUS_SPAWN_H
00027 
00028 #include <dbus/dbus-string.h>
00029 #include <dbus/dbus-errors.h>
00030 #include <dbus/dbus-watch.h>
00031 
00032 DBUS_BEGIN_DECLS
00033 
00034 typedef void (* DBusSpawnChildSetupFunc) (void *user_data);
00035 
00036 typedef struct DBusBabysitter DBusBabysitter;
00037 
00038 dbus_bool_t _dbus_spawn_async_with_babysitter     (DBusBabysitter           **sitter_p,
00039                                                    char                     **argv,
00040                                                    DBusSpawnChildSetupFunc    child_setup,
00041                                                    void                      *user_data,
00042                                                    DBusError                 *error);
00043 DBusBabysitter* _dbus_babysitter_ref              (DBusBabysitter            *sitter);
00044 void        _dbus_babysitter_unref                (DBusBabysitter            *sitter);
00045 void        _dbus_babysitter_kill_child           (DBusBabysitter            *sitter);
00046 dbus_bool_t _dbus_babysitter_get_child_exited     (DBusBabysitter            *sitter);
00047 void        _dbus_babysitter_set_child_exit_error (DBusBabysitter            *sitter,
00048                                                    DBusError                 *error);
00049 dbus_bool_t _dbus_babysitter_set_watch_functions  (DBusBabysitter            *sitter,
00050                                                    DBusAddWatchFunction       add_function,
00051                                                    DBusRemoveWatchFunction    remove_function,
00052                                                    DBusWatchToggledFunction   toggled_function,
00053                                                    void                      *data,
00054                                                    DBusFreeFunction           free_data_function);
00055 
00056 DBUS_END_DECLS
00057 
00058 #endif /* DBUS_SPAWN_H */

Generated on Fri Sep 21 18:12:13 2007 for D-Bus by  doxygen 1.5.1