Package org.jboss.weld.util
Class BeanMethods
- java.lang.Object
-
- org.jboss.weld.util.BeanMethods
-
public class BeanMethods extends Object
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static <T> Collection<EnhancedAnnotatedMethod<?,? super T>>
filterMethods(Collection<EnhancedAnnotatedMethod<?,? super T>> methods)
Oracle JDK 8 compiler (unlike prev versions) generates bridge methods which have method and parameter annotations copied from the original method.static <T> Collection<EnhancedAnnotatedMethod<?,? super T>>
getAsyncObserverMethods(EnhancedAnnotatedType<T> type)
static <T> List<Set<MethodInjectionPoint<?,?>>>
getInitializerMethods(jakarta.enterprise.inject.spi.Bean<?> declaringBean, EnhancedAnnotatedType<T> type, BeanManagerImpl manager)
static <T> List<Method>
getInterceptorMethods(EnhancedAnnotatedType<T> type, InterceptionType interceptionType, boolean targetClass)
static <T> Collection<EnhancedAnnotatedMethod<?,? super T>>
getObserverMethods(EnhancedAnnotatedType<T> type)
static <T> List<jakarta.enterprise.inject.spi.AnnotatedMethod<? super T>>
getPostConstructMethods(EnhancedAnnotatedType<T> type)
static <T> List<jakarta.enterprise.inject.spi.AnnotatedMethod<? super T>>
getPreDestroyMethods(EnhancedAnnotatedType<T> type)
-
-
-
Method Detail
-
getPostConstructMethods
public static <T> List<jakarta.enterprise.inject.spi.AnnotatedMethod<? super T>> getPostConstructMethods(EnhancedAnnotatedType<T> type)
-
getPreDestroyMethods
public static <T> List<jakarta.enterprise.inject.spi.AnnotatedMethod<? super T>> getPreDestroyMethods(EnhancedAnnotatedType<T> type)
-
getInitializerMethods
public static <T> List<Set<MethodInjectionPoint<?,?>>> getInitializerMethods(jakarta.enterprise.inject.spi.Bean<?> declaringBean, EnhancedAnnotatedType<T> type, BeanManagerImpl manager)
-
getObserverMethods
public static <T> Collection<EnhancedAnnotatedMethod<?,? super T>> getObserverMethods(EnhancedAnnotatedType<T> type)
-
getAsyncObserverMethods
public static <T> Collection<EnhancedAnnotatedMethod<?,? super T>> getAsyncObserverMethods(EnhancedAnnotatedType<T> type)
-
filterMethods
public static <T> Collection<EnhancedAnnotatedMethod<?,? super T>> filterMethods(Collection<EnhancedAnnotatedMethod<?,? super T>> methods)
Oracle JDK 8 compiler (unlike prev versions) generates bridge methods which have method and parameter annotations copied from the original method. However such methods should not become observers, producers, disposers, initializers and lifecycle callbacks. Moreover, JDK8u60 propagates parameter annotations to the synthetic method generated for a lambda. Therefore, we should also ignore synthetic methods.- Parameters:
methods
-- Returns:
- a collection with bridge and synthetic methods filtered out
-
getInterceptorMethods
public static <T> List<Method> getInterceptorMethods(EnhancedAnnotatedType<T> type, InterceptionType interceptionType, boolean targetClass)
-
-