On Tue, 5 Sep 2000, Bill Halchin wrote:

> Dear Man Chi Ly and others,
> 
>    I now have the CLASSPATH:
> 
> CLASSPATH=$HOME/FTP/xerces-1_1_3/xerces.jar (FTP is a directory
>      I put everything I download on Linux)
> export CLASSPATH
> 
> - I did a source on .bashrc
> - I echo'd $CLASSPATH
> - the .jar file is in the path
> 
> 
> but javac cannot see the imported classes/interfaces, i.e.

are you compiling using make or any other script, or just javac on the
command line?

> 
> import org.xml.sax.XMLReader;
> 
> import org.apache.xerces.parsers.SAXParser;
> 
> 
> - I did a "jar -tf xerces.java" to see if these class/interfaces
>      are present. The first one was. The second scrolled off my
>      GNome window/terminal. I tried piping to "more" but it seems
>      that output of jar is not to stdout. But anyway I saw the
>      first class/interface. The compiler complains about both
>       imports!!!
> 

just for reference:

$ jar tf ~/proj-mediator2/java/classes/xerces.jar | grep SAXParser
org/apache/xerces/parsers/SAXParser.class

The few times I tried using Xerces-J, I didn't have any peculiar problems
with it. We're currently using OpenXML, which is a derivative of Xerces-J.

> 
> Regards,
> 
> Bill Halchin
> 
> 
> >From: Man Chi Ly <[EMAIL PROTECTED]>
> >To: [EMAIL PROTECTED]
> >Subject: Re: Some jar utility and .jar questions
> >Date: Mon, 4 Sep 2000 15:11:35 -0700 (PDT)
> >
> >
> >
> >On Mon, 4 Sep 2000, Bill Halchin wrote:
> >
> > > Hello,
> > >
> > >    1) Can the javac compler extract classes from .jar files if
> > >          these files are in CLASS_PATH or must I "unjar"?
> >
> >yes, i.e.
> >
> >CLASSPATH=some/dir/classes:other/dir/xerces.jar
> >
> > >
> > >    2) I tried "jar -t xerces.jar" and the jar utility seems to be
> > >          waiting for more from StdIn?? I also tried "jar -x
> > >          xerces.jar" with the same results. ?
> > >
> >
> >type jar without any arguments to see the syntax to the tool (it's very
> >simple). What you want to do appears to be:
> >
> >jar tf xerces.jar
> >
> >The f argument signifies a file specification.
> >
> > >
> > >    I am trying to use the Apache Xerces SAX classes. Any help
> > >     would be greatly appreciated!
> > >
> > > Thanks,
> > >
> > > Bill Halchin
> > > 


----------------------------------------------------------------------
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to