Salome HOME
Small fix in French resource file
[modules/geom.git] / src / GEOM / GEOM_DataMapOfAsciiStringTransient.hxx
1 // Copyright (C) 2007-2011  CEA/DEN, EDF R&D, OPEN CASCADE
2 //
3 // Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
5 //
6 // This library is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License.
10 //
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14 // Lesser General Public License for more details.
15 //
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
19 //
20 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
21
22 #ifndef _GEOM_DataMapOfAsciiStringTransient_HeaderFile
23 #define _GEOM_DataMapOfAsciiStringTransient_HeaderFile
24
25 #ifndef _TCollection_BasicMap_HeaderFile
26 #include <TCollection_BasicMap.hxx>
27 #endif
28 #ifndef _Handle_Standard_Transient_HeaderFile
29 #include <Handle_Standard_Transient.hxx>
30 #endif
31 #ifndef _Handle_GEOM_DataMapNodeOfDataMapOfAsciiStringTransient_HeaderFile
32 #include <Handle_GEOM_DataMapNodeOfDataMapOfAsciiStringTransient.hxx>
33 #endif
34 #ifndef _Standard_Integer_HeaderFile
35 #include <Standard_Integer.hxx>
36 #endif
37 #ifndef _Standard_Boolean_HeaderFile
38 #include <Standard_Boolean.hxx>
39 #endif
40
41 class Standard_DomainError;
42 class Standard_NoSuchObject;
43 class TCollection_AsciiString;
44 class Standard_Transient;
45 class GEOM_DataMapNodeOfDataMapOfAsciiStringTransient;
46 class GEOM_DataMapIteratorOfDataMapOfAsciiStringTransient;
47
48 #ifndef _Standard_HeaderFile
49 #include <Standard.hxx>
50 #endif
51 #ifndef _Standard_Macro_HeaderFile
52 #include <Standard_Macro.hxx>
53 #endif
54
55 #include <Basics_OCCTVersion.hxx>
56
57 class GEOM_DataMapOfAsciiStringTransient  : public TCollection_BasicMap {
58
59 public:
60
61     void* operator new(size_t,void* anAddress) 
62       {
63         return anAddress;
64       }
65     void* operator new(size_t size) 
66       { 
67         return Standard::Allocate(size); 
68       }
69     void  operator delete(void *anAddress) 
70       { 
71         if (anAddress) Standard::Free((Standard_Address&)anAddress); 
72       }
73
74  // Methods PUBLIC
75  // 
76 Standard_EXPORT GEOM_DataMapOfAsciiStringTransient(const Standard_Integer NbBuckets = 1);
77 Standard_EXPORT   GEOM_DataMapOfAsciiStringTransient& Assign(const GEOM_DataMapOfAsciiStringTransient& Other) ;
78   GEOM_DataMapOfAsciiStringTransient& operator =(const GEOM_DataMapOfAsciiStringTransient& Other) 
79 {
80   return Assign(Other);
81 }
82
83 Standard_EXPORT   void ReSize(const Standard_Integer NbBuckets) ;
84 Standard_EXPORT   void Clear() ;
85 ~GEOM_DataMapOfAsciiStringTransient()
86 {
87   Clear();
88 }
89
90 Standard_EXPORT   Standard_Boolean Bind(const TCollection_AsciiString& K,const Handle(Standard_Transient)& I) ;
91 Standard_EXPORT   Standard_Boolean IsBound(const TCollection_AsciiString& K) const;
92 Standard_EXPORT   Standard_Boolean UnBind(const TCollection_AsciiString& K) ;
93 Standard_EXPORT  const Handle_Standard_Transient& Find(const TCollection_AsciiString& K) const;
94  const Handle_Standard_Transient& operator()(const TCollection_AsciiString& K) const
95 {
96   return Find(K);
97 }
98
99 Standard_EXPORT   Handle_Standard_Transient& ChangeFind(const TCollection_AsciiString& K) ;
100   Handle_Standard_Transient& operator()(const TCollection_AsciiString& K) 
101 {
102   return ChangeFind(K);
103 }
104
105 #if OCC_VERSION_LARGE > 0x06050100 // for OCC-6.5.2 and higher version
106   Standard_EXPORT Standard_Address Find1 (const TCollection_AsciiString& K) const;
107   Standard_EXPORT Standard_Address ChangeFind1 (const TCollection_AsciiString& K);
108 #endif
109
110 private: 
111  // Methods PRIVATE
112  // 
113 Standard_EXPORT GEOM_DataMapOfAsciiStringTransient(const GEOM_DataMapOfAsciiStringTransient& Other);
114 };
115
116 // other Inline functions and methods (like "C++: function call" methods)
117 //
118
119 #endif