Herve,

> I'm taking a look at Avail. I want to know whether or not one can call a Java 
> API method or Java program method inside an Avail piece of code ? Is there an 
> Avail module allowing to make such a bridge with a Java program ?

Yes, have a look at /avail/Avail/Foundation/Pojos. Also search the library for 
references to “pojo”. My guess is that will locate all of the primitives 
related to binding Java from Avail.

Unfortunately the mechanism is woefully under-documented right now. I developed 
the Java connection, and I think that I’m the only one who has used it so far. 
Also, while I was trying to put together an example of how to use it for you, I 
encountered a problem that I couldn’t trivially get past. It looks like I broke 
something the last time that I maintained the code, and I note that there are 
no unit tests. It looks like it is possible to create pojo types, and to bind 
and invoke constructors to obtain instances of them, but I was unable to bind a 
trivial method (other than one provided by java.lang.Object). So that won’t get 
you very far…

This mechanism used to work — we built part of a roguelike game using it — so 
it probably won’t take much to get it working again. I’ll create an issue in 
Trac later today. I’m not sure when I’ll get around to actually fixing this — 
Mark and I are neck-deep in macros, and I’m about to transition back to writing 
documentation for the website (in anticipation of our long overdue milestone 
release).

Sorry I don’t have a more immediately positive answer for you!


Todd L Smith
CEO | The Avail Foundation, LLC
http://www.availlang.org


Reply via email to