ANNOUNCE: Haskell/Java VM Bridge 0.2 Release
Thu, 10 Apr 2003 09:37:58 -0700
Release 0.2 of Haskell/Java VM Bridge is now available in source-code
New in Version 0.2:
* 'Haskell' now a separate Autotools project installing in
* New array region access functions
* Correct array types in autogenerated class interfaces
* Subtype parameters in autogenerated class interfaces
* VMLayer 'env' parameter now implicit
* Various changes in the BasicLayer
* new native StartExecuteFunction function called by
* Mac OS X support
* Beginnings of MinGW32/Cygwin support
* New Sun 1.4 JVM
* Now installs in /usr/lib/jvm-bridge/
* ExecuteFunction bindings now done at run-time
Haskell/Java VM Bridge allows Haskell programs access to the Java Virtual
Machine. It comes in two parts: the 'Native' part, that abstracts away
differences in the various Java VMs, and the 'Haskell' part that provides
a Haskell API. The Native part is not Haskell-specific, and could
potentially be used by other languages wishing to access the Java VM.
* Calling of Java methods, access to fields, array-handling;
* Integration of garbage collectors;
* Reconciliation of exception models;
* Reconciliation of thread models, including 'synchronized' monitor
support and the ability to fork Haskell actions as Java threads;
* Strong typing for Java classes and method argument lists (as tuples),
and use of Haskell lists as arrays;
* Creation of Java classes 'on the fly' (using DefineClass and the Java
Class File Format) that can have Haskell callback methods;
* Lifted monads which do all the necessary JNI class and method/field ID
preloading and 'JNIEnv'-pointer variable handling for you -- these can be
automatically generated via a tool (MakeJVMModule);
* Layered design includes lower-level IO-based interface;
* Automatic generation of modules for Java API classes;
* All relevant imports, flags and libraries etc. handled by a single GHC
* No 'unsafe' Haskell calls or pure function FFI anywhere;
* Easy to port to new Java VMs.
This release should be 'beta' quality, but has undergone little testing.
You will need:
* An x86 machine running some form of Unix, or a Mac OS X machine;
* GHC 5.02.4 or later;
In particular, GHC 5.02.2 and earlier will not work on Mac OS X.
* A Java VM. It's been tested only with Sun's JVM, but should (may?) work
with a number of others.
Haddock documentation is currently blocked on a bug in Haddock ("implicit
parameters"). Should that be fixed, you will be able to build API
documentaion by doing "make doc".
Some simple examples have been included such as a program that shows a
Java Frame containing an instance of a Haskell-defined subclass of Canvas
that has a Haskell 'paint' method that draws an oval. You should be able
to figure out most of it from that.
Haskell/JVM Bridge and source code is licensed under the GNU Lesser GPL.
* port to Cygwin
* use hierarchical module structure
* separate out pure (non-FFI) Haskell into a separate package
* better typing for the IO-based layer
Ashley Yakeley, Seattle WA
Almost empty page: <http://semantic.org/>