Abstract type: Difference between revisions
Content added Content deleted
Line 109: | Line 109: | ||
In Genyris by default there are no constructors. In effect all classes are Abstract until they are used to tag an object. |
In Genyris by default there are no constructors. In effect all classes are Abstract until they are used to tag an object. |
||
<lang python>class Stack()</lang> |
<lang python>class Stack()</lang> |
||
There is no constructor for |
There is no constructor for this class. To prevent the class ever being associated with an instance it suffices to force the validator to fail. |
||
<lang python>class Stack() |
<lang python>class Stack() |
||
def !valid?(object) nil |
def !valid?(object) nil |