C# Class POLLaunch.Console.MyConsole

Root Console Hook Class
Inheritance: System.Diagnostics.Process
Exibir arquivo Open project: polserver/poltools Class Usage Examples

Public Methods

Method Description
MyConsole ( ) : System

Default Constructor

Start ( string filename, string workingdir ) : void

Starts "filename" process at "workingdir" directory.

Start ( string filename, string workingdir, bool redirectinput ) : void

Starts "filename" process at "workingdir" directory with Standard Output Redirected.

Start ( string filename, string workingdir, string args ) : void

Starts "filename" process at "workingdir" directory using "args" arguments.

Start ( string filename, string workingdir, string args, bool redirectinput ) : void

Starts "filename" process at "workingdir" directory using "args" arguments.

Write ( char c ) : bool

Writes a char to the Input Stream for the Hooked Process.

Write ( char c, bool Ctrl, bool Shift, bool Alt ) : bool

Writes a char to the started processes InputStream.

Write ( string text ) : bool

Writes a string of text to the started processes InputStream.

Private Methods

Method Description
HookConsole ( ) : bool
MyConsole_Exited ( object sender, EventArgs e ) : void
MyConsole_OutputDataReceived ( object sender, DataReceivedEventArgs e ) : void

Method Details

MyConsole() public method

Default Constructor
public MyConsole ( ) : System
return System

Start() public method

Starts "filename" process at "workingdir" directory.
public Start ( string filename, string workingdir ) : void
filename string Full path to program
workingdir string Full path to working dir
return void

Start() public method

Starts "filename" process at "workingdir" directory with Standard Output Redirected.
public Start ( string filename, string workingdir, bool redirectinput ) : void
filename string Full path to program
workingdir string Full path to working dir
redirectinput bool Bool to use Stanard Input Redirect
return void

Start() public method

Starts "filename" process at "workingdir" directory using "args" arguments.
public Start ( string filename, string workingdir, string args ) : void
filename string Full path to program
workingdir string Full path to working dir
args string Arguments to send to the command line.
return void

Start() public method

Starts "filename" process at "workingdir" directory using "args" arguments.
public Start ( string filename, string workingdir, string args, bool redirectinput ) : void
filename string Full path to program
workingdir string Full path to working dir
args string Arguments to send to the command line
redirectinput bool To use the Standard Input Redirect
return void

Write() public method

Writes a char to the Input Stream for the Hooked Process.
public Write ( char c ) : bool
c char Character to send.
return bool

Write() public method

Writes a char to the started processes InputStream.
public Write ( char c, bool Ctrl, bool Shift, bool Alt ) : bool
c char
Ctrl bool
Shift bool
Alt bool
return bool

Write() public method

Writes a string of text to the started processes InputStream.
public Write ( string text ) : bool
text string Text to send to the Input Stream for the Process
return bool