Ok,
 
Now it looks like I need something special to use _javascript_ within bsf....
 
Looking at the build.xml that is used to build bsf, it looks like it is
checking for the availability of
 
    <available property="rhino.present"
               classname="org.mozilla._javascript_.Scriptable"/>
 
Anyone know where I can find this class?  Am I missing some
documentation somewhere that describes this, or does it just
not exist anywhere.  In the Ant doc under optional tasks, it
describes the <script> task, and makes it sound as though it
is just hunky-dory to just start using it....Hmmm....
 
Error log below:
 
BUILD FAILED
 
D:\NewWork\SourceRoot\text2.xml:8: java.lang.ClassNotFoundException: com.ibm.bsf.engines._javascript_._javascript_Engine
java.lang.ClassNotFoundException: com.ibm.bsf.engines._javascript_._javascript_Engine
        at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:297)
        at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:286)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:253)
        at com.ibm.bsf.BSFManager.loadScriptingEngine(BSFManager.java:316)
        at com.ibm.bsf.BSFManager.exec(BSFManager.java:481)
        at org.apache.tools.ant.taskdefs.optional.Script.execute(Script.java:110)
        at org.apache.tools.ant.Target.execute(Target.java:142)
        at org.apache.tools.ant.Project.runTarget(Project.java:818)
        at org.apache.tools.ant.Project.executeTarget(Project.java:532)
        at org.apache.tools.ant.Project.executeTargets(Project.java:506)
        at org.apache.tools.ant.Main.runBuild(Main.java:420)
        at org.apache.tools.ant.Main.main(Main.java:149)
 
Jason
 
----- Original Message -----
Sent: Tuesday, December 26, 2000 10:34 AM
Subject: Re: Problem using script task

Ok,
 
So, once I build the BSF stuff, do I then need to include something in my
classpath so that Ant will use it?  Is this documented already somewhere?
I didn't see anything, so far...
 
Jason
----- Original Message -----
Sent: Tuesday, December 26, 2000 8:56 AM
Subject: Re: Problem using script task

----- Original Message -----
Sent: Tuesday, December 26, 2000 7:26 AM
Subject: Re: Problem using script task

Also,
 
When I installed Ant1.2, I installed the binary version, and so I don't
have any bootstrap files to run, etc....I manually placed the optional.jar
in my /Ant1.2/lib directory, and the ant script is finding it ok and adding
it to the classpath.....
 
I get the same error with a <junit> class, so I think I am definitely not
properly configured for optional tasks.
 
Jason
You need some external packages to use <script> and <junit>.
 
For junit: Download JUnit from http://sourceforge.net/projects/junit/
For scripting: BSF (Bean Scripting Framework) is hosted at http://oss.software.ibm.com/developerworks/opensource/bsf/index.html. Unfortunately there is no binary download available and you must get (and build) it yourself.
 
Nico
 
 

Reply via email to