Comment: Metamodel of Joose 3.0 (Score 1) on 2009.11.25 4:07
Hi,
I thought you might be interested to look at the meta-model of the Joose 3.0. Joose is a very close port of Moose to JavaScript. And its sources are much clearer and easier to understand )
It starts with the abstract property:
http://github.com/Joose/Joose/blob/mutability/lib/Joose/Managed/Property.js
And abstract property set (isa property):
http://github.com/Joose/Joose/blob/mutability/lib/Joose/Managed/PropertySet.js
Then defines some kind of "property set algebra", with couple of operations defined: flattening and composition.
Flattening is what happens between roles, when they are listed in the class (produces a new property set), and composition is what happens between class and role.
The whole project can be found here:
http://github.com/Joose/Joose/tree/mutability
And documentation is "borrowed" from Moose
http://joose.github.com/Joose/doc/html/Joose/Manual.html
There is an implementation limitation though - Joose supports only one superclass (to fit well into prototype nature of JavaScript)
Regards, Nickolay
