code: @Override
    public FacetResult[] getFacetResults() {
      if (facets == null || facets.isEmpty()) {
        return new FacetResult[0];
      }
      Collection<FacetResult> facetResults = facets.values();
      return facetResults.toArray(new FacetResult[facetResults.size()]);
    }
docs: Returns an array of facet results for this search.
  @return The facets array.