Hello,
I've tried to call java from my flowscript as shown here:
http://cocoon.apache.org/2.1/userdocs/flow/java.html
However, I get a compilation error when I try to load my webpage. First,
is there anywhere to see specifics about the compilation error
encountered? All it tells me is Compilation produced 1 syntax error on
line 1.
Also, are there any more complete examples of calling java from
flowscript?
And finally, any ideas on what may be wrong?
Here's my main flowscript function, which otherwise works until I add
the java Date stuff:
function main()
{
var d = new java.util.Date();
d.year = 2003; // same effect as d.setYear(2003);
getInfo();
upload();
var uri = neutralInstModel "/" + inputType + "In/" + inputFile + "/"
+ inputType + "In.trans/" + cocoon.continuation.id;
cocoon.sendPage(uri);
}
And here's my flow-interpreters entry in cocoon.xcon:
<flow-interpreters default="javascript" logger="flow">
<!-- FOM (Flow Object Model) -->
<component-instance
class="org.apache.cocoon.components.flow.javascript.fom.FOM_JavaScriptIn
terpreter" name="javascript">
<load-on-startup>resource://org/apache/cocoon/components/flow/javascript
/fom/fom_system.js</load-on-startup>
<reload-scripts>true</reload-scripts>
<check-time>4000</check-time>
<classpath>file:C:/Program Files/Apache Software Foundation/Tomcat
6.0/webapps/SIF/WEB-INF/lib</classpath>
<!-- <debugger>enabled</debugger> --> <!-- JavaScript Debugger
support -->
</component-instance>
<!--..... Start configuration from 'apples-processor' -->
<component-instance
class="org.apache.cocoon.components.flow.apples.ApplesProcessor"
logger="apples" name="apples">
<!--
<load-on-startup>resource://org/apache/cocoon/components/flow/javascript
/fom/fom_system.js</load-on-startup>
<reload-scripts>true</reload-scripts>
<check-time>4000</check-time>
-->
</component-instance>
<!--..... End configuration from 'apples-processor' -->
<!--..... Start configuration from 'javaflow' -->
<component-instance
class="org.apache.cocoon.components.flow.java.JavaInterpreter"
name="java"/>
<!--..... End configuration from 'javaflow' -->
</flow-interpreters>
Thanks!
Jeff
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]