类 CglibSubclassingInstantiationStrategy
- java.lang.Object
- org.springframework.beans.factory.support.SimpleInstantiationStrategy
- org.springframework.beans.factory.support.CglibSubclassingInstantiationStrategy
- 所有已实现的接口:
InstantiationStrategy
public class CglibSubclassingInstantiationStrategy extends SimpleInstantiationStrategy
Default object instantiation strategy for use in BeanFactories.Uses CGLIB to generate subclasses dynamically if methods need to be overridden by the container to implement Method Injection.
- 从以下版本开始:
- 1.1
- 作者:
- Rod Johnson, Juergen Hoeller, Sam Brannen
构造器概要
构造器 构造器 说明 CglibSubclassingInstantiationStrategy()
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 protected Object
instantiateWithMethodInjection(RootBeanDefinition bd, String beanName, BeanFactory owner)
Subclasses can override this method, which is implemented to throw UnsupportedOperationException, if they can instantiate an object with the Method Injection specified in the given RootBeanDefinition.protected Object
instantiateWithMethodInjection(RootBeanDefinition bd, String beanName, BeanFactory owner, Constructor<?> ctor, Object... args)
Subclasses can override this method, which is implemented to throw UnsupportedOperationException, if they can instantiate an object with the Method Injection specified in the given RootBeanDefinition.从类继承的方法 org.springframework.beans.factory.support.SimpleInstantiationStrategy
getCurrentlyInvokedFactoryMethod, instantiate, instantiate, instantiate
构造器详细资料
CglibSubclassingInstantiationStrategy
public CglibSubclassingInstantiationStrategy()
方法详细资料
instantiateWithMethodInjection
protected Object instantiateWithMethodInjection(RootBeanDefinition bd, @Nullable String beanName, BeanFactory owner)
从类复制的说明:SimpleInstantiationStrategy
Subclasses can override this method, which is implemented to throw UnsupportedOperationException, if they can instantiate an object with the Method Injection specified in the given RootBeanDefinition. Instantiation should use a no-arg constructor.
instantiateWithMethodInjection
protected Object instantiateWithMethodInjection(RootBeanDefinition bd, @Nullable String beanName, BeanFactory owner, @Nullable Constructor<?> ctor, Object... args)
从类复制的说明:SimpleInstantiationStrategy
Subclasses can override this method, which is implemented to throw UnsupportedOperationException, if they can instantiate an object with the Method Injection specified in the given RootBeanDefinition. Instantiation should use the given constructor and parameters.