mirror of
https://github.com/Open-Cascade-SAS/OCCT.git
synced 2026-05-30 07:21:44 +08:00
0024271: Provide Boolean operations for NCollection_Map
NCollection_Map - add two maps content Exchange operation without data copying Add Exchange method to NCollection_DataMap, NCollection_DoubleMap, NCollection_IndexedDataMap, NCollection_IndexedMap Add NCollection_Map::IsEqual() method Corrections for gcc - use this->myAllocator
This commit is contained in:
@@ -199,6 +199,17 @@ class NCollection_BaseMap
|
||||
Standard_EXPORT Standard_Integer NextPrimeForMap
|
||||
(const Standard_Integer N) const;
|
||||
|
||||
//! Exchange content of two maps without data copying
|
||||
void exchangeMapsData (NCollection_BaseMap& theOther)
|
||||
{
|
||||
std::swap (myData1, theOther.myData1);
|
||||
std::swap (myData2, theOther.myData2);
|
||||
//std::swap (isDouble, theOther.isDouble);
|
||||
std::swap (mySaturated, theOther.mySaturated);
|
||||
std::swap (myNbBuckets, theOther.myNbBuckets);
|
||||
std::swap (mySize, theOther.mySize);
|
||||
}
|
||||
|
||||
protected:
|
||||
// --------- PROTECTED FIELDS -----------
|
||||
NCollection_ListNode ** myData1;
|
||||
|
||||
Reference in New Issue
Block a user