[haXe] Abstract Classes?
Martin Heidegger
mastakaneda at gmail.com
Mon Nov 6 09:54:56 CET 2006
Hmm: It does not look difficult to add support for Abstract classes.
And throwing a exception always adds unnecessary overhead to the
filesize, the dependencies and to documentation. What is the
bad thing with Abstract classes (why does haXe not support it)?
greetings
Martin.
2006/11/6, Nicolas Cannasse <ncannasse at motion-twin.com>:
>
> > Hi,
> >
> > Is it somehow possible to declare abstract classes in haxe? Have I
> missed
> > something obvious, or is that feature not implemented in haxe?
> >
> > / Rickard
>
> There is no abstract classes in haXe, but you can define a private
> constructor. This way, such a class can't be constructed. Only
> subclasses might define a public constructor.
>
> There is no abstract method either, so you need to define an empty body
> (or maybe throw an exception) in the main class. These functions will be
> overridden in subclasses.
>
> Nicolas
>
> --
> haXe - an open source web programming language
> http://haxe.org
>
--
ICQ: 117662935
Skype: mastakaneda
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.motion-twin.com/pipermail/haxe/attachments/20061106/cbbe8f09/attachment.htm
More information about the Haxe
mailing list