helper.validate("number_argument", val > 0 && val < 100);
to ensure the argument value is in the specified range and force the application to terminate if the test fails, printing an adequate error message and usage information.
@param name the (case-sensitive) name of the argument to validate.
@param valid the boolean result of the validation test for the argument.
@return reference to this application helper, allowing command-chaining.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|