#include <shellwin.h>

Inheritance diagram for ShellWin:
Collaboration diagram for ShellWin:

List of all members.

Public Member Functions

 ShellWin ()
virtual void initialize (void)
virtual bool execute (const CString &dir, const CString &script, CString **redstdout, CString **redstderr, uint timeout)
virtual CStringreadFile (const CString &fullPath)

Private Member Functions

bool createChildProcess (const CString &dir, const CString &script, const CString &tmpstdout, const CString &tmpstderr, uint timeout)

Detailed Description

ShellWin utility class to support the use of shell scripts in Windows TODO: check whether reading the pipe only after the execution may lead to problems if the pipe gets full. Easier solution may be to redirect stdout and stderr to file and read from file


Constructor & Destructor Documentation

ShellWin::ShellWin (  ) 

constructor


Member Function Documentation

bool ShellWin::createChildProcess ( const CString dir,
const CString script,
const CString tmpstdout,
const CString tmpstderr,
uint  timeout 
) [private]

ShellWin::createChildProcess create a child process to execute the script return false in case of timeout

Referenced by execute().

bool ShellWin::execute ( const CString dir,
const CString script,
CString **  redstdout,
CString **  redstderr,
uint  timeout 
) [virtual]

execute bash script named script in directory dir return stdout and stderr output of run in redstdout and redstderr return false in case of timeout, true otherwise

ShellWin::execute execute bash script named script in directory dir return stdout and stderr output of run in redstdout and redstderr return false in case of timeout, true otherwise

Implements Shell.

References createChildProcess(), ENVBUFSIZE, readFile(), and tempFileName().

Here is the call graph for this function:

void ShellWin::initialize ( void   )  [virtual]

ShellWin::initialize opportunity to do any necessary initialization

Reimplemented from Shell.

CString * ShellWin::readFile ( const CString fullPath  )  [virtual]

read a file into a string

ShellWin::readFile read a file into a string

Implements Shell.

References FILEBUFSIZE.

Referenced by execute().


The documentation for this class was generated from the following files: