Babel-17 can call Java now

I have done some serious thinking about how to use Babel-17 to power my projects like Applied Cuisine.

The main backend for my projects is going to be Google App Engine (GAE). So it would be great if I could use Babel-17 for GAE development. The first step to achieve this has been done now. Babel-17 can call Java now. Here is an example:

val s = native New ("java.lang.Short", 2)
val ar = native New ("java.util.ArrayList")
val _ = 
  begin
    ar.add 1
    ar.add 10
    ar.add 5
    ar.add s
    ar.add ((18, 13, 15),)
  end
ar.toArray ()

The above code evaluates to (1,10,5,2,(18,13,15)).

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


%d bloggers like this: