Search code examples
javajarembedded-resourcejnlpjava-web-start

JNLP download location for jars on to your local system.


Is there a way to determine where the jars have been downloaded while accessing JNLP file. Can it be governed programatically.?

I need to extract a resource from jar to use it for further processing.

It would be better even if I can specify that download jars at same location as JNLP file. Is it possible?


Solution

  • I need to extract a resource from jar to use it for further processing.

    Use the technique mentioned in the embedded resource info. page to get an URL. Either provide the URL for further processing (e.g. most J2SE methods that accept input resources will accept an URL). Or get an input stream from the URL and use that.

    Can it be governed programatically?

    No, or rather, not by client JWS applications.

    It would be better even if I can specify that download jars at same location as JNLP file. Is it possible?

    Do you mean the location it is cached on the local disks? Since it is not possible to find the location the JNLP is cached, I do not see how that would help. But to answer your question. Again, no.