From: "Jean-Pierre Rosen" <rosen@adalog.fr>
Subject: Re: Multiple interface inheritance workaround in Ada 95 / Ada 0x to satisfy a Java language advocate?
Date: Tue, 30 Jul 2002 16:27:06 +0200
Date: 2002-07-30T16:27:06+02:00 [thread overview]
Message-ID: <ai67li$hh7$1@s1.read.news.oleane.net> (raw)
In-Reply-To: fXw19.29303$NX5.1749@nwrddc02.gnilink.net
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1006 bytes --]
"Hyman Rosen" <hyrosen@mail.com> a �crit dans le message news: fXw19.29303$NX5.1749@nwrddc02.gnilink.net...
> Jean-Pierre Rosen wrote:
> > It provides a design pattern for providing all the functionnality of Java interfaces
>
> Including cross-casting?
>
> That is, in Java (or C++), if I have class C implements I1, I2
> and I have an I1 reference, I can try casting the I1 to an I2,
> and if the reference is actually to a C object, the cast works.
>
> The attempts to simulate MI in Ada by using access discriminants
> don't handle this, as far as I know.
>
Yes. Or more exactly, the design pattern provides functions that allow you to get an I1 or I2 view for a C object, and to go back
from an I1 or I2 view back to the original C object.
And you are correct that this is not obvious to achieve. That's what prompted me to make a paper of it!
--
---------------------------------------------------------
J-P. Rosen (rosen@adalog.fr)
Visit Adalog's web site at http://www.adalog.fr
next prev parent reply other threads:[~2002-07-30 14:27 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-07-29 12:05 Multiple interface inheritance workaround in Ada 95 / Ada 0x to satisfy a Java language advocate? Colin Paul Gloster
2002-07-29 12:42 ` Jean-Pierre Rosen
2002-07-29 14:18 ` Colin Paul Gloster
2002-07-29 14:58 ` Jean-Pierre Rosen
2002-07-29 17:04 ` Pascal Obry
2002-07-30 13:57 ` Hyman Rosen
2002-07-30 14:27 ` Jean-Pierre Rosen [this message]
2002-07-30 15:30 ` Hyman Rosen
2002-07-30 17:34 ` Jim Rogers
2002-07-30 18:20 ` Hyman Rosen
2002-07-30 20:22 ` Robert A Duff
2002-07-30 19:17 ` Robert A Duff
2002-07-30 22:10 ` Hyman Rosen
2002-07-29 17:27 ` Hyman Rosen
2002-07-30 8:13 ` Dmitry A. Kazakov
2002-07-30 20:55 ` Robert Dewar
2002-07-31 22:08 ` Dmitry A.Kazakov
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox