Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

PsPvmNameServer Class Reference

a name server for pvm. More...

#include <PsPvmNameServer.h>

Inheritance diagram for PsPvmNameServer:

Inheritance graph
[legend]
Collaboration diagram for PsPvmNameServer:

Collaboration graph
[legend]
List of all members.

Public Methods

virtual ~PsPvmNameServer ()
 destructor

 PsPvmNameServer (int parentSiteId, PsNameServer &nameServer)
 constructor, copying and verifying the state of the old name server in respect to the central name server

virtual long getIdentifierAsFrom (const PsString &, long *nextId)
 get the id corresponding to a string if the string is unknown to the name server, a new id will be added

virtual const PsStringgetStringAssociatedTo (PsName::idType id) const
 get the string associated to an id

virtual bool includes (const PsNameServer &otherNameServer)
 redefine includes to cancel check because a conversion has occured with respect to the original name server

virtual void deleted (PsName::idType id, PsName *name)
 redefine deleted to prevent destructions.

virtual void created (PsName::idType id, PsName *)
 redefine to do nothing, because bookkeeping becomes to expensive due to unpacking


Protected Methods

virtual const PsStringgetStringAssociatedTo (PsName::idType id)
 get the string associated to an id this is the non-const version used when a request needs to be sent to the central server


Protected Attributes

int _mainNameServerSiteId
 site id of the central name server


Detailed Description

a name server for pvm.

One of the important pre-conditions for the current implementation of distribution using pvm is that PsName are coherant across the simulation, because synchronisation messages are created and decoded using the order on PsNames. Moreover, the creation and interpretation is made robust and more or less efficient by encoding the ids associated to PsName rather than their string value

Author:
D. Margery
Version:
1.0

Definition at line 15 of file PsPvmNameServer.h.


Constructor & Destructor Documentation

virtual PsPvmNameServer::~PsPvmNameServer   [virtual]
 

destructor

PsPvmNameServer::PsPvmNameServer int    parentSiteId,
PsNameServer   nameServer
 

constructor, copying and verifying the state of the old name server in respect to the central name server


Member Function Documentation

virtual void PsPvmNameServer::created PsName::idType    id,
PsName  
[virtual]
 

redefine to do nothing, because bookkeeping becomes to expensive due to unpacking

Reimplemented from PsNameServerT< STL_ALLOC >.

virtual void PsPvmNameServer::deleted PsName::idType    id,
PsName   name
[virtual]
 

redefine deleted to prevent destructions.

In fact, deleted does nothing, because it becomes very expensive to do something due to unpacking. The name server serves as a cache...

Reimplemented from PsNameServerT< STL_ALLOC >.

virtual long PsPvmNameServer::getIdentifierAsFrom const PsString  ,
long *    nextId
[virtual]
 

get the id corresponding to a string if the string is unknown to the name server, a new id will be added

Reimplemented from PsNameServerT< STL_ALLOC >.

virtual const PsString& PsPvmNameServer::getStringAssociatedTo PsName::idType    id [protected, virtual]
 

get the string associated to an id this is the non-const version used when a request needs to be sent to the central server

virtual const PsString& PsPvmNameServer::getStringAssociatedTo PsName::idType    id const [virtual]
 

get the string associated to an id

Reimplemented from PsNameServerT< STL_ALLOC >.

virtual bool PsPvmNameServer::includes const PsNameServer   otherNameServer [virtual]
 

redefine includes to cancel check because a conversion has occured with respect to the original name server

Reimplemented from PsNameServer.


Member Data Documentation

int PsPvmNameServer::_mainNameServerSiteId [protected]
 

site id of the central name server

Definition at line 52 of file PsPvmNameServer.h.


The documentation for this class was generated from the following file:
logo OpenMask

Documentation generated on Mon Nov 25 15:26:22 2002

Generated with doxygen 1.2.12 by Dimitri van Heesch ,   1997-2001