[armedbear-cvs] r13949 - in trunk/abcl/contrib/jfli: . examples examples/swing examples/swt
mevenson at common-lisp.net
mevenson at common-lisp.net
Tue May 29 07:10:03 UTC 2012
Author: mevenson
Date: Tue May 29 00:10:01 2012
New Revision: 13949
Log:
abcl-contrib: Add jfli.
The Java Foreign Linker Interface (JFLI) provides an abstraction to
manipulate Java classes from Armed Bear Common Lisp that has been
ported to other Lisp implementations.
Incorporated into ABCL from <git://github.com/mrohne/jfli>.
Added:
trunk/abcl/contrib/jfli/
trunk/abcl/contrib/jfli/README
trunk/abcl/contrib/jfli/examples/
trunk/abcl/contrib/jfli/examples/swing/
trunk/abcl/contrib/jfli/examples/swing/README
trunk/abcl/contrib/jfli/examples/swt/
trunk/abcl/contrib/jfli/examples/swt/README
trunk/abcl/contrib/jfli/examples/swt/file.gif (contents, props changed)
trunk/abcl/contrib/jfli/examples/swt/folder.gif (contents, props changed)
trunk/abcl/contrib/jfli/jfli.asd
Added: trunk/abcl/contrib/jfli/README
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ trunk/abcl/contrib/jfli/README Tue May 29 00:10:01 2012 (r13949)
@@ -0,0 +1,36 @@
+JFLI
+====
+
+The Java Foreign Linker Interface (JFLI) provides an abstraction to
+manipulate Java classes from Armed Bear Common Lisp that has been
+ported to other Lisp implementations.
+
+Incorporated into ABCL from <git://github.com/mrohne/jfli>.
+
+
+README
+------
+
+jfli (http://jfli.sf.net) is a library that provides access to Java
+from Lisp. jfli-abcl is jfli modified to work with ABCL
+(http://armedbear-j.sf.net); it provides the same interface to Java,
+but, since ABCL lives on the JVM, it doesn't need jni.
+
+jfli-abcl has an experimental NEW-CLASS macro that writes and loads a
+Java class at runtime, and defines the usual jfli-like Lisp interface
+to it. See the documentation of NEW-CLASS and the examples for the
+syntax. If you want to use it, make sure that (1) asm.jar
+(http://asm.objectweb.org) is in your classpath, and (2) the runtime
+generated Java classes are in the Java package of the same name as the
+Lisp package in which they're defined, like this:
+
+(in-package "FOO")
+(new-class "FOO.MyClass" ...)
+
+Caveats: jfli-abcl inherits all the bugs from jfli; see the archives
+of the jfli-users mailing list for a partial list. It probably also
+adds some of its own. I'm particularly interested in the latter type.
+
+Please send (ABCL-specific) bug reports, suggestions, examples,
+and whatever else you can think of, to asimon at math.bme.hu.
+
Added: trunk/abcl/contrib/jfli/examples/swing/README
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ trunk/abcl/contrib/jfli/examples/swing/README Tue May 29 00:10:01 2012 (r13949)
@@ -0,0 +1,10 @@
+This is a swing/jdbc example.
+
+To try it, (compile and) load table-gen.lisp and table.lisp
+(you need to modify it a bit first if you're not using PostgreSQL), in
+this order, then do
+
+(table:create-and-show-gui "select * from <your table here>")
+
+The cells are editable, so don't try it on an important db table.
+
Added: trunk/abcl/contrib/jfli/examples/swt/README
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ trunk/abcl/contrib/jfli/examples/swt/README Tue May 29 00:10:01 2012 (r13949)
@@ -0,0 +1,27 @@
+This example is a Lisp version of Explorer v9 from
+http://www-106.ibm.com/developerworks/opensource/library/os-ecgui3/
+The gifs are from
+ftp://www6.software.ibm.com/software/developer/library/os-ecgui3/examples.zip
+
+To use it, (optionally compile) and load swt9jfli-gen.lisp first, and
+then swt9jfli.lisp. Start it with (swt0:main).
+
+But make sure first that besides asm.jar (http:/asm.objectweb.org),
+the various swt-related jars are in your classpath. I start abcl like
+this:
+
+/usr/java/jdk1.5.0/bin/java -cp /home/simon/java/j2/j/src/\
+:/usr/share/java/pg74.215.jdbc3.jar\
+:/home/simon/java/asm-1.5.1/lib/asm-1.5.1.jar\
+:/opt/home/simon/java/eclipse/plugins/org.eclipse.core.boot_2.1.3/boot.jar\
+:/opt/home/simon/java/eclipse/plugins/org.eclipse.core.runtime_2.1.1/runtime.jar\
+:/opt/home/simon/java/eclipse/plugins/org.eclipse.jface_2.1.3/jface.jar\
+:/opt/home/simon/java/eclipse/plugins/org.eclipse.jface.text_2.1.0/jfacetext.jar\
+:/opt/home/simon/java/eclipse/plugins/org.eclipse.swt.gtk_2.1.3/ws/gtk/swt.jar\
+:/opt/home/simon/java/eclipse/plugins/org.eclipse.swt.gtk_2.1.3/ws/gtk/swt-pi.jar\
+ -Djava.library.path=/opt/home/simon/java/eclipse/plugins/org.eclipse.swt.gtk_2.1.3/os/linux/x86/\
+:/home/simon/java/jogl/\
+ org.armedbear.lisp.Main "$@"
+
+If everything goes well, a window like
+http://www.math.bme.hu/~asimon/lisp/swt.png should appear.
Added: trunk/abcl/contrib/jfli/examples/swt/file.gif
==============================================================================
Binary file. No diff available.
Added: trunk/abcl/contrib/jfli/examples/swt/folder.gif
==============================================================================
Binary file. No diff available.
Added: trunk/abcl/contrib/jfli/jfli.asd
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ trunk/abcl/contrib/jfli/jfli.asd Tue May 29 00:10:01 2012 (r13949)
@@ -0,0 +1,5 @@
+(defpackage :jfli-system (:use :cl :asdf))
+(in-package :jfli-system)
+
+(defsystem jfli
+ :components ((:file "jfli")))
More information about the armedbear-cvs
mailing list