Class FaultToleranceMethodSearch
java.lang.Object
io.quarkus.smallrye.faulttolerance.deployment.FaultToleranceMethodSearch
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) org.jboss.jandex.MethodInfofindBeforeRetryMethod(org.jboss.jandex.ClassInfo beanClass, org.jboss.jandex.ClassInfo declaringClass, String name) Finds a before retry method for given guarded method.(package private) org.jboss.jandex.MethodInfofindFallbackMethod(org.jboss.jandex.ClassInfo beanClass, org.jboss.jandex.ClassInfo declaringClass, String name, org.jboss.jandex.Type[] parameterTypes, org.jboss.jandex.Type returnType) Finds a fallback method for given guarded method.(package private) Set<org.jboss.jandex.MethodInfo>findFallbackMethodsWithExceptionParameter(org.jboss.jandex.ClassInfo beanClass, org.jboss.jandex.ClassInfo declaringClass, String name, org.jboss.jandex.Type[] parameterTypes, org.jboss.jandex.Type returnType) Finds a set of fallback methods with exception parameter for given guarded method.
-
Constructor Details
-
FaultToleranceMethodSearch
FaultToleranceMethodSearch(org.jboss.jandex.IndexView index)
-
-
Method Details
-
findFallbackMethod
org.jboss.jandex.MethodInfo findFallbackMethod(org.jboss.jandex.ClassInfo beanClass, org.jboss.jandex.ClassInfo declaringClass, String name, org.jboss.jandex.Type[] parameterTypes, org.jboss.jandex.Type returnType) Finds a fallback method for given guarded method. If the guarded method is present on givenbeanClassand is actually declared by givendeclaringClassand has givenparameterTypesandreturnType, then a fallback method of givenname, with parameter types and return type matching the parameter types and return type of the guarded method, is searched for on thebeanClassand its superclasses and superinterfaces, according to the specification rules. Returnsnullif no matching fallback method exists.- Parameters:
beanClass- the class of the bean that has the guarded methoddeclaringClass- the class that actually declares the guarded method (can be a supertype of bean class)name- name of the fallback methodparameterTypes- parameter types of the guarded methodreturnType- return type of the guarded method- Returns:
- the fallback method or
nullif none exists
-
findFallbackMethodsWithExceptionParameter
Set<org.jboss.jandex.MethodInfo> findFallbackMethodsWithExceptionParameter(org.jboss.jandex.ClassInfo beanClass, org.jboss.jandex.ClassInfo declaringClass, String name, org.jboss.jandex.Type[] parameterTypes, org.jboss.jandex.Type returnType) Finds a set of fallback methods with exception parameter for given guarded method. If the guarded method is present on givenbeanClassand is actually declared by givendeclaringClassand has givenparameterTypesandreturnType, then fallback methods of givenname, with parameter types and return type matching the parameter types and return type of the guarded method, and with one additional parameter assignable toThrowableat the end of parameter list, is searched for on thebeanClassand its superclasses and superinterfaces, according to the specification rules. Returns an empty set if no matching fallback method exists.- Parameters:
beanClass- the class of the bean that has the guarded methoddeclaringClass- the class that actually declares the guarded method (can be a supertype of bean class)name- name of the fallback methodparameterTypes- parameter types of the guarded methodreturnType- return type of the guarded method- Returns:
- the fallback method or an empty set if none exists
-
findBeforeRetryMethod
org.jboss.jandex.MethodInfo findBeforeRetryMethod(org.jboss.jandex.ClassInfo beanClass, org.jboss.jandex.ClassInfo declaringClass, String name) Finds a before retry method for given guarded method. If the guarded method is present on givenbeanClassand is actually declared by givendeclaringClass, then a before retry method of givenname, with no parameters and return type ofvoid, is searched for on thebeanClassand its superclasses and superinterfaces, according to the specification rules. Returnsnullif no matching before retry method exists.- Parameters:
beanClass- the class of the bean that has the guarded methoddeclaringClass- the class that actually declares the guarded method (can be a supertype of bean class)name- name of the before retry method- Returns:
- the before retry method or
nullif none exists
-