Darin Petkov | f7897bc | 2011-06-08 17:13:36 -0700 | [diff] [blame] | 1 | // Copyright (c) 2011 The Chromium OS Authors. All rights reserved. |
| 2 | // Use of this source code is governed by a BSD-style license that can be |
| 3 | // found in the LICENSE file. |
| 4 | |
| 5 | #ifndef SHILL_GLIB_H_ |
| 6 | #define SHILL_GLIB_H_ |
| 7 | |
| 8 | #include "shill/glib_interface.h" |
| 9 | |
| 10 | namespace shill { |
| 11 | |
| 12 | // A concrete implementation of the GLib interface. |
| 13 | class GLib : public GLibInterface { |
| 14 | public: |
Darin Petkov | 92c4390 | 2011-06-09 20:46:06 -0700 | [diff] [blame] | 15 | virtual guint ChildWatchAdd(GPid pid, |
| 16 | GChildWatchFunc function, |
| 17 | gpointer data); |
| 18 | virtual gboolean SourceRemove(guint tag); |
Darin Petkov | f7897bc | 2011-06-08 17:13:36 -0700 | [diff] [blame] | 19 | virtual gboolean SpawnAsync(const gchar *working_directory, |
| 20 | gchar **argv, |
| 21 | gchar **envp, |
| 22 | GSpawnFlags flags, |
| 23 | GSpawnChildSetupFunc child_setup, |
| 24 | gpointer user_data, |
| 25 | GPid *child_pid, |
| 26 | GError **error); |
Darin Petkov | 92c4390 | 2011-06-09 20:46:06 -0700 | [diff] [blame] | 27 | virtual void SpawnClosePID(GPid pid); |
Darin Petkov | f7897bc | 2011-06-08 17:13:36 -0700 | [diff] [blame] | 28 | }; |
| 29 | |
| 30 | } // namespace shill |
| 31 | |
| 32 | #endif // SHILL_GLIB_H_ |