Interface CompositeProjectionValueStep<N extends CompositeProjectionOptionsStep<?,T>,T>
- Type Parameters:
N- The next step if a method other thanmulti()is called, i.e. the return type of methods defined inCompositeProjectionOptionsStepwhen called directly on this object.T- The type of composed projections.
- All Superinterfaces:
CompositeProjectionOptionsStep<N,,T> ProjectionFinalStep<T>
public interface CompositeProjectionValueStep<N extends CompositeProjectionOptionsStep<?,T>,T>
extends CompositeProjectionOptionsStep<N,T>
The step in a composite projection definition
where the projection (optionally) can be marked as multi-valued (returning Lists),
and where optional parameters can be set.
By default (if multi() is not called), the projection is single-valued.
-
Method Summary
Methods inherited from interface org.hibernate.search.engine.search.projection.dsl.ProjectionFinalStep
toProjection
-
Method Details
-
multi
CompositeProjectionOptionsStep<?,List<T>> multi()Defines the projection as multi-valued, i.e. returningList<T>instead ofT.Calling
multi()is mandatory forobject projectionson multi-valued object fields, otherwise the projection will throw an exception upon creating the search query.Calling
multi()onbasic composite projectionsis generally not useful: the only effect is that projected values will be wrapped in a one-elementList.- Returns:
- A new step to define optional parameters for the projection.
-