Are you trying to show localized messages in your user interface? If the answer is yes, you might want to follow these steps:
- Specify a message source bean your application context configuration. More information about the message source is found here: http://static.springsource.org/sprin...-messagesource
- Configure the locale resolver and locale change interceptor components. More about information about this is found here: http://static.springsource.org/sprin...localeresolver
- Use the message tag of the Spring tag library to get the message shown in the JSP page. More information about this is found here: http://static.springsource.org/sprin...ng.tld.message
Also, if you need to generate feedback/error messages in your java code, you can wire the message source and the locale resolver beans to your class and use them to get the localized feedback / error message.
I got an impression that at the moment you have implemented the code accessing your resource files yourself. If you decide to use this approach, you can get rid of this boilerplate code.