Opened 17 years ago

Last modified 14 years ago

#18 new defect

can't handle forward references in RemoteInterface classes

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 (3)

comment:1 Changed 16 years ago by Brian Warner

Description: modified (diff)

comment:2 Changed 16 years ago by Brian Warner

Description: modified (diff)

comment:3 Changed 15 years ago by Brian Warner

Component: unknownschemas
Note: See TracTickets for help on using tickets.