/// <summary> /// Lists the script accessible methods /// </summary> public void listMethods() { StringBuilder stringBuilder = null; foreach (MethodInfo method in this.methods) { stringBuilder = new StringBuilder(); stringBuilder.Append(method.Name); // retrieve the methods parameter information to add to the output ScriptUtils.getMethodParameterInfo(method.GetParameters(), ref stringBuilder); Console.WriteLine(stringBuilder.ToString()); } }
/// <summary> /// Displays general help such as the command identifier, high level commands, and registered objects /// </summary> public void help() { Console.WriteLine("\nObject invoker is: \"" + COMMAND_IDENTIFIER + "\""); Console.WriteLine("Log file is: " + this.logFile); Console.WriteLine("Lock on to objects enabled: " + this.lockOnEnabled); Console.WriteLine("High level commands:"); StringBuilder stringBuilder = null; MethodInfo method = null; foreach (string command in HIGH_LEVEL_COMMANDS) { stringBuilder = new StringBuilder(command); method = this.GetType().GetMethod(command); ScriptUtils.getMethodParameterInfo(method.GetParameters(), ref stringBuilder); Console.WriteLine(stringBuilder.ToString()); } Console.WriteLine("Registered Objects: "); foreach (RegisteredObject registeredObject in this.registeredObjects) { Console.WriteLine(registeredObject.ReferenceName); } }