Next: interfaces examples, Previous: interfaces defs, Up: interfaces [Contents][Index]
Interfaces have run–time type descriptors, accessible through the
type-descriptor
syntax, Interface type descriptors. Example:
(import (prefix (vicare system type-descriptors) td::)) (define-interface-type <Stuff> (method-prototype red (lambda () => (<top>))) (method (blue) 2)) (define itd (type-descriptor <Stuff>)) (td::interface-type-descr? itd) ⇒ #t (td::interface-type-descr.type-name itd) ⇒ <Stuff>