Webmaster  |  Imprint 
C++ Server Pages
Main  |  License  |  Documentation  |  Download 

Process Class Reference

Process Environment.

#include <cxxtools/process.h>

Inheritance diagram for Process:

List of all members.

Public Types

enum  State {
  Ready = 0,
  Running = 1,
  Finished = 2,
  Failed = 3
}

Public Member Functions

 Process (const std::string &commandline)
 Constructs a Process with a command including its arguments.
 Process (const ProcessInfo &procInfo)
 Constructs a Process with a process info structure.
 ~Process ()
 Dtor.
const ProcessInfoprocInfo () const
State state () const
void start ()
 Start/Create the Process.
void kill ()
 Kills the Process.
int wait ()
 Waits until the Process ends.
IODevicestdInput ()
IODevicestdOutput ()
IODevicestdError ()

Static Public Member Functions

static void setEnvVar (const std::string &name, const std::string &value)
 Set environment variable.
static void unsetEnvVar (const std::string &name)
 Unset environment variable.
static std::string getEnvVar (const std::string &name)
 Get environment variable.
static void sleep (size_t milliSec)
 Called Process Sleeps milliSec Seconds.
static unsigned long usedMemory ()


Constructor & Destructor Documentation

Process ( const std::string &  commandline  )  [explicit]

Parameters:
command Name of the executable along with its arguments


Member Function Documentation

void start (  ) 

Exceptions:
SystemError 

void kill (  ) 

Exceptions:
SystemError 

int wait (  ) 

Exceptions:
SystemError 

static void setEnvVar ( const std::string &  name,
const std::string &  value 
) [static]

Exceptions:
SystemError 

static void unsetEnvVar ( const std::string &  name  )  [static]

Exceptions:
SystemError 

static std::string getEnvVar ( const std::string &  name  )  [static]

Exceptions:
SystemError 

static void sleep ( size_t  milliSec  )  [static]

Exceptions:
SystemError 

Copyright © 2008 The Tntnet Development Team
Tntnet 1.6