custom static method
Creates a custom validation rule using the given func.
The message is returned if validation fails.
Implementation
static ValidationRule custom(
ValidationFunction func, {
required String message,
}) {
return ValidationRule(func, message);
}