[REBOL] Class object inheritance library interest ?
From: chrismorency::videotron::ca at: 13-Mar-2002 23:46
Short version :
Anybody interested in helping for this kind of library ? email me privately
at: to-email rejoin ["chrismorency" "@" "videotron.ca"]
Long version :
For the past few months, I've been working on a class object inheritance
library for Rebol. I've been through several implementations,
reimplementations, complete rewrites simply to make sure the library would
be the simpliest to understand by most rebol beginners !
The library currently provides metaclass creation, class creation, object
interface, instances, inheritance, super class, etc. It provides two basic
methods : subclass and new. Yet it is pretty small AFAIK : 23kb including a
13.6kb object/analyser script that could be reused outside the library.
(take in consideration that methods and arguments have long naming scheme in
order to keep the code clear.)
The biggest challenge and most important requirement was to keep instances,
class and metaclass true the way objects are called under Rebol while
changing the way methods and variables are inherited or instanciated...
For exemple, as a developer, you would still use class/new and
instance/do-something etc. Everything would be transparent, however your
method, unless overwritten, would be implemented once (or maybe not *EG*).
I'm now at the point where I think I need some input from some fellow
rebolers (2-3), I begin to have a critical view upon my own work which
brings me to a destructive behavior with it... I even begin to wonder if it
is of any worth to bring a classic OOP behavior to REBOL.
I especially need input from people who are familiar with implementing OOP
languages. Although I daily work in OOP under Smalltalk, I never implemented
a language before... and this rebol-like dialect is my first attempt. I
would like the library to feel like smalltalk while staying true to Rebol.
Why ? Basically I like OOP, I like SmallTalk and I like Rebol too but I'm
not too fond of the current rebol object/inheritence implementation !
I know this library is a long way from release. Eventually, once the core of
it is completed, I will require more people to work on the basic
Object/Behavior/Class/Collection kernel. The kernel should feature most of
current Rebol functions and datatypes, but within an Object/Class
hierarchy... After that, I have begun thinking about object inspectors,
etc... but that is another task ;)