Interface ExtendedSearchPredicateFactory<SR,S extends ExtendedSearchPredicateFactory<SR,?>>
- Type Parameters:
SR
- Scope root type.S
- The self type, i.e. the exposed type of this factory.
- All Superinterfaces:
SearchPredicateFactory
,TypedSearchPredicateFactory<SR>
- All Known Subinterfaces:
ElasticsearchSearchPredicateFactory<SR>
,LuceneSearchPredicateFactory<SR>
- All Known Implementing Classes:
AbstractSearchPredicateFactory
public interface ExtendedSearchPredicateFactory<SR,S extends ExtendedSearchPredicateFactory<SR,?>>
extends TypedSearchPredicateFactory<SR>
A base interface for subtypes of
TypedSearchPredicateFactory
allowing to
easily override the self type for all relevant methods.
Warning: Generic parameters of this type are subject to change, so this type should not be referenced directly in user code.
-
Method Summary
Modifier and TypeMethodDescriptionCreate a new predicate factory whose root for all paths passed to the DSL will be the given object field.<SR2> ExtendedSearchPredicateFactory
<SR2, ?> withScopeRoot
(Class<SR2> scopeRootType)
-
Method Details
-
withRoot
Description copied from interface:TypedSearchPredicateFactory
Create a new predicate factory whose root for all paths passed to the DSL will be the given object field.This is used to call reusable methods that apply the same predicate on different object fields that have same structure (same sub-fields).
- Specified by:
withRoot
in interfaceSearchPredicateFactory
- Specified by:
withRoot
in interfaceTypedSearchPredicateFactory<SR>
- Parameters:
objectFieldPath
- The path from the current root to an object field that will become the new root.- Returns:
- A new predicate factory using the given object field as root.
-
withScopeRoot
- Throws:
SearchException
- In case the current factory cannot be rescoped for thescopeRootType
.
-