TEAM-ADA Archives

Team Ada: Ada Programming Language Advocacy

TEAM-ADA@LISTSERV.ACM.ORG

Options: Use Forum View

Use Monospaced Font
Show HTML Part by Default
Condense Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Sender:
"Team Ada: Ada Advocacy Issues (83 & 95)" <[log in to unmask]>
Subject:
From:
"W. Wesley Groleau x4923" <[log in to unmask]>
Date:
Fri, 17 Sep 1999 10:52:45 -0500
Reply-To:
"W. Wesley Groleau x4923" <[log in to unmask]>
Parts/Attachments:
text/plain (75 lines)
> There are not too many things that Ada would need to exceed Java.

If you don't need those particular things, Ada already exceeds Java.  If
you do need them, Ada (calling Java for those things) already exceeds
Java.

>   (a) The Java Runtime objects are automatically sequentialized
> (serialized) for distribution, while you have to write a serializer
> yourself in Ada providing for each type and each partition in that
> serializer code.
>
>   (b) The Java Runtime contains a reliable socket interface, while
> in Ada you have to write it yourself.
>
>   (c) The Java Runtime handles certain events automatically, while
> these events must be programmed manually in Ada.
>
>   (d) The Java Runtime handles graphics automatically (awt), while
> lighting up dots and filled rectangles on the screen must be
> programmed manually in Ada.

Many people have had no problem communicating between Ada and X-servers.
Plus, there is available at least one completely Ada implementation of
X11R6.

>   (e) The Java Runtime supports JINI device drivers by downloading a
> JINI class, while in Ada you have to write this yourself.

> It seems to me that if we program a generic serializer using
> stream_IO and the distributed annex, a reliable socket interface, a
> package of event handlers for keyboard/mouse/tablet/scsi/music/etc.,
> a package similar to awt, and an advertisement/lookup/execution
> service location package, Ada could have advantages similar to Java.
>
> What is missing is just a handful of packages. The people who have
> been posting software on the Ada lists have put in an amount of work
> in the last year equal to the task of writing this package. All that
> is needed is a group decision that Ada will have all these features
> of Java in one year and some TCP, unix, DOS, and JINI experts to
> implement these packages.

Look at it this way.

 There are some things that Java would need to exceed Ada.

  (a) Inheritance of primitive types, with range constraints (derived
      types and subtypes).  In Java, you have to write it yourself and you
      can't use operators on it.  To make a subtype, you have to code
      almost as much as the parent type.  To make a derived type,
      likewise, except how do you mimic Ada's feature that an object of
      the derived type can't copy its value to an object of the parent
      type?

  (b) Enumerated types.   In Java you have to write it yourself, and if
      you want to inherit from it with range constraints.....

  (c) In Ada, you can have multidimensional arrays, or arrays indexed by
      an enumerated type, or by a type that does not start at zero or end
      on 2**n-1, while such classes must be programmed manually in Ada,
      and must use a different syntax than "simple" arrays.

  (d) The Ada Runtime handles concurrency at a more abstract level, while
      this level must be programmed manually in Java using lower level
      constructs.

  (e) etc., etc., generics, blah, blah, real-time, yadda, yadda,
      Annex E vs. RMI, ....

It seems to me that if we program bindings to the Java predefined classes.....

What is missing is just a compiler that makes J-code from Ada....

What?  There already is one?  Oh, and Cobol and Eiffel and Smalltalk and
FORTH, too?  And others?  Wow.

ATOM RSS1 RSS2