Package org.mozilla.zest.core.v1
Class ZestActionInvoke
- java.lang.Object
-
- org.mozilla.zest.core.v1.ZestElement
-
- org.mozilla.zest.core.v1.ZestStatement
-
- org.mozilla.zest.core.v1.ZestAction
-
- org.mozilla.zest.core.v1.ZestActionInvoke
-
public class ZestActionInvoke extends ZestAction
The Class ZestActionPrint.
-
-
Field Summary
-
Fields inherited from class org.mozilla.zest.core.v1.ZestElement
JSON_ELEMENT_TYPE
-
-
Constructor Summary
Constructors Constructor Description ZestActionInvoke()Instantiates a new zest action invoke.ZestActionInvoke(int index)Instantiates a new zest action invoke.ZestActionInvoke(String script, String variableName, List<String[]> parameters)Instantiates a new zest action invoke.ZestActionInvoke(String script, String variableName, List<String[]> parameters, String charset)Constructs aZestActionInvokewith the given data.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ZestActionInvokedeepCopy()Deep copy.StringgetCharset()Gets the name of the charset used for read operations (for example, read the script from the file or the output of the invoked program).List<String[]>getParameters()StringgetScript()StringgetVariableName()Stringinvoke(ZestResponse response, ZestRuntime runtime)Invoke.booleanisPassive()Checks if is passive.booleanisSameSubclass(ZestElement ze)Checks if is same subclass.voidsetCharset(String charset)Sets the name of the charset used for read operations (for example, read the script from the file or the output of the invoked program).voidsetParameters(List<String[]> parameters)voidsetScript(String script)voidsetVariableName(String variableName)-
Methods inherited from class org.mozilla.zest.core.v1.ZestStatement
getIndex, getNext, getPrevious, init, insertAfter, insertBefore, isEnabled, remove, setEnabled, setNext, setPrev
-
Methods inherited from class org.mozilla.zest.core.v1.ZestElement
getElementType, setElementType
-
-
-
-
Constructor Detail
-
ZestActionInvoke
public ZestActionInvoke()
Instantiates a new zest action invoke.
-
ZestActionInvoke
public ZestActionInvoke(int index)
Instantiates a new zest action invoke.- Parameters:
index- the index
-
ZestActionInvoke
public ZestActionInvoke(String script, String variableName, List<String[]> parameters)
Instantiates a new zest action invoke.- Parameters:
script- the name of the script or process to invoke.variableName- the name of the variable to assign the result of the invocation.parameters- the parameters for the script or the process.
-
ZestActionInvoke
public ZestActionInvoke(String script, String variableName, List<String[]> parameters, String charset)
Constructs aZestActionInvokewith the given data.- Parameters:
script- the name of the script or process to invoke.variableName- the name of the variable to assign the result of the invocation.parameters- the parameters for the script or the process.charset- the name of the charset used for read operations (for example, read the script or the output of the invoked program).- Since:
- 0.14.0
-
-
Method Detail
-
isSameSubclass
public boolean isSameSubclass(ZestElement ze)
Description copied from class:ZestElementChecks if is same subclass.- Overrides:
isSameSubclassin classZestAction- Parameters:
ze- the ze- Returns:
- true, if is same subclass
-
invoke
public String invoke(ZestResponse response, ZestRuntime runtime) throws ZestActionFailException
Description copied from class:ZestActionInvoke.- Specified by:
invokein classZestAction- Parameters:
response- the response- Returns:
- the string
- Throws:
ZestActionFailException- the zest action fail exception
-
getVariableName
public String getVariableName()
-
setVariableName
public void setVariableName(String variableName)
-
getScript
public String getScript()
-
setScript
public void setScript(String script)
-
getCharset
public String getCharset()
Gets the name of the charset used for read operations (for example, read the script from the file or the output of the invoked program).- Returns:
- the name of the charset.
- Since:
- 0.14.0
-
setCharset
public void setCharset(String charset)
Sets the name of the charset used for read operations (for example, read the script from the file or the output of the invoked program).- Parameters:
charset- the name of the charset.- Since:
- 0.14.0
-
deepCopy
public ZestActionInvoke deepCopy()
Description copied from class:ZestElementDeep copy.- Specified by:
deepCopyin classZestStatement- Returns:
- the zest element
-
isPassive
public boolean isPassive()
Description copied from class:ZestStatementChecks if is passive.- Specified by:
isPassivein classZestStatement- Returns:
- true, if is passive
-
-