-
1. Re: Reading files from another archive
peterj Mar 13, 2009 11:05 AM (in response to eriksson.viktor)For one of our applications what we did was created a subdirectory under the server/xxx/conf directory and placed various configuration and customization files there. Then to look them up, we used the jboss.server.config.url system property to locate the conf directory. For example, to access server/xxx/conf/mystuff/desired.xsl, use:
String confUrl = System.getProperty("jboss.server.config.url");
File f = new File(confUrl + "mystuff/desired.xsl"); -
2. Re: Reading files from another archive
eriksson.viktor Mar 16, 2009 7:20 PM (in response to eriksson.viktor)Thank you.
But it is not possible to read from other archives or ?
Is this maybe a more correct way to do things ? -
3. Re: Reading files from another archive
eriksson.viktor Mar 16, 2009 8:46 PM (in response to eriksson.viktor)Think I found out how to do it.
I compiled my configuration stuff into a jar with 1 dummy sourcefile.
I then import this sourcefile in my real application and type:
DummyFile.class.getResourceAsStream("/xsl/hello.xsl").read(bytes);