The commander class takes care of commands. It also takes control of the drawer.
More...
The commander class takes care of commands. It also takes control of the drawer.
◆ Commander() [1/3]
| Advanced_Software_Engineering.Commander.Commander |
( |
Graphics |
graphics | ) |
|
Create a new Commander instance.
- Parameters
-
| graphics | initial graphics object |
◆ Commander() [2/3]
| Advanced_Software_Engineering.Commander.Commander |
( |
| ) |
|
Creates a new Commander instance without a context. Should only be used for testing purpouses.
◆ Commander() [3/3]
| Advanced_Software_Engineering.Commander.Commander |
( |
Graphics |
graphics, |
|
|
string |
rawCommands |
|
) |
| |
Creates a new Commander instance with a graphics context and commands to process right off the bat.
- Parameters
-
| graphics | Graphics contetx |
| rawCommands | Commands to process |
◆ AddCommand()
| void Advanced_Software_Engineering.Commander.AddCommand |
( |
IVerb |
command | ) |
|
Adds a IVerb to the command list to be executed.
- Parameters
-
◆ DrawAllCommands()
| void Advanced_Software_Engineering.Commander.DrawAllCommands |
( |
Graphics |
updateGraphicsElement | ) |
|
This command updates the graphics element (usually) when the page repaints.
- Parameters
-
| updateGraphicsElement | The graphics element to be updated |
◆ ExplainCommands()
| string Advanced_Software_Engineering.Commander.ExplainCommands |
( |
| ) |
|
Explains all of the commands in order
- Returns
- Explanation of all the commands
◆ GetLastStatus()
| bool Advanced_Software_Engineering.Commander.GetLastStatus |
( |
| ) |
|
Gets the status of the code that was processed
- Returns
- False if there was no error. True if there was an error
◆ ProcessCommands()
| void Advanced_Software_Engineering.Commander.ProcessCommands |
( |
string |
rawCommands, |
|
|
bool |
pardonCommands = false |
|
) |
| |
processes commands. Removes all commands if it fails parsing the raw commands.
- Parameters
-
| rawCommands | Processes commands seperated by
or \r
|
| pardonCommands | If the command is wrong, don't remove all of the commands |
◆ ProcessCommandsAndExecute()
| void Advanced_Software_Engineering.Commander.ProcessCommandsAndExecute |
( |
string |
rawCommands, |
|
|
bool |
pardonCommands = false |
|
) |
| |
Processes the commands and executes them at the same time. It's the same as
- Parameters
-
| rawCommands | Processes commands seperated by
or \r
|
| pardonCommands | If the command is wrong, don't remove all of the commands |
◆ RemoveAllCommands()
| void Advanced_Software_Engineering.Commander.RemoveAllCommands |
( |
| ) |
|
Removes all commands from the Commander and resets the drawer.
The documentation for this class was generated from the following file:
- Advanced Software Engineering/Commander.cs