Interface AssociatedContentQuery<T>
-
- Type Parameters:
T- the type of the results returned by the Query
public interface AssociatedContentQuery<T>AnAssociatedContentQueryis returned by theAssociatedContentServiceand can be used to trill down the result set further.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.Iterator<T>execute()Executes theAssociatedContentQueryreturning anIteratoron the result set.AssociatedContentQuery<T>withLimit(long limit)Set a limit to theAssociatedContentQuery.AssociatedContentQuery<T>withOffset(long offset)Set an offset to theAssociatedContentQuery.<N> AssociatedContentQuery<N>withTransformer(QueryResultTransformer<N> transformer)Sets a custom transformer for this query results.
-
-
-
Method Detail
-
withLimit
AssociatedContentQuery<T> withLimit(long limit)
Set a limit to theAssociatedContentQuery.If not called, the limit is
Long.MAX_VALUE.- Parameters:
limit- the limit- Returns:
- the
AssociatedContentQueryitself
-
withOffset
AssociatedContentQuery<T> withOffset(long offset)
Set an offset to theAssociatedContentQuery.If not called, the offset is
0- Parameters:
offset- the offset- Returns:
- the
AssociatedContentQueryitself
-
execute
java.util.Iterator<T> execute()
Executes theAssociatedContentQueryreturning anIteratoron the result set. This iterator may contain all query hits or not, depending if a hit can be converted to the result type of theAssociatedContentQuery.- Returns:
- an
Iteratorof a hits that can be converted to the result type,nullvalues filtered out
-
withTransformer
<N> AssociatedContentQuery<N> withTransformer(QueryResultTransformer<N> transformer)
Sets a custom transformer for this query results. This would transform the results from typeTto typeNIf not called, the default transformer is used.
- Type Parameters:
N- the new result type- Parameters:
transformer- aQueryResultTransformerimplementation- Returns:
- an
AssociatedContentQueryobject
-
-