[jdom-interest] JDOM XPath error...help needed.

Laurent Bihanic laurent.bihanic at atosorigin.com
Tue Mar 18 00:39:10 PST 2003


Hi,

You are probably using an old beta version of Jaxen: Text.getValue() existed 
until JDOM beta 7 and was removed in beta 8.
Clean up your classpath and try using the Jaxen JARs included in the lib 
directory of the JDOM distribution (jaxen-core.jar, jaxen-jdom.jar and 
saxpath.jar). This should be Jaxen 1.0 FCS.

Laurent

Jason Long wrote:
> I am having a problem that I must resolve immediatly.  I am about to have
> the client sign off on this project, and a strange behavior has started.  I
> may be something I changed, but I do not think so.  Here is what is going
> on.
> 
> Example XPath:
> //item[@size='4.500' and @weight='11.60' and @grade='K-55' and @endFin='LTC'
> and @yard='A-A' and mill='New API Seamless Baoshan' and location='Houston,
> TX' and @status='IN STOCK']
> 
> This what working, but unexpectedly stopped.  I did upgrade to the latest
> code, but after I noticed this problem I started to use jdom8 again.  This
> did not fix the problem.   When this xpath is used now, I get the following
> error found at the end of this email.  I will work if I take the mill and
> location out of the xpath.  The difference is that these are text nodes and
> the rest are attributes.  I definately did not change the way I am
> generating the xpath, so I am a bit confused why this behavior started.  I
> need to fix this asap, so any advice would be greatly appreciated.
> 
> java.lang.NoSuchMethodError: org.jdom.Text.getValue()Ljava/lang/String;
> 	at
> org.jaxen.jdom.DocumentNavigator.getElementStringValue(DocumentNavigator.jav
> a:346)
> 	at org.jaxen.function.StringFunction.evaluate(StringFunction.java:52)
> 	at
> org.jaxen.expr.DefaultEqualsExpr.evaluateSetString(DefaultEqualsExpr.java:10
> 6)
> 	at org.jaxen.expr.DefaultEqualityExpr.evaluate(DefaultEqualityExpr.java:79)
> 	at org.jaxen.expr.DefaultAndExpr.evaluate(DefaultAndExpr.java:31)
> 	at org.jaxen.expr.DefaultAndExpr.evaluate(DefaultAndExpr.java:38)
> 	at org.jaxen.expr.DefaultAndExpr.evaluate(DefaultAndExpr.java:38)
> 	at org.jaxen.expr.DefaultAndExpr.evaluate(DefaultAndExpr.java:38)
> 	at org.jaxen.expr.DefaultAndExpr.evaluate(DefaultAndExpr.java:38)
> 	at org.jaxen.expr.DefaultAndExpr.evaluate(DefaultAndExpr.java:38)
> 	at org.jaxen.expr.DefaultPredicate.evaluate(DefaultPredicate.java:45)
> 	at org.jaxen.expr.PredicateSet.evaluatePredicates(PredicateSet.java:112)
> 	at
> org.jaxen.expr.DefaultLocationPath.evaluate(DefaultLocationPath.java:157)
> 	at
> org.jaxen.expr.DefaultAbsoluteLocationPath.evaluate(DefaultAbsoluteLocationP
> ath.java:65)
> 	at org.jaxen.expr.DefaultXPath.asList(DefaultXPath.java:46)
> 	at org.jaxen.JaXPath.jaSelectNodes(JaXPath.java:35)
> 	at org.jaxen.BaseXPath.selectNodes(BaseXPath.java:22)
> 	at com.jmlie.MP3_Publisher.inventory_test.doGet(inventory_test.java:103)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
> FilterChain.java:247)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
> ain.java:193)
> 	at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
> va:260)
> 	at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
> eNext(StandardPipeline.java:643)
> 	at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
> 	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
> 	at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
> va:191)
> 	at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
> eNext(StandardPipeline.java:643)
> 	at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
> 	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
> 	at
> org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2415)
> 	at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180
> )
> 	at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
> eNext(StandardPipeline.java:643)
> 	at
> org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.
> java:170)
> 	at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
> eNext(StandardPipeline.java:641)
> 	at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:172
> )
> 	at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
> eNext(StandardPipeline.java:641)
> 	at
> org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:509)
> 	at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
> eNext(StandardPipeline.java:641)
> 	at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
> 	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
> 	at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
> :174)
> 	at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
> eNext(StandardPipeline.java:643)
> 	at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
> 	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
> 	at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:223)
> 	at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:432)
> 	at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConne
> ction(Http11Protocol.java:386)
> 	at
> org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:534)
> 	at
> org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.jav
> a:530)
> 	at java.lang.Thread.run(Thread.java:536)
> 
> Jason Long - CEO and Chief Software Engineer
> Supernova Software - supernovasoftware.com
> BS Physics, MS  Chemical Engineering




More information about the jdom-interest mailing list