Class DelegatingFactoryBean

  • All Implemented Interfaces:
    org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanNameAware, org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.FactoryBean<java.lang.Object>, org.springframework.beans.factory.InitializingBean, org.springframework.context.ApplicationContextAware

    public class DelegatingFactoryBean
    extends java.lang.Object
    implements org.springframework.beans.factory.FactoryBean<java.lang.Object>, org.springframework.beans.factory.InitializingBean, org.springframework.beans.factory.DisposableBean, org.springframework.context.ApplicationContextAware, org.springframework.beans.factory.BeanNameAware
    FactoryBean implementation based on delegate object that was instantiated
    Since:
    1.0.0
    Author:
    Mercy
    See Also:
    FactoryBean
    • Field Summary

      • Fields inherited from interface org.springframework.beans.factory.FactoryBean

        OBJECT_TYPE_ATTRIBUTE
    • Constructor Summary

      Constructors 
      Constructor Description
      DelegatingFactoryBean​(java.lang.Object delegate)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void afterPropertiesSet()  
      void destroy()  
      java.lang.Object getObject()  
      java.lang.Class<?> getObjectType()  
      void setApplicationContext​(org.springframework.context.ApplicationContext context)  
      void setBeanName​(java.lang.String name)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface org.springframework.beans.factory.FactoryBean

        isSingleton
    • Constructor Detail

      • DelegatingFactoryBean

        public DelegatingFactoryBean​(java.lang.Object delegate)
    • Method Detail

      • getObject

        public java.lang.Object getObject()
                                   throws java.lang.Exception
        Specified by:
        getObject in interface org.springframework.beans.factory.FactoryBean<java.lang.Object>
        Throws:
        java.lang.Exception
      • getObjectType

        public java.lang.Class<?> getObjectType()
        Specified by:
        getObjectType in interface org.springframework.beans.factory.FactoryBean<java.lang.Object>
      • afterPropertiesSet

        public void afterPropertiesSet()
                                throws java.lang.Exception
        Specified by:
        afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
        Throws:
        java.lang.Exception
      • setApplicationContext

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

        public void setBeanName​(java.lang.String name)
        Specified by:
        setBeanName in interface org.springframework.beans.factory.BeanNameAware
      • destroy

        public void destroy()
                     throws java.lang.Exception
        Specified by:
        destroy in interface org.springframework.beans.factory.DisposableBean
        Throws:
        java.lang.Exception