NumeRe v1.1.4
NumeRe: Framework für Numerische Rechnungen
|
This class provides the interface to the core of NumeRe. It provides all functionalities, which was done by the main function before and handles the communication to the graphical user interface. More...
#include <kernel.hpp>
Public Member Functions | |
NumeReKernel () | |
Constructor of the kernel. More... | |
~NumeReKernel () | |
Destructor of the kernel. More... | |
void | showWindow (const NumeRe::Window &window) |
This member function passes a window object to the user interface, which will then converted into a real window. More... | |
NumeRe::Table | getTable (const std::string &sTableName) |
This member function creates the table container for the selected numerical table. More... | |
NumeRe::Container< std::string > | getStringTable (const std::string &sStringTableName) |
This member function creates the table container for the string table or the clusters. More... | |
void | refreshFunctionTree () |
This member function informs the GUI to reload the contents of the function tree as soon as possible. More... | |
void | closeWindows (int type) |
This member function informs the GUI to close all windows of the selected type. Use 0 or WT_ALL to close all closable windows at once. More... | |
KernelStatus | MainLoop (const std::string &sCommand) |
This is the main loop for the core of NumeRe. More... | |
FileSystem & | getFileSystem () |
MemoryManager & | getMemoryManager () |
NumeRe::Cluster & | getAns () |
void | setAns (NumeRe::Cluster *ans) |
mu::Parser & | getParser () |
NumeRe::StringParser & | getStringParser () |
FunctionDefinitionManager & | getDefinitions () |
Settings & | getSettings () |
PlotData & | getPlottingData () |
Output & | getOutput () |
Script & | getScript () |
Procedure & | getProcedureInterpreter () |
ProcedureLibrary & | getProcedureLibrary () |
NumeReDebugger & | getDebugger () |
NumeRe::WindowManager & | getWindowManager () |
void | displaySplash () |
This function displays the intro text. More... | |
std::map< std::string, std::string > | getPluginLanguageStrings () |
This member function returns a map of language strings for the installed plugins, which will be used by the global language object in the editor and the symbols browser. More... | |
std::map< std::string, std::string > | getFunctionLanguageStrings () |
This member function returns a map of language strings for the declared functions, which will be used by the global language object in the editor and the symbols browser. More... | |
std::vector< std::string > | getPluginCommands () |
This member function is used by the syntax highlighter to hightlight the plugin commands. More... | |
int | ReadOpenFileFlag () |
This member function returns the mode, how a file shall be opened in the editor, when called by the kernel-. More... | |
std::string | ReadAnswer () |
This member function is a simple wrapper to read the kernel answer and reset it automatically. More... | |
std::string | getDocumentation (const std::string &sCommand) |
This member function returns the documentation for the passed command string as HTML string prepared for the help browser. More... | |
std::vector< std::string > | getDocIndex () |
This member function returns the documentation index as a string vector, which can be used to fill the tree in the documentation browser. More... | |
NumeReVariables | getVariableList () |
This member function returns a structure containing all currently declared variables, which can be displayed in the variable viewer. More... | |
bool | SettingsModified () |
Returns true , if the user changed any internal settings using the set command. More... | |
int | getAutosaveInterval () const |
long long int | getLastSavedTime () const |
void | Autosave () |
Saves the allocated memories by the tables automatically. More... | |
void | StartUp (NumeReTerminal *_parent, const std::string &__sPath, const std::string &sPredefinedFunctions) |
This is the kernel "booting" function. More... | |
void | CloseSession () |
This member function shuts the kernel down and terminates the kernel instance. Every call to NumeReKernel::getInstance() after a call to this function will produce a segmentation fault. More... | |
void | CancelCalculation () |
void | saveData () |
This member function performs the autosaving of tables at application shutdown. More... | |
Settings | getKernelSettings () |
Get the settings available in the Settings class. More... | |
void | setKernelSettings (const Settings &_settings) |
Update the internal settings. More... | |
std::vector< std::string > | getPathSettings () const |
This member function returns a vector containing all currently declared paths in a distinct order. More... | |
const std::vector< Package > & | getInstalledPackages () const |
Returns a vector containing the names and the version info of each installed plugin. More... | |
std::map< std::string, std::string > | getMenuMap () const |
Returns the menu map used to construct the package menu. More... | |
void | initializeStackTracker () |
Starts the stack tracker, which will prevent stack overflows. More... | |
void | printVersionInfo () |
This member function prints the version headline and the version information to the console. More... | |
void | updateLineLenght (int nLength) |
This member function is used to update the internal terminal line length information after the terminal had been resized. More... | |
void | sendErrorNotification () |
This member function is used to toggle the error notification status. The error notification is used to style text as error messages. More... | |
Static Public Member Functions | |
static NumeReKernel * | getInstance () |
This static member function returns a a pointer to the singleton instance of the kernel. More... | |
static void | toggleTableStatus () |
Toggles the table writing status, which will reduce the number or events send to the terminal. More... | |
static void | flush () |
Inform the terminal to write the current output buffer as soon as possible. More... | |
static void | print (const std::string &__sLine, bool printingEnabled=true) |
This member function appends the passed string as a new output line to the buffer and informs the terminal that we have a new string to print. More... | |
static void | printPreFmt (const std::string &__sLine, bool printingEnabled=true) |
This member function appends the pre- formatted string to the buffer and informs the terminal that we have a new string to print. More... | |
static std::string | formatResultOutput (int nNum, mu::value_type *v) |
This static function is used to format the result output in the terminal for numerical-only results. More... | |
static std::string | formatResultOutput (const std::vector< std::string > &vStringResults) |
This static function is used to format the result output in the terminal for string and numerical results converted to a string vector. More... | |
static void | issueWarning (std::string sWarningMessage) |
This static function may be used to issue a warning to the user. The warning will be printed by the terminal in a separate colour. More... | |
static void | failMessage (std::string sFailMessage) |
This static function may be used to print a test failure message in the terminal. More... | |
static int | numberOfNumbersPerLine () |
This member function returns the count of numbers fitting into a single terminal line depending on its line length. More... | |
static void | progressBar (int nStep, int nFirstStep, int nFinalStep, const std::string &sType) |
This function displays a progress bar constructed from characters in the terminal. More... | |
static void | getline (std::string &sLine) |
This function is an implementation replacing the std::getline() function. More... | |
static void | gotoLine (const std::string &sFile, unsigned int nLine=0) |
This member function handles opening files and jumping to lines as requested by the kernel. More... | |
static void | setDocumentation (const std::string &_sDocumentation) |
This member function handles the display of a documentation window as requested by the kernel. More... | |
static void | installationDone () |
Notify the GUI that the installation was processed. More... | |
static bool | GetAsyncCancelState () |
This function is used by the kernel to get informed, when the user pressed ESC or used other means of aborting the current calculation process. More... | |
static void | showTable (NumeRe::Table _table, std::string __name, bool openeditable=false) |
This member function passes a table to the GUI to be displayed in the table viewer. It also allows to create a table editor window. More... | |
static void | showStringTable (NumeRe::Container< std::string > _stringtable, std::string __name, bool openeditable=false) |
This member function passes a string table to the GUI to be displayed in the table viewer. More... | |
static NumeRe::Table | getTable () |
This member function is used by the kernel to be notified when the user finished the table edit process and the table may be updated internally. More... | |
static void | showDebugEvent (const std::string &sTitle, const std::vector< std::string > &vStacktrace) |
This member function passes the debugging information to the GUI to be displayed in the debugger window. More... | |
static int | waitForContinue () |
This static function waits until the user sends a continuation command via the debugger and returns the corresponding debugger code. More... | |
static int | evalDebuggerBreakPoint (const std::string &sCurrentCommand="") |
This member function handles the creation of the debugger information for a script debugger breakpoint and returns the obtained debugger code. More... | |
static void | clcTerminal () |
Clear the terminal. More... | |
Static Public Attributes | |
static int * | baseStackPosition = nullptr |
static NumeReTerminal * | m_parent = nullptr |
static std::queue< NumeReTask > | taskQueue |
static int | nLINE_LENGTH = 80 |
static bool | bWritingTable = false |
static bool | bCancelSignal = false |
static int | nOpenFileFlag = 0 |
static int | nLastStatusVal = -1 |
static unsigned int | nLastLineLength = 0 |
static bool | modifiedSettings = false |
static NumeRe::Table | table |
static bool | bSupressAnswer = false |
static bool | bGettingLine = false |
static bool | bErrorNotification = false |
static ProcedureLibrary | ProcLibrary |
Private Member Functions | |
void | printResult (const std::string &sLine, bool bScriptRunning) |
This member function appends the formatted string to the buffer and informs the terminal that we have a new string to print. More... | |
std::string | maskProcedureSigns (std::string sLine) |
This member function masks the dollar signs in the strings to avoid that the line breaking functions uses them as aliases for line breaks. More... | |
bool | handleCommandLineSource (std::string &sLine, std::string &sKeep) |
This private member function will handle the command line input source and validate it, before the core will evaluate it. More... | |
bool | getLineFromCommandCache (std::string &sLine, const std::string &sCurrentCommand) |
This private member function returns the current command line from the command cache (i.e. the list of commands separated by semicolons). More... | |
bool | handleComposeBlock (std::string &sLine, const std::string &sCurrentCommand, KernelStatus &nReturnVal) |
This private member function will handle the compose block (i.e. store the different commands and return them, once the block is finished). More... | |
bool | handleProcedureWrite (const std::string &sLine, const std::string &sCurrentCommand, KernelStatus &nReturnVal) |
This private member function will handle the writing of procedure lines to the corresponding file. More... | |
bool | uninstallPlugin (const std::string &sLine, const std::string &sCurrentCommand) |
This private member function uninstalls a previously installed plugin. More... | |
void | handleToCmd (std::string &sLine, std::string &sCache, std::string &sCurrentCommand) |
This private member function handles the "to_cmd()" function, if it is part of the current command line. More... | |
bool | evaluateProcedureCalls (std::string &sLine) |
This private member function will evaluate any calls to procedurs and replace their results in the current command line. More... | |
bool | executePlugins (std::string &sLine) |
This private member function will execute any call to a plugin. More... | |
bool | handleFlowControls (std::string &sLine, const std::string &sCurrentCommand, KernelStatus &nReturnVal) |
This private member function will handle used flow controls. More... | |
bool | evaluateStrings (std::string &sLine, std::string &sCache, bool &bWriteToCache, KernelStatus &nReturnVal) |
This private member function redirects the processing of strings to the string parser. More... | |
void | createCalculationAnswer (int nNum, mu::value_type *v) |
This private member function will create the answer line for the parser which is then passed to NumeReKernel::printResult(). More... | |
void | resetAfterError () |
This private member function will reset the kernel variables after an error had been handled. More... | |
std::string | getGreeting () |
Returns a random greeting string, which may be printed to the terminal later. More... | |
void | checkInternalStates () |
Evaluates the internal states, performs necessary actions and resets them. More... | |
void | defineOperators () |
This member function declares all numerical operators. More... | |
void | defineConst () |
This member function declares all numerical constants. More... | |
void | defineFunctions () |
This member function declares all mathematical functions. More... | |
Private Attributes | |
std::string | sCommandLine |
std::string | sAnswer |
std::string | sPlotCompose |
std::queue< std::string > | commandQueue |
bool | refreshTree |
FileSystem | _fSys |
Settings | _option |
Output | _out |
MemoryManager | _memoryManager |
mu::Parser | _parser |
NumeRe::StringParser | _stringParser |
FunctionDefinitionManager | _functions |
PlotData | _pData |
Script | _script |
Procedure | _procedure |
NumeReDebugger | _debugger |
NumeRe::WindowManager | _manager |
NumeRe::Cluster * | _ans |
Static Private Attributes | |
static NumeReKernel * | kernelInstance = nullptr |
This class provides the interface to the core of NumeRe. It provides all functionalities, which was done by the main function before and handles the communication to the graphical user interface.
Definition at line 96 of file kernel.hpp.
Enumerator | |
---|---|
DEBUGGER_CONTINUE | |
DEBUGGER_STEP | |
DEBUGGER_STEPOVER | |
DEBUGGER_LEAVE |
Definition at line 129 of file kernel.hpp.
Definition at line 101 of file kernel.hpp.
NumeReKernel::NumeReKernel | ( | ) |
Constructor of the kernel.
Definition at line 67 of file kernel.cpp.
References _ans, kernelInstance, sAnswer, sCommandLine, and sPlotCompose.
NumeReKernel::~NumeReKernel | ( | ) |
Destructor of the kernel.
Definition at line 80 of file kernel.cpp.
References CloseSession(), and kernelInstance.
void NumeReKernel::Autosave | ( | ) |
Saves the allocated memories by the tables automatically.
Definition at line 121 of file kernel.cpp.
References _memoryManager, g_logger, MemoryManager::getSaveStatus(), DetachedLogger::info(), and MemoryManager::saveToCacheFile().
Referenced by NumeReTerminal::Entry().
|
inline |
Definition at line 357 of file kernel.hpp.
References bCancelSignal.
Referenced by NumeReTerminal::CancelCalculation().
|
private |
Evaluates the internal states, performs necessary actions and resets them.
Definition at line 2133 of file kernel.cpp.
References _lang, Language::addToLanguage(), getPluginLanguageStrings(), NumeReTerminal::m_kernelCS, NumeReTerminal::m_KernelStatus, m_parent, NUMERE_QUEUED_COMMAND, NUMERE_REFRESH_FUNCTIONTREE, refreshTree, taskQueue, and NumeReTask::taskType.
Referenced by evaluateStrings(), handleFlowControls(), and MainLoop().
|
static |
Clear the terminal.
Definition at line 3543 of file kernel.cpp.
References DetachedLogger::debug(), g_logger, KERNEL_PRINT_SLEEP, NumeReTerminal::m_kernelCS, NumeReTerminal::m_KernelStatus, m_parent, NUMERE_CLC_TERMINAL, NUMERE_QUEUED_COMMAND, taskQueue, and NumeReTask::taskType.
Referenced by cmd_clc().
void NumeReKernel::CloseSession | ( | ) |
This member function shuts the kernel down and terminates the kernel instance. Every call to NumeReKernel::getInstance() after a call to this function will produce a segmentation fault.
Definition at line 2210 of file kernel.cpp.
References _functions, _memoryManager, _option, _out, _pData, _script, Settings::controlDefinitions(), g_logger, FunctionDefinitionManager::getDefinedFunctions(), Settings::getExePath(), FileSystem::getPath(), Settings::getSetting(), DetachedLogger::info(), m_parent, MemoryManager::removeTablesFromMemory(), sAnswer, FunctionDefinitionManager::save(), Settings::save(), saveData(), sCommandLine, SETTING_S_LOADPATH, SETTING_S_PLOTPATH, SETTING_S_SAVEPATH, SETTING_S_SCRIPTPATH, and SettingsValue::stringval().
Referenced by NumeReTerminal::Entry(), and ~NumeReKernel().
void NumeReKernel::closeWindows | ( | int | type | ) |
This member function informs the GUI to close all windows of the selected type. Use 0 or WT_ALL to close all closable windows at once.
type | int |
Definition at line 3590 of file kernel.cpp.
References KERNEL_PRINT_SLEEP, NumeReTerminal::m_kernelCS, NumeReTerminal::m_KernelStatus, m_parent, NumeReTask::nLine, NUMERE_CLOSE_WINDOWS, NUMERE_QUEUED_COMMAND, taskQueue, and NumeReTask::taskType.
Referenced by cmd_close().
|
private |
This private member function will create the answer line for the parser which is then passed to NumeReKernel::printResult().
nNum | int |
v | value_type* |
Definition at line 2058 of file kernel.cpp.
References _script, bSupressAnswer, formatResultOutput(), getAns(), Script::isOpen(), Script::isValid(), printResult(), NumeRe::Cluster::setDoubleArray(), and vAns.
Referenced by MainLoop().
|
private |
This member function declares all numerical constants.
Definition at line 361 of file kernel.cpp.
References _parser, mu::ParserBase::DefineConst(), errorTypeToString(), TYPE_ASSERTIONERROR, TYPE_CUSTOMERROR, TYPE_MATHERROR, and TYPE_SYNTAXERROR.
Referenced by StartUp().
|
private |
This member function declares all mathematical functions.
Definition at line 425 of file kernel.cpp.
References _parser, mu::ParserBase::DefineFun(), parser_acsc(), parser_acsch(), parser_AiryA(), parser_AiryB(), parser_and(), parser_asec(), parser_asech(), parser_AssociatedLaguerrePolynomial(), parser_AssociatedLegendrePolynomial(), parser_beta(), parser_BetheWeizsaecker(), parser_Binom(), parser_clausen(), parser_clock(), parser_Cnt(), parser_compare(), parser_complex(), parser_conj(), parser_cot(), parser_csc(), parser_csch(), parser_date(), parser_digamma(), parser_dilogarithm(), parser_doubleFaculty(), parser_EllipticD(), parser_EllipticE(), parser_EllipticF(), parser_EllipticP(), parser_erf(), parser_erfc(), parser_Faculty(), parser_floor(), parser_gamma(), parser_gcd(), parser_gRandom(), parser_Heaviside(), parser_HermitePolynomial(), parser_Ignore(), parser_imag(), parser_imSphericalHarmonics(), parser_interval(), parser_IrregularCylBessel(), parser_is_string(), parser_isnan(), parser_ivl(), parser_LaguerrePolynomial(), parser_lcm(), parser_LegendrePolynomial(), parser_log_b(), parser_MaxPos(), parser_Med(), parser_MinPos(), parser_Norm(), parser_Num(), parser_numereversion(), parser_or(), parser_Pct(), parser_perlin(), parser_phi(), parser_polar2rect(), parser_polygamma(), parser_polynomial(), parser_product(), parser_Random(), parser_real(), parser_rect(), parser_rect2polar(), parser_RegularCylBessel(), parser_roof(), parser_round(), parser_sec(), parser_sech(), parser_SinusCardinalis(), parser_sleep(), parser_SphericalBessel(), parser_SphericalHarmonics(), parser_SphericalNeumann(), parser_Std(), parser_studentFactor(), parser_theta(), parser_time(), parser_toDegree(), parser_toRadian(), parser_weeknum(), parser_xor(), parser_Zernike(), and parser_zeta().
Referenced by StartUp().
|
private |
This member function declares all numerical operators.
Definition at line 303 of file kernel.cpp.
References _parser, mu::ParserBase::DefineInfixOprt(), mu::ParserBase::DefineOprt(), mu::ParserBase::DefinePostfixOprt(), mu::oaLEFT, parser_Angstroem(), parser_AstroUnit(), parser_Barn(), parser_BinAND(), parser_BinOR(), parser_Calorie(), parser_Celsius(), parser_Curie(), parser_doubleFaculty(), parser_ElectronVolt(), parser_Faculty(), parser_Fahrenheit(), parser_Fermi(), parser_Foot(), parser_Gauss(), parser_Giga(), parser_Ignore(), parser_imaginaryUnit(), parser_Inch(), parser_Kilo(), parser_kmh(), parser_Knoten(), parser_Lightyear(), parser_liter(), parser_Mega(), parser_Micro(), parser_Mile(), parser_Milli(), parser_Mod(), parser_mol(), parser_mph(), parser_Nano(), parser_Not(), parser_Parsec(), parser_Poise(), parser_PSI(), parser_Torr(), parser_XOR(), parser_Yard(), mu::prLOGIC, and mu::prMUL_DIV.
Referenced by StartUp().
void NumeReKernel::displaySplash | ( | ) |
This function displays the intro text.
Definition at line 2265 of file kernel.cpp.
References printPreFmt().
Referenced by cmd_credits(), and printVersionInfo().
|
static |
This member function handles the creation of the debugger information for a script debugger breakpoint and returns the obtained debugger code.
sCurrentCommand | const std::string& |
Definition at line 3475 of file kernel.cpp.
References _debugger, _parser, DEBUGGER_CONTINUE, NumeReDebugger::gatherInformations(), NumeRe::ClusterManager::getClusterMap(), getDebugger(), getInstance(), getMemoryManager(), getParser(), getScript(), getStringParser(), NumeRe::StringVarFactory::getStringVars(), MemoryManager::getTableMap(), mu::ParserBase::GetVar(), and NumeReDebugger::showBreakPoint().
Referenced by Procedure::evalDebuggerBreakPoint(), and MainLoop().
|
private |
This private member function will evaluate any calls to procedurs and replace their results in the current command line.
sLine | std::string& |
Definition at line 1702 of file kernel.cpp.
References _functions, _memoryManager, _option, _out, _parser, _pData, _procedure, _script, Procedure::execute(), findCommand(), FlowCtrl::getCurrentBlockDepth(), getMatchingParenthesis(), Procedure::getReturnType(), isInQuotes(), Procedure::mangleName(), Procedure::replaceReturnVal(), StripSpaces(), and toString().
Referenced by MainLoop().
|
private |
This private member function redirects the processing of strings to the string parser.
sLine | std::string& |
sCache | std::string& |
bWriteToCache | bool& |
nReturnVal | KernelStatus& |
Definition at line 2007 of file kernel.cpp.
References _lang, _memoryManager, _option, _procedure, _script, _stringParser, bCancelSignal, checkInternalStates(), commandQueue, NumeRe::StringParser::evalAndFormat(), Language::get(), PackageManager::getPluginNames(), Script::getScriptFileName(), Script::isOpen(), NumeRe::StringParser::isStringExpression(), Script::isValid(), LineBreak(), NUMERE_DONE_KEYWORD, print(), sCommandLine, MemoryManager::setPluginCommands(), NumeRe::StringParser::STRING_SUCCESS, and Script::wasLastCommand().
Referenced by MainLoop().
|
private |
This private member function will execute any call to a plugin.
sLine | std::string& |
Definition at line 1800 of file kernel.cpp.
References _functions, _memoryManager, _option, _out, _parser, _pData, _procedure, _script, MemoryManager::copyTable(), mu::ParserBase::CreateTempVectorVar(), Returnvalue::delayDelete, MemoryManager::deleteTable(), Settings::enableSystemPrints(), PackageManager::evalPluginCmd(), Procedure::execute(), MemoryManager::getCols(), FlowCtrl::getCurrentBlockDepth(), MemoryManager::getLines(), PackageManager::getPluginProcName(), PackageManager::getPluginVarList(), MemoryManager::isEmpty(), Returnvalue::isNumeric(), PackageManager::isPluginCmd(), Returnvalue::isString(), MemoryManager::isTable(), MemoryManager::renameTable(), mu::ParserBase::SetVectorVar(), Returnvalue::sReturnedTable, StripSpaces(), MemoryManager::swapTables(), Returnvalue::vNumVal, and Returnvalue::vStringVal.
Referenced by MainLoop().
|
static |
This static function may be used to print a test failure message in the terminal.
sFailMessage | std::string |
Definition at line 2865 of file kernel.cpp.
References KERNEL_PRINT_SLEEP, NumeReTerminal::m_kernelCS, NumeReTerminal::m_KernelStatus, m_parent, NumeReTerminal::m_sAnswer, NUMERE_ANSWER_READ, NUMERE_ISSUE_WARNING, NUMERE_STATUSBAR_UPDATE, and replaceAll().
Referenced by Procedure::catchExceptionForTest().
|
static |
Inform the terminal to write the current output buffer as soon as possible.
Definition at line 3684 of file kernel.cpp.
References m_parent.
Referenced by printVersionInfo(), progressBar(), and showMatrixResult().
|
static |
This static function is used to format the result output in the terminal for string and numerical results converted to a string vector.
vStringResults | const std::vector<std::string>& |
Definition at line 2781 of file kernel.cpp.
References _option, getInstance(), Settings::getPrecision(), getSettings(), numberOfNumbersPerLine(), strfill(), TERMINAL_FORMAT_FIELD_LENOFFSET, and truncString().
|
static |
This static function is used to format the result output in the terminal for numerical-only results.
nNum | int |
v | value_type* |
Definition at line 2730 of file kernel.cpp.
References _option, getInstance(), Settings::getPrecision(), getSettings(), numberOfNumbersPerLine(), strfill(), TERMINAL_FORMAT_FIELD_LENOFFSET, and toString().
Referenced by FlowCtrl::calc(), FlowCtrl::compile(), createCalculationAnswer(), NumeRe::StringParser::createTerminalOutput(), and Procedure::ProcCalc().
|
inline |
Definition at line 268 of file kernel.hpp.
References _ans, _memoryManager, and NumeRe::ClusterManager::getCluster().
Referenced by FlowCtrl::calc(), FlowCtrl::compile(), createCalculationAnswer(), NumeRe::StringParser::createStringOutput(), NumeRe::StringParser::eval(), FlowCtrl::evalRangeBasedHeader(), Procedure::ProcCalc(), NumeRe::StringParser::storeStringResults(), tableMethod_categorize(), tableMethod_counteq(), tableMethod_findCols(), tableMethod_index(), and tableMethod_rank().
|
static |
This function is used by the kernel to get informed, when the user pressed ESC or used other means of aborting the current calculation process.
Definition at line 3703 of file kernel.cpp.
References bCancelSignal.
Referenced by FlowCtrl::calc(), FlowCtrl::compile(), FlowCtrl::evalHeader(), FlowCtrl::evalRangeBasedHeader(), executeCommand(), Fitcontroller::fitctrl(), integrate(), integrate2d(), MainLoop(), Procedure::ProcCalc(), and Odesolver::solve().
|
inline |
Definition at line 346 of file kernel.hpp.
References _option, and Settings::getAutoSaveInterval().
Referenced by NumeReTerminal::Entry().
|
inline |
Definition at line 326 of file kernel.hpp.
References _debugger.
Referenced by NumeReTerminal::addBreakpoint(), FlowCtrl::calc(), Procedure::catchExceptionForTest(), ProcedureVarFactory::checkArgument(), ProcedureVarFactory::checkArgumentValue(), NumeReTerminal::clearBreakpoints(), cmd_set(), FlowCtrl::compile(), ProcedureVarFactory::createLocalClusters(), ProcedureVarFactory::createLocalInlineStrings(), ProcedureVarFactory::createLocalInlineVars(), ProcedureVarFactory::createLocalStrings(), ProcedureVarFactory::createLocalTables(), ProcedureVarFactory::createLocalVars(), ProcedureVarFactory::createProcedureArguments(), evalDebuggerBreakPoint(), Procedure::evalDebuggerBreakPoint(), FlowCtrl::evalHeader(), FlowCtrl::evalRangeBasedHeader(), ProcedureVarFactory::evaluateProcedureArguments(), Procedure::execute(), FlowCtrl::for_loop(), Procedure::getErrorInformationForDebugger(), DebugViewer::getInformationByStackId(), Procedure::getInlined(), FlowCtrl::if_fork(), FlowCtrl::range_based_for_loop(), NumeReTerminal::removeBreakpoint(), Procedure::resetProcedure(), FlowCtrl::switch_fork(), FlowCtrl::try_catch(), and FlowCtrl::while_loop().
|
inline |
Definition at line 291 of file kernel.hpp.
References _functions.
Referenced by calculateChiMap(), calculateSplines(), cmd_define(), cmd_execute(), cmd_fit(), cmd_ifndefined(), cmd_list(), cmd_load(), cmd_matop(), cmd_new(), cmd_odesolve(), cmd_plotting(), cmd_redefine(), cmd_save(), cmd_set(), cmd_undefine(), differentiate(), FlowCtrl::eval(), evaluateExpression(), evaluateFittingParams(), evaluateParameterValues(), findExtrema(), findZeroes(), CommandLineParser::getExprAsMathExpression(), ProcedureVarFactory::init(), parseArg(), CommandLineParser::parseExprAsNumericalValues(), CommandLineParser::parseExprAsString(), solveLGSSymbolic(), and taylor().
std::vector< std::string > NumeReKernel::getDocIndex | ( | ) |
This member function returns the documentation index as a string vector, which can be used to fill the tree in the documentation browser.
Definition at line 2383 of file kernel.cpp.
References _option, and Documentation::getDocIndex().
Referenced by NumeReTerminal::getDocIndex().
std::string NumeReKernel::getDocumentation | ( | const std::string & | sCommand | ) |
This member function returns the documentation for the passed command string as HTML string prepared for the help browser.
sCommand | const std::string& |
Definition at line 2368 of file kernel.cpp.
References _option, and doc_HelpAsHTML().
Referenced by NumeReTerminal::getDocumentation().
|
inline |
Definition at line 258 of file kernel.hpp.
References _fSys.
Referenced by cmd_pack(), cmd_unpack(), doc_ReplaceTokensForHTML(), FileSystem::initializeFromKernel(), is_dir(), is_file(), strfnc_getfileinfo(), strfnc_sha256(), and Archive::unpack().
std::map< std::string, std::string > NumeReKernel::getFunctionLanguageStrings | ( | ) |
This member function returns a map of language strings for the declared functions, which will be used by the global language object in the editor and the symbols browser.
Definition at line 2306 of file kernel.cpp.
References _functions, FunctionDefinitionManager::getComment(), FunctionDefinitionManager::getDefinedFunctions(), FunctionDefinitionManager::getFunctionSignature(), and toUpperCase().
Referenced by NumeReTerminal::getFunctionLanguageStrings().
|
private |
Returns a random greeting string, which may be printed to the terminal later.
Definition at line 2110 of file kernel.cpp.
References _option, NumeRe::DataBase::addData(), fileExists(), NumeRe::DataBase::getElement(), NumeRe::DataBase::randomRecord(), NumeRe::DataBase::size(), Settings::useCustomLangFiles(), and FileSystem::ValidFileName().
Referenced by printVersionInfo().
const std::vector< Package > & NumeReKernel::getInstalledPackages | ( | ) | const |
Returns a vector containing the names and the version info of each installed plugin.
Definition at line 2553 of file kernel.cpp.
References _procedure, and PackageManager::getPackages().
Referenced by NumeReTerminal::getInstalledPackages(), and Script::handleInstallInformation().
|
inlinestatic |
This static member function returns a a pointer to the singleton instance of the kernel.
Obtaining the pointer to the kernel allows getting references to the main class objects.
Definition at line 221 of file kernel.hpp.
References kernelInstance.
Referenced by analyzePulse(), append_data(), applyFitAlgorithm(), NumeRe::StringFuncHandler::applySpecialStringFuncs(), applySyntaxHighlighting(), NumeRe::StringFuncHandler::argumentParser(), boneDetection(), FlowCtrl::calc(), calculateChiMap(), calculatePercentageAvgAndCreateParserVariables(), calculateSplines(), FunctionDefinitionManager::call(), NumeRe::StringFuncHandler::callFunction(), NumeRe::StringFuncHandler::callFunctionParallel(), NumeRe::StringFuncHandler::callMultiFunction(), NumeRe::StringFuncHandler::callMultiFunctionParallel(), Procedure::catchExceptionForTest(), ProcedureVarFactory::checkArgument(), ProcedureVarFactory::checkArgumentValue(), Assertion::checkAssertion(), cmd_append(), cmd_audio(), cmd_audioread(), cmd_clear(), cmd_close(), cmd_copy(), cmd_credits(), cmd_datagrid(), cmd_define(), cmd_delete(), cmd_diff(), cmd_edit(), cmd_eval(), cmd_execute(), cmd_extrema(), cmd_find(), cmd_fit(), cmd_get(), cmd_help(), cmd_ifndefined(), cmd_install(), cmd_list(), cmd_load(), cmd_matop(), cmd_move(), cmd_new(), cmd_odesolve(), cmd_pack(), cmd_plotting(), cmd_print(), cmd_progress(), cmd_pulse(), cmd_quit(), cmd_read(), cmd_readline(), cmd_redefine(), cmd_regularize(), cmd_reload(), cmd_remove(), cmd_rename(), cmd_resample(), cmd_retouch(), cmd_save(), cmd_seek(), cmd_set(), cmd_show(), cmd_smooth(), cmd_spline(), cmd_start(), cmd_stats(), cmd_stfa(), cmd_swap(), cmd_taylor(), cmd_undefine(), cmd_unpack(), cmd_warn(), cmd_window(), cmd_workpath(), cmd_write(), cmd_zeroes(), FlowCtrl::compile(), Plot::constructDataLegendElement(), containsStringClusters(), ValueColumn::convert(), FunctionDefinition::convertToValues(), CopyData(), MemoryManager::copyTable(), Plot::create2dDrawing(), Plot::create2dPlot(), Plot::create3dDrawing(), createDatagrid(), Documentation::createDocumentationIndex(), createEveryDefinition(), createHist1D(), createHist2D(), DocumentationGenerator::createLaTeXFileName(), ProcedureVarFactory::createLocalClusters(), ProcedureVarFactory::createLocalInlineStrings(), ProcedureVarFactory::createLocalInlineVars(), ProcedureVarFactory::createLocalStrings(), ProcedureVarFactory::createLocalTables(), ProcedureVarFactory::createLocalVars(), createMafVectorName(), DocumentationGenerator::createMainProcedure(), createOutputForHist1D(), createOutputForHist2D(), createPlot(), createPlotForHist1D(), createPlotsForHist2D(), ProcedureVarFactory::createProcedureArguments(), Plot::createStd3dPlot(), Plot::createStdPlot(), NumeRe::StringParser::createStringOutput(), DocumentationGenerator::createStyleFile(), Plot::createSubPlotSet(), NumeRe::WindowManager::createWindow(), DataAccessParser::DataAccessParser(), PackageManager::declareNewPackage(), NumeReDebugger::decodeType(), FunctionDefinitionManager::defineFunc(), deleteCacheEntry(), PackageManager::deletePackage(), Dependencies::Dependencies(), dialogCommand(), differentiate(), doc_ReplaceTokensForHTML(), DocumentationGenerator::DocumentationGenerator(), editObject(), FlowCtrl::eval(), NumeRe::StringParser::eval(), evalDebuggerBreakPoint(), Procedure::evalDebuggerBreakPoint(), NumeRe::StringFuncHandler::evalFunction(), FlowCtrl::evalHeader(), DataAccessParser::evalIndices(), evalPoints(), FlowCtrl::evalRangeBasedHeader(), NumeRe::StringLogicParser::evalStringLogic(), NumeRe::StringLogicParser::evalStringTernary(), evaluateExpression(), evaluateFittingParams(), evaluateNumerical(), evaluateParameterValues(), ProcedureVarFactory::evaluateProcedureArguments(), NumeRe::StringVarFactory::evaluateStringVectors(), Procedure::execute(), CommandLineParser::exprContainsDataObjects(), extractFirstParameterStringValue(), extractRange(), fastFourierTransform(), fastWaveletTransform(), Plot::filename(), findExtrema(), findExtremaInData(), findExtremaInMultiResult(), findZeroes(), findZeroesInData(), findZeroesInMultiResult(), DocumentationGenerator::followBranch(), FlowCtrl::for_loop(), formatNumberToTex(), formatResultOutput(), NumeReDebugger::gatherLoopBasedInformations(), getArgAtPos(), StringVector::getBooleanVectorized(), getDataForFit(), getDataFromObject(), getDataGridDimensions(), Procedure::getErrorInformationForDebugger(), CommandLineParser::getExprAsDataObject(), CommandLineParser::getExprAsFileName(), CommandLineParser::getExprAsMathExpression(), CommandLineParser::getFileParameterValue(), getFittingParameters(), NumeReDebugger::getGlobals(), getIndices(), Procedure::getInlined(), Script::getNextScriptCommandFromScript(), StringVector::getNumericalVectorized(), getParametersFromWindow(), getParameterTable(), PlotData::getParams(), NumeRe::CallTipProvider::getProcedure(), getProcedureFileName(), Dependencies::getProcedureFileName(), getSamplesForDatagrid(), CommandLineParser::getTargetTable(), ValueColumn::getValueAsString(), getVarList(), getWindow(), Script::handleInstallInformation(), handleMafDataAccess(), handleToCmd(), FlowCtrl::if_fork(), Includer::Includer(), ProcedureVarFactory::init(), FileSystem::initializeFromKernel(), integrate(), integrate2d(), integrateSingleDimensionData(), integrationstep_simpson(), integrationstep_trapezoidal(), is_dir(), is_file(), isClusterCandidate(), listDeclaredVariables(), listInstalledPlugins(), moveData(), moveOrCopyFiles(), numberOfNumbersPerLine(), Archive::pack(), parseArg(), DocumentationGenerator::parseDocumentation(), parseEventOpt(), MemoryManager::parseEvery(), CommandLineParser::parseExprAsNumericalValues(), CommandLineParser::parseExprAsString(), parseLayoutScript(), particleSwarmOptimizer(), plotTableBySize(), plugin_histogram(), plugin_random(), plugin_statistics(), DocumentationGenerator::prepareFileNameForLaTeX(), prepareTemplate(), NumeRe::StringFuncHandler::printValue(), Procedure::ProcCalc(), FlowCtrl::range_based_for_loop(), readAudioFile(), readImage(), Interval::refresh(), refreshBoundaries(), refreshFunctionTree(), regularizeDataSet(), removeFile(), replaceDataEntities(), Procedure::replaceReturnVal(), PlotData::reset(), FlowCtrl::reset(), ProcedureVarFactory::reset(), Procedure::resetProcedure(), rotateTable(), saveDataObject(), seekInAudioFile(), setParametersInWindow(), PlotData::setParams(), CommandLineParser::setReturnValue(), StringColumn::setValue(), CategoricalColumn::setValue(), shortTimeFourierAnalysis(), showMatrix(), Odesolver::solve(), solveLGSSymbolic(), sortClusters(), sortData(), sortStrings(), NumeRe::StringParser::storeStringResults(), strfnc_getfileinfo(), strfnc_sha256(), swapTables(), FlowCtrl::switch_fork(), tableMethod_aliasof(), tableMethod_annotate(), tableMethod_anova(), tableMethod_binsof(), tableMethod_categories(), tableMethod_categorize(), tableMethod_convert(), tableMethod_counteq(), tableMethod_cov(), tableMethod_findCols(), tableMethod_index(), tableMethod_pcorr(), tableMethod_rank(), tableMethod_scorr(), tableMethod_typeof(), tableMethod_zscore(), taylor(), FlowCtrl::try_catch(), FunctionDefinitionManager::undefineFunc(), Archive::unpack(), FlowCtrl::updateTestStats(), FlowCtrl::while_loop(), windowCommand(), writeAudioFile(), Script::writeDocumentationArticle(), Script::writeProcedure(), and writeToFile().
Settings NumeReKernel::getKernelSettings | ( | ) |
Get the settings available in the Settings class.
Definition at line 94 of file kernel.cpp.
References _option.
Referenced by NumeReTerminal::getKernelSettings().
|
inline |
Definition at line 350 of file kernel.hpp.
References _memoryManager, and MemoryManager::getLastSaved().
Referenced by NumeReTerminal::Entry().
|
static |
This function is an implementation replacing the std::getline() function.
sLine | std::string& |
Definition at line 3621 of file kernel.cpp.
References bGettingLine, NumeReTerminal::m_bCommandAvailable, NumeReTerminal::m_kernelCS, m_parent, NumeReTerminal::m_sCommandLine, and StripSpaces().
Referenced by clear_cache(), cmd_readline(), cmd_set(), confirmOperation(), Output::format(), getPathForSetting(), Script::handleInstallInformation(), load_data(), MainLoop(), promptForUserInput(), and removeFile().
|
private |
This private member function returns the current command line from the command cache (i.e. the list of commands separated by semicolons).
sLine | std::string& |
sCurrentCommand | const std::string& |
Definition at line 1336 of file kernel.cpp.
References _procedure, bSupressAnswer, commandQueue, getAllSemiColonSeparatedTokens(), and Procedure::is_writing().
Referenced by MainLoop().
|
inline |
Definition at line 263 of file kernel.hpp.
References _memoryManager.
Referenced by append_data(), NumeRe::StringFuncHandler::applySpecialStringFuncs(), NumeRe::StringFuncHandler::argumentParser(), boneDetection(), calculateChiMap(), cmd_append(), cmd_clear(), cmd_define(), cmd_delete(), cmd_edit(), cmd_execute(), cmd_fit(), cmd_get(), cmd_list(), cmd_load(), cmd_matop(), cmd_new(), cmd_odesolve(), cmd_pack(), cmd_plotting(), cmd_quit(), cmd_reload(), cmd_remove(), cmd_rename(), cmd_resample(), cmd_retouch(), cmd_set(), cmd_show(), cmd_smooth(), cmd_stats(), containsStringClusters(), CopyData(), createDatagrid(), createHist1D(), createHist2D(), createMafVectorName(), DataAccessParser::DataAccessParser(), NumeReDebugger::decodeType(), deleteCacheEntry(), dialogCommand(), differentiate(), FlowCtrl::eval(), evalDebuggerBreakPoint(), DataAccessParser::evalIndices(), evalPoints(), evaluateExpression(), evaluateFittingParams(), evaluateNumerical(), evaluateParameterValues(), CommandLineParser::exprContainsDataObjects(), extractFirstParameterStringValue(), extractRange(), fastFourierTransform(), fastWaveletTransform(), findExtrema(), findZeroes(), NumeReDebugger::gatherLoopBasedInformations(), getDataForFit(), getDataFromObject(), getDataGridDimensions(), CommandLineParser::getExprAsMathExpression(), NumeReDebugger::getGlobals(), Procedure::getInlined(), getParametersFromWindow(), getSamplesForDatagrid(), CommandLineParser::getTargetTable(), ProcedureVarFactory::init(), integrate(), integrateSingleDimensionData(), isClusterCandidate(), moveData(), parseArg(), CommandLineParser::parseExprAsNumericalValues(), plugin_histogram(), plugin_random(), plugin_statistics(), readAudioFile(), readImage(), Interval::refresh(), regularizeDataSet(), Procedure::replaceReturnVal(), rotateTable(), saveDataObject(), seekInAudioFile(), setParametersInWindow(), shortTimeFourierAnalysis(), sortClusters(), sortData(), sortStrings(), tableMethod_aliasof(), tableMethod_annotate(), tableMethod_anova(), tableMethod_binsof(), tableMethod_categories(), tableMethod_categorize(), tableMethod_convert(), tableMethod_counteq(), tableMethod_cov(), tableMethod_findCols(), tableMethod_index(), tableMethod_pcorr(), tableMethod_rank(), tableMethod_scorr(), tableMethod_typeof(), tableMethod_zscore(), FlowCtrl::updateTestStats(), and writeAudioFile().
std::map< std::string, std::string > NumeReKernel::getMenuMap | ( | ) | const |
Returns the menu map used to construct the package menu.
Definition at line 2566 of file kernel.cpp.
References _procedure, and PackageManager::getMenuMap().
Referenced by NumeReTerminal::getMenuMap().
|
inline |
Definition at line 306 of file kernel.hpp.
References _out.
Referenced by cmd_quit(), cmd_set(), cmd_show(), createHist2D(), createOutputForHist1D(), createOutputForHist2D(), createPlotForHist1D(), createPlotsForHist2D(), FlowCtrl::eval(), ProcedureVarFactory::init(), plugin_histogram(), and plugin_statistics().
|
inline |
Definition at line 281 of file kernel.hpp.
References _parser.
Referenced by NumeRe::StringFuncHandler::applySpecialStringFuncs(), NumeRe::StringFuncHandler::argumentParser(), calculateChiMap(), calculatePercentageAvgAndCreateParserVariables(), Assertion::checkAssertion(), cmd_edit(), cmd_execute(), cmd_fit(), cmd_get(), cmd_list(), cmd_load(), cmd_matop(), cmd_new(), cmd_odesolve(), cmd_plotting(), cmd_reload(), cmd_set(), FunctionDefinition::convertToValues(), createDatagrid(), NumeRe::StringParser::createStringOutput(), DataAccessParser::DataAccessParser(), NumeReDebugger::decodeType(), deleteCacheEntry(), differentiate(), FlowCtrl::eval(), evalDebuggerBreakPoint(), evalPoints(), NumeRe::StringLogicParser::evalStringLogic(), NumeRe::StringLogicParser::evalStringTernary(), evaluateExpression(), evaluateFittingParams(), evaluateNumerical(), evaluateParameterValues(), NumeRe::StringVarFactory::evaluateStringVectors(), extractFirstParameterStringValue(), findExtrema(), findExtremaInData(), findExtremaInMultiResult(), findZeroes(), findZeroesInData(), findZeroesInMultiResult(), StringVector::getBooleanVectorized(), CommandLineParser::getExprAsMathExpression(), getFittingParameters(), NumeReDebugger::getGlobals(), Procedure::getInlined(), StringVector::getNumericalVectorized(), CommandLineParser::getTargetTable(), getWindow(), ProcedureVarFactory::init(), integrate(), integrate2d(), integrationstep_simpson(), integrationstep_trapezoidal(), parseArg(), MemoryManager::parseEvery(), CommandLineParser::parseExprAsNumericalValues(), particleSwarmOptimizer(), plugin_random(), Interval::refresh(), refreshBoundaries(), PlotData::setParams(), CommandLineParser::setReturnValue(), tableMethod_anova(), tableMethod_binsof(), tableMethod_categories(), tableMethod_categorize(), tableMethod_convert(), tableMethod_counteq(), tableMethod_cov(), tableMethod_findCols(), tableMethod_index(), tableMethod_pcorr(), tableMethod_rank(), tableMethod_scorr(), tableMethod_typeof(), tableMethod_zscore(), taylor(), and windowCommand().
std::vector< std::string > NumeReKernel::getPathSettings | ( | ) | const |
This member function returns a vector containing all currently declared paths in a distinct order.
Definition at line 2531 of file kernel.cpp.
References _option, Settings::getExePath(), Settings::getLoadPath(), Settings::getPlotPath(), Settings::getProcPath(), Settings::getSavePath(), Settings::getScriptPath(), and Settings::getWorkPath().
Referenced by DocumentationGenerator::createLaTeXFileName(), DocumentationGenerator::createMainProcedure(), NumeReTerminal::getPathSettings(), and DocumentationGenerator::prepareFileNameForLaTeX().
|
inline |
Definition at line 301 of file kernel.hpp.
References _pData.
Referenced by cmd_get(), cmd_plotting(), cmd_set(), createHist1D(), createHist2D(), createPlotForHist1D(), createPlotsForHist2D(), FlowCtrl::eval(), and ProcedureVarFactory::init().
std::vector< std::string > NumeReKernel::getPluginCommands | ( | ) |
This member function is used by the syntax highlighter to hightlight the plugin commands.
Definition at line 2329 of file kernel.cpp.
References _procedure, PackageManager::getPackageCount(), and PackageManager::getPluginCommand().
Referenced by applySyntaxHighlighting(), and NumeReTerminal::OnThreadUpdate().
std::map< std::string, std::string > NumeReKernel::getPluginLanguageStrings | ( | ) |
This member function returns a map of language strings for the installed plugins, which will be used by the global language object in the editor and the symbols browser.
Definition at line 2281 of file kernel.cpp.
References _procedure, PackageManager::getPackageCount(), PackageManager::getPackageDescription(), PackageManager::getPluginCommand(), PackageManager::getPluginCommandSignature(), replaceAll(), and toUpperCase().
Referenced by checkInternalStates(), NumeReTerminal::getPluginLanguageStrings(), and StartUp().
|
inline |
Definition at line 316 of file kernel.hpp.
References _procedure.
Referenced by getProcedureFileName(), Dependencies::getProcedureFileName(), Script::handleInstallInformation(), listInstalledPlugins(), NumeReTerminal::updatePackage(), Script::writeDocumentationArticle(), and Script::writeProcedure().
|
inline |
Definition at line 321 of file kernel.hpp.
References ProcLibrary.
Referenced by PackageDialog::followBranch(), DocumentationGenerator::followBranch(), NumeReWindow::OnCalculateDependencies(), and DocumentationGenerator::parseDocumentation().
|
inline |
Definition at line 311 of file kernel.hpp.
References _script.
Referenced by cmd_install(), cmd_set(), cmd_start(), FlowCtrl::eval(), evalDebuggerBreakPoint(), ProcedureVarFactory::init(), and parseLayoutScript().
|
inline |
Definition at line 296 of file kernel.hpp.
References _option.
Referenced by append_data(), applyFitAlgorithm(), NumeRe::StringFuncHandler::applySpecialStringFuncs(), NumeRe::StringFuncHandler::argumentParser(), calculateChiMap(), calculateSplines(), NumeRe::StringFuncHandler::callFunction(), NumeRe::StringFuncHandler::callFunctionParallel(), NumeRe::StringFuncHandler::callMultiFunction(), NumeRe::StringFuncHandler::callMultiFunctionParallel(), cmd_clear(), cmd_copy(), cmd_datagrid(), cmd_define(), cmd_delete(), cmd_edit(), cmd_execute(), cmd_extrema(), cmd_find(), cmd_fit(), cmd_get(), cmd_help(), cmd_ifndefined(), cmd_list(), cmd_load(), cmd_matop(), cmd_move(), cmd_new(), cmd_odesolve(), cmd_plotting(), cmd_quit(), cmd_read(), cmd_readline(), cmd_redefine(), cmd_regularize(), cmd_remove(), cmd_rename(), cmd_resample(), cmd_retouch(), cmd_save(), cmd_set(), cmd_show(), cmd_smooth(), cmd_spline(), cmd_undefine(), cmd_warn(), cmd_workpath(), cmd_zeroes(), FunctionDefinition::convertToValues(), Documentation::createDocumentationIndex(), createHist2D(), createOutputForHist1D(), createOutputForHist2D(), createPlotForHist1D(), createPlotsForHist2D(), DataAccessParser::DataAccessParser(), deleteCacheEntry(), Dependencies::Dependencies(), differentiate(), FlowCtrl::eval(), NumeRe::StringFuncHandler::evalFunction(), evaluateExpression(), evaluateFittingParams(), evaluateParameterValues(), extractFirstParameterStringValue(), fastFourierTransform(), fastWaveletTransform(), findExtrema(), findZeroes(), formatNumberToTex(), formatResultOutput(), CommandLineParser::getExprAsMathExpression(), getParameterTable(), PlotData::getParams(), NumeRe::CallTipProvider::getProcedure(), CommandLineParser::getTargetTable(), Script::handleInstallInformation(), ProcedureVarFactory::init(), integrate(), integrate2d(), numberOfNumbersPerLine(), Archive::pack(), parseArg(), parseEventOpt(), CommandLineParser::parseExprAsNumericalValues(), plugin_random(), plugin_statistics(), prepareTemplate(), Interval::refresh(), removeFile(), PlotData::reset(), saveDataObject(), solveLGSSymbolic(), tableMethod_anova(), tableMethod_binsof(), tableMethod_counteq(), tableMethod_cov(), tableMethod_index(), tableMethod_pcorr(), tableMethod_rank(), tableMethod_scorr(), tableMethod_zscore(), taylor(), and Script::writeDocumentationArticle().
|
inline |
Definition at line 286 of file kernel.hpp.
References _stringParser.
Referenced by FlowCtrl::calc(), cmd_define(), cmd_ifndefined(), cmd_install(), cmd_pack(), cmd_print(), cmd_redefine(), cmd_set(), cmd_stats(), FlowCtrl::compile(), Plot::create2dDrawing(), Plot::create2dPlot(), Plot::create3dDrawing(), ProcedureVarFactory::createLocalClusters(), ProcedureVarFactory::createLocalInlineStrings(), ProcedureVarFactory::createLocalInlineVars(), ProcedureVarFactory::createLocalStrings(), ProcedureVarFactory::createLocalTables(), ProcedureVarFactory::createLocalVars(), Plot::createStd3dPlot(), Plot::createStdPlot(), Plot::createSubPlotSet(), NumeReDebugger::decodeType(), dialogCommand(), evalDebuggerBreakPoint(), FlowCtrl::evalHeader(), FlowCtrl::evalRangeBasedHeader(), evaluateExpression(), evaluateFittingParams(), evaluateParameterValues(), ProcedureVarFactory::evaluateProcedureArguments(), Procedure::execute(), extractFirstParameterStringValue(), Plot::filename(), findExtrema(), findZeroes(), NumeReDebugger::gatherLoopBasedInformations(), getArgAtPos(), CommandLineParser::getExprAsFileName(), CommandLineParser::getFileParameterValue(), NumeReDebugger::getGlobals(), getIndices(), getVarList(), handleMafDataAccess(), handleToCmd(), listDeclaredVariables(), moveOrCopyFiles(), parseArg(), CommandLineParser::parseExprAsNumericalValues(), CommandLineParser::parseExprAsString(), plotTableBySize(), Procedure::ProcCalc(), FlowCtrl::range_based_for_loop(), replaceDataEntities(), Procedure::replaceReturnVal(), FlowCtrl::reset(), ProcedureVarFactory::reset(), saveDataObject(), CommandLineParser::setReturnValue(), tableMethod_aliasof(), tableMethod_annotate(), tableMethod_categorize(), tableMethod_convert(), tableMethod_counteq(), tableMethod_findCols(), tableMethod_index(), tableMethod_rank(), windowCommand(), and writeToFile().
NumeRe::Container< std::string > NumeReKernel::getStringTable | ( | const std::string & | sStringTableName | ) |
This member function creates the table container for the string table or the clusters.
sStringTableName | const std::string& |
Definition at line 3357 of file kernel.cpp.
References _memoryManager, NumeRe::ClusterManager::getCluster(), NumeRe::Cluster::getDouble(), NumeRe::Cluster::getString(), StringMemory::getStringCols(), StringMemory::getStringElements(), NumeRe::Cluster::getType(), NumeRe::ClusterManager::isCluster(), mu::isnan(), NumeRe::ClusterItem::ITEMTYPE_STRING, StringMemory::readString(), NumeRe::Container< T >::set(), NumeRe::Cluster::size(), and toString().
Referenced by NumeReTerminal::getStringTable().
|
static |
This member function is used by the kernel to be notified when the user finished the table edit process and the table may be updated internally.
Definition at line 3299 of file kernel.cpp.
References NumeReTerminal::m_bTableEditAvailable, NumeReTerminal::m_bTableEditCanceled, NumeReTerminal::m_kernelCS, m_parent, and table.
Referenced by editObject(), and NumeReTerminal::getTable().
NumeRe::Table NumeReKernel::getTable | ( | const std::string & | sTableName | ) |
This member function creates the table container for the selected numerical table.
sTableName | const std::string& |
Definition at line 3335 of file kernel.cpp.
References _memoryManager, MemoryManager::extractTable(), MemoryManager::getCols(), and MemoryManager::isTable().
NumeReVariables NumeReKernel::getVariableList | ( | ) |
This member function returns a structure containing all currently declared variables, which can be displayed in the variable viewer.
Definition at line 2421 of file kernel.cpp.
References _memoryManager, _parser, _stringParser, DEFAULT_MINMAX_PRECISION, DEFAULT_NUM_PRECISION, ellipsize(), formatByteSize(), MemoryManager::getBytes(), NumeRe::ClusterManager::getClusterMap(), MemoryManager::getCols(), MemoryManager::getLines(), StringMemory::getStringCols(), StringMemory::getStringElements(), StringMemory::getStringSize(), NumeRe::StringVarFactory::getStringVars(), MemoryManager::getTableMap(), mu::ParserBase::GetVar(), mu::isnan(), MemoryManager::max(), StringMemory::maxString(), MAXSTRINGLENGTH, MemoryManager::min(), StringMemory::minString(), NumeReVariables::nClusters, NumeReVariables::nNumerics, NumeReVariables::nStrings, NumeReVariables::nTables, replaceControlCharacters(), toExternalString(), toString(), and NumeReVariables::vVariables.
Referenced by NumeReTerminal::getVariableList().
|
inline |
Definition at line 331 of file kernel.hpp.
References _manager.
Referenced by createPlot(), createPlotForHist1D(), createPlotsForHist2D(), dialogCommand(), getWindow(), and windowCommand().
|
static |
This member function handles opening files and jumping to lines as requested by the kernel.
sFile | const std::string& |
nLine | unsigned int |
Definition at line 3098 of file kernel.cpp.
References NumeReTerminal::m_kernelCS, NumeReTerminal::m_KernelStatus, m_parent, NumeReTask::nLine, NUMERE_EDIT_FILE, NUMERE_QUEUED_COMMAND, NumeReTask::sString, taskQueue, and NumeReTask::taskType.
Referenced by editObject(), NumeReDebugger::select(), and NumeReDebugger::showEvent().
|
private |
This private member function will handle the command line input source and validate it, before the core will evaluate it.
sLine | std::string& |
sKeep | std::string& |
Definition at line 1261 of file kernel.cpp.
References _script, commandQueue, findCommand(), Script::getNextScriptCommand(), Script::isOpen(), Script::isValid(), StripSpaces(), SyntaxError::UNMATCHED_PARENTHESIS, and validateParenthesisNumber().
Referenced by MainLoop().
|
private |
This private member function will handle the compose block (i.e. store the different commands and return them, once the block is finished).
sLine | std::string& |
sCurrentCommand | const std::string& |
nReturnVal | KernelStatus& |
Definition at line 1404 of file kernel.cpp.
References _lang, _option, _procedure, _script, commandQueue, findCommand(), findParameter(), Language::get(), getArgAtPos(), FlowCtrl::getCurrentBlock(), FlowCtrl::getCurrentBlockDepth(), Procedure::is_writing(), Script::isOpen(), Script::isValid(), LineBreak(), NUMERE_PENDING_SPECIAL, print(), printPreFmt(), sPlotCompose, Match::sString, and strfill().
Referenced by MainLoop().
|
private |
This private member function will handle used flow controls.
sLine | std::string& |
sCurrentCommand | const std::string& |
nReturnVal | KernelStatus& |
Definition at line 1891 of file kernel.cpp.
References _lang, _memoryManager, _option, _procedure, _script, bCancelSignal, bSupressAnswer, checkInternalStates(), commandQueue, Language::get(), FlowCtrl::getCurrentBlock(), FlowCtrl::getCurrentBlockDepth(), Script::getCurrentLine(), PackageManager::getPluginNames(), FlowCtrl::getReturnSignal(), Script::getScriptFileName(), Procedure::is_writing(), FlowCtrl::isFlowCtrlStatement(), Script::isOpen(), Script::isValid(), LineBreak(), NUMERE_DONE_KEYWORD, NUMERE_PENDING_SPECIAL, print(), printPreFmt(), Script::returnCommand(), FlowCtrl::setCommand(), MemoryManager::setPluginCommands(), sPlotCompose, strfill(), toggleTableStatus(), and Script::wasLastCommand().
Referenced by MainLoop().
|
private |
This private member function will handle the writing of procedure lines to the corresponding file.
sLine | const std::string& |
sCurrentCommand | const std::string& |
nReturnVal | KernelStatus& |
Definition at line 1550 of file kernel.cpp.
References _lang, _option, _procedure, _script, commandQueue, Language::get(), FlowCtrl::getCurrentBlock(), FlowCtrl::getCurrentBlockDepth(), Procedure::is_writing(), Script::isOpen(), Script::isValid(), LineBreak(), NUMERE_PENDING_SPECIAL, print(), printPreFmt(), sPlotCompose, strfill(), and Procedure::writeProcedure().
Referenced by MainLoop().
|
private |
This private member function handles the "to_cmd()" function, if it is part of the current command line.
sLine | std::string& |
sCache | std::string& |
sCurrentCommand | std::string& |
Definition at line 1657 of file kernel.cpp.
References _procedure, _stringParser, NumeRe::StringParser::evalAndFormat(), findCommand(), FlowCtrl::getCurrentBlockDepth(), getInstance(), getMatchingParenthesis(), getStringParser(), isInQuotes(), NumeRe::StringParser::isStringExpression(), Match::sString, StripSpaces(), and SyntaxError::UNMATCHED_PARENTHESIS.
Referenced by MainLoop().
void NumeReKernel::initializeStackTracker | ( | ) |
Starts the stack tracker, which will prevent stack overflows.
Definition at line 546 of file kernel.cpp.
References baseStackPosition, DetachedLogger::debug(), g_logger, and toHexString().
Referenced by NumeReTerminal::Entry().
|
static |
Notify the GUI that the installation was processed.
Definition at line 3159 of file kernel.cpp.
References NumeReTerminal::m_kernelCS, NumeReTerminal::m_KernelStatus, m_parent, NUMERE_INSTALLATION_DONE, NUMERE_QUEUED_COMMAND, taskQueue, and NumeReTask::taskType.
Referenced by Script::close(), Script::getNextScriptCommandFromScript(), Script::returnCommand(), and uninstallPlugin().
|
static |
This static function may be used to issue a warning to the user. The warning will be printed by the terminal in a separate colour.
sWarningMessage | std::string |
Definition at line 2833 of file kernel.cpp.
References _lang, g_logger, Language::get(), KERNEL_PRINT_SLEEP, NumeReTerminal::m_kernelCS, NumeReTerminal::m_KernelStatus, m_parent, NumeReTerminal::m_sAnswer, NUMERE_ANSWER_READ, NUMERE_ISSUE_WARNING, NUMERE_STATUSBAR_UPDATE, replaceAll(), and DetachedLogger::warning().
Referenced by calculateChiMap(), calculateSplines(), FileSystem::cleanPath(), cmd_define(), cmd_ifndefined(), cmd_redefine(), cmd_retouch(), cmd_warn(), differentiate(), ProcedureVarFactory::evaluateProcedureArguments(), fitDataSet(), Memory::importTable(), Includer::openIncludedFile(), NumeRe::NumeReDataFile::readHeader(), NumeRe::JcampDX::readTable(), rotateTable(), solveLGSSymbolic(), strfnc_getkeyval(), taylor(), and undefineFunctions().
NumeReKernel::KernelStatus NumeReKernel::MainLoop | ( | const std::string & | sCommand | ) |
This is the main loop for the core of NumeRe.
sCommand | const std::string& |
This function is called by the terminal to process the desired operations using the core of this application. It features an inner loop, which will process a whole script or a semicolon-separated list of commands automatically.
Definition at line 600 of file kernel.cpp.
References _assertionHandler, _functions, _lang, _memoryManager, _option, _parser, _procedure, _script, _stringParser, NumeRe::Cluster::assignResults(), bCancelSignal, bSupressAnswer, FunctionDefinitionManager::call(), Assertion::checkAssertion(), checkInternalStates(), mu::ParserBase::ClearVectorVars(), Script::close(), DetachedLogger::cmdline(), Indices::col, COMMAND_HAS_RETURNVALUE, COMMAND_PROCESSED, commandHandler(), commandQueue, MemoryManager::containsTablesOrClusters(), createCalculationAnswer(), DEBUGGER_LEAVE, DEBUGGER_STEP, Assertion::enable(), Settings::enableSystemPrints(), DetachedLogger::error(), mu::ParserBase::Eval(), evalDebuggerBreakPoint(), evalRecursiveExpressions(), evaluateProcedureCalls(), evaluateStrings(), executePlugins(), findCommand(), SyntaxError::FUNCTION_ERROR, g_logger, Language::get(), GetAsyncCancelState(), NumeRe::ClusterManager::getCluster(), FlowCtrl::getCurrentBlockDepth(), Script::getCurrentLine(), getDataElements(), Procedure::getDebuggerCode(), mu::ParserError::GetExpr(), getIndices(), Language::getKey(), getline(), getLineFromCommandCache(), mu::ParserError::GetMsg(), FileSystem::getPath(), PackageManager::getPluginNames(), mu::ParserError::GetPos(), Settings::getProcPath(), FileSystem::getProgramPath(), MemoryManager::getSaveStatus(), Script::getScriptFileName(), Settings::getSetting(), mu::ParserError::GetToken(), handleCommandLineSource(), handleComposeBlock(), handleFlowControls(), handleProcedureWrite(), handleToCmd(), SyntaxError::INVALID_INDEX, SyntaxError::invalid_position, Procedure::is_writing(), mu::ParserBase::IsAlreadyParsed(), isClusterCandidate(), FlowCtrl::isFlowCtrlStatement(), Script::isOpen(), VectorIndex::isOpenEnd(), NumeRe::StringParser::isStringExpression(), Script::isValid(), isValidIndexSet(), LineBreak(), SyntaxError::LOOP_THROW, m_parent, make_hline(), maskProcedureSigns(), mu::ParserBase::mVarMapPntr, nLastLineLength, nLastStatusVal, NO_COMMAND, SyntaxError::NO_MATRIX, NUMERE_DONE, NUMERE_DONE_KEYWORD, NUMERE_ERROR, NUMERE_PENDING, NUMERE_QUIT, pointToError(), print(), printPreFmt(), SyntaxError::PROCEDURE_THROW, SyntaxError::PROCESS_ABORTED_BY_USER, promptForUserInput(), refreshTree, MemoryManager::removeTablesFromMemory(), NumeRe::ClusterManager::removeTemporaryClusters(), NumeRe::StringVarFactory::removeTempStringVectorVars(), Assertion::reset(), resetAfterError(), Assertion::resetStats(), Indices::row, MemoryManager::saveToCacheFile(), sCommandLine, sendErrorNotification(), mu::ParserBase::SetExpr(), FileSystem::setPath(), MemoryManager::setPluginCommands(), SETTING_S_PROCPATH, Match::sString, SettingsValue::stringval(), StripSpaces(), sVersion, VectorIndex::to_string(), toString(), toSystemCodePage(), toUpperCase(), uninstallPlugin(), Settings::useDebugger(), Settings::useEscInScripts(), DetachedLogger::warning(), Script::wasLastCommand(), MemoryManager::writeToTable(), and Language::YES().
Referenced by NumeReTerminal::Entry().
|
private |
This member function masks the dollar signs in the strings to avoid that the line breaking functions uses them as aliases for line breaks.
sLine | std::string |
Definition at line 2613 of file kernel.cpp.
Referenced by MainLoop().
|
static |
This member function returns the count of numbers fitting into a single terminal line depending on its line length.
Definition at line 2897 of file kernel.cpp.
References getInstance(), Settings::getPrecision(), getSettings(), getWindow(), and TERMINAL_FORMAT_FIELD_LENOFFSET.
Referenced by formatResultOutput().
|
static |
This member function appends the passed string as a new output line to the buffer and informs the terminal that we have a new string to print.
__sLine | const std::string& |
printingEnabled | bool |
Definition at line 2636 of file kernel.cpp.
References bErrorNotification, bWritingTable, KERNEL_PRINT_SLEEP, NumeReTerminal::m_kernelCS, NumeReTerminal::m_KernelStatus, m_parent, NumeReTerminal::m_sAnswer, NUMERE_ANSWER_READ, NUMERE_PRINTLINE, and NUMERE_STATUSBAR_UPDATE.
Referenced by mu::ParserBase::ActivateLoopMode(), MemoryManager::addTable(), analyzePulse(), append_data(), mu::ParserByteCode::AsciiDump(), boneDetection(), FlowCtrl::calc(), calculateChiMap(), calculateSplines(), clear_cache(), cmd_audio(), cmd_audioread(), cmd_clear(), cmd_copy(), cmd_credits(), cmd_datagrid(), cmd_define(), cmd_delete(), cmd_find(), cmd_get(), cmd_ifndefined(), cmd_load(), cmd_move(), cmd_plotting(), cmd_redefine(), cmd_regularize(), cmd_remove(), cmd_rename(), cmd_resample(), cmd_retouch(), cmd_seek(), cmd_set(), cmd_smooth(), cmd_stfa(), cmd_workpath(), FlowCtrl::compile(), confirmOperation(), createOutputForHist1D(), createOutputForHist2D(), mu::ParserBase::CreateRPN(), createStatsOutput(), mu::ParserBase::DeactivateLoopMode(), doc_Help(), doc_SearchFct(), mu::ParserBase::Eval(), Script::evaluateInstallInformation(), evaluateStrings(), fitDataSet(), Output::format(), mu::ParserBase::GetExpr(), Script::getNextScriptCommandFromScript(), getPathForSetting(), handleComposeBlock(), handleFlowControls(), Script::handleInstallInformation(), handleProcedureWrite(), listCommands(), listConstants(), listDeclaredVariables(), listDefinitions(), listFiles(), listFunctions(), listInstalledPlugins(), listLogicalOperators(), listUnitConversions(), FunctionDefinitionManager::load(), load_data(), MainLoop(), make_stringmatrix(), newObject(), mu::ParserBase::PauseLoopMode(), plugin_random(), printVersionInfo(), Procedure::ProcCalc(), removeFile(), resetAfterError(), Script::returnCommand(), rotateTable(), Settings::save(), saveData(), saveDataObject(), FlowCtrl::setCommand(), show_data(), showMatrixResult(), solveLGS(), solveLGSSymbolic(), mu::ParserBase::StackDump(), Timer::Stop(), swapTables(), taylor(), undefineFunctions(), uninstallPlugin(), and Script::writeProcedure().
|
static |
This member function appends the pre- formatted string to the buffer and informs the terminal that we have a new string to print.
__sLine | const std::string& |
printingEnabled | bool |
Definition at line 2683 of file kernel.cpp.
References bErrorNotification, bWritingTable, KERNEL_PRINT_SLEEP, NumeReTerminal::m_kernelCS, NumeReTerminal::m_KernelStatus, m_parent, NumeReTerminal::m_sAnswer, NUMERE_ANSWER_READ, NUMERE_PRINTLINE_PREFMT, and NUMERE_STATUSBAR_UPDATE.
Referenced by analyzePulse(), applyFitAlgorithm(), mu::ParserByteCode::AsciiDump(), autoSave(), FlowCtrl::calc(), calculateChiMap(), clear_cache(), cmd_append(), cmd_credits(), cmd_readline(), cmd_set(), FlowCtrl::compile(), confirmOperation(), createPlotForHist1D(), Plot::createPlotOrAnimation(), createPlotsForHist2D(), Plot::createSubPlotSet(), createTeXExport(), Plot::displayMessage(), displaySplash(), doc_SearchFct(), editObject(), NumeReTerminal::Entry(), FlowCtrl::eval(), NumeRe::StringParser::evalAndFormat(), FlowCtrl::evalForkFlowCommands(), FlowCtrl::evalHeader(), FlowCtrl::evalRangeBasedHeader(), executeCommand(), fastFourierTransform(), fastWaveletTransform(), fitDataSet(), FlowCtrl::for_loop(), Output::format(), getPathForSetting(), handleComposeBlock(), handleFlowControls(), Script::handleInstallInformation(), handleProcedureWrite(), integrate(), integrate2d(), listCommands(), listConstants(), listDeclaredVariables(), listDefinitions(), listDirectory(), listFiles(), listFunctions(), listLogicalOperators(), listUnitConversions(), FunctionDefinitionManager::load(), Settings::load(), load_data(), MainLoop(), make_hline(), Plot::Plot(), plotTableBySize(), Output::print(), printUnits(), printVersionInfo(), progressBar(), promptForUserInput(), FlowCtrl::range_based_for_loop(), removeFile(), FunctionDefinitionManager::save(), showMatrixResult(), Odesolver::solve(), mu::ParserBase::StackDump(), and FlowCtrl::while_loop().
|
private |
This member function appends the formatted string to the buffer and informs the terminal that we have a new string to print.
sLine | const std::string& |
bScriptRunning | bool |
Definition at line 2582 of file kernel.cpp.
References bSupressAnswer, NumeReTerminal::m_kernelCS, NumeReTerminal::m_KernelStatus, m_parent, NumeReTerminal::m_sAnswer, NUMERE_ANSWER_READ, NUMERE_CALC_UPDATE, and NUMERE_STATUSBAR_UPDATE.
Referenced by createCalculationAnswer().
void NumeReKernel::printVersionInfo | ( | ) |
This member function prints the version headline and the version information to the console.
Definition at line 563 of file kernel.cpp.
References _lang, _option, bWritingTable, AutoVersion::DATE, displaySplash(), fileExists(), flush(), Language::get(), Settings::getExePath(), getGreeting(), LineBreak(), make_hline(), AutoVersion::MONTH, print(), printPreFmt(), Settings::showGreeting(), strfill(), sVersion, toSystemCodePage(), and AutoVersion::YEAR.
Referenced by NumeReTerminal::clearTerminal(), and NumeReTerminal::Entry().
|
static |
This function displays a progress bar constructed from characters in the terminal.
nStep | int |
nFirstStep | int |
nFinalStep | int |
sType | const std::string& |
Definition at line 2950 of file kernel.cpp.
References _lang, date::abs(), drawBar(), flush(), Language::get(), intCast(), nLastLineLength, nLastStatusVal, printPreFmt(), strfill(), toggleTableStatus(), and toString().
Referenced by make_progressBar().
std::string NumeReKernel::ReadAnswer | ( | ) |
This member function is a simple wrapper to read the kernel answer and reset it automatically.
Definition at line 2251 of file kernel.cpp.
References sAnswer.
int NumeReKernel::ReadOpenFileFlag | ( | ) |
This member function returns the mode, how a file shall be opened in the editor, when called by the kernel-.
Definition at line 2351 of file kernel.cpp.
References nOpenFileFlag.
Referenced by NumeReTerminal::OnThreadUpdate().
void NumeReKernel::refreshFunctionTree | ( | ) |
This member function informs the GUI to reload the contents of the function tree as soon as possible.
Definition at line 3573 of file kernel.cpp.
References DetachedLogger::debug(), g_logger, getInstance(), and refreshTree.
Referenced by PackageManager::declareNewPackage(), FunctionDefinitionManager::defineFunc(), PackageManager::deletePackage(), and FunctionDefinitionManager::undefineFunc().
|
private |
This private member function will reset the kernel variables after an error had been handled.
Definition at line 2076 of file kernel.cpp.
References _debugger, _lang, _option, _parser, _pData, _procedure, _script, _stringParser, bCancelSignal, Script::close(), commandQueue, mu::ParserBase::DeactivateLoopMode(), NumeReDebugger::finalize(), Language::get(), Script::getCurrentLine(), Script::isOpen(), Script::isValid(), LineBreak(), print(), NumeRe::StringVarFactory::removeTempStringVectorVars(), FlowCtrl::reset(), sCommandLine, PlotData::setFileName(), and toString().
Referenced by MainLoop().
void NumeReKernel::saveData | ( | ) |
This member function performs the autosaving of tables at application shutdown.
Definition at line 2187 of file kernel.cpp.
References _lang, _memoryManager, _option, g_logger, Language::get(), MemoryManager::getSaveStatus(), DetachedLogger::info(), LineBreak(), print(), and MemoryManager::saveToCacheFile().
Referenced by CloseSession().
void NumeReKernel::sendErrorNotification | ( | ) |
This member function is used to toggle the error notification status. The error notification is used to style text as error messages.
Definition at line 2916 of file kernel.cpp.
References bErrorNotification.
Referenced by MainLoop().
|
inline |
|
static |
This member function handles the display of a documentation window as requested by the kernel.
_sDocumentation | const std::string& |
Definition at line 3130 of file kernel.cpp.
References NumeReTerminal::m_kernelCS, NumeReTerminal::m_KernelStatus, m_parent, NUMERE_OPEN_DOC, NUMERE_QUEUED_COMMAND, NumeReTask::sString, taskQueue, and NumeReTask::taskType.
Referenced by doc_Help().
void NumeReKernel::setKernelSettings | ( | const Settings & | _settings | ) |
Update the internal settings.
_settings | const Settings& |
Definition at line 107 of file kernel.cpp.
References _debugger, _option, Settings::copySettings(), NumeReDebugger::setActive(), and Settings::useDebugger().
Referenced by NumeReTerminal::setKernelSettings().
bool NumeReKernel::SettingsModified | ( | ) |
Returns true
, if the user changed any internal settings using the set
command.
Definition at line 2515 of file kernel.cpp.
References modifiedSettings.
Referenced by NumeReTerminal::OnThreadUpdate().
|
static |
This member function passes the debugging information to the GUI to be displayed in the debugger window.
sTitle | const std::string& |
vStacktrace | const std::vector<std::string>& |
Definition at line 3405 of file kernel.cpp.
References DetachedLogger::debug(), g_logger, NumeReTerminal::m_kernelCS, NumeReTerminal::m_KernelStatus, NumeReTerminal::m_nDebuggerCode, m_parent, NUMERE_DEBUG_EVENT, NUMERE_QUEUED_COMMAND, taskQueue, NumeReTask::taskType, and NumeReTask::vDebugEvent.
Referenced by NumeReDebugger::showEvent().
|
static |
This member function passes a string table to the GUI to be displayed in the table viewer.
_stringtable | NumeRe::Container<std::string> |
__name | std::string |
openeditable | bool |
Definition at line 3230 of file kernel.cpp.
References NumeReTerminal::m_kernelCS, NumeReTerminal::m_KernelStatus, m_parent, NUMERE_EDIT_TABLE, NUMERE_QUEUED_COMMAND, NUMERE_SHOW_STRING_TABLE, NumeReTask::sString, NumeReTask::stringTable, taskQueue, and NumeReTask::taskType.
Referenced by cmd_show().
|
static |
This member function passes a table to the GUI to be displayed in the table viewer. It also allows to create a table editor window.
_table | NumeRe::Table |
__name | std::string |
openeditable | bool |
Definition at line 3191 of file kernel.cpp.
References NumeReTerminal::m_kernelCS, NumeReTerminal::m_KernelStatus, m_parent, NUMERE_EDIT_TABLE, NUMERE_QUEUED_COMMAND, NUMERE_SHOW_TABLE, NumeReTask::sString, NumeReTask::table, taskQueue, and NumeReTask::taskType.
Referenced by editObject(), and show_data().
void NumeReKernel::showWindow | ( | const NumeRe::Window & | window | ) |
This member function passes a window object to the user interface, which will then converted into a real window.
window | const NumeRe::Window& |
Definition at line 3267 of file kernel.cpp.
References NumeReTerminal::m_kernelCS, NumeReTerminal::m_KernelStatus, m_parent, NUMERE_QUEUED_COMMAND, NUMERE_SHOW_WINDOW, taskQueue, NumeReTask::taskType, and NumeReTask::window.
Referenced by NumeRe::WindowManager::createWindow().
void NumeReKernel::StartUp | ( | NumeReTerminal * | _parent, |
const std::string & | __sPath, | ||
const std::string & | sPredefinedFunctions | ||
) |
This is the kernel "booting" function.
_parent | wxTerm* |
__sPath | const std::string& |
sPredefinedFunctions | const std::string& |
This function sets all parameters, functions and constants used for the numerical parser. loads possible available autosaves and definition files for functions and plugins.
Definition at line 144 of file kernel.cpp.
References _defVars, _fontData, _fSys, _functions, _lang, _memoryManager, _option, _out, _parser, _pData, _procedure, _script, Language::addToLanguage(), Settings::controlDefinitions(), Documentation::createDocumentationIndex(), FileSystem::createRevisionsFolder(), NumeRe::ClusterManager::dClusterElementsCount, DetachedLogger::debug(), defineConst(), defineFunctions(), defineOperators(), mu::ParserBase::DefineVar(), fileExists(), g_logger, Settings::getDefaultPlotFont(), Settings::getExePath(), Settings::getLoadPath(), Settings::getPlotPath(), PackageManager::getPluginInfoPath(), getPluginLanguageStrings(), PackageManager::getPluginNames(), FunctionDefinitionManager::getPredefinedFuncs(), Settings::getProcPath(), Settings::getSavePath(), Settings::getScriptPath(), Settings::getSetting(), getTimeStamp(), Settings::getTokenPaths(), Settings::getWindow(), DetachedLogger::info(), FunctionDefinitionManager::load(), Settings::load(), Settings::loadEmptyCols(), MemoryManager::loadFromCacheFile(), PackageManager::loadPlugins(), Language::loadStrings(), Logger::LVL_DISABLED, mu::ParserBase::m_lDataStorage, m_parent, NumeRe::ClusterManager::newCluster(), nLINE_LENGTH, DetachedLogger::open(), parser_AddVariable(), reduceLogFilesize(), refreshTree, NumeRe::FileAdapter::setbLoadEmptyCols(), NumeRe::Cluster::setDouble(), DetachedLogger::setLoggingLevel(), FileSystem::setPath(), MemoryManager::setPluginCommands(), MemoryManager::setPredefinedFuncs(), FunctionDefinitionManager::setPredefinedFuncs(), Procedure::setPredefinedFuncs(), Script::setPredefinedFuncs(), NumeRe::FileAdapter::setSavePath(), SETTING_S_EXEPATH, FileSystem::setTokens(), mu::ParserBase::SetVarFactory(), DefaultVariables::sName, SettingsValue::stringval(), MemoryManager::tableColumnsCount, MemoryManager::tableLinesCount, Settings::useCustomLangFiles(), Settings::useLogFile(), vAns, and DefaultVariables::vValue.
|
static |
Toggles the table writing status, which will reduce the number or events send to the terminal.
Definition at line 3671 of file kernel.cpp.
References bWritingTable.
Referenced by analyzePulse(), mu::ParserByteCode::AsciiDump(), cmd_credits(), createOutputForHist1D(), createOutputForHist2D(), createStatsOutput(), doc_SearchFct(), fitDataSet(), handleFlowControls(), listCommands(), listConstants(), listDeclaredVariables(), listDefinitions(), listFiles(), listFunctions(), listInstalledPlugins(), listLogicalOperators(), listUnitConversions(), progressBar(), show_data(), and showMatrixResult().
|
private |
This private member function uninstalls a previously installed plugin.
sLine | const std::string& |
sCurrentCommand | const std::string& |
Definition at line 1609 of file kernel.cpp.
References _lang, _option, _procedure, PackageManager::deletePackage(), findCommand(), fromSystemCodePage(), Language::get(), getArgAtPos(), getNextArgument(), installationDone(), LineBreak(), print(), and Documentation::removeFromDocIndex().
Referenced by MainLoop().
void NumeReKernel::updateLineLenght | ( | int | nLength | ) |
This member function is used to update the internal terminal line length information after the terminal had been resized.
nLength | int |
Definition at line 2169 of file kernel.cpp.
References _option, DetachedLogger::debug(), g_logger, Settings::getSetting(), nLINE_LENGTH, SETTING_V_WINDOW_X, and SettingsValue::value().
Referenced by NumeReTerminal::UpdateSize().
|
static |
This static function waits until the user sends a continuation command via the debugger and returns the corresponding debugger code.
Definition at line 3440 of file kernel.cpp.
References DetachedLogger::debug(), DEBUGGER_CONTINUE, g_logger, NumeReTerminal::m_kernelCS, NumeReTerminal::m_nDebuggerCode, and m_parent.
Referenced by NumeReDebugger::showEvent().
|
private |
Definition at line 159 of file kernel.hpp.
Referenced by getAns(), NumeReKernel(), and setAns().
|
private |
Definition at line 157 of file kernel.hpp.
Referenced by evalDebuggerBreakPoint(), getDebugger(), resetAfterError(), and setKernelSettings().
|
private |
Definition at line 147 of file kernel.hpp.
Referenced by getFileSystem(), and StartUp().
|
private |
Definition at line 153 of file kernel.hpp.
Referenced by CloseSession(), evaluateProcedureCalls(), executePlugins(), getDefinitions(), getFunctionLanguageStrings(), MainLoop(), and StartUp().
|
private |
Definition at line 158 of file kernel.hpp.
Referenced by getWindowManager().
|
private |
Definition at line 150 of file kernel.hpp.
Referenced by Autosave(), CloseSession(), evaluateProcedureCalls(), evaluateStrings(), executePlugins(), getAns(), getLastSavedTime(), getMemoryManager(), getStringTable(), getTable(), getVariableList(), handleFlowControls(), MainLoop(), saveData(), and StartUp().
|
private |
Definition at line 148 of file kernel.hpp.
Referenced by CloseSession(), evaluateProcedureCalls(), evaluateStrings(), executePlugins(), formatResultOutput(), getAutosaveInterval(), getDocIndex(), getDocumentation(), getGreeting(), getKernelSettings(), getPathSettings(), getSettings(), handleComposeBlock(), handleFlowControls(), handleProcedureWrite(), MainLoop(), printVersionInfo(), resetAfterError(), saveData(), setKernelSettings(), StartUp(), uninstallPlugin(), and updateLineLenght().
|
private |
Definition at line 149 of file kernel.hpp.
Referenced by CloseSession(), evaluateProcedureCalls(), executePlugins(), getOutput(), and StartUp().
|
private |
Definition at line 151 of file kernel.hpp.
Referenced by defineConst(), defineFunctions(), defineOperators(), evalDebuggerBreakPoint(), evaluateProcedureCalls(), executePlugins(), getParser(), getVariableList(), MainLoop(), resetAfterError(), and StartUp().
|
private |
Definition at line 154 of file kernel.hpp.
Referenced by CloseSession(), evaluateProcedureCalls(), executePlugins(), getPlottingData(), resetAfterError(), and StartUp().
|
private |
Definition at line 156 of file kernel.hpp.
Referenced by evaluateProcedureCalls(), evaluateStrings(), executePlugins(), getInstalledPackages(), getLineFromCommandCache(), getMenuMap(), getPluginCommands(), getPluginLanguageStrings(), getProcedureInterpreter(), handleComposeBlock(), handleFlowControls(), handleProcedureWrite(), handleToCmd(), MainLoop(), resetAfterError(), StartUp(), and uninstallPlugin().
|
private |
Definition at line 155 of file kernel.hpp.
Referenced by CloseSession(), createCalculationAnswer(), evaluateProcedureCalls(), evaluateStrings(), executePlugins(), getScript(), handleCommandLineSource(), handleComposeBlock(), handleFlowControls(), handleProcedureWrite(), MainLoop(), resetAfterError(), and StartUp().
|
private |
Definition at line 152 of file kernel.hpp.
Referenced by evaluateStrings(), getStringParser(), getVariableList(), handleToCmd(), MainLoop(), and resetAfterError().
|
static |
Definition at line 188 of file kernel.hpp.
Referenced by Procedure::execute(), and initializeStackTracker().
|
static |
Definition at line 193 of file kernel.hpp.
Referenced by CancelCalculation(), evaluateStrings(), GetAsyncCancelState(), handleFlowControls(), MainLoop(), and resetAfterError().
|
static |
Definition at line 201 of file kernel.hpp.
Referenced by print(), printPreFmt(), and sendErrorNotification().
|
static |
Definition at line 200 of file kernel.hpp.
Referenced by getline(), and NumeReTerminal::pipe_command().
|
static |
Definition at line 199 of file kernel.hpp.
Referenced by FlowCtrl::calc(), calculateSplines(), FlowCtrl::compile(), createCalculationAnswer(), NumeRe::StringParser::createStringOutput(), FlowCtrl::eval(), NumeRe::StringParser::evalAndFormat(), Procedure::execute(), FlowCtrl::for_loop(), getLineFromCommandCache(), handleFlowControls(), FlowCtrl::if_fork(), MainLoop(), printResult(), Procedure::ProcCalc(), FlowCtrl::range_based_for_loop(), Procedure::resetProcedure(), showMatrixResult(), FlowCtrl::switch_fork(), FlowCtrl::try_catch(), and FlowCtrl::while_loop().
|
static |
Definition at line 192 of file kernel.hpp.
Referenced by print(), printPreFmt(), printVersionInfo(), and toggleTableStatus().
|
private |
Definition at line 141 of file kernel.hpp.
Referenced by evaluateStrings(), getLineFromCommandCache(), handleCommandLineSource(), handleComposeBlock(), handleFlowControls(), handleProcedureWrite(), MainLoop(), and resetAfterError().
|
staticprivate |
Definition at line 144 of file kernel.hpp.
Referenced by getInstance(), NumeReKernel(), and ~NumeReKernel().
|
static |
Definition at line 189 of file kernel.hpp.
Referenced by checkInternalStates(), clcTerminal(), CloseSession(), closeWindows(), failMessage(), flush(), getline(), getTable(), gotoLine(), installationDone(), issueWarning(), MainLoop(), print(), printPreFmt(), printResult(), setDocumentation(), showDebugEvent(), showStringTable(), showTable(), showWindow(), StartUp(), and waitForContinue().
|
static |
Definition at line 197 of file kernel.hpp.
Referenced by cmd_set(), and SettingsModified().
|
static |
Definition at line 196 of file kernel.hpp.
Referenced by MainLoop(), and progressBar().
|
static |
Definition at line 195 of file kernel.hpp.
Referenced by MainLoop(), and progressBar().
|
static |
Definition at line 191 of file kernel.hpp.
Referenced by make_hline(), sectionHeadline(), StartUp(), and updateLineLenght().
|
static |
Definition at line 194 of file kernel.hpp.
Referenced by editObject(), and ReadOpenFileFlag().
|
static |
Definition at line 202 of file kernel.hpp.
Referenced by NumeReTerminal::Entry(), Procedure::execute(), Procedure::getInlined(), getProcedureLibrary(), and Procedure::isInlineable().
|
private |
Definition at line 142 of file kernel.hpp.
Referenced by checkInternalStates(), MainLoop(), refreshFunctionTree(), and StartUp().
|
private |
Definition at line 139 of file kernel.hpp.
Referenced by CloseSession(), NumeReKernel(), and ReadAnswer().
|
private |
Definition at line 138 of file kernel.hpp.
Referenced by CloseSession(), evaluateStrings(), MainLoop(), NumeReKernel(), and resetAfterError().
|
private |
Definition at line 140 of file kernel.hpp.
Referenced by handleComposeBlock(), handleFlowControls(), handleProcedureWrite(), and NumeReKernel().
|
static |
Definition at line 198 of file kernel.hpp.
Referenced by getTable(), and NumeReTerminal::passEditedTable().
|
static |
Definition at line 190 of file kernel.hpp.
Referenced by checkInternalStates(), clcTerminal(), closeWindows(), gotoLine(), installationDone(), NumeReTerminal::OnThreadUpdate(), setDocumentation(), showDebugEvent(), showStringTable(), showTable(), and showWindow().