From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,112bc0825846dede X-Google-Attributes: gid103376,public From: stt@henning.camb.inmet.com (Tucker Taft) Subject: Re: Ada and Java Date: 1996/03/20 Message-ID: X-Deja-AN: 143390769 sender: news@inmet.camb.inmet.com (USENET news) x-nntp-posting-host: henning.camb.inmet.com references: <4inoks$kak@mica.inel.gov> organization: Intermetrics, Inc. newsgroups: comp.lang.ada Date: 1996-03-20T00:00:00+00:00 List-Id: Paul Whittington (paul@srv.net) wrote: : homeboy@nando.net () wrote: : > ... : >Basically, Intermetrics is developing a compiler that will take Ada95 code : >(excluding some features) and kick out the Java architecture neutral byte : >codes. ... : I've heard of this Ada 95 JVM compiler and I've read the Intermetrics : web page on it, but has anyone actually seen it? We have distributed a small number of "alpha" versions. : Is there an expected availability date for a commercial version and : what will be the configurations and costs? A "beta" version is due out this week. Stay tuned... : What does the Ada 95 interface to the Java class library look like? There is an Ada package corresponding to each Java class in the API. I have included a copy of the Ada package corresponding to standard class java.util.Hashtable at the end of this message. The typical way to use such a package is to "with" and "use" it (horrors ;-). The type names are designed to make "use" appropriate. We considered other conventions, but this seems to provide the most direct mapping. : Is Intermetrics going to publish the specs for the Java class library : interface in the hopes that it will become a standard, or to get input : from others? We do hope it will become a standard, and comments are certainly welcome. The mapping to Java is so direct that hopefully there isn't too much to debate (but there is always *something* to debate ;-). : Is there a beta program? Yes. You will be able to download a Sparc, Win32, and (soon) a Mac version of the Ada/Java "beta". The product is called AppletMagic(tm), by the way. Keep an eye on http://www.inmet.com/java.html, or comp.lang.ada. -Tucker Taft stt@inmet.com http://www.inmet.com/~stt/ Intermetrics, Inc. Cambridge, MA USA ------ Ada package interface corresponding to java.util.Hashtable ---- with java.util.Dictionary; use java.util.Dictionary; with java.lang.String; use java.lang.String; with java.util.Enumeration; use java.util.Enumeration; with java.lang.Cloneable; use java.lang.Cloneable; with java.lang; use java.lang; package java.util.Hashtable is type Hashtable_Obj is new Dictionary_Obj with record Cloneable : aliased Cloneable_Obj; -- implements Cloneable end record; type Hashtable_Ptr is access all Hashtable_Obj'Class; function new_Hashtable( initialCapacity : Integer; loadFactor : Float; this : Hashtable_Ptr := null) return Hashtable_Ptr; function new_Hashtable( initialCapacity : Integer; this : Hashtable_Ptr := null) return Hashtable_Ptr; procedure init_Hashtable(this : access Hashtable_Obj'Class); function new_Hashtable(this : Hashtable_Ptr := null) return Hashtable_Ptr; function size(this : access Hashtable_Obj) return Integer; function isEmpty(this : access Hashtable_Obj) return Boolean; function keys(this : access Hashtable_Obj) return Enumeration_Ptr; function elements(this : access Hashtable_Obj) return Enumeration_Ptr; function contains(this : access Hashtable_Obj; value : Object_Ptr) return Boolean; function containsKey(this : access Hashtable_Obj; key : Object_Ptr) return Boolean; function get(this : access Hashtable_Obj; key : Object_Ptr) return Object_Ptr; function put(this : access Hashtable_Obj; key : Object_Ptr; value : Object_Ptr) return Object_Ptr; function remove(this : access Hashtable_Obj; key : Object_Ptr) return Object_Ptr; procedure clear(this : access Hashtable_Obj); function clone(this : access Hashtable_Obj) return Object_Ptr; function toString(this : access Hashtable_Obj) return String_Ptr; pragma Import(Java, contains); pragma Import(Java, containsKey); pragma Import(Java, clone); pragma Import(Java, put); pragma Import(Java, elements); pragma Import(Java, remove); pragma Import(Java, size); pragma Import(Java, get); pragma Import(Java, clear); pragma Import(Java, keys); pragma Import(Java, isEmpty); pragma Import(Java, toString); pragma Import(Java_Constructor, init_Hashtable); pragma Import(Java_Constructor, new_Hashtable); end java.util.Hashtable;