00001 /* 00002 * This file is part of openMask © INRIA, CNRS, Universite de Rennes 1 1993-2002, thereinafter the Software 00003 * 00004 * The Software has been developped within the Siames Project. 00005 * INRIA, the University of Rennes 1 and CNRS jointly hold intellectual property rights 00006 * 00007 * The Software has been registered with the Agence pour la Protection des 00008 * Programmes (APP) under registration number IDDN.FR.001.510008.00.S.P.2001.000.41200 00009 * 00010 * This file may be distributed under the terms of the Q Public License 00011 * version 1.0 as defined by Trolltech AS of Norway and appearing in the file 00012 * LICENSE.QPL included in the packaging of this file. 00013 * 00014 * Licensees holding valid specific licenses issued by INRIA, CNRS or Université de Rennes 1 00015 * for the software may use this file in accordance with that specific license 00016 * 00017 */ 00018 #ifndef PsNameServerHEADER 00019 #define PsNameServerHEADER 00020 00021 #include <Psn.h> 00022 00023 #ifdef _HASHMAPNOTSTD 00024 #include <ext/hash_map> 00025 #else 00026 #include <hash_map> 00027 #endif 00028 00029 #include <PsString.h> 00030 #include <iterator> 00031 #include "PsList.h" 00032 #include "PsPair.h" 00033 00042 class PsNameServer { 00043 public : 00045 PsNameServer(); 00046 00047 00049 virtual ~PsNameServer() ; 00050 00051 00055 virtual long getIdentifier(const PsString &) = 0 ; 00056 00057 00060 virtual long getSystemIdentifier (const PsString &) = 0 ; 00061 00062 00065 virtual const PsString & getStringAssociatedTo (PsName::idType id) const = 0 ; 00066 00067 00070 virtual void printToStream (ostream & out, const string & separator ) const ; 00071 00072 00074 virtual bool includes ( const PsNameServer & otherNameServer ); 00075 00076 00077 00079 friend bool operator == (const PsNameServer & , const PsNameServer &); 00080 00081 00082 00084 virtual void created(PsName::idType, PsName *) = 0; 00085 00086 00088 virtual void deleted(PsName::idType, PsName *) = 0; 00089 00090 00092 typedef PsList <PsPair<PsPair<PsName::idType,PsString>, int > > CanonicalRepresentationType ; 00093 00094 00098 virtual CanonicalRepresentationType * getCanonicalRepresentation () const = 0 ; 00099 00101 virtual const list<PsName *> & getNamesOfId (PsName::idType) const = 0 ; 00102 protected: 00104 virtual void lock() const = 0; 00106 virtual void unlock() const = 0 ; 00107 00113 void changeNamesId ( PsName * namePointer, PsName::idType oldId, PsName::idType newId ) ; 00114 00115 }; 00116 00117 00118 #endif 00119 00120 00121 00122 00123 00124 00125
| Documentation generated on Mon Nov 25 15:25:00 2002 |
Generated with doxygen 1.2.12 by Dimitri van Heesch , 1997-2001 |