-// Copyright (C) 2007-2015 CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2023 CEA, EDF, OPEN CASCADE
//
// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
#include <GEOM_Solver.hxx>
#include <GEOM_ISubShape.hxx>
-#include <Basics_OCCTVersion.hxx>
-
#include "utilities.h"
#include <TDF.hxx>
#include <TColStd_ListOfInteger.hxx>
#include <TColStd_ListIteratorOfListOfInteger.hxx>
-#include <TColStd_HArray1OfReal.hxx>
-#include <TColStd_HArray1OfInteger.hxx>
-#include <TColStd_HSequenceOfTransient.hxx>
-#include <TCollection_AsciiString.hxx>
#include <TCollection_ExtendedString.hxx>
#include <cstdlib>
//================================================================================
/*!
- * \brief Retuns true if this function is the last one in the study
+ * \brief Returns true if this function is the last one in the study
*/
//================================================================================
return aShape;
}
}
- catch (Standard_Failure) {
- Handle(Standard_Failure) aFail = Standard_Failure::Caught();
- MESSAGE("GEOM_Function::GetValue Error: " << aFail->GetMessageString());
+ catch (Standard_Failure& aFail) {
+ MESSAGE("GEOM_Function::GetValue Error: " << aFail.GetMessageString());
return aShape;
}
}
TDF_Label aSubShapesLabel = _label.FindChild(SUBSHAPES_LABEL);
- Handle(TDataStd_ExtStringList) aList;
- if (!aSubShapesLabel.FindAttribute(TDataStd_ExtStringList::GetID(), aList)) {
- aList = new TDataStd_ExtStringList;
- aSubShapesLabel.AddAttribute(aList);
- }
-
+ Handle(TDataStd_ExtStringList) aList = TDataStd_ExtStringList::Set( aSubShapesLabel );
TCollection_AsciiString anEntry;
TDF_Tool::Entry(theSubShape->GetOwnerEntry(), anEntry);
aList->Append(anEntry);
TDF_Label aSubShapesLabel = _label.FindChild(SUBSHAPES_LABEL);
- Handle(TDataStd_ExtStringList) aList;
- if (!aSubShapesLabel.FindAttribute(TDataStd_ExtStringList::GetID(), aList)) {
- aList = new TDataStd_ExtStringList;
- aSubShapesLabel.AddAttribute(aList);
- }
+ Handle(TDataStd_ExtStringList) aList = TDataStd_ExtStringList::Set( aSubShapesLabel );
_isDone = true;
return aList->List();
return reinterpret_cast<void*> ( address );
}
-IMPLEMENT_STANDARD_HANDLE (GEOM_Function, Standard_Transient);
-IMPLEMENT_STANDARD_RTTIEXT(GEOM_Function, Standard_Transient );
+IMPLEMENT_STANDARD_RTTIEXT(GEOM_Function, Standard_Transient )