|
From: Steven D. <ste...@in...> - 2005-09-21 09:44:55
|
Bing,
You can implement a BeanFactoryPostProcessor to do that. Have a look
at the code of PropertyPlaceholderConfigurer. This class inspects
bean definitions and replaces ${key} with property values loaded from
property files. BeanFactoryPostProcessors are recognized by the bean
factory and applied automatically.
Steven Devijver
Senior consultant
@ Interface21
ste...@in...
On 21 Sep 2005, at 04:20, Bing Ran wrote:
> I'm implementing my own BeanFactory as a subclass of
> DefaultListableBeanFactory. What I want to do is to reinterpret
> injected
> values on a bean, such as the <value>#{param.userName}</value> part
> in the
> bean definition:
>
> <bean ...>
> <property name="a"> <value>#{param.userName}</value></property>
> </bean>
>
> I'd like to set the value from another source (such as in JSF
> context) at
> the time the bean is instantiated. Any tips how my code can get a
> chance to
> re-interpret the dependency?
>
> Thanks!
>
> Bing Ran
>
>
>
>
> -------------------------------------------------------
> SF.Net email is sponsored by:
> Tame your development challenges with Apache's Geronimo App Server.
> Download
> it for free - -and be entered to win a 42" plasma tv or your very own
> Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php
> _______________________________________________
> Springframework-developer mailing list
> Spr...@li...
> https://lists.sourceforge.net/lists/listinfo/springframework-developer
>
>
>
|