From: Lutz Donnerhacke <lutz@iks-jena.de>
Subject: Re: Abstract methods in ADA95
Date: Thu, 17 Oct 2002 14:39:55 +0000 (UTC)
Date: 2002-10-17T14:39:55+00:00 [thread overview]
Message-ID: <slrnaqtitn.q0.lutz@taranis.iks-jena.de> (raw)
In-Reply-To: 20021017-143635-828420@foorum.com
* Hector Hugo wrote:
> Hello, i'm new programing in Ada95, i come from C++ world and i've got
> problems when i try to use abstract methods in Ada95. I'm trying to do
> something similar to this but in Ada95:
>
> class Abstract_Class
> {
> public:
> virtual void Abstract_Method () = 0; // C++ abstract method.
>
> ...
> };
type Abstract_Class is abstract tagged record ...;
procedure Abstract_Method (a : Abstract_Class) is abstact;
> class Son_Class: public Abstract_Class // C++ tagged type extension.
> {
> void Abstract_Method ();
>
> ...
> };
type Son_Class is new Abstract_Class with record ...;
procedure Abstract_Method (a : Son_Class);
> void main ()
> {
> Abstract_Class* p_abstract = new Son_Class;
>
> p_abstract->Abstract_Method ();
> }
procedure main is
concrete : Abstract_Class'Class := Son_Class'(null record);
begin
Abstract_Method(concrete);
end main;
next prev parent reply other threads:[~2002-10-17 14:39 UTC|newest]
Thread overview: 39+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-10-17 13:36 Abstract methods in ADA95 Hector Hugo
2002-10-17 14:39 ` Lutz Donnerhacke [this message]
2002-10-17 14:50 ` David C. Hoos
2002-10-17 14:57 ` Preben Randhol
2002-10-17 14:56 ` Preben Randhol
2002-10-17 16:18 ` Matthew Heaney
2002-10-17 19:26 ` Jeffrey Carter
2002-10-17 19:41 ` David C. Hoos
2002-10-17 20:34 ` Georg Bauhaus
2002-10-18 13:56 ` Frank J. Lhota
2002-10-18 0:40 ` Robert A Duff
2002-10-18 21:05 ` Jeffrey Carter
2002-10-18 22:00 ` Robert A Duff
2002-10-21 14:46 ` Wes Groleau
2002-10-18 3:13 ` SteveD
2002-10-18 14:44 ` Robert A Duff
2002-10-18 21:15 ` Dale Stanbrough
2002-10-18 21:08 ` Jeffrey Carter
2002-10-18 21:23 ` David C. Hoos
2002-10-18 21:37 ` Jeffrey Carter
2002-10-18 22:08 ` Robert A Duff
2002-10-21 15:03 ` Peter Amey
2002-10-21 15:04 ` Wes Groleau
2002-10-18 22:10 ` Robert A Duff
2002-10-19 12:40 ` SteveD
2002-10-19 18:40 ` Jeffrey Carter
2002-10-21 15:34 ` Martin Dowie
2002-10-21 19:37 ` Jeffrey Carter
2002-10-22 11:59 ` Georg Bauhaus
2002-10-22 12:24 ` Marin David Condic
2002-10-23 9:29 ` Martin Dowie
2002-10-23 10:36 ` Ed Falis
2002-10-23 10:37 ` Preben Randhol
2002-10-23 12:54 ` John English
2002-10-23 13:48 ` Martin Dowie
[not found] ` <aornkp$mpf$1@bob.news.rcn.net>
2002-10-19 18:54 ` Crapper (was: Re: Abstract methods in ADA95) Jeffrey Carter
2002-10-21 17:57 ` Abstract methods in ADA95 Programmer Dude
2002-10-21 18:58 ` Jim Rogers
2002-10-21 14:49 ` Wes Groleau
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox