Class AbstractAsyncSpecificationInterceptor<T,R>
- java.lang.Object
-
- io.micronaut.data.runtime.intercept.AbstractQueryInterceptor<T,R>
-
- io.micronaut.data.runtime.intercept.criteria.AbstractSpecificationInterceptor<T,R>
-
- io.micronaut.data.runtime.intercept.criteria.async.AbstractAsyncSpecificationInterceptor<T,R>
-
- Type Parameters:
T
- The declaring typeR
- The return type
- All Implemented Interfaces:
DataInterceptor<T,R>
- Direct Known Subclasses:
CountAsyncSpecificationInterceptor
,DeleteAllAsyncSpecificationInterceptor
,FindAllAsyncSpecificationInterceptor
,FindOneAsyncSpecificationInterceptor
,FindPageAsyncSpecificationInterceptor
,UpdateAllAsyncSpecificationInterceptor
public abstract class AbstractAsyncSpecificationInterceptor<T,R> extends AbstractSpecificationInterceptor<T,R>
Abstract async specification interceptor.- Since:
- 3.2
- Author:
- Denis Stepanov
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class io.micronaut.data.runtime.intercept.criteria.AbstractSpecificationInterceptor
AbstractSpecificationInterceptor.Type
-
-
Field Summary
Fields Modifier and Type Field Description protected AsyncRepositoryOperations
asyncOperations
protected static io.micronaut.core.type.Argument<java.util.List<java.lang.Object>>
LIST_OF_OBJECTS
-
Fields inherited from class io.micronaut.data.runtime.intercept.AbstractQueryInterceptor
operations, preparedQueryResolver
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
AbstractAsyncSpecificationInterceptor(RepositoryOperations operations)
Default constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.lang.Number
convertNumberToReturnType(io.micronaut.aop.MethodInvocationContext<?,?> context, java.lang.Number number)
Convert a number argument if necessary.protected io.micronaut.core.type.Argument<?>
findReturnType(io.micronaut.aop.MethodInvocationContext<?,?> context, io.micronaut.core.type.Argument<?> defaultArg)
protected io.micronaut.core.type.Argument<?>
getReturnType(io.micronaut.aop.MethodInvocationContext<?,?> context)
Returns the return type.-
Methods inherited from class io.micronaut.data.runtime.intercept.criteria.AbstractSpecificationInterceptor
getCriteriaDeleteBuilder, getCriteriaQueryBuilder, getCriteriaUpdateBuilder, getDeleteSpecification, getQuerySpecification, getUpdateSpecification, preparedQueryForCriteria
-
Methods inherited from class io.micronaut.data.runtime.intercept.AbstractQueryInterceptor
convertNumberArgumentIfNecessary, convertOne, convertOne, count, findEntitiesParameter, findEntityParameter, getDeleteAllBatchOperation, getDeleteBatchOperation, getDeleteBatchOperation, getDeleteOperation, getEntitiesParameter, getEntityParameter, getInsertBatchOperation, getInsertBatchOperation, getInsertOperation, getInsertOperation, getPageable, getPagedQuery, getParameterValueMap, getRequiredEntity, getRequiredRootEntity, getUpdateAllBatchOperation, getUpdateOperation, getUpdateOperation, instantiateEntity, isNullable, isNumber, prepareCountQuery, prepareQuery, prepareQuery, prepareQuery, validateNullArguments
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.micronaut.data.intercept.DataInterceptor
intercept
-
-
-
-
Field Detail
-
LIST_OF_OBJECTS
protected static final io.micronaut.core.type.Argument<java.util.List<java.lang.Object>> LIST_OF_OBJECTS
-
asyncOperations
protected final AsyncRepositoryOperations asyncOperations
-
-
Constructor Detail
-
AbstractAsyncSpecificationInterceptor
protected AbstractAsyncSpecificationInterceptor(RepositoryOperations operations)
Default constructor.- Parameters:
operations
- The operations
-
-
Method Detail
-
getReturnType
protected final io.micronaut.core.type.Argument<?> getReturnType(io.micronaut.aop.MethodInvocationContext<?,?> context)
Description copied from class:AbstractQueryInterceptor
Returns the return type.- Overrides:
getReturnType
in classAbstractQueryInterceptor<T,R>
- Parameters:
context
- The context- Returns:
- the return type
-
findReturnType
protected final io.micronaut.core.type.Argument<?> findReturnType(io.micronaut.aop.MethodInvocationContext<?,?> context, io.micronaut.core.type.Argument<?> defaultArg)
-
convertNumberToReturnType
@Nullable protected java.lang.Number convertNumberToReturnType(io.micronaut.aop.MethodInvocationContext<?,?> context, java.lang.Number number)
Convert a number argument if necessary.- Parameters:
context
- The method contextnumber
- The number- Returns:
- The result
-
-