A keyword or a keyword sequence can have a combined total of 20 input and output parameters. This topic describes how you can handle these parameters with Silk4J.
In the Keyword-Driven Test Editor, you can view any defined parameters for a keyword or a keyword sequence and you can edit the parameter values.
In the Keywords window, you can see which parameters are assigned to a keyword or a keyword sequence when you hover the mouse cursor over the keyword or keyword sequence.
You can define and use input parameters for keywords in the same way as for any other test method.
@Keyword public void setUserDetails(String userName, String password) { ... }
You can define a return value or one or more output parameters for a keyword. You can also use a combination of a return value and one ore more output parameters.
@Keyword public String getText() { return "text"; }
@Keyword public void getUserDetails(OutParameter userName, OutParameter password) { userName.setValue("name"); password.setValue("password"); }
You can define or edit the parameters for a keyword sequence in the Parameters dialog box, which you can open if you click Parameters in the Keyword Sequence Editor.