Class FacetQueryChecker (2.0.0)

public final class FacetQueryChecker

Provides checks for faceted search related query options.

Inheritance

java.lang.Object > FacetQueryChecker

Static Methods

checkDepth(Integer value)

public static Integer checkDepth(Integer value)

Checks that a facet depth option is valid. The facet depth must be greater than 0 and less than SearchApiLimits#FACET_MAXIMUM_DEPTH.

Parameter
Name Description
value Integer

the facet depth option to check

Returns
Type Description
Integer

the facet depth

checkDiscoveryLimit(int value)

public static int checkDiscoveryLimit(int value)

Checks that a discovery limit is valid. The value must be greater than 0 and less than SearchApiLimits#FACET_MAXIMUM_DISCOVERY_LIMIT.

Parameter
Name Description
value int

the discovery limit to check

Returns
Type Description
int

the discovery limit

checkDiscoveryValueLimit(Integer value)

public static Integer checkDiscoveryValueLimit(Integer value)

Checks whether discovery value limit option is valid. The discovery value limit must be greater than 0 and less than SearchApiLimits#FACET_MAXIMUM_VALUE_LIMIT.

Parameter
Name Description
value Integer

the discovery value limit to check

Returns
Type Description
Integer

the discovery value limit

checkFacetValue(String value)

public static String checkFacetValue(String value)

Checks that a value constraint is valid. The Value length must be at least 1 and less than SearchApiLimits#MAXIMUM_ATOM_LENGTH.

Parameter
Name Description
value String

the value constraint to check

Returns
Type Description
String

the value constraint

checkValid(SearchServicePb.SearchParams params)

public static SearchServicePb.SearchParams checkValid(SearchServicePb.SearchParams params)

Checks whether all options related to faceted search are valid.

Parameter
Name Description
params com.google.appengine.api.search.proto.SearchServicePb.SearchParams

the SearchParams to check

Returns
Type Description
com.google.appengine.api.search.proto.SearchServicePb.SearchParams

this checked SearchParams

checkValueLimit(Integer value)

public static Integer checkValueLimit(Integer value)

Checks whether a value limit option is valid. The value limit must be greater than 0 and less than SearchApiLimits#FACET_MAXIMUM_VALUE_LIMIT.

Parameter
Name Description
value Integer

the value limit to check

Returns
Type Description
Integer

the value limit