@Test(expected = IllegalArgumentException.class) public final void testRequestResponseOKAddNull() { final RequestResponseOK requestResponseOK = new RequestResponseOK(); requestResponseOK.addAllResults(null); }
public RequestResponseOK<T> addAllResults(List<T> resultList) { ParametersChecker.checkParameter("Result list is a mandatory parameter", resultList); results.addAll(resultList); hits.setSize(hits.getSize() + resultList.size()); hits.setTotal(hits.getSize()); return this; }
RequestResponseOK extends RequestResponse<T> { public RequestResponseOK<T> addAllResults(List<T> resultList) { ParametersChecker.checkParameter("Result list is a mandatory parameter", resultList); results.addAll(resultList); hits.setSize(hits.getSize() + resultList.size()); hits.setTotal(hits.getSize()); return this; } }
RequestResponseOK extends RequestResponse<T> { public RequestResponseOK<T> addAllResults(List<T> resultList) { ParametersChecker.checkParameter("Result list is a mandatory parameter", resultList); results.addAll(resultList); hits.setSize(hits.getSize() + resultList.size()); hits.setTotal(hits.getSize()); return this; } RequestResponseOK();  RequestResponseOK(JsonNode query); }
RequestResponseOK extends RequestResponse<T> { public RequestResponseOK<T> addAllResults(List<T> resultList) { ParametersChecker.checkParameter("Result list is a mandatory parameter", resultList); results.addAll(resultList); hits.setSize(hits.getSize() + resultList.size()); hits.setTotal(hits.getSize()); return this; } RequestResponseOK();  RequestResponseOK(JsonNode query); RequestResponseOK<T> addResult(T result); RequestResponseOK<T> addAllResults(List<T> resultList); RequestResponseOK<T> addFacetResult(FacetResult facetResult); RequestResponseOK<T> addAllFacetResults(List<FacetResult> facetResultList); DatabaseCursor getHits(); RequestResponseOK<T> setHits(DatabaseCursor hits); RequestResponseOK<T> setHits(long total, int offset, int limit); RequestResponseOK<T> setHits(long total, int offset, int limit, int size, String scrollId); RequestResponseOK<T> setHits(long total, int offset, int limit, int size); RequestResponseOK<T> setTotal(long total); RequestResponseOK<T> setScrollId(String scrollId); List<FacetResult> getFacetResults(); List<T> getResults(); JsonNode getQuery(); @JsonIgnore T getFirstResult(); RequestResponseOK<T> setQuery(JsonNode query); @JsonIgnore boolean isEmpty(); static RequestResponseOK<JsonNode> getFromJsonNode(JsonNode node); static RequestResponseOK<T> getFromJsonNode(JsonNode node, Class<T> clazz); @JsonIgnore List<JsonNode> getResultsAsJsonNodes(); RequestResponseOK<T> setHttpCode(int httpCode); @Override Response toResponse(); }
RequestResponseOK extends RequestResponse<T> { public RequestResponseOK<T> addAllResults(List<T> resultList) { ParametersChecker.checkParameter("Result list is a mandatory parameter", resultList); results.addAll(resultList); hits.setSize(hits.getSize() + resultList.size()); hits.setTotal(hits.getSize()); return this; } RequestResponseOK();  RequestResponseOK(JsonNode query); RequestResponseOK<T> addResult(T result); RequestResponseOK<T> addAllResults(List<T> resultList); RequestResponseOK<T> addFacetResult(FacetResult facetResult); RequestResponseOK<T> addAllFacetResults(List<FacetResult> facetResultList); DatabaseCursor getHits(); RequestResponseOK<T> setHits(DatabaseCursor hits); RequestResponseOK<T> setHits(long total, int offset, int limit); RequestResponseOK<T> setHits(long total, int offset, int limit, int size, String scrollId); RequestResponseOK<T> setHits(long total, int offset, int limit, int size); RequestResponseOK<T> setTotal(long total); RequestResponseOK<T> setScrollId(String scrollId); List<FacetResult> getFacetResults(); List<T> getResults(); JsonNode getQuery(); @JsonIgnore T getFirstResult(); RequestResponseOK<T> setQuery(JsonNode query); @JsonIgnore boolean isEmpty(); static RequestResponseOK<JsonNode> getFromJsonNode(JsonNode node); static RequestResponseOK<T> getFromJsonNode(JsonNode node, Class<T> clazz); @JsonIgnore List<JsonNode> getResultsAsJsonNodes(); RequestResponseOK<T> setHttpCode(int httpCode); @Override Response toResponse(); static final String TAG_RESULTS; static final String TAG_FACET_RESULTS; static final String TAG_CONTEXT; }