private static DefaultListableBeanFactory buildListableBeanFactory ( Map < String , ? > extraBeans ) { //new empty context final DefaultListableBeanFactory parentBeanFactory = new DefaultListableBeanFactory ( ) ; //Injection of the new beans in the context for ( String key : extraBeans . keySet ( ) ) { parentBeanFactory . registerSingleton ( key , extraBeans . get ( key ) ) ; } return parentBeanFactory ; }
Builds a listable bean factory with the given beans .