Class FilterQueryBuilder<T>
java.lang.Object
com.amilesend.tmdb.client.model.discover.filter.FilterQueryBuilder<T>
- Type Parameters:
T
- the type
Builder to construct a filter string that includes a delimited list of items. This allows for defined predicates
(i.e., "and", "or") to further define filter queries.
Example:
Example:
String providers = new FilterQueryBuilder("netflix", QueryBuilder.Type.ADD).append("hulu").build();
String genres = new FilterQueryBuilder("drama", QueryBuilder.Type.OR).append("horror").build();
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enum
Defines the predicate type for the delimited filter list. -
Constructor Summary
ConstructorsConstructorDescriptionFilterQueryBuilder
(T attribute, FilterQueryBuilder.Type type) Creates a newQueryBuilder
. -
Method Summary
-
Constructor Details
-
FilterQueryBuilder
Creates a newQueryBuilder
.- Parameters:
attribute
- the name of the attributetype
- the attribute type- See Also:
-
-
Method Details
-
append
Appends an attribute value to the list.- Parameters:
attribute
- the attribute value- Returns:
- the builder
-
build
Returns a new delimited string for the filter.- Returns:
- the list of attributes
-