You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Marcel Stor <ma...@frightanic.com> on 2003/04/10 08:21:24 UTC

properties file confusion

Hi all,

I have got a class that depends on external properties in a properties
file. The class references that file through new File("my.properties").
That is fine as long as I'm working in the closed IDE environment and
the file is placed in the project root folder.
I've now packaged the class into a JAR file and placed it into
%CATALINA_HOME%\webapps\myApp\WEB-INF\lib. The class now tries to locate
the file in the windows\system32 folder. Why is that? I would like to
place it in WEB-INF or WEB-INF\lib or even myApp\. How should I
reference it then inside my class?
The class is neither a servlet nor is it web app specific, so the way I
locate the properties file should also be applicable if it is used by a
destop application.

Thanks for all your help.

Marcel


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org