code: public <T> void addRangeFilter(String field, T minValue, T maxValue){
          if(minValue instanceof String){
              if(StringUtils.isEmpty(field) || StringUtils.isEmpty((String) minValue) || StringUtils.isEmpty((String) maxValue)){
                  throw new IllegalArgumentException("Expected all attributes to be non empty");
              }
              filterQueries.put(field, new FilterFieldRange(field, (String)minValue, (String)maxValue));
          }else if (minValue instanceof Date){
              filterQueries.put(field, new FilterFieldRangeDate(field, (Date)minValue, (Date)maxValue));
          }
          else if (minValue instanceof Integer){
              filterQueries.put(field, new FilterFieldRange.FilterFieldRangeInteger(field, (Integer)minValue, (Integer)maxValue));
          }
      }
docs: Alternative to filter, which accepts a range of items to filter.
  For instance, the field might be a year, and minValue 2000 and maxValue 2009
  this filter will return records between the supplied ranges (inclusive)
  @param field
  @param minValue
  @param maxValue