Solved

Zipping classes in packages

Posted on 1997-05-07
4
224 Views
Last Modified: 2010-04-16
My applet is a bit large, about 120k.

So I'm trying to create ZIP, CAB and JAR files for it.

My package structure looks like:  myOrg.appname.modules
Where I have two "modules" packages, with the applet class
sitting at the myOrg.appname level.

My code parameter is:  CODE="myOrg.appname.myApplet.class"

I've created a working CAB file, that was easy.

I'm having trouble with the the ZIP format.  Using
PKZIP for windows I've tryed storing the class files in the Zip file, without and without relative path names to the
base of my package tree.

When I load the zip file with Netscape Nav, it says "Applet can't start: class myOrg.appname.applet.class not found".  
Does anyone know why?  Has anyone had some experience using the ZIP format with packaged classes?

No, I'm not compressing the class files when I Zip them.

Thanks in advance.
Gerry Rempel
grempel@acm.org
0
Comment
Question by:gerry99
  • 2
4 Comments
 

Expert Comment

by:pedxing
ID: 1220222
Which version of PKZIP?  Does it handle long filenames?

0
 
LVL 1

Author Comment

by:gerry99
ID: 1220223
I'm using Pkzip 2.50, 32-bit version for windows.  It handles long file names.

0
 

Accepted Solution

by:
ddyer earned 50 total points
ID: 1220224

use winzip32 rather than pkzip, point at the root of your java
hierarchy, and use "add with wildcards".  The files in the
archive should have pathnames with the same components as
fully qualified class names; if your class is foo.baar.*
the classes should shop up in winzip as foo\bar\

There's a nifty java package called "greenbay" which
does the right thing, and is easier to use than zip
- you just feed it the packages you want archived.
Find greenbay by searching dejanews

0
 
LVL 1

Author Comment

by:gerry99
ID: 1220225
Thanks for the advice.

Winzip32 is easy to use for this task.

I think my fundamental problem may have been that I was spelling
"archive" as "arhive".

I couldn't find any reference to this "greenbay", however I'll be fine using winzip.

Gerry
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This was posted to the Netbeans forum a Feb, 2010 and I also sent it to Verisign. Who didn't help much in my struggles to get my application signed. ------------------------- Start The idea here is to target your cell phones with the correct…
Introduction This article is the last of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers our test design approach and then goes through a simple test case example, how …
Viewers learn how to read error messages and identify possible mistakes that could cause hours of frustration. Coding is as much about debugging your code as it is about writing it. Define Error Message: Line Numbers: Type of Error: Break Down…
The viewer will learn how to implement Singleton Design Pattern in Java.

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question