Main Page   Modules   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Related Pages  

piped_process Class Reference

A class to manage a piped process. More...

#include <piped_process.h>

Inheritance diagram for piped_process:

wxProcess List of all members.

Public Methods

  piped_process (process_progress_dialog *parent=NULL, int id=-1)
  Constructor.

bool  suck_process_output (bool after_process_terminated)
  Suck some output from the process, and query whether more input remains queued.

int  get_process_pid ()
  Accessor to a process's pid.

void  set_process_pid (int process_pid)
  Accessor to a process's pid.


Protected Attributes

process_progress_dialog m_parent
  Keep the parent, so can find the listbox to send the output to.

int  m_process_pid

Detailed Description

A class to manage a piped process.

Constructor & Destructor Documentation

piped_process::piped_process process_progress_dialog   parent = NULL,
int    id = -1
 

Constructor.

Reason we need a progress_dialog parameter [and not a wxWindow], is so we can find its listbox for output.

Parameters:
parent  The parent process_progress_dialog.
id  The ID of the control on the process_progress_dialog that will recieve event of this process terminating. (This control id should not to be confused with a pid).

Member Function Documentation

bool piped_process::suck_process_output bool    after_process_terminated
 

Suck some output from the process, and query whether more input remains queued.

param after_process_terminated TRUE if the suck is after the process is terminated (used to trace program flow during debuggging). return TRUE if there is more output to be sucked, so that OnIdle, knows to suck it again.