Class PropertyDescriptor.ConstrainedSetValidator

java.lang.Object
org.apache.nifi.components.PropertyDescriptor.ConstrainedSetValidator
All Implemented Interfaces:
Validator
Enclosing class:
PropertyDescriptor

private static final class PropertyDescriptor.ConstrainedSetValidator extends Object implements Validator
  • Field Details

  • Constructor Details

    • ConstrainedSetValidator

      private ConstrainedSetValidator(Collection<AllowableValue> validValues)
      Constructs a validator that will check if the given value is in the given set.
      Parameters:
      validValues - values which are acceptible
      Throws:
      NullPointerException - if the given validValues is null
  • Method Details

    • validate

      public ValidationResult validate(String subject, String input, ValidationContext context)
      Specified by:
      validate in interface Validator
      Parameters:
      subject - what is being validated
      input - the string to be validated
      context - the ValidationContext to use when validating properties
      Returns:
      ValidationResult