[kepler-dev] [Bug 1835] - create jni cookbook for creating jni actors

bugzilla-daemon@ecoinformatics.org bugzilla-daemon at ecoinformatics.org
Thu Dec 16 07:40:41 PST 2004


------- Additional Comments From cxh at eecs.berkeley.edu  2004-12-16 07:40 -------
Perhaps some of the resources below can be used as a starting point.

The Matlab actor uses JNI.

Ptolemy II includes a JNI actor facility, but the UI is broken right now.

How to use the JNI actor facility is covered in ptII/jni/demo/jni/README.htm

The release notes say:
Limitations in JNI
# The Interface to C actors using the Java Native Interface is not available via
the Windows Installer (or Web Start). To use the JNI/Ptolemy II interface, you
must download Ptolemy II as source files and compile.
# The JNI user interface does not permit creation of new JNI actors.

If you follow the instructions in JNIUtilities, then eventually you will get a

The resulting model will be missing

<property name="output" class="jni.Argument" value="false,false,true,double">

We are working with the original authors on a solution.
In the short term, one workaround is to edit the xml file directly and add the
appropriate property by hand.
# JNI will not work with Hierarchical classes, subclasses, and inner classes 

In addition, there are problems with the JNI interface under gcc-3.3, gcc-3.2
is recommended.

More information about the Kepler-dev mailing list