OpenASIP
2.0
|
#include <SimulatorCLI.hh>
Public Member Functions | |
SimulatorCLI ()=delete | |
SimulatorCLI (SimulatorFrontend &frontend) | |
virtual | ~SimulatorCLI () |
virtual void | run () |
virtual void | interpreteAndPrintResults (const TCEString &scriptString) |
SimulatorInterpreter & | interpreter () |
Protected Attributes | |
SimulatorFrontend & | simFront_ |
SimulatorInterpreterContext * | context_ |
LineReader * | reader_ |
SimulatorInterpreter * | interpreter_ |
SimulatorCmdLineOptions * | options_ |
RuntimeErrorReporter * | errorReporter_ |
Command Line Interface for controlling the simulation engine using the simulator control scripting language (tcl).
Definition at line 48 of file SimulatorCLI.hh.
|
delete |
SimulatorCLI::SimulatorCLI | ( | SimulatorFrontend & | frontend | ) |
simulatorInterpreter | Use the given interpreter instead of default one. Takes ownership of the object. |
Catch runtime errors and print them out to the simulator console.
Definition at line 121 of file SimulatorCLI.cc.
References Application::argc(), Application::argv(), assert, Application::cmdLineOptions(), context_, errorReporter_, LineReader::initialize(), interpreter_, SimulatorFrontend::isCompiledSimulation(), options_, reader_, LineReader::setInputHistoryLog(), SIM_COMMAND_PROMPT, SIM_DEFAULT_COMMAND_LOG, and simFront_.
|
virtual |
Definition at line 153 of file SimulatorCLI.cc.
References context_, errorReporter_, interpreter_, and reader_.
|
virtual |
Executes the given script string in the script interpreter and prints out possible results.
interpreter | Interpreter to use. |
scriptString | Script string to execute. |
Definition at line 176 of file SimulatorCLI.cc.
References TclInterpreter::interpret(), interpreter_, and ScriptInterpreter::result().
Referenced by main().
|
inline |
|
virtual |
Runs the interpreter loop.
Inputs a line of script from the user, processes it and prints out the results.
Definition at line 189 of file SimulatorCLI.cc.
References TclInterpreter::interpret(), interpreter_, SimulatorInterpreter::isQuitCommandGiven(), reader_, LineReader::readLine(), ScriptInterpreter::result(), SIM_INTERP_QUIT_COMMAND, and StringTools::trim().
Referenced by main().
|
protected |
Definition at line 61 of file SimulatorCLI.hh.
Referenced by SimulatorCLI(), and ~SimulatorCLI().
|
protected |
Definition at line 65 of file SimulatorCLI.hh.
Referenced by SimulatorCLI(), and ~SimulatorCLI().
|
protected |
Definition at line 63 of file SimulatorCLI.hh.
Referenced by interpreteAndPrintResults(), interpreter(), run(), SimulatorCLI(), TTASimulatorCLI::TTASimulatorCLI(), and ~SimulatorCLI().
|
protected |
Definition at line 64 of file SimulatorCLI.hh.
Referenced by SimulatorCLI().
|
protected |
Definition at line 62 of file SimulatorCLI.hh.
Referenced by run(), SimulatorCLI(), and ~SimulatorCLI().
|
protected |
Definition at line 60 of file SimulatorCLI.hh.
Referenced by SimulatorCLI().