IGLib
1.7.2
The IGLib base library EXTENDED - with other lilbraries and applications.
|
Internal script for running embedded applications. More...
Public Member Functions | |
AppIgorGresovnik () | |
void | CloseLogWriter () |
Closes the file writer used for logging, and thus unlocks teh underlyig file so that other programs dcan use it. More... | |
override void | Script_AddCommands (ICommandLineApplicationInterpreter interpreter, SortedList< string, string > helpStrings) |
Adds application commands to the application interpreter. More... | |
string | AppExGraphics (string[] arguments) |
Runs some graphics examples. More... | |
string | AppExVector (string[] arguments) |
Runs some vector examples. More... | |
string | AppExFunction (string[] arguments) |
Example for defining custom functions. More... | |
string | AppExLocateScriptCode (string[] arguments) |
Code in this method helps the user locate script classes and their appropriate methods that execute particular examples via the "Internal" interpreter command. More... | |
![]() | |
AppExtBase () | |
virtual string | AppFormDemo (string[] arguments) |
Runs one of the form demo - related embedded applications. More... | |
![]() | |
AppBase () | |
virtual string | AppCustom (string[] arguments) |
Runs one of the custom embedded applications. More... | |
![]() | |
void | Script_AddCommands1 (ICommandLineApplicationInterpreter interpreter, SortedList< string, string > helpStrings) |
Adds commands to the internal interpreter. More... | |
ScriptAppBase () | |
virtual string | RunFileByScript (string filePath) |
Runs all commands that are written in a file. Each line of a file is interpreted as a single command, consisting of command name followed by arguments. More... | |
virtual void | ReportError (string errorString) |
new string | AppMyTest (string[] arguments) |
Test action. More... | |
override string | AppCustomApp (string[] arguments) |
Custom application. More... | |
virtual string | AppNumerics (string[] arguments) |
Runs one of the numerics - related embedded applications. More... | |
virtual string | AppFile (string[] arguments) |
Runs one of the file system - related embedded applications. More... | |
virtual string | AppCrypto (string[] arguments) |
Runs one of the cryptography - related embedded applications. More... | |
virtual string | AppSystem (string[] arguments) |
Runs one of the file system - related embedded applications. More... | |
virtual string | AppAssembly (string[] arguments) |
Runs one of the file assembly - related embedded applications. More... | |
virtual string | AppProcess (string[] arguments) |
Runs one of the process - related embedded applications. More... | |
virtual string | AppDataStructures (string[] arguments) |
Runs one of the data structures demo - related embedded applications. More... | |
![]() | |
LoadableScriptSpecialFunctionBase () | |
override void | Script_AddCommand (ICommandLineApplicationInterpreter interpreter, SortedList< string, string > helpStrings, string commandName, Script_CommandDelegate command, string helpString) |
Adds a new internal script command under specified name to the internal interpreter of the current script object. More... | |
string | AppMyTest (string[] arguments) |
Test action. More... | |
![]() | |
LoadableScriptBase () | |
Argument-less constructor. If argument-less constructor is called then initialization is not performed and will be performed later. More... | |
string | Run (string[] arguments) |
Performs the action of this object. Override this in derived classes! More... | |
void | Initialize (string[] arguments) |
Initializes the object. If not called explicitly, this method is automatically called at the first call to the Run method. More... | |
virtual string | Script_DefaultInitialize (string[] arguments) |
Default initialization method for scripts. More... | |
virtual string | Script_DefaultRun (string[] arguments) |
Default run method for the script. Can be used when only installed commands are run by hte script. More... | |
virtual ICommandLineApplicationInterpreter | Script_CreateInterpreterWithoutCommands () |
Creates and returns an interpreter that can be used as script's internal interpreter for running script's commands. More... | |
delegate string | Script_CommandDelegate (string[] args) |
Delegate for commands that are installed on script's internal interpreter (property Script_Interpreter). More... | |
void | Script_AddCommand (string commandName, Script_CommandDelegate command, string helpString) |
Adds a new internal script command under specified name to the internal interpreter of the current script object. More... | |
string | Script_GetHelpString (string scriptCommandName) |
Returns help string for internal script command with specified name, or null if help string is not installed for such a command. More... | |
void | Script_PrintCommandsHelp () |
Prits help for the installed internal commands of the script. More... | |
virtual bool | Script_ContainsCommand (string commandName) |
Returns true if the internal script's interpreter contains a command with specified name, false otherwise. More... | |
virtual bool | Script_ContainsScriptCommand (string commandName) |
Returns true if the specified command is script command (i.e. its first argument is command-name and it is run through the Script_CommandAdapter object). More... | |
virtual void | Script_RemoveCommand (string commandName) |
Removes the specified internal script command from the internal interpreter of the current scripting object. More... | |
virtual void | Script_RemoveAllCommands () |
Removes ALL internal script commands from the internal interpreter of the current scripting object. More... | |
string | Script_Run (string[] arguments) |
Runs internal script command. More... | |
string | Script_Run (string commandName, params string[] otherArguments) |
Runs internal script command. More... | |
virtual void | Script_PrintArguments (string messageString, string[] arguments) |
Prints the specified array of string arguments (usually passed as command-line arguments). More... | |
Public Attributes | |
const string | DefaultWorkingDirectoryName = "Petek_Diploma" |
Default name of the working directory for Marko Petek's graduate thesis. More... | |
const string | DefaultSolutionFileName = "Solution.txt" |
Default name of the file where solution is written. More... | |
const string | DefaultLogFileName = "Log.txt" |
Default name of the application's log file. More... | |
const string | ConstExGraphics = "ExGraphics" |
Name of the command that runns the main thesis application. More... | |
const string | ConstHelpExGraphics = "Customized function for running some examples." |
const string | ConstExVector = "ExVector" |
Name of the command that runns the main thesis application. More... | |
const string | ConstHelpExVector = "Customized function for running some vector examples." |
const string | ConstExFunction = "ExFunction" |
Name of the command that runns the main thesis application. More... | |
const string | ConstHelpExFunction = "Customized function for running some real function examples." |
const string | ConstLocateScriptCode = "LocateScriptCode" |
Name of the command that runs the snippet of code used for location of script classes. More... | |
const string | ConstHelpLocateScriptCode = "Runs auxiliary code containing instructions for locating script code." |
![]() | |
const string | ConstFormDemo = "FormDemo" |
Name of the command for the file system-related embedded applications. More... | |
const string | ConstHelpFormDemo |
const string | FormDemoTestDevelop = "TestDevelop" |
const string | FormDemoLaunchInfo = "Info" |
const string | FormDemoLaunchWarning = "Warning" |
const string | FormDemoLaunchError = "Error" |
const string | IgFormsNamespace = "IG.Forms" |
const string | FormDemoOpenForm = "OpenForm" |
const string | FormDemoOpenControl = "OpenControl" |
const string | FormDemoOpenFormOrControl = "OpenFormOrControl" |
const string | FormDemoFadingMessage = "FadingMessage" |
const string | FormDemoBrowserSimple = "Browser" |
const string | FormDemoWindowPositioning = "WindowPositioning" |
const string | FormDemoMessageBoxLauncher = "MessageBoxLauncher" |
const string | FormDemoStopWatch = "StopWatch" |
const string | FormDemoCookingTimer = "CookingTimer" |
const string | CryptoHashForm = "HashForm" |
![]() | |
const string | ConstCustom = "Custom" |
Name of the command for a group of custom applications. More... | |
const string | ConstHelpCustom = "Custom application group." |
const string | FileTestArguments = "PrintArguments" |
const string | CustomPrintArguments = "PrintArguments" |
![]() | |
const string | DataStructuresTestCsvApp = "TestCsv" |
const string | DataStructuresTestCsvWriteDefinitionAndData = "CsvWriteDefinitionAndData" |
const string | DataStructuresTestCsvReadDefinitionAndData = "CsvReadDefinitionAndData" |
new const string | ConstMyTest = "MyTest" |
Name of the command that performs my custom test. More... | |
new const string | ConstHelpMyTest = "Custom test function." |
new const string | ConstCustomApp = "CustomApp" |
Name of the command for custom test. More... | |
new const string | ConstHelpCustomApp = "Custom aplication." |
const string | ConstSystem = "System" |
Name of the command for the system-related embedded applications. More... | |
const string | ConstHelpSystem = "Various system-related embedded applications. Run with ? argument to see which applications are available." |
const string | ConstAssembly = "Assembly" |
Name of the command for the assemblies-related embedded applications. More... | |
const string | ConstHelpAssembly = "Various assemblies-related embedded applications. Run with ? argument to see which applications are available." |
const string | ConstNumerics = "Numerics" |
Name of the command for the numerics-related embedded applications. More... | |
const string | ConstHelpNumerics = "Various numerics-related embedded applications. Run with ? argument to see which applications are available." |
const string | ConstFile = "File" |
Name of the command for the file system-related embedded applications. More... | |
const string | ConstHelpFile = "Various file system-related embedded applications. Run with ? argument to see which applications are available." |
const string | ConstCrypto1 = "Crypto" |
Name of the command for the cryptography-related embedded applications. More... | |
const string | ConstHelpCrypto = "Various cryptography-related embedded applications. Run with ? argument to see which applications are available." |
const string | ConstProcess = "Process" |
Name of the command for the process-related embedded applications. More... | |
const string | ConstHelpProcess = "Various process-related embedded applications. Run with ? argument to see which applications are available." |
const string | ConstDataStructures = "DataStructures" |
Name of the command for the data structures-related embedded applications. More... | |
const string | ConstHelpDataStructures |
const string | ConstRunFile = "RunFileByScript" |
Name of the command that runs (interprets) the specified command file by the script's interpreter. More... | |
const string | ConstHelpRunFile |
const string | NumericsScriptScalarFunction = "ScriptScalarFunction" |
const string | FileLogEvents = "LogEvents" |
const string | FileWaitCreation = "WaitCreation" |
const string | FileRelativePath = "RelativePath" |
const string | FileStandardPath = "StandardPath" |
const string | FileCurrentDirectory = "CurrentDirectory" |
const string | FileCurrentDirectory1 = "SetCurrentDirectory" |
const string | CryptoGetFileHash = "GetFileHash" |
const string | CryptoCheckSum = "CheckSum" |
const string | CryptoEncryptBasic = "EncryptBasic" |
const string | CryptoDecryptBasic = "DecryptBasic" |
const string | CryptoEncryptPlain = "EncryptPlain" |
const string | CryptoDecryptPlain = "DecryptPlain" |
const string | CryptoGetKey = "GetKey" |
const string | CryptoGetInitializationVector = "GetInitializationVector" |
const string | CryptoGetInitializationVector1 = "GetIV" |
const string | CryptoGetSalt = "GetSalt" |
const string | CryptoTimeKeyGeneration = "TimeKeyGeneration" |
const string | CryptoConvert = "Convert" |
const string | CryptoAsymKeyInfo = "AsymKeyInfo" |
const string | CryptoCertStoreInfo = "CertStoreInfo" |
const string | CryptoCertInfo = "CertInfo" |
const string | CryptoAddCertificate = "AddCertificate" |
const string | CryptoRemoveCertificate = "RemoveCertificate" |
const string | CryptoAsymTest = "AsymTest" |
const string | CryptoCleanFiles = "CleanFiles" |
const string | SystemRuntimeVersion = "RuntimeVersion" |
const string | SystemComputerName = "ComputerName" |
const string | SystemDomainName = "DomainName" |
const string | SystemIpAddress = "IpAddress" |
const string | SystemUserName = "UserName" |
const string | SystemSystemInfo = "Info" |
const string | SystemMACAddress = "MACAddress" |
const string | AssemblyInfo = "Info" |
const string | AssemblyInfo1 = "AssemblyInfo" |
const string | AssemblyResources = "Resources" |
const string | AssemblyResources1 = "ResourceInfo" |
const string | AssemblyResourcesEmbedded = "ResourcesEmbedded" |
const string | AssemblyResourcesResx = "ResourcesResx" |
const string | AssemblyReferenced = "ReferencedAssemblies" |
const string | AssemblyReferenced1 = "Referenced" |
const string | AssemblyLoaded = "LoadedAssemblies" |
const string | AssemblyLoaded1 = "Loaded" |
const string | AssemblyLoad = "LoadAssemblies" |
const string | AssemblyLoad1 = "Load" |
const string | AssemblyInfoLoad = "InfoLoadAssemblies" |
const string | AssemblyInfoLoad1 = "InfoLoad" |
const string | ProcessListProcesses = "ListProcesses" |
const string | ProcessListApplications = "ListApplications" |
const string | ProcessListApplicationsByWindow = "ListApplicationsByWindow" |
const string | ProcessKillProcesses = "KillProcesses" |
const string | ProcessKillApplications = "KillApplications" |
const string | ProcessKillApplicationsByWindow = "KillApplicationsByWindow" |
![]() | |
const string | ConstMyTest = "MyTest" |
Name of the command that performs my custom test. More... | |
const string | ConstHelpMyTest = "Custom test function." |
const string | ConstCustomApp = "CustomApp" |
Name of the command for custom test. More... | |
const string | ConstHelpCustomApp = "Custom aplication." |
![]() | |
const string | ConstDefaultHelp = "Help" |
Default command name for help. More... | |
const string | ConstHelpDefaultUniversal = "?" |
Universal name of the help command. More... | |
const string | ConstDefaultTestScrip = "TestScript" |
Default command name for test method. More... | |
Protected Member Functions | |
virtual void | InitLogWriter (TextWriter writer) |
Initializes a text writer used for logging. More... | |
![]() | |
void | AddFormDemoCommand (string appName, CommandMethod appMethod, string appHelp) |
Adds a new form demonstration - related embedded application's command (added as a sub-command of the base command named ConstFormDemo). More... | |
virtual string | FormDemoFunctionTestDevelop (string appName, string[] args) |
Executes embedded application - a test function used in development. More... | |
virtual string | FormDemoFunctionLaunchInfo (string appName, string[] args) |
Executes embedded application - launches an info message by the IG.Forms.UtilForms.Reporter. Message to be shown must be passed as command argument. More... | |
virtual string | FormDemoFunctionLaunchWarning (string appName, string[] args) |
Executes embedded application - launches a warning message by the IG.Forms.UtilForms.Reporter. Message to be shown must be passed as command argument. More... | |
virtual string | FormDemoFunctionLaunchError (string appName, string[] args) |
Executes embedded application - launches an error message by the IG.Forms.UtilForms.Reporter. Message to be shown must be passed as command argument. More... | |
virtual string | FormDemoFunctionLaunchReport (ReportType type, string appName, string[] args) |
Executes embedded application - launches a message of particular kind by the IG.Forms.UtilForms.Reporter. Message to be shown must be passed as command argument. More... | |
virtual string | FormDemoFunctionOpenForm (string appName, string[] args) |
Executes embedded application - opens the specified form. The form must either be specified with a fully qualified name of its class, or, if its class is in the IG.Forms namespace, with just a simple name of its class. More... | |
virtual string | FormDemoFunctionOpenControl (string appName, string[] args) |
Executes embedded application - launches the specified control. The control must either be specified with a fully qualified name of its class, or, if its class is in the IG.Forms namespace, with just a simple name of its class. The form is launched embedded in a container window handled by the ControlViewerForm class. More... | |
virtual string | FormDemoFunctionOpenFormOrControl (string appName, string[] args) |
Executes embedded application - opens the specified form or control. The form or control must either be specified with a fully qualified name of its class, or, if its class is in the IG.Forms namespace, with just a simple name of its class. More... | |
virtual string | FormDemoFunctionOpenFormOrControl (bool openForm, bool openControl, string appName, string[] args) |
Executes embedded application - opens the specified form or control. The form or control must either be specified with a fully qualified name of its class, or, if its class is in the IG.Forms namespace, with just a simple name of its class. More... | |
virtual string | FormDemoFunctionOpenFormOld (string appName, string[] args) |
Executes embedded application - opens the specified form. The form must either be specified with a fully qualified name of its class, or, if its class is in the IG.Lib namespace, with just a simple name of its class (or more precisel, part of the name that comes after "IG.Lib."). More... | |
virtual string | FormDemoFunctionFadingMessage (string appName, string[] args) |
Executes embedded application - demonstration of fading messages. More... | |
virtual string | FormDemoFunctionBrowserSimple (string appName, string[] args) |
Executes embedded application - demonstration of fading messages. More... | |
virtual string | FormDemoFunctionWindowPositioning (string appName, string[] args) |
Executes embedded application - window positioning test. More... | |
virtual string | FormDemoFunctionMessageBoxLauncher (string appName, string[] args) |
Executes embedded application - messaxe box launcher demo. More... | |
virtual string | FormDemoFunctionStopWatch (string appName, string[] args) |
Executes embedded application - a stopwatch. More... | |
virtual string | FormDemoFunctionCookingTimer (string appName, string[] args) |
Executes embedded application - a cooking timer with a countdown and alarm. More... | |
virtual void | InitAppFormDemo () |
Initializes commands for form demo related utilities (embedded applications). More... | |
virtual string | RunAppFormDemo (string[] args) |
Runs a form demo - related utility (embedded application) according to arguments. More... | |
virtual string | CryptoFunctionHashForm (string appName, string[] args) |
Executes embedded application - launches a windows form for calculation of various hashRet values of a file. More... | |
override void | InitAppCrypto () |
Initializes commands for cryptography related utilities (embedded applications). More... | |
![]() | |
override void | InitAppFile () |
Initializes commands for file system related utilities (embedded applications). More... | |
virtual string | FileFunctionTestArguments (string appName, string[] args) |
Executes embedded application that just prints arguments passed to the application to a console. More... | |
void | AddCustomCommand (string appName, CommandMethod appMethod, string appHelp) |
Adds a new file system - related embedded application's command (added as sub-command of the base command named ScriptAppBase.ConstFile). More... | |
virtual string | CustomFunctionPrintArguments (string appName, string[] args) |
Executes embedded application - writing to the console information about file events for the specified file or directory. More... | |
virtual void | InitAppCustom () |
Initializes commands for file system related utilities (embedded applications). More... | |
virtual string | RunAppCustom (string[] args) |
Runs a file system related utility (embedded application) according to arguments. More... | |
![]() | |
virtual void | InitAppDataStructuresPartial () |
Initializes commands for form demo related utilities (embedded applications). More... | |
virtual string | DataStructuresFunctionTestCsvApp (string appName, string[] args) |
Executes embedded application - demo application for demonstration of work with CSVs. More... | |
virtual string | DataStructuresFunctionTestCsvWriteDefinitionAndData (string appName, string[] args) |
Executes embedded application - test of writing sampled data definition and data in CSV format. More... | |
virtual string | DataStructuresFunctionTestCsvReadDefinitionAndData (string appName, string[] appArgs) |
Executes embedded application - test of writing sampled data definition and data in CSV format. More... | |
override void | InitializeThis (string[] arguments) |
Initializes the current object. More... | |
override string | RunThis (string[] arguments) |
Runs action of the current object. More... | |
void | Script_AddRunFileByScriptCommand (ICommandLineApplicationInterpreter interpreter, SortedList< string, string > helpStrings) |
Adds the Run comand to the script's interpreter and performs the necessary additional tasks. More... | |
void | Script_RemoveRunFileByScriptCommand (ICommandLineApplicationInterpreter interpreter, SortedList< string, string > helpStrings) |
Removes the Run comand from the script's interpreter and performs the necessary accompanying tasks. More... | |
virtual string | AppRunFileByScript (string[] args) |
Execution method that Runs the specified command file by the script's interpreter. More... | |
void | AddNumericsCommand (string appName, CommandMethod appMethod, string appHelp) |
Adds a new numerics - related embedded application's command (added as sub-command of the base command named ConstNumerics). More... | |
virtual string | NumericsFunctionScriptScalarFuncitons (string appName, string[] args) |
Executes embedded application - testing of definition of scalar function objects through expressions. More... | |
virtual void | InitAppNumerics () |
Initializes commands for numerics related utilities (embedded applications). More... | |
virtual string | RunAppNumerics (string[] args) |
Runs a numerics related utility (embedded application) according to arguments. More... | |
void | AddFileCommand (string appName, CommandMethod appMethod, string appHelp) |
Adds a new file system - related embedded application's command (added as sub-command of the base command named ConstFile). More... | |
virtual string | FileFunctionLogEvents (string appName, string[] args) |
Executes embedded application - writing to the console information about file events for the specified file or directory. More... | |
virtual string | FileFunctionWaitCreation (string appName, string[] args) |
Executes embedded application - waiting for creation of the specified file. More... | |
virtual string | FileFunctionRelativePath (string appName, string[] args) |
Executes embedded application - writing to the console information about file events for the specified file or directory. More... | |
virtual string | FileFunctionStandardPath (string appName, string[] args) |
Executes embedded application - writing to the console information about file events for the specified file or directory. More... | |
virtual string | FileFunctionCurrentDirectory (string appName, string[] args) |
Executes embedded application - writing to the console information about file events for the specified file or directory. More... | |
virtual string | RunAppFile (string[] args) |
Runs a file system related utility (embedded application) according to arguments. More... | |
void | AddCryptoCommand (string appName, CommandMethod appMethod, string appHelp) |
Adds a new cryptography - related embedded application's command (added as sub-command of the base command named ConstCrypto1). More... | |
virtual string | CryptoFunctionGetFileHash (string appName, string[] args) |
Executes embedded application - calculation of various hashRet values of a file. More... | |
virtual string | CryptoFunctionCheckSum (string appName, string[] args) |
Executes embedded application - calculation AND verification of various hashRet values of a file or a string. More... | |
virtual string | CryptoFunctionEncryptBasic (string appName, string[] args) |
Executes embedded application - symmetric encryption of files, strings, or byte fields by using the BASIC class of methods. More... | |
virtual string | CryptoFunctionDecryptBasic (string appName, string[] args) |
Executes embedded application - symmetric decryption of files, strings, or byte fields by using the BASIC class of methods. More... | |
virtual string | CryptoFunctionEncryptPlain (string appName, string[] args) |
Executes embedded application - symmetric encryption of files, strings, or byte fields by using the PLAIN class of methods. More... | |
virtual string | CryptoFunctionDecryptPlain (string appName, string[] args) |
Executes embedded application - symmetric decryption of files, strings, or byte fields by using the PLAIN class of methods. More... | |
virtual string | CryptoFunctionGetKey (string appName, string[] args) |
Executes embedded application - generation of secret keys for encryption. More... | |
virtual string | CryptoFunctionGetInitializationVector (string appName, string[] args) |
Executes embedded application - generation of initialization vectors for encryption. More... | |
virtual string | CryptoFunctionGetSalt (string appName, string[] args) |
Executes embedded application - generation of salts for encryption. More... | |
virtual string | CryptoFunctionTimeKeyGeneration (string appName, string[] args) |
Executes embedded application - measuring time of password generaton utilities. More... | |
virtual string | CryptoFunctionConvert (string appName, string[] args) |
Executes embedded application - conversion between different representations of data. More... | |
virtual string | CryptoFunctionAsymKeyInfo (string appName, string[] args) |
Executes embedded application - printing infomration about the specified asymmetric key. More... | |
virtual string | CryptoFunctionCertStoreInfo (string appName, string[] args) |
Executes embedded application - printing infomration about the specified certificate store. More... | |
virtual string | CryptoFunctionCertInfo (string appName, string[] args) |
Executes embedded application - printing infomration about the specified certificate. More... | |
virtual string | CryptoFunctionAddCertificate (string appName, string[] args) |
Executes embedded application - adding the specified certificate to the specified certificate store. More... | |
virtual string | CryptoFunctionRemoveCertificate (string appName, string[] args) |
Executes embedded application - removing the certificate from certificate store. More... | |
virtual string | CryptoFunctionAsymTest (string appName, string[] args) |
Executes embedded application - test of asymmetric encrypton. More... | |
virtual string | CryptoFunctionCleanFiles (string appName, string[] args) |
Executes embedded application - conversion between different representations of data. More... | |
virtual string | RunAppCrypto (string[] args) |
Runs a cryptography related utility (embedded application) according to arguments. More... | |
virtual string | CryptoFunctionGetFileHash_OLD_TO_DELETE (string appName, string[] args) |
Executes embedded application - calculation of various hashRet values of a file. More... | |
virtual string | CryptoFunctionCheckSum_OLD_TO_DELETE_LATER (string appName, string[] args) |
Executes embedded application - calculation AND verification of various hashRet values of a file. More... | |
virtual string | CryptoFunctionTimeKeyGeneration_OLD_TO_DELETE_LATER (string appName, string[] args) |
Executes embedded application - symmetric encryption of files, strings, or byte fields. More... | |
virtual string | CryptoFunctionConvert_OLD_TO_DELETE (string appName, string[] args) |
Executes embedded application - symmetric encryption of files, strings, or byte fields. More... | |
void | AddSystemCommand (string appName, CommandMethod appMethod, string appHelp) |
Adds a new system - related embedded application's command (added as sub-command of the base command named ConstSystem). More... | |
virtual string | SystemFunctionRuntimeVersion (string appName, string[] args) |
Executes embedded application - writing to the console and returning version of the runtime that application runs on. More... | |
virtual string | SystemFunctionComputerName (string appName, string[] args) |
Executes embedded application - writing to the console and returning the current computer name. More... | |
virtual string | SystemFunctionDomainName (string appName, string[] args) |
Executes embedded application - writing to the console and returning the current domain name. More... | |
virtual string | SystemFunctionIpAddress (string appName, string[] args) |
Executes embedded application - writing to the console and returning the current IP address. More... | |
virtual string | SystemFunctionUserName (string appName, string[] args) |
Executes embedded application - writing to the console and returning the current user name. More... | |
virtual string | SystemFunctionSystemInfo (string appName, string[] args) |
Executes embedded application - writing to the console and returning the system info. More... | |
virtual string | SystemFunctionMACAddress (string appName, string[] args) |
Executes embedded application - writing to the console and returning the current domain name. More... | |
virtual void | InitAppSystem () |
Initializes commands for file system related utilities (embedded applications). More... | |
virtual string | RunAppSystem (string[] args) |
Runs a file system related utility (embedded application) according to arguments. More... | |
void | AddAssemblyCommand (string appName, CommandMethod appMethod, string appHelp) |
Adds a new assembly - related embedded application's command (added as sub-command of the base command named ConstSystem). More... | |
virtual string | AssemblyFunctionInfo (string appName, string[] args) |
Executes embedded application - writing to the console information about the specified assembly. More... | |
virtual string | AssemblyFunctionResourcesEmbedded (string appName, string[] args) |
Executes embedded application - writing to the console information about the specified assembly's embedded resources. More... | |
virtual string | AssemblyFunctionResourcesResx (string appName, string[] args) |
Executes embedded application - writing to the console information about the specified assembly's resources included through .resx files. More... | |
virtual string | AssemblyFunctionResources (string appName, string[] args) |
Executes embedded application - writing to the console information about the specified assembly's resources. More... | |
virtual string | AssemblyFunctionResources (string appName, string[] args, bool includeEmbedded, bool includeResx) |
Executes embedded application - writing to the console information about the specified assembly's resources. More... | |
virtual string | AssemblyFunctionReferenced (string appName, string[] args) |
Executes embedded application - writing to the console list of referenced assemblies. More... | |
virtual string | AssemblyFunctionLoaded (string appName, string[] args) |
Executes embedded application - writing to the console list of loaded assemblies. More... | |
virtual string | AssemblyFunctionLoadAssemblies (string appName, string[] args) |
Executes embedded application - loading the specified assemblies to the application domain. More... | |
virtual string | AssemblyFunctionInfoLoadAssemblies (string appName, string[] args) |
Executes embedded application - loading the specified assemblies for inspection only (can not be executed). More... | |
virtual string | AssemblyFunctionLoadAssemblies (int outputLevel, bool reflectionOnly, string appName, string[] args) |
Executes embedded application - loading the specified assemblies to the application domain. More... | |
virtual void | InitAppAssembly () |
Initializes commands for assembly related utilities (embedded applications). More... | |
virtual string | RunAppAssembly (string[] args) |
Runs a file assembly related utility (embedded application) according to arguments. More... | |
void | AddProcessCommand (string appName, CommandMethod appMethod, string appHelp) |
Adds a new process - related embedded application's command (added as sub-command of the base command named ConstProcess). More... | |
virtual string | ProcessFunctionListProcesses (string appName, string[] args) |
Embedded application - lists all processes that satisfy the specified conditions. More... | |
virtual string | ProcessFunctionListApplications (string appName, string[] args) |
Embedded application. Lists all running applications sarisfyin specified conditions. More... | |
virtual string | ProcessFunctionListApplicationsByWindow (string appName, string[] args) |
Embedded application. Lists all running applications sarisfyin specified conditions. More... | |
virtual string | ProcessFunctionKillProcesses (string appName, string[] args) |
Embedded application - kills all processes that satisfy the specified conditions. More... | |
virtual string | ProcessFunctionKillApplications (string appName, string[] args) |
Embedded application. Kills all running applications sarisfyin specified conditions. More... | |
virtual string | ProcessFunctionKillApplicationsByWindow (string appName, string[] args) |
Embedded application. Kills all running applications sarisfyin specified conditions. More... | |
virtual void | InitAppProcess () |
Initializes commands for process - related utilities (embedded applications). More... | |
virtual string | RunAppProcess (string[] args) |
Runs a process - related utility (embedded application) according to arguments. More... | |
void | AddDataStructuresCommand (string appName, CommandMethod appMethod, string appHelp) |
Adds a new data structure- related embedded demo application's command (added as a sub-command of the base command named ConstDataStructures). More... | |
virtual void | InitAppDataStructures () |
Initializes commands for form demo related utilities (embedded applications). More... | |
virtual string | RunAppDataStructures (string[] args) |
Runs a data structures demo - related utility (embedded application) according to arguments. More... | |
![]() | |
override void | InitializeThis (string[] arguments) |
Initializes the current object. More... | |
override string | RunThis (string[] arguments) |
Runs action of the current object. More... | |
![]() | |
delegate string | CommandMethod (string commandName, string[] args) |
Delegate for internal command methods. More... | |
ICommandLineApplicationInterpreter | Script_CreateInterpreter () |
Creates and returns an interpreter that can be used as script's internal interpreter for running script's commands. More... | |
virtual string | Script_CommandHelp (string[] arguments) |
Prints help. More... | |
virtual string | Script_CommandTestScript (string[] arguments) |
Prints help. More... | |
Protected Attributes | |
string | _workingDirectoryName = DefaultWorkingDirectoryName |
string | _workingDirectoryPath |
string | _solutionFileName = DefaultSolutionFileName |
string | _solutionFilePath |
string | _logFileName = DefaultLogFileName |
string | _logFilePath |
bool | _externalLogWriterUsed = false |
![]() | |
List< string > | AppFormDemoNames = new List<string>() |
List of installed form demo command names. More... | |
List< string > | AppFormDemoHelpStrings = new List<string>() |
List of help strings corresponding to installed form demo commands. More... | |
List< CommandMethod > | AppFormDemoMethods = new List<CommandMethod>() |
List of methods used to perform form demo commmands. More... | |
const string | FormDemoHelpTestDevelop |
const string | FormDemoHelpLaunchInfo |
const string | FormDemoHelpLaunchWarning |
const string | FormDemoHelpLaunchError |
const string | FormDemoHelpOpenForm |
const string | FormDemoHelpOpenControl |
const string | FormDemoHelpOpenFormOrControl |
const string | FormDemoHelpFadingMessage = FormDemoFadingMessage + " : Runs the fading message demo." |
const string | FormDemoHelpBrowserSimple = FormDemoBrowserSimple + " : Runs a browser." |
const string | FormDemoHelpWindowPositioning = FormDemoWindowPositioning + " : Runs the window positioning test." |
const string | FormDemoHelpMessageBoxLauncher = FormDemoMessageBoxLauncher + " : Runs the window positioning test." |
const string | FormDemoHelpStopWatch |
const string | FormDemoHelpCookingTimer |
bool | _appFormDemoCommandsInitialized = false |
const string | CryptoHelpHashForm |
HashForm | hashForm |
![]() | |
List< string > | AppCustomNames = new List<string>() |
List of installed file command names. More... | |
List< string > | AppCustomHelpStrings = new List<string>() |
List of help strings corresponding to installed file commands. More... | |
List< CommandMethod > | AppCustomMethods = new List<CommandMethod>() |
List of methods used to perform file commmands. More... | |
const string | CustomHelpPrintArguments = CustomPrintArguments + " arg1 arg2 ... : Prints out the arguments of the command." |
bool | _appCustomCommandsInitialized = false |
![]() | |
const string | DataStructuresHelpTestCsvApp = DataStructuresTestCsvApp + " : Runs the CSV simple demo application." |
const string | DataStructuresHelpTestCsvWriteDefinitionAndData |
const string | DataStructuresHelpTestCsvReadDefinitionAndData |
bool | _isAddRunFileByScriptCommand = true |
List< string > | AppNumericsNames = new List<string>() |
List of installed numerics command names. More... | |
List< string > | AppNumericsHelpStrings = new List<string>() |
List of help strings corresponding to installed numerics-related commands. More... | |
List< CommandMethod > | AppNumericsMethods = new List<CommandMethod>() |
List of methods used to perform numerics-related commmands. More... | |
const string | NumericsHelpScriptScalarFunction = NumericsScriptScalarFunction + " : Definition of scalar functions by expressions." |
bool | _appNumericsCommandsInitialized = false |
List< string > | AppFileNames = new List<string>() |
List of installed file command names. More... | |
List< string > | AppFileHelpStrings = new List<string>() |
List of help strings corresponding to installed file commands. More... | |
List< CommandMethod > | AppFileMethods = new List<CommandMethod>() |
List of methods used to perform file commmands. More... | |
const string | FileHelpLogEvents = FileLogEvents + " FileOrDirectory MaxEvents : Logs file events for the specified file or directory." |
const string | FileHelpWaitCreation = NumericsScriptScalarFunction + " FilePath <ReturnIfExists> : Waits until file is created." |
const string | FileHelpRelativePath |
const string | FileHelpStandardPath |
const string | FileHelpCurrentDirectory |
const string | FileHelpCurrentDirectory1 |
bool | _appFileCommandsInitialized = false |
List< string > | AppCryptoNames = new List<string>() |
List of installed cryptographic command names. More... | |
List< string > | AppCryptoHelpStrings = new List<string>() |
List of help strings corresponding to installed cryptographic commands. More... | |
List< CommandMethod > | AppCryptoMethods = new List<CommandMethod>() |
List of methods used to perform cryptographic commmands. More... | |
const string | CryptoHelpGetFileHash |
const string | CryptoHelpCheckSum |
const string | CryptoHelpDecryptBasic = CryptoDecryptBasic + CryptoHelpEncryptBasicPart |
const string | CryptoHelpEncryptBasic = CryptoEncryptBasic + CryptoHelpEncryptBasicPart |
const string | CryptoHelpDecryptPlain = CryptoDecryptPlain + CryptoHelpEncryptBasicPart |
const string | CryptoHelpEncryptPlain = CryptoEncryptPlain + CryptoHelpEncryptBasicPart |
const string | CryptoHelpEncryptBasicPart |
const string | CryptoHelpGetKey = CryptoGetKey + CryptoHelpGetKeyLastPart |
const string | CryptoHelpGetInitializationVector = CryptoGetInitializationVector + CryptoHelpGetKeyLastPart |
const string | CryptoHelpGetInitializationVector1 = CryptoGetInitializationVector1 + CryptoHelpGetKeyLastPart |
const string | CryptoHelpGetSalt = CryptoGetSalt + CryptoHelpGetKeyLastPart |
const string | CryptoHelpGetKeyLastPart |
const string | CryptoHelpTimeKeyGeneration |
const string | CryptoHelpConvert |
const string | CryptoHelpAsymKeyInfo |
const string | CryptoHelpCertStoreInfo |
const string | CryptoHelpCertInfo |
const string | CryptoHelpAddCertificate |
const string | CryptoHelpRemoveCertificate |
const string | CryptoHelpAsymTest |
const string | CryptoHelpCleanFiles |
bool | _appCryptoCommandsInitialized = false |
List< string > | AppSystemNames = new List<string>() |
List of installed system related command names. More... | |
List< string > | AppSystemHelpStrings = new List<string>() |
List of help strings corresponding to installed system related commands. More... | |
List< CommandMethod > | AppSystemMethods = new List<CommandMethod>() |
List of methods used to perform system related commmands. More... | |
const string | SystemHelpRuntimeVersion = SystemRuntimeVersion + " : Prints version of the runtime environment that application runs on." |
const string | SystemHelpComputerName = SystemComputerName + " : Prints and returns the current computer name." |
const string | SystemHelpDomainName = SystemDomainName + " : Prints and returns the current domain name." |
const string | SystemHelpIpAddress = SystemIpAddress + " : Prints and returns IP address of the current computer." |
const string | SystemHelpUserName = SystemUserName + " : Prints and returns the current user name." |
const string | SystemHelpSystemInfo = SystemSystemInfo + " : Prints and returns basic system info." |
const string | SystemHelpMACAddress = SystemMACAddress + " : Prints and returns the current domain name." |
bool | _appSystemCommandsInitialized = false |
List< string > | AppAssemblyNames = new List<string>() |
List of installed assemblies related command names. More... | |
List< string > | AppAssemblyHelpStrings = new List<string>() |
List of help strings corresponding to installed assembly related commands. More... | |
List< CommandMethod > | AppAssemblyMethods = new List<CommandMethod>() |
List of methods used to perform assembly related commmands. More... | |
const string | AssemblyHelpInfo |
const string | AssemblyHelpInfo1 |
const string | AssemblyHelpResources |
const string | AssemblyHelpResources1 |
const string | AssemblyHelpResourcesEmbedded |
const string | AssemblyHelpResourcesResx |
const string | AssemblyHelpReferenced |
const string | AssemblyHelpReferenced1 = AssemblyHelpReferenced |
const string | AssemblyHelpLoaded = AssemblyLoaded + @" : Prints all loaded assemblies." |
const string | AssemblyHelpLoaded1 = AssemblyHelpLoaded |
const string | AssemblyHelpLoad |
const string | AssemblyHelpLoad1 = AssemblyHelpLoad |
const string | AssemblyHelpInfoLoad |
const string | AssemblyHelpInfoLoad1 = AssemblyHelpInfoLoad |
bool | _appAssemblyCommandsInitialized = false |
List< string > | AppProcessNames = new List<string>() |
List of installed process-related command names. More... | |
List< string > | AppProcessHelpStrings = new List<string>() |
List of help strings corresponding to installed process commands. More... | |
List< CommandMethod > | AppProcessMethods = new List<CommandMethod>() |
List of methods used to perform process-related commmands. More... | |
const string | ProcessHelpListProcesses |
const string | ProcessHelpListApplications |
const string | ProcessHelpListApplicationsByWindow |
const string | ProcessHelpKillProcesses |
const string | ProcessHelpKillApplications |
const string | ProcessHelpKillApplicationsByWindow |
bool | _appProcessCommandsInitialized = false |
List< string > | AppDataStructuresNames = new List<string>() |
List of installed data structure - related demo command names. More... | |
List< string > | AppDataStructuresHelpStrings = new List<string>() |
List of help strings corresponding to the installed data structure - related demo commands. More... | |
List< CommandMethod > | AppDataStructuresMethods = new List<CommandMethod>() |
List of methods used to perform data structure - related demo commmands. More... | |
bool | _appDataStructuresCommandsInitialized = false |
![]() | |
string | _embeddedCommandName = null |
int | _outputLevel = DefaultOutputLevel |
ICommandLineApplicationInterpreter | _script_interpreter |
Properties | |
virtual string | ParentWorkingDirectory [get] |
Returns parent directory of the working directory. Delegated to Utilities.ParentWorkingDirectoryPath More... | |
virtual string | WorkingDirectoryName [get, protected set] |
Name of the working directory. More... | |
virtual string | WorkingDirectoryPath [get, protected set] |
Path of the application's working directory. More... | |
virtual string | SolutionFileName [get, set] |
Name of the file where solution is written to. More... | |
virtual string | SolutionFilePath [get, set] |
Path to the solution file. More... | |
virtual string | LogFileName [get, set] |
Name of the file where notes on operation can be logged. More... | |
virtual string | LogFilePath [get, set] |
Path to the log file where notes on operations can be logged. More... | |
TextWriter | LogWriter [get, protected set] |
File writer used for logging notes on operation of the application. More... | |
![]() | |
virtual bool | IsAddRunFileByScriptCommand [get, set] |
Whether or not the Run command is installed on the script's interpreter. More... | |
![]() | |
string | EmbeddedCommandName [get, set] |
Command that was used to launch the current embedded application script. More... | |
object | Lock [get] |
This object's central lock object to be used by other object. Do not use this object for locking in class' methods, for this you should use InternalLock. More... | |
string[] | InitializationArguments [get, set] |
Arguments used by the initialization method. WARNING: arguments can only be set before initialization is performed. Initialization is performed either implicitly at the first call to the Run method or explicitly by calling the Initialize method. More... | |
virtual bool | IsInitialized [get, protected set] |
Whether the object has been initialized or not. More... | |
static int | DefaultOutputLevel [get, set] |
int | OutputLevel [get, set] |
Level of output to console produced by some operations of the current object. More... | |
virtual ICommandLineApplicationInterpreter | Script_Interpreter [get, protected set] |
Script's internal interpreter that takes care for execution of installed internal commands. More... | |
SortedList< string, string > | Script_CommandHelpStrings [get] |
Contains help strings associated with script commands installed on interpreter. More... | |
![]() | |
string | EmbeddedCommandName [get, set] |
Command that was used to launch the current embedded application script. More... | |
string[] | InitializationArguments [get, set] |
Arguments used by the initialization method. More... | |
bool | IsInitialized [get] |
Whether the object has been initialized or not. More... | |
![]() | |
object | Lock [get] |
Private Attributes | |
TextWriter | _logWriter |
Internal script for running embedded applications.
This script will contain examples that are prepared for Marko Petek by Igor Gresovnik.
In the applications that have the command-line interpreter, embedded applications from this class can typically be run in the following way:
AppName Internal IG.Script.AppShellExt CommandName arg1 arg2 ...
where AppName is the application name, IG.Script.AppBase is the full name of the script class that contains embedded applications, CommandName is name of the command that launches embedded application, and arg1, arg2, etc. are command arguments for the embedded application.
$A Igor Jan01;
|
inline |
|
inlineprotectedvirtual |
Initializes a text writer used for logging.
Initialization consists of writing introductory text that includes the current time.
writer | Logging text writer that is initialized. |
|
inline |
Closes the file writer used for logging, and thus unlocks teh underlyig file so that other programs dcan use it.
|
inlinevirtual |
Adds application commands to the application interpreter.
interpreter | Interpreter where commands are executed. |
helpStrings | List containg help strings. |
Reimplemented from IG.Script.AppExtBase.
|
inline |
Runs some graphics examples.
arguments | Array of command-line arguments. |
References IG.Gr3d.VtkPlotBase.ExampleCurvePlotLissajous(), IG.Gr3d.VtkPlotBase.ExampleCustomSurfaceComparison(), IG.Gr.PlotterZedGraph.ExampleLissajous(), IG.Gr3d.VtkPlotBase.ExampleSurfacePlotManualScaled(), IG.Gr.PlotterZedGraph.ExempleSinePlots(), and IG.Lib.LoadableScriptBase.Run().
|
inline |
Runs some vector examples.
arguments | Array of command-line arguments. |
References IG.Num.VectorBase.Multiply(), and IG.Num.VectorBase.ScalarProduct().
|
inline |
Example for defining custom functions.
arguments | Command arguments. |
References IG.Num.Func.GetQuadratic(), IG.Num.IRealFunction.Tabulate(), and IG.Num.RealFunctionBase.Tabulate().
|
inline |
Code in this method helps the user locate script classes and their appropriate methods that execute particular examples via the "Internal" interpreter command.
Instructions for locating the code of interest:
* Anywhere in the code, declare a variable of the correspoonding script class. Full class name is precisely the argumet that follows the "Internal" command or argument when the command is launched through interpreter.
* Navigate to the definition of that class.
* Search for the string that is the internal command. This string is usually assigned to some constant.
* By searching where that constant is referenced (you can perform usual string search within the script class, or right-click constant name and chose "Find All References"), locate the position where command is installed on the script's interpreter. This is usually done by the LoadableScriptBase.Script_AddCommand method.
One of the arguments of the method that installs the command is the method that actually executes the command. Navigate to that method (right-click, select "Go To Definition"), and in the body of the method you will find the code behind the interpreter command. Beside the pure code, there may be some auxiliary stuff, e.g. for acquisition of interpreter arguments.
Warnings:
* Sometimes the command is not defined directly in the script class that is loaded to execte the command (i.e. the class whose name follows the "Internal" keyword in the interpreter command), but it is defined and/or installed in one of the classes from which this class derives (inheritance!). Therefore, if you don't find the appropriate interpreter command in the expected class, check also down the inheritance hierarchy, i.e in the class inherited by the expected class, then in the class inherited by that class, etc.
* Nested commands: Some script commands are nested, i.e. one command contains a number of subcommands. In this case, the method you are looking for is associated with the subcommand rather than the main command.
Example:
In the following command:
Shell Internal IG.Script.ScriptGraphics2dBase Graph CurvePlotLissajous 8 10
"Graph" is the main command of the IG.Script.ScriptGraphics2dBase script class, but it contains several nested commands, and "CurvePlotLissajous" is the nested command that dues the actual job of plotting the Lissajous curves. Therefore, this is the string you must search for within the script class. The second occurrence of the string is where the string is assigned to the IG.Script.ScriptGraphics2dBase.GraphCurvePlotLissajous constant, and by searching for references to this constant within the class, you quickly find the place where the command is installed. The corresponding line of code looks something like this:
AddGraphCommand(GraphCurvePlotLissajous, GraphFunctionCurvePlotLissajous, GraphHelpCurvePlotLissajous);
The second argument is the method that actually does the job of plotting Lissajous curves, terefore you can just right-click on this argument and select "Go To Definition."
arguments | Command arguments. |
const string IG.Script.AppIgorGresovnik.DefaultWorkingDirectoryName = "Petek_Diploma" |
Default name of the working directory for Marko Petek's graduate thesis.
const string IG.Script.AppIgorGresovnik.DefaultSolutionFileName = "Solution.txt" |
Default name of the file where solution is written.
const string IG.Script.AppIgorGresovnik.DefaultLogFileName = "Log.txt" |
Default name of the application's log file.
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
private |
|
protected |
const string IG.Script.AppIgorGresovnik.ConstExGraphics = "ExGraphics" |
Name of the command that runns the main thesis application.
const string IG.Script.AppIgorGresovnik.ConstHelpExGraphics = "Customized function for running some examples." |
const string IG.Script.AppIgorGresovnik.ConstExVector = "ExVector" |
Name of the command that runns the main thesis application.
const string IG.Script.AppIgorGresovnik.ConstHelpExVector = "Customized function for running some vector examples." |
const string IG.Script.AppIgorGresovnik.ConstExFunction = "ExFunction" |
Name of the command that runns the main thesis application.
const string IG.Script.AppIgorGresovnik.ConstHelpExFunction = "Customized function for running some real function examples." |
const string IG.Script.AppIgorGresovnik.ConstLocateScriptCode = "LocateScriptCode" |
Name of the command that runs the snippet of code used for location of script classes.
const string IG.Script.AppIgorGresovnik.ConstHelpLocateScriptCode = "Runs auxiliary code containing instructions for locating script code." |
|
get |
Returns parent directory of the working directory. Delegated to Utilities.ParentWorkingDirectoryPath
|
getprotected set |
Name of the working directory.
|
getprotected set |
Path of the application's working directory.
|
getset |
Name of the file where solution is written to.
|
getset |
Path to the solution file.
|
getset |
Name of the file where notes on operation can be logged.
|
getset |
Path to the log file where notes on operations can be logged.
|
getprotected set |
File writer used for logging notes on operation of the application.
Getter always provides an initialized file writer that can be immediately used for writing.
Setting to null closes the log file writer, meaning also that all contents are flushed. In this case, the next call togetter will open a new writer and re-initialize it, together with writing introductory text by the InitLogWriter method.