From e6f550da9928b45b2f21a0ea60f428e1711c7c49 Mon Sep 17 00:00:00 2001 From: abv Date: Sun, 3 Jan 2016 07:11:46 +0300 Subject: [PATCH] 0027067: Avoid use of virtual methods for implementation of destructors in legacy classes Redundant methods Delete() and Desroy(), created in CDL as a hack to define destructor for the class, are removed; their definitions are converted to definition of destructors. In a couple of places methods Destroy() are preserved (bug made non-virtual) because they are called explicitly. --- src/AdvApp2Var/AdvApp2Var_Criterion.cxx | 2 +- src/AdvApp2Var/AdvApp2Var_Criterion.hxx | 4 +--- src/AdvApprox/AdvApprox_Cutting.cxx | 2 +- src/AdvApprox/AdvApprox_Cutting.hxx | 19 +-------------- src/Aspect/Aspect_Window.hxx | 4 ---- src/BRepAlgo/BRepAlgo_BooleanOperation.cxx | 6 ++--- src/BRepAlgo/BRepAlgo_BooleanOperation.hxx | 4 +--- src/BRepBuilderAPI/BRepBuilderAPI_Command.cxx | 6 ++++- src/BRepBuilderAPI/BRepBuilderAPI_Command.hxx | 4 +--- .../BRepBuilderAPI_MakeShape.cxx | 4 ---- .../BRepBuilderAPI_MakeShape.hxx | 4 ---- src/BRepClass3d/BRepClass3d_SolidExplorer.cxx | 6 ++--- src/BRepClass3d/BRepClass3d_SolidExplorer.hxx | 3 +-- src/BRepLib/BRepLib_Command.cxx | 2 +- src/BRepLib/BRepLib_Command.hxx | 4 +--- src/BRepToIGES/BRepToIGES_BREntity.cxx | 4 ++-- src/BRepToIGES/BRepToIGES_BREntity.hxx | 23 +----------------- src/BinTools/BinTools_ShapeSet.cxx | 4 ++-- src/BinTools/BinTools_ShapeSet.hxx | 3 +-- src/CDM/CDM_Document.cxx | 5 ++-- src/CDM/CDM_Document.hxx | 6 +---- src/ChFi3d/ChFi3d_Builder.cxx | 7 +++++- src/ChFi3d/ChFi3d_Builder.hxx | 4 +--- src/Cocoa/Cocoa_Window.hxx | 9 ++----- src/Cocoa/Cocoa_Window.mm | 4 ++-- src/FairCurve/FairCurve_Batten.cxx | 2 +- src/FairCurve/FairCurve_Batten.hxx | 3 +-- .../Graphic3d_DataStructureManager.cxx | 6 ----- .../Graphic3d_DataStructureManager.hxx | 10 -------- src/Graphic3d/Graphic3d_Structure.cxx | 4 ++-- src/Graphic3d/Graphic3d_Structure.hxx | 6 +---- src/Graphic3d/Graphic3d_StructureManager.cxx | 4 ++-- src/Graphic3d/Graphic3d_StructureManager.hxx | 6 +---- src/IFGraph/IFGraph_SubPartsIterator.cxx | 4 ++-- src/IFGraph/IFGraph_SubPartsIterator.hxx | 6 +---- src/Interface/Interface_EntityIterator.cxx | 8 ++++++- src/Interface/Interface_EntityIterator.hxx | 7 +++--- src/Interface/Interface_FileReaderTool.cxx | 4 ++-- src/Interface/Interface_FileReaderTool.hxx | 3 +-- src/MeshVS/MeshVS_Mesh.cxx | 4 ---- src/MeshVS/MeshVS_Mesh.hxx | 6 ----- src/MoniTool/MoniTool_OptValue.cxx | 4 ++-- src/MoniTool/MoniTool_OptValue.hxx | 23 +----------------- src/MoniTool/MoniTool_TimerSentry.hxx | 3 +-- src/MoniTool/MoniTool_TimerSentry.lxx | 4 ++-- src/ProjLib/ProjLib_ProjectOnSurface.cxx | 7 +++++- src/ProjLib/ProjLib_ProjectOnSurface.hxx | 3 +-- src/PrsMgr/PrsMgr_Presentation.cxx | 4 ++-- src/PrsMgr/PrsMgr_Presentation.hxx | 6 +---- .../QANewModTopOpe_Limitation.cxx | 2 +- .../QANewModTopOpe_Limitation.hxx | 12 +--------- src/ShapeUpgrade/ShapeUpgrade_ShapeDivide.cxx | 4 ++-- src/ShapeUpgrade/ShapeUpgrade_ShapeDivide.hxx | 3 +-- src/StepData/StepData_FieldList.cxx | 4 ++++ src/StepData/StepData_FieldList.hxx | 24 ++----------------- src/StepData/StepData_FieldList1.cxx | 3 --- src/StepData/StepData_FieldList1.hxx | 12 ---------- src/StepData/StepData_FieldListD.cxx | 3 --- src/StepData/StepData_FieldListD.hxx | 12 ---------- src/StepData/StepData_FieldListN.cxx | 3 --- src/StepData/StepData_FieldListN.hxx | 12 ---------- src/StepData/StepData_SelectType.cxx | 3 ++- src/StepData/StepData_SelectType.hxx | 12 +--------- src/Storage/Storage_BaseDriver.cxx | 3 ++- src/Storage/Storage_BaseDriver.hxx | 4 +--- src/TopOpeBRep/TopOpeBRep_DSFiller.cxx | 6 ++--- src/TopOpeBRep/TopOpeBRep_DSFiller.hxx | 3 +-- .../TopOpeBRep_EdgesIntersector.cxx | 2 +- .../TopOpeBRep_EdgesIntersector.hxx | 3 +-- .../TopOpeBRepBuild_AreaBuilder.cxx | 2 +- .../TopOpeBRepBuild_AreaBuilder.hxx | 3 +-- .../TopOpeBRepBuild_Builder.cxx | 4 ++-- .../TopOpeBRepBuild_Builder.hxx | 3 +-- .../TopOpeBRepBuild_Builder1.hxx | 3 +-- .../TopOpeBRepBuild_Builder1_1.cxx | 4 ++-- .../TopOpeBRepBuild_LoopClassifier.cxx | 2 +- .../TopOpeBRepBuild_LoopClassifier.hxx | 4 +--- .../TopOpeBRepBuild_LoopSet.cxx | 2 +- .../TopOpeBRepBuild_LoopSet.hxx | 3 +-- .../TopOpeBRepBuild_ShapeSet.cxx | 2 +- .../TopOpeBRepBuild_ShapeSet.hxx | 3 +-- src/TopOpeBRepTool/TopOpeBRepTool_BoxSort.cxx | 6 ++--- src/TopOpeBRepTool/TopOpeBRepTool_BoxSort.hxx | 12 +--------- .../TopOpeBRepTool_SolidClassifier.cxx | 6 ++--- .../TopOpeBRepTool_SolidClassifier.hxx | 3 +-- src/TopTools/TopTools_ShapeSet.cxx | 2 +- src/TopTools/TopTools_ShapeSet.hxx | 3 +-- src/TransferBRep/TransferBRep_Reader.cxx | 3 ++- src/TransferBRep/TransferBRep_Reader.hxx | 6 +---- src/Units/Units_ShiftedToken.cxx | 4 ---- src/Units/Units_ShiftedToken.hxx | 7 ------ src/Units/Units_Token.cxx | 4 ---- src/Units/Units_Token.hxx | 7 ------ src/WNT/WNT_WClass.cxx | 4 ++-- src/WNT/WNT_WClass.hxx | 6 +---- src/WNT/WNT_Window.cxx | 4 ++-- src/WNT/WNT_Window.hxx | 8 ++----- src/XCAFDoc/XCAFDoc_DocumentTool.cxx | 10 -------- src/XCAFDoc/XCAFDoc_DocumentTool.hxx | 12 +--------- src/Xw/Xw_Window.cxx | 4 ++-- src/Xw/Xw_Window.hxx | 9 ++----- src/math/math_BissecNewton.hxx | 3 +-- src/math/math_BissecNewton.lxx | 4 ---- src/math/math_BrentMinimum.hxx | 3 +-- src/math/math_BrentMinimum.lxx | 5 ---- src/math/math_FRPR.hxx | 3 +-- src/math/math_FRPR.lxx | 4 ---- src/math/math_FunctionSetRoot.cxx | 1 - src/math/math_FunctionSetRoot.hxx | 3 +-- src/math/math_FunctionSetRoot.lxx | 5 ---- src/math/math_NewtonFunctionSetRoot.hxx | 3 +-- src/math/math_NewtonFunctionSetRoot.lxx | 4 ---- src/math/math_NewtonMinimum.hxx | 3 +-- src/math/math_NewtonMinimum.lxx | 4 ---- src/math/math_Powell.hxx | 3 +-- src/math/math_Powell.lxx | 4 ---- 116 files changed, 150 insertions(+), 467 deletions(-) diff --git a/src/AdvApp2Var/AdvApp2Var_Criterion.cxx b/src/AdvApp2Var/AdvApp2Var_Criterion.cxx index a4ed4b2fff..c65914408d 100644 --- a/src/AdvApp2Var/AdvApp2Var_Criterion.cxx +++ b/src/AdvApp2Var/AdvApp2Var_Criterion.cxx @@ -19,7 +19,7 @@ #include #include -void AdvApp2Var_Criterion::Delete() +AdvApp2Var_Criterion::~AdvApp2Var_Criterion() {} //============================================================================ diff --git a/src/AdvApp2Var/AdvApp2Var_Criterion.hxx b/src/AdvApp2Var/AdvApp2Var_Criterion.hxx index 12c8a2ead2..ba92de3002 100644 --- a/src/AdvApp2Var/AdvApp2Var_Criterion.hxx +++ b/src/AdvApp2Var/AdvApp2Var_Criterion.hxx @@ -37,9 +37,7 @@ public: DEFINE_STANDARD_ALLOC - - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~AdvApp2Var_Criterion(){Delete() ; } + Standard_EXPORT virtual ~AdvApp2Var_Criterion(); Standard_EXPORT virtual void Value (AdvApp2Var_Patch& P, const AdvApp2Var_Context& C) const = 0; diff --git a/src/AdvApprox/AdvApprox_Cutting.cxx b/src/AdvApprox/AdvApprox_Cutting.cxx index 0b46bba5ee..769e1a7f95 100644 --- a/src/AdvApprox/AdvApprox_Cutting.cxx +++ b/src/AdvApprox/AdvApprox_Cutting.cxx @@ -17,5 +17,5 @@ #include -void AdvApprox_Cutting::Delete() +AdvApprox_Cutting::~AdvApprox_Cutting() {} diff --git a/src/AdvApprox/AdvApprox_Cutting.hxx b/src/AdvApprox/AdvApprox_Cutting.hxx index 6f1651bd65..c6e2c1780b 100644 --- a/src/AdvApprox/AdvApprox_Cutting.hxx +++ b/src/AdvApprox/AdvApprox_Cutting.hxx @@ -32,27 +32,10 @@ public: DEFINE_STANDARD_ALLOC - - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~AdvApprox_Cutting(){Delete();} + Standard_EXPORT virtual ~AdvApprox_Cutting(); Standard_EXPORT virtual Standard_Boolean Value (const Standard_Real a, const Standard_Real b, Standard_Real& cuttingvalue) const = 0; - - - -protected: - - - - - -private: - - - - - }; diff --git a/src/Aspect/Aspect_Window.hxx b/src/Aspect/Aspect_Window.hxx index f309c67d73..e5cd1134da 100644 --- a/src/Aspect/Aspect_Window.hxx +++ b/src/Aspect/Aspect_Window.hxx @@ -46,7 +46,6 @@ class Aspect_Window : public MMgt_TShared { public: - //! Modifies the window background. Standard_EXPORT void SetBackground (const Aspect_Background& ABack); @@ -76,9 +75,6 @@ public: //! and returns TRUE if the window is mapped at screen. Standard_EXPORT virtual Standard_Boolean DoMapping() const = 0; - //! Destroy the Window - Standard_EXPORT virtual void Destroy() = 0; - //! Returns the window background. Standard_EXPORT Aspect_Background Background() const; diff --git a/src/BRepAlgo/BRepAlgo_BooleanOperation.cxx b/src/BRepAlgo/BRepAlgo_BooleanOperation.cxx index b72ab399cd..5c1a383743 100644 --- a/src/BRepAlgo/BRepAlgo_BooleanOperation.cxx +++ b/src/BRepAlgo/BRepAlgo_BooleanOperation.cxx @@ -77,10 +77,10 @@ extern void FDSCNX_Close();// see TopOpeBRepDS_connex.cxx extern void FDSSDM_Close();// see TopOpeBRepDS_samdom.cxx //======================================================================= -//function : Delete -//purpose : alias ~BRepAlgoAPI_BooleanOperation +//function : ~BRepAlgo_BooleanOperation +//purpose : //======================================================================= - void BRepAlgo_BooleanOperation::Delete() +BRepAlgo_BooleanOperation::~BRepAlgo_BooleanOperation() { FDSSDM_Close(); FDSCNX_Close(); diff --git a/src/BRepAlgo/BRepAlgo_BooleanOperation.hxx b/src/BRepAlgo/BRepAlgo_BooleanOperation.hxx index a80c041edc..69f20024ab 100644 --- a/src/BRepAlgo/BRepAlgo_BooleanOperation.hxx +++ b/src/BRepAlgo/BRepAlgo_BooleanOperation.hxx @@ -47,9 +47,7 @@ public: DEFINE_STANDARD_ALLOC - - Standard_EXPORT virtual void Delete() Standard_OVERRIDE; -Standard_EXPORT virtual ~BRepAlgo_BooleanOperation() {Delete();} + Standard_EXPORT virtual ~BRepAlgo_BooleanOperation(); Standard_EXPORT void PerformDS(); diff --git a/src/BRepBuilderAPI/BRepBuilderAPI_Command.cxx b/src/BRepBuilderAPI/BRepBuilderAPI_Command.cxx index 81b7421e66..d770f7f09b 100644 --- a/src/BRepBuilderAPI/BRepBuilderAPI_Command.cxx +++ b/src/BRepBuilderAPI/BRepBuilderAPI_Command.cxx @@ -27,7 +27,11 @@ BRepBuilderAPI_Command::BRepBuilderAPI_Command() : { } -void BRepBuilderAPI_Command::Delete() +//======================================================================= +//function : ~BRepBuilderAPI_Command +//purpose : +//======================================================================= +BRepBuilderAPI_Command::~BRepBuilderAPI_Command() {} //======================================================================= diff --git a/src/BRepBuilderAPI/BRepBuilderAPI_Command.hxx b/src/BRepBuilderAPI/BRepBuilderAPI_Command.hxx index d47fd7745e..a64a8ec868 100644 --- a/src/BRepBuilderAPI/BRepBuilderAPI_Command.hxx +++ b/src/BRepBuilderAPI/BRepBuilderAPI_Command.hxx @@ -39,10 +39,8 @@ class BRepBuilderAPI_Command public: DEFINE_STANDARD_ALLOC - - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~BRepBuilderAPI_Command(){Delete() ; } + Standard_EXPORT virtual ~BRepBuilderAPI_Command(); Standard_EXPORT virtual Standard_Boolean IsDone() const; diff --git a/src/BRepBuilderAPI/BRepBuilderAPI_MakeShape.cxx b/src/BRepBuilderAPI/BRepBuilderAPI_MakeShape.cxx index 95727530b7..ba27b58772 100644 --- a/src/BRepBuilderAPI/BRepBuilderAPI_MakeShape.cxx +++ b/src/BRepBuilderAPI/BRepBuilderAPI_MakeShape.cxx @@ -31,10 +31,6 @@ BRepBuilderAPI_MakeShape::BRepBuilderAPI_MakeShape() { } -void BRepBuilderAPI_MakeShape::Delete() -{} - - //======================================================================= //function : Build //purpose : diff --git a/src/BRepBuilderAPI/BRepBuilderAPI_MakeShape.hxx b/src/BRepBuilderAPI/BRepBuilderAPI_MakeShape.hxx index acc31608c1..7536e26b13 100644 --- a/src/BRepBuilderAPI/BRepBuilderAPI_MakeShape.hxx +++ b/src/BRepBuilderAPI/BRepBuilderAPI_MakeShape.hxx @@ -40,10 +40,6 @@ public: DEFINE_STANDARD_ALLOC - - Standard_EXPORT virtual void Delete() Standard_OVERRIDE; -Standard_EXPORT virtual ~BRepBuilderAPI_MakeShape(){Delete() ; } - //! This is called by Shape(). It does nothing but //! may be redefined. Standard_EXPORT virtual void Build(); diff --git a/src/BRepClass3d/BRepClass3d_SolidExplorer.cxx b/src/BRepClass3d/BRepClass3d_SolidExplorer.cxx index 051eac5f1e..ce51048866 100644 --- a/src/BRepClass3d/BRepClass3d_SolidExplorer.cxx +++ b/src/BRepClass3d/BRepClass3d_SolidExplorer.cxx @@ -771,11 +771,11 @@ BRepClass3d_SolidExplorer::BRepClass3d_SolidExplorer(const TopoDS_Shape& S) } //======================================================================= -//function : Delete -//purpose : +//function : ~BRepClass3d_SolidExplorer +//purpose : //======================================================================= -void BRepClass3d_SolidExplorer::Delete() +BRepClass3d_SolidExplorer::~BRepClass3d_SolidExplorer() { Destroy() ; } diff --git a/src/BRepClass3d/BRepClass3d_SolidExplorer.hxx b/src/BRepClass3d/BRepClass3d_SolidExplorer.hxx index 8873a07184..8db650a8f3 100644 --- a/src/BRepClass3d/BRepClass3d_SolidExplorer.hxx +++ b/src/BRepClass3d/BRepClass3d_SolidExplorer.hxx @@ -56,8 +56,7 @@ public: Standard_EXPORT BRepClass3d_SolidExplorer(const TopoDS_Shape& S); - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~BRepClass3d_SolidExplorer(){Destroy() ; } + Standard_EXPORT virtual ~BRepClass3d_SolidExplorer(); Standard_EXPORT void InitShape (const TopoDS_Shape& S); diff --git a/src/BRepLib/BRepLib_Command.cxx b/src/BRepLib/BRepLib_Command.cxx index abb2225392..a52bbe6fe2 100644 --- a/src/BRepLib/BRepLib_Command.cxx +++ b/src/BRepLib/BRepLib_Command.cxx @@ -27,7 +27,7 @@ BRepLib_Command::BRepLib_Command() : { } -void BRepLib_Command::Delete() +BRepLib_Command::~BRepLib_Command() {} //======================================================================= diff --git a/src/BRepLib/BRepLib_Command.hxx b/src/BRepLib/BRepLib_Command.hxx index 1acc1645e9..bf2a5ce1d9 100644 --- a/src/BRepLib/BRepLib_Command.hxx +++ b/src/BRepLib/BRepLib_Command.hxx @@ -40,9 +40,7 @@ public: DEFINE_STANDARD_ALLOC - - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~BRepLib_Command(){Delete() ; } + Standard_EXPORT virtual ~BRepLib_Command(); Standard_EXPORT Standard_Boolean IsDone() const; diff --git a/src/BRepToIGES/BRepToIGES_BREntity.cxx b/src/BRepToIGES/BRepToIGES_BREntity.cxx index 274db3ca5b..2cbf5e28eb 100644 --- a/src/BRepToIGES/BRepToIGES_BREntity.cxx +++ b/src/BRepToIGES/BRepToIGES_BREntity.cxx @@ -374,9 +374,9 @@ Standard_Boolean BRepToIGES_BREntity::GetPCurveMode () const } //======================================================================= -//function : Delete +//function : ~BRepToIGES_BREntity //purpose : //======================================================================= -void BRepToIGES_BREntity::Delete() +BRepToIGES_BREntity::~BRepToIGES_BREntity() {} diff --git a/src/BRepToIGES/BRepToIGES_BREntity.hxx b/src/BRepToIGES/BRepToIGES_BREntity.hxx index 2fa9c25c10..eb6e0f96af 100644 --- a/src/BRepToIGES/BRepToIGES_BREntity.hxx +++ b/src/BRepToIGES/BRepToIGES_BREntity.hxx @@ -108,35 +108,14 @@ public: //! (value of parameter write.surfacecurve.mode) Standard_EXPORT Standard_Boolean GetPCurveMode() const; - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~BRepToIGES_BREntity() { Delete(); } - - - - -protected: - - - - + Standard_EXPORT virtual ~BRepToIGES_BREntity(); private: - - - Handle(IGESData_IGESModel) TheModel; Standard_Real TheUnitFactor; Standard_Boolean myConvSurface; Standard_Boolean myPCurveMode; Handle(Transfer_FinderProcess) TheMap; - - }; - - - - - - #endif // _BRepToIGES_BREntity_HeaderFile diff --git a/src/BinTools/BinTools_ShapeSet.cxx b/src/BinTools/BinTools_ShapeSet.cxx index 5e98faf1d2..5008ddffc1 100644 --- a/src/BinTools/BinTools_ShapeSet.cxx +++ b/src/BinTools/BinTools_ShapeSet.cxx @@ -79,11 +79,11 @@ BinTools_ShapeSet::BinTools_ShapeSet(const Standard_Boolean isWithTriangles) {} //======================================================================= -//function : Delete +//function : ~BinTools_ShapeSet //purpose : //======================================================================= -void BinTools_ShapeSet::Delete() +BinTools_ShapeSet::~BinTools_ShapeSet() {} //======================================================================= diff --git a/src/BinTools/BinTools_ShapeSet.hxx b/src/BinTools/BinTools_ShapeSet.hxx index 6ee6c9b1e3..61eea483d2 100644 --- a/src/BinTools/BinTools_ShapeSet.hxx +++ b/src/BinTools/BinTools_ShapeSet.hxx @@ -48,8 +48,7 @@ public: //! Parameter is added for XML Persistence Standard_EXPORT BinTools_ShapeSet(const Standard_Boolean isWithTriangles = Standard_False); - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~BinTools_ShapeSet(){Delete() ; } + Standard_EXPORT virtual ~BinTools_ShapeSet(); //! Define if shape will be stored with triangles Standard_EXPORT void SetWithTriangles (const Standard_Boolean isWithTriangles); diff --git a/src/CDM/CDM_Document.cxx b/src/CDM/CDM_Document.cxx index abb89f358c..d731826158 100644 --- a/src/CDM/CDM_Document.cxx +++ b/src/CDM/CDM_Document.cxx @@ -70,11 +70,12 @@ CDM_Document::CDM_Document(): //======================================================================= -//function : Destroy +//function : ~CDM_Document //purpose : //======================================================================= -void CDM_Document::Destroy() { +CDM_Document::~CDM_Document() +{ if(!myMetaData.IsNull()) myMetaData->UnsetDocument(); } diff --git a/src/CDM/CDM_Document.hxx b/src/CDM/CDM_Document.hxx index d34be1c98c..5cc70e5554 100644 --- a/src/CDM/CDM_Document.hxx +++ b/src/CDM/CDM_Document.hxx @@ -384,11 +384,7 @@ protected: Standard_EXPORT CDM_Document(); - Standard_EXPORT virtual void Destroy(); -~CDM_Document() -{ - Destroy(); -} + Standard_EXPORT ~CDM_Document(); Standard_Boolean myResourcesAreLoaded; diff --git a/src/ChFi3d/ChFi3d_Builder.cxx b/src/ChFi3d/ChFi3d_Builder.cxx index eb7bba3f1b..a3b63c1b8b 100644 --- a/src/ChFi3d/ChFi3d_Builder.cxx +++ b/src/ChFi3d/ChFi3d_Builder.cxx @@ -167,7 +167,12 @@ static void CompleteDS(TopOpeBRepDS_DataStructure& DStr, } } -void ChFi3d_Builder::Delete() +//======================================================================= +//function : ~ChFi3d_Builder +//purpose : +//======================================================================= + +ChFi3d_Builder::~ChFi3d_Builder() {} //======================================================================= diff --git a/src/ChFi3d/ChFi3d_Builder.hxx b/src/ChFi3d/ChFi3d_Builder.hxx index 79082e6f01..6af9c73620 100644 --- a/src/ChFi3d/ChFi3d_Builder.hxx +++ b/src/ChFi3d/ChFi3d_Builder.hxx @@ -80,9 +80,7 @@ public: DEFINE_STANDARD_ALLOC - - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~ChFi3d_Builder(){Delete() ; } + Standard_EXPORT virtual ~ChFi3d_Builder(); Standard_EXPORT void SetParams (const Standard_Real Tang, const Standard_Real Tesp, const Standard_Real T2d, const Standard_Real TApp3d, const Standard_Real TolApp2d, const Standard_Real Fleche); diff --git a/src/Cocoa/Cocoa_Window.hxx b/src/Cocoa/Cocoa_Window.hxx index 1793597ac6..5dfd3778ad 100644 --- a/src/Cocoa/Cocoa_Window.hxx +++ b/src/Cocoa/Cocoa_Window.hxx @@ -78,13 +78,8 @@ public: Standard_EXPORT Cocoa_Window (NSView* theViewNS); #endif - //! Destroies the Window and all resourses attached to it - Standard_EXPORT virtual void Destroy(); - - ~Cocoa_Window() - { - Destroy(); - } + //! Destroys the Window and all resourses attached to it + Standard_EXPORT ~Cocoa_Window(); //! Opens the window Standard_EXPORT virtual void Map() const Standard_OVERRIDE; diff --git a/src/Cocoa/Cocoa_Window.mm b/src/Cocoa/Cocoa_Window.mm index 168857e7f5..69cbeb7ea0 100644 --- a/src/Cocoa/Cocoa_Window.mm +++ b/src/Cocoa/Cocoa_Window.mm @@ -143,10 +143,10 @@ Cocoa_Window::Cocoa_Window (NSView* theViewNS) } // ======================================================================= -// function : Destroy +// function : ~Cocoa_Window // purpose : // ======================================================================= -void Cocoa_Window::Destroy() +Cocoa_Window::~Cocoa_Window() { #if !defined(HAVE_OBJC_ARC) Cocoa_LocalPool aLocalPool; diff --git a/src/FairCurve/FairCurve_Batten.cxx b/src/FairCurve/FairCurve_Batten.cxx index 3f52ac8f59..259c67d19a 100644 --- a/src/FairCurve/FairCurve_Batten.cxx +++ b/src/FairCurve/FairCurve_Batten.cxx @@ -117,7 +117,7 @@ FairCurve_Batten::FairCurve_Batten(const gp_Pnt2d& P1, Flatknots->ChangeArray1()); } // ================================================================== -void FairCurve_Batten::Delete() +FairCurve_Batten::~FairCurve_Batten() {} // ================================================================== void FairCurve_Batten::Angles(const gp_Pnt2d& P1, diff --git a/src/FairCurve/FairCurve_Batten.hxx b/src/FairCurve/FairCurve_Batten.hxx index e3719b9ebb..c873073d29 100644 --- a/src/FairCurve/FairCurve_Batten.hxx +++ b/src/FairCurve/FairCurve_Batten.hxx @@ -69,8 +69,7 @@ public: //! gp_Pnt2d::IsEqual tests to see if this is the case. Standard_EXPORT FairCurve_Batten(const gp_Pnt2d& P1, const gp_Pnt2d& P2, const Standard_Real Height, const Standard_Real Slope = 0); - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~FairCurve_Batten(){Delete();} + Standard_EXPORT virtual ~FairCurve_Batten(); //! Freesliding is initialized with the default setting false. //! When Freesliding is set to true and, as a result, sliding diff --git a/src/Graphic3d/Graphic3d_DataStructureManager.cxx b/src/Graphic3d/Graphic3d_DataStructureManager.cxx index 77afe37046..443c510ee7 100644 --- a/src/Graphic3d/Graphic3d_DataStructureManager.cxx +++ b/src/Graphic3d/Graphic3d_DataStructureManager.cxx @@ -32,9 +32,3 @@ IMPLEMENT_STANDARD_RTTIEXT(Graphic3d_DataStructureManager,MMgt_TShared) //-Constructors Graphic3d_DataStructureManager::Graphic3d_DataStructureManager () { } - -//-Destructors - -void Graphic3d_DataStructureManager::Destroy () { - -} diff --git a/src/Graphic3d/Graphic3d_DataStructureManager.hxx b/src/Graphic3d/Graphic3d_DataStructureManager.hxx index f2e1025605..39cf35ee75 100644 --- a/src/Graphic3d/Graphic3d_DataStructureManager.hxx +++ b/src/Graphic3d/Graphic3d_DataStructureManager.hxx @@ -34,16 +34,6 @@ class Graphic3d_DataStructureManager : public MMgt_TShared public: - - //! Deletes the manager . - Standard_EXPORT virtual void Destroy(); -~Graphic3d_DataStructureManager() -{ - Destroy(); -} - - - DEFINE_STANDARD_RTTIEXT(Graphic3d_DataStructureManager,MMgt_TShared) protected: diff --git a/src/Graphic3d/Graphic3d_Structure.cxx b/src/Graphic3d/Graphic3d_Structure.cxx index a32663511a..0ecb12de8d 100644 --- a/src/Graphic3d/Graphic3d_Structure.cxx +++ b/src/Graphic3d/Graphic3d_Structure.cxx @@ -98,10 +98,10 @@ Graphic3d_Structure::Graphic3d_Structure (const Handle(Graphic3d_StructureManage } //============================================================================= -//function : Destroy +//function : ~Graphic3d_Structure //purpose : //============================================================================= -void Graphic3d_Structure::Destroy() +Graphic3d_Structure::~Graphic3d_Structure() { // as myFirstStructureManager can be already destroyed, // avoid attempts to access it diff --git a/src/Graphic3d/Graphic3d_Structure.hxx b/src/Graphic3d/Graphic3d_Structure.hxx index 2fdc75f6e9..f3d869180e 100644 --- a/src/Graphic3d/Graphic3d_Structure.hxx +++ b/src/Graphic3d/Graphic3d_Structure.hxx @@ -99,11 +99,7 @@ public: //! Suppresses the structure . //! It will be erased at the next screen update. - Standard_EXPORT virtual void Destroy(); -~Graphic3d_Structure() -{ - Destroy(); -} + Standard_EXPORT ~Graphic3d_Structure(); //! Displays the structure in all the views of the visualiser. Standard_EXPORT virtual void Display(); diff --git a/src/Graphic3d/Graphic3d_StructureManager.cxx b/src/Graphic3d/Graphic3d_StructureManager.cxx index d858c23e1b..de34df4ea9 100644 --- a/src/Graphic3d/Graphic3d_StructureManager.cxx +++ b/src/Graphic3d/Graphic3d_StructureManager.cxx @@ -101,8 +101,8 @@ Standard_Integer Limit = Graphic3d_StructureManager::Limit (); //-Destructors -void Graphic3d_StructureManager::Destroy () { - +Graphic3d_StructureManager::~Graphic3d_StructureManager () +{ myDisplayedStructure.Clear (); myHighlightedStructure.Clear (); myDefinedViews.Clear(); diff --git a/src/Graphic3d/Graphic3d_StructureManager.hxx b/src/Graphic3d/Graphic3d_StructureManager.hxx index 1892bf86c2..946ad39e3e 100644 --- a/src/Graphic3d/Graphic3d_StructureManager.hxx +++ b/src/Graphic3d/Graphic3d_StructureManager.hxx @@ -70,11 +70,7 @@ public: Standard_EXPORT Graphic3d_StructureManager (const Handle(Graphic3d_GraphicDriver)& theDriver); //! Deletes the manager . - Standard_EXPORT virtual void Destroy(); -~Graphic3d_StructureManager() -{ - Destroy(); -} + Standard_EXPORT ~Graphic3d_StructureManager(); //! Modifies the default attributes for lines //! in the visualiser. diff --git a/src/IFGraph/IFGraph_SubPartsIterator.cxx b/src/IFGraph/IFGraph_SubPartsIterator.cxx index 37f698827c..cf430b620c 100644 --- a/src/IFGraph/IFGraph_SubPartsIterator.cxx +++ b/src/IFGraph/IFGraph_SubPartsIterator.cxx @@ -253,9 +253,9 @@ IFGraph_SubPartsIterator::IFGraph_SubPartsIterator } //======================================================================= -//function : Delete +//function : ~IFGraph_SubPartsIterator //purpose : //======================================================================= -void IFGraph_SubPartsIterator::Delete() +IFGraph_SubPartsIterator::~IFGraph_SubPartsIterator() {} diff --git a/src/IFGraph/IFGraph_SubPartsIterator.hxx b/src/IFGraph/IFGraph_SubPartsIterator.hxx index a6f6e9559f..cc4f243045 100644 --- a/src/IFGraph/IFGraph_SubPartsIterator.hxx +++ b/src/IFGraph/IFGraph_SubPartsIterator.hxx @@ -150,11 +150,7 @@ public: //! Error : same as above (end of iteration) Standard_EXPORT Interface_EntityIterator Entities() const; - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~IFGraph_SubPartsIterator() { Delete(); } - - - + Standard_EXPORT virtual ~IFGraph_SubPartsIterator(); protected: diff --git a/src/Interface/Interface_EntityIterator.cxx b/src/Interface/Interface_EntityIterator.cxx index e04f9a4b21..4bf98b4561 100644 --- a/src/Interface/Interface_EntityIterator.cxx +++ b/src/Interface/Interface_EntityIterator.cxx @@ -150,5 +150,11 @@ Interface_EntityIterator::Interface_EntityIterator () return thelist; } - void Interface_EntityIterator::Destroy () +void Interface_EntityIterator::Destroy () { thecurr.Nullify(); } // redevient vide ! + +Interface_EntityIterator::~Interface_EntityIterator() +{ + Destroy(); +} + diff --git a/src/Interface/Interface_EntityIterator.hxx b/src/Interface/Interface_EntityIterator.hxx index 3204ab502f..48beaf7ad3 100644 --- a/src/Interface/Interface_EntityIterator.hxx +++ b/src/Interface/Interface_EntityIterator.hxx @@ -90,11 +90,10 @@ public: Standard_EXPORT Handle(TColStd_HSequenceOfTransient) Content() const; //! Clears data of iteration - Standard_EXPORT virtual void Destroy(); -Standard_EXPORT virtual ~Interface_EntityIterator() { Destroy();} - - + Standard_EXPORT void Destroy(); + //! Destructor + Standard_EXPORT virtual ~Interface_EntityIterator(); protected: diff --git a/src/Interface/Interface_FileReaderTool.cxx b/src/Interface/Interface_FileReaderTool.cxx index 7f0edbe476..1009559138 100644 --- a/src/Interface/Interface_FileReaderTool.cxx +++ b/src/Interface/Interface_FileReaderTool.cxx @@ -566,11 +566,11 @@ Handle(Standard_Transient) Interface_FileReaderTool::LoadedEntity //======================================================================= -//function : Destroy +//function : ~Interface_FileReaderTool //purpose : //======================================================================= -void Interface_FileReaderTool::Destroy() +Interface_FileReaderTool::~Interface_FileReaderTool() {} void Interface_FileReaderTool::Clear() diff --git a/src/Interface/Interface_FileReaderTool.hxx b/src/Interface/Interface_FileReaderTool.hxx index f1a220d9cf..216bb4aec9 100644 --- a/src/Interface/Interface_FileReaderTool.hxx +++ b/src/Interface/Interface_FileReaderTool.hxx @@ -175,8 +175,7 @@ public: //! else (in case of syntactic fail) Standard_EXPORT virtual Standard_Boolean AnalyseRecord (const Standard_Integer num, const Handle(Standard_Transient)& anent, Handle(Interface_Check)& acheck) = 0; - Standard_EXPORT virtual void Destroy(); -Standard_EXPORT virtual ~Interface_FileReaderTool() { Destroy(); } + Standard_EXPORT virtual ~Interface_FileReaderTool(); //! Ends file reading after reading all the entities //! default is doing nothing; redefinable as necessary diff --git a/src/MeshVS/MeshVS_Mesh.cxx b/src/MeshVS/MeshVS_Mesh.cxx index c4c7a32ee7..1027721d4b 100644 --- a/src/MeshVS/MeshVS_Mesh.cxx +++ b/src/MeshVS/MeshVS_Mesh.cxx @@ -133,10 +133,6 @@ MeshVS_Mesh::MeshVS_Mesh (const Standard_Boolean theIsAllowOverlapped ) myHilightDrawer->SetDouble ( MeshVS_DA_MarkerScale, 2.0 ); } -void MeshVS_Mesh::Destroy() -{ -} - //================================================================ // Function : Compute // Purpose : diff --git a/src/MeshVS/MeshVS_Mesh.hxx b/src/MeshVS/MeshVS_Mesh.hxx index e726125457..2561ccf717 100644 --- a/src/MeshVS/MeshVS_Mesh.hxx +++ b/src/MeshVS/MeshVS_Mesh.hxx @@ -53,12 +53,6 @@ public: //! Its value is stored in drawer Standard_EXPORT MeshVS_Mesh(const Standard_Boolean theIsAllowOverlapped = Standard_False); - Standard_EXPORT virtual void Destroy(); -~MeshVS_Mesh() -{ - Destroy(); -} - //! Computes presentation using builders added to sequence. Each builder computes //! own part of mesh presentation according to its type. Standard_EXPORT virtual void Compute (const Handle(PrsMgr_PresentationManager3d)& PM, const Handle(Prs3d_Presentation)& Prs, const Standard_Integer DisplayMode) Standard_OVERRIDE; diff --git a/src/MoniTool/MoniTool_OptValue.cxx b/src/MoniTool/MoniTool_OptValue.cxx index 83a4e6fadd..df8b7bed6d 100644 --- a/src/MoniTool/MoniTool_OptValue.cxx +++ b/src/MoniTool/MoniTool_OptValue.cxx @@ -56,9 +56,9 @@ MoniTool_OptValue::MoniTool_OptValue (const Standard_CString opt) { val = theval; } //======================================================================= -//function : Delete +//function : ~MoniTool_OptValue //purpose : //======================================================================= -void MoniTool_OptValue::Delete() +MoniTool_OptValue::~MoniTool_OptValue() {} diff --git a/src/MoniTool/MoniTool_OptValue.hxx b/src/MoniTool/MoniTool_OptValue.hxx index 9afdba1ed2..f1e075525f 100644 --- a/src/MoniTool/MoniTool_OptValue.hxx +++ b/src/MoniTool/MoniTool_OptValue.hxx @@ -95,32 +95,11 @@ public: //! Warning : type is not controlled Standard_EXPORT void Value (Handle(Standard_Transient)& val) const; - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~MoniTool_OptValue() { Delete(); } - - - - -protected: - - - - + Standard_EXPORT virtual ~MoniTool_OptValue(); private: - - - TCollection_AsciiString theopt; Handle(Standard_Transient) theval; - - }; - - - - - - #endif // _MoniTool_OptValue_HeaderFile diff --git a/src/MoniTool/MoniTool_TimerSentry.hxx b/src/MoniTool/MoniTool_TimerSentry.hxx index c3e735d68b..cfabc1d3ab 100644 --- a/src/MoniTool/MoniTool_TimerSentry.hxx +++ b/src/MoniTool/MoniTool_TimerSentry.hxx @@ -44,8 +44,7 @@ public: MoniTool_TimerSentry(const Handle(MoniTool_Timer)& timer); //! Destructor stops the associated timer - void Destroy(); -Standard_EXPORT ~MoniTool_TimerSentry () { Destroy(); } + ~MoniTool_TimerSentry (); Handle(MoniTool_Timer) Timer() const; diff --git a/src/MoniTool/MoniTool_TimerSentry.lxx b/src/MoniTool/MoniTool_TimerSentry.lxx index 0d3f6c42b6..df40366d2b 100644 --- a/src/MoniTool/MoniTool_TimerSentry.lxx +++ b/src/MoniTool/MoniTool_TimerSentry.lxx @@ -36,11 +36,11 @@ inline MoniTool_TimerSentry::MoniTool_TimerSentry (const Handle(MoniTool_Timer)& } //======================================================================= -//function : Destroy +//function : Destructor //purpose : make stop for corresponding timer before destroying //======================================================================= -inline void MoniTool_TimerSentry::Destroy() +inline MoniTool_TimerSentry::~MoniTool_TimerSentry() { if ( ! myTimer.IsNull() ) myTimer->Stop(); } diff --git a/src/ProjLib/ProjLib_ProjectOnSurface.cxx b/src/ProjLib/ProjLib_ProjectOnSurface.cxx index 58e66845fb..667302d8ad 100644 --- a/src/ProjLib/ProjLib_ProjectOnSurface.cxx +++ b/src/ProjLib/ProjLib_ProjectOnSurface.cxx @@ -246,7 +246,12 @@ void ProjLib_ProjectOnSurface::Load(const Handle(Adaptor3d_HCurve)& C, } } -void ProjLib_ProjectOnSurface::Delete() +//======================================================================= +//function : ~ProjLib_ProjectOnSurface +//purpose : +//======================================================================= + +ProjLib_ProjectOnSurface::~ProjLib_ProjectOnSurface() {} //======================================================================= diff --git a/src/ProjLib/ProjLib_ProjectOnSurface.hxx b/src/ProjLib/ProjLib_ProjectOnSurface.hxx index 9d5accde33..a88db5fa1f 100644 --- a/src/ProjLib/ProjLib_ProjectOnSurface.hxx +++ b/src/ProjLib/ProjLib_ProjectOnSurface.hxx @@ -43,8 +43,7 @@ public: //! Create a projector normaly to the surface . Standard_EXPORT ProjLib_ProjectOnSurface(const Handle(Adaptor3d_HSurface)& S); - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~ProjLib_ProjectOnSurface(){Delete() ; } + Standard_EXPORT virtual ~ProjLib_ProjectOnSurface(); //! Set the Surface to . //! To compute the projection, you have to Load the Curve. diff --git a/src/PrsMgr/PrsMgr_Presentation.cxx b/src/PrsMgr/PrsMgr_Presentation.cxx index e585398e7d..22ee0e2fe9 100644 --- a/src/PrsMgr/PrsMgr_Presentation.cxx +++ b/src/PrsMgr/PrsMgr_Presentation.cxx @@ -389,10 +389,10 @@ Handle(Prs3d_Projector) PrsMgr_Presentation::Projector (const Handle(Graphic3d_D } //======================================================================= -//function : Destroy +//function : ~PrsMgr_Presentation //purpose : //======================================================================= -void PrsMgr_Presentation::Destroy() +PrsMgr_Presentation::~PrsMgr_Presentation() { Erase(); } diff --git a/src/PrsMgr/PrsMgr_Presentation.hxx b/src/PrsMgr/PrsMgr_Presentation.hxx index e04bb1627c..e93f122a3a 100644 --- a/src/PrsMgr/PrsMgr_Presentation.hxx +++ b/src/PrsMgr/PrsMgr_Presentation.hxx @@ -49,11 +49,7 @@ public: //! Destructor - Standard_EXPORT virtual void Destroy(); -~PrsMgr_Presentation() -{ - Destroy(); -} + Standard_EXPORT ~PrsMgr_Presentation(); const Handle(Prs3d_Presentation)& Presentation() const; diff --git a/src/QANewModTopOpe/QANewModTopOpe_Limitation.cxx b/src/QANewModTopOpe/QANewModTopOpe_Limitation.cxx index d3890dec94..8b5e24ff41 100644 --- a/src/QANewModTopOpe/QANewModTopOpe_Limitation.cxx +++ b/src/QANewModTopOpe/QANewModTopOpe_Limitation.cxx @@ -295,7 +295,7 @@ Standard_Boolean QANewModTopOpe_Limitation::IsDeleted(const TopoDS_Shape& S) } -void QANewModTopOpe_Limitation::Delete() +QANewModTopOpe_Limitation::~QANewModTopOpe_Limitation() { delete myCut; delete myCommon; diff --git a/src/QANewModTopOpe/QANewModTopOpe_Limitation.hxx b/src/QANewModTopOpe/QANewModTopOpe_Limitation.hxx index ab28bd7971..1aef94f1b6 100644 --- a/src/QANewModTopOpe/QANewModTopOpe_Limitation.hxx +++ b/src/QANewModTopOpe/QANewModTopOpe_Limitation.hxx @@ -81,17 +81,7 @@ public: Standard_EXPORT virtual Standard_Boolean IsDeleted (const TopoDS_Shape& S) Standard_OVERRIDE; - Standard_EXPORT virtual void Delete() Standard_OVERRIDE; -Standard_EXPORT ~QANewModTopOpe_Limitation() {Delete();} - - - - -protected: - - - - + Standard_EXPORT ~QANewModTopOpe_Limitation(); private: diff --git a/src/ShapeUpgrade/ShapeUpgrade_ShapeDivide.cxx b/src/ShapeUpgrade/ShapeUpgrade_ShapeDivide.cxx index ff18adbf22..31e5e2a45e 100644 --- a/src/ShapeUpgrade/ShapeUpgrade_ShapeDivide.cxx +++ b/src/ShapeUpgrade/ShapeUpgrade_ShapeDivide.cxx @@ -80,11 +80,11 @@ void ShapeUpgrade_ShapeDivide::Init(const TopoDS_Shape &S) } //======================================================================= -//function : Delete +//function : ~ShapeUpgrade_ShapeDivide //purpose : //======================================================================= -void ShapeUpgrade_ShapeDivide::Delete() +ShapeUpgrade_ShapeDivide::~ShapeUpgrade_ShapeDivide() {} diff --git a/src/ShapeUpgrade/ShapeUpgrade_ShapeDivide.hxx b/src/ShapeUpgrade/ShapeUpgrade_ShapeDivide.hxx index da284647eb..7e6fc37be6 100644 --- a/src/ShapeUpgrade/ShapeUpgrade_ShapeDivide.hxx +++ b/src/ShapeUpgrade/ShapeUpgrade_ShapeDivide.hxx @@ -50,8 +50,7 @@ public: //! Initialize by a Shape. Standard_EXPORT void Init (const TopoDS_Shape& S); - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~ShapeUpgrade_ShapeDivide(){Delete();} + Standard_EXPORT virtual ~ShapeUpgrade_ShapeDivide(); //! Defines the spatial precision used for splitting Standard_EXPORT void SetPrecision (const Standard_Real Prec); diff --git a/src/StepData/StepData_FieldList.cxx b/src/StepData/StepData_FieldList.cxx index 0a93bd3aa7..ec78dd67a9 100644 --- a/src/StepData/StepData_FieldList.cxx +++ b/src/StepData/StepData_FieldList.cxx @@ -19,6 +19,10 @@ static StepData_Field nulfild; +StepData_FieldList::~StepData_FieldList() +{ +} + StepData_FieldList::StepData_FieldList () { } Standard_Integer StepData_FieldList::NbFields () const diff --git a/src/StepData/StepData_FieldList.hxx b/src/StepData/StepData_FieldList.hxx index 94e6d90c1f..3371e87f75 100644 --- a/src/StepData/StepData_FieldList.hxx +++ b/src/StepData/StepData_FieldList.hxx @@ -36,6 +36,8 @@ public: DEFINE_STANDARD_ALLOC + //! Destructor is virtual + Standard_EXPORT virtual ~StepData_FieldList(); //! Creates a FieldList of 0 Field Standard_EXPORT StepData_FieldList(); @@ -52,28 +54,6 @@ public: //! Fills an iterator with the entities shared by Standard_EXPORT void FillShared (Interface_EntityIterator& iter) const; - - - - -protected: - - - - - -private: - - - - - }; - - - - - - #endif // _StepData_FieldList_HeaderFile diff --git a/src/StepData/StepData_FieldList1.cxx b/src/StepData/StepData_FieldList1.cxx index 7c8dd040a9..e3a8b3d9d8 100644 --- a/src/StepData/StepData_FieldList1.cxx +++ b/src/StepData/StepData_FieldList1.cxx @@ -32,6 +32,3 @@ StepData_Field& StepData_FieldList1::CField (const Standard_Integer num) if (num != 1) Standard_OutOfRange::Raise("StepData_FieldList1 : CField"); return thefield; } - -void StepData_FieldList1::Destroy () {} - diff --git a/src/StepData/StepData_FieldList1.hxx b/src/StepData/StepData_FieldList1.hxx index db8e64d5ed..9b88156f09 100644 --- a/src/StepData/StepData_FieldList1.hxx +++ b/src/StepData/StepData_FieldList1.hxx @@ -49,18 +49,6 @@ public: //! modify its content Standard_EXPORT virtual StepData_Field& CField (const Standard_Integer num) Standard_OVERRIDE; - Standard_EXPORT virtual void Destroy(); -Standard_EXPORT virtual ~StepData_FieldList1() { Destroy(); } - - - - -protected: - - - - - private: diff --git a/src/StepData/StepData_FieldListD.cxx b/src/StepData/StepData_FieldListD.cxx index bf8eda0ac0..30efabd57d 100644 --- a/src/StepData/StepData_FieldListD.cxx +++ b/src/StepData/StepData_FieldListD.cxx @@ -39,6 +39,3 @@ StepData_Field& StepData_FieldListD::CField (const Standard_Integer num) if (thefields.IsNull()) Standard_OutOfRange::Raise("StepData_FieldListD::Field"); return thefields->ChangeValue(num); } - -void StepData_FieldListD::Destroy () {} - diff --git a/src/StepData/StepData_FieldListD.hxx b/src/StepData/StepData_FieldListD.hxx index 2b69fa92ed..eda422fe38 100644 --- a/src/StepData/StepData_FieldListD.hxx +++ b/src/StepData/StepData_FieldListD.hxx @@ -53,18 +53,6 @@ public: //! Returns the field n0 between 1 and NbFields, in order to //! modify its content Standard_EXPORT virtual StepData_Field& CField (const Standard_Integer num) Standard_OVERRIDE; - - Standard_EXPORT virtual void Destroy(); -Standard_EXPORT virtual ~StepData_FieldListD() { Destroy(); } - - - - -protected: - - - - private: diff --git a/src/StepData/StepData_FieldListN.cxx b/src/StepData/StepData_FieldListN.cxx index fb6f76cc7d..d3f185ee4b 100644 --- a/src/StepData/StepData_FieldListN.cxx +++ b/src/StepData/StepData_FieldListN.cxx @@ -31,6 +31,3 @@ StepData_Field& StepData_FieldListN::CField (const Standard_Integer num) { return thefields.ChangeValue(num); } - -void StepData_FieldListN::Destroy() {} - diff --git a/src/StepData/StepData_FieldListN.hxx b/src/StepData/StepData_FieldListN.hxx index 7d1239b5b3..691f75db3d 100644 --- a/src/StepData/StepData_FieldListN.hxx +++ b/src/StepData/StepData_FieldListN.hxx @@ -50,18 +50,6 @@ public: //! Returns the field n0 between 1 and NbFields, in order to //! modify its content Standard_EXPORT virtual StepData_Field& CField (const Standard_Integer num) Standard_OVERRIDE; - - Standard_EXPORT virtual void Destroy(); -Standard_EXPORT virtual ~StepData_FieldListN() { Destroy(); } - - - - -protected: - - - - private: diff --git a/src/StepData/StepData_SelectType.cxx b/src/StepData/StepData_SelectType.cxx index aaa66bd5cb..db55e4bcbd 100644 --- a/src/StepData/StepData_SelectType.cxx +++ b/src/StepData/StepData_SelectType.cxx @@ -188,4 +188,5 @@ Standard_Real StepData_SelectType::Real () const thevalue = sm; } -void StepData_SelectType::Destroy(){} +StepData_SelectType::~StepData_SelectType() +{} diff --git a/src/StepData/StepData_SelectType.hxx b/src/StepData/StepData_SelectType.hxx index f70db763f6..05040ef80a 100644 --- a/src/StepData/StepData_SelectType.hxx +++ b/src/StepData/StepData_SelectType.hxx @@ -157,17 +157,7 @@ public: Standard_EXPORT void SetReal (const Standard_Real val, const Standard_CString name = ""); - Standard_EXPORT virtual void Destroy(); -Standard_EXPORT virtual ~StepData_SelectType() { Destroy(); } - - - - -protected: - - - - + Standard_EXPORT virtual ~StepData_SelectType(); private: diff --git a/src/Storage/Storage_BaseDriver.cxx b/src/Storage/Storage_BaseDriver.cxx index 76a76f791e..ee0bc8791a 100644 --- a/src/Storage/Storage_BaseDriver.cxx +++ b/src/Storage/Storage_BaseDriver.cxx @@ -24,7 +24,8 @@ Storage_BaseDriver::Storage_BaseDriver() : myOpenMode(Storage_VSNone) { } -void Storage_BaseDriver::Delete() + +Storage_BaseDriver::~Storage_BaseDriver() {} TCollection_AsciiString Storage_BaseDriver::ReadMagicNumber (Standard_IStream& theIStream) diff --git a/src/Storage/Storage_BaseDriver.hxx b/src/Storage/Storage_BaseDriver.hxx index 8541ddc73e..a6f345b144 100644 --- a/src/Storage/Storage_BaseDriver.hxx +++ b/src/Storage/Storage_BaseDriver.hxx @@ -53,9 +53,7 @@ public: DEFINE_STANDARD_ALLOC - - Standard_EXPORT void Delete(); -Standard_EXPORT virtual ~Storage_BaseDriver(){Delete();} + Standard_EXPORT virtual ~Storage_BaseDriver(); Standard_EXPORT virtual Storage_Error Open (const TCollection_AsciiString& aName, const Storage_OpenMode aMode) = 0; diff --git a/src/TopOpeBRep/TopOpeBRep_DSFiller.cxx b/src/TopOpeBRep/TopOpeBRep_DSFiller.cxx index c17b884d07..ee17c44b2d 100644 --- a/src/TopOpeBRep/TopOpeBRep_DSFiller.cxx +++ b/src/TopOpeBRep/TopOpeBRep_DSFiller.cxx @@ -100,10 +100,10 @@ TopOpeBRep_DSFiller::TopOpeBRep_DSFiller() //modified by NIZNHY-PKV Mon Dec 16 11:12:38 2002 f //======================================================================= -//function : Destroy -//purpose : alias ~TopOpeBRep_DSFiller +//function : ~TopOpeBRep_DSFiller +//purpose : //======================================================================= -void TopOpeBRep_DSFiller::Destroy() +TopOpeBRep_DSFiller::~TopOpeBRep_DSFiller() { if (myPShapeClassifier) { delete myPShapeClassifier; diff --git a/src/TopOpeBRep/TopOpeBRep_DSFiller.hxx b/src/TopOpeBRep/TopOpeBRep_DSFiller.hxx index 72f63b531c..7f0dfffc8e 100644 --- a/src/TopOpeBRep/TopOpeBRep_DSFiller.hxx +++ b/src/TopOpeBRep/TopOpeBRep_DSFiller.hxx @@ -58,8 +58,7 @@ public: Standard_EXPORT TopOpeBRep_DSFiller(); - Standard_EXPORT void Destroy(); -Standard_EXPORT ~TopOpeBRep_DSFiller() {Destroy();} + Standard_EXPORT ~TopOpeBRep_DSFiller(); //! return field myPShapeClassifier. //! set field myPShapeClassifier. diff --git a/src/TopOpeBRep/TopOpeBRep_EdgesIntersector.cxx b/src/TopOpeBRep/TopOpeBRep_EdgesIntersector.cxx index d5cce79a1b..79ed2b09b6 100644 --- a/src/TopOpeBRep/TopOpeBRep_EdgesIntersector.cxx +++ b/src/TopOpeBRep/TopOpeBRep_EdgesIntersector.cxx @@ -108,7 +108,7 @@ TopOpeBRep_EdgesIntersector::TopOpeBRep_EdgesIntersector() myselectkeep = Standard_True; } -void TopOpeBRep_EdgesIntersector::Delete() +TopOpeBRep_EdgesIntersector::~TopOpeBRep_EdgesIntersector() {} //======================================================================= diff --git a/src/TopOpeBRep/TopOpeBRep_EdgesIntersector.hxx b/src/TopOpeBRep/TopOpeBRep_EdgesIntersector.hxx index cba41622f4..c79d8c6a3b 100644 --- a/src/TopOpeBRep/TopOpeBRep_EdgesIntersector.hxx +++ b/src/TopOpeBRep/TopOpeBRep_EdgesIntersector.hxx @@ -60,8 +60,7 @@ public: Standard_EXPORT TopOpeBRep_EdgesIntersector(); - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~TopOpeBRep_EdgesIntersector(){Delete() ; } + Standard_EXPORT virtual ~TopOpeBRep_EdgesIntersector(); Standard_EXPORT void SetFaces (const TopoDS_Shape& F1, const TopoDS_Shape& F2); diff --git a/src/TopOpeBRepBuild/TopOpeBRepBuild_AreaBuilder.cxx b/src/TopOpeBRepBuild/TopOpeBRepBuild_AreaBuilder.cxx index 76d5467df5..b92c471581 100644 --- a/src/TopOpeBRepBuild/TopOpeBRepBuild_AreaBuilder.cxx +++ b/src/TopOpeBRepBuild/TopOpeBRepBuild_AreaBuilder.cxx @@ -55,7 +55,7 @@ myUNKNOWNRaise(Standard_False) // no raise if UNKNOWN state found InitAreaBuilder(LS,LC,ForceClass); } -void TopOpeBRepBuild_AreaBuilder::Delete() +TopOpeBRepBuild_AreaBuilder::~TopOpeBRepBuild_AreaBuilder() {} //======================================================================= diff --git a/src/TopOpeBRepBuild/TopOpeBRepBuild_AreaBuilder.hxx b/src/TopOpeBRepBuild/TopOpeBRepBuild_AreaBuilder.hxx index 0d2680dc17..c591b3452c 100644 --- a/src/TopOpeBRepBuild/TopOpeBRepBuild_AreaBuilder.hxx +++ b/src/TopOpeBRepBuild/TopOpeBRepBuild_AreaBuilder.hxx @@ -66,8 +66,7 @@ public: //! the shapes described by using the classifier . Standard_EXPORT TopOpeBRepBuild_AreaBuilder(TopOpeBRepBuild_LoopSet& LS, TopOpeBRepBuild_LoopClassifier& LC, const Standard_Boolean ForceClass = Standard_False); - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~TopOpeBRepBuild_AreaBuilder(){Delete() ; } + Standard_EXPORT virtual ~TopOpeBRepBuild_AreaBuilder(); //! Sets a AreaBuilder to find the areas on //! the shapes described by using the classifier . diff --git a/src/TopOpeBRepBuild/TopOpeBRepBuild_Builder.cxx b/src/TopOpeBRepBuild/TopOpeBRepBuild_Builder.cxx index fc83cacf0f..209441cc3f 100644 --- a/src/TopOpeBRepBuild/TopOpeBRepBuild_Builder.cxx +++ b/src/TopOpeBRepBuild/TopOpeBRepBuild_Builder.cxx @@ -99,10 +99,10 @@ TopOpeBRepBuild_Builder::TopOpeBRepBuild_Builder(const TopOpeBRepDS_BuildTool& B //modified by NIZHNY-MZV Sat May 6 10:04:49 2000 //======================================================================= -//function : Destroy +//function : ~TopOpeBRepBuild_Builder //purpose : virtual destructor //======================================================================= -void TopOpeBRepBuild_Builder::Destroy() +TopOpeBRepBuild_Builder::~TopOpeBRepBuild_Builder() { } diff --git a/src/TopOpeBRepBuild/TopOpeBRepBuild_Builder.hxx b/src/TopOpeBRepBuild/TopOpeBRepBuild_Builder.hxx index 047ef14137..393453dc09 100644 --- a/src/TopOpeBRepBuild/TopOpeBRepBuild_Builder.hxx +++ b/src/TopOpeBRepBuild/TopOpeBRepBuild_Builder.hxx @@ -89,8 +89,7 @@ public: Standard_EXPORT TopOpeBRepBuild_Builder(const TopOpeBRepDS_BuildTool& BT); - Standard_EXPORT virtual void Destroy(); -Standard_EXPORT virtual ~TopOpeBRepBuild_Builder() { Destroy() ; } + Standard_EXPORT virtual ~TopOpeBRepBuild_Builder(); Standard_EXPORT TopOpeBRepDS_BuildTool& ChangeBuildTool(); diff --git a/src/TopOpeBRepBuild/TopOpeBRepBuild_Builder1.hxx b/src/TopOpeBRepBuild/TopOpeBRepBuild_Builder1.hxx index 0bb15b5c54..ec2183077e 100644 --- a/src/TopOpeBRepBuild/TopOpeBRepBuild_Builder1.hxx +++ b/src/TopOpeBRepBuild/TopOpeBRepBuild_Builder1.hxx @@ -58,8 +58,7 @@ public: Standard_EXPORT TopOpeBRepBuild_Builder1(const TopOpeBRepDS_BuildTool& BT); - Standard_EXPORT virtual void Destroy() Standard_OVERRIDE; -Standard_EXPORT virtual ~TopOpeBRepBuild_Builder1() { Destroy() ; } + Standard_EXPORT virtual ~TopOpeBRepBuild_Builder1(); //! Removes all splits and merges already performed. //! Does NOT clear the handled DS (except ShapeWithStatesMaps). diff --git a/src/TopOpeBRepBuild/TopOpeBRepBuild_Builder1_1.cxx b/src/TopOpeBRepBuild/TopOpeBRepBuild_Builder1_1.cxx index 856017194b..a23853e3ec 100644 --- a/src/TopOpeBRepBuild/TopOpeBRepBuild_Builder1_1.cxx +++ b/src/TopOpeBRepBuild/TopOpeBRepBuild_Builder1_1.cxx @@ -87,10 +87,10 @@ extern Standard_Boolean GLOBAL_faces2d; //modified by NIZNHY-PKV Mon Dec 16 11:38:55 2002 f //======================================================================= -//function : Destroy +//function : ~TopOpeBRepBuild_Builder1 //purpose : //======================================================================= -void TopOpeBRepBuild_Builder1::Destroy() +TopOpeBRepBuild_Builder1::~TopOpeBRepBuild_Builder1() { processedEdges.Clear(); theUsedVertexMap.Clear(); diff --git a/src/TopOpeBRepBuild/TopOpeBRepBuild_LoopClassifier.cxx b/src/TopOpeBRepBuild/TopOpeBRepBuild_LoopClassifier.cxx index 13c6d238f9..0a6aca8739 100644 --- a/src/TopOpeBRepBuild/TopOpeBRepBuild_LoopClassifier.cxx +++ b/src/TopOpeBRepBuild/TopOpeBRepBuild_LoopClassifier.cxx @@ -18,5 +18,5 @@ #include #include -void TopOpeBRepBuild_LoopClassifier::Delete() +TopOpeBRepBuild_LoopClassifier::~TopOpeBRepBuild_LoopClassifier() {} diff --git a/src/TopOpeBRepBuild/TopOpeBRepBuild_LoopClassifier.hxx b/src/TopOpeBRepBuild/TopOpeBRepBuild_LoopClassifier.hxx index 04af148cbf..733cdbcd76 100644 --- a/src/TopOpeBRepBuild/TopOpeBRepBuild_LoopClassifier.hxx +++ b/src/TopOpeBRepBuild/TopOpeBRepBuild_LoopClassifier.hxx @@ -32,9 +32,7 @@ public: DEFINE_STANDARD_ALLOC - - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~TopOpeBRepBuild_LoopClassifier(){Delete() ; } + Standard_EXPORT virtual ~TopOpeBRepBuild_LoopClassifier(); //! Returns the state of loop compared with loop . Standard_EXPORT virtual TopAbs_State Compare (const Handle(TopOpeBRepBuild_Loop)& L1, const Handle(TopOpeBRepBuild_Loop)& L2) = 0; diff --git a/src/TopOpeBRepBuild/TopOpeBRepBuild_LoopSet.cxx b/src/TopOpeBRepBuild/TopOpeBRepBuild_LoopSet.cxx index 67715df8e2..b6cec72f41 100644 --- a/src/TopOpeBRepBuild/TopOpeBRepBuild_LoopSet.cxx +++ b/src/TopOpeBRepBuild/TopOpeBRepBuild_LoopSet.cxx @@ -27,7 +27,7 @@ myLoopIndex(1), myNbLoop(0) { } -void TopOpeBRepBuild_LoopSet::Delete() +TopOpeBRepBuild_LoopSet::~TopOpeBRepBuild_LoopSet() {} //======================================================================= diff --git a/src/TopOpeBRepBuild/TopOpeBRepBuild_LoopSet.hxx b/src/TopOpeBRepBuild/TopOpeBRepBuild_LoopSet.hxx index a6890dc7bf..c2c933327f 100644 --- a/src/TopOpeBRepBuild/TopOpeBRepBuild_LoopSet.hxx +++ b/src/TopOpeBRepBuild/TopOpeBRepBuild_LoopSet.hxx @@ -38,8 +38,7 @@ public: Standard_EXPORT TopOpeBRepBuild_LoopSet(); - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~TopOpeBRepBuild_LoopSet(){Delete() ; } + Standard_EXPORT virtual ~TopOpeBRepBuild_LoopSet(); Standard_EXPORT TopOpeBRepBuild_ListOfLoop& ChangeListOfLoop(); diff --git a/src/TopOpeBRepBuild/TopOpeBRepBuild_ShapeSet.cxx b/src/TopOpeBRepBuild/TopOpeBRepBuild_ShapeSet.cxx index 381fb0c41c..4d75721cc5 100644 --- a/src/TopOpeBRepBuild/TopOpeBRepBuild_ShapeSet.cxx +++ b/src/TopOpeBRepBuild/TopOpeBRepBuild_ShapeSet.cxx @@ -56,7 +56,7 @@ TopOpeBRepBuild_ShapeSet::TopOpeBRepBuild_ShapeSet(const TopAbs_ShapeEnum SubSha myCheckShape = Standard_False; // temporary NYI } -void TopOpeBRepBuild_ShapeSet::Delete() +TopOpeBRepBuild_ShapeSet::~TopOpeBRepBuild_ShapeSet() {} //======================================================================= diff --git a/src/TopOpeBRepBuild/TopOpeBRepBuild_ShapeSet.hxx b/src/TopOpeBRepBuild/TopOpeBRepBuild_ShapeSet.hxx index d0f5a4ec79..331563b6fd 100644 --- a/src/TopOpeBRepBuild/TopOpeBRepBuild_ShapeSet.hxx +++ b/src/TopOpeBRepBuild/TopOpeBRepBuild_ShapeSet.hxx @@ -70,8 +70,7 @@ public: //! :check (or not) the shapes, startelements, elements added. Standard_EXPORT TopOpeBRepBuild_ShapeSet(const TopAbs_ShapeEnum SubShapeType, const Standard_Boolean checkshape = Standard_True); - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~TopOpeBRepBuild_ShapeSet(){Delete() ; } + Standard_EXPORT virtual ~TopOpeBRepBuild_ShapeSet(); //! Adds to the list of shapes. (wires or shells). Standard_EXPORT virtual void AddShape (const TopoDS_Shape& S); diff --git a/src/TopOpeBRepTool/TopOpeBRepTool_BoxSort.cxx b/src/TopOpeBRepTool/TopOpeBRepTool_BoxSort.cxx index fbd65e2b63..9e35698cb9 100644 --- a/src/TopOpeBRepTool/TopOpeBRepTool_BoxSort.cxx +++ b/src/TopOpeBRepTool/TopOpeBRepTool_BoxSort.cxx @@ -60,10 +60,10 @@ TopOpeBRepTool_BoxSort::TopOpeBRepTool_BoxSort(const MTOhbt& HBT) //modified by NIZNHY-PKV Mon Dec 16 10:26:00 2002 f //======================================================================= -//function : Destroy -//purpose : alias ~TopOpeBRepTool_BoxSort +//function : ~TopOpeBRepTool_BoxSort +//purpose : //======================================================================= -void TopOpeBRepTool_BoxSort::Destroy() +TopOpeBRepTool_BoxSort::~TopOpeBRepTool_BoxSort() { if (!myHBT.IsNull()) { myHBT->Clear(); diff --git a/src/TopOpeBRepTool/TopOpeBRepTool_BoxSort.hxx b/src/TopOpeBRepTool/TopOpeBRepTool_BoxSort.hxx index 08eb30507a..043cb7995a 100644 --- a/src/TopOpeBRepTool/TopOpeBRepTool_BoxSort.hxx +++ b/src/TopOpeBRepTool/TopOpeBRepTool_BoxSort.hxx @@ -72,17 +72,7 @@ public: Standard_EXPORT const Bnd_Box& Box (const TopoDS_Shape& S) const; - Standard_EXPORT void Destroy(); -Standard_EXPORT ~TopOpeBRepTool_BoxSort() {Destroy();} - - - - -protected: - - - - + Standard_EXPORT ~TopOpeBRepTool_BoxSort(); private: diff --git a/src/TopOpeBRepTool/TopOpeBRepTool_SolidClassifier.cxx b/src/TopOpeBRepTool/TopOpeBRepTool_SolidClassifier.cxx index 412b8aacf4..0ace45e00b 100644 --- a/src/TopOpeBRepTool/TopOpeBRepTool_SolidClassifier.cxx +++ b/src/TopOpeBRepTool/TopOpeBRepTool_SolidClassifier.cxx @@ -32,10 +32,10 @@ TopOpeBRepTool_SolidClassifier::TopOpeBRepTool_SolidClassifier() //modified by NIZNHY-PKV Mon Dec 16 10:39:00 2002 f //======================================================================= -//function : Destroy -//purpose : alias ~TopOpeBRepTool_SolidClassifier +//function : ~TopOpeBRepTool_SolidClassifier +//purpose : //======================================================================= -void TopOpeBRepTool_SolidClassifier::Destroy() +TopOpeBRepTool_SolidClassifier::~TopOpeBRepTool_SolidClassifier() { Standard_Integer i, aNb; diff --git a/src/TopOpeBRepTool/TopOpeBRepTool_SolidClassifier.hxx b/src/TopOpeBRepTool/TopOpeBRepTool_SolidClassifier.hxx index 85b58f6d14..cdf82a5b87 100644 --- a/src/TopOpeBRepTool/TopOpeBRepTool_SolidClassifier.hxx +++ b/src/TopOpeBRepTool/TopOpeBRepTool_SolidClassifier.hxx @@ -45,8 +45,7 @@ public: Standard_EXPORT void Clear(); - Standard_EXPORT void Destroy(); -Standard_EXPORT ~TopOpeBRepTool_SolidClassifier() {Destroy();} + Standard_EXPORT ~TopOpeBRepTool_SolidClassifier(); Standard_EXPORT void LoadSolid (const TopoDS_Solid& S); diff --git a/src/TopTools/TopTools_ShapeSet.cxx b/src/TopTools/TopTools_ShapeSet.cxx index 8c07693b3a..3e8bf4d7ca 100644 --- a/src/TopTools/TopTools_ShapeSet.cxx +++ b/src/TopTools/TopTools_ShapeSet.cxx @@ -44,7 +44,7 @@ TopTools_ShapeSet::TopTools_ShapeSet() : myFormatNb(1) { } -void TopTools_ShapeSet::Delete() +TopTools_ShapeSet::~TopTools_ShapeSet() {} //======================================================================= diff --git a/src/TopTools/TopTools_ShapeSet.hxx b/src/TopTools/TopTools_ShapeSet.hxx index 0a347618fd..fde517d6bc 100644 --- a/src/TopTools/TopTools_ShapeSet.hxx +++ b/src/TopTools/TopTools_ShapeSet.hxx @@ -48,8 +48,7 @@ public: //! Builds an empty ShapeSet. Standard_EXPORT TopTools_ShapeSet(); - Standard_EXPORT virtual void Delete(); -Standard_EXPORT virtual ~TopTools_ShapeSet(){Delete() ; } + Standard_EXPORT virtual ~TopTools_ShapeSet(); Standard_EXPORT void SetFormatNb (const Standard_Integer theFormatNb); diff --git a/src/TransferBRep/TransferBRep_Reader.cxx b/src/TransferBRep/TransferBRep_Reader.cxx index 97e4911371..f7c63fa0f6 100644 --- a/src/TransferBRep/TransferBRep_Reader.cxx +++ b/src/TransferBRep/TransferBRep_Reader.cxx @@ -252,5 +252,6 @@ TransferBRep_Reader::TransferBRep_Reader () () const { return theProc; } -void TransferBRep_Reader::Destroy() {} +TransferBRep_Reader::~TransferBRep_Reader() +{} diff --git a/src/TransferBRep/TransferBRep_Reader.hxx b/src/TransferBRep/TransferBRep_Reader.hxx index 1f930aebed..6cf937f0e3 100644 --- a/src/TransferBRep/TransferBRep_Reader.hxx +++ b/src/TransferBRep/TransferBRep_Reader.hxx @@ -182,11 +182,7 @@ public: //! Can be used for queries more accurate than the default ones. Standard_EXPORT Handle(Transfer_TransientProcess) TransientProcess() const; - Standard_EXPORT virtual void Destroy(); -Standard_EXPORT virtual ~TransferBRep_Reader() { Destroy(); } - - - + Standard_EXPORT virtual ~TransferBRep_Reader(); protected: diff --git a/src/Units/Units_ShiftedToken.cxx b/src/Units/Units_ShiftedToken.cxx index 146b301b9f..cef31550ed 100644 --- a/src/Units/Units_ShiftedToken.cxx +++ b/src/Units/Units_ShiftedToken.cxx @@ -91,7 +91,3 @@ void Units_ShiftedToken::Dump(const Standard_Integer ashift, for(int i=0; i=(const Handle(Units_Token)& atoken1,const Handle(Uni { return atoken1->IsGreaterOrEqual(atoken2); } - -void Units_Token::Destroy () { - -} diff --git a/src/Units/Units_Token.hxx b/src/Units/Units_Token.hxx index fe098e8d86..87ecd9ffb9 100644 --- a/src/Units/Units_Token.hxx +++ b/src/Units/Units_Token.hxx @@ -183,13 +183,6 @@ public: //! false otherwise. Standard_Boolean IsGreaterOrEqual (const Handle(Units_Token)& atoken) const; - //! Destroies the Token - Standard_EXPORT virtual void Destroy(); -~Units_Token() -{ - Destroy(); -} - //! Useful for debugging Standard_EXPORT virtual void Dump (const Standard_Integer ashift, const Standard_Integer alevel) const; diff --git a/src/WNT/WNT_WClass.cxx b/src/WNT/WNT_WClass.cxx index f28c6b2c02..014348b6f6 100644 --- a/src/WNT/WNT_WClass.cxx +++ b/src/WNT/WNT_WClass.cxx @@ -68,11 +68,11 @@ WNT_WClass::WNT_WClass ( } // end constructor //======================================================================= -//function : Destroy +//function : ~WNT_WClass //purpose : //======================================================================= -void WNT_WClass::Destroy () +WNT_WClass::~WNT_WClass () { UnregisterClass ( lpszName, ( HINSTANCE )hInstance ); diff --git a/src/WNT/WNT_WClass.hxx b/src/WNT/WNT_WClass.hxx index 78658d2357..6b28ffe293 100644 --- a/src/WNT/WNT_WClass.hxx +++ b/src/WNT/WNT_WClass.hxx @@ -62,11 +62,7 @@ public: Standard_EXPORT WNT_WClass(const Standard_CString aClassName, const Standard_Address aWndProc, const WNT_Uint& aStyle, const Standard_Integer aClassExtra = 0, const Standard_Integer aWindowExtra = 0, const Aspect_Handle aCursor = 0, const Aspect_Handle anIcon = 0, const Standard_CString aMenuName = 0); //! Destroys all resources attached to the class - Standard_EXPORT virtual void Destroy(); -~WNT_WClass() -{ - Destroy(); -} + Standard_EXPORT ~WNT_WClass(); //! Returns address of window procedure. Standard_Address WndProc() const; diff --git a/src/WNT/WNT_Window.cxx b/src/WNT/WNT_Window.cxx index 7f8b0767cc..b8d586fe2f 100644 --- a/src/WNT/WNT_Window.cxx +++ b/src/WNT/WNT_Window.cxx @@ -123,10 +123,10 @@ WNT_Window::WNT_Window (const Aspect_Handle theHandle, } // ======================================================================= -// function : Destroy +// function : ~WNT_Window // purpose : // ======================================================================= -void WNT_Window::Destroy() +WNT_Window::~WNT_Window() { if (myHWindow == NULL || myIsForeign) diff --git a/src/WNT/WNT_Window.hxx b/src/WNT/WNT_Window.hxx index 519263004d..b7b6f3c0f6 100644 --- a/src/WNT/WNT_Window.hxx +++ b/src/WNT/WNT_Window.hxx @@ -56,12 +56,8 @@ public: //! This handle equals ( aPart1 << 16 ) + aPart2. Standard_EXPORT WNT_Window(const Aspect_Handle aHandle, const Quantity_NameOfColor aBackColor = Quantity_NOC_MATRAGRAY); - //! Destroies the Window and all resourses attached to it. - Standard_EXPORT virtual void Destroy(); -~WNT_Window() -{ - Destroy(); -} + //! Destroys the Window and all resourses attached to it. + Standard_EXPORT ~WNT_Window(); //! Sets cursor for ENTIRE WINDOW CLASS to which //! the Window belongs. diff --git a/src/XCAFDoc/XCAFDoc_DocumentTool.cxx b/src/XCAFDoc/XCAFDoc_DocumentTool.cxx index e1ceaa23af..b00f02ebe8 100644 --- a/src/XCAFDoc/XCAFDoc_DocumentTool.cxx +++ b/src/XCAFDoc/XCAFDoc_DocumentTool.cxx @@ -313,13 +313,3 @@ Standard_Boolean XCAFDoc_DocumentTool::IsXCAFDocument(const Handle(TDocStd_Docu Handle(TDataStd_TreeNode) aRootNode; return RootL.FindAttribute (aRefGuid, aRootNode); } - - -//======================================================================= -//function : Destroy -//purpose : No longer required. Kept for binary compatibility only. -//======================================================================= - -void XCAFDoc_DocumentTool::Destroy() -{ -} diff --git a/src/XCAFDoc/XCAFDoc_DocumentTool.hxx b/src/XCAFDoc/XCAFDoc_DocumentTool.hxx index 38d4102104..e67d725a8d 100644 --- a/src/XCAFDoc/XCAFDoc_DocumentTool.hxx +++ b/src/XCAFDoc/XCAFDoc_DocumentTool.hxx @@ -104,17 +104,7 @@ public: Standard_EXPORT Handle(TDF_Attribute) NewEmpty() const Standard_OVERRIDE; Standard_EXPORT void Paste (const Handle(TDF_Attribute)& into, const Handle(TDF_RelocationTable)& RT) const Standard_OVERRIDE; - - //! Unregisters the document holding this attribute from an - //! internal global map of XDE documents. - Standard_EXPORT virtual void Destroy(); -~XCAFDoc_DocumentTool() -{ - Destroy(); -} - - - + DEFINE_STANDARD_RTTIEXT(XCAFDoc_DocumentTool,TDF_Attribute) protected: diff --git a/src/Xw/Xw_Window.cxx b/src/Xw/Xw_Window.cxx index 48e1965f90..cd4004dec4 100644 --- a/src/Xw/Xw_Window.cxx +++ b/src/Xw/Xw_Window.cxx @@ -229,10 +229,10 @@ Xw_Window::Xw_Window (const Handle(Aspect_DisplayConnection)& theXDisplay, } // ======================================================================= -// function : Destroy +// function : ~Xw_Window // purpose : // ======================================================================= -void Xw_Window::Destroy() +Xw_Window::~Xw_Window() { if (myIsOwnWin && myXWindow != 0 && !myDisplay.IsNull()) { diff --git a/src/Xw/Xw_Window.hxx b/src/Xw/Xw_Window.hxx index 693e8f93c9..bf1828189b 100644 --- a/src/Xw/Xw_Window.hxx +++ b/src/Xw/Xw_Window.hxx @@ -58,13 +58,8 @@ public: const Window theXWin, const Aspect_FBConfig theFBConfig = NULL); - //! Destroies the Window and all resourses attached to it - Standard_EXPORT virtual void Destroy() Standard_OVERRIDE; - - ~Xw_Window() - { - Destroy(); - } + //! Destroys the Window and all resourses attached to it + Standard_EXPORT ~Xw_Window(); //! Opens the window Standard_EXPORT virtual void Map() const Standard_OVERRIDE; diff --git a/src/math/math_BissecNewton.hxx b/src/math/math_BissecNewton.hxx index 43b5f5a9e0..9da3447717 100644 --- a/src/math/math_BissecNewton.hxx +++ b/src/math/math_BissecNewton.hxx @@ -82,8 +82,7 @@ public: //! Is used to redifine the operator <<. Standard_EXPORT void Dump (Standard_OStream& o) const; - //! Destructor alias. - void Delete() const; + //! Destructor Standard_EXPORT virtual ~math_BissecNewton(); diff --git a/src/math/math_BissecNewton.lxx b/src/math/math_BissecNewton.lxx index 06815b1cfc..bb1739283e 100644 --- a/src/math/math_BissecNewton.lxx +++ b/src/math/math_BissecNewton.lxx @@ -14,10 +14,6 @@ #include -inline void math_BissecNewton::Delete() const -{ -} - inline Standard_Boolean math_BissecNewton::IsSolutionReached(math_FunctionWithDerivative&) { return Abs(dx) <= XTol; diff --git a/src/math/math_BrentMinimum.hxx b/src/math/math_BrentMinimum.hxx index 46c4a0ee16..057e8ab8b7 100644 --- a/src/math/math_BrentMinimum.hxx +++ b/src/math/math_BrentMinimum.hxx @@ -51,8 +51,7 @@ public: //! It has to be used if F(Bx) is known. Standard_EXPORT math_BrentMinimum(const Standard_Real TolX, const Standard_Real Fbx, const Standard_Integer NbIterations = 100, const Standard_Real ZEPS = 1.0e-12); - //! Destructor alias. - void Delete() const; + //! Destructor Standard_EXPORT virtual ~math_BrentMinimum(); diff --git a/src/math/math_BrentMinimum.lxx b/src/math/math_BrentMinimum.lxx index 948890225a..9f5fd8cf69 100644 --- a/src/math/math_BrentMinimum.lxx +++ b/src/math/math_BrentMinimum.lxx @@ -14,11 +14,6 @@ #include -inline void math_BrentMinimum::Delete() const -{ -} - - inline Standard_Boolean math_BrentMinimum::IsSolutionReached(math_Function&) { const Standard_Real TwoTol = 2.0 * (XTol * fabs(x) + EPSZ); diff --git a/src/math/math_FRPR.hxx b/src/math/math_FRPR.hxx index 8995143213..3730ebe4fc 100644 --- a/src/math/math_FRPR.hxx +++ b/src/math/math_FRPR.hxx @@ -48,8 +48,7 @@ public: //! Warning: constructor does not perform computations. Standard_EXPORT math_FRPR(const math_MultipleVarFunctionWithGradient& theFunction, const Standard_Real theTolerance, const Standard_Integer theNbIterations = 200, const Standard_Real theZEPS = 1.0e-12); - //! Destructor alias. - Standard_EXPORT void Delete() const; + //! Destructor Standard_EXPORT virtual ~math_FRPR(); diff --git a/src/math/math_FRPR.lxx b/src/math/math_FRPR.lxx index aa0a9e670f..29b358049f 100644 --- a/src/math/math_FRPR.lxx +++ b/src/math/math_FRPR.lxx @@ -15,10 +15,6 @@ #include #include -inline void math_FRPR::Delete() const -{ -} - inline Standard_Boolean math_FRPR::IsSolutionReached(math_MultipleVarFunctionWithGradient&) { return 2.0 * fabs(TheMinimum - PreviousMinimum) <= diff --git a/src/math/math_FunctionSetRoot.cxx b/src/math/math_FunctionSetRoot.cxx index 59485ec69c..aa41d3dadb 100644 --- a/src/math/math_FunctionSetRoot.cxx +++ b/src/math/math_FunctionSetRoot.cxx @@ -666,7 +666,6 @@ math_FunctionSetRoot::math_FunctionSetRoot(math_FunctionSetWithDerivatives& theF //======================================================================= math_FunctionSetRoot::~math_FunctionSetRoot() { - Delete(); } //======================================================================= diff --git a/src/math/math_FunctionSetRoot.hxx b/src/math/math_FunctionSetRoot.hxx index 3a738404f4..6236308452 100644 --- a/src/math/math_FunctionSetRoot.hxx +++ b/src/math/math_FunctionSetRoot.hxx @@ -61,8 +61,7 @@ public: //! constructor. Standard_EXPORT math_FunctionSetRoot(math_FunctionSetWithDerivatives& F, const Standard_Integer NbIterations = 100); - //! Destructor alias. - Standard_EXPORT void Delete() const; + //! Destructor Standard_EXPORT virtual ~math_FunctionSetRoot(); //! Initializes the tolerance values. diff --git a/src/math/math_FunctionSetRoot.lxx b/src/math/math_FunctionSetRoot.lxx index 50937dba46..24b1bad422 100644 --- a/src/math/math_FunctionSetRoot.lxx +++ b/src/math/math_FunctionSetRoot.lxx @@ -15,11 +15,6 @@ #include #include -inline void math_FunctionSetRoot::Delete() const -{ -} - - inline Standard_Boolean math_FunctionSetRoot::IsSolutionReached(math_FunctionSetWithDerivatives&) { for (Standard_Integer i = 1; i <= Sol.Length(); ++i) diff --git a/src/math/math_NewtonFunctionSetRoot.hxx b/src/math/math_NewtonFunctionSetRoot.hxx index dc13d7b1fb..026663161c 100644 --- a/src/math/math_NewtonFunctionSetRoot.hxx +++ b/src/math/math_NewtonFunctionSetRoot.hxx @@ -60,8 +60,7 @@ public: //! The method SetTolerance must be called before performing the algorithm. Standard_EXPORT math_NewtonFunctionSetRoot(math_FunctionSetWithDerivatives& theFunction, const Standard_Real theFTolerance, const Standard_Integer theNbIterations = 100); - //! Destructor alias. - Standard_EXPORT void Delete() const; + //! Destructor Standard_EXPORT virtual ~math_NewtonFunctionSetRoot(); //! Initializes the tolerance values for the unknowns. diff --git a/src/math/math_NewtonFunctionSetRoot.lxx b/src/math/math_NewtonFunctionSetRoot.lxx index c318555dd5..635c164754 100644 --- a/src/math/math_NewtonFunctionSetRoot.lxx +++ b/src/math/math_NewtonFunctionSetRoot.lxx @@ -14,10 +14,6 @@ #include -inline void math_NewtonFunctionSetRoot::Delete() const -{ -} - inline Standard_Boolean math_NewtonFunctionSetRoot::IsSolutionReached(math_FunctionSetWithDerivatives&) { for (Standard_Integer i = DeltaX.Lower(); i <= DeltaX.Upper(); ++i) diff --git a/src/math/math_NewtonMinimum.hxx b/src/math/math_NewtonMinimum.hxx index 41a464e2f1..7de5f81d83 100644 --- a/src/math/math_NewtonMinimum.hxx +++ b/src/math/math_NewtonMinimum.hxx @@ -52,8 +52,7 @@ public: //! Search the solution. Standard_EXPORT void Perform (math_MultipleVarFunctionWithHessian& theFunction, const math_Vector& theStartingPoint); - //! Destructor alias. - void Delete() const; + //! Destructor Standard_EXPORT virtual ~math_NewtonMinimum(); diff --git a/src/math/math_NewtonMinimum.lxx b/src/math/math_NewtonMinimum.lxx index 688945b7cc..2d6852b97f 100644 --- a/src/math/math_NewtonMinimum.lxx +++ b/src/math/math_NewtonMinimum.lxx @@ -16,10 +16,6 @@ #include -inline void math_NewtonMinimum::Delete() const -{ -} - inline Standard_Boolean math_NewtonMinimum::IsConverged() const { return ( (TheStep.Norm() <= XTol ) || diff --git a/src/math/math_Powell.hxx b/src/math/math_Powell.hxx index d07c2f3b18..080cc2d2aa 100644 --- a/src/math/math_Powell.hxx +++ b/src/math/math_Powell.hxx @@ -47,8 +47,7 @@ public: //! Constructor. Initialize new entity. Standard_EXPORT math_Powell(const math_MultipleVarFunction& theFunction, const Standard_Real theTolerance, const Standard_Integer theNbIterations = 200, const Standard_Real theZEPS = 1.0e-12); - //! Destructor alias - void Delete() const; + //! Destructor Standard_EXPORT virtual ~math_Powell(); diff --git a/src/math/math_Powell.lxx b/src/math/math_Powell.lxx index 5d7cdc477e..56aa6c6be8 100644 --- a/src/math/math_Powell.lxx +++ b/src/math/math_Powell.lxx @@ -15,10 +15,6 @@ #include #include -inline void math_Powell::Delete() const -{ -} - inline Standard_Boolean math_Powell::IsSolutionReached(math_MultipleVarFunction&) { return 2.0 * fabs(PreviousMinimum - TheMinimum) <= -- 2.20.1