public abstract class AbstractMethodAnnotationPostProcessor<T extends java.lang.annotation.Annotation> extends java.lang.Object implements MethodAnnotationPostProcessor<T>
Modifier and Type | Field and Description |
---|---|
protected java.lang.Class<T> |
annotationType |
protected ConfigurableListableBeanFactory |
beanFactory |
protected DestinationResolver<MessageChannel> |
channelResolver |
protected ConversionService |
conversionService |
protected Environment |
environment |
Constructor and Description |
---|
AbstractMethodAnnotationPostProcessor(ListableBeanFactory beanFactory,
Environment environment) |
Modifier and Type | Method and Description |
---|---|
protected boolean |
beanAnnotationAware() |
protected void |
configurePollingEndpoint(AbstractPollingEndpoint pollingEndpoint,
java.util.List<java.lang.annotation.Annotation> annotations) |
protected AbstractEndpoint |
createEndpoint(MessageHandler handler,
java.lang.reflect.Method method,
java.util.List<java.lang.annotation.Annotation> annotations) |
protected abstract MessageHandler |
createHandler(java.lang.Object bean,
java.lang.reflect.Method method,
java.util.List<java.lang.annotation.Annotation> annotations)
Subclasses must implement this method to create the MessageHandler.
|
protected AbstractEndpoint |
doCreateEndpoint(MessageHandler handler,
MessageChannel inputChannel,
java.util.List<java.lang.annotation.Annotation> annotations) |
protected java.lang.String |
generateHandlerBeanName(java.lang.String originalBeanName,
java.lang.reflect.Method method) |
protected java.lang.String |
getInputChannelAttribute() |
java.lang.Object |
postProcess(java.lang.Object bean,
java.lang.String beanName,
java.lang.reflect.Method method,
java.util.List<java.lang.annotation.Annotation> annotations) |
protected java.lang.Object |
resolveTargetBeanFromMethodWithBeanAnnotation(java.lang.reflect.Method method) |
protected void |
setAdviceChainIfPresent(java.lang.String beanName,
java.util.List<java.lang.annotation.Annotation> annotations,
MessageHandler handler) |
protected void |
setOutputChannelIfPresent(java.util.List<java.lang.annotation.Annotation> annotations,
AbstractReplyProducingMessageHandler handler) |
boolean |
shouldCreateEndpoint(java.lang.reflect.Method method,
java.util.List<java.lang.annotation.Annotation> annotations)
|
protected final ConfigurableListableBeanFactory beanFactory
protected final ConversionService conversionService
protected final Environment environment
protected final DestinationResolver<MessageChannel> channelResolver
protected final java.lang.Class<T extends java.lang.annotation.Annotation> annotationType
public AbstractMethodAnnotationPostProcessor(ListableBeanFactory beanFactory, Environment environment)
public java.lang.Object postProcess(java.lang.Object bean, java.lang.String beanName, java.lang.reflect.Method method, java.util.List<java.lang.annotation.Annotation> annotations)
postProcess
in interface MethodAnnotationPostProcessor<T extends java.lang.annotation.Annotation>
public boolean shouldCreateEndpoint(java.lang.reflect.Method method, java.util.List<java.lang.annotation.Annotation> annotations)
MethodAnnotationPostProcessor
shouldCreateEndpoint
in interface MethodAnnotationPostProcessor<T extends java.lang.annotation.Annotation>
method
- the method to check if it is eligible to create an Endpointannotations
- the List of annotations to processboolean
flag to determine whether or not to create an
AbstractEndpoint
protected java.lang.String getInputChannelAttribute()
protected boolean beanAnnotationAware()
protected final void setAdviceChainIfPresent(java.lang.String beanName, java.util.List<java.lang.annotation.Annotation> annotations, MessageHandler handler)
protected AbstractEndpoint createEndpoint(MessageHandler handler, java.lang.reflect.Method method, java.util.List<java.lang.annotation.Annotation> annotations)
protected AbstractEndpoint doCreateEndpoint(MessageHandler handler, MessageChannel inputChannel, java.util.List<java.lang.annotation.Annotation> annotations)
protected void configurePollingEndpoint(AbstractPollingEndpoint pollingEndpoint, java.util.List<java.lang.annotation.Annotation> annotations)
protected java.lang.String generateHandlerBeanName(java.lang.String originalBeanName, java.lang.reflect.Method method)
protected void setOutputChannelIfPresent(java.util.List<java.lang.annotation.Annotation> annotations, AbstractReplyProducingMessageHandler handler)
protected java.lang.Object resolveTargetBeanFromMethodWithBeanAnnotation(java.lang.reflect.Method method)
protected abstract MessageHandler createHandler(java.lang.Object bean, java.lang.reflect.Method method, java.util.List<java.lang.annotation.Annotation> annotations)
bean
- The bean.method
- The method.annotations
- The messaging annotation (or meta-annotation hierarchy) on the method.