Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

user data/constant stored in xml file  RSS feed

Ningfeng Xu
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am looking at the Jakarta Commons Configuration. It is nice to do some application specific data configuration in XML file using this package. But each time when I need a constant stored in XML file, I have the following code:

XMLConfiguration config = new XMLConfiguration("tables.xml");
int rowsPerPage = config.getInt("rowsPerPage");

I suppose this code will be executed every time when needed, loading the file and parsing the integer. Does struts or tomcat have some builtin solution for user-level data? like they have(struts-config.xml,web.xml) for their data. Thanks.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!