boolean isLast() {
      Preconditions.checkState(result != null, "result not supposed to be null");
      return result.isEmpty() || count >= limit;
    }
Max number of documents to fetch
criteria/elasticsearch/src/org/immutables/criteria/elasticsearch/Scrolling.java