On Sun, Dec 14, 2008 at 8:51 AM, David Ashley
wrote:
> There are other alternatives besides subclassing. I discovered them when
> doing the RexxGTK library and I use them all over the place.
David,
Thanks for this. I'll look closer at the RexxGTK code. I've browsed
through many a time, but wi
Mark -
There are other alternatives besides subclassing. I discovered them when
doing the RexxGTK library and I use them all over the place.
What I needed was very similar to your requirements. I needed
alternative init methods that could take complex arguments and then
provide a class instanc
On Sat, Dec 13, 2008 at 1:24 PM, Rick McGuire wrote:
> There's only one init method, which is normally called by the new
> method of the class object. The normal pattern if you wish to have
> multiple versions of "new" is to have the additional class methods
> call new, then perform any addition
There's only one init method, which is normally called by the new
method of the class object. The normal pattern if you wish to have
multiple versions of "new" is to have the additional class methods
call new, then perform any additional initialization after new
completes. For example, .array~of
What would be the proper way to implement something like:
a = .array~new
b = .array~of(1, 2, 3,)
using the native API for a new class?
In other words, I want to define a new class where there are several
different *sets* of initialization options that can be used to create
the new object. R