Class Joiner
- java.lang.Object
-
- io.micronaut.data.model.jpa.criteria.impl.util.Joiner
-
- All Implemented Interfaces:
PredicateVisitor
,SelectionVisitor
@Internal public class Joiner extends java.lang.Object implements SelectionVisitor, PredicateVisitor
Traversing the query selection and predicates and extracting required query joins.- Since:
- 3.2
- Author:
- Denis Stepanov
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Joiner.Joined
The data structure representing a join.
-
Constructor Summary
Constructors Constructor Description Joiner()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Map<java.lang.String,Joiner.Joined>
getJoins()
Returns required query joins.void
joinIfNeeded(PersistentPropertyPath<?> persistentPropertyPath)
Join property relationships if needed.void
visit(IdExpression<?,?> idExpression)
VisitIdExpression
.void
visit(LiteralExpression<?> literalExpression)
VisitLiteralExpression
.void
visit(ConjunctionPredicate conjunction)
VisitConjunctionPredicate
.void
visit(DisjunctionPredicate disjunction)
VisitDisjunctionPredicate
.void
visit(ExpressionBinaryPredicate expressionBinaryPredicate)
VisitExpressionBinaryPredicate
.void
visit(NegatedPredicate negate)
VisitNegatedPredicate
.void
visit(PersistentPropertyBetweenPredicate<?> propertyBetweenPredicate)
void
visit(PersistentPropertyBinaryPredicate<?> propertyToExpressionOp)
void
visit(PersistentPropertyInPredicate<?> propertyIn)
void
visit(PersistentPropertyInValuesPredicate<?> inValues)
void
visit(PersistentPropertyUnaryPredicate<?> propertyOp)
void
visit(AggregateExpression<?,?> aggregateExpression)
VisitAggregateExpression
.void
visit(AliasedSelection<?> aliasedSelection)
VisitAliasedSelection
.void
visit(CompoundSelection<?> compoundSelection)
VisitCompoundSelection
.void
visit(PersistentEntityRoot<?> entityRoot)
VisitPersistentEntityRoot
.void
visit(PersistentPropertyPath<?> persistentPropertyPath)
VisitPersistentPropertyPath
.void
visit(jakarta.persistence.criteria.Predicate predicate)
VisitPredicate
.
-
-
-
Method Detail
-
getJoins
public java.util.Map<java.lang.String,Joiner.Joined> getJoins()
Returns required query joins.- Returns:
- The joins
-
joinIfNeeded
public void joinIfNeeded(PersistentPropertyPath<?> persistentPropertyPath)
Join property relationships if needed.- Parameters:
persistentPropertyPath
- The property
-
visit
public void visit(PersistentEntityRoot<?> entityRoot)
Description copied from interface:SelectionVisitor
VisitPersistentEntityRoot
.- Specified by:
visit
in interfaceSelectionVisitor
- Parameters:
entityRoot
- The entityRoot
-
visit
public void visit(PersistentPropertyPath<?> persistentPropertyPath)
Description copied from interface:SelectionVisitor
VisitPersistentPropertyPath
.- Specified by:
visit
in interfaceSelectionVisitor
- Parameters:
persistentPropertyPath
- The persistentPropertyPath
-
visit
public void visit(jakarta.persistence.criteria.Predicate predicate)
Description copied from interface:SelectionVisitor
VisitPredicate
.- Specified by:
visit
in interfaceSelectionVisitor
- Parameters:
predicate
- The predicate
-
visit
public void visit(AliasedSelection<?> aliasedSelection)
Description copied from interface:SelectionVisitor
VisitAliasedSelection
.- Specified by:
visit
in interfaceSelectionVisitor
- Parameters:
aliasedSelection
- The aliasedSelection
-
visit
public void visit(CompoundSelection<?> compoundSelection)
Description copied from interface:SelectionVisitor
VisitCompoundSelection
.- Specified by:
visit
in interfaceSelectionVisitor
- Parameters:
compoundSelection
- The compoundSelection
-
visit
public void visit(LiteralExpression<?> literalExpression)
Description copied from interface:SelectionVisitor
VisitLiteralExpression
.- Specified by:
visit
in interfaceSelectionVisitor
- Parameters:
literalExpression
- The literalExpression
-
visit
public void visit(IdExpression<?,?> idExpression)
Description copied from interface:SelectionVisitor
VisitIdExpression
.- Specified by:
visit
in interfaceSelectionVisitor
- Parameters:
idExpression
- The idExpression
-
visit
public void visit(AggregateExpression<?,?> aggregateExpression)
Description copied from interface:SelectionVisitor
VisitAggregateExpression
.- Specified by:
visit
in interfaceSelectionVisitor
- Parameters:
aggregateExpression
- The aggregateExpression
-
visit
public void visit(ConjunctionPredicate conjunction)
Description copied from interface:PredicateVisitor
VisitConjunctionPredicate
.- Specified by:
visit
in interfacePredicateVisitor
- Parameters:
conjunction
- The conjunction
-
visit
public void visit(DisjunctionPredicate disjunction)
Description copied from interface:PredicateVisitor
VisitDisjunctionPredicate
.- Specified by:
visit
in interfacePredicateVisitor
- Parameters:
disjunction
- The disjunction
-
visit
public void visit(NegatedPredicate negate)
Description copied from interface:PredicateVisitor
VisitNegatedPredicate
.- Specified by:
visit
in interfacePredicateVisitor
- Parameters:
negate
- The negate
-
visit
public void visit(PersistentPropertyInPredicate<?> propertyIn)
Description copied from interface:PredicateVisitor
- Specified by:
visit
in interfacePredicateVisitor
- Parameters:
propertyIn
- The propertyIn
-
visit
public void visit(PersistentPropertyUnaryPredicate<?> propertyOp)
Description copied from interface:PredicateVisitor
- Specified by:
visit
in interfacePredicateVisitor
- Parameters:
propertyOp
- The propertyOp
-
visit
public void visit(PersistentPropertyBetweenPredicate<?> propertyBetweenPredicate)
Description copied from interface:PredicateVisitor
- Specified by:
visit
in interfacePredicateVisitor
- Parameters:
propertyBetweenPredicate
- The propertyBetweenPredicate
-
visit
public void visit(PersistentPropertyBinaryPredicate<?> propertyToExpressionOp)
Description copied from interface:PredicateVisitor
- Specified by:
visit
in interfacePredicateVisitor
- Parameters:
propertyToExpressionOp
- The propertyToExpressionOp
-
visit
public void visit(PersistentPropertyInValuesPredicate<?> inValues)
Description copied from interface:PredicateVisitor
- Specified by:
visit
in interfacePredicateVisitor
- Parameters:
inValues
- The inValues
-
visit
public void visit(ExpressionBinaryPredicate expressionBinaryPredicate)
Description copied from interface:PredicateVisitor
VisitExpressionBinaryPredicate
.- Specified by:
visit
in interfacePredicateVisitor
- Parameters:
expressionBinaryPredicate
- The expressionBinaryPredicate
-
-