T-Plan Robot Enterprise 3.5.1
Build No. 3.5.1-20140411.1

com.tplan.robot.scripting.commands
Interface AdvancedCommandHandler

All Superinterfaces:
CommandHandler
All Known Implementing Classes:
AbstractFileResourceCommand, CompareToCommand, ConnectCommand, EvalCommand, ExcelCommand, ExecCommand, ExitCommand, FileCommand, ImageDoctorCommand, IncludeCommand, LogCommand, MouseCommand, PressCommand, ReportCommand, RunCommand, ScreenshotCommand, ScriptCommand, StepCommand, StringCommand, TimerCommand, TypeCommand, TypeLineCommand, VarfCommand, VariableCommand, WaitforCommand, WarningCommand

public interface AdvancedCommandHandler
extends CommandHandler

Interface allowing the commands to expose context dependent list of supported arguments, parameters and values. It is intended to help users design commands through the script editor and command wizard GUI components.


T-Plan Robot Enterprise, (C) 2009-2014 T-Plan Limited. All rights reserved.


Method Summary
 List getArguments(String command, ScriptingContext context)
          Get the list of supported arguments.
 List getParameters(String command, ScriptingContext context)
          Get the list of supported parameters.
 List getParameterValues(String paramName, String command, ScriptingContext context)
          Get values of a particular parameter.
 
Methods inherited from interface com.tplan.robot.scripting.commands.CommandHandler
addCommandListener, canRunWithoutConnection, execute, getCommandNames, getContextArgument, getContextAttributes, getContextShortcut, getStablePopupMenuItems, isGlobalPrerequisity, removeCommandListener, validate
 

Method Detail

getArguments

List getArguments(String command,
                  ScriptingContext context)
Get the list of supported arguments. For example, the Mouse command should return a list containing "click", "move" etc. Commands which have no argument and rely just on parameters (param=value) should return null.

Parameters:
command - the current command.
context - a context.
Returns:
list of supported argument values.

getParameters

List getParameters(String command,
                   ScriptingContext context)
Get the list of supported parameters. Command handlers are free to parse the current command and return a filtered list depending on what is already specified. Parameters in the list should be String instances. If they are other objects than String, they may or may not be handled well depending on what the GUI supports.

Parameters:
command - the current conmmand text (complete).
context - a context.
Returns:
list of supported parameter names.

getParameterValues

List getParameterValues(String paramName,
                        String command,
                        ScriptingContext context)
Get values of a particular parameter. This is to be used for parameters which have a fixed set of acceptable values. The command wizard typically displays the values as a list.

Parameters:
paramName - parameter name.
command - the current conmmand text (complete).
context - a context.
Returns:
list of supported parameter values.

T-Plan Robot Enterprise 3.5.1
Build No. 3.5.1-20140411.1