Class CombiningValidator<T>

  • Type Parameters:
    T - the type to be validated.
    All Implemented Interfaces:
    Validator<T>

    public class CombiningValidator<T>
    extends Object
    implements Validator<T>
    This is a special validator that combines several validators into one. By default the validation stops after one invalid result has been found.
    • Constructor Detail

      • CombiningValidator

        public CombiningValidator​(List<Validator<T>> validators)
      • CombiningValidator

        public CombiningValidator​(Validator<T>... validators)
    • Method Detail

      • registerValidationListener

        public void registerValidationListener​(ValidationListener validationListener)
        Components that are interested in the result of the token validation can register a validation listener which is called whenever a token is validated. Listener must implement the ValidationListener interface.
        Parameters:
        validationListener - the listener to be added.
      • removeValidationListener

        public void removeValidationListener​(ValidationListener validationListener)
        Use this method to remove a registered listener so that it is not called anymore.
        Parameters:
        validationListener - the listener to be removed.