The FacetOptions Class

Class FacetOptions provides options for processing facet results of a query.

FacetOptions is defined in the google.appengine.api.search module.

Introduction

Class FacetOptions provides options for processing facet results of a query. Options include number of facets to discover, number of values for each facet and the depth of the result to be considered for facet computation.

Constructor

The constructor for class FacetOptions is defined as follows:

facet_option = FacetOptions(discovery_limit=5, discovery_value_limit=None, depth=None)

Specify options for processing facet results of a query.

Arguments

discovery_limit
discovery_value_limit
depth

Result value

A new instance of class FacetOptions.

Exceptions

TypeError

If an unknown attribute is passed.

ValueError

If any of the parameters have invalid values (e.g., a negative depth).

Properties

An instance of class FacetOptions has the following properties:

discovery_limit

Number of facets to discover if facet discovery is turned on. If None, discover facets will be disabled.

discovery_value_limit

Number of values to be discovered for each of the top discovered facets.

depth

Number of documents in query results to evaluate to gather facet information.