0024911: Avoid using virtual functions in NCollection classes

NCollection_BaseCollection class, relevant header files, and macro DEFINE_BASECOLLECTION removed.
Hence methods Assign() from other compatible (via inheritance of BaseCollection) collections are not available any more, as well as base Iterator class.

All methods of Iterator classes are made non-virtual, allowing their inline expansion for better performance.

OCCT-specific operators new and delete added to collection classes and removed from iterator classes.
This commit is contained in:
abv
2014-05-08 09:13:00 +04:00
committed by apn
parent 598fcce93c
commit ddf2fe8eeb
66 changed files with 456 additions and 1016 deletions

View File

@@ -16,7 +16,7 @@
#ifndef _SelectMgr_DataMapOfObjectOwners_HeaderFile
#define _SelectMgr_DataMapOfObjectOwners_HeaderFile
#include <NCollection_DefineDataMap.hxx>
#include <NCollection_DataMap.hxx>
#include <SelectMgr_SelectableObject.hxx>
#include <SelectMgr_SequenceOfOwner.hxx>
@@ -26,12 +26,7 @@ inline Standard_Boolean IsEqual (const Handle(SelectMgr_SelectableObject)& theH1
return (theH1 == theH2);
}
DEFINE_BASECOLLECTION(SelectMgr_CollectionOfSequenceOfOwner, SelectMgr_SequenceOfOwner)
DEFINE_DATAMAP(SelectMgr_DataMapOfObjectOwners, SelectMgr_CollectionOfSequenceOfOwner,
Handle(SelectMgr_SelectableObject), SelectMgr_SequenceOfOwner)
typedef SelectMgr_DataMapOfObjectOwners::Iterator
SelectMgr_DataMapIteratorOfMapOfObjectOwners;
typedef NCollection_DataMap<Handle(SelectMgr_SelectableObject), SelectMgr_SequenceOfOwner> SelectMgr_DataMapOfObjectOwners;
typedef SelectMgr_DataMapOfObjectOwners::Iterator SelectMgr_DataMapIteratorOfMapOfObjectOwners;
#endif