Line: 1 to 1 | ||||||||
---|---|---|---|---|---|---|---|---|
Adding Tools to HIPE | ||||||||
Line: 115 to 115 | ||||||||
p.parameterValidator = MyVal() | ||||||||
Added: | ||||||||
> > | Also, a prebuilt confirming (always returns true) Validator is available in TaskParameter :
parameter.setParameterValidator(TaskParameter.TRUE_VALIDATOR); | |||||||
Note how the validation logic is now within the parameter validation block, rather than in the preamble or execution block of your task. One advantage is that the execution block of your task can concentrate on the core algorithm. A validator is mandatory for the task to appear in the Applicable category of the Tasks view. If your task really is very general and applies to a given variable type with no exceptions, write a dummy validator that always accepts input values. |