<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>

<META NAME="Generator" CONTENT="MS Exchange Server version 6.5.7638.1">
<TITLE>[jdom-interest] yet another NoClassDefFoundError</TITLE>
</HEAD>
<BODY>
<DIV id=idOWAReplyText49905 dir=ltr>
<DIV dir=ltr><FONT face=Arial color=#000000 size=2><A 
href="http://jakarta.apache.org/regexp/">http://jakarta.apache.org/regexp/</A></FONT></DIV></DIV>
<DIV dir=ltr><BR>
<HR tabIndex=-1>
<FONT face=Tahoma size=2><B>From:</B> jdom-interest-bounces@jdom.org on behalf 
of Tobias Thierer<BR><B>Sent:</B> Tue 5/30/2006 8:45 PM<BR><B>To:</B> 
jdom-interest@jdom.org<BR><B>Subject:</B> [jdom-interest] yet another 
NoClassDefFoundError<BR></FONT><BR></DIV>
<DIV>
<P><FONT size=2>Hi,<BR><BR>I have an XML document to parse in the 
form:<BR><BR>&lt;a&gt;<BR>&nbsp; &lt;b&gt;...&lt;/b&gt;<BR>&nbsp; 
&lt;b&gt;...&lt;/b&gt;<BR>&nbsp; &lt;b&gt;...&lt;/b&gt;<BR>&nbsp; ..<BR>&nbsp; 
&lt;b&gt;...&lt;/b&gt;<BR>&lt;/a&gt;<BR><BR>The whole document is too large to 
hold in memory, so I wanted to get only<BR>one b-element at the time from the 
parser. I tried to use ElementScanner and<BR>ElementListener from jdom-contrib, 
but run into a NoClassDefFoundError when<BR>I call<BR><BR>&nbsp;&nbsp; 
elementScanner.addElementListener(elementListener, "/a/*");<BR><BR>I also get 
the error when I try the ElementScannerTest.java example file<BR>(attached) that 
comes with the jdom-contrib documentation. The error occurs<BR>in line 384 of 
XPathMatcher.java, where it tries to call<BR><BR>&nbsp; 
Class.forName("org.jdom.contrib.input.scanner.JakartaRegExpXPathMatcher")<BR><BR>this 
fails with a NoClassDefFoundError which is then caught and masked, so<BR>in the 
end I get the following error message:<BR><BR>Exception in thread "main" 
java.lang.NoClassDefFoundError:<BR>org/apache/regexp/RESyntaxException<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
at java.lang.Class.forName0(Native 
Method)<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; at 
java.lang.Class.forName(Class.java:164)<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
at<BR>org.jdom.contrib.input.scanner.XPathMatcher.newXPathMatcher(XPathMatcher.java:384)<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
at<BR>org.jdom.contrib.input.scanner.ElementScanner.addElementListener(ElementScanner.java:240)<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
at ElementScannerTest.main(ElementScannerTest.java:23)<BR><BR><BR>I've searched 
this mailinglist's archives and there were plenty repors 
of<BR>NoClassDefFoundErrors, but none of them in conjunction with 
RESyntaxException.<BR><BR>I have observed this problem on three different 
machines, but still wonder<BR>if it might be a configuration problem. Any ideas 
or hints would be greatly<BR>appreciated.<BR><BR>Thanks in 
advance,<BR><BR>&nbsp; Tobias<BR><BR>P.S.: An IntelliJ project including 
jdom.jar, jdom-contrib.jar and<BR>ElementScannerTest.java which exhibits the 
above error can be downloaded<BR>from: <A 
href="http://www.tobias-thierer.de/stuff/jdom-error.zip">http://www.tobias-thierer.de/stuff/jdom-error.zip</A><BR><BR></FONT></P></DIV>

</BODY>
</HTML>