Class FacetResult.Builder (2.0.0)

public static final class FacetResult.Builder

A builder of facet result. This is not thread-safe.

Inheritance

java.lang.Object > FacetResult.Builder

Methods

addValue(FacetResultValue value)

public FacetResult.Builder addValue(FacetResultValue value)

Add a value to this facet result.

Parameter
Name Description
value FacetResultValue

the value to add.

Returns
Type Description
FacetResult.Builder

this builder

build()

public FacetResult build()

Builds a facet result. The builder must at least have a name.

Returns
Type Description
FacetResult

the facet result built by this builder

setName(String name)

public FacetResult.Builder setName(String name)

Sets the name of this facet result that is a single facet name.

Parameter
Name Description
name String

The name of the facet for this facet result.

Returns
Type Description
FacetResult.Builder

this builder