Package net.risesoft.util
Class BeanFactory
- java.lang.Object
-
- net.risesoft.util.BeanFactory
-
public class BeanFactory extends Object
- Author:
- qinman, zhangchongjie
- Date:
- 2022/12/20
-
-
Constructor Summary
Constructors Constructor Description BeanFactory()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static org.springframework.beans.factory.support.DefaultListableBeanFactoryaddBean(org.springframework.beans.factory.support.DefaultListableBeanFactory beanFactory, String beanName)向BeanFactory中添加实体类对象static voiddelBean(org.springframework.beans.factory.support.DefaultListableBeanFactory beanFactory, String beanName)从BeanFactory中删除实体类对象static org.springframework.beans.factory.support.DefaultListableBeanFactorygetBeanFactory(org.springframework.context.ConfigurableApplicationContext applicationContext)从spring应用上下文中获取BeanFactory
-
-
-
Method Detail
-
addBean
public static org.springframework.beans.factory.support.DefaultListableBeanFactory addBean(org.springframework.beans.factory.support.DefaultListableBeanFactory beanFactory, String beanName)向BeanFactory中添加实体类对象- Parameters:
beanFactory- spring的BeanFactorybeanName- 实体类的名称,例如net.risesoft.fileflow.service.Test1- Returns:
-
delBean
public static void delBean(org.springframework.beans.factory.support.DefaultListableBeanFactory beanFactory, String beanName)从BeanFactory中删除实体类对象- Parameters:
beanFactory- spring的BeanFactorybeanName- 实体类的名称,例如net.risesoft.fileflow.service.Test1
-
getBeanFactory
public static org.springframework.beans.factory.support.DefaultListableBeanFactory getBeanFactory(org.springframework.context.ConfigurableApplicationContext applicationContext)
从spring应用上下文中获取BeanFactory- Parameters:
applicationContext- spring应用上下文- Returns:
-
-