org.apache.lucene.facet

## Class FacetQuery

- java.lang.Object
- - org.apache.lucene.search.Query
  - - org.apache.lucene.search.TermQuery
    - - org.apache.lucene.facet.FacetQuery

-     public class FacetQuery
      extends TermQuery

  A term `Query` over a `FacetField`.

  NOTE:This helper class is an alternative to `DrillDownQuery` especially in cases where you don't intend to use `DrillSideways`

  WARNING: This API is experimental and might change in incompatible ways in the next release.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `FacetQuery(FacetsConfig facetsConfig, String dimension, String... path)` Creates a new `FacetQuery` filtering the query on the given dimension.
    `FacetQuery(String dimension, String... path)` Creates a new `FacetQuery` filtering the query on the given dimension.

  - ### Method Summary

    - ### Methods inherited from class org.apache.lucene.search.TermQuery

      `createWeight, equals, getTerm, getTermStates, hashCode, toString, visit`

    - ### Methods inherited from class org.apache.lucene.search.Query

      `classHash, rewrite, sameClassAs, toString`

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### FacetQuery

          public FacetQuery(FacetsConfig facetsConfig,
                            String dimension,
                            String... path)

      Creates a new `FacetQuery` filtering the query on the given dimension.

    - #### FacetQuery

          public FacetQuery(String dimension,
                            String... path)

      Creates a new `FacetQuery` filtering the query on the given dimension.

      NOTE:Uses FacetsConfig.DEFAULT_DIM_CONFIG.

Copyright © 2000-2020 Apache Software Foundation. All Rights Reserved.