Class RawQueryMethodMatcher
java.lang.Object
io.micronaut.data.processor.visitors.finders.RawQueryMethodMatcher
- All Implemented Interfaces:
io.micronaut.core.order.Ordered
,MethodMatcher
Finder with custom defied query used to return a single result.
- Since:
- 2.4.0
- Author:
- Denis Stepanov
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.micronaut.data.processor.visitors.finders.MethodMatcher
MethodMatcher.MethodMatch
-
Field Summary
Fields inherited from interface io.micronaut.data.processor.visitors.finders.MethodMatcher
DEFAULT_POSITION
Fields inherited from interface io.micronaut.core.order.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic QueryParameterBinding
addBinding
(MethodMatchContext matchContext, List<io.micronaut.inject.ast.ParameterElement> parameters, List<io.micronaut.core.annotation.AnnotationValue<ParameterExpression>> parameterExpressions, io.micronaut.inject.ast.ParameterElement entityParam, SourcePersistentEntity persistentEntity, String name, BindingParameter.BindingContext bindingContext) static io.micronaut.inject.ast.ClassElement
extractExpressionType
(MatchContext matchContext, io.micronaut.core.annotation.AnnotationValue<ParameterExpression> parameterExpression) Extract the expression type.final int
getOrder()
match
(MethodMatchContext matchContext)
-
Constructor Details
-
RawQueryMethodMatcher
public RawQueryMethodMatcher()
-
-
Method Details
-
getOrder
public final int getOrder()- Specified by:
getOrder
in interfaceMethodMatcher
- Specified by:
getOrder
in interfaceio.micronaut.core.order.Ordered
-
match
- Specified by:
match
in interfaceMethodMatcher
-
addBinding
public static QueryParameterBinding addBinding(MethodMatchContext matchContext, List<io.micronaut.inject.ast.ParameterElement> parameters, List<io.micronaut.core.annotation.AnnotationValue<ParameterExpression>> parameterExpressions, io.micronaut.inject.ast.ParameterElement entityParam, SourcePersistentEntity persistentEntity, String name, BindingParameter.BindingContext bindingContext) -
extractExpressionType
public static io.micronaut.inject.ast.ClassElement extractExpressionType(MatchContext matchContext, io.micronaut.core.annotation.AnnotationValue<ParameterExpression> parameterExpression) Extract the expression type.- Parameters:
matchContext
- The match contextparameterExpression
- The parameter expression- Returns:
- the type
-