public abstract class AbstractMethodAnnotationPostProcessor<T extends Annotation> extends Object implements MethodAnnotationPostProcessor<T>
Modifier and Type | Field and Description |
---|---|
protected BeanFactory |
beanFactory |
protected DestinationResolver<MessageChannel> |
channelResolver |
protected Environment |
environment |
Constructor and Description |
---|
AbstractMethodAnnotationPostProcessor(ListableBeanFactory beanFactory,
Environment environment) |
Modifier and Type | Method and Description |
---|---|
protected void |
configurePollingEndpoint(AbstractPollingEndpoint pollingEndpoint,
T annotation) |
protected abstract MessageHandler |
createHandler(Object bean,
Method method,
T annotation)
Subclasses must implement this method to create the MessageHandler.
|
protected String |
generateHandlerBeanName(String originalBeanName,
Method method,
Class<? extends Annotation> annotationType) |
Object |
postProcess(Object bean,
String beanName,
Method method,
T annotation) |
protected void |
setAdviceChainIfPresent(String beanName,
T annotation,
MessageHandler handler) |
protected final BeanFactory beanFactory
protected final Environment environment
protected final DestinationResolver<MessageChannel> channelResolver
public AbstractMethodAnnotationPostProcessor(ListableBeanFactory beanFactory, Environment environment)
public Object postProcess(Object bean, String beanName, Method method, T annotation)
postProcess
in interface MethodAnnotationPostProcessor<T extends Annotation>
protected final void setAdviceChainIfPresent(String beanName, T annotation, MessageHandler handler)
protected void configurePollingEndpoint(AbstractPollingEndpoint pollingEndpoint, T annotation)
protected String generateHandlerBeanName(String originalBeanName, Method method, Class<? extends Annotation> annotationType)
protected abstract MessageHandler createHandler(Object bean, Method method, T annotation)
bean
- The bean.method
- The method.annotation
- The annotation.