You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by "Alberto A. Flores" <aa...@gmail.com> on 2008/04/29 15:00:43 UTC
Injecting values into struts.xml
Does anyone know if it's possible to inject values into struts.xml
(something like PropertyConfigurer does in Spring)?
Thanks!
--
Alberto A. Flores
http://www.linkedin.com/in/aflores
Re: Injecting values into struts.xml
Posted by Dave Newton <ne...@yahoo.com>.
--- Laurie Harper <la...@holoweb.net> wrote:
> Alberto A. Flores wrote:
> > Does anyone know if it's possible to inject values into struts.xml
> > (something like PropertyConfigurer does in Spring)?
>
> I couldn't find a PropertyConfigurer class in Spring; perhaps you meant
> PropertyPlaceholderConfigurer or PropertyOverrideConfigurer? In any
> case, I'm not familiar with those classes so I'm not sure what you mean
> by 'inject values into struts.xml'. How would you 'inject values' into
> an XML file?
Spring uses PropertyPlaceholderConfigurer to load variables from property
files. They can then be accessed using the typical ${} access notation
throughout Spring config files; handy for things like datasource properties.
I'm not aware that this is possible for the S2 config file, but depending on
what specifically you're trying to accomplish it may not be necessary.
Dave
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: Injecting values into struts.xml
Posted by Laurie Harper <la...@holoweb.net>.
Alberto A. Flores wrote:
> Does anyone know if it's possible to inject values into struts.xml
> (something like PropertyConfigurer does in Spring)?
I couldn't find a PropertyConfigurer class in Spring; perhaps you meant
PropertyPlaceholderConfigurer or PropertyOverrideConfigurer? In any
case, I'm not familiar with those classes so I'm not sure what you mean
by 'inject values into struts.xml'. How would you 'inject values' into
an XML file?
If your question is whether there's a way to specify configuration
values in a properties file instead of in struts.xml then you can use do
that by putting them in struts.properties.
L.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org