[jboss-user] [Microcontainer] - Re: Using the VFS to read a resource from nested jars

jason.greene@jboss.com do-not-reply at jboss.com
Wed Dec 13 11:02:14 EST 2006


See the man test cases located here:

http://anonsvn.jboss.org/repos/jbossas/projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/

However, what you are looking for is DeploymentUnit.getMetaDataFile(String)

or 

DeploymentUnit.getFile(String)

The former searches relative to WEB-INF/META-INF the latter is at the root of the deployment.

If you were using the VFS outside of a deployer then the usage looks like this:

VFS vfs = VFS.getVFS(anyURL);
VirtualFile jar = vfs.findChild("something.txt");


View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3993444#3993444

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3993444



More information about the jboss-user mailing list