What'd be a good way to get access to a deployed WAR's content using VFS?

Right now, I'm doing:
servletContext.getRealPath("") + File.separator + "WEB-INF" + File.separator
+ "classes" + File.separator + path;

And this quite inconvenient to rely on servletContext since I don't have
access to it in lower layers, not speaking about the test, which in
isolation don't even run in a ServletContext.

I don't see any other way than using the local file system. But if I do so,
I'll get an absolute path, not a relative to the deployment folder one.

Any idea?
-- 
View this message in context: 
http://www.nabble.com/-commons-vfs--accessing-exploded-WAR-content-at-runtime-tp25971229p25971229.html
Sent from the Commons - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org

Reply via email to