protected void validateRange()

in sources/src/main/java/com/google/solutions/jitaccess/catalog/policy/AbstractProperty.java [324:336]


  protected void validateRange(@Nullable String value) {
    super.validateRange(value);

    if (value != null && value.length() < this.minLength) {
      throw new IllegalArgumentException(
        String.format("The value for '%s' is too short", this.displayName()));
    }

    if (value != null && value.length() > this.maxLength) {
      throw new IllegalArgumentException(
        String.format("The value for '%s' is too long", this.displayName()));
    }
  }