• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Applet .jar files and libraries

 
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am having a heck of a time getting my applet to be able to read its required libraries. I have seen threads here and there on this issue, but have not been able to find straightforward language on what is required. My situation is as follows:

I have an applet that uses the Java Advanced Imaging API and thus needs to read in classes from jai_codec.jar and jai_core.jar, among others. The Applet itself must be able to load files from the local server and therefore it must (as far as I understand) be archived in a signed .jar file (please correct me if I'm wrong on this). The problem is that the applet cannot find the other .jar files it needs to read from.

Now, I have seen some indication that perhaps these libraries must be included in the 'archive' attribute in the Applet tag. I have not tried this yet, but this solution does not appeal to me since the libraries required by the Applet may be quite numerous. I have tried simply dropping the external .jar file into the same directory as the Applet's .jar file, and also including them in the root directory of the Applet's .jar file, to no avail.

I would like to know if adding these libraries to the 'archive' attribute is the only way (and/or the preferred way) to accomplish what I am trying to do, or if there is some other way to load these libraries so that the Applet can find them.


Thank you,

Justin Ellis
 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Adding them to the archive attribute is the only way. Note that they also *may* need to be signed; I'm not quite sure on that.
 
J Ellis
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ulf,

Thank you so much for the quick and succinct reply. I can verify that I did not have to sign the library .jar files.


Justin Ellis
reply
    Bookmark Topic Watch Topic
  • New Topic