Interface FindersUtils


  • @Internal
    public interface FindersUtils
    Finders utils.
    • Method Detail

      • resolveInterceptorTypeByOperationType

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> resolveInterceptorTypeByOperationType​(boolean hasEntityParameter,
                                                                                                                                                                boolean hasMultipleEntityParameter,
                                                                                                                                                                DataMethod.OperationType operationType,
                                                                                                                                                                MethodMatchContext matchContext)
      • pickSaveOneInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> pickSaveOneInterceptor​(MethodMatchContext matchContext,
                                                                                                                                                 io.micronaut.inject.ast.ClassElement returnType)
      • pickUpdateAllEntitiesInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> pickUpdateAllEntitiesInterceptor​(MethodMatchContext matchContext,
                                                                                                                                                           io.micronaut.inject.ast.ClassElement returnType)
      • pickDeleteInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> pickDeleteInterceptor​(MethodMatchContext matchContext,
                                                                                                                                                io.micronaut.inject.ast.ClassElement returnType)
      • pickDeleteAllInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> pickDeleteAllInterceptor​(MethodMatchContext matchContext,
                                                                                                                                                   io.micronaut.inject.ast.ClassElement returnType)
      • pickSaveEntityInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> pickSaveEntityInterceptor​(MethodMatchContext matchContext,
                                                                                                                                                    io.micronaut.inject.ast.ClassElement returnType)
      • pickSaveAllEntitiesInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> pickSaveAllEntitiesInterceptor​(MethodMatchContext matchContext,
                                                                                                                                                         io.micronaut.inject.ast.ClassElement returnType)
      • pickUpdateInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> pickUpdateInterceptor​(MethodMatchContext matchContext,
                                                                                                                                                io.micronaut.inject.ast.ClassElement returnType)
      • pickUpdateEntityInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> pickUpdateEntityInterceptor​(MethodMatchContext matchContext,
                                                                                                                                                      io.micronaut.inject.ast.ClassElement returnType)
      • resolveFindInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> resolveFindInterceptor​(MethodMatchContext matchContext,
                                                                                                                                                 io.micronaut.inject.ast.ClassElement returnType)
      • resolveSyncFindInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> resolveSyncFindInterceptor​(@NonNull
                                                                                                                                                     MethodMatchContext matchContext,
                                                                                                                                                     @NotNull
                                                                                                                                                     @NotNull io.micronaut.inject.ast.ClassElement returnType)
      • resolveReactiveFindInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> resolveReactiveFindInterceptor​(@NonNull
                                                                                                                                                         MethodMatchContext matchContext,
                                                                                                                                                         @NonNull
                                                                                                                                                         io.micronaut.inject.ast.ClassElement returnType,
                                                                                                                                                         @NonNull
                                                                                                                                                         io.micronaut.inject.ast.ClassElement reactiveType)
      • resolveAsyncFindInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> resolveAsyncFindInterceptor​(@NonNull
                                                                                                                                                      MethodMatchContext matchContext,
                                                                                                                                                      @NonNull
                                                                                                                                                      io.micronaut.inject.ast.ClassElement returnType,
                                                                                                                                                      @NonNull
                                                                                                                                                      io.micronaut.inject.ast.ClassElement asyncType)
      • pickCountInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> pickCountInterceptor​(MethodMatchContext matchContext,
                                                                                                                                               io.micronaut.inject.ast.ClassElement returnType)
      • pickExistsInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> pickExistsInterceptor​(MethodMatchContext matchContext,
                                                                                                                                                io.micronaut.inject.ast.ClassElement returnType)
      • pickFindByIdInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> pickFindByIdInterceptor​(MethodMatchContext matchContext,
                                                                                                                                                  io.micronaut.inject.ast.ClassElement returnType)
      • pickFindOneInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> pickFindOneInterceptor​(MethodMatchContext matchContext,
                                                                                                                                                 io.micronaut.inject.ast.ClassElement returnType)
      • pickCountSpecInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​io.micronaut.inject.ast.ClassElement> pickCountSpecInterceptor​(MethodMatchContext matchContext,
                                                                                                                                             io.micronaut.inject.ast.ClassElement returnType)
      • pickDeleteAllSpecInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​io.micronaut.inject.ast.ClassElement> pickDeleteAllSpecInterceptor​(MethodMatchContext matchContext,
                                                                                                                                                 io.micronaut.inject.ast.ClassElement returnType)
      • pickFindAllSpecInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​io.micronaut.inject.ast.ClassElement> pickFindAllSpecInterceptor​(MethodMatchContext matchContext,
                                                                                                                                               io.micronaut.inject.ast.ClassElement returnType)
      • pickFindOneSpecInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​io.micronaut.inject.ast.ClassElement> pickFindOneSpecInterceptor​(MethodMatchContext matchContext,
                                                                                                                                               io.micronaut.inject.ast.ClassElement returnType)
      • pickFindPageSpecInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​io.micronaut.inject.ast.ClassElement> pickFindPageSpecInterceptor​(MethodMatchContext matchContext,
                                                                                                                                                io.micronaut.inject.ast.ClassElement returnType)
      • pickUpdateAllSpecInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​io.micronaut.inject.ast.ClassElement> pickUpdateAllSpecInterceptor​(MethodMatchContext matchContext,
                                                                                                                                                 io.micronaut.inject.ast.ClassElement returnType)
      • pickExistsSpecInterceptor

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​io.micronaut.inject.ast.ClassElement> pickExistsSpecInterceptor​(MethodMatchContext matchContext,
                                                                                                                                              io.micronaut.inject.ast.ClassElement returnType)
      • getAsyncType

        static io.micronaut.inject.ast.ClassElement getAsyncType​(@NonNull
                                                                 MethodMatchContext matchContext,
                                                                 @NonNull
                                                                 io.micronaut.inject.ast.ClassElement returnType)
      • typeAndInterceptorEntry

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​java.lang.Class<? extends DataInterceptor>> typeAndInterceptorEntry​(io.micronaut.inject.ast.ClassElement type,
                                                                                                                                                  java.lang.Class<? extends DataInterceptor> interceptor)
      • typeAndInterceptorEntry

        static java.util.Map.Entry<io.micronaut.inject.ast.ClassElement,​io.micronaut.inject.ast.ClassElement> typeAndInterceptorEntry​(io.micronaut.inject.ast.ClassElement type,
                                                                                                                                            io.micronaut.inject.ast.ClassElement interceptor)
      • isFutureType

        static boolean isFutureType​(MethodMatchContext methodMatchContext,
                                    @Nullable
                                    io.micronaut.inject.ast.ClassElement type)
      • isReactiveType

        static boolean isReactiveType​(@Nullable
                                      io.micronaut.inject.ast.ClassElement type)
      • isPage

        static boolean isPage​(MethodMatchContext methodMatchContext,
                              io.micronaut.inject.ast.ClassElement typeArgument)
      • isSlice

        static boolean isSlice​(MethodMatchContext methodMatchContext,
                               io.micronaut.inject.ast.ClassElement typeArgument)
      • isContainer

        static boolean isContainer​(io.micronaut.inject.ast.ClassElement typeArgument,
                                   java.lang.Class<?> containerType)
      • isOneOfContainers

        static boolean isOneOfContainers​(io.micronaut.inject.ast.ClassElement typeArgument,
                                         java.lang.Class<?>... containers)
      • isContainer

        static boolean isContainer​(io.micronaut.inject.ast.ClassElement typeArgument,
                                   java.lang.String containerType)
      • isValidResultType

        static boolean isValidResultType​(io.micronaut.inject.ast.ClassElement returnType)
      • isReactiveSingleResult

        static boolean isReactiveSingleResult​(io.micronaut.inject.ast.ClassElement returnType)
      • getInterceptorElement

        static io.micronaut.inject.ast.ClassElement getInterceptorElement​(@NonNull
                                                                          MethodMatchContext matchContext,
                                                                          java.lang.Class<? extends DataInterceptor> type)
        Obtain the interceptor element for the given class.
        Parameters:
        matchContext - The match context
        type - The type
        Returns:
        The element
      • getInterceptorElement

        static io.micronaut.inject.ast.ClassElement getInterceptorElement​(@NonNull
                                                                          MethodMatchContext matchContext,
                                                                          java.lang.String type)
        Obtain the interceptor element for the given class name.
        Parameters:
        matchContext - The match context
        type - The type
        Returns:
        The element