Class SubsystemProxyFactory

  • All Implemented Interfaces:
    java.io.Serializable, org.springframework.aop.framework.Advised, org.springframework.aop.TargetClassAware, org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanClassLoaderAware, org.springframework.beans.factory.BeanFactoryAware, org.springframework.beans.factory.FactoryBean<java.lang.Object>, org.springframework.context.ApplicationContextAware
    Direct Known Subclasses:
    CryptodocSubsystemProxyFactory

    public class SubsystemProxyFactory
    extends org.springframework.aop.framework.ProxyFactoryBean
    implements org.springframework.context.ApplicationContextAware
    A factory bean, normally used in conjunction with ChildApplicationContextFactory allowing selected interfaces in a child application context to be proxied by a bean in the parent application context. This allows 'hot-swapping' and reconfiguration of entire subsystems.
    See Also:
    Serialized Form
    • Field Summary

      • Fields inherited from class org.springframework.aop.framework.ProxyFactoryBean

        GLOBAL_SUFFIX, logger
      • Fields inherited from class org.springframework.aop.framework.AdvisedSupport

        EMPTY_TARGET_SOURCE
    • Constructor Summary

      Constructors 
      Constructor Description
      SubsystemProxyFactory()
      Instantiates a new managed subsystem proxy factory.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected java.lang.Object locateBean​(org.aopalliance.intercept.MethodInvocation mi)  
      void setApplicationContext​(org.springframework.context.ApplicationContext applicationContext)  
      void setDefaultBean​(java.lang.Object defaultBean)
      Sets an optional default bean to be used if the target bean is not found.
      void setInterfaces​(java.lang.Class[] interfaces)  
      void setSourceApplicationContextFactory​(ApplicationContextFactory sourceApplicationContextFactory)
      Sets the source application context factory by reference
      void setSourceApplicationContextFactoryName​(java.lang.String sourceApplicationContextFactoryName)
      Sets the source application context factory by name.
      void setSourceBeanName​(java.lang.String sourceBeanName)
      Sets an optional bean name to target all calls to in the source application context.
      • Methods inherited from class org.springframework.aop.framework.ProxyFactoryBean

        adviceChanged, createCompositeInterface, getObject, getObjectType, getProxy, isSingleton, setAdvisorAdapterRegistry, setAutodetectInterfaces, setBeanClassLoader, setBeanFactory, setFrozen, setInterceptorNames, setProxyClassLoader, setProxyInterfaces, setSingleton, setTargetName
      • Methods inherited from class org.springframework.aop.framework.ProxyCreatorSupport

        addListener, createAopProxy, getAopProxyFactory, isActive, removeListener, setAopProxyFactory
      • Methods inherited from class org.springframework.aop.framework.AdvisedSupport

        addAdvice, addAdvice, addAdvisor, addAdvisor, addAdvisors, addAdvisors, addInterface, adviceIncluded, copyConfigurationFrom, copyConfigurationFrom, countAdvicesOfType, getAdvisorChainFactory, getAdvisors, getAdvisorsInternal, getInterceptorsAndDynamicInterceptionAdvice, getProxiedInterfaces, getTargetClass, getTargetSource, indexOf, indexOf, isInterfaceProxied, isPreFiltered, removeAdvice, removeAdvisor, removeAdvisor, removeInterface, replaceAdvisor, setAdvisorChainFactory, setPreFiltered, setTarget, setTargetClass, setTargetSource, toProxyConfigString, toString, updateAdvisorArray
      • Methods inherited from class org.springframework.aop.framework.ProxyConfig

        copyFrom, isExposeProxy, isFrozen, isOpaque, isOptimize, isProxyTargetClass, setExposeProxy, setOpaque, setOptimize, setProxyTargetClass
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface org.springframework.aop.framework.Advised

        isExposeProxy, isFrozen, isProxyTargetClass, setExposeProxy
    • Constructor Detail

      • SubsystemProxyFactory

        public SubsystemProxyFactory()
        Instantiates a new managed subsystem proxy factory.
    • Method Detail

      • setInterfaces

        public void setInterfaces​(java.lang.Class[] interfaces)
        Overrides:
        setInterfaces in class org.springframework.aop.framework.AdvisedSupport
      • setSourceApplicationContextFactoryName

        public void setSourceApplicationContextFactoryName​(java.lang.String sourceApplicationContextFactoryName)
        Sets the source application context factory by name.
        Parameters:
        sourceApplicationContextFactoryName - the name of the sourceApplicationContextFactory to set
      • setSourceApplicationContextFactory

        public void setSourceApplicationContextFactory​(ApplicationContextFactory sourceApplicationContextFactory)
        Sets the source application context factory by reference
        Parameters:
        sourceApplicationContextFactory - the sourceApplicationContextFactory to set
      • setApplicationContext

        public void setApplicationContext​(org.springframework.context.ApplicationContext applicationContext)
                                   throws org.springframework.beans.BeansException
        Specified by:
        setApplicationContext in interface org.springframework.context.ApplicationContextAware
        Throws:
        org.springframework.beans.BeansException
      • setSourceBeanName

        public void setSourceBeanName​(java.lang.String sourceBeanName)
        Sets an optional bean name to target all calls to in the source application context. If not set, an appropriate bean is looked up based on method class.
        Parameters:
        sourceBeanName - the sourceBeanName to set
      • setDefaultBean

        public void setDefaultBean​(java.lang.Object defaultBean)
        Sets an optional default bean to be used if the target bean is not found. Generally used when a subsystem does not exist.
        Parameters:
        defaultBean - the defaultBean to set
      • locateBean

        protected java.lang.Object locateBean​(org.aopalliance.intercept.MethodInvocation mi)