commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jim Barnett <Jim.Barn...@genesyslab.com>
Subject RE: [scxml] standalone example not working
Date Wed, 12 Dec 2012 12:49:09 GMT
A bit more detail.  I'm trying to get the StandaloneJexlExpressions example to work, as described
on the commons website (http://commons.apache.org/scxml/guide/testing-standalone.html), specifically:

java -classpath

    commons-digester-1.8.1.jar;commons-beanutils-1.8.0.jar;
    commons-logging-1.1.1.jar;commons-scxml-0.9.jar;
    commons-jexl-1.1.jar

    org.apache.commons.scxml.test.StandaloneJexlExpressions  microwave01.xml

When I run this code, I get a missing class def error:

Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/commons/jexl/JexlContext
        at org.apache.commons.scxml.env.jexl.StandaloneJexlExpressions.main(StandaloneJexlExpressions.java:62)
Caused by: java.lang.ClassNotFoundException: org.apache.commons.jexl.JexlContext
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)

The relevant line in StandaloneJexlExpressions.java is the one that instantiates the JexlEvaluator:

   Evaluator evaluator = new JexlEvaluator();

The code for the JexlEvaluator class references the JexlContext class, but what's puzzling
about this error is that it is looking for JexlContext in the wrong package.  (JexlContext
is in org.apache.commons.scxml.env.jexl, not org/apache/commons/jexl.) Furthermore I get the
same error even if I a) include the org/apache/commons/scxml/env/jexl/JexlContext package
in the JexlEvaluator.java source file, or b) modify the JexlEvaluator.java code to use the
correct fully qualified package name for JexlContext (i.e., org.apache.commons.scxml.env.jexl.JexlContext).
 

So I'm puzzled.  There's obviously something about the package layout that I don't understand.
 I'd be grateful for any suggestions.  

- Jim

-----Original Message-----
From: Stadelmann Josef [mailto:josef.stadelmann@axa-winterthur.ch] 
Sent: Wednesday, December 12, 2012 3:47 AM
To: Commons Users List
Subject: AW: [scxml] standalone example not working

sometimes you get help if you tell the community which calls is missing.
for that we would need the stack trace and perhaps a fragment of your source code causing
the problem.

Josef 


-----Urspr√ľngliche Nachricht-----
Von: Jim Barnett [mailto:Jim.Barnett@genesyslab.com]
Gesendet: Dienstag, 11. Dezember 2012 14:35
An: user@commons.apache.org
Betreff: [scxml] standalone example not working

Has anyone gotten the StandaloneJexlExpressions example to work?  When I run it, I get a missing
class error.   Any guidance would be appreciated.

thanks


-          Jim

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@commons.apache.org
For additional commands, e-mail: user-help@commons.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@commons.apache.org
For additional commands, e-mail: user-help@commons.apache.org


Mime
View raw message