vertx/src/main/java/eu/internetofus/common/vertx/OpenAPIValidator.java
/**
   * Check the specification field that indicates that a maximum field of a type
   * is valid.
   *
   * @param maxName      name of the maximum property to check.
   * @param minName      name of the minimum property to check.
   * @param expectedType for the minimum field.
   * @param env          validation environment to use.
   *
   * @throws ValidationErrorException if it is not an instance of.
   */
Check the specification field that indicates that a maximum field of a type
is valid.

@param maxName      name of the maximum property to check.
@param minName      name of the minimum property to check.
@param expectedType for the minimum field.
@param env          validation environment to use.

@throws ValidationErrorException if it is not an instance of.
Check the specification field that indicates that a maximum field of a type is valid . @param maxName name of the maximum property to check . @param minName name of the minimum property to check . @param expectedType for the minimum field . @param env validation environment to use . @throws ValidationErrorException if it is not an instance of .
private static void checkMaxOf(@NotNull final String maxName, @NotNull final String minName,
      @NotNull final String expectedType, @NotNull final SpecificationEnvironment env) throws ValidationErrorException {
    final var value = env.specification.getValue(maxName);
    if (value instanceof Integer || value instanceof Long) {
      final var max = ((Number) value).longValue();
      final var min = env.specification.getLong(minName, 0l);
      if (max < min) {
        throw env.notValid(maxName, "The value must be equal to or greater than '" + min + "'.");
      } else {
        checkIfTypeIs(maxName, env, expectedType);
      }
    } else {
      throw env.notValid(maxName, "Expecting an 'integer' value.");
    }
  }
private static void checkMaxOf ( @ NotNull final String maxName , @ NotNull final String minName , @ NotNull final String expectedType , @ NotNull final SpecificationEnvironment env ) throws ValidationErrorException { final var value = env . specification . getValue ( maxName ) ; if ( value instanceof Integer || value instanceof Long ) { final var max = ( ( Number ) value ) . longValue ( ) ; final var min = env . specification . getLong ( minName , 0l ) ; if ( max < min ) { throw env . notValid ( maxName , "The value must be equal to or greater than '" + min + "'." ) ; } else { checkIfTypeIs ( maxName , env , expectedType ) ; } } else { throw env . notValid ( maxName , "Expecting an 'integer' value." ) ; } }
Check the specification field that indicates that a maximum field of a type
 is valid.
Check the specification field that indicates that a maximum field of a type is valid .