Andy, I've get the same problem, but I'm not trying to use the 'parses'
package, possibly the 'parsers' package (org.apache.xml.parsers.*).  My JRE
directory (rather, the one that the sysadmin has installed) does not even
contain an 'ext' directory inside of 'lib'.

My stack trace looks like this:

Exception in thread "main" java.lang.NoClassDefFoundError:
org/apache/xerces/parsers/AbstractDOMParser
        at
com.westgroup.morpheus.filters.dom.XFilter$1.startElement(XFilter.java:155)
        at
org.apache.xerces.parsers.SAXParser.startElement(SAXParser.java:1340)
        at
org.apache.xerces.validators.common.XMLValidator.callStartElement(XMLValidat
or.java:965)
        at
org.apache.xerces.framework.XMLDocumentScanner.scanElement(XMLDocumentScanne
r.java:1858)
        at
org.apache.xerces.framework.XMLDocumentScanner$ContentDispatcher.dispatch(XM
LDocumentScanner.java:1234)
        at
org.apache.xerces.framework.XMLDocumentScanner.parseSome(XMLDocumentScanner.
java:381)
        at org.apache.xerces.framework.XMLParser.parse(XMLParser.java:952)
        at org.apache.xerces.framework.XMLParser.parse(XMLParser.java:991)
        (...more stack that refers to my code...)

The line of code that's killing it is:

        System.err.println ("adding InputRules to rulesTable...");
-->     rulesTable.put (pKey, new RulesBuilder().parseRulesFiles (rules,
layout));
        System.err.println ("Done.");

where 'rulesTable' is a Hashtable, 'pKey' is a string, and 'RulesBuilder' is
a class of my own that does some additional parsing.  It's constructor is
empty, but execution doesn't even get that far -- I put a
System.err.println() in the constructor which doesn't get printed before the
stack trace.

The above line is located in an anonymous class of HandlerBase to handle the
startElement event of a prior SAX parse.  There's no logical reason that I
can find why I should get this exception at this point.

I've attached the code for these two classes in case someone has some time
to glance over the problem method and see something that I don't.

I appreciate all your help in this matter.  It is important to discover this
as either a bug in Xerces2, or a pitfall for some people making the
transition from X1 to X2 especially now since X1 will not likely be having
any more releases.

Sincerely,

Brion Swanson
Sofware Developer
West Group


-----Original Message-----
From: Andy Clark [mailto:[EMAIL PROTECTED]
Sent: Monday, August 20, 2001 10:05 PM
To: [EMAIL PROTECTED]
Subject: Re: Help, Xerces 2.0 beta install problem


Youngjoon Ryu wrote:
> and set classpath=d:\work\Xerces\xerces.jar
> Exception in thread "main" java.lang.NoClassDefFoundError:
org/apache/xerces/parses/AbstractDOMParse
> error: Unable to instantiate parse (org.apache.xerces.parses.SAXParse)

Sounds like a classpath problem because those classes (and the
"parses" package) don't even exist in Xerces2. Is something
tucked away in your lib/ext directory of your JRE?

-- 
Andy Clark * IBM, TRL - Japan * [EMAIL PROTECTED]

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Attachment: RulesBuilder.java
Description: Binary data

Attachment: XFilter.java
Description: Binary data

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to