operator + method

Validator<T> operator +(
  1. Validator<T> other
)

Combines this validator with another using AND logic (alias for combine).

Alternative syntax for combining validators where both must pass.

Example:

final validator = requiredValidator + lengthValidator;

Implementation

Validator<T> operator +(Validator<T> other) {
  return combine(other);
}