org.springframework.integration.security
Class ChannelInterceptorRegisteringBeanPostProcessor

java.lang.Object
  extended by org.springframework.integration.security.ChannelInterceptorRegisteringBeanPostProcessor
All Implemented Interfaces:
org.springframework.beans.factory.config.BeanPostProcessor, org.springframework.core.Ordered

public class ChannelInterceptorRegisteringBeanPostProcessor
extends java.lang.Object
implements org.springframework.beans.factory.config.BeanPostProcessor, org.springframework.core.Ordered

Registers the provided ChannelInterceptor instance with any AbstractMessageChannel with a name matching the provided pattern

Author:
Jonas Partner

Field Summary
private  ChannelInterceptor channelInterceptor
           
private  int order
           
private  java.util.List<java.util.regex.Pattern> regexpPatterns
           
 
Fields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
 
Constructor Summary
ChannelInterceptorRegisteringBeanPostProcessor(ChannelInterceptor channelInterceptor, java.util.List<java.lang.String> patterns)
           
 
Method Summary
 int getOrder()
           
protected  boolean matchesPattern(java.lang.String beanName)
           
 java.lang.Object postProcessAfterInitialization(java.lang.Object bean, java.lang.String beanName)
           
 java.lang.Object postProcessBeforeInitialization(java.lang.Object bean, java.lang.String beanName)
           
 void setOrder(int order)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

channelInterceptor

private final ChannelInterceptor channelInterceptor

regexpPatterns

private final java.util.List<java.util.regex.Pattern> regexpPatterns

order

private int order
Constructor Detail

ChannelInterceptorRegisteringBeanPostProcessor

public ChannelInterceptorRegisteringBeanPostProcessor(ChannelInterceptor channelInterceptor,
                                                      java.util.List<java.lang.String> patterns)
Method Detail

postProcessAfterInitialization

public java.lang.Object postProcessAfterInitialization(java.lang.Object bean,
                                                       java.lang.String beanName)
                                                throws org.springframework.beans.BeansException
Specified by:
postProcessAfterInitialization in interface org.springframework.beans.factory.config.BeanPostProcessor
Throws:
org.springframework.beans.BeansException

postProcessBeforeInitialization

public java.lang.Object postProcessBeforeInitialization(java.lang.Object bean,
                                                        java.lang.String beanName)
                                                 throws org.springframework.beans.BeansException
Specified by:
postProcessBeforeInitialization in interface org.springframework.beans.factory.config.BeanPostProcessor
Throws:
org.springframework.beans.BeansException

getOrder

public int getOrder()
Specified by:
getOrder in interface org.springframework.core.Ordered

setOrder

public void setOrder(int order)

matchesPattern

protected boolean matchesPattern(java.lang.String beanName)