C# Class IrcShark.Extensions.Terminal.TerminalExtension

Inheritance: IrcShark.Extensions.Extension
Show file Open project: hapm/IrcShark Class Usage Examples

Public Properties

Property Type Description
AutoCompleteList List

Public Methods

Method Description
ExecuteCommand ( CommandCall call ) : void

Executes the command with the given name.

ReadCommand ( ) : CommandCall

Reads a command from the Terminal.

ResetColor ( ) : void

Resets the foreground and background color of the terminal.

Start ( IrcShark context ) : void

Starts the TerminalExtension.

Stop ( ) : void

Stops the execution of the TerminalExtension.

TerminalExtension ( ) : System

Initializes a new instance of the TerminalExtension class.

TerminalLogger ( object sender, LogMessage msg ) : void

This is a replacement logger for the IrcSharkApplication.DefaultConsoleLogger.

The default loghandler is not compatible with the TerminalExtension and is replaced with this loghandler.

Write ( string format ) : void

Writes text to the terminal.

WriteLine ( ) : void

Writes a linebreak to the terminal.

WriteLine ( string line ) : void

Writes a complete line and appends a linebreak at the end.

Private Methods

Method Description
AddCommands ( ) : void

Adds all commands.

AutoComplete ( string text, int cursor ) : Completion

Autocompletes the word, the cursor is currently on.

Run ( ) : void

This method is used by the internal reading thread for reading a command from the terminal.

drawStartupLogo ( ) : void

Method Details

ExecuteCommand() public method

Executes the command with the given name.
public ExecuteCommand ( CommandCall call ) : void
call CommandCall The CommandCall to execute.
return void

ReadCommand() public method

Reads a command from the Terminal.
public ReadCommand ( ) : CommandCall
return CommandCall

ResetColor() public method

Resets the foreground and background color of the terminal.
public ResetColor ( ) : void
return void

Start() public method

Starts the TerminalExtension.
public Start ( IrcShark context ) : void
context IrcShark
return void

Stop() public method

Stops the execution of the TerminalExtension.
public Stop ( ) : void
return void

TerminalExtension() public method

Initializes a new instance of the TerminalExtension class.
public TerminalExtension ( ) : System
return System

TerminalLogger() public method

This is a replacement logger for the IrcSharkApplication.DefaultConsoleLogger.
The default loghandler is not compatible with the TerminalExtension and is replaced with this loghandler.
public TerminalLogger ( object sender, LogMessage msg ) : void
sender object The Logger what send the message.
msg IrcShark.LogMessage The Message.
return void

Write() public method

Writes text to the terminal.
public Write ( string format ) : void
format string
return void

WriteLine() public method

Writes a linebreak to the terminal.
public WriteLine ( ) : void
return void

WriteLine() public method

Writes a complete line and appends a linebreak at the end.
public WriteLine ( string line ) : void
line string The line to write.
return void

Property Details

AutoCompleteList public property

Saves a list of all commands added to the terminal.
public List AutoCompleteList
return List