Opened 17 years ago

Last modified 14 years ago

#18 new defect

can't handle forward references in RemoteInterface classes — at Version 1

Reported by: Brian Warner Owned by:
Priority: major Milestone: undecided
Component: schemas Version: 0.1.5
Keywords: Cc:

Description (last modified by Brian Warner)

At the moment, the RemoteInterface? metaclass mechanism fully parses the RemoteInterface? specification before the class itself is defined. This makes it impossible to have methods which e.g. return instances of the same class (think graph-traversal interfaces: A.get_children() returns more instances of A). Likewise, it is impossible to have two classes mutually reference each other.

To fix this, the parsing of the methods inside the RemoteInterface? should be put off as long as possible. The first time that someone uses a RemoteInterface? (to obtain a schema or enumerate the methods) should trigger the parsing.

Change History (1)

comment:1 Changed 16 years ago by Brian Warner

Description: modified (diff)
Note: See TracTickets for help on using tickets.