wood burning stoves 2.0*
The moose likes Servlets and the fly likes GWT project and properties files Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "GWT project and properties files" Watch "GWT project and properties files" New topic
Author

GWT project and properties files

George Vagenas
Greenhorn

Joined: Mar 04, 2008
Posts: 11
Hello everybody,

I am in the middle of a GWT project that i need to use some property files for the database information i use there. For this purpose i use the apache Commons Configuration kit, but my problem is that since this properties are needed in various classes in my project i am trying to find a way to use them in a loose coupling way and not include the configuration code in every class.

Any ideas?

Thanks
George
Ben Souther
Sheriff

Joined: Dec 11, 2004
Posts: 13410

I don't know much about GWT but I can speak a little about properties objects in a web app.

If the properties files are read at startup, using a context listener and then bound to context scope, it should be pretty easy for your servlet code to pass a reference to any classes that need them. Do you have a more specific example that you can talk about?


Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: GWT project and properties files
 
Similar Threads
GWT project and properties files
How to output to different directory?
SurefireExecutionException
Consequnces of not using Google App Engine in Eclipse - GWT project
Shouldn't jforum-custom.conf override mysql.properties?