Doesn't MessageResourcesConfig.getParameter give you the bundle basename? So, if you're in an action, you could do:
ModuleConfig moduleConfig = mapping.getModuleConfig(); MessageResourcesConfig messageConfig = moduleConfig.findMessageResourcesConfig(Globals.MESSAGES_KEY); String bundleBasename = messageConfig.getParameter(); Quoting "Craig R. McClanahan" <[EMAIL PROTECTED]>: > Todor Sergueev Petkov wrote: > > > Hello, > > does anybody know how, from a Struts Action class I can > > access the name of the Application Ressources file defined inside > > web.xml. Or is there a simpler way to access directly the properties, > > one by one from the properties file? > > > To find out the *name* of the application resources file, you would have > to parse the struts-config.xml file yourself, looking for the > appropriate <message-resources> element. To access the actual entries, > an instance of MessageResources containing them is stored as a servlet > context attribute under the "key" that you specify (the default is > "org.apache.struts.action.MESSAGE"). The standard MessageResources > implementation class does not offer an iterator over the message keys, > but you could subclass it fairly easily and add such a method. > > > > > Thanks, > > Todor > > > Craig -- Kris Schneider <mailto:[EMAIL PROTECTED]> D.O.Tech <http://www.dotech.com/> --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

