next up previous
Next: 3.7 Exception actions Up: 3.6 Messaging Actions Previous: 3.6.3 Procedures

3.6.4 Procedure lookup

At run-time, a request must be matched to a procedure on the receiver side. In the context of an object, this mechanism is called operation lookup. It requires certain kinds of maps to look up the type of a message, and locate the appropriate procedure of the request object.

A map may be global or associated with a class or an object. A global map records all the procedures and their signature. The look-up in this map is very like a traditional procedure call. A map associated with a class only records the methods of the class. If no method in the class matches the request, another class is searched, which is linked to it with a pointer. A map associated with an object records the methods of the object8. If no method is matched, another object linking with it is then searched.

A matching from a request type to a procedure in the context of a state machine is called transition triggering. In a state machine, each state is a state of the requested object. A map is associated with the object or the class of the object. Similarly, if no procedure is matched in the map, another object or class which is pointed to is then searched.


next up previous
Next: 3.7 Exception actions Up: 3.6 Messaging Actions Previous: 3.6.3 Procedures
Thomas Feng 2003-04-18