wt.rule.algorithm
Class StringConstant
java.lang.Object
wt.rule.algorithm.StringConstant
- All Implemented Interfaces:
- RuleAlgorithm
- public class StringConstant
- extends Object
- implements RuleAlgorithm
An very simple algorithm that takes a single String
argument and returns it unmodified.
Supported API: false
Extendable: false
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RESOURCE
private static final String RESOURCE
- See Also:
- Constant Field Values
CLASSNAME
private static final String CLASSNAME
StringConstant
public StringConstant()
calculate
public Object calculate(Object[] args,
WTContainerRef container)
throws WTException
- Execute the algorithm using the specified arguments. Return the result.
Supported API: false
- Specified by:
calculate
in interface RuleAlgorithm
- Parameters:
args
- the arguments for the algorithmcontainer
- the container to use for object lookups
- Returns:
- Object
- Throws:
WTException
validateArgs
public void validateArgs(String[] args)
throws InvalidAlgorithmArgumentException
- Validate the arguments. Throw an
InvalidAlgorithmArgumentException
if any of the arguments are invalid.
Supported API: false
- Specified by:
validateArgs
in interface RuleAlgorithm
- Parameters:
args
- the string args from the XML
- Throws:
InvalidAlgorithmArgumentException