CONSULT:
Factor handbook » The language » Objects » Delegation

Prev:BROADCAST:
Next:define-consult ( consultation -- )


Vocabulary
delegate

Syntax
CONSULT: group class code ;


Inputs
None

Outputs
None

Word description
Declares that objects of class will delegate the generic words contained in group to the object returned by executing code with the original object as an input. CONSULT: will overwrite any existing methods on class for the members of group, but new methods can be added after the CONSULT: to override the delegation.

See also
define-consult, BROADCAST:

Definition