rutz::child_process Class Reference

An exception-safe wrapper around a child process from fork(). More...

#include <rutz/pipe.h>

List of all members.

Public Member Functions

 child_process ()
 Fork a child process.
 ~child_process () throw ()
 Destructor waits for child process to complete.
bool in_parent () const throw ()
 Check if we're in the parent or child process after the fork().
int wait () throw ()
 Wait for child process to complete, and return its status code.

Detailed Description

An exception-safe wrapper around a child process from fork().

Definition at line 105 of file pipe.h.


Constructor & Destructor Documentation

rutz::child_process::child_process (  ) 

Fork a child process.

Throws an exception if the fork() call fails.

Definition at line 125 of file pipe.cc.

References SRC_POS.

rutz::child_process::~child_process (  )  throw ()

Destructor waits for child process to complete.

Definition at line 133 of file pipe.cc.

References wait().


Member Function Documentation

bool rutz::child_process::in_parent (  )  const throw () [inline]

Check if we're in the parent or child process after the fork().

Definition at line 116 of file pipe.h.

Referenced by rutz::bidir_pipe::init().

int rutz::child_process::wait (  )  throw ()

Wait for child process to complete, and return its status code.

Definition at line 138 of file pipe.cc.

Referenced by rutz::exec_pipe::exit_status(), rutz::bidir_pipe::exit_status(), and ~child_process().


The documentation for this class was generated from the following files:
Generated on Sun May 8 08:31:18 2011 for iLab Neuromorphic Vision Toolkit by  doxygen 1.6.3