Accessing App resources After packaging in a Jar file
I have a small application that contains few packages and a folder that holds configuration files (xml files), which are accessed by my classes at runtime. The application does not work when I package it in a jar file. My classes cannot find configuration files. I unpacked (unzipped) the jar file and I can see that the folder and configuration files are there. I used to refer to the configuration files using relative path e.g. 搈yfolder/config.xml?br>I tried Google, and I concluded that it is recommended to use URL instead of relative path, but I do not know how to do that?
I would like also to mention that I am using 3rd party classes from Apache, which uses the configuration files as a string. I checked their documentation, they do not have a constructor that takes a URL, and I do not know what to do to overcome this problem.
Any help, a like to a book, or URL will be very appreciated
Best Regards
Thabet

