NameServer is an abstract super pattern describing objects that perform a mapping between logical object names and object references. Subpatterns of NameServer may perform this mapping differently. Currently the only subpattern of NameServer implemented is the ns attribute of ensemble.
The attributes of the NameServer pattern are:
- put: Saves the association between a textual name and an object reference entered as parameters. The overWrite virtual is called if an object of that name is already registered. If overWrite returns true, the existing (name,object reference) pair is overwritten with the new one.
- get: Given a textual name and a qualification, get returns the object reference associated with that name, assuming it qualifies to the type entered If no associated object is found, notFound is raised and NONE is returned. If an object with the right name, but wrong type, is found, quaError is raised. The type entered should be a super pattern to the pattern of the object returned.
- remove: Removes the named object from the NameServer. notFound is raised if no object of that name is registered in the NameServer.
NameServer is a remoteable, but all the public operations described above do some work locally before doing calls to the (private) entrys of the NameServer.
Distributed Objects in BETA - Reference Manual |
© 1993-2002 Mjølner Informatics |
[Modified: Monday October 23rd 2000 at 11:16]
|