querying contents of jar file from webstart

in a webstart app I would like to query the contents of one of the jars that webstart is running from. in specific I want find all files in the jar with suffix ".cfg". I know I can do this with the JarFile class, but JarFile requires the path to the JarFile which is unclear if thats possible from webstart. I know also I can do a getResource via a Class/ClassLoader but as far as I can tell that requires a specific filename - not a catchall like *.cfg. I also tried making my own class loader (with system loader as parent) and querying the getLibrary method with the name of my jar but it didnt work. Any notions? Thanks for your help - Mark

mgibson@fruitfly.org

[678 byte] By [gusgibsona] at [2007-11-26 20:17:12]
# 1
you gan use getResource() with the original url to the resource, and the JNLPClassLoader in latest versions of Java Web Start will access it from the cache without re-downloading it./Andy
dietz333a at 2007-7-10 0:40:25 > top of Java-index,Desktop,Deploying...
# 2
I recently had a need to do this also but worked around it. If you figure out how to do it I'd like to see the code. What is the JAR's original URL is that like "jar:file:JARNAME!/"?
javaunixsolarisa at 2007-7-10 0:40:25 > top of Java-index,Desktop,Deploying...