code: private void checkLimitRange(int limit) {
      int minLimit = offsetPaginationConfiguration.allowZeroLimit() ? 0 : 1;
  
      if (limit < minLimit || limit > offsetPaginationConfiguration.maxLimit()) {
        throw InvalidParameterException.create(
            "Invalid value for '" + this.getParameterFieldName() + "': " + limit
                + "  - value between " + minLimit + " and " + offsetPaginationConfiguration.maxLimit()
                + " is required.");
      }
    }
docs: Ensures that the limit is in the allowed range.
  
  @param limit the parsed limit value to check the range of
  @throws InvalidParameterException if the limit value is less outside of the allowed range