|
From: Rajeev K. <Ra...@cu...> - 2003-11-19 23:55:07
|
Why can't we use beanDefinitionMap.containsKey(beanName) in the ListableBeanFactoryImpl? ----- Original Message ----- From: "Kopylenko, Dmitry" <dko...@su...> To: "'Rod Johnson '" <rod...@in...>; <spr...@li...> Sent: Wednesday, November 19, 2003 3:05 PM Subject: RE: [Springframework-developer] how to determine if a bean exists in registry? > I would say the impl. for such method would use > AbstractBeanFactory.getBeanDefinition(String) call, catch > NoSuchBeanDefinitionException and return false, otherwise return true. > > Dmitriy. > > -----Original Message----- > From: Rod Johnson > To: spr...@li... > Sent: 11/19/2003 5:15 PM > Subject: Re: [Springframework-developer] how to determine if a bean exists > in registry? > > >It would still make sense to add a containsBean method to BeanFactory, > I > guess, to avoid workarounds like isSingleton or getAliases checks. If > noone > objects, I'll do that - is that OK with you, Darren? Rod, what do you > think? > > This makes sense so long as the bean won't be instantiated by that call. > Otherwise getBean() with a catch block would work. > > R > > > > > ------------------------------------------------------- > This SF.net email is sponsored by: SF.net Giveback Program. > Does SourceForge.net help you be more productive? Does it > help you create better code? SHARE THE LOVE, and help us help > YOU! Click Here: http://sourceforge.net/donate/ > _______________________________________________ > Springframework-developer mailing list > Spr...@li... > https://lists.sourceforge.net/lists/listinfo/springframework-developer > > > ------------------------------------------------------- > This SF.net email is sponsored by: SF.net Giveback Program. > Does SourceForge.net help you be more productive? Does it > help you create better code? SHARE THE LOVE, and help us help > YOU! Click Here: http://sourceforge.net/donate/ > _______________________________________________ > Springframework-developer mailing list > Spr...@li... > https://lists.sourceforge.net/lists/listinfo/springframework-developer |