0026937: Eliminate NO_CXX_EXCEPTION macro support
authorski <ski@opencascade.com>
Thu, 2 Feb 2017 13:35:21 +0000 (16:35 +0300)
committerapn <apn@opencascade.com>
Thu, 2 Feb 2017 13:35:54 +0000 (16:35 +0300)
Macro NO_CXX_EXCEPTION was removed from code.
Method Raise() was replaced by explicit throw statement.
Method Standard_Failure::Caught() was replaced by normal C++mechanism of exception transfer.
Method Standard_Failure::Caught() is deprecated now.
Eliminated empty constructors.
Updated samples.
Eliminate empty method ChangeValue from NCollection_Map class.
Removed not operable methods from NCollection classes.

1146 files changed:
dox/user_guides/foundation_classes/foundation_classes.md
samples/mfc/standard/01_Geometry/src/GeometryView2D.cpp
samples/mfc/standard/02_Modeling/src/ModelingDoc.cpp
samples/mfc/standard/04_Viewer3d/src/Viewer3dDoc.cpp
samples/mfc/standard/06_Ocaf/src/TOcafFunction_CutDriver.cxx
samples/mfc/standard/07_Triangulation/src/TriangulationDoc.cpp
samples/mfc/standard/08_HLR/src/HLRView2D.cpp
samples/mfc/standard/08_HLR/src/HLRView3D.cpp
samples/mfc/standard/09_Animation/src/AnimationView3D.cpp
samples/mfc/standard/10_Convert/src/WNT/OCCDemoDoc.cpp
samples/mfc/standard/Common/OCC_2dView.cpp
samples/mfc/standard/Common/OCC_2dViewRD.cpp
samples/mfc/standard/Common/OCC_3dView.cpp
samples/mfc/standard/Common/Winmain.cpp
samples/qt/Common/src/View.cxx
src/AIS/AIS_AngleDimension.cxx
src/AIS/AIS_Animation.cxx
src/AIS/AIS_Axis.cxx
src/AIS/AIS_Chamf2dDimension.cxx
src/AIS/AIS_Chamf3dDimension.cxx
src/AIS/AIS_Circle.cxx
src/AIS/AIS_ConcentricRelation.cxx
src/AIS/AIS_ConnectedInteractive.cxx
src/AIS/AIS_Dimension.cxx
src/AIS/AIS_EllipseRadiusDimension.cxx
src/AIS/AIS_EqualDistanceRelation.cxx
src/AIS/AIS_EqualRadiusRelation.cxx
src/AIS/AIS_FixRelation.cxx
src/AIS/AIS_IdenticRelation.cxx
src/AIS/AIS_InteractiveContext.cxx
src/AIS/AIS_InteractiveContext.hxx
src/AIS/AIS_Line.cxx
src/AIS/AIS_MaxRadiusDimension.cxx
src/AIS/AIS_MidPointRelation.cxx
src/AIS/AIS_MinRadiusDimension.cxx
src/AIS/AIS_OffsetDimension.cxx
src/AIS/AIS_ParallelRelation.cxx
src/AIS/AIS_PerpendicularRelation.cxx
src/AIS/AIS_PlaneTrihedron.cxx
src/AIS/AIS_Point.cxx
src/AIS/AIS_SymmetricRelation.cxx
src/AIS/AIS_TangentRelation.cxx
src/AIS/AIS_Trihedron.cxx
src/Adaptor2d/Adaptor2d_Curve2d.cxx
src/Adaptor2d/Adaptor2d_Line2d.cxx
src/Adaptor2d/Adaptor2d_OffsetCurve.cxx
src/Adaptor3d/Adaptor3d_Curve.cxx
src/Adaptor3d/Adaptor3d_CurveOnSurface.cxx
src/Adaptor3d/Adaptor3d_InterFunc.cxx
src/Adaptor3d/Adaptor3d_IsoCurve.cxx
src/Adaptor3d/Adaptor3d_Surface.cxx
src/Adaptor3d/Adaptor3d_TopolTool.cxx
src/AdvApp2Var/AdvApp2Var_ApproxAFunc2Var.cxx
src/AdvApp2Var/AdvApp2Var_Context.cxx
src/AdvApp2Var/AdvApp2Var_Patch.cxx
src/AdvApprox/AdvApprox_ApproxAFunction.cxx
src/AdvApprox/AdvApprox_ApproxAFunction.lxx
src/AdvApprox/AdvApprox_PrefAndRec.cxx
src/AdvApprox/AdvApprox_SimpleApprox.cxx
src/AppBlend/AppBlend_AppSurf.gxx
src/AppBlend/AppBlend_AppSurf.lxx
src/AppCont/AppCont_ContMatrices.cxx
src/AppCont/AppCont_ContMatrices_1.cxx
src/AppCont/AppCont_ContMatrices_2.cxx
src/AppCont/AppCont_ContMatrices_3.cxx
src/AppCont/AppCont_ContMatrices_4.cxx
src/AppDef/AppDef_LinearCriteria.cxx
src/AppDef/AppDef_MultiLine.cxx
src/AppDef/AppDef_MultiPointConstraint.cxx
src/AppDef/AppDef_Variational.cxx
src/AppParCurves/AppParCurves_LeastSquare.gxx
src/AppParCurves/AppParCurves_MultiBSpCurve.cxx
src/AppParCurves/AppParCurves_MultiCurve.cxx
src/AppParCurves/AppParCurves_MultiPoint.cxx
src/AppParCurves/AppParCurves_MultiPoint.lxx
src/Approx/Approx_CurveOnSurface.cxx
src/Approx/Approx_CurvlinFunc.cxx
src/Approx/Approx_SameParameter.cxx
src/Approx/Approx_SweepApproximation.cxx
src/Approx/Approx_SweepApproximation.lxx
src/Approx/Approx_SweepFunction.cxx
src/Aspect/Aspect_AspectFillAreaDefinitionError.hxx
src/Aspect/Aspect_AspectLineDefinitionError.hxx
src/Aspect/Aspect_AspectMarkerDefinitionError.hxx
src/Aspect/Aspect_BadAccess.hxx
src/Aspect/Aspect_DisplayConnection.cxx
src/Aspect/Aspect_DisplayConnectionDefinitionError.hxx
src/Aspect/Aspect_DriverDefinitionError.hxx
src/Aspect/Aspect_GenId.cxx
src/Aspect/Aspect_GraphicDeviceDefinitionError.hxx
src/Aspect/Aspect_IdentDefinitionError.hxx
src/Aspect/Aspect_WindowDefinitionError.hxx
src/Aspect/Aspect_WindowError.hxx
src/BOPAlgo/BOPAlgo_Algo.cxx
src/BOPTools/BOPTools_AlgoTools2D.cxx
src/BRep/BRep_Builder.cxx
src/BRep/BRep_CurveOn2Surfaces.cxx
src/BRep/BRep_CurveRepresentation.cxx
src/BRep/BRep_PointRepresentation.cxx
src/BRep/BRep_Tool.cxx
src/BRepAdaptor/BRepAdaptor_Curve.cxx
src/BRepAlgo/BRepAlgo_AsDes.cxx
src/BRepAlgo/BRepAlgo_Image.cxx
src/BRepAlgoAPI/BRepAlgoAPI_Algo.cxx
src/BRepApprox/BRepApprox_TheFunctionOfTheInt2SOfThePrmPrmSvSurfacesOfApprox.hxx
src/BRepApprox/BRepApprox_TheInt2SOfThePrmPrmSvSurfacesOfApprox.hxx
src/BRepBlend/BRepBlend_Extremity.lxx
src/BRepBlend/BRepBlend_Line.lxx
src/BRepBlend/BRepBlend_RstRstConstRad.cxx
src/BRepBlend/BRepBlend_RstRstEvolRad.cxx
src/BRepBlend/BRepBlend_RstRstLineBuilder.cxx
src/BRepBlend/BRepBlend_RstRstLineBuilder.lxx
src/BRepBlend/BRepBlend_SurfRstConstRad.cxx
src/BRepBlend/BRepBlend_SurfRstEvolRad.cxx
src/BRepBlend/BRepBlend_SurfRstLineBuilder.cxx
src/BRepBlend/BRepBlend_SurfRstLineBuilder.lxx
src/BRepBuilderAPI/BRepBuilderAPI_Command.cxx
src/BRepBuilderAPI/BRepBuilderAPI_FastSewing.cxx
src/BRepBuilderAPI/BRepBuilderAPI_ModifyShape.cxx
src/BRepBuilderAPI/BRepBuilderAPI_Sewing.cxx
src/BRepCheck/BRepCheck_Analyzer.cxx
src/BRepClass3d/BRepClass3d_SolidExplorer.cxx
src/BRepClass3d/BRepClass3d_SolidExplorer.hxx
src/BRepExtrema/BRepExtrema_DistShapeShape.cxx
src/BRepExtrema/BRepExtrema_UnCompatibleShape.hxx
src/BRepFeat/BRepFeat_MakeCylindricalHole.cxx
src/BRepFeat/BRepFeat_MakeDPrism.cxx
src/BRepFeat/BRepFeat_MakeLinearForm.cxx
src/BRepFeat/BRepFeat_MakePipe.cxx
src/BRepFeat/BRepFeat_MakePrism.cxx
src/BRepFeat/BRepFeat_MakeRevol.cxx
src/BRepFeat/BRepFeat_MakeRevolutionForm.cxx
src/BRepFill/BRepFill.cxx
src/BRepFill/BRepFill_CompatibleWires.cxx
src/BRepFill/BRepFill_CurveConstraint.cxx
src/BRepFill/BRepFill_Draft.cxx
src/BRepFill/BRepFill_Evolved.cxx
src/BRepFill/BRepFill_Filling.cxx
src/BRepFill/BRepFill_Generator.cxx
src/BRepFill/BRepFill_MultiLine.cxx
src/BRepFill/BRepFill_OffsetWire.cxx
src/BRepFill/BRepFill_Pipe.cxx
src/BRepFill/BRepFill_PipeShell.cxx
src/BRepFill/BRepFill_Section.cxx
src/BRepFill/BRepFill_SectionPlacement.cxx
src/BRepFill/BRepFill_Sweep.cxx
src/BRepFill/BRepFill_TrimEdgeTool.cxx
src/BRepFill/BRepFill_TrimSurfaceTool.cxx
src/BRepIntCurveSurface/BRepIntCurveSurface_Inter.cxx
src/BRepLProp/BRepLProp.cxx
src/BRepLib/BRepLib.cxx
src/BRepLib/BRepLib_Command.cxx
src/BRepLib/BRepLib_FuseEdges.cxx
src/BRepMAT2d/BRepMAT2d_LinkTopoBilo.cxx
src/BRepMesh/BRepMesh_DataStructureOfDelaun.cxx
src/BRepMesh/BRepMesh_Delaun.cxx
src/BRepMesh/BRepMesh_PairOfIndex.hxx
src/BRepOffset/BRepOffset_MakeOffset.cxx
src/BRepOffset/BRepOffset_Offset.cxx
src/BRepOffset/BRepOffset_Tool.cxx
src/BRepOffsetAPI/BRepOffsetAPI_MakeOffset.cxx
src/BRepOffsetAPI/BRepOffsetAPI_MakePipeShell.cxx
src/BRepOffsetAPI/BRepOffsetAPI_ThruSections.cxx
src/BRepPrim/BRepPrim_Cone.cxx
src/BRepPrim/BRepPrim_FaceBuilder.cxx
src/BRepPrim/BRepPrim_GWedge.cxx
src/BRepPrim/BRepPrim_OneAxis.cxx
src/BRepProj/BRepProj_Projection.cxx
src/BRepSweep/BRepSweep_NumLinearRegularSweep.cxx
src/BRepSweep/BRepSweep_Rotation.cxx
src/BRepTest/BRepTest_BasicCommands.cxx
src/BRepTest/BRepTest_CheckCommands.cxx
src/BRepTest/BRepTest_FillingCommands.cxx
src/BRepTools/BRepTools_Debug.cxx
src/BRepTools/BRepTools_GTrsfModification.cxx
src/BRepTools/BRepTools_Modifier.cxx
src/BRepTools/BRepTools_Modifier.lxx
src/BRepTools/BRepTools_TrsfModification.cxx
src/BRepTools/BRepTools_WireExplorer.cxx
src/BRepTopAdaptor/BRepTopAdaptor_FClass2d.cxx
src/BRepTopAdaptor/BRepTopAdaptor_TopolTool.cxx
src/BSplCLib/BSplCLib.cxx
src/BSplCLib/BSplCLib_2.cxx
src/BSplCLib/BSplCLib_CurveComputation.gxx
src/BSplSLib/BSplSLib.cxx
src/BiTgte/BiTgte_Blend.cxx
src/BiTgte/BiTgte_CurveOnEdge.cxx
src/BiTgte/BiTgte_CurveOnVertex.cxx
src/BinDrivers/BinDrivers.cxx
src/BinDrivers/BinDrivers_DocumentRetrievalDriver.cxx
src/BinDrivers/BinDrivers_DocumentStorageDriver.cxx
src/BinLDrivers/BinLDrivers.cxx
src/BinMDF/BinMDF_ADriverTable.cxx
src/BinMNaming/BinMNaming_NamedShapeDriver.cxx
src/BinMNaming/BinMNaming_NamingDriver.cxx
src/BinTools/BinTools.cxx
src/BinTools/BinTools_Curve2dSet.cxx
src/BinTools/BinTools_CurveSet.cxx
src/BinTools/BinTools_LocationSet.cxx
src/BinTools/BinTools_ShapeSet.cxx
src/BinTools/BinTools_SurfaceSet.cxx
src/BinXCAFDrivers/BinXCAFDrivers.cxx
src/Bisector/Bisector_BisecAna.cxx
src/Bisector/Bisector_BisecCC.cxx
src/Bisector/Bisector_BisecPC.cxx
src/Blend/Blend_CSFunction.cxx
src/Blend/Blend_CSWalking.lxx
src/Blend/Blend_CSWalking_1.gxx
src/Blend/Blend_Point.lxx
src/Blend/Blend_RstRstFunction.cxx
src/Blend/Blend_SurfRstFunction.cxx
src/Blend/Blend_Walking.lxx
src/Blend/Blend_Walking_1.gxx
src/BlendFunc/BlendFunc_CSCircular.cxx
src/BlendFunc/BlendFunc_CSConstRad.cxx
src/BlendFunc/BlendFunc_ChAsym.cxx
src/BlendFunc/BlendFunc_Chamfer.cxx
src/BlendFunc/BlendFunc_ConstRad.cxx
src/BlendFunc/BlendFunc_Corde.cxx
src/BlendFunc/BlendFunc_EvolRad.cxx
src/BlendFunc/BlendFunc_Ruled.cxx
src/Bnd/Bnd_Box.cxx
src/Bnd/Bnd_Box2d.cxx
src/Bnd/Bnd_Range.hxx
src/BndLib/BndLib.cxx
src/CDF/CDF_Application.cxx
src/CDF/CDF_FWOSDriver.cxx
src/CDF/CDF_MetaDataDriverError.hxx
src/CDF/CDF_StoreList.cxx
src/CDM/CDM_Document.cxx
src/CPnts/CPnts_AbscissaPoint.cxx
src/CSLib/CSLib_Class2d.cxx
src/ChFi2d/ChFi2d_AnaFilletAlgo.cxx
src/ChFi2d/ChFi2d_FilletAlgo.cxx
src/ChFi3d/ChFi3d_Builder.cxx
src/ChFi3d/ChFi3d_Builder_0.cxx
src/ChFi3d/ChFi3d_Builder_1.cxx
src/ChFi3d/ChFi3d_Builder_2.cxx
src/ChFi3d/ChFi3d_Builder_C1.cxx
src/ChFi3d/ChFi3d_Builder_CnCrn.cxx
src/ChFi3d/ChFi3d_Builder_NotImp.cxx
src/ChFi3d/ChFi3d_ChBuilder.cxx
src/ChFi3d/ChFi3d_ChBuilder_C3.cxx
src/ChFi3d/ChFi3d_FilBuilder.cxx
src/ChFi3d/ChFi3d_FilBuilder_C2.cxx
src/ChFiDS/ChFiDS_ChamfSpine.cxx
src/ChFiDS/ChFiDS_CommonPoint.cxx
src/ChFiDS/ChFiDS_CommonPoint.lxx
src/ChFiDS/ChFiDS_ElSpine.cxx
src/ChFiDS/ChFiDS_FilSpine.cxx
src/ChFiDS/ChFiDS_Spine.cxx
src/ChFiDS/ChFiDS_SurfData.lxx
src/ChFiKPart/ChFiKPart_ComputeData.cxx
src/ChFiKPart/ChFiKPart_ComputeData_Fcts.cxx
src/Cocoa/Cocoa_Window.mm
src/Contap/Contap_ContAna.cxx
src/Contap/Contap_ContAna.lxx
src/Contap/Contap_Contour.cxx
src/Contap/Contap_Contour.lxx
src/Contap/Contap_HContTool.cxx
src/Contap/Contap_Line.cxx
src/Contap/Contap_Line.lxx
src/Contap/Contap_Point.lxx
src/Contap/Contap_SurfFunction.lxx
src/Convert/Convert_CircleToBSplineCurve.cxx
src/Convert/Convert_CompPolynomialToPoles.cxx
src/Convert/Convert_ConicToBSplineCurve.cxx
src/Convert/Convert_GridPolynomialToPoles.cxx
src/Convert/Convert_PolynomialCosAndSin.cxx
src/DBRep/DBRep_Debug.cxx
src/DDF/DDF_IOStream.cxx
src/DDocStd/DDocStd_ToolsCommands.cxx
src/DNaming/DNaming_ModelingCommands.cxx
src/DNaming/DNaming_TransformationDriver.cxx
src/Draft/Draft.cxx
src/Draft/Draft_Modification.cxx
src/Draft/Draft_Modification_1.cxx
src/Draft/Draft_VertexInfo.cxx
src/Draw/Draw.cxx
src/Draw/Draw_Debug.cxx
src/Draw/Draw_Failure.hxx
src/Draw/Draw_Interpretor.cxx
src/DrawDim/DrawDim.cxx
src/DrawDim/DrawDim_Dimension.cxx
src/DrawTrSurf/DrawTrSurf_Debug.cxx
src/Expr/Expr_BinaryExpression.cxx
src/Expr/Expr_BinaryFunction.cxx
src/Expr/Expr_Difference.cxx
src/Expr/Expr_ExprFailure.hxx
src/Expr/Expr_FunctionDerivative.cxx
src/Expr/Expr_GeneralExpression.cxx
src/Expr/Expr_InvalidAssignment.hxx
src/Expr/Expr_InvalidFunction.hxx
src/Expr/Expr_InvalidOperand.hxx
src/Expr/Expr_NamedConstant.cxx
src/Expr/Expr_NamedFunction.cxx
src/Expr/Expr_NamedUnknown.cxx
src/Expr/Expr_NotAssigned.hxx
src/Expr/Expr_NotEvaluable.hxx
src/Expr/Expr_NumericValue.cxx
src/Expr/Expr_PolyExpression.cxx
src/Expr/Expr_RUIterator.cxx
src/Expr/Expr_RelationIterator.cxx
src/Expr/Expr_SingleRelation.cxx
src/Expr/Expr_Sum.cxx
src/Expr/Expr_SystemRelation.cxx
src/Expr/Expr_UnaryExpression.cxx
src/Expr/Expr_UnaryFunction.cxx
src/Expr/Expr_UnaryMinus.cxx
src/Expr/Expr_UnknownIterator.cxx
src/ExprIntrp/ExprIntrp_GenExp.cxx
src/ExprIntrp/ExprIntrp_GenRel.cxx
src/ExprIntrp/ExprIntrp_SyntaxError.hxx
src/ExprIntrp/ExprIntrp_yaccintrf.cxx
src/Extrema/Extrema_CurveLocator.gxx
src/Extrema/Extrema_ExtCC.cxx
src/Extrema/Extrema_ExtCC2d.cxx
src/Extrema/Extrema_ExtCS.cxx
src/Extrema/Extrema_ExtElC.cxx
src/Extrema/Extrema_ExtElC.hxx
src/Extrema/Extrema_ExtElC2d.cxx
src/Extrema/Extrema_ExtElC2d.hxx
src/Extrema/Extrema_ExtElCS.cxx
src/Extrema/Extrema_ExtElSS.cxx
src/Extrema/Extrema_ExtPElC.cxx
src/Extrema/Extrema_ExtPElC2d.cxx
src/Extrema/Extrema_ExtPElS.cxx
src/Extrema/Extrema_ExtPExtS.cxx
src/Extrema/Extrema_ExtPRevS.cxx
src/Extrema/Extrema_ExtPS.cxx
src/Extrema/Extrema_ExtSS.cxx
src/Extrema/Extrema_FuncExtCS.cxx
src/Extrema/Extrema_FuncExtPC.gxx
src/Extrema/Extrema_FuncExtSS.cxx
src/Extrema/Extrema_FuncPSNorm.cxx
src/Extrema/Extrema_GExtPC.gxx
src/Extrema/Extrema_GLocateExtPC.gxx
src/Extrema/Extrema_GenExtCS.cxx
src/Extrema/Extrema_GenExtPC.gxx
src/Extrema/Extrema_GenExtPS.cxx
src/Extrema/Extrema_GenExtSS.cxx
src/Extrema/Extrema_GenLocateExtCC.gxx
src/Extrema/Extrema_GenLocateExtCS.cxx
src/Extrema/Extrema_GenLocateExtPC.gxx
src/Extrema/Extrema_GenLocateExtPS.cxx
src/Extrema/Extrema_GenLocateExtSS.cxx
src/Extrema/Extrema_LocateExtCC.cxx
src/Extrema/Extrema_LocateExtCC2d.cxx
src/FEmTool/FEmTool_Assembly.cxx
src/FEmTool/FEmTool_Curve.cxx
src/FEmTool/FEmTool_ElementsOfRefMatrix.cxx
src/FEmTool/FEmTool_LinearFlexion.cxx
src/FEmTool/FEmTool_LinearJerk.cxx
src/FEmTool/FEmTool_LinearTension.cxx
src/FEmTool/FEmTool_ProfileMatrix.cxx
src/FSD/FSD_BinaryFile.cxx
src/FSD/FSD_CmpFile.cxx
src/FSD/FSD_File.cxx
src/FairCurve/FairCurve_Batten.cxx
src/FairCurve/FairCurve_Batten.lxx
src/FilletSurf/FilletSurf_Builder.cxx
src/FilletSurf/FilletSurf_InternalBuilder.cxx
src/GC/GC_MakeConicalSurface.cxx
src/GC/GC_MakeConicalSurface.hxx
src/GC/GC_MakePlane.cxx
src/GC/GC_MakePlane.hxx
src/GC/GC_MakeTrimmedCylinder.cxx
src/GC/GC_MakeTrimmedCylinder.hxx
src/GCPnts/GCPnts_AbscissaPoint.pxx
src/GProp/GProp_GProps.cxx
src/GProp/GProp_PEquation.cxx
src/GProp/GProp_PGProps.cxx
src/GProp/GProp_UndefinedAxis.hxx
src/GccAna/GccAna_Circ2d2TanOn.cxx
src/GccAna/GccAna_Circ2d2TanOn_1.cxx
src/GccAna/GccAna_Circ2d2TanOn_10.cxx
src/GccAna/GccAna_Circ2d2TanOn_2.cxx
src/GccAna/GccAna_Circ2d2TanOn_3.cxx
src/GccAna/GccAna_Circ2d2TanOn_4.cxx
src/GccAna/GccAna_Circ2d2TanOn_6.cxx
src/GccAna/GccAna_Circ2d2TanOn_7.cxx
src/GccAna/GccAna_Circ2d2TanOn_8.cxx
src/GccAna/GccAna_Circ2d2TanOn_9.cxx
src/GccAna/GccAna_Circ2d2TanRad.cxx
src/GccAna/GccAna_Circ2d2TanRad_1.cxx
src/GccAna/GccAna_Circ2d2TanRad_2.cxx
src/GccAna/GccAna_Circ2d2TanRad_3.cxx
src/GccAna/GccAna_Circ2d2TanRad_4.cxx
src/GccAna/GccAna_Circ2d2TanRad_5.cxx
src/GccAna/GccAna_Circ2d3Tan.cxx
src/GccAna/GccAna_Circ2d3Tan_1.cxx
src/GccAna/GccAna_Circ2d3Tan_2.cxx
src/GccAna/GccAna_Circ2d3Tan_3.cxx
src/GccAna/GccAna_Circ2d3Tan_4.cxx
src/GccAna/GccAna_Circ2d3Tan_5.cxx
src/GccAna/GccAna_Circ2d3Tan_6.cxx
src/GccAna/GccAna_Circ2d3Tan_7.cxx
src/GccAna/GccAna_Circ2d3Tan_8.cxx
src/GccAna/GccAna_Circ2dBisec.cxx
src/GccAna/GccAna_Circ2dTanCen.cxx
src/GccAna/GccAna_Circ2dTanOnRad.cxx
src/GccAna/GccAna_Circ2dTanOnRad_1.cxx
src/GccAna/GccAna_Circ2dTanOnRad_2.cxx
src/GccAna/GccAna_Circ2dTanOnRad_3.cxx
src/GccAna/GccAna_Circ2dTanOnRad_4.cxx
src/GccAna/GccAna_Circ2dTanOnRad_5.cxx
src/GccAna/GccAna_CircLin2dBisec.cxx
src/GccAna/GccAna_CircPnt2dBisec.cxx
src/GccAna/GccAna_Lin2d2Tan.cxx
src/GccAna/GccAna_Lin2dBisec.cxx
src/GccAna/GccAna_Lin2dTanObl.cxx
src/GccAna/GccAna_Lin2dTanPar.cxx
src/GccAna/GccAna_Lin2dTanPer.cxx
src/GccAna/GccAna_LinPnt2dBisec.cxx
src/GccAna/GccAna_NoSolution.hxx
src/GccAna/GccAna_Pnt2dBisec.cxx
src/GccEnt/GccEnt_BadQualifier.hxx
src/GccInt/GccInt_Bisec.cxx
src/Geom/Geom_BSplineCurve.cxx
src/Geom/Geom_BSplineSurface.cxx
src/Geom/Geom_BSplineSurface_1.cxx
src/Geom/Geom_BezierCurve.cxx
src/Geom/Geom_BezierSurface.cxx
src/Geom/Geom_Circle.cxx
src/Geom/Geom_ConicalSurface.cxx
src/Geom/Geom_CylindricalSurface.cxx
src/Geom/Geom_Ellipse.cxx
src/Geom/Geom_Geometry.cxx
src/Geom/Geom_Hyperbola.cxx
src/Geom/Geom_OffsetCurve.cxx
src/Geom/Geom_OffsetSurface.cxx
src/Geom/Geom_OsculatingSurface.cxx
src/Geom/Geom_Parabola.cxx
src/Geom/Geom_RectangularTrimmedSurface.cxx
src/Geom/Geom_SphericalSurface.cxx
src/Geom/Geom_SurfaceOfRevolution.cxx
src/Geom/Geom_ToroidalSurface.cxx
src/Geom/Geom_TrimmedCurve.cxx
src/Geom/Geom_UndefinedDerivative.hxx
src/Geom/Geom_UndefinedValue.hxx
src/Geom2d/Geom2d_BSplineCurve.cxx
src/Geom2d/Geom2d_BezierCurve.cxx
src/Geom2d/Geom2d_Circle.cxx
src/Geom2d/Geom2d_Ellipse.cxx
src/Geom2d/Geom2d_Hyperbola.cxx
src/Geom2d/Geom2d_OffsetCurve.cxx
src/Geom2d/Geom2d_Parabola.cxx
src/Geom2d/Geom2d_TrimmedCurve.cxx
src/Geom2d/Geom2d_UndefinedDerivative.hxx
src/Geom2d/Geom2d_UndefinedValue.hxx
src/Geom2dAPI/Geom2dAPI_InterCurveCurve.cxx
src/Geom2dAPI/Geom2dAPI_InterCurveCurve.hxx
src/Geom2dAPI/Geom2dAPI_Interpolate.cxx
src/Geom2dAPI/Geom2dAPI_PointsToBSpline.cxx
src/Geom2dAdaptor/Geom2dAdaptor.cxx
src/Geom2dAdaptor/Geom2dAdaptor_Curve.cxx
src/Geom2dAdaptor/Geom2dAdaptor_Curve.lxx
src/Geom2dConvert/Geom2dConvert.cxx
src/Geom2dConvert/Geom2dConvert_BSplineCurveKnotSplitting.cxx
src/Geom2dConvert/Geom2dConvert_BSplineCurveToBezierCurve.cxx
src/Geom2dEvaluator/Geom2dEvaluator_OffsetCurve.cxx
src/Geom2dGcc/Geom2dGcc_Circ2d2TanOn.cxx
src/Geom2dGcc/Geom2dGcc_Circ2d2TanOnGeo.cxx
src/Geom2dGcc/Geom2dGcc_Circ2d2TanOnIter.cxx
src/Geom2dGcc/Geom2dGcc_Circ2d2TanRad.cxx
src/Geom2dGcc/Geom2dGcc_Circ2d2TanRadGeo.cxx
src/Geom2dGcc/Geom2dGcc_Circ2d3Tan.cxx
src/Geom2dGcc/Geom2dGcc_Circ2d3TanIter.cxx
src/Geom2dGcc/Geom2dGcc_Circ2dTanCen.cxx
src/Geom2dGcc/Geom2dGcc_Circ2dTanCenGeo.cxx
src/Geom2dGcc/Geom2dGcc_Circ2dTanOnRad.cxx
src/Geom2dGcc/Geom2dGcc_Circ2dTanOnRadGeo.cxx
src/Geom2dGcc/Geom2dGcc_FunctionTanCuCuCu.cxx
src/Geom2dGcc/Geom2dGcc_FunctionTanCuCuOnCu.cxx
src/Geom2dGcc/Geom2dGcc_IsParallel.hxx
src/Geom2dGcc/Geom2dGcc_Lin2d2Tan.cxx
src/Geom2dGcc/Geom2dGcc_Lin2d2TanIter.cxx
src/Geom2dGcc/Geom2dGcc_Lin2dTanObl.cxx
src/Geom2dGcc/Geom2dGcc_Lin2dTanOblIter.cxx
src/GeomAPI/GeomAPI_Interpolate.cxx
src/GeomAPI/GeomAPI_PointsToBSpline.cxx
src/GeomAdaptor/GeomAdaptor.cxx
src/GeomAdaptor/GeomAdaptor_Curve.cxx
src/GeomAdaptor/GeomAdaptor_Curve.lxx
src/GeomAdaptor/GeomAdaptor_Surface.cxx
src/GeomAdaptor/GeomAdaptor_Surface.lxx
src/GeomAdaptor/GeomAdaptor_SurfaceOfLinearExtrusion.cxx
src/GeomAdaptor/GeomAdaptor_SurfaceOfRevolution.cxx
src/GeomConvert/GeomConvert.cxx
src/GeomConvert/GeomConvert_1.cxx
src/GeomConvert/GeomConvert_BSplineCurveKnotSplitting.cxx
src/GeomConvert/GeomConvert_BSplineCurveToBezierCurve.cxx
src/GeomConvert/GeomConvert_BSplineSurfaceKnotSplitting.cxx
src/GeomConvert/GeomConvert_BSplineSurfaceToBezierSurface.cxx
src/GeomConvert/GeomConvert_CompBezierSurfacesToBSplineSurface.cxx
src/GeomEvaluator/GeomEvaluator_OffsetCurve.cxx
src/GeomEvaluator/GeomEvaluator_OffsetSurface.cxx
src/GeomFill/GeomFill_BSplineCurves.cxx
src/GeomFill/GeomFill_BezierCurves.cxx
src/GeomFill/GeomFill_BoundWithSurf.cxx
src/GeomFill/GeomFill_Boundary.cxx
src/GeomFill/GeomFill_ConstrainedFilling.cxx
src/GeomFill/GeomFill_Curved.cxx
src/GeomFill/GeomFill_Curved.hxx
src/GeomFill/GeomFill_Darboux.cxx
src/GeomFill/GeomFill_DiscreteTrihedron.cxx
src/GeomFill/GeomFill_DraftTrihedron.cxx
src/GeomFill/GeomFill_EvolvedSection.cxx
src/GeomFill/GeomFill_Fixed.cxx
src/GeomFill/GeomFill_Frenet.cxx
src/GeomFill/GeomFill_LocationGuide.cxx
src/GeomFill/GeomFill_LocationLaw.cxx
src/GeomFill/GeomFill_NSections.cxx
src/GeomFill/GeomFill_Pipe.cxx
src/GeomFill/GeomFill_Profiler.cxx
src/GeomFill/GeomFill_SectionLaw.cxx
src/GeomFill/GeomFill_SectionPlacement.cxx
src/GeomFill/GeomFill_SnglrFunc.cxx
src/GeomFill/GeomFill_Sweep.cxx
src/GeomFill/GeomFill_SweepSectionGenerator.cxx
src/GeomFill/GeomFill_TrihedronLaw.cxx
src/GeomInt/GeomInt_IntSS_1.cxx
src/GeomInt/GeomInt_LineConstructor.cxx
src/GeomInt/GeomInt_LineConstructor.lxx
src/GeomInt/GeomInt_TheFunctionOfTheInt2SOfThePrmPrmSvSurfacesOfWLApprox.hxx
src/GeomInt/GeomInt_TheInt2SOfThePrmPrmSvSurfacesOfWLApprox.hxx
src/GeomLProp/GeomLProp.cxx
src/GeomLib/GeomLib.cxx
src/GeomLib/GeomLib_IsPlanarSurface.cxx
src/GeomLib/GeomLib_LogSample.cxx
src/GeomPlate/GeomPlate_BuildPlateSurface.cxx
src/GeomPlate/GeomPlate_CurveConstraint.cxx
src/GeomPlate/GeomPlate_PointConstraint.cxx
src/GeomPlate/GeomPlate_Surface.cxx
src/GeomToIGES/GeomToIGES_GeomCurve.cxx
src/GeomToStep/GeomToStep_MakeConicalSurface.cxx
src/GeomTools/GeomTools_Curve2dSet.cxx
src/GeomTools/GeomTools_CurveSet.cxx
src/GeomTools/GeomTools_Debug.cxx
src/GeomTools/GeomTools_SurfaceSet.cxx
src/Graphic3d/Graphic3d_ArrayOfPrimitives.cxx
src/Graphic3d/Graphic3d_ArrayOfPrimitives.lxx
src/Graphic3d/Graphic3d_AspectFillArea3d.cxx
src/Graphic3d/Graphic3d_AspectFillArea3d.hxx
src/Graphic3d/Graphic3d_AspectLine3d.cxx
src/Graphic3d/Graphic3d_AspectLine3d.hxx
src/Graphic3d/Graphic3d_AspectMarker3d.cxx
src/Graphic3d/Graphic3d_AspectMarker3d.hxx
src/Graphic3d/Graphic3d_AspectText3d.cxx
src/Graphic3d/Graphic3d_AspectText3d.hxx
src/Graphic3d/Graphic3d_AspectTextDefinitionError.hxx
src/Graphic3d/Graphic3d_GroupDefinitionError.hxx
src/Graphic3d/Graphic3d_MaterialAspect.cxx
src/Graphic3d/Graphic3d_MaterialDefinitionError.hxx
src/Graphic3d/Graphic3d_PriorityDefinitionError.hxx
src/Graphic3d/Graphic3d_ShaderProgram.cxx
src/Graphic3d/Graphic3d_StructureDefinitionError.hxx
src/Graphic3d/Graphic3d_Texture1D.cxx
src/Graphic3d/Graphic3d_Texture2D.cxx
src/Graphic3d/Graphic3d_TextureEnv.cxx
src/Graphic3d/Graphic3d_TextureRoot.cxx
src/Graphic3d/Graphic3d_TransformError.hxx
src/Graphic3d/Graphic3d_TransformPers.hxx
src/Graphic3d/Graphic3d_Vector.cxx
src/Graphic3d/Graphic3d_VectorError.hxx
src/HLRBRep/HLRBRep_Data.cxx
src/HLRBRep/HLRBRep_EdgeBuilder.cxx
src/HLRBRep/HLRBRep_Hider.cxx
src/HLRBRep/HLRBRep_InternalAlgo.cxx
src/HLRBRep/HLRBRep_VertexList.cxx
src/HLRTopoBRep/HLRTopoBRep_DSFiller.cxx
src/Hatch/Hatch_Hatcher.cxx
src/Hermit/Hermit.cxx
src/IFGraph/IFGraph_SubPartsIterator.cxx
src/IFSelect/IFSelect_Activator.cxx
src/IFSelect/IFSelect_ContextModif.cxx
src/IFSelect/IFSelect_ContextWrite.cxx
src/IFSelect/IFSelect_Editor.cxx
src/IFSelect/IFSelect_PacketList.cxx
src/IFSelect/IFSelect_SelectAnyList.cxx
src/IFSelect/IFSelect_WorkSession.cxx
src/IGESAppli/IGESAppli_ElementResults.cxx
src/IGESAppli/IGESAppli_FiniteElement.cxx
src/IGESAppli/IGESAppli_FlowLineSpec.cxx
src/IGESAppli/IGESAppli_LevelToPWBLayerMap.cxx
src/IGESAppli/IGESAppli_NodalConstraint.cxx
src/IGESAppli/IGESAppli_NodalDisplAndRot.cxx
src/IGESAppli/IGESAppli_NodalResults.cxx
src/IGESAppli/IGESAppli_PWBArtworkStackup.cxx
src/IGESAppli/IGESAppli_PipingFlow.cxx
src/IGESBasic/IGESBasic_ExternalRefFileIndex.cxx
src/IGESBasic/IGESBasic_ExternalReferenceFile.cxx
src/IGESBasic/IGESBasic_Group.cxx
src/IGESBasic/IGESBasic_SingleParent.cxx
src/IGESBasic/IGESBasic_SubfigureDef.cxx
src/IGESConvGeom/IGESConvGeom_GeomBuilder.cxx
src/IGESData/IGESData_IGESDumper.cxx
src/IGESData/IGESData_IGESEntity.cxx
src/IGESData/IGESData_IGESWriter.cxx
src/IGESData/IGESData_ParamCursor.cxx
src/IGESData/IGESData_ToolLocation.cxx
src/IGESDefs/IGESDefs_AssociativityDef.cxx
src/IGESDefs/IGESDefs_AttributeDef.cxx
src/IGESDefs/IGESDefs_AttributeTable.cxx
src/IGESDefs/IGESDefs_GenericData.cxx
src/IGESDefs/IGESDefs_MacroDef.cxx
src/IGESDefs/IGESDefs_TabularData.cxx
src/IGESDefs/IGESDefs_UnitsData.cxx
src/IGESDimen/IGESDimen_CenterLine.cxx
src/IGESDimen/IGESDimen_DimensionDisplayData.cxx
src/IGESDimen/IGESDimen_DimensionedGeometry.cxx
src/IGESDimen/IGESDimen_FlagNote.cxx
src/IGESDimen/IGESDimen_GeneralLabel.cxx
src/IGESDimen/IGESDimen_GeneralNote.cxx
src/IGESDimen/IGESDimen_GeneralSymbol.cxx
src/IGESDimen/IGESDimen_LeaderArrow.cxx
src/IGESDimen/IGESDimen_LinearDimension.cxx
src/IGESDimen/IGESDimen_NewDimensionedGeometry.cxx
src/IGESDimen/IGESDimen_NewGeneralNote.cxx
src/IGESDimen/IGESDimen_Section.cxx
src/IGESDimen/IGESDimen_SectionedArea.cxx
src/IGESDimen/IGESDimen_WitnessLine.cxx
src/IGESDraw/IGESDraw_CircArraySubfigure.cxx
src/IGESDraw/IGESDraw_Drawing.cxx
src/IGESDraw/IGESDraw_DrawingWithRotation.cxx
src/IGESDraw/IGESDraw_LabelDisplay.cxx
src/IGESDraw/IGESDraw_NetworkSubfigure.cxx
src/IGESDraw/IGESDraw_NetworkSubfigureDef.cxx
src/IGESDraw/IGESDraw_Planar.cxx
src/IGESDraw/IGESDraw_RectArraySubfigure.cxx
src/IGESDraw/IGESDraw_SegmentedViewsVisible.cxx
src/IGESDraw/IGESDraw_ViewsVisible.cxx
src/IGESDraw/IGESDraw_ViewsVisibleWithAttr.cxx
src/IGESGeom/IGESGeom_BSplineCurve.cxx
src/IGESGeom/IGESGeom_BSplineSurface.cxx
src/IGESGeom/IGESGeom_Boundary.cxx
src/IGESGeom/IGESGeom_BoundedSurface.cxx
src/IGESGeom/IGESGeom_CompositeCurve.cxx
src/IGESGeom/IGESGeom_CopiousData.cxx
src/IGESGeom/IGESGeom_Flash.cxx
src/IGESGeom/IGESGeom_SplineCurve.cxx
src/IGESGeom/IGESGeom_SplineSurface.cxx
src/IGESGeom/IGESGeom_TransformationMatrix.cxx
src/IGESGeom/IGESGeom_TrimmedSurface.cxx
src/IGESGraph/IGESGraph_DefinitionLevel.cxx
src/IGESGraph/IGESGraph_LineFontDefPattern.cxx
src/IGESGraph/IGESGraph_TextFontDef.cxx
src/IGESSolid/IGESSolid_BooleanTree.cxx
src/IGESSolid/IGESSolid_EdgeList.cxx
src/IGESSolid/IGESSolid_Face.cxx
src/IGESSolid/IGESSolid_Loop.cxx
src/IGESSolid/IGESSolid_ManifoldSolid.cxx
src/IGESSolid/IGESSolid_Shell.cxx
src/IGESSolid/IGESSolid_SolidAssembly.cxx
src/IGESSolid/IGESSolid_TopoBuilder.cxx
src/IGESSolid/IGESSolid_VertexList.cxx
src/IGESToBRep/IGESToBRep.cxx
src/IGESToBRep/IGESToBRep_BasicCurve.cxx
src/IGESToBRep/IGESToBRep_BasicSurface.cxx
src/IGESToBRep/IGESToBRep_TopoSurface.cxx
src/Image/Image_PixMap.cxx
src/IntAna/IntAna_Curve.cxx
src/IntAna/IntAna_Int3Pln.lxx
src/IntAna/IntAna_IntConicQuad.lxx
src/IntAna/IntAna_IntLinTorus.lxx
src/IntAna/IntAna_IntQuadQuad.cxx
src/IntAna/IntAna_IntQuadQuad.lxx
src/IntAna/IntAna_QuadQuadGeo.cxx
src/IntAna/IntAna_QuadQuadGeo.lxx
src/IntAna2d/IntAna2d_AnaIntersection.lxx
src/IntAna2d/IntAna2d_IntPoint.lxx
src/IntCurve/IntCurve_IntConicConic_1.cxx
src/IntCurve/IntCurve_IntConicCurveGen.gxx
src/IntCurve/IntCurve_IntConicCurveGen.lxx
src/IntCurve/IntCurve_Polygon2dGen.gxx
src/IntCurveSurface/IntCurveSurface_Intersection.cxx
src/IntImp/IntImp_Int2S.gxx
src/IntImp/IntImp_Int2S.lxx
src/IntImp/IntImp_IntCS.gxx
src/IntImp/IntImp_ZerImpFunc.lxx
src/IntImp/IntImp_ZerParFunc.gxx
src/IntImp/IntImp_ZerParFunc.lxx
src/IntImpParGen/IntImpParGen_Intersector.gxx
src/IntPatch/IntPatch_ALine.lxx
src/IntPatch/IntPatch_GLine.lxx
src/IntPatch/IntPatch_HInterTool.cxx
src/IntPatch/IntPatch_ImpImpIntersection.lxx
src/IntPatch/IntPatch_ImpImpIntersection_2.gxx
src/IntPatch/IntPatch_ImpImpIntersection_4.gxx
src/IntPatch/IntPatch_ImpPrmIntersection.cxx
src/IntPatch/IntPatch_ImpPrmIntersection.lxx
src/IntPatch/IntPatch_Intersection.lxx
src/IntPatch/IntPatch_Line.lxx
src/IntPatch/IntPatch_LineConstructor.cxx
src/IntPatch/IntPatch_Point.lxx
src/IntPatch/IntPatch_PolyArc.cxx
src/IntPatch/IntPatch_PrmPrmIntersection.cxx
src/IntPatch/IntPatch_PrmPrmIntersection.lxx
src/IntPatch/IntPatch_RLine.lxx
src/IntPatch/IntPatch_RstInt.cxx
src/IntPatch/IntPatch_SpecialPoints.cxx
src/IntPatch/IntPatch_WLine.lxx
src/IntRes2d/IntRes2d_Domain.lxx
src/IntRes2d/IntRes2d_Intersection.lxx
src/IntRes2d/IntRes2d_IntersectionSegment.lxx
src/IntRes2d/IntRes2d_Transition.lxx
src/IntStart/IntStart_PathPoint.lxx
src/IntStart/IntStart_SearchInside.lxx
src/IntStart/IntStart_SearchOnBoundaries.gxx
src/IntStart/IntStart_SearchOnBoundaries.lxx
src/IntStart/IntStart_Segment.lxx
src/IntSurf/IntSurf_PathPoint.lxx
src/IntSurf/IntSurf_Transition.lxx
src/IntTools/IntTools_CArray1.gxx
src/IntTools/IntTools_FaceFace.cxx
src/IntTools/IntTools_TopolTool.cxx
src/IntWalk/IntWalk_IWLine.lxx
src/IntWalk/IntWalk_IWalking.lxx
src/IntWalk/IntWalk_IWalking_6.gxx
src/IntWalk/IntWalk_PWalking.lxx
src/IntWalk/IntWalk_TheFunctionOfTheInt2S.hxx
src/IntWalk/IntWalk_TheInt2S.hxx
src/Interface/Interface_Check.cxx
src/Interface/Interface_CheckFailure.hxx
src/Interface/Interface_CheckIterator.cxx
src/Interface/Interface_CheckTool.cxx
src/Interface/Interface_CopyMap.cxx
src/Interface/Interface_CopyTool.cxx
src/Interface/Interface_EntityCluster.cxx
src/Interface/Interface_EntityIterator.cxx
src/Interface/Interface_EntityList.cxx
src/Interface/Interface_FileReaderTool.cxx
src/Interface/Interface_Graph.cxx
src/Interface/Interface_InterfaceError.hxx
src/Interface/Interface_InterfaceMismatch.hxx
src/Interface/Interface_InterfaceModel.cxx
src/Interface/Interface_LineBuffer.cxx
src/Interface/Interface_MSG.cxx
src/Interface/Interface_Recognizer.gxx
src/Interface/Interface_ShareFlags.cxx
src/Interface/Interface_ShareTool.cxx
src/Interface/Interface_StaticStandards.cxx
src/Interface/Interface_UndefinedContent.cxx
src/LProp/LProp_BadContinuity.hxx
src/LProp/LProp_CLProps.gxx
src/LProp/LProp_CurAndInf.cxx
src/LProp/LProp_NotDefined.hxx
src/LProp/LProp_SLProps.gxx
src/Law/Law.cxx
src/Law/Law_BSpFunc.cxx
src/Law/Law_BSpline.cxx
src/Law/Law_BSplineKnotSplitting.cxx
src/Law/Law_Composite.cxx
src/Law/Law_Interpolate.cxx
src/LibCtl/LibCtl_Library.gxx
src/LocOpe/LocOpe_BuildShape.cxx
src/LocOpe/LocOpe_BuildWires.cxx
src/LocOpe/LocOpe_CSIntersector.cxx
src/LocOpe/LocOpe_CurveShapeIntersector.cxx
src/LocOpe/LocOpe_CurveShapeIntersector.lxx
src/LocOpe/LocOpe_DPrism.cxx
src/LocOpe/LocOpe_Generator.cxx
src/LocOpe/LocOpe_Generator.lxx
src/LocOpe/LocOpe_GluedShape.cxx
src/LocOpe/LocOpe_Gluer.cxx
src/LocOpe/LocOpe_Gluer.lxx
src/LocOpe/LocOpe_LinearForm.cxx
src/LocOpe/LocOpe_Pipe.cxx
src/LocOpe/LocOpe_Prism.cxx
src/LocOpe/LocOpe_Revol.cxx
src/LocOpe/LocOpe_RevolutionForm.cxx
src/LocOpe/LocOpe_SplitDrafts.cxx
src/LocOpe/LocOpe_SplitShape.cxx
src/LocOpe/LocOpe_Spliter.cxx
src/LocOpe/LocOpe_Spliter.lxx
src/LocOpe/LocOpe_WiresOnShape.cxx
src/LocalAnalysis/LocalAnalysis_CurveContinuity.cxx
src/LocalAnalysis/LocalAnalysis_SurfaceContinuity.cxx
src/MAT/MAT_Arc.cxx
src/MAT2d/MAT2d_CutCurve.cxx
src/MAT2d/MAT2d_Tool2d.cxx
src/MeshTest/MeshTest_Debug.cxx
src/MoniTool/MoniTool_CaseData.cxx
src/MoniTool/MoniTool_CaseData.hxx
src/MoniTool/MoniTool_TypedValue.cxx
src/NCollection/NCollection_AccAllocator.cxx
src/NCollection/NCollection_BaseSequence.cxx
src/NCollection/NCollection_CellFilter.hxx
src/NCollection/NCollection_DataMap.hxx
src/NCollection/NCollection_DoubleMap.hxx
src/NCollection/NCollection_HeapAllocator.cxx
src/NCollection/NCollection_IncAllocator.cxx
src/NCollection/NCollection_IndexedDataMap.hxx
src/NCollection/NCollection_IndexedMap.hxx
src/NCollection/NCollection_Map.hxx
src/NCollection/NCollection_WinHeapAllocator.cxx
src/OSD/OSD.hxx
src/OSD/OSD_Directory.cxx
src/OSD/OSD_Disk.cxx
src/OSD/OSD_Environment.cxx
src/OSD/OSD_Error.cxx
src/OSD/OSD_Exception.hxx
src/OSD/OSD_Exception_ACCESS_VIOLATION.hxx
src/OSD/OSD_Exception_ARRAY_BOUNDS_EXCEEDED.hxx
src/OSD/OSD_Exception_CTRL_BREAK.hxx
src/OSD/OSD_Exception_FLT_DENORMAL_OPERAND.hxx
src/OSD/OSD_Exception_FLT_DIVIDE_BY_ZERO.hxx
src/OSD/OSD_Exception_FLT_INEXACT_RESULT.hxx
src/OSD/OSD_Exception_FLT_INVALID_OPERATION.hxx
src/OSD/OSD_Exception_FLT_OVERFLOW.hxx
src/OSD/OSD_Exception_FLT_STACK_CHECK.hxx
src/OSD/OSD_Exception_FLT_UNDERFLOW.hxx
src/OSD/OSD_Exception_ILLEGAL_INSTRUCTION.hxx
src/OSD/OSD_Exception_INT_DIVIDE_BY_ZERO.hxx
src/OSD/OSD_Exception_INT_OVERFLOW.hxx
src/OSD/OSD_Exception_INVALID_DISPOSITION.hxx
src/OSD/OSD_Exception_IN_PAGE_ERROR.hxx
src/OSD/OSD_Exception_NONCONTINUABLE_EXCEPTION.hxx
src/OSD/OSD_Exception_PRIV_INSTRUCTION.hxx
src/OSD/OSD_Exception_STACK_OVERFLOW.hxx
src/OSD/OSD_Exception_STATUS_NO_MEMORY.hxx
src/OSD/OSD_File.cxx
src/OSD/OSD_FileNode.cxx
src/OSD/OSD_OSDError.hxx
src/OSD/OSD_Parallel.hxx
src/OSD/OSD_Path.cxx
src/OSD/OSD_SIGBUS.hxx
src/OSD/OSD_SIGHUP.hxx
src/OSD/OSD_SIGILL.hxx
src/OSD/OSD_SIGINT.hxx
src/OSD/OSD_SIGKILL.hxx
src/OSD/OSD_SIGQUIT.hxx
src/OSD/OSD_SIGSEGV.hxx
src/OSD/OSD_SIGSYS.hxx
src/OSD/OSD_Signal.hxx
src/OSD/OSD_signal.cxx
src/OpenGl/OpenGl_GraphicDriver.cxx
src/OpenGl/OpenGl_Group.cxx
src/OpenGl/OpenGl_StructureShadow.cxx
src/OpenGl/OpenGl_Window.cxx
src/OpenGl/OpenGl_Window_1.mm
src/PCDM/PCDM_DriverError.hxx
src/PCDM/PCDM_ReadWriter.cxx
src/PCDM/PCDM_StorageDriver.cxx
src/PLib/PLib.cxx
src/PLib/PLib_JacobiPolynomial.cxx
src/Plate/Plate_LinearScalarConstraint.cxx
src/Plate/Plate_LinearXYZConstraint.cxx
src/Plate/Plate_SampledCurveConstraint.cxx
src/Plugin/Plugin.cxx
src/Plugin/Plugin_Failure.hxx
src/Poly/Poly_CoherentTriangle.cxx
src/Poly/Poly_CoherentTriangulation.cxx
src/Poly/Poly_Triangulation.cxx
src/ProjLib/ProjLib_CompProjectedCurve.cxx
src/ProjLib/ProjLib_ComputeApprox.cxx
src/ProjLib/ProjLib_ComputeApproxOnPolarSurface.cxx
src/ProjLib/ProjLib_PrjFunc.cxx
src/ProjLib/ProjLib_PrjResolve.cxx
src/ProjLib/ProjLib_ProjectOnPlane.cxx
src/ProjLib/ProjLib_ProjectedCurve.cxx
src/ProjLib/ProjLib_Projector.cxx
src/Prs3d/Prs3d_InvalidAngle.hxx
src/PrsMgr/PrsMgr_PresentableObject.cxx
src/QABugs/QABugs_11.cxx
src/QABugs/QABugs_20.cxx
src/QANewBRepNaming/QANewBRepNaming_BooleanOperation.cxx
src/QANewBRepNaming/QANewBRepNaming_BooleanOperationFeat.cxx
src/QANewBRepNaming/QANewBRepNaming_Box.cxx
src/QANewBRepNaming/QANewBRepNaming_Chamfer.cxx
src/QANewBRepNaming/QANewBRepNaming_Cylinder.cxx
src/QANewBRepNaming/QANewBRepNaming_Fillet.cxx
src/QANewBRepNaming/QANewBRepNaming_Gluing.cxx
src/QANewBRepNaming/QANewBRepNaming_ImportShape.cxx
src/QANewBRepNaming/QANewBRepNaming_Prism.cxx
src/QANewBRepNaming/QANewBRepNaming_Revol.cxx
src/QANewBRepNaming/QANewBRepNaming_Sphere.cxx
src/QANewBRepNaming/QANewBRepNaming_TopNaming.cxx
src/QANewModTopOpe/QANewModTopOpe_Limitation.cxx
src/Quantity/Quantity_Color.cxx
src/Quantity/Quantity_ColorDefinitionError.hxx
src/Quantity/Quantity_Date.cxx
src/Quantity/Quantity_DateDefinitionError.hxx
src/Quantity/Quantity_Period.cxx
src/Quantity/Quantity_PeriodDefinitionError.hxx
src/RWStl/RWStl.cxx
src/Resource/Resource_Manager.cxx
src/Resource/Resource_NoSuchResource.hxx
src/Select3D/Select3D_PointData.hxx
src/SelectMgr/SelectMgr_SelectableObject.cxx
src/SelectMgr/SelectMgr_SelectingVolumeManager.cxx
src/ShapeAnalysis/ShapeAnalysis_BoxBndTree.cxx
src/ShapeAnalysis/ShapeAnalysis_Curve.cxx
src/ShapeAnalysis/ShapeAnalysis_Surface.cxx
src/ShapeAnalysis/ShapeAnalysis_WireOrder.cxx
src/ShapeBuild/ShapeBuild_Edge.cxx
src/ShapeConstruct/ShapeConstruct.cxx
src/ShapeConstruct/ShapeConstruct_Curve.cxx
src/ShapeConstruct/ShapeConstruct_ProjectCurveOnSurface.cxx
src/ShapeCustom/ShapeCustom_BSplineRestriction.cxx
src/ShapeExtend/ShapeExtend.cxx
src/ShapeFix/ShapeFix_Edge.cxx
src/ShapeFix/ShapeFix_EdgeProjAux.cxx
src/ShapeFix/ShapeFix_Solid.cxx
src/ShapeFix/ShapeFix_Wire_1.cxx
src/ShapeFix/ShapeFix_Wireframe.cxx
src/ShapeProcess/ShapeProcess.cxx
src/ShapeProcess/ShapeProcess_Context.cxx
src/ShapeUpgrade/ShapeUpgrade_FixSmallBezierCurves.cxx
src/ShapeUpgrade/ShapeUpgrade_ShapeDivide.cxx
src/ShapeUpgrade/ShapeUpgrade_SplitCurve2d.cxx
src/ShapeUpgrade/ShapeUpgrade_SplitCurve3d.cxx
src/ShapeUpgrade/ShapeUpgrade_SplitSurface.cxx
src/Standard/Standard_AbortiveTransaction.hxx
src/Standard/Standard_Assert.hxx
src/Standard/Standard_ConstructionError.hxx
src/Standard/Standard_DimensionError.hxx
src/Standard/Standard_DimensionMismatch.hxx
src/Standard/Standard_DivideByZero.hxx
src/Standard/Standard_DomainError.hxx
src/Standard/Standard_ErrorHandler.cxx
src/Standard/Standard_ErrorHandler.hxx
src/Standard/Standard_Failure.cxx
src/Standard/Standard_Failure.hxx
src/Standard/Standard_GUID.cxx
src/Standard/Standard_ImmutableObject.hxx
src/Standard/Standard_LicenseError.hxx
src/Standard/Standard_LicenseNotFound.hxx
src/Standard/Standard_MMgrOpt.cxx
src/Standard/Standard_MMgrRaw.cxx
src/Standard/Standard_MMgrTBBalloc.cxx
src/Standard/Standard_MultiplyDefined.hxx
src/Standard/Standard_NegativeValue.hxx
src/Standard/Standard_NoMoreObject.hxx
src/Standard/Standard_NoSuchObject.hxx
src/Standard/Standard_NotImplemented.hxx
src/Standard/Standard_NullObject.hxx
src/Standard/Standard_NullValue.hxx
src/Standard/Standard_NumericError.hxx
src/Standard/Standard_OutOfMemory.hxx
src/Standard/Standard_OutOfRange.hxx
src/Standard/Standard_Overflow.hxx
src/Standard/Standard_ProgramError.hxx
src/Standard/Standard_RangeError.hxx
src/Standard/Standard_Real.cxx
src/Standard/Standard_ShortReal.cxx
src/Standard/Standard_TooManyUsers.hxx
src/Standard/Standard_Transient.cxx
src/Standard/Standard_TypeMismatch.hxx
src/Standard/Standard_Underflow.hxx
src/StdDrivers/StdDrivers.cxx
src/StdFail/StdFail_InfiniteSolutions.hxx
src/StdFail/StdFail_NotDone.hxx
src/StdFail/StdFail_Undefined.hxx
src/StdFail/StdFail_UndefinedDerivative.hxx
src/StdFail/StdFail_UndefinedValue.hxx
src/StdLDrivers/StdLDrivers.cxx
src/StdLDrivers/StdLDrivers_DocumentRetrievalDriver.cxx
src/StdSelect/StdSelect_ViewerSelector3d.cxx
src/StepData/StepData_FieldList.cxx
src/StepData/StepData_FieldList1.cxx
src/StepData/StepData_FieldListD.cxx
src/StepData/StepData_Plex.cxx
src/StepData/StepData_SelectType.cxx
src/StepData/StepData_Simple.cxx
src/StepData/StepData_StepReaderTool.cxx
src/StepData/StepData_StepWriter.cxx
src/StepFile/StepFile_CallFailure.cxx
src/StepFile/StepFile_Read.cxx
src/StepSelect/StepSelect_StepType.cxx
src/StepToGeom/StepToGeom.cxx
src/StepToTopoDS/StepToTopoDS_Builder.cxx
src/StepToTopoDS/StepToTopoDS_TranslateCompositeCurve.cxx
src/StepToTopoDS/StepToTopoDS_TranslateEdgeLoop.cxx
src/Storage/Storage_RootData.cxx
src/Storage/Storage_StreamExtCharParityError.hxx
src/Storage/Storage_StreamFormatError.hxx
src/Storage/Storage_StreamModeError.hxx
src/Storage/Storage_StreamReadError.hxx
src/Storage/Storage_StreamTypeMismatchError.hxx
src/Storage/Storage_StreamUnknownTypeError.hxx
src/Storage/Storage_StreamWriteError.hxx
src/Storage/Storage_TypeData.cxx
src/Sweep/Sweep_NumShapeTool.cxx
src/TCollection/TCollection_Array2.gxx
src/TCollection/TCollection_AsciiString.cxx
src/TCollection/TCollection_AsciiString.lxx
src/TCollection/TCollection_BaseSequence.cxx
src/TCollection/TCollection_DataMap.gxx
src/TCollection/TCollection_DoubleMap.gxx
src/TCollection/TCollection_ExtendedString.cxx
src/TCollection/TCollection_HAsciiString.cxx
src/TCollection/TCollection_IndexedDataMap.gxx
src/TCollection/TCollection_IndexedMap.gxx
src/TDF/TDF_Attribute.cxx
src/TDF/TDF_CopyTool.cxx
src/TDF/TDF_Delta.cxx
src/TDF/TDF_Label.cxx
src/TDF/TDF_Transaction.cxx
src/TDataStd/TDataStd_Current.cxx
src/TDataStd/TDataStd_Directory.cxx
src/TDataStd/TDataStd_NoteBook.cxx
src/TDataStd/TDataStd_TreeNode.cxx
src/TDataStd/TDataStd_Variable.cxx
src/TDataXtd/TDataXtd_Geometry.cxx
src/TDataXtd/TDataXtd_Shape.cxx
src/TDocStd/TDocStd_Application.cxx
src/TDocStd/TDocStd_Document.cxx
src/TDocStd/TDocStd_Modified.cxx
src/TDocStd/TDocStd_MultiTransactionManager.cxx
src/TDocStd/TDocStd_Owner.cxx
src/TDocStd/TDocStd_XLinkIterator.cxx
src/TDocStd/TDocStd_XLinkTool.cxx
src/TFunction/TFunction_IFunction.cxx
src/TNaming/TNaming_Name.cxx
src/TNaming/TNaming_NamedShape.cxx
src/TObj/TObj_Application.cxx
src/TObj/TObj_Model.cxx
src/TObj/TObj_TIntSparseArray.cxx
src/TPrsStd/TPrsStd_AISPresentation.cxx
src/TPrsStd/TPrsStd_AISViewer.cxx
src/TPrsStd/TPrsStd_ConstraintTools.cxx
src/TestTopOpe/TestTopOpe_HDSCommands.cxx
src/TopOpeBRep/TopOpeBRep_Bipoint.cxx
src/TopOpeBRep/TopOpeBRep_EdgesFiller.cxx
src/TopOpeBRep/TopOpeBRep_EdgesIntersector.cxx
src/TopOpeBRep/TopOpeBRep_EdgesIntersector_1.cxx
src/TopOpeBRep/TopOpeBRep_FaceEdgeIntersector.cxx
src/TopOpeBRep/TopOpeBRep_FacesFiller.cxx
src/TopOpeBRep/TopOpeBRep_FacesIntersector.cxx
src/TopOpeBRep/TopOpeBRep_GeomTool.cxx
src/TopOpeBRep/TopOpeBRep_Hctxee2d.cxx
src/TopOpeBRep/TopOpeBRep_Hctxff2d.cxx
src/TopOpeBRep/TopOpeBRep_LineInter.cxx
src/TopOpeBRep/TopOpeBRep_Point2d.cxx
src/TopOpeBRep/TopOpeBRep_Point2d.lxx
src/TopOpeBRep/TopOpeBRep_ProcessGR.cxx
src/TopOpeBRep/TopOpeBRep_ShapeIntersector.cxx
src/TopOpeBRep/TopOpeBRep_ShapeIntersector2d.cxx
src/TopOpeBRep/TopOpeBRep_VPointInter.cxx
src/TopOpeBRep/TopOpeBRep_VPointInterClassifier.cxx
src/TopOpeBRep/TopOpeBRep_VPointInterIterator.cxx
src/TopOpeBRep/TopOpeBRep_WPointInterIterator.cxx
src/TopOpeBRep/TopOpeBRep_kpart.cxx
src/TopOpeBRep/TopOpeBRep_vprclo.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_BlockBuilder.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_BuilderON.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_End.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_FaceBuilder.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_GTopo.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_GridEE.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_GridSS.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_HBuilder.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_KPart.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_Section.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_ShapeSet.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_SolidBuilder.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_SplitShapes.hxx
src/TopOpeBRepBuild/TopOpeBRepBuild_WireEdgeClassifier.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_WireEdgeSet.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_fctwes.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_kpkole.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_makefaces.cxx
src/TopOpeBRepDS/TopOpeBRepDS.cxx
src/TopOpeBRepDS/TopOpeBRepDS_BuildTool.cxx
src/TopOpeBRepDS/TopOpeBRepDS_DataStructure.cxx
src/TopOpeBRepDS/TopOpeBRepDS_EXPORT.cxx
src/TopOpeBRepDS/TopOpeBRepDS_Edge3dInterferenceTool.cxx
src/TopOpeBRepDS/TopOpeBRepDS_EdgeInterferenceTool.cxx
src/TopOpeBRepDS/TopOpeBRepDS_FaceInterferenceTool.cxx
src/TopOpeBRepDS/TopOpeBRepDS_HDataStructure.cxx
src/TopOpeBRepDS/TopOpeBRepDS_PointIterator.cxx
src/TopOpeBRepDS/TopOpeBRepDS_TKI.cxx
src/TopOpeBRepDS/TopOpeBRepDS_Transition.cxx
src/TopOpeBRepDS/TopOpeBRepDS_repvg.cxx
src/TopOpeBRepTool/TopOpeBRepTool_BoxSort.cxx
src/TopOpeBRepTool/TopOpeBRepTool_CurveTool.cxx
src/TopOpeBRepTool/TopOpeBRepTool_FuseEdges.cxx
src/TopOpeBRepTool/TopOpeBRepTool_HBoxTool.cxx
src/TopOpeBRepTool/TopOpeBRepTool_PURGE.cxx
src/TopOpeBRepTool/TopOpeBRepTool_PurgeInternalEdges.cxx
src/TopOpeBRepTool/TopOpeBRepTool_REGUS.cxx
src/TopOpeBRepTool/TopOpeBRepTool_REGUW.cxx
src/TopOpeBRepTool/TopOpeBRepTool_ShapeClassifier.cxx
src/TopOpeBRepTool/TopOpeBRepTool_ShapeTool.cxx
src/TopOpeBRepTool/TopOpeBRepTool_face.cxx
src/TopoDS/TopoDS_Builder.cxx
src/TopoDS/TopoDS_FrozenShape.hxx
src/TopoDS/TopoDS_LockedShape.hxx
src/TopoDS/TopoDS_UnCompatibleShapes.hxx
src/Transfer/Transfer_Binder.cxx
src/Transfer/Transfer_Iterator.gxx
src/Transfer/Transfer_TransferDeadLoop.hxx
src/Transfer/Transfer_TransferFailure.hxx
src/Transfer/Transfer_TransferInput.cxx
src/Transfer/Transfer_TransferIterator.cxx
src/Transfer/Transfer_TransferOutput.cxx
src/Transfer/Transfer_TransferProcess.gxx
src/Units/Units.cxx
src/Units/Units_NoSuchType.hxx
src/Units/Units_NoSuchUnit.hxx
src/Units/Units_Sentence.cxx
src/Units/Units_UnitsSystem.cxx
src/V3d/V3d_BadValue.hxx
src/V3d/V3d_UnMapped.hxx
src/V3d/V3d_View_2.cxx
src/V3d/V3d_View_3.cxx
src/V3d/V3d_Viewer.cxx
src/ViewerTest/ViewerTest_ViewerCommands.cxx
src/Vrml/Vrml_DirectionalLight.cxx
src/Vrml/Vrml_Material.cxx
src/Vrml/Vrml_PointLight.cxx
src/Vrml/Vrml_SFImage.cxx
src/Vrml/Vrml_SpotLight.cxx
src/VrmlConverter/VrmlConverter_Projector.cxx
src/WNT/WNT_ClassDefinitionError.hxx
src/WNT/WNT_WClass.cxx
src/WNT/WNT_Window.cxx
src/XDEDRAW/XDEDRAW_Props.cxx
src/XSAlgo/XSAlgo_AlgoContainer.cxx
src/XSControl/XSControl_Controller.cxx
src/XSControl/XSControl_TransferWriter.cxx
src/XSControl/XSControl_Utils.cxx
src/XSDRAWIGES/XSDRAWIGES.cxx
src/XmlDrivers/XmlDrivers.cxx
src/XmlLDrivers/XmlLDrivers.cxx
src/XmlLDrivers/XmlLDrivers_DocumentRetrievalDriver.cxx
src/XmlLDrivers/XmlLDrivers_DocumentStorageDriver.cxx
src/XmlMDataXtd/XmlMDataXtd_ConstraintDriver.cxx
src/XmlMDataXtd/XmlMDataXtd_GeometryDriver.cxx
src/XmlMNaming/XmlMNaming_NamedShapeDriver.cxx
src/XmlMNaming/XmlMNaming_NamingDriver.cxx
src/XmlMNaming/XmlMNaming_Shape1.cxx
src/Xw/Xw_Window.cxx
src/gp/gp_GTrsf.cxx
src/gp/gp_GTrsf.lxx
src/gp/gp_GTrsf2d.cxx
src/gp/gp_Vec2d.cxx
src/gp/gp_VectorWithNullMagnitude.hxx
src/math/math_EigenValuesSearcher.cxx
src/math/math_FunctionSetRoot.cxx
src/math/math_Gauss.cxx
src/math/math_Matrix.cxx
src/math/math_NotSquare.hxx
src/math/math_SingularMatrix.hxx
tests/bugs/fclasses/bug28217 [deleted file]

index 8cc072b..7c96145 100644 (file)
@@ -752,7 +752,7 @@ In order to actually convert signals to exceptions, macro *OCC_CATCH_SIGNALS* ne
 
 @subsubsection occt_fcug_2_4_4 Implementation on various platforms. 
 
-The exception handling mechanism in Open CASCADE Technology  is implemented in different ways depending on the preprocessor macros *NO_CXX_EXCEPTIONS*  and *OCC_CONVERT_SIGNALS*, which shall be consistently defined by compilation  procedures for both Open CASCADE Technology and user applications: 
+The exception handling mechanism in Open CASCADE Technology  is implemented in different ways depending on the preprocessor macro *OCC_CONVERT_SIGNALS*, which shall be consistently defined by compilation  procedures for both Open CASCADE Technology and user applications: 
 
 1. On  Windows, these macros are not defined by default, and normal C++  exceptions are used in all cases, including throwing from signal handler. Thus the  behavior is as expected in C++. 
 
@@ -763,18 +763,7 @@ The exception handling mechanism in Open CASCADE Technology  is implemented in d
    * macro *OCC_CATCH_SIGNALS* is necessary (besides call to  *OSD::SetSignal()* described above) for conversion of signals into exceptions;
    * the destructors for automatic C++ objects created in the code  after that macro and till the place where signal is raised will not be called in  case of signal, since no C++ stack unwinding is performed by long jump.
 
-3. On  Linux Open CASCADE Technology can also be compiled in compatibility  mode. In that case macro  *NO_CXX_EXCEPTIONS* is defined and the C++ exceptions are simulated with C long  jumps. As a consequence, the behavior is slightly different from that expected  in the C++ standard.  
-
-While exception handling with  *NO_CXX_EXCEPTIONS* is very similar to C++ by syntax, it has a number of  peculiarities that should be taken into account: 
-
-* try and catch are actually macros defined in the file *Standard_ErrorHandler.hxx*. Therefore, including this file is necessary for  handling OCCT exceptions;
-* due to being a macro, catch cannot contain a declaration of the  exception object after its type; only type is allowed in the catch statement.  Use method *Standard_Failure::Caught()* to access an exception object;
-* catch macro may conflict with some STL classes that might use  catch(...) statements in their header files. So STL headers should not be  included after *Standard_ErrorHandler.hxx*;
-* Open CASCADE Technology try/catch block will not handle normal  C++ exceptions; however this can be achieved using special workarounds;
-* the try macro defines a C++ object that holds an entry point in the  exception handler. Therefore if exception is raised by code located immediately  after the try/catch block but on the same nesting level as *try*, it may  be handled by that *catch*. This may lead to unexpected behavior,  including infinite loop. To avoid that, always surround the try/catch block with curved brackets;
-* the destructors of C++ objects allocated on the stack after  handler initialization are not called by exception raising.
-
-In general, for writing platform-independent code it is recommended  to insert macros *OCC_CATCH_SIGNALS* in try {} blocks or other code where signals  may happen. For compatibility with previous versions of Open CASCADE Technology  the limitations described above for *NO_CXX_EXCEPTIONS* shall be assumed. 
+In general, for writing platform-independent code it is recommended  to insert macros *OCC_CATCH_SIGNALS* in try {} blocks or other code where signals  may happen.
 
 @subsection occt_fcug_2_5 Plug-In  Management
 
index e46af68..c3c21d8 100755 (executable)
@@ -102,7 +102,7 @@ void CGeometryView2D::OnLButtonDown(UINT nFlags, CPoint point)
     case CurAction2d_GlobalPanning :// noting
       break;
     default :
-      Standard_Failure::Raise(" incompatible Current Mode ");
+      throw Standard_Failure(" incompatible Current Mode ");
       break;
     }
   }
@@ -163,7 +163,7 @@ void CGeometryView2D::OnLButtonUp(UINT nFlags, CPoint point)
       myCurrentMode = CurAction2d_Nothing;
       break;
     default :
-      Standard_Failure::Raise(" incompatible Current Mode ");
+      throw Standard_Failure(" incompatible Current Mode ");
       break;
     } //switch (myCurrentMode)
   } // else // if ( Ctrl )
@@ -247,7 +247,7 @@ void CGeometryView2D::OnMouseMove(UINT nFlags, CPoint point)
       case CurAction2d_GlobalPanning : // nothing           
         break;
       default :
-        Standard_Failure::Raise(" incompatible Current Mode ");
+        throw Standard_Failure(" incompatible Current Mode ");
         break;
       }//  switch (myCurrentMode)
     }// if ( nFlags & MK_CONTROL )  else 
index 36c2ff5..28e3caf 100755 (executable)
@@ -4736,7 +4736,7 @@ void CModelingDoc::OnStopStop()
                if (!(W.Closed())){
                        AfxMessageBox (L"Wire is not closed!");
                        return;
-                       //Standard_Failure::Raise("Wire is not closed");
+                       //throw Standard_Failure("Wire is not closed");
                        
                }
                BRepBuilderAPI_MakeFace MF(support,W,Standard_True);
index 9c5cd4f..62fd159 100755 (executable)
@@ -943,10 +943,10 @@ void CViewer3dDoc::DoSample()
     {
       myPresentation->DoSample();
     }
-    catch (Standard_Failure)
+    catch (Standard_Failure const& anException)
     {
       Standard_SStream aSStream;
-      aSStream << "An exception was caught: " << Standard_Failure::Caught() << ends;
+      aSStream << "An exception was caught: " << anException << ends;
       CString aMsg = aSStream.str().c_str();
       AfxMessageBox (aMsg);
     }
index 5e49dec..a39a86d 100755 (executable)
@@ -113,9 +113,9 @@ Standard_Integer TOcafFunction_CutDriver::Execute(Handle(TFunction_Logbook)& /*l
        // Get the TNaming_NamedShape attributes of these labels
        Handle(TNaming_NamedShape) OriginalNShape, ToolNShape;
        if (!( OriginalLab.FindAttribute(TNaming_NamedShape::GetID(),OriginalNShape) ))
-               Standard_Failure::Raise("TOcaf_Commands::CutObjects");          
+               throw Standard_Failure("TOcaf_Commands::CutObjects");
        if (!( ToolLab.FindAttribute(TNaming_NamedShape::GetID(),ToolNShape) ))
-               Standard_Failure::Raise("TOcaf_Commands::CutObjects");          
+               throw Standard_Failure("TOcaf_Commands::CutObjects");
 
        // Now, let's get the TopoDS_Shape of these TNaming_NamedShape:
        TopoDS_Shape OriginalShape  = OriginalNShape->Get();
index 5c2ce5d..609a8aa 100755 (executable)
@@ -346,10 +346,10 @@ void CTriangulationDoc::DoSample()
     {
       myPresentation->DoSample();
     }
-    catch (Standard_Failure)
+    catch (Standard_Failure const& anException)
     {
       Standard_SStream aSStream;
-      aSStream << "An exception was caught: " << Standard_Failure::Caught() << ends;
+      aSStream << "An exception was caught: " << anException << ends;
       CString aMsg = aSStream.str().c_str();
 //      aSStream.rdbuf()->freeze(0);   // allow deletion of dynamic array
       AfxMessageBox (aMsg);
index d7c8476..eb0be5e 100755 (executable)
@@ -167,7 +167,7 @@ void CHLRView2D::OnMouseMove(UINT nFlags, CPoint point)
       case CurAction2d_GlobalPanning :
         break;
       default :
-        Standard_Failure::Raise(" incompatible Current Mode ");
+        throw Standard_Failure(" incompatible Current Mode ");
         break;
       }
     }
index ac189da..3d9bbb6 100755 (executable)
@@ -144,7 +144,7 @@ void CHLRView3D::OnLButtonDown(UINT nFlags, CPoint point)
                        myView->StartRotation(point.x,point.y);  
         break;
         default :
-           Standard_Failure::Raise(" incompatible Current Mode ");
+           throw Standard_Failure(" incompatible Current Mode ");
         break;
         }
     }
@@ -205,7 +205,7 @@ void CHLRView3D::OnLButtonUp(UINT nFlags, CPoint point)
               myCurrentMode = CurAction3d_Nothing;
         break;
         default :
-           Standard_Failure::Raise(" incompatible Current Mode ");
+           throw Standard_Failure(" incompatible Current Mode ");
         break;
         } //switch (myCurrentMode)
     } //       else // if ( Ctrl )
@@ -276,7 +276,7 @@ void CHLRView3D::OnMouseMove(UINT nFlags, CPoint point)
              myView->Redraw();
         break;
         default :
-           Standard_Failure::Raise(" incompatible Current Mode ");
+           throw Standard_Failure(" incompatible Current Mode ");
         break;
         }//  switch (myCurrentMode)
       }// if ( nFlags & CASCADESHORTCUTKEY )  else 
index 563abdc..7f57898 100755 (executable)
@@ -359,7 +359,7 @@ void CAnimationView3D::OnLButtonDown(UINT nFlags, CPoint point)
                        SetTimer ( 1 , 100 , NULL ) ;
                break ;
         default :
-           Standard_Failure::Raise(" incompatible Current Mode ");
+           throw Standard_Failure(" incompatible Current Mode ");
         break;
         }
     }
@@ -426,7 +426,7 @@ void CAnimationView3D::OnLButtonUp(UINT nFlags, CPoint point)
                        KillTimer ( 1 ) ;
                break;
         default :
-           Standard_Failure::Raise(" incompatible Current Mode ");
+           throw Standard_Failure(" incompatible Current Mode ");
         break;
         } //switch (myCurrentMode)
     } //       else // if ( Ctrl )
@@ -529,7 +529,7 @@ void CAnimationView3D::OnMouseMove(UINT nFlags, CPoint point)
                case CurrentAction3d_Turn :
                        break ;
         default :
-           Standard_Failure::Raise(" incompatible Current Mode ");
+           throw Standard_Failure(" incompatible Current Mode ");
         break;
         }//  switch (myCurrentMode)
       }// if ( nFlags & MK_CONTROL )  else 
index 9ed3005..4565605 100755 (executable)
@@ -150,10 +150,10 @@ void COCCDemoDoc::DoSample()
     {
       myPresentation->DoSample();
     }
-    catch (Standard_Failure)
+    catch (Standard_Failure const& anException)
     {
       Standard_SStream aSStream;
-      aSStream << "An exception was caught: " << Standard_Failure::Caught() << ends;
+      aSStream << "An exception was caught: " << anException << ends;
       CString aMsg = aSStream.str().c_str();
       AfxMessageBox (aMsg);
     }
index 3a6f7ef..79a388d 100755 (executable)
@@ -232,7 +232,7 @@ void OCC_2dView::OnBUTTONGridValues()
     TheCircularGridDialog.ShowWindow(SW_SHOW);
     break;
   default :
-    Standard_Failure::Raise("invalid Aspect_GridType");
+    throw Standard_Failure("invalid Aspect_GridType");
   }
 }
 void OCC_2dView::OnUpdateBUTTONGridValues(CCmdUI* pCmdUI) 
@@ -282,7 +282,7 @@ void OCC_2dView::OnLButtonDown(UINT nFlags, CPoint point)
     case CurAction2d_GlobalPanning :// nothing
       break;
     default :
-      Standard_Failure::Raise(" incompatible Current Mode ");
+      throw Standard_Failure(" incompatible Current Mode ");
       break;
     }
   }
@@ -344,7 +344,7 @@ void OCC_2dView::OnLButtonUp(UINT nFlags, CPoint point)
       myCurrentMode = CurAction2d_Nothing;
       break;
     default :
-      Standard_Failure::Raise(" incompatible Current Mode ");
+      throw Standard_Failure(" incompatible Current Mode ");
       break;
     } //switch (myCurrentMode)
   } // else // if ( CASCADESHORTCUTKEY )       
@@ -432,7 +432,7 @@ void OCC_2dView::OnMouseMove(UINT nFlags, CPoint point)
       case CurAction2d_GlobalPanning : // nothing
         break;
       default :
-        Standard_Failure::Raise(" incompatible Current Mode ");
+        throw Standard_Failure(" incompatible Current Mode ");
         break;
       }//  switch (myCurrentMode)
     }// if ( nFlags & CASCADESHORTCUTKEY )  else 
index aad6911..41feaa6 100755 (executable)
@@ -177,7 +177,7 @@ void OCC_2dViewRD::OnBUTTONGridValues()
       TheCircularGridDialog.ShowWindow(SW_SHOW);                  \n\
     break;                                                        \n\
     default :                                                     \n\
-      Standard_Failure::Raise(\"invalid Aspect_GridType\"); \n\
+      throw Standard_Failure(\"invalid Aspect_GridType\"); \n\
   }                                                               \n\
 \n");
   // Update The Result Dialog
index 4d8a436..ec8ddbf 100755 (executable)
@@ -302,7 +302,7 @@ void OCC_3dView::OnLButtonDown(UINT nFlags, CPoint point)
       myView->StartRotation(point.x,point.y);  
       break;
     default :
-      Standard_Failure::Raise(" incompatible Current Mode ");
+      throw Standard_Failure(" incompatible Current Mode ");
       break;
     }
   }
@@ -372,7 +372,7 @@ void OCC_3dView::OnLButtonUp(UINT nFlags, CPoint point)
       }
       break;
     default :
-      Standard_Failure::Raise(" incompatible Current Mode ");
+      throw Standard_Failure(" incompatible Current Mode ");
       break;
     } //switch (myCurrentMode)
   } // else // if ( Ctrl )
@@ -472,7 +472,7 @@ void OCC_3dView::OnMouseMove(UINT nFlags, CPoint point)
         myView->Redraw();
         break;
       default :
-        Standard_Failure::Raise(" incompatible Current Mode ");
+        throw Standard_Failure(" incompatible Current Mode ");
         break;
       }//  switch (myCurrentMode)
     }// if ( nFlags & MK_CONTROL )  else 
index b86db10..fd1576d 100755 (executable)
@@ -103,10 +103,10 @@ Application:
          nReturnCode = pApp->Run();
     }
 //  if(_Function.Catches(STANDARD_TYPE(Standard_Failure)))
-       catch(Standard_Failure)
+       catch(Standard_Failure const& anException)
     {
       Standard_SStream ostr;
-      ostr<<Standard_Failure::Caught()<<"\n\0";
+      ostr<<anException<<"\n\0";
       CString aMsg = ostr.str().c_str();
       MessageBoxW (NULL, aMsg, L"CasCade Error", MB_ICONERROR);
       goto Application; // restart application loop
index ddd32a7..ae31db2 100755 (executable)
@@ -634,7 +634,7 @@ void View::onLButtonDown( const int/*Qt::MouseButtons*/ nFlags, const QPoint poi
            myView->StartRotation( point.x(), point.y() );
            break;
       default:
-           Standard_Failure::Raise( "incompatible Current Mode" );
+           throw Standard_Failure( "incompatible Current Mode" );
            break;
     }
   }
@@ -720,7 +720,7 @@ void View::onLButtonUp( Qt::MouseButtons nFlags, const QPoint point )
             noActiveActions();
             break;
         default:
-          Standard_Failure::Raise(" incompatible Current Mode ");
+            throw Standard_Failure(" incompatible Current Mode ");
             break;
     }
     activateCursor( myCurrentMode );
@@ -788,7 +788,7 @@ void View::onMouseMove( Qt::MouseButtons nFlags, const QPoint point )
           myView->Redraw();
           break;
         default:
-          Standard_Failure::Raise( "incompatible Current Mode" );
+          throw Standard_Failure( "incompatible Current Mode" );
           break;
     }
     }
index 1a1ff29..93cd0ed 100644 (file)
@@ -1300,7 +1300,7 @@ void AIS_AngleDimension::SetTextPosition (const gp_Pnt& theTextPos)
   // The text position point for angle dimension should belong to the working plane.
   if (!GetPlane().Contains (theTextPos, Precision::Confusion()))
   {
-    Standard_ProgramError::Raise ("The text position point for angle dimension doesn't belong to the working plane.");
+    throw Standard_ProgramError("The text position point for angle dimension doesn't belong to the working plane.");
   }
 
   myIsTextPositionFixed = Standard_True;
index e7214ac..dba5403 100644 (file)
@@ -59,7 +59,7 @@ void AIS_Animation::Add (const Handle(AIS_Animation)& theAnimation)
 {
   if (theAnimation.IsNull())
   {
-    Standard_ProgramError::Raise ("AIS_Animation::Add() - attempt to add a NULL animation!");
+    throw Standard_ProgramError("AIS_Animation::Add() - attempt to add a NULL animation!");
   }
 
   for (NCollection_Sequence<Handle(AIS_Animation)>::Iterator anIter (myAnimations); anIter.More(); anIter.Next())
@@ -189,7 +189,7 @@ Standard_Real AIS_Animation::UpdateTimer()
 {
   if (myTimer.IsNull())
   {
-    Standard_ProgramError::Raise ("AIS_Animation::UpdateTimer() - timer was not created!");
+    throw Standard_ProgramError("AIS_Animation::UpdateTimer() - timer was not created!");
   }
 
   const Standard_Real anElapsedTime = myTimer->ElapsedTime();
index 31eaf41..fc34d77 100644 (file)
@@ -187,7 +187,7 @@ void AIS_Axis::Compute(const Handle(PrsMgr_PresentationManager3d)&,
 
 void AIS_Axis::Compute(const Handle(Prs3d_Projector)& aProjector, const Handle(Geom_Transformation)& aTransformation, const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_Axis::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_Axis::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
   PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
 }
 
index 1cad4d9..a6514d0 100644 (file)
@@ -212,13 +212,13 @@ void AIS_Chamf2dDimension::Compute(const Handle(PrsMgr_PresentationManager3d)& ,
 void AIS_Chamf2dDimension::Compute(const Handle(Prs3d_Projector)& aProjector,
                                   const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_Chamf2dDimension::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_Chamf2dDimension::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
  PrsMgr_PresentableObject::Compute( aProjector , aPresentation ) ;
 }
 
 void AIS_Chamf2dDimension::Compute(const Handle(Prs3d_Projector)& aProjector, const Handle(Geom_Transformation)& aTransformation, const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_Chamf2dDimension::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_Chamf2dDimension::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
   PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
 }
 
index 9cf07d2..8971e89 100644 (file)
@@ -186,13 +186,13 @@ void AIS_Chamf3dDimension::Compute(const Handle(PrsMgr_PresentationManager3d)& ,
 void AIS_Chamf3dDimension::Compute(const Handle(Prs3d_Projector)& aProjector,
                                   const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_Chamf3dDimension::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_Chamf3dDimension::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
  PrsMgr_PresentableObject::Compute( aProjector , aPresentation ) ;
 }
 
 void AIS_Chamf3dDimension::Compute(const Handle(Prs3d_Projector)& aProjector, const Handle(Geom_Transformation)& aTransformation, const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_Chamf3dDimension::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_Chamf3dDimension::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
   PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
 }
 
index 14d653c..4ab0cca 100644 (file)
@@ -94,7 +94,7 @@ void AIS_Circle::Compute(const Handle(Prs3d_Projector)& aProjector,
                          const Handle(Geom_Transformation)& aTransformation,
                          const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_Circle::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_Circle::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
   PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
 }
 
index 51445a9..473ce2c 100644 (file)
@@ -88,7 +88,7 @@ void AIS_ConcentricRelation::Compute(const Handle(PrsMgr_PresentationManager3d)&
 
 void AIS_ConcentricRelation::Compute(const Handle(Prs3d_Projector)& aProjector, const Handle(Geom_Transformation)& aTransformation, const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_ConcentricRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_ConcentricRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
   PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
 }
 
index 237e320..2919ddd 100644 (file)
@@ -75,7 +75,7 @@ void AIS_ConnectedInteractive::connect (const Handle(AIS_InteractiveObject)& the
   }
   else
   {
-    Standard_ProgramError::Raise ("AIS_ConnectedInteractive::Connect() - object without own presentation can not be connected");
+    throw Standard_ProgramError("AIS_ConnectedInteractive::Connect() - object without own presentation can not be connected");
   }
 
   if (!myReference.IsNull())
index 204c329..d0a716a 100755 (executable)
@@ -656,7 +656,7 @@ void AIS_Dimension::DrawLinearDimension (const Handle(Prs3d_Presentation)& thePr
   // do not build any dimension for equal points
   if (theFirstPoint.IsEqual (theSecondPoint, Precision::Confusion()))
   {
-    Standard_ProgramError::Raise ("Can not build presentation for equal points.");
+    throw Standard_ProgramError("Can not build presentation for equal points.");
   }
 
   Handle(Prs3d_DimensionAspect) aDimensionAspect = myDrawer->DimensionAspect();
@@ -684,7 +684,7 @@ void AIS_Dimension::DrawLinearDimension (const Handle(Prs3d_Presentation)& thePr
     if (!AdjustParametersForLinear (myFixedTextPosition, theFirstPoint, theSecondPoint,
                                     anExtensionSize, aHorisontalTextPos, myFlyout, myPlane, myIsPlaneCustom))
     {
-      Standard_ProgramError::Raise ("Can not adjust plane to the custom label position.");
+      throw Standard_ProgramError("Can not adjust plane to the custom label position.");
     }
   }
 
index 9bc9b0d..a5ed32f 100644 (file)
@@ -164,7 +164,7 @@ void AIS_EllipseRadiusDimension::ComputeCylFaceGeometry(const AIS_KindOfSurface
       }
       else 
        {
-         Standard_ConstructionError::Raise("AIS:: Not expected type of surface") ;
+         throw Standard_ConstructionError("AIS:: Not expected type of surface") ;
            return;
          }
       
@@ -174,7 +174,7 @@ void AIS_EllipseRadiusDimension::ComputeCylFaceGeometry(const AIS_KindOfSurface
        {
          if(Offset <0.0 && Abs(Offset) > myEllipse.MinorRadius ())
            {
-             Standard_ConstructionError::Raise("AIS:: Absolute value of negative offset is larger than MinorRadius");
+             throw Standard_ConstructionError("AIS:: Absolute value of negative offset is larger than MinorRadius");
                return;
              }
          
@@ -225,7 +225,7 @@ void AIS_EllipseRadiusDimension::ComputePlanarFaceGeometry()
     }
   if( !find )
     {
-      Standard_ConstructionError::Raise("AIS:: Curve is not an ellipsee or is Null") ;
+      throw Standard_ConstructionError("AIS:: Curve is not an ellipsee or is Null") ;
        return;
       }
   
index 6cd5b5d..f4d3628 100644 (file)
@@ -215,7 +215,7 @@ void AIS_EqualDistanceRelation::Compute( const Handle( PrsMgr_PresentationManage
 void AIS_EqualDistanceRelation::Compute( const Handle( Prs3d_Projector )& /*aProjector*/,
                                         const Handle( Prs3d_Presentation )& /*aPresentation*/) 
 {
-// Standard_NotImplemented::Raise("AIS_EqualDistanceRelation::Compute( const Handle( Prs3d_Projector )&,
+// throw Standard_NotImplemented("AIS_EqualDistanceRelation::Compute( const Handle( Prs3d_Projector )&,
  // const Handle( Prs3d_Presentation )& )");
 // PrsMgr_PresentableObject::Compute( aProjector , aPresentation ) ; 
 }
@@ -228,7 +228,7 @@ void AIS_EqualDistanceRelation::Compute(const Handle(Prs3d_Projector)& aProjecto
                                  const Handle(Geom_Transformation)& aTransformation,
                                  const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_EqualDistanceRelation::Compute(const Handle(Prs3d_Projector)&,
+// throw Standard_NotImplemented("AIS_EqualDistanceRelation::Compute(const Handle(Prs3d_Projector)&,
 //  const Handle(Geom_Transformation)&,const Handle(Prs3d_Presentation)&)");
  PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ; 
 }
index 4f903e8..021c5c1 100644 (file)
@@ -155,7 +155,7 @@ void AIS_EqualRadiusRelation::Compute( const Handle( PrsMgr_PresentationManager3
 void AIS_EqualRadiusRelation::Compute( const Handle( Prs3d_Projector )& /*aProjector*/,
                                       const Handle( Prs3d_Presentation )& /*aPresentation*/)
 {
-// Standard_NotImplemented::Raise("AIS_EqualRadiusRelation::Compute( const Handle( Prs3d_Projector )&,const Handle( Prs3d_Presentation )& )");
+// throw Standard_NotImplemented("AIS_EqualRadiusRelation::Compute( const Handle( Prs3d_Projector )&,const Handle( Prs3d_Presentation )& )");
 // PrsMgr_PresentableObject::Compute( aProjector , aPresentation ) ;
 }
 
@@ -168,7 +168,7 @@ void AIS_EqualRadiusRelation::Compute(const Handle(Prs3d_Projector)& aProjector,
                                       const Handle(Geom_Transformation)& aTransformation,
                                       const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_EqualRadiusRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_EqualRadiusRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
  PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
 }
 
index 15737d9..647f209 100644 (file)
@@ -204,7 +204,7 @@ void AIS_FixRelation::Compute(const Handle(PrsMgr_PresentationManager3d)&,
 void AIS_FixRelation::Compute(const Handle(Prs3d_Projector)& aProjector,
                              const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_FixRelation::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_FixRelation::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
  PrsMgr_PresentableObject::Compute( aProjector , aPresentation ) ; 
 }
 
@@ -217,7 +217,7 @@ void AIS_FixRelation::Compute(const Handle(Prs3d_Projector)& aProjector,
                               const Handle(Geom_Transformation)& aTransformation,
                               const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_FixRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_FixRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
  PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
 }
 
index 203a800..b8cc46c 100644 (file)
@@ -359,13 +359,13 @@ void AIS_IdenticRelation::Compute(const Handle(PrsMgr_PresentationManager3d)&,
 void AIS_IdenticRelation::Compute(const Handle(Prs3d_Projector)& aProjector,
                                  const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_IdenticRelation::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_IdenticRelation::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
  PrsMgr_PresentableObject::Compute( aProjector , aPresentation ) ;
 }
 
 void AIS_IdenticRelation::Compute(const Handle(Prs3d_Projector)& aProjector, const Handle(Geom_Transformation)& aTransformation, const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_IdenticRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_IdenticRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
  PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
 }
 
index 70d7400..ac91d36 100644 (file)
@@ -840,7 +840,7 @@ void AIS_InteractiveContext::Remove (const Handle(AIS_InteractiveObject)& theIOb
   {
     if (theIObj->myCTXPtr != this)
     {
-      Standard_ProgramError::Raise ("AIS_InteractiveContext - object has been displayed in another context!");
+      throw Standard_ProgramError("AIS_InteractiveContext - object has been displayed in another context!");
     }
     theIObj->SetContext (Handle(AIS_InteractiveContext)());
   }
index 85b2305..ca775d8 100644 (file)
@@ -1796,7 +1796,7 @@ protected:
     {
       if (theObj->myCTXPtr != this)
       {
-        Standard_ProgramError::Raise ("AIS_InteractiveContext - object has been already displayed in another context!");
+        throw Standard_ProgramError("AIS_InteractiveContext - object has been already displayed in another context!");
       }
     }
     else
index bcce3f6..730f3b3 100644 (file)
@@ -126,7 +126,7 @@ void AIS_Line::Compute(const Handle(PrsMgr_PresentationManager3d)&,
 
 void AIS_Line::Compute(const Handle(Prs3d_Projector)& aProjector, const Handle(Geom_Transformation)& aTransformation, const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_Line::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_Line::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
  PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation) ;
 }
 
index 9486fca..0b8aebd 100644 (file)
@@ -126,7 +126,7 @@ void AIS_MaxRadiusDimension::Compute(const Handle(PrsMgr_PresentationManager3d)&
 void  AIS_MaxRadiusDimension::Compute(const Handle(Prs3d_Projector)& aProjector,
                                       const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_MaxRadiusDimension::Compute(const Handle(Prs3d_Projector)& aProjector, const Handle(Prs3d_Presentation)& aPresentation)");
+// throw Standard_NotImplemented("AIS_MaxRadiusDimension::Compute(const Handle(Prs3d_Projector)& aProjector, const Handle(Prs3d_Presentation)& aPresentation)");
  PrsMgr_PresentableObject::Compute( aProjector , aPresentation ) ;
 }
 
@@ -139,7 +139,7 @@ void AIS_MaxRadiusDimension::Compute(const Handle(Prs3d_Projector)& aProjector,
                                      const Handle(Geom_Transformation)& aTransformation,
                                      const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_MaxRadiusDimension::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_MaxRadiusDimension::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
  PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
 }
 
index 910b960..0eaf05f 100644 (file)
@@ -144,16 +144,16 @@ void AIS_MidPointRelation::Compute(const Handle(PrsMgr_PresentationManager3d)&,
 void AIS_MidPointRelation::Compute(const Handle(Prs3d_Projector)& /*aProjector*/,
                                   const Handle(Prs3d_Presentation)& /*aPresentation*/)
 {
-// Standard_NotImplemented::Raise("AIS_MidPointRelation::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_MidPointRelation::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
 // PrsMgr_PresentableObject::Compute( aProjector , aPresentation ) ;
 }
 
-void AIS_MidPointRelation::Compute(const Handle(Prs3d_Projector)& aProjector,
-                                  const Handle(Geom_Transformation)& aTransformation,
-                                  const Handle(Prs3d_Presentation)& aPresentation)
+void AIS_MidPointRelation::Compute(const Handle(Prs3d_Projector)&,
+                                  const Handle(Geom_Transformation)&,
+                                  const Handle(Prs3d_Presentation)&)
 {
Standard_NotImplemented::Raise("AIS_MidPointRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
- PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
throw Standard_NotImplemented("AIS_MidPointRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
 }
 
 //=======================================================================
index 6c98841..7237060 100644 (file)
@@ -126,7 +126,7 @@ void AIS_MinRadiusDimension::Compute(const Handle(PrsMgr_PresentationManager3d)&
 void  AIS_MinRadiusDimension::Compute(const Handle(Prs3d_Projector)& aProjector,
                                       const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_MinRadiusDimension::Compute(const Handle(Prs3d_Projector)& aProjector, const Handle(Prs3d_Presentation)& aPresentation)");
+// throw Standard_NotImplemented("AIS_MinRadiusDimension::Compute(const Handle(Prs3d_Projector)& aProjector, const Handle(Prs3d_Presentation)& aPresentation)");
  PrsMgr_PresentableObject::Compute( aProjector , aPresentation ) ;
 }
 
@@ -139,7 +139,7 @@ void AIS_MinRadiusDimension::Compute(const Handle(Prs3d_Projector)& aProjector,
                                      const Handle(Geom_Transformation)& aTransformation,
                                      const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_MinRadiusDimension::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_MinRadiusDimension::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
  PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
 }
 
index a4232ad..dd9f864 100644 (file)
@@ -140,7 +140,7 @@ void AIS_OffsetDimension::Compute(const Handle(PrsMgr_PresentationManager3d)&,
 void AIS_OffsetDimension::Compute(const Handle(Prs3d_Projector)& /*aProjector*/,
                                  const Handle(Prs3d_Presentation)& /*aPresentation*/)
 {
-// Standard_NotImplemented::Raise("AIS_OffsetDimension::Compute(const Handle(Prs3d_Projector)& aProjector,const Handle(Prs3d_Presentation)& aPresentation)");
+// throw Standard_NotImplemented("AIS_OffsetDimension::Compute(const Handle(Prs3d_Projector)& aProjector,const Handle(Prs3d_Presentation)& aPresentation)");
 // PrsMgr_PresentableObject::Compute( aProjector , aPresentation ) ;
 }
 
@@ -148,7 +148,7 @@ void AIS_OffsetDimension::Compute(const Handle(Prs3d_Projector)& aProjector,
                                  const Handle(Geom_Transformation)& aTransformation,
                                  const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_OffsetDimension::Compute(const Handle(Prs3d_Projector)&,const Handle(Geom_Transformation)&,const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_OffsetDimension::Compute(const Handle(Prs3d_Projector)&,const Handle(Geom_Transformation)&,const Handle(Prs3d_Presentation)&)");
  PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
 }
 
index 77a3220..985d201 100644 (file)
@@ -124,13 +124,13 @@ void AIS_ParallelRelation::Compute(const Handle(PrsMgr_PresentationManager3d)&,
 void AIS_ParallelRelation::Compute(const Handle(Prs3d_Projector)& aProjector,
                                   const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_ParallelRelation::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_ParallelRelation::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
   PrsMgr_PresentableObject::Compute( aProjector , aPresentation ) ;
 }
 
 void AIS_ParallelRelation::Compute(const Handle(Prs3d_Projector)& aProjector, const Handle(Geom_Transformation)& aTransformation, const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_ParallelRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_ParallelRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
   PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
 }
 
@@ -209,7 +209,7 @@ void AIS_ParallelRelation::ComputeSelection(const Handle(SelectMgr_Selection)& a
 //=======================================================================
 void AIS_ParallelRelation::ComputeTwoFacesParallel(const Handle(Prs3d_Presentation)&)
 {
-  Standard_NotImplemented::Raise("AIS_ParallelRelation::ComputeTwoFacesParallel not implemented");
+  throw Standard_NotImplemented("AIS_ParallelRelation::ComputeTwoFacesParallel not implemented");
 }
 
 //=======================================================================
index 4971b14..313f974 100644 (file)
@@ -114,13 +114,13 @@ void AIS_PerpendicularRelation::Compute(const Handle(PrsMgr_PresentationManager3
 void AIS_PerpendicularRelation::Compute(const Handle(Prs3d_Projector)& aProjector,
                                        const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_PerpendicularRelation::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_PerpendicularRelation::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
  PrsMgr_PresentableObject::Compute( aProjector , aPresentation ) ;
 }
 
 void AIS_PerpendicularRelation::Compute(const Handle(Prs3d_Projector)& aProjector, const Handle(Geom_Transformation)& aTransformation, const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_PerpendicularRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_PerpendicularRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
  PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
 }
 
index 67ca778..b59d2fb 100644 (file)
@@ -185,7 +185,7 @@ void AIS_PlaneTrihedron::Compute(const Handle(PrsMgr_PresentationManager3d)&,
 
 void AIS_PlaneTrihedron::Compute(const Handle(Prs3d_Projector)& aProjector, const Handle(Geom_Transformation)& aTransformation, const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_PlaneTrihedron::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_PlaneTrihedron::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
  PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation) ;
 }
 
index e6eaae1..20878ff 100644 (file)
@@ -110,7 +110,7 @@ void AIS_Point::Compute(const Handle(Prs3d_Projector)& aProjector,
                         const Handle(Geom_Transformation)& aTransformation,
                         const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_Point::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_Point::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
  PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation) ;
 }
 
index 003b1d6..74d0068 100644 (file)
@@ -129,16 +129,16 @@ void AIS_SymmetricRelation::Compute(const Handle(PrsMgr_PresentationManager3d)&,
 void AIS_SymmetricRelation::Compute(const Handle(Prs3d_Projector)& /*aProjector*/,
                                    const Handle(Prs3d_Presentation)& /*aPresentation*/)
 {
-// Standard_NotImplemented::Raise("AIS_SymmetricRelation::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_SymmetricRelation::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
 // PrsMgr_PresentableObject::Compute( aProjector , aPresentation ) ;
 }
 
-void AIS_SymmetricRelation::Compute(const Handle(Prs3d_Projector)& aProjector,
-                                    const Handle(Geom_Transformation)& aTransformation,
-                                    const Handle(Prs3d_Presentation)& aPresentation)
+void AIS_SymmetricRelation::Compute(const Handle(Prs3d_Projector)&,
+                                    const Handle(Geom_Transformation)&,
+                                    const Handle(Prs3d_Presentation)&)
 {
Standard_NotImplemented::Raise("AIS_SymmetricRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
- PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
throw Standard_NotImplemented("AIS_SymmetricRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
 }
 
 //=======================================================================
index d7bda08..bab2482 100644 (file)
@@ -120,7 +120,7 @@ void AIS_TangentRelation::Compute(const Handle(PrsMgr_PresentationManager3d)&,
 void AIS_TangentRelation::Compute(const Handle(Prs3d_Projector)& aProjector,
                                  const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_TangentRelation::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_TangentRelation::Compute(const Handle(Prs3d_Projector)&,const Handle(Prs3d_Presentation)&)");
   PrsMgr_PresentableObject::Compute( aProjector , aPresentation ) ;
 }
 
@@ -128,7 +128,7 @@ void AIS_TangentRelation::Compute(const Handle(Prs3d_Projector)& aProjector,
                                  const Handle(Geom_Transformation)& aTransformation,
                                  const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_TangentRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_TangentRelation::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
   PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation ) ;
 }
 
index 58e164b..ffa1dfb 100644 (file)
@@ -297,7 +297,7 @@ void AIS_Trihedron::Compute(const Handle(Prs3d_Projector)& aProjector,
                             const Handle(Geom_Transformation)& aTransformation,
                             const Handle(Prs3d_Presentation)& aPresentation)
 {
-// Standard_NotImplemented::Raise("AIS_Trihedron::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
+// throw Standard_NotImplemented("AIS_Trihedron::Compute(const Handle(Prs3d_Projector)&, const Handle(Geom_Transformation)&, const Handle(Prs3d_Presentation)&)");
  PrsMgr_PresentableObject::Compute( aProjector , aTransformation , aPresentation) ;
 }
 
index 5241109..aabbf95 100644 (file)
@@ -46,8 +46,7 @@ Adaptor2d_Curve2d::~Adaptor2d_Curve2d()
 
 Standard_Real Adaptor2d_Curve2d::FirstParameter() const 
 {  
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::FirstParameter");
-  return 0.;
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::FirstParameter");
 }
 
 
@@ -58,8 +57,7 @@ Standard_Real Adaptor2d_Curve2d::FirstParameter() const
 
 Standard_Real Adaptor2d_Curve2d::LastParameter() const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::LastParameter");
-  return 0.;
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::LastParameter");
 }
 
 
@@ -70,8 +68,7 @@ Standard_Real Adaptor2d_Curve2d::LastParameter() const
 
 GeomAbs_Shape Adaptor2d_Curve2d::Continuity() const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::Continuity");
-  return GeomAbs_C0;
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::Continuity");
 }
 
 
@@ -83,8 +80,7 @@ GeomAbs_Shape Adaptor2d_Curve2d::Continuity() const
 //Standard_Integer Adaptor2d_Curve2d::NbIntervals(const GeomAbs_Shape S) const 
 Standard_Integer Adaptor2d_Curve2d::NbIntervals(const GeomAbs_Shape ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::NbIntervals");
-  return 0;
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::NbIntervals");
 }
 
 
@@ -98,7 +94,7 @@ Standard_Integer Adaptor2d_Curve2d::NbIntervals(const GeomAbs_Shape ) const
 void Adaptor2d_Curve2d::Intervals(TColStd_Array1OfReal& , 
                                const GeomAbs_Shape ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::Intervals");
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::Intervals");
 }
 
 
@@ -114,8 +110,7 @@ Handle(Adaptor2d_HCurve2d) Adaptor2d_Curve2d::Trim(const Standard_Real ,
                                               const Standard_Real ,
                                               const Standard_Real ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::Trim");
-  return Handle(Adaptor2d_HCurve2d)();
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::Trim");
 }
 
 //=======================================================================
@@ -125,8 +120,7 @@ Handle(Adaptor2d_HCurve2d) Adaptor2d_Curve2d::Trim(const Standard_Real ,
 
 Standard_Boolean Adaptor2d_Curve2d::IsClosed() const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::IsClosed");
-  return 0;
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::IsClosed");
 }
 
 
@@ -137,8 +131,7 @@ Standard_Boolean Adaptor2d_Curve2d::IsClosed() const
 
 Standard_Boolean Adaptor2d_Curve2d::IsPeriodic() const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::IsPeriodic");
-  return 0;
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::IsPeriodic");
 }
 
 
@@ -149,8 +142,7 @@ Standard_Boolean Adaptor2d_Curve2d::IsPeriodic() const
 
 Standard_Real Adaptor2d_Curve2d::Period() const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::Period");
-  return 0.;
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::Period");
 }
 
 
@@ -162,8 +154,7 @@ Standard_Real Adaptor2d_Curve2d::Period() const
 //gp_Pnt2d Adaptor2d_Curve2d::Value(const Standard_Real U) const 
 gp_Pnt2d Adaptor2d_Curve2d::Value(const Standard_Real ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::Value");
-  return gp_Pnt2d();
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::Value");
 }
 
 
@@ -175,7 +166,7 @@ gp_Pnt2d Adaptor2d_Curve2d::Value(const Standard_Real ) const
 //void Adaptor2d_Curve2d::D0(const Standard_Real U, gp_Pnt2d& P) const 
 void Adaptor2d_Curve2d::D0(const Standard_Real , gp_Pnt2d& ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::D0");
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::D0");
 }
 
 
@@ -189,7 +180,7 @@ void Adaptor2d_Curve2d::D0(const Standard_Real , gp_Pnt2d& ) const
 void Adaptor2d_Curve2d::D1(const Standard_Real , 
                         gp_Pnt2d& , gp_Vec2d& ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::D1");
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::D1");
 }
 
 
@@ -203,7 +194,7 @@ void Adaptor2d_Curve2d::D1(const Standard_Real ,
 void Adaptor2d_Curve2d::D2(const Standard_Real , 
                         gp_Pnt2d& , gp_Vec2d& , gp_Vec2d& ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::D2");
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::D2");
 }
 
 
@@ -217,7 +208,7 @@ void Adaptor2d_Curve2d::D2(const Standard_Real ,
 void Adaptor2d_Curve2d::D3(const Standard_Real , 
                         gp_Pnt2d& , gp_Vec2d& , gp_Vec2d& , gp_Vec2d& ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::D3");
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::D3");
 }
 
 
@@ -231,8 +222,7 @@ void Adaptor2d_Curve2d::D3(const Standard_Real ,
 gp_Vec2d Adaptor2d_Curve2d::DN(const Standard_Real , 
                             const Standard_Integer ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::DN");
-  return gp_Vec2d();
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::DN");
 }
 
 
@@ -244,8 +234,7 @@ gp_Vec2d Adaptor2d_Curve2d::DN(const Standard_Real ,
 //Standard_Real Adaptor2d_Curve2d::Resolution(const Standard_Real R3d) const 
 Standard_Real Adaptor2d_Curve2d::Resolution(const Standard_Real ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::Resolution");
-  return 0.;
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::Resolution");
 }
 
 
@@ -256,8 +245,7 @@ Standard_Real Adaptor2d_Curve2d::Resolution(const Standard_Real ) const
 
 GeomAbs_CurveType Adaptor2d_Curve2d::GetType() const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::GetType");
-  return GeomAbs_OtherCurve;
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::GetType");
 }
 
 
@@ -268,8 +256,7 @@ GeomAbs_CurveType Adaptor2d_Curve2d::GetType() const
 
 gp_Lin2d Adaptor2d_Curve2d::Line() const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::Line");
-  return gp_Lin2d();
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::Line");
 }
 
 
@@ -280,8 +267,7 @@ gp_Lin2d Adaptor2d_Curve2d::Line() const
 
 gp_Circ2d Adaptor2d_Curve2d::Circle() const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::Circle");
-  return gp_Circ2d();
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::Circle");
 }
 
 
@@ -292,8 +278,7 @@ gp_Circ2d Adaptor2d_Curve2d::Circle() const
 
 gp_Elips2d Adaptor2d_Curve2d::Ellipse() const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::Ellipse");
-  return gp_Elips2d();
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::Ellipse");
 }
 
 
@@ -304,8 +289,7 @@ gp_Elips2d Adaptor2d_Curve2d::Ellipse() const
 
 gp_Hypr2d Adaptor2d_Curve2d::Hyperbola() const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::Hyperbola");
-  return gp_Hypr2d();
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::Hyperbola");
 }
 
 
@@ -316,8 +300,7 @@ gp_Hypr2d Adaptor2d_Curve2d::Hyperbola() const
 
 gp_Parab2d Adaptor2d_Curve2d::Parabola() const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::Parabola");
-  return gp_Parab2d();
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::Parabola");
 }
 
 
@@ -328,8 +311,7 @@ gp_Parab2d Adaptor2d_Curve2d::Parabola() const
 
 Standard_Integer Adaptor2d_Curve2d::Degree() const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::Degree");
-  return 0;
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::Degree");
 }
 
 
@@ -340,8 +322,7 @@ Standard_Integer Adaptor2d_Curve2d::Degree() const
 
 Standard_Boolean Adaptor2d_Curve2d::IsRational() const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::IsRational");
-  return 0;
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::IsRational");
 }
 
 
@@ -352,8 +333,7 @@ Standard_Boolean Adaptor2d_Curve2d::IsRational() const
 
 Standard_Integer Adaptor2d_Curve2d::NbPoles() const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::NbPole");
-  return 0;
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::NbPole");
 }
 
 
@@ -364,8 +344,7 @@ Standard_Integer Adaptor2d_Curve2d::NbPoles() const
 
 Standard_Integer Adaptor2d_Curve2d::NbKnots() const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::NbKnots");
-  return 0;
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::NbKnots");
 }
 
 
@@ -376,8 +355,7 @@ Standard_Integer Adaptor2d_Curve2d::NbKnots() const
 
 Handle(Geom2d_BezierCurve) Adaptor2d_Curve2d::Bezier() const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::Bezier");
-  return Handle(Geom2d_BezierCurve)();
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::Bezier");
 }
 
 
@@ -388,8 +366,7 @@ Handle(Geom2d_BezierCurve) Adaptor2d_Curve2d::Bezier() const
 
 Handle(Geom2d_BSplineCurve) Adaptor2d_Curve2d::BSpline() const 
 {
-  Standard_NotImplemented::Raise("Adaptor2d_Curve2d::BSpline");
-  return Handle(Geom2d_BSplineCurve)();
+  throw Standard_NotImplemented("Adaptor2d_Curve2d::BSpline");
 }
 
 //=======================================================================
index cca4207..d9c1178 100644 (file)
@@ -173,8 +173,7 @@ Standard_Boolean Adaptor2d_Line2d::IsPeriodic() const
 
 Standard_Real Adaptor2d_Line2d::Period() const 
 {
-  Standard_NoSuchObject::Raise();
-  return 0;
+  throw Standard_NoSuchObject();
 }
 
 //=======================================================================
@@ -238,7 +237,7 @@ void Adaptor2d_Line2d::D3(const Standard_Real X, gp_Pnt2d& P, gp_Vec2d& V1, gp_V
 //gp_Vec2d Adaptor2d_Line2d::DN(const Standard_Real U, const Standard_Integer N) const 
 gp_Vec2d Adaptor2d_Line2d::DN(const Standard_Real , const Standard_Integer N) const 
 {
-  if (N<=0) {Standard_OutOfRange::Raise();}
+  if (N<=0) {throw Standard_OutOfRange();}
   if (N==1) {
     return myAx2d.Direction();
   }
@@ -282,8 +281,7 @@ gp_Lin2d Adaptor2d_Line2d::Line() const
 
 gp_Circ2d Adaptor2d_Line2d::Circle() const 
 {
-  Standard_NoSuchObject::Raise();
-  return gp_Circ2d();
+  throw Standard_NoSuchObject();
 }
 
 //=======================================================================
@@ -293,8 +291,7 @@ gp_Circ2d Adaptor2d_Line2d::Circle() const
 
 gp_Elips2d Adaptor2d_Line2d::Ellipse() const 
 {
-  Standard_NoSuchObject::Raise();
-  return gp_Elips2d();
+  throw Standard_NoSuchObject();
 }
 
 //=======================================================================
@@ -304,8 +301,7 @@ gp_Elips2d Adaptor2d_Line2d::Ellipse() const
 
 gp_Hypr2d Adaptor2d_Line2d::Hyperbola() const 
 {
-  Standard_NoSuchObject::Raise();
-  return gp_Hypr2d();
+  throw Standard_NoSuchObject();
 }
 
 //=======================================================================
@@ -315,8 +311,7 @@ gp_Hypr2d Adaptor2d_Line2d::Hyperbola() const
 
 gp_Parab2d Adaptor2d_Line2d::Parabola() const 
 {
-  Standard_NoSuchObject::Raise();
-  return gp_Parab2d();
+  throw Standard_NoSuchObject();
 }
 
 //=======================================================================
@@ -326,8 +321,7 @@ gp_Parab2d Adaptor2d_Line2d::Parabola() const
 
 Standard_Integer Adaptor2d_Line2d::Degree()  const 
  {
-  Standard_NoSuchObject::Raise();
-  return 0 ;
+  throw Standard_NoSuchObject();
 }
 //=======================================================================
 //function : IsRational
@@ -336,8 +330,7 @@ Standard_Integer Adaptor2d_Line2d::Degree()  const
 
 Standard_Boolean Adaptor2d_Line2d::IsRational()  const 
  {
-  Standard_NoSuchObject::Raise();
-  return 0 ;
+  throw Standard_NoSuchObject();
 }
 //=======================================================================
 //function : NbPoles
@@ -346,8 +339,7 @@ Standard_Boolean Adaptor2d_Line2d::IsRational()  const
 
 Standard_Integer Adaptor2d_Line2d::NbPoles()  const 
  {
-  Standard_NoSuchObject::Raise();
-  return 0 ;
+  throw Standard_NoSuchObject();
 }
 //=======================================================================
 //function : NbKnots
@@ -356,8 +348,7 @@ Standard_Integer Adaptor2d_Line2d::NbPoles()  const
 
 Standard_Integer Adaptor2d_Line2d::NbKnots()  const 
  {
-  Standard_NoSuchObject::Raise();
-  return 0 ;
+  throw Standard_NoSuchObject();
 }
 //=======================================================================
 //function : Bezier
@@ -366,9 +357,7 @@ Standard_Integer Adaptor2d_Line2d::NbKnots()  const
 
 Handle(Geom2d_BezierCurve) Adaptor2d_Line2d::Bezier() const 
 {
-  Standard_NoSuchObject::Raise();
-  Handle(Geom2d_BezierCurve) nul;
-  return nul;
+  throw Standard_NoSuchObject();
 }
 
 //=======================================================================
@@ -378,8 +367,6 @@ Handle(Geom2d_BezierCurve) Adaptor2d_Line2d::Bezier() const
 
 Handle(Geom2d_BSplineCurve) Adaptor2d_Line2d::BSpline() const 
 {
-  Standard_NoSuchObject::Raise();
-  Handle(Geom2d_BSplineCurve) nul;
-  return nul;
+  throw Standard_NoSuchObject();
 }
 
index fc18a6d..4f7e429 100644 (file)
@@ -145,7 +145,7 @@ GeomAbs_Shape Adaptor2d_OffsetCurve::Continuity() const
   case GeomAbs_G1: return GeomAbs_C0;
   case GeomAbs_C0:
 // No Continuity !!
-    Standard_TypeMismatch::Raise("Adaptor2d_OffsetCurve::IntervalContinuity");
+    throw Standard_TypeMismatch("Adaptor2d_OffsetCurve::IntervalContinuity");
     break;
   }
 
@@ -309,8 +309,7 @@ gp_Pnt2d Adaptor2d_OffsetCurve::Value(const Standard_Real U) const
       return gp_Pnt2d(P.XY()+myOffset*V.XY()/Norme);
     }
     else {
-      gp_VectorWithNullMagnitude::Raise("Adaptor2d_OffsetCurve::Value");
-      return gp_Pnt2d();
+      throw gp_VectorWithNullMagnitude("Adaptor2d_OffsetCurve::Value");
     }
   }
   else {
@@ -351,7 +350,7 @@ void Adaptor2d_OffsetCurve::D1
                                    (V2.XY()*V3.XY())/(Norme*Norme)));
     }
     else {
-      gp_VectorWithNullMagnitude::Raise("Adaptor2d_OffsetCurve::D1");
+      throw gp_VectorWithNullMagnitude("Adaptor2d_OffsetCurve::D1");
     }
   }
   else {
@@ -392,7 +391,7 @@ void Adaptor2d_OffsetCurve::D2
       D1( U,P,V1);
     }
     else {
-      gp_VectorWithNullMagnitude::Raise("Adaptor2d_OffsetCurve::D2");
+      throw gp_VectorWithNullMagnitude("Adaptor2d_OffsetCurve::D2");
     }
   }
   else {
@@ -412,7 +411,7 @@ void Adaptor2d_OffsetCurve::D3
   (const Standard_Real , 
    gp_Pnt2d& , gp_Vec2d& , gp_Vec2d& , gp_Vec2d& ) const
 {
-  Standard_NotImplemented::Raise("Adaptor2d_OffsetCurve::D3");
+  throw Standard_NotImplemented("Adaptor2d_OffsetCurve::D3");
 }
 
 //=======================================================================
@@ -424,8 +423,7 @@ gp_Vec2d Adaptor2d_OffsetCurve::DN
 //  (const Standard_Real T, const Standard_Integer N) const
   (const Standard_Real , const Standard_Integer ) const
 {
-  Standard_NotImplemented::Raise("Adaptor2d_OffsetCurve::DN");
-  return gp_Vec2d();
+  throw Standard_NotImplemented("Adaptor2d_OffsetCurve::DN");
 }
 
 
@@ -480,8 +478,7 @@ gp_Lin2d Adaptor2d_OffsetCurve::Line() const
     return gp_Lin2d(P,V);
   }
   else {
-    Standard_NoSuchObject::Raise("Adaptor2d_OffsetCurve::Line");
-    return gp_Lin2d();
+    throw Standard_NoSuchObject("Adaptor2d_OffsetCurve::Line");
   }
 }
 
@@ -516,15 +513,13 @@ gp_Circ2d Adaptor2d_OffsetCurve::Circle() const
        return gp_Circ2d( axes,radius); 
       }
       else {     // Cercle de rayon Nul
-       Standard_NoSuchObject::Raise("Adaptor2d_OffsetCurve::Circle");
+       throw Standard_NoSuchObject("Adaptor2d_OffsetCurve::Circle");
       }
     }
   }
   else {
-    Standard_NoSuchObject::Raise("Adaptor2d_OffsetCurve::Circle");
+    throw Standard_NoSuchObject("Adaptor2d_OffsetCurve::Circle");
   }
-  // portage WNT
-  return gp_Circ2d();
 }
 
 //=======================================================================
@@ -538,10 +533,8 @@ gp_Elips2d Adaptor2d_OffsetCurve::Ellipse() const
     return myCurve->Ellipse();;
   }
   else {
-    Standard_NoSuchObject::Raise("Adaptor2d_OffsetCurve:Ellipse");
+    throw Standard_NoSuchObject("Adaptor2d_OffsetCurve:Ellipse");
   }
-  // portage WNT
-  return gp_Elips2d();
 }
 
 //=======================================================================
@@ -555,10 +548,8 @@ gp_Hypr2d Adaptor2d_OffsetCurve::Hyperbola() const
     return myCurve->Hyperbola();
   }
   else {
-    Standard_NoSuchObject::Raise("Adaptor2d_OffsetCurve:Hyperbola");
+    throw Standard_NoSuchObject("Adaptor2d_OffsetCurve:Hyperbola");
   }
-  // portage WNT
-  return gp_Hypr2d();
 }
 
 //=======================================================================
@@ -572,10 +563,8 @@ gp_Parab2d Adaptor2d_OffsetCurve::Parabola() const
     return myCurve->Parabola();
   }
   else {
-    Standard_NoSuchObject::Raise("Adaptor2d_OffsetCurve:Parabola");
+    throw Standard_NoSuchObject("Adaptor2d_OffsetCurve:Parabola");
   }
-  // portage WNT
-  return gp_Parab2d();
 }
 //=======================================================================
 //function : Degree
@@ -590,8 +579,7 @@ Standard_Integer  Adaptor2d_OffsetCurve::Degree() const
     return myCurve->Degree();
   }
   else {
-    Standard_NoSuchObject::Raise("Adaptor2d_OffsetCurve::Degree");
-    return 0;
+    throw Standard_NoSuchObject("Adaptor2d_OffsetCurve::Degree");
   }
 }
 //=======================================================================
@@ -619,8 +607,7 @@ Standard_Integer  Adaptor2d_OffsetCurve::NbPoles() const
     return myCurve->NbPoles();
   }
   else {
-    Standard_NoSuchObject::Raise("Adaptor2d_OffsetCurve::NbPoles");
-    return 0;
+    throw Standard_NoSuchObject("Adaptor2d_OffsetCurve::NbPoles");
   }
 }
 
@@ -635,8 +622,7 @@ Standard_Integer  Adaptor2d_OffsetCurve::NbKnots() const
     return myCurve->NbKnots();
   }
   else {
-    Standard_NoSuchObject::Raise("Adaptor2d_OffsetCurve::NbKnots");
-    return 0;
+    throw Standard_NoSuchObject("Adaptor2d_OffsetCurve::NbKnots");
   }
 }
 
index 4825344..49b02da 100644 (file)
@@ -47,8 +47,7 @@ Adaptor3d_Curve::~Adaptor3d_Curve()
 
 Standard_Real Adaptor3d_Curve::FirstParameter() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::FirstParameter");
-  return 0.;
+  throw Standard_NotImplemented("Adaptor3d_Curve::FirstParameter");
 }
 
 
@@ -59,8 +58,7 @@ Standard_Real Adaptor3d_Curve::FirstParameter() const
 
 Standard_Real Adaptor3d_Curve::LastParameter() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::LastParameter");
-  return 0.;
+  throw Standard_NotImplemented("Adaptor3d_Curve::LastParameter");
 }
 
 
@@ -71,8 +69,7 @@ Standard_Real Adaptor3d_Curve::LastParameter() const
 
 GeomAbs_Shape Adaptor3d_Curve::Continuity() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::Continuity");
-  return GeomAbs_C0;
+  throw Standard_NotImplemented("Adaptor3d_Curve::Continuity");
 }
 
 
@@ -83,8 +80,7 @@ GeomAbs_Shape Adaptor3d_Curve::Continuity() const
 
 Standard_Integer Adaptor3d_Curve::NbIntervals(const GeomAbs_Shape ) const
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::NbIntervals");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Curve::NbIntervals");
 }
 
 
@@ -95,7 +91,7 @@ Standard_Integer Adaptor3d_Curve::NbIntervals(const GeomAbs_Shape ) const
 
 void Adaptor3d_Curve::Intervals(TColStd_Array1OfReal& , const GeomAbs_Shape ) const
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::Intervals");
+  throw Standard_NotImplemented("Adaptor3d_Curve::Intervals");
 }
 
 
@@ -107,8 +103,7 @@ void Adaptor3d_Curve::Intervals(TColStd_Array1OfReal& , const GeomAbs_Shape ) co
 //Handle(Adaptor3d_HCurve) Adaptor3d_Curve::Trim(const Standard_Real First, const Standard_Real Last, const Standard_Real Tol) const 
 Handle(Adaptor3d_HCurve) Adaptor3d_Curve::Trim(const Standard_Real , const Standard_Real , const Standard_Real ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::Trim");
-  return Handle(Adaptor3d_HCurve)();
+  throw Standard_NotImplemented("Adaptor3d_Curve::Trim");
 }
 
 
@@ -119,8 +114,7 @@ Handle(Adaptor3d_HCurve) Adaptor3d_Curve::Trim(const Standard_Real , const Stand
 
 Standard_Boolean Adaptor3d_Curve::IsClosed() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::IsClosed");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Curve::IsClosed");
 }
 
 
@@ -131,8 +125,7 @@ Standard_Boolean Adaptor3d_Curve::IsClosed() const
 
 Standard_Boolean Adaptor3d_Curve::IsPeriodic() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::IsPeriodic");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Curve::IsPeriodic");
 }
 
 
@@ -143,8 +136,7 @@ Standard_Boolean Adaptor3d_Curve::IsPeriodic() const
 
 Standard_Real Adaptor3d_Curve::Period() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::Period");
-  return 0.;
+  throw Standard_NotImplemented("Adaptor3d_Curve::Period");
 }
 
 
@@ -156,8 +148,7 @@ Standard_Real Adaptor3d_Curve::Period() const
 //gp_Pnt Adaptor3d_Curve::Value(const Standard_Real U) const 
 gp_Pnt Adaptor3d_Curve::Value(const Standard_Real ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::Value");
-  return gp_Pnt();
+  throw Standard_NotImplemented("Adaptor3d_Curve::Value");
 }
 
 
@@ -169,7 +160,7 @@ gp_Pnt Adaptor3d_Curve::Value(const Standard_Real ) const
 //void Adaptor3d_Curve::D0(const Standard_Real U, gp_Pnt& P) const 
 void Adaptor3d_Curve::D0(const Standard_Real , gp_Pnt& ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::D0");
+  throw Standard_NotImplemented("Adaptor3d_Curve::D0");
 }
 
 
@@ -181,7 +172,7 @@ void Adaptor3d_Curve::D0(const Standard_Real , gp_Pnt& ) const
 //void Adaptor3d_Curve::D1(const Standard_Real U, gp_Pnt& P, gp_Vec& V) const 
 void Adaptor3d_Curve::D1(const Standard_Real , gp_Pnt& , gp_Vec& ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::D1");
+  throw Standard_NotImplemented("Adaptor3d_Curve::D1");
 }
 
 
@@ -193,7 +184,7 @@ void Adaptor3d_Curve::D1(const Standard_Real , gp_Pnt& , gp_Vec& ) const
 //void Adaptor3d_Curve::D2(const Standard_Real U, gp_Pnt& P, gp_Vec& V1, gp_Vec& V2) const 
 void Adaptor3d_Curve::D2(const Standard_Real , gp_Pnt& , gp_Vec& , gp_Vec& ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::D2");
+  throw Standard_NotImplemented("Adaptor3d_Curve::D2");
 }
 
 
@@ -205,7 +196,7 @@ void Adaptor3d_Curve::D2(const Standard_Real , gp_Pnt& , gp_Vec& , gp_Vec& ) con
 //void Adaptor3d_Curve::D3(const Standard_Real U, gp_Pnt& P, gp_Vec& V1, gp_Vec& V2, gp_Vec& V3) const 
 void Adaptor3d_Curve::D3(const Standard_Real , gp_Pnt& , gp_Vec& , gp_Vec& , gp_Vec& ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::D3");
+  throw Standard_NotImplemented("Adaptor3d_Curve::D3");
 }
 
 
@@ -217,8 +208,7 @@ void Adaptor3d_Curve::D3(const Standard_Real , gp_Pnt& , gp_Vec& , gp_Vec& , gp_
 //gp_Vec Adaptor3d_Curve::DN(const Standard_Real U, const Standard_Integer N) const 
 gp_Vec Adaptor3d_Curve::DN(const Standard_Real , const Standard_Integer ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::DN");
-  return gp_Vec();
+  throw Standard_NotImplemented("Adaptor3d_Curve::DN");
 }
 
 
@@ -230,8 +220,7 @@ gp_Vec Adaptor3d_Curve::DN(const Standard_Real , const Standard_Integer ) const
 //Standard_Real Adaptor3d_Curve::Resolution(const Standard_Real R3d) const 
 Standard_Real Adaptor3d_Curve::Resolution(const Standard_Real ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::Resolution");
-  return 0.;
+  throw Standard_NotImplemented("Adaptor3d_Curve::Resolution");
 }
 
 
@@ -242,8 +231,7 @@ Standard_Real Adaptor3d_Curve::Resolution(const Standard_Real ) const
 
 GeomAbs_CurveType Adaptor3d_Curve::GetType() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::GetType");
-  return GeomAbs_OtherCurve;
+  throw Standard_NotImplemented("Adaptor3d_Curve::GetType");
 }
 
 
@@ -254,8 +242,7 @@ GeomAbs_CurveType Adaptor3d_Curve::GetType() const
 
 gp_Lin Adaptor3d_Curve::Line() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::Line");
-  return gp_Lin();
+  throw Standard_NotImplemented("Adaptor3d_Curve::Line");
 }
 
 
@@ -266,8 +253,7 @@ gp_Lin Adaptor3d_Curve::Line() const
 
 gp_Circ Adaptor3d_Curve::Circle() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::Circle");
-  return gp_Circ();
+  throw Standard_NotImplemented("Adaptor3d_Curve::Circle");
 }
 
 
@@ -278,8 +264,7 @@ gp_Circ Adaptor3d_Curve::Circle() const
 
 gp_Elips Adaptor3d_Curve::Ellipse() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::Ellipse");
-  return gp_Elips();
+  throw Standard_NotImplemented("Adaptor3d_Curve::Ellipse");
 }
 
 
@@ -290,8 +275,7 @@ gp_Elips Adaptor3d_Curve::Ellipse() const
 
 gp_Hypr Adaptor3d_Curve::Hyperbola() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::Hyperbola");
-  return gp_Hypr();
+  throw Standard_NotImplemented("Adaptor3d_Curve::Hyperbola");
 }
 
 
@@ -302,8 +286,7 @@ gp_Hypr Adaptor3d_Curve::Hyperbola() const
 
 gp_Parab Adaptor3d_Curve::Parabola() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::Parabola");
-  return gp_Parab();
+  throw Standard_NotImplemented("Adaptor3d_Curve::Parabola");
 }
 
 
@@ -314,8 +297,7 @@ gp_Parab Adaptor3d_Curve::Parabola() const
 
 Standard_Integer Adaptor3d_Curve::Degree() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::Degree");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Curve::Degree");
 }
 
 
@@ -326,8 +308,7 @@ Standard_Integer Adaptor3d_Curve::Degree() const
 
 Standard_Boolean Adaptor3d_Curve::IsRational() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::IsRational");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Curve::IsRational");
 }
 
 
@@ -338,8 +319,7 @@ Standard_Boolean Adaptor3d_Curve::IsRational() const
 
 Standard_Integer Adaptor3d_Curve::NbPoles() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::NbPoles");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Curve::NbPoles");
 }
 
 
@@ -350,8 +330,7 @@ Standard_Integer Adaptor3d_Curve::NbPoles() const
 
 Standard_Integer Adaptor3d_Curve::NbKnots() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::NbKnots");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Curve::NbKnots");
 }
 
 
@@ -362,8 +341,7 @@ Standard_Integer Adaptor3d_Curve::NbKnots() const
 
 Handle(Geom_BezierCurve) Adaptor3d_Curve::Bezier() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::Bezier");
-  return Handle(Geom_BezierCurve)();
+  throw Standard_NotImplemented("Adaptor3d_Curve::Bezier");
 }
 
 
@@ -374,8 +352,7 @@ Handle(Geom_BezierCurve) Adaptor3d_Curve::Bezier() const
 
 Handle(Geom_BSplineCurve) Adaptor3d_Curve::BSpline() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::BSpline");
-  return Handle(Geom_BSplineCurve)();
+  throw Standard_NotImplemented("Adaptor3d_Curve::BSpline");
 }
 
 //=======================================================================
@@ -385,6 +362,5 @@ Handle(Geom_BSplineCurve) Adaptor3d_Curve::BSpline() const
 
 Handle(Geom_OffsetCurve) Adaptor3d_Curve::OffsetCurve() const
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Curve::OffsetCurve");
-  return Handle(Geom_OffsetCurve)();
+  throw Standard_NotImplemented("Adaptor3d_Curve::OffsetCurve");
 }
index 14112d5..1a633f2 100644 (file)
@@ -158,7 +158,7 @@ static void Hunt(const TColStd_Array1OfReal& Arr,
     Iloc = i;
   else
     if(Abs(Coord - Arr(i)) > Tol) 
-      Standard_NotImplemented::Raise("Adaptor3d_CurveOnSurface:Hunt");
+      throw Standard_NotImplemented("Adaptor3d_CurveOnSurface:Hunt");
 }
 
 //=======================================================================
@@ -1179,7 +1179,7 @@ gp_Vec Adaptor3d_CurveOnSurface::DN
     D3(U,P,V1,V2,V);
     break ;
   default:
-    Standard_NotImplemented::Raise("Adaptor3d_CurveOnSurface:DN");
+    throw Standard_NotImplemented("Adaptor3d_CurveOnSurface:DN");
     break;
   }
   return V;
@@ -1305,8 +1305,7 @@ Standard_Integer Adaptor3d_CurveOnSurface::NbKnots() const {
   if (mySurface->GetType()==GeomAbs_Plane)
     return myCurve->NbKnots();
   else {
-    Standard_NoSuchObject::Raise();
-    return 0;
+    throw Standard_NoSuchObject();
   }
 }
 
@@ -1635,7 +1634,7 @@ void Adaptor3d_CurveOnSurface::EvalFirstLastSurf()
       Ok = LocatePart_Offset(UV,DUV,mySurface,LeftBot,RightTop);
       break;
       default :
-       Standard_NotImplemented::Raise("Adaptor3d_CurveOnSurface::EvalFirstLastSurf");
+       throw Standard_NotImplemented("Adaptor3d_CurveOnSurface::EvalFirstLastSurf");
       break;
     }
   }
@@ -1673,7 +1672,7 @@ void Adaptor3d_CurveOnSurface::EvalFirstLastSurf()
       Ok = LocatePart_Offset(UV,DUV,mySurface,LeftBot,RightTop);
       break;
       default :
-       Standard_NotImplemented::Raise("Adaptor3d_CurveOnSurface::EvalFirstLastSurf");
+       throw Standard_NotImplemented("Adaptor3d_CurveOnSurface::EvalFirstLastSurf");
       break;
     }
   }
index b89837f..2643630 100644 (file)
@@ -23,7 +23,7 @@
 
 Adaptor3d_InterFunc::Adaptor3d_InterFunc(const Handle(Adaptor2d_HCurve2d)& C, const Standard_Real FixVal, const Standard_Integer Fix) : myCurve2d(C),myFixVal(FixVal),myFix(Fix)
 {
-  if(Fix != 1 && Fix != 2 ) Standard_ConstructionError::Raise();
+  if(Fix != 1 && Fix != 2 ) throw Standard_ConstructionError();
 
 }
 
index 75eed94..5cbc54e 100644 (file)
@@ -137,7 +137,7 @@ void Adaptor3d_IsoCurve::Load(const GeomAbs_IsoType Iso,
     break;
 
   case GeomAbs_NoneIso:
-    Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+    throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
     break;
   }
 }
@@ -230,8 +230,7 @@ GeomAbs_Shape Adaptor3d_IsoCurve::Continuity() const
     break;
   }
   
-  Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
-  return GeomAbs_C0;
+  throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
 }
 
 //=======================================================================
@@ -241,7 +240,7 @@ GeomAbs_Shape Adaptor3d_IsoCurve::Continuity() const
 
 Standard_Integer Adaptor3d_IsoCurve::NbIntervals(const GeomAbs_Shape S) const
 {
-  if (myIso == GeomAbs_NoneIso) Standard_NoSuchObject::Raise();
+  if (myIso == GeomAbs_NoneIso) throw Standard_NoSuchObject();
   Standard_Boolean UIso =  (myIso == GeomAbs_IsoU);
 
   Standard_Integer nbInter = UIso ? 
@@ -272,7 +271,7 @@ Standard_Integer Adaptor3d_IsoCurve::NbIntervals(const GeomAbs_Shape S) const
 void Adaptor3d_IsoCurve::Intervals(TColStd_Array1OfReal& TI,
                                    const GeomAbs_Shape S) const
 {
-  if (myIso == GeomAbs_NoneIso) Standard_NoSuchObject::Raise();
+  if (myIso == GeomAbs_NoneIso) throw Standard_NoSuchObject();
   Standard_Boolean UIso =  (myIso == GeomAbs_IsoU);
 
   Standard_Integer nbInter = UIso ? 
@@ -338,8 +337,7 @@ Standard_Boolean Adaptor3d_IsoCurve::IsClosed() const
     break;
   }
 
-  Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
-  return Standard_False;
+  throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
 }
 
 //=======================================================================
@@ -359,8 +357,7 @@ Standard_Boolean Adaptor3d_IsoCurve::IsPeriodic() const
     break;
   }
 
-  Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
-  return Standard_False;
+  throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
 }
 
 //=======================================================================
@@ -380,8 +377,7 @@ Standard_Real Adaptor3d_IsoCurve::Period() const
     break;
   }
 
-  Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
-  return 0.;
+  throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
 }
 
 //=======================================================================
@@ -401,7 +397,7 @@ gp_Pnt Adaptor3d_IsoCurve::Value(const Standard_Real T) const
     
   case GeomAbs_NoneIso: 
     {
-      Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+      throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
       break;
     }
   }
@@ -428,7 +424,7 @@ void Adaptor3d_IsoCurve::D0(const Standard_Real T, gp_Pnt& P) const
     break;
     
   case GeomAbs_NoneIso:
-    Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+    throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
     break;
   }
 }
@@ -452,7 +448,7 @@ void Adaptor3d_IsoCurve::D1(const Standard_Real T, gp_Pnt& P, gp_Vec& V) const
     break;
     
   case GeomAbs_NoneIso:
-    Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+    throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
     break;
   }
 }
@@ -477,7 +473,7 @@ void Adaptor3d_IsoCurve::D2(const Standard_Real T, gp_Pnt& P,
                  P,V1,dummy1,V2,dummy2,dummy3);
     break;
   case GeomAbs_NoneIso:
-    Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+    throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
     break;
   }
 }
@@ -504,7 +500,7 @@ void Adaptor3d_IsoCurve::D3(const Standard_Real T, gp_Pnt& P,
     break;
     
   case GeomAbs_NoneIso:
-    Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+    throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
     break;
   }
 }
@@ -525,7 +521,7 @@ gp_Vec Adaptor3d_IsoCurve::DN(const Standard_Real T,
     return mySurface->DN(T,myParameter,N,0);
   case GeomAbs_NoneIso:
     {
-      Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+      throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
       break;
     }
   }
@@ -572,9 +568,7 @@ GeomAbs_CurveType Adaptor3d_IsoCurve::GetType() const {
        
       case GeomAbs_NoneIso:
        {
-         Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
-         // portage WNT
-         return GeomAbs_OtherCurve;
+         throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
        }
       }
       break;
@@ -600,9 +594,7 @@ GeomAbs_CurveType Adaptor3d_IsoCurve::GetType() const {
        return GeomAbs_Circle;
        
       case GeomAbs_NoneIso:
-       Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
-       // portage WNT
-       return GeomAbs_OtherCurve;
+       throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
        break;
       }
       break;
@@ -618,9 +610,7 @@ GeomAbs_CurveType Adaptor3d_IsoCurve::GetType() const {
        return mySurface->BasisCurve()->GetType();
        
       case GeomAbs_NoneIso:
-       Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
-       // portage WNT
-       return GeomAbs_OtherCurve;
+       throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
        break;
       }
       break;
@@ -681,8 +671,7 @@ gp_Circ Adaptor3d_IsoCurve::Circle() const
        
       case GeomAbs_IsoU: 
        {
-         Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:UIso");
-         return gp_Circ();
+         throw Standard_NoSuchObject("Adaptor3d_IsoCurve:UIso");
        }
       case GeomAbs_IsoV: 
        {
@@ -690,8 +679,7 @@ gp_Circ Adaptor3d_IsoCurve::Circle() const
        }
       case GeomAbs_NoneIso: 
        {
-         Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
-         return gp_Circ();
+         throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
        }
       }
       break;
@@ -705,8 +693,7 @@ gp_Circ Adaptor3d_IsoCurve::Circle() const
        
       case GeomAbs_IsoU: 
        {
-         Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:UIso");
-         return gp_Circ();
+         throw Standard_NoSuchObject("Adaptor3d_IsoCurve:UIso");
        }
       case GeomAbs_IsoV: 
        {
@@ -715,8 +702,7 @@ gp_Circ Adaptor3d_IsoCurve::Circle() const
        }
       case GeomAbs_NoneIso: 
        {
-         Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
-         return gp_Circ();
+         throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
        }
       }
       break;
@@ -740,8 +726,7 @@ gp_Circ Adaptor3d_IsoCurve::Circle() const
        
       case GeomAbs_NoneIso: 
        {
-         Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
-         return gp_Circ();
+         throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
        }
       }
       break;
@@ -766,8 +751,7 @@ gp_Circ Adaptor3d_IsoCurve::Circle() const
       
     case GeomAbs_NoneIso: 
       {
-       Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
-       return gp_Circ();
+       throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
       }
     }
     break;
@@ -802,8 +786,7 @@ gp_Circ Adaptor3d_IsoCurve::Circle() const
   }
   default:  
     {
-      Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:Circle");
-      return gp_Circ();
+      throw Standard_NoSuchObject("Adaptor3d_IsoCurve:Circle");
     }
     
   }
@@ -826,10 +809,9 @@ gp_Elips Adaptor3d_IsoCurve::Ellipse() const
   }
   default:  
     {
-      Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:Ellipse");
+      throw Standard_NoSuchObject("Adaptor3d_IsoCurve:Ellipse");
     } 
   }
-  return gp_Elips();
 }
 
 //=======================================================================
@@ -839,8 +821,7 @@ gp_Elips Adaptor3d_IsoCurve::Ellipse() const
 
 gp_Hypr Adaptor3d_IsoCurve::Hyperbola() const
 {
-  Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:Hyperbola");
-  return gp_Hypr();
+  throw Standard_NoSuchObject("Adaptor3d_IsoCurve:Hyperbola");
 }
 
 //=======================================================================
@@ -850,8 +831,7 @@ gp_Hypr Adaptor3d_IsoCurve::Hyperbola() const
 
 gp_Parab Adaptor3d_IsoCurve::Parabola() const
 {
-  Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:Parabola");
-  return gp_Parab();
+  throw Standard_NoSuchObject("Adaptor3d_IsoCurve:Parabola");
 }
 
 //=======================================================================
@@ -877,7 +857,7 @@ Standard_Integer Adaptor3d_IsoCurve::Degree() const
        
       case GeomAbs_NoneIso:
       default:
-       Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+       throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
       }        
     }
     break ;
@@ -888,7 +868,7 @@ Standard_Integer Adaptor3d_IsoCurve::Degree() const
        degree = mySurface->BasisCurve()->Degree();
        break;
       default:
-       Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+       throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
       }
     }
     break;
@@ -899,12 +879,12 @@ Standard_Integer Adaptor3d_IsoCurve::Degree() const
        degree = mySurface->BasisCurve()->Degree();
        break;
       default:
-       Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+       throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
       }
     }
     break;
   default:
-    Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+    throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
     break ;
   }
   return degree ;
@@ -933,7 +913,7 @@ Standard_Boolean Adaptor3d_IsoCurve::IsRational() const
        
       case GeomAbs_NoneIso:
       default:
-       Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+       throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
       }        
     }
     break ;
@@ -944,7 +924,7 @@ Standard_Boolean Adaptor3d_IsoCurve::IsRational() const
        is_rational = mySurface->BasisCurve()->IsRational();
        break;
       default:
-       Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+       throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
       }
     }
     break;
@@ -955,12 +935,12 @@ Standard_Boolean Adaptor3d_IsoCurve::IsRational() const
        is_rational = mySurface->BasisCurve()->IsRational();
        break;
       default:
-       Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+       throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
       }
     }
     break;
   default:
-    Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+    throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
   }
   return is_rational;
 }      
@@ -988,7 +968,7 @@ Standard_Integer Adaptor3d_IsoCurve::NbPoles() const
       
     case GeomAbs_NoneIso:
     default:
-      Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+      throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
     }  
     break ;
   case GeomAbs_SurfaceOfRevolution: 
@@ -1000,7 +980,7 @@ Standard_Integer Adaptor3d_IsoCurve::NbPoles() const
        }
        break;
       default:
-       Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+       throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
       }
     }
     break;
@@ -1013,13 +993,13 @@ Standard_Integer Adaptor3d_IsoCurve::NbPoles() const
        }
        break;
       default:
-       Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+       throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
       }
     }
     break;
 
   default:
-    Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+    throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
     break ;
   }
  return nb_poles ;
@@ -1047,7 +1027,7 @@ Standard_Integer Adaptor3d_IsoCurve::NbKnots() const
        
       case GeomAbs_NoneIso:
       default:
-       Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+       throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
       }        
     }
     break ;
@@ -1060,7 +1040,7 @@ Standard_Integer Adaptor3d_IsoCurve::NbKnots() const
          break ;
        }
       default:
-       Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+       throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
       }        
     }
     break ;
@@ -1073,12 +1053,12 @@ Standard_Integer Adaptor3d_IsoCurve::NbKnots() const
          break ;
        }
       default:
-       Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+       throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
       }        
     }
     break ;
   default:
-    Standard_NoSuchObject::Raise("Adaptor3d_IsoCurve:NoneIso");
+    throw Standard_NoSuchObject("Adaptor3d_IsoCurve:NoneIso");
     break ;
   }
   return nb_knots ;
index 4c15f07..42adac7 100644 (file)
@@ -49,8 +49,7 @@ Adaptor3d_Surface::~Adaptor3d_Surface()
 
 Standard_Real Adaptor3d_Surface::FirstUParameter() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::FirstUParameter");
-  return 0.;
+  throw Standard_NotImplemented("Adaptor3d_Surface::FirstUParameter");
 }
 
 
@@ -61,8 +60,7 @@ Standard_Real Adaptor3d_Surface::FirstUParameter() const
 
 Standard_Real Adaptor3d_Surface::LastUParameter() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::LastUParameter");
-  return 0.;
+  throw Standard_NotImplemented("Adaptor3d_Surface::LastUParameter");
 }
 
 
@@ -73,8 +71,7 @@ Standard_Real Adaptor3d_Surface::LastUParameter() const
 
 Standard_Real Adaptor3d_Surface::FirstVParameter() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::FirstVParameter");
-  return 0.;
+  throw Standard_NotImplemented("Adaptor3d_Surface::FirstVParameter");
 }
 
 
@@ -85,8 +82,7 @@ Standard_Real Adaptor3d_Surface::FirstVParameter() const
 
 Standard_Real Adaptor3d_Surface::LastVParameter() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::LastVParameter");
-  return 0.;
+  throw Standard_NotImplemented("Adaptor3d_Surface::LastVParameter");
 }
 
 
@@ -97,8 +93,7 @@ Standard_Real Adaptor3d_Surface::LastVParameter() const
 
 GeomAbs_Shape Adaptor3d_Surface::UContinuity() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::UContinuity");
-  return GeomAbs_C0;
+  throw Standard_NotImplemented("Adaptor3d_Surface::UContinuity");
 }
 
 
@@ -109,8 +104,7 @@ GeomAbs_Shape Adaptor3d_Surface::UContinuity() const
 
 GeomAbs_Shape Adaptor3d_Surface::VContinuity() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::VContinuity");
-  return GeomAbs_C0;
+  throw Standard_NotImplemented("Adaptor3d_Surface::VContinuity");
 }
 
 
@@ -122,8 +116,7 @@ GeomAbs_Shape Adaptor3d_Surface::VContinuity() const
 //Standard_Integer Adaptor3d_Surface::NbUIntervals(const GeomAbs_Shape S) const 
 Standard_Integer Adaptor3d_Surface::NbUIntervals(const GeomAbs_Shape ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::NbUIntervals");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Surface::NbUIntervals");
 }
 
 
@@ -135,8 +128,7 @@ Standard_Integer Adaptor3d_Surface::NbUIntervals(const GeomAbs_Shape ) const
 //Standard_Integer Adaptor3d_Surface::NbVIntervals(const GeomAbs_Shape S) const 
 Standard_Integer Adaptor3d_Surface::NbVIntervals(const GeomAbs_Shape ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::NbVIntervals");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Surface::NbVIntervals");
 }
 
 
@@ -148,7 +140,7 @@ Standard_Integer Adaptor3d_Surface::NbVIntervals(const GeomAbs_Shape ) const
 //void Adaptor3d_Surface::UIntervals(TColStd_Array1OfReal& T, const GeomAbs_Shape S) const 
 void Adaptor3d_Surface::UIntervals(TColStd_Array1OfReal& , const GeomAbs_Shape ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::UIntervals");
+  throw Standard_NotImplemented("Adaptor3d_Surface::UIntervals");
 }
 
 
@@ -160,7 +152,7 @@ void Adaptor3d_Surface::UIntervals(TColStd_Array1OfReal& , const GeomAbs_Shape )
 //void Adaptor3d_Surface::VIntervals(TColStd_Array1OfReal& T, const GeomAbs_Shape S) const 
 void Adaptor3d_Surface::VIntervals(TColStd_Array1OfReal& , const GeomAbs_Shape ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::VIntervals");
+  throw Standard_NotImplemented("Adaptor3d_Surface::VIntervals");
 }
 
 
@@ -172,8 +164,7 @@ void Adaptor3d_Surface::VIntervals(TColStd_Array1OfReal& , const GeomAbs_Shape )
 //Handle(Adaptor3d_HSurface) Adaptor3d_Surface::UTrim(const Standard_Real First, const Standard_Real Last, const Standard_Real Tol) const 
 Handle(Adaptor3d_HSurface) Adaptor3d_Surface::UTrim(const Standard_Real , const Standard_Real , const Standard_Real ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::UTrim");
-  return Handle(Adaptor3d_HSurface)();
+  throw Standard_NotImplemented("Adaptor3d_Surface::UTrim");
 }
 
 
@@ -185,8 +176,7 @@ Handle(Adaptor3d_HSurface) Adaptor3d_Surface::UTrim(const Standard_Real , const
 //Handle(Adaptor3d_HSurface) Adaptor3d_Surface::VTrim(const Standard_Real First, const Standard_Real Last, const Standard_Real Tol) const 
 Handle(Adaptor3d_HSurface) Adaptor3d_Surface::VTrim(const Standard_Real , const Standard_Real , const Standard_Real ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::VTrim");
-  return Handle(Adaptor3d_HSurface)();
+  throw Standard_NotImplemented("Adaptor3d_Surface::VTrim");
 }
 
 
@@ -197,8 +187,7 @@ Handle(Adaptor3d_HSurface) Adaptor3d_Surface::VTrim(const Standard_Real , const
 
 Standard_Boolean Adaptor3d_Surface::IsUClosed() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::IsUClosed");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Surface::IsUClosed");
 }
 
 
@@ -209,8 +198,7 @@ Standard_Boolean Adaptor3d_Surface::IsUClosed() const
 
 Standard_Boolean Adaptor3d_Surface::IsVClosed() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::IsVClosed");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Surface::IsVClosed");
 }
 
 
@@ -221,8 +209,7 @@ Standard_Boolean Adaptor3d_Surface::IsVClosed() const
 
 Standard_Boolean Adaptor3d_Surface::IsUPeriodic() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::IsUPeriodic");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Surface::IsUPeriodic");
 }
 
 
@@ -233,8 +220,7 @@ Standard_Boolean Adaptor3d_Surface::IsUPeriodic() const
 
 Standard_Real Adaptor3d_Surface::UPeriod() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::UPeriod");
-  return 0.;
+  throw Standard_NotImplemented("Adaptor3d_Surface::UPeriod");
 }
 
 
@@ -245,8 +231,7 @@ Standard_Real Adaptor3d_Surface::UPeriod() const
 
 Standard_Boolean Adaptor3d_Surface::IsVPeriodic() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::IsVPeriodic");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Surface::IsVPeriodic");
 }
 
 
@@ -257,8 +242,7 @@ Standard_Boolean Adaptor3d_Surface::IsVPeriodic() const
 
 Standard_Real Adaptor3d_Surface::VPeriod() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::VPeriod");
-  return 0.;
+  throw Standard_NotImplemented("Adaptor3d_Surface::VPeriod");
 }
 
 
@@ -270,8 +254,7 @@ Standard_Real Adaptor3d_Surface::VPeriod() const
 //gp_Pnt Adaptor3d_Surface::Value(const Standard_Real U, const Standard_Real V) const 
 gp_Pnt Adaptor3d_Surface::Value(const Standard_Real , const Standard_Real ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::Value");
-  return gp_Pnt();
+  throw Standard_NotImplemented("Adaptor3d_Surface::Value");
 }
 
 
@@ -283,7 +266,7 @@ gp_Pnt Adaptor3d_Surface::Value(const Standard_Real , const Standard_Real ) cons
 //void Adaptor3d_Surface::D0(const Standard_Real U, const Standard_Real V, gp_Pnt& P) const 
 void Adaptor3d_Surface::D0(const Standard_Real , const Standard_Real , gp_Pnt& ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::D0");
+  throw Standard_NotImplemented("Adaptor3d_Surface::D0");
 }
 
 
@@ -295,7 +278,7 @@ void Adaptor3d_Surface::D0(const Standard_Real , const Standard_Real , gp_Pnt& )
 //void Adaptor3d_Surface::D1(const Standard_Real U, const Standard_Real V, gp_Pnt& P, gp_Vec& D1U, gp_Vec& D1V) const 
 void Adaptor3d_Surface::D1(const Standard_Real , const Standard_Real , gp_Pnt& , gp_Vec& , gp_Vec& ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::D1");
+  throw Standard_NotImplemented("Adaptor3d_Surface::D1");
 }
 
 
@@ -307,7 +290,7 @@ void Adaptor3d_Surface::D1(const Standard_Real , const Standard_Real , gp_Pnt& ,
 //void Adaptor3d_Surface::D2(const Standard_Real U, const Standard_Real V, gp_Pnt& P, gp_Vec& D1U, gp_Vec& D1V, gp_Vec& D2U, gp_Vec& D2V, gp_Vec& D2UV) const 
 void Adaptor3d_Surface::D2(const Standard_Real , const Standard_Real , gp_Pnt& , gp_Vec& , gp_Vec& , gp_Vec& , gp_Vec& , gp_Vec& ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::D2");
+  throw Standard_NotImplemented("Adaptor3d_Surface::D2");
 }
 
 
@@ -319,7 +302,7 @@ void Adaptor3d_Surface::D2(const Standard_Real , const Standard_Real , gp_Pnt& ,
 //void Adaptor3d_Surface::D3(const Standard_Real U, const Standard_Real V, gp_Pnt& P, gp_Vec& D1U, gp_Vec& D1V, gp_Vec& D2U, gp_Vec& D2V, gp_Vec& D2UV, gp_Vec& D3U, gp_Vec& D3V, gp_Vec& D3UUV, gp_Vec& D3UVV) const 
 void Adaptor3d_Surface::D3(const Standard_Real , const Standard_Real , gp_Pnt& , gp_Vec& , gp_Vec& , gp_Vec& , gp_Vec& , gp_Vec& , gp_Vec& , gp_Vec& , gp_Vec& , gp_Vec& ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::D3");
+  throw Standard_NotImplemented("Adaptor3d_Surface::D3");
 }
 
 
@@ -331,8 +314,7 @@ void Adaptor3d_Surface::D3(const Standard_Real , const Standard_Real , gp_Pnt& ,
 //gp_Vec Adaptor3d_Surface::DN(const Standard_Real U, const Standard_Real V, const Standard_Integer Nu, const Standard_Integer Nv) const 
 gp_Vec Adaptor3d_Surface::DN(const Standard_Real , const Standard_Real , const Standard_Integer , const Standard_Integer ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::DN");
-  return gp_Vec();
+  throw Standard_NotImplemented("Adaptor3d_Surface::DN");
 }
 
 
@@ -344,8 +326,7 @@ gp_Vec Adaptor3d_Surface::DN(const Standard_Real , const Standard_Real , const S
 //Standard_Real Adaptor3d_Surface::UResolution(const Standard_Real R3d) const 
 Standard_Real Adaptor3d_Surface::UResolution(const Standard_Real ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::UResolution");
-  return 0.;
+  throw Standard_NotImplemented("Adaptor3d_Surface::UResolution");
 }
 
 
@@ -357,8 +338,7 @@ Standard_Real Adaptor3d_Surface::UResolution(const Standard_Real ) const
 //Standard_Real Adaptor3d_Surface::VResolution(const Standard_Real R3d) const 
 Standard_Real Adaptor3d_Surface::VResolution(const Standard_Real ) const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::VResolution");
-  return 0.;
+  throw Standard_NotImplemented("Adaptor3d_Surface::VResolution");
 }
 
 
@@ -369,8 +349,7 @@ Standard_Real Adaptor3d_Surface::VResolution(const Standard_Real ) const
 
 GeomAbs_SurfaceType Adaptor3d_Surface::GetType() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::GetType");
-  return GeomAbs_OtherSurface;
+  throw Standard_NotImplemented("Adaptor3d_Surface::GetType");
 }
 
 
@@ -381,8 +360,7 @@ GeomAbs_SurfaceType Adaptor3d_Surface::GetType() const
 
 gp_Pln Adaptor3d_Surface::Plane() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::Plane");
-  return gp_Pln();
+  throw Standard_NotImplemented("Adaptor3d_Surface::Plane");
 }
 
 
@@ -393,8 +371,7 @@ gp_Pln Adaptor3d_Surface::Plane() const
 
 gp_Cylinder Adaptor3d_Surface::Cylinder() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::Cylinder");
-  return gp_Cylinder();
+  throw Standard_NotImplemented("Adaptor3d_Surface::Cylinder");
 }
 
 
@@ -405,8 +382,7 @@ gp_Cylinder Adaptor3d_Surface::Cylinder() const
 
 gp_Cone Adaptor3d_Surface::Cone() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::Cone");
-  return gp_Cone();
+  throw Standard_NotImplemented("Adaptor3d_Surface::Cone");
 }
 
 
@@ -417,8 +393,7 @@ gp_Cone Adaptor3d_Surface::Cone() const
 
 gp_Sphere Adaptor3d_Surface::Sphere() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::Sphere");
-  return gp_Sphere();
+  throw Standard_NotImplemented("Adaptor3d_Surface::Sphere");
 }
 
 
@@ -429,8 +404,7 @@ gp_Sphere Adaptor3d_Surface::Sphere() const
 
 gp_Torus Adaptor3d_Surface::Torus() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::Torus");
-  return gp_Torus();
+  throw Standard_NotImplemented("Adaptor3d_Surface::Torus");
 }
 
 
@@ -441,8 +415,7 @@ gp_Torus Adaptor3d_Surface::Torus() const
 
 Standard_Integer Adaptor3d_Surface::UDegree() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::UDegree");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Surface::UDegree");
 }
 
 
@@ -453,8 +426,7 @@ Standard_Integer Adaptor3d_Surface::UDegree() const
 
 Standard_Integer Adaptor3d_Surface::NbUPoles() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::NbUPoles");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Surface::NbUPoles");
 }
 
 
@@ -465,8 +437,7 @@ Standard_Integer Adaptor3d_Surface::NbUPoles() const
 
 Standard_Integer Adaptor3d_Surface::VDegree() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::VDegree");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Surface::VDegree");
 }
 
 
@@ -477,8 +448,7 @@ Standard_Integer Adaptor3d_Surface::VDegree() const
 
 Standard_Integer Adaptor3d_Surface::NbVPoles() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::NbVPoles");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Surface::NbVPoles");
 }
 
 
@@ -489,8 +459,7 @@ Standard_Integer Adaptor3d_Surface::NbVPoles() const
 
 Standard_Integer Adaptor3d_Surface::NbUKnots() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::NbUKnots");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Surface::NbUKnots");
 }
 
 
@@ -501,8 +470,7 @@ Standard_Integer Adaptor3d_Surface::NbUKnots() const
 
 Standard_Integer Adaptor3d_Surface::NbVKnots() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::NbVKnots");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Surface::NbVKnots");
 }
 
 
@@ -513,8 +481,7 @@ Standard_Integer Adaptor3d_Surface::NbVKnots() const
 
 Standard_Boolean Adaptor3d_Surface::IsURational() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::IsURational");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Surface::IsURational");
 }
 
 
@@ -525,8 +492,7 @@ Standard_Boolean Adaptor3d_Surface::IsURational() const
 
 Standard_Boolean Adaptor3d_Surface::IsVRational() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::IsVRational");
-  return 0;
+  throw Standard_NotImplemented("Adaptor3d_Surface::IsVRational");
 }
 
 
@@ -537,8 +503,7 @@ Standard_Boolean Adaptor3d_Surface::IsVRational() const
 
 Handle(Geom_BezierSurface) Adaptor3d_Surface::Bezier() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::Bezier");
-  return Handle(Geom_BezierSurface)();
+  throw Standard_NotImplemented("Adaptor3d_Surface::Bezier");
 }
 
 
@@ -549,8 +514,7 @@ Handle(Geom_BezierSurface) Adaptor3d_Surface::Bezier() const
 
 Handle(Geom_BSplineSurface) Adaptor3d_Surface::BSpline() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::BSpline");
-  return Handle(Geom_BSplineSurface)();
+  throw Standard_NotImplemented("Adaptor3d_Surface::BSpline");
 }
 
 
@@ -561,8 +525,7 @@ Handle(Geom_BSplineSurface) Adaptor3d_Surface::BSpline() const
 
 gp_Ax1 Adaptor3d_Surface::AxeOfRevolution() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::AxeOfRevolution");
-  return gp_Ax1();
+  throw Standard_NotImplemented("Adaptor3d_Surface::AxeOfRevolution");
 }
 
 
@@ -573,8 +536,7 @@ gp_Ax1 Adaptor3d_Surface::AxeOfRevolution() const
 
 gp_Dir Adaptor3d_Surface::Direction() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::Direction");
-  return gp_Dir();
+  throw Standard_NotImplemented("Adaptor3d_Surface::Direction");
 }
 
 
@@ -585,8 +547,7 @@ gp_Dir Adaptor3d_Surface::Direction() const
 
 Handle(Adaptor3d_HCurve) Adaptor3d_Surface::BasisCurve() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::BasisCurve");
-  return Handle(Adaptor3d_HCurve)();
+  throw Standard_NotImplemented("Adaptor3d_Surface::BasisCurve");
 }
 
 
@@ -597,8 +558,7 @@ Handle(Adaptor3d_HCurve) Adaptor3d_Surface::BasisCurve() const
 
 Handle(Adaptor3d_HSurface) Adaptor3d_Surface::BasisSurface() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::BasisSurface");
-  return Handle(Adaptor3d_HSurface)();
+  throw Standard_NotImplemented("Adaptor3d_Surface::BasisSurface");
 }
 
 
@@ -609,6 +569,5 @@ Handle(Adaptor3d_HSurface) Adaptor3d_Surface::BasisSurface() const
 
 Standard_Real Adaptor3d_Surface::OffsetValue() const 
 {
-  Standard_NotImplemented::Raise("Adaptor3d_Surface::OffsetValue");
-  return 0.;
+  throw Standard_NotImplemented("Adaptor3d_Surface::OffsetValue");
 }
index a42d633..536ad16 100644 (file)
@@ -73,7 +73,7 @@ Adaptor3d_TopolTool::Adaptor3d_TopolTool (const Handle(Adaptor3d_HSurface)& S)
 
 void Adaptor3d_TopolTool::Initialize ()
 {
Standard_NotImplemented::Raise("Adaptor3d_TopolTool::Initialize ()");
throw Standard_NotImplemented("Adaptor3d_TopolTool::Initialize ()");
 }
 
 void Adaptor3d_TopolTool::Initialize (const Handle(Adaptor3d_HSurface)& S)
@@ -222,7 +222,7 @@ Standard_Boolean Adaptor3d_TopolTool::More ()
 
 Handle(Adaptor2d_HCurve2d) Adaptor3d_TopolTool::Value ()
 {
-  if (idRestr >= nbRestr) {Standard_DomainError::Raise();}
+  if (idRestr >= nbRestr) {throw Standard_DomainError();}
   return myRestr[idRestr];
 }
 
@@ -266,7 +266,7 @@ Standard_Boolean Adaptor3d_TopolTool::MoreVertex ()
 
 Handle(Adaptor3d_HVertex) Adaptor3d_TopolTool::Vertex ()
 {
-  if (idVtx >= nbVtx) {Standard_DomainError::Raise();}
+  if (idVtx >= nbVtx) {throw Standard_DomainError();}
   return myVtx[idVtx];
 }
 
@@ -812,8 +812,7 @@ Standard_Boolean Adaptor3d_TopolTool::Has3d() const
 
 Standard_Real Adaptor3d_TopolTool::Tol3d(const Handle(Adaptor2d_HCurve2d)&) const
 {
-  Standard_DomainError::Raise("Adaptor3d_TopolTool: has no 3d representation");
-  return 0.;
+  throw Standard_DomainError("Adaptor3d_TopolTool: has no 3d representation");
 }
 
 //=======================================================================
@@ -823,8 +822,7 @@ Standard_Real Adaptor3d_TopolTool::Tol3d(const Handle(Adaptor2d_HCurve2d)&) cons
 
 Standard_Real Adaptor3d_TopolTool::Tol3d(const Handle(Adaptor3d_HVertex)&) const
 {
-  Standard_DomainError::Raise("Adaptor3d_TopolTool: has no 3d representation");
-  return 0.;
+  throw Standard_DomainError("Adaptor3d_TopolTool: has no 3d representation");
 }
 
 //=======================================================================
@@ -834,8 +832,7 @@ Standard_Real Adaptor3d_TopolTool::Tol3d(const Handle(Adaptor3d_HVertex)&) const
 
 gp_Pnt Adaptor3d_TopolTool::Pnt(const Handle(Adaptor3d_HVertex)&) const
 {
-  Standard_DomainError::Raise("Adaptor3d_TopolTool: has no 3d representation");
-  return gp::Origin();
+  throw Standard_DomainError("Adaptor3d_TopolTool: has no 3d representation");
 }
 
 
index 92423d9..109b9d4 100644 (file)
@@ -197,7 +197,7 @@ void AdvApp2Var_ApproxAFunc2Var::Init()
     iu = 2;
     break;
   default :
-    Standard_ConstructionError::Raise("AdvApp2Var_ApproxAFunc2Var : UContinuity Error");
+    throw Standard_ConstructionError("AdvApp2Var_ApproxAFunc2Var : UContinuity Error");
   }
   switch (myContInV) {
   case GeomAbs_C0 :
@@ -210,14 +210,14 @@ void AdvApp2Var_ApproxAFunc2Var::Init()
     iv = 2;
     break;
   default :
-    Standard_ConstructionError::Raise("AdvApp2Var_ApproxAFunc2Var : VContinuity Error");
+    throw Standard_ConstructionError("AdvApp2Var_ApproxAFunc2Var : VContinuity Error");
   }
   ndu = Max(myMaxDegInU+1,2*iu+2);
   ndv = Max(myMaxDegInV+1,2*iv+2);
   if (ndu<2*iu+2)
-    Standard_ConstructionError::Raise("AdvApp2Var_ApproxAFunc2Var : UMaxDegree Error");
+    throw Standard_ConstructionError("AdvApp2Var_ApproxAFunc2Var : UMaxDegree Error");
   if (ndv<2*iv+2)
-    Standard_ConstructionError::Raise("AdvApp2Var_ApproxAFunc2Var : VMaxDegree Error");
+    throw Standard_ConstructionError("AdvApp2Var_ApproxAFunc2Var : VMaxDegree Error");
   myPrecisionCode = Max(0,Min(myPrecisionCode,3));
   AdvApp2Var_Context Conditions(ifav,iu,iv,ndu,ndv,
                                myPrecisionCode,
@@ -363,8 +363,7 @@ void AdvApp2Var_ApproxAFunc2Var::ComputePatches(const AdvApprox_Cutting& UChoice
     myResult(FirstNA).Discretise(myConditions,myConstraints,Func);
     if ( ! myResult(FirstNA).IsDiscretised() ) {
       myHasResult =  myDone = Standard_False;
-      Standard_ConstructionError::Raise
-              ("AdvApp2Var_ApproxAFunc2Var : Surface Discretisation Error");
+      throw Standard_ConstructionError("AdvApp2Var_ApproxAFunc2Var : Surface Discretisation Error");
     }
 
 // calculate the number and the type of autorized cuts
@@ -403,8 +402,7 @@ void AdvApp2Var_ApproxAFunc2Var::ComputePatches(const AdvApprox_Cutting& UChoice
         }
         else {
           myHasResult =  myDone = Standard_False;
-          Standard_ConstructionError::Raise
-              ("AdvApp2Var_ApproxAFunc2Var : Surface Approximation Error");
+          throw Standard_ConstructionError("AdvApp2Var_ApproxAFunc2Var : Surface Approximation Error");
         }
        break;
       case 1 :
@@ -426,8 +424,7 @@ void AdvApp2Var_ApproxAFunc2Var::ComputePatches(const AdvApprox_Cutting& UChoice
        break;
       default :
         myHasResult =  myDone = Standard_False;
-        Standard_ConstructionError::Raise
-              ("AdvApp2Var_ApproxAFunc2Var : Surface Approximation Error");
+        throw Standard_ConstructionError("AdvApp2Var_ApproxAFunc2Var : Surface Approximation Error");
       }
     }
   }
@@ -460,8 +457,7 @@ void AdvApp2Var_ApproxAFunc2Var::ComputePatches(const AdvApprox_Cutting& UChoice
     myResult(FirstNA).Discretise(myConditions,myConstraints,Func);
     if ( ! myResult(FirstNA).IsDiscretised() ) {
       myHasResult =  myDone = Standard_False;
-      Standard_ConstructionError::Raise
-              ("AdvApp2Var_ApproxAFunc2Var : Surface Discretisation Error");
+      throw Standard_ConstructionError("AdvApp2Var_ApproxAFunc2Var : Surface Discretisation Error");
     }
 
 // calculate the number and type of autorized cuts
@@ -521,8 +517,7 @@ void AdvApp2Var_ApproxAFunc2Var::ComputePatches(const AdvApprox_Cutting& UChoice
        }
        else {
          myHasResult =  myDone = Standard_False;
-         Standard_ConstructionError::Raise
-           ("AdvApp2Var_ApproxAFunc2Var : Surface Approximation Error");
+         throw Standard_ConstructionError("AdvApp2Var_ApproxAFunc2Var : Surface Approximation Error");
        }
        break;
       case 1 :
@@ -544,8 +539,7 @@ void AdvApp2Var_ApproxAFunc2Var::ComputePatches(const AdvApprox_Cutting& UChoice
        break;
        default :
        myHasResult =  myDone = Standard_False;
-       Standard_ConstructionError::Raise
-         ("AdvApp2Var_ApproxAFunc2Var : Surface Approximation Error");
+       throw Standard_ConstructionError("AdvApp2Var_ApproxAFunc2Var : Surface Approximation Error");
       }
     }
   }
@@ -623,8 +617,7 @@ void AdvApp2Var_ApproxAFunc2Var::ComputeConstraints(const AdvApprox_Cutting& UCh
        }
        else {
          myHasResult =  myDone = Standard_False;
-         Standard_ConstructionError::Raise
-           ("AdvApp2Var_ApproxAFunc2Var : Curve Approximation Error");
+         throw Standard_ConstructionError("AdvApp2Var_ApproxAFunc2Var : Curve Approximation Error");
        }
       }
     }
@@ -708,8 +701,7 @@ void AdvApp2Var_ApproxAFunc2Var::ComputeConstraints(const AdvApprox_Cutting& UCh
           }
           else {
            myHasResult =  myDone = Standard_False;
-           Standard_ConstructionError::Raise
-              ("AdvApp2Var_ApproxAFunc2Var : Curve Approximation Error");
+           throw Standard_ConstructionError("AdvApp2Var_ApproxAFunc2Var : Curve Approximation Error");
           }
        }
       }
@@ -880,8 +872,7 @@ Handle(TColStd_HArray1OfReal)
 {
   Handle (TColStd_HArray1OfReal) EPtr;
   if (Dimension <1 || Dimension >3) {
-    Standard_OutOfRange::Raise
-      ("AdvApp2Var_ApproxAFunc2Var::MaxError : Dimension must be equal to 1,2 or 3 !");
+    throw Standard_OutOfRange("AdvApp2Var_ApproxAFunc2Var::MaxError : Dimension must be equal to 1,2 or 3 !");
   }
   switch (Dimension) {
   case 1:
@@ -907,8 +898,7 @@ Handle(TColStd_HArray1OfReal)
 {
   Handle (TColStd_HArray1OfReal) EPtr;
   if (Dimension <1 || Dimension >3) {
-    Standard_OutOfRange::Raise
-      ("AdvApp2Var_ApproxAFunc2Var::AverageError : Dimension must be equal to 1,2 or 3 !");
+    throw Standard_OutOfRange("AdvApp2Var_ApproxAFunc2Var::AverageError : Dimension must be equal to 1,2 or 3 !");
   }
   switch (Dimension) {
   case 1:
@@ -934,8 +924,7 @@ Handle(TColStd_HArray1OfReal)
 {
   Handle (TColStd_HArray1OfReal) EPtr;
   if (Dimension <1 || Dimension >3) {
-    Standard_OutOfRange::Raise
-      ("AdvApp2Var_ApproxAFunc2Var::UFrontError : Dimension must be equal to 1,2 or 3 !");
+    throw Standard_OutOfRange("AdvApp2Var_ApproxAFunc2Var::UFrontError : Dimension must be equal to 1,2 or 3 !");
   }
   switch (Dimension) {
   case 1:
@@ -961,8 +950,7 @@ Handle(TColStd_HArray1OfReal)
 {
   Handle (TColStd_HArray1OfReal) EPtr;
   if (Dimension <=0 || Dimension >3) {
-    Standard_OutOfRange::Raise
-      ("AdvApp2Var_ApproxAFunc2Var::VFrontError : Dimension must be equal to 1,2 or 3 !");
+    throw Standard_OutOfRange("AdvApp2Var_ApproxAFunc2Var::VFrontError : Dimension must be equal to 1,2 or 3 !");
   }
   switch (Dimension) {
   case 1:
@@ -988,8 +976,7 @@ Standard_Real
                                      const Standard_Integer SSPIndex) const 
 {
   if (Dimension !=3 || SSPIndex !=1) {
-    Standard_OutOfRange::Raise
-      ("AdvApp2Var_ApproxAFunc2Var::MaxError: ONE Surface 3D only !");
+    throw Standard_OutOfRange("AdvApp2Var_ApproxAFunc2Var::MaxError: ONE Surface 3D only !");
   }
   Handle (TColStd_HArray1OfReal) EPtr = MaxError(Dimension);
   return EPtr->Value(SSPIndex);
@@ -1005,8 +992,7 @@ Standard_Real
                                          const Standard_Integer SSPIndex) const 
 {
   if (Dimension !=3 || SSPIndex !=1) {
-    Standard_OutOfRange::Raise
-      ("AdvApp2Var_ApproxAFunc2Var::AverageError : ONE Surface 3D only !");
+    throw Standard_OutOfRange("AdvApp2Var_ApproxAFunc2Var::AverageError : ONE Surface 3D only !");
   }
   Handle (TColStd_HArray1OfReal) EPtr = AverageError(Dimension);
   return EPtr->Value(SSPIndex);
@@ -1022,8 +1008,7 @@ Standard_Real
                                         const Standard_Integer SSPIndex) const 
 {
   if (Dimension !=3 || SSPIndex !=1) {
-    Standard_OutOfRange::Raise
-      ("AdvApp2Var_ApproxAFunc2Var::UFrontError : ONE Surface 3D only !");
+    throw Standard_OutOfRange("AdvApp2Var_ApproxAFunc2Var::UFrontError : ONE Surface 3D only !");
   }
   Handle (TColStd_HArray1OfReal) EPtr = UFrontError(Dimension);
   return EPtr->Value(SSPIndex);
@@ -1039,8 +1024,7 @@ Standard_Real
                                         const Standard_Integer SSPIndex) const 
 {
   if (Dimension !=3 || SSPIndex !=1) {
-    Standard_OutOfRange::Raise
-      ("AdvApp2Var_ApproxAFunc2Var::VFrontError : ONE Surface 3D only !");
+    throw Standard_OutOfRange("AdvApp2Var_ApproxAFunc2Var::VFrontError : ONE Surface 3D only !");
   }
   Handle (TColStd_HArray1OfReal) EPtr = VFrontError(Dimension);
   return EPtr->Value(SSPIndex);
@@ -1057,8 +1041,7 @@ Standard_Real
                                       const Standard_Integer SSPIndex) const 
 {
   if (Dimension !=3 || SSPIndex !=1) {
-    Standard_OutOfRange::Raise
-      ("AdvApp2Var_ApproxAFunc2Var::CritError: ONE Surface 3D only !");
+    throw Standard_OutOfRange("AdvApp2Var_ApproxAFunc2Var::CritError: ONE Surface 3D only !");
   }
   return myCriterionError;
 }
index 7a57352..a5fe953 100644 (file)
@@ -102,7 +102,7 @@ Standard_Integer ncfl;
 ncfl = nlimu;
 if (ncfl<2*iu+2) ncfl = 2*iu+2;
 if (!lesparam(iu,ncfl,iprecis,NbPntU,JDegU) )
-  { Standard_ConstructionError::Raise("AdvApp2Var_Context");}
+  { throw Standard_ConstructionError("AdvApp2Var_Context");}
 myNbURoot = NbPntU;
 myJDegU = JDegU;
 if (iu>-1) NbPntU = myNbURoot - 2;
@@ -121,7 +121,7 @@ ncfl = nlimv;
 if (ncfl<2*iv+2) ncfl = 2*iv+2;
 //Ma1nbp(&iv,&ncfl,&iprec,&NbPntV,&JDegV,&ErrorCode);
 if (!lesparam(iv, ncfl, iprecis, NbPntV, JDegV) )
-  { Standard_ConstructionError::Raise("AdvApp2Var_Context");}
+  { throw Standard_ConstructionError("AdvApp2Var_Context");}
 myNbVRoot = NbPntV;
 myJDegV = JDegV;
 if (iv>-1) NbPntV = myNbVRoot - 2;
@@ -156,7 +156,7 @@ Standard_Real *UG_array =
   (Standard_Real *) &UGauss->ChangeArray1()(UGauss->Lower());
 AdvApp2Var_ApproxF2var::mmapptt_(&JDegU,&NbPntU,&iu,UG_array,&ErrorCode);
 if (ErrorCode != 0 ) {
-  Standard_ConstructionError::Raise("AdvApp2Var_Context : Error in FORTRAN");
+  throw Standard_ConstructionError("AdvApp2Var_Context : Error in FORTRAN");
 }
 myUGauss = UGauss;
 
@@ -168,7 +168,7 @@ Standard_Real *VG_array =
   (Standard_Real *) &VGauss->ChangeArray1()(VGauss->Lower());
 AdvApp2Var_ApproxF2var::mmapptt_(&JDegV,&NbPntV,&iv,VG_array,&ErrorCode);
 if (ErrorCode != 0 ) {
-  Standard_ConstructionError::Raise("AdvApp2Var_Context : Error in FORTRAN");
+  throw Standard_ConstructionError("AdvApp2Var_Context : Error in FORTRAN");
 }
 myVGauss = VGauss;
 
index 7e9030f..c789d34 100644 (file)
@@ -502,8 +502,7 @@ void AdvApp2Var_Patch::AddConstraints(const AdvApp2Var_Context& Conditions,
   if (IORDRV>=0) {
     AdvApp2Var_ApproxF2var::mma1her_(&IORDRV,HermV,&IERCOD);
     if (IERCOD!=0) {
-      Standard_ConstructionError::Raise
-          ("AdvApp2Var_Patch::AddConstraints : Error in FORTRAN");
+      throw Standard_ConstructionError("AdvApp2Var_Patch::AddConstraints : Error in FORTRAN");
     }
     AdvApp2Var_ApproxF2var::mma2ac2_(&NDIMEN,
                                     &NDegU,
@@ -526,8 +525,7 @@ void AdvApp2Var_Patch::AddConstraints(const AdvApp2Var_Context& Conditions,
   if (IORDRU>=0) {
     AdvApp2Var_ApproxF2var::mma1her_(&IORDRU,HermU,&IERCOD);
     if (IERCOD!=0) {
-      Standard_ConstructionError::Raise
-          ("AdvApp2Var_Patch::AddConstraints : Error in FORTRAN");
+      throw Standard_ConstructionError("AdvApp2Var_Patch::AddConstraints : Error in FORTRAN");
     }
     AdvApp2Var_ApproxF2var::mma2ac3_(&NDIMEN,&NDegU,&NDegV,&IORDRU,&NCFLMV,
                                     NCFU0,IsoU0,NCFU1,IsoU1,HermU,PATCAN);
@@ -910,8 +908,7 @@ void AdvApp2Var_Patch::MakeApprox(const AdvApp2Var_Context& Conditions,
                                     &myNbCoeffInV,
                                     PATJAC,PATAUX,PATCAN,&IERCOD);
     if (IERCOD !=0) {
-      Standard_ConstructionError::Raise
-             ("AdvApp2Var_Patch::MakeApprox : Error in FORTRAN");
+      throw Standard_ConstructionError("AdvApp2Var_Patch::MakeApprox : Error in FORTRAN");
     }
     myEquation = HPCAN;
 
@@ -1173,8 +1170,7 @@ AdvApp2Var_Patch::Poles(const Standard_Integer SSPIndex,
     SousEquation = myEquation;
   }
   else {
-    Standard_ConstructionError::Raise
-               ("AdvApp2Var_Patch::Poles :  SSPIndex out of range");
+    throw Standard_ConstructionError("AdvApp2Var_Patch::Poles :  SSPIndex out of range");
   }
   Handle(TColStd_HArray1OfReal) Intervalle = 
     new (TColStd_HArray1OfReal) (1,2);
@@ -1214,8 +1210,7 @@ AdvApp2Var_Patch::Coefficients(const Standard_Integer SSPIndex,
     SousEquation = myEquation;
   }
   else {
-    Standard_ConstructionError::Raise
-               ("AdvApp2Var_Patch::Poles :  SSPIndex out of range");
+    throw Standard_ConstructionError("AdvApp2Var_Patch::Poles :  SSPIndex out of range");
   }
   return SousEquation;
 }
index 65cf620..33d45ff 100644 (file)
@@ -459,7 +459,7 @@ void AdvApprox_ApproxAFunction::Approximation(
          Continuity = GeomAbs_C2 ;
          break ;
       default:
-        Standard_ConstructionError::Raise();
+        throw Standard_ConstructionError();
   }
 
 //--------------------- Choix du nombre de points ----------------------
@@ -683,7 +683,7 @@ void AdvApprox_ApproxAFunction::Perform(const Standard_Integer Num1DSS,
       myLast < myFirst ||
       myMaxDegree < 1  ||
       myMaxSegments < 0)
-    Standard_ConstructionError::Raise(); 
+    throw Standard_ConstructionError();
   if (myMaxDegree > 14) { 
       myMaxDegree = 14 ;
   }
@@ -717,7 +717,7 @@ void AdvApprox_ApproxAFunction::Perform(const Standard_Integer Num1DSS,
     ContinuityOrder = 2 ;
     break ;
   default:
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   Standard_Real ApproxStartEnd[2] ;
   Standard_Integer NumMaxCoeffs = Max(myMaxDegree + 1, 2 * ContinuityOrder + 2);
@@ -1019,7 +1019,7 @@ Handle(TColStd_HArray1OfReal)
   if (D <= 0 ||
       D > 3) {
     
-    Standard_OutOfRange::Raise() ;
+    throw Standard_OutOfRange() ;
   }
   switch (D) {
   case 1:
@@ -1059,7 +1059,7 @@ Handle(TColStd_HArray1OfReal)
   if (D <= 0 ||
       D > 3) {
     
-    Standard_OutOfRange::Raise() ;
+    throw Standard_OutOfRange() ;
   }
   switch (D) {
   case 1:
index f56bf25..70f5757 100644 (file)
@@ -90,5 +90,5 @@ AdvApprox_ApproxAFunction::Multiplicities() const
 //=======================================================================
 
 inline Standard_Integer AdvApprox_ApproxAFunction::NumSubSpaces(const Standard_Integer Dimension)  const 
-{ if (Dimension < 1 || Dimension > 3) Standard_ConstructionError::Raise()  ;
+{ if (Dimension < 1 || Dimension > 3) throw Standard_ConstructionError()  ;
   return myNumSubSpaces[Dimension-1] ; }
index 08b50ed..2f85ed4 100644 (file)
@@ -28,7 +28,7 @@ AdvApprox_PrefAndRec::AdvApprox_PrefAndRec(const TColStd_Array1OfReal& RecCut,
 {
   myRecCutting =  RecCut;
   myPrefCutting =  PrefCut;
-  if (myWeight <= 1) { Standard_DomainError::Raise("PrefAndRec : Weight is too small");}
+  if (myWeight <= 1) { throw Standard_DomainError("PrefAndRec : Weight is too small");}
 }
 
 Standard_Boolean AdvApprox_PrefAndRec::Value(const Standard_Real a,
index d2bdd60..2ca97c3 100644 (file)
@@ -56,7 +56,7 @@ AdvApprox_SimpleApprox(const Standard_Integer TotalDimension,
     case GeomAbs_C1: myNivConstr = 1; break;
     case GeomAbs_C2: myNivConstr = 2; break;
     default: 
-      Standard_ConstructionError::Raise("Invalid Continuity");
+      throw Standard_ConstructionError("Invalid Continuity");
   }
 
   Standard_Integer DegreeQ = myWorkDegree - 2*(myNivConstr+1);
index fd8a7f9..7ead66a 100644 (file)
@@ -117,7 +117,7 @@ void AppBlend_AppSurf::CriteriumWeight(Standard_Real& W1, Standard_Real& W2, Sta
 
 void AppBlend_AppSurf::SetCriteriumWeight(const Standard_Real W1, const Standard_Real W2, const Standard_Real W3)
 {
-  if (W1 < 0 || W2 < 0 || W3 < 0 ) Standard_DomainError::Raise();
+  if (W1 < 0 || W2 < 0 || W3 < 0 ) throw Standard_DomainError();
   critweights[0] = W1;
   critweights[1] = W2;
   critweights[2] = W3;
@@ -906,7 +906,7 @@ void AppBlend_AppSurf::SurfShape (Standard_Integer& UDegree,
                                  Standard_Integer& NbUKnots,
                                  Standard_Integer& NbVKnots) const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   UDegree  = udeg;
   VDegree  = vdeg;
   NbUPoles = tabPoles->ColLength();
@@ -924,7 +924,7 @@ void AppBlend_AppSurf::Surface(TColgp_Array2OfPnt& TPoles,
                               TColStd_Array1OfInteger& TVMults) const
 
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   TPoles   = tabPoles->Array2();
   TWeights = tabWeights->Array2();
   TUKnots  = tabUKnots->Array1();
@@ -942,8 +942,8 @@ void AppBlend_AppSurf::Curves2dShape(Standard_Integer& Degree,
                                     Standard_Integer& NbPoles,
                                     Standard_Integer& NbKnots) const
 {
-  if (!done) {StdFail_NotDone::Raise();}
-  if (seqPoles2d.Length() == 0) {Standard_DomainError::Raise();}
+  if (!done) {throw StdFail_NotDone();}
+  if (seqPoles2d.Length() == 0) {throw Standard_DomainError();}
   Degree = vdeg;
   NbPoles = tabPoles->ColLength();
   NbKnots = tabVKnots->Length();
@@ -959,8 +959,8 @@ void AppBlend_AppSurf::Curve2d(const Standard_Integer Index,
                               TColStd_Array1OfReal& TKnots,
                               TColStd_Array1OfInteger& TMults) const
 {
-  if (!done) {StdFail_NotDone::Raise();}
-  if (seqPoles2d.Length() == 0) {Standard_DomainError::Raise();}
+  if (!done) {throw StdFail_NotDone();}
+  if (seqPoles2d.Length() == 0) {throw Standard_DomainError();}
   TPoles = seqPoles2d(Index)->Array1();
   TKnots  = tabVKnots->Array1();
   TMults  = tabVMults->Array1();
index 22700ed..0d52a93 100644 (file)
@@ -28,92 +28,92 @@ inline Standard_Boolean AppBlend_AppSurf::IsDone() const
 
 inline Standard_Integer AppBlend_AppSurf::UDegree() const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return udeg;
 }
 
 inline Standard_Integer AppBlend_AppSurf::VDegree() const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return vdeg;
 }
 
 inline const TColgp_Array2OfPnt& AppBlend_AppSurf::SurfPoles() const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return tabPoles->Array2();
 }
 
 inline const TColStd_Array2OfReal& AppBlend_AppSurf::SurfWeights() const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return tabWeights->Array2();
 }
 
 
 inline const TColStd_Array1OfReal& AppBlend_AppSurf::SurfUKnots() const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return tabUKnots->Array1();
 }
 
 inline const TColStd_Array1OfReal& AppBlend_AppSurf::SurfVKnots() const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return tabVKnots->Array1();
 }
 
 inline const TColStd_Array1OfInteger& AppBlend_AppSurf::SurfUMults() const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return tabUMults->Array1();
 }
 
 inline const TColStd_Array1OfInteger& AppBlend_AppSurf::SurfVMults() const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return tabVMults->Array1();
 }
 
 inline Standard_Integer AppBlend_AppSurf::NbCurves2d () const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return seqPoles2d.Length();
 }
 
 inline Standard_Integer AppBlend_AppSurf::Curves2dDegree() const
 {
-  if (!done) {StdFail_NotDone::Raise();}
-  if (seqPoles2d.Length() == 0) {Standard_DomainError::Raise();}
+  if (!done) {throw StdFail_NotDone();}
+  if (seqPoles2d.Length() == 0) {throw Standard_DomainError();}
   return vdeg;
 }
 
 inline const TColgp_Array1OfPnt2d& AppBlend_AppSurf::
   Curve2dPoles(const Standard_Integer Index) const
 {
-  if (!done) {StdFail_NotDone::Raise();}
-  if (seqPoles2d.Length() == 0) {Standard_DomainError::Raise();}
+  if (!done) {throw StdFail_NotDone();}
+  if (seqPoles2d.Length() == 0) {throw Standard_DomainError();}
   return seqPoles2d(Index)->Array1();
 }
 
 inline const TColStd_Array1OfReal& AppBlend_AppSurf::Curves2dKnots () const
 {
-  if (!done) {StdFail_NotDone::Raise();}
-  if (seqPoles2d.Length() == 0) {Standard_DomainError::Raise();}
+  if (!done) {throw StdFail_NotDone();}
+  if (seqPoles2d.Length() == 0) {throw Standard_DomainError();}
   return tabVKnots->Array1();
 }
 
 inline const TColStd_Array1OfInteger& AppBlend_AppSurf::Curves2dMults () const
 {
-  if (!done) {StdFail_NotDone::Raise();}
-  if (seqPoles2d.Length() == 0) {Standard_DomainError::Raise();}
+  if (!done) {throw StdFail_NotDone();}
+  if (seqPoles2d.Length() == 0) {throw Standard_DomainError();}
   return tabVMults->Array1();
 }
 
 inline void AppBlend_AppSurf::TolReached (Standard_Real& Tol3d,
                                          Standard_Real& Tol2d) const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   Tol3d = tol3dreached;
   Tol2d = tol2dreached;
 }
index 7a54a7a..54a258b 100644 (file)
@@ -2069,7 +2069,7 @@ static const Standard_Real IMatrix[] = {
 void InvMMatrix(const Standard_Integer classe,
                math_Matrix&           InvM)
 {
-  if (classe > 24) Standard_DimensionError::Raise("InvMMatrix: classe > 24");
+  if (classe > 24) throw Standard_DimensionError("InvMMatrix: classe > 24");
   Standard_Integer i, j, k = 0, Som = 0;
   for (i = 2; i < classe; i++) {
     Som += (i)*(i);
index 99e5e20..0956cea 100644 (file)
@@ -414,7 +414,7 @@ static const Standard_Real IBP[] = {
 
 void IBPMatrix(const Standard_Integer classe, math_Matrix& IBPMa)
 {
-  if (classe > 26) Standard_DimensionError::Raise("IBPMatrix: classe > 26");
+  if (classe > 26) throw Standard_DimensionError("IBPMatrix: classe > 26");
 //  math_Matrix IBPMa(1, classe-2, 1, classe-2);
   Standard_Integer i, j, k = 0, Som = 0;
   for (i = 1; i < classe-2; i++) {
index 6b457c6..3243a8e 100644 (file)
@@ -3276,7 +3276,7 @@ static const Standard_Real BBMatrix[] = {
 void MMatrix(const Standard_Integer classe,
             math_Matrix&           M)
 {
-  if (classe > 24) Standard_DimensionError::Raise("MMatrix: classe > 24");
+  if (classe > 24) throw Standard_DimensionError("MMatrix: classe > 24");
   Standard_Integer i, j, k = 0, Som = 0;
   for (i = 2; i < classe; i++) {
     Som += (i)*(i);
index 6f44ece..20f4443 100644 (file)
@@ -352,7 +352,7 @@ static const Standard_Real IBT[] = {
 
 void IBTMatrix(const Standard_Integer classe, math_Matrix& IBTMa)
 {
-  if (classe > 26) Standard_DimensionError::Raise("IBTMatrix: classe > 26");
+  if (classe > 26) throw Standard_DimensionError("IBTMatrix: classe > 26");
 //  math_Matrix IBTMa(1, classe-4, 1, classe-4);
   Standard_Integer i, j, k = 0, Som = 0;
   for (i = 1; i < classe-4; i++) {
index 57b9db2..7cc15f2 100644 (file)
@@ -1234,8 +1234,8 @@ void VBernstein(const Standard_Integer classe,
                const Standard_Integer nbpoints,
                math_Matrix&           M)
 {
-  if (classe > 26) Standard_DimensionError::Raise("VBernstein: classe > 26");
-  if (nbpoints > 24) Standard_DimensionError::Raise("VBernstein: nbpoints > 24");
+  if (classe > 26) throw Standard_DimensionError("VBernstein: classe > 26");
+  if (nbpoints > 24) throw Standard_DimensionError("VBernstein: nbpoints > 24");
   //  math_Matrix VB(classe, nbpoints);
   
   Standard_Integer i, j, k = 0, Som;
index 826c657..9a13885 100644 (file)
@@ -204,7 +204,7 @@ void AppDef_LinearCriteria::GetEstimation(Standard_Real& E1,
 //=======================================================================
 Handle(FEmTool_HAssemblyTable) AppDef_LinearCriteria::AssemblyTable() const
 {
-  if(myCurve.IsNull()) Standard_DomainError::Raise("AppDef_LinearCriteria::AssemblyTable");
+  if(myCurve.IsNull()) throw Standard_DomainError("AppDef_LinearCriteria::AssemblyTable");
 
   Standard_Integer NbDim = myCurve->Dimension(),
                    NbElm = myCurve->NbElements(),
@@ -279,7 +279,7 @@ Handle(FEmTool_HAssemblyTable) AppDef_LinearCriteria::AssemblyTable() const
 //=======================================================================
 Handle(TColStd_HArray2OfInteger) AppDef_LinearCriteria::DependenceTable() const
 {
-  if(myCurve.IsNull()) Standard_DomainError::Raise("AppDef_LinearCriteria::DependenceTable");
+  if(myCurve.IsNull()) throw Standard_DomainError("AppDef_LinearCriteria::DependenceTable");
 
   Standard_Integer Dim = myCurve->Dimension();
 
@@ -304,7 +304,7 @@ Standard_Integer AppDef_LinearCriteria::QualityValues(const Standard_Real J1min,
                                                            Standard_Real& J2,
                                                            Standard_Real& J3) 
 {
-  if(myCurve.IsNull()) Standard_DomainError::Raise("AppDef_LinearCriteria::QualityValues");
+  if(myCurve.IsNull()) throw Standard_DomainError("AppDef_LinearCriteria::QualityValues");
 
   Standard_Integer NbDim = myCurve->Dimension(),
                    NbElm = myCurve->NbElements();
@@ -414,13 +414,13 @@ void AppDef_LinearCriteria::ErrorValues(Standard_Real& MaxError,
                                              Standard_Real& QuadraticError,
                                              Standard_Real& AverageError) 
 {
-  if(myCurve.IsNull()) Standard_DomainError::Raise("AppDef_LinearCriteria::ErrorValues");
+  if(myCurve.IsNull()) throw Standard_DomainError("AppDef_LinearCriteria::ErrorValues");
 
   Standard_Integer NbDim = myCurve->Dimension();
 
   Standard_Integer myNbP2d = AppDef_MyLineTool::NbP2d(mySSP), myNbP3d = AppDef_MyLineTool::NbP3d(mySSP);
 
-  if(NbDim != (2*myNbP2d + 3*myNbP3d)) Standard_DomainError::Raise("AppDef_LinearCriteria::ErrorValues");
+  if(NbDim != (2*myNbP2d + 3*myNbP3d)) throw Standard_DomainError("AppDef_LinearCriteria::ErrorValues");
 
   TColgp_Array1OfPnt TabP3d(1, Max(1,myNbP3d));
   TColgp_Array1OfPnt2d TabP2d(1, Max(1,myNbP2d));    
@@ -473,10 +473,10 @@ void AppDef_LinearCriteria::Hessian(const Standard_Integer Element,
                                          const Standard_Integer Dimension2,
                                          math_Matrix& H) 
 {
-  if(myCurve.IsNull()) Standard_DomainError::Raise("AppDef_LinearCriteria::Hessian");
+  if(myCurve.IsNull()) throw Standard_DomainError("AppDef_LinearCriteria::Hessian");
 
   if(DependenceTable()->Value(Dimension1, Dimension2) == 0) 
-    Standard_DomainError::Raise("AppDef_LinearCriteria::Hessian");
+    throw Standard_DomainError("AppDef_LinearCriteria::Hessian");
 
   Standard_Integer //NbDim = myCurve->Dimension(),
                    MxDeg = myCurve->Base()->WorkDegree(),
@@ -570,12 +570,12 @@ void AppDef_LinearCriteria::Gradient(const Standard_Integer Element,
                                           math_Vector& G) 
 {
   if(myCurve.IsNull()) 
-    Standard_DomainError::Raise("AppDef_LinearCriteria::ErrorValues");
+    throw Standard_DomainError("AppDef_LinearCriteria::ErrorValues");
 
   Standard_Integer myNbP2d = AppDef_MyLineTool::NbP2d(mySSP), myNbP3d = AppDef_MyLineTool::NbP3d(mySSP);
 
   if(Dimension > (2*myNbP2d + 3*myNbP3d)) 
-    Standard_DomainError::Raise("AppDef_LinearCriteria::ErrorValues");
+    throw Standard_DomainError("AppDef_LinearCriteria::ErrorValues");
 
   TColgp_Array1OfPnt TabP3d(1, Max(1,myNbP3d));
   TColgp_Array1OfPnt2d TabP2d(1, Max(1,myNbP2d));    
@@ -687,9 +687,9 @@ void AppDef_LinearCriteria::SetWeight(const Standard_Real QuadraticWeight,
                                            const Standard_Real percentJ3) 
 {
   if (QuadraticWeight < 0. || QualityWeight < 0.) 
-    Standard_DomainError::Raise("AppDef_LinearCriteria::SetWeight");
+    throw Standard_DomainError("AppDef_LinearCriteria::SetWeight");
   if (percentJ1 < 0. || percentJ2 < 0. || percentJ3 < 0.) 
-    Standard_DomainError::Raise("AppDef_LinearCriteria::SetWeight");
+    throw Standard_DomainError("AppDef_LinearCriteria::SetWeight");
 
   myQuadraticWeight = QuadraticWeight; myQualityWeight = QualityWeight;
 
index dd980ca..cd8e328 100644 (file)
@@ -26,7 +26,7 @@ AppDef_MultiLine::AppDef_MultiLine(){}
 
 AppDef_MultiLine::AppDef_MultiLine (const Standard_Integer NbMult)
 {
-  if (NbMult < 0 ) Standard_ConstructionError::Raise();
+  if (NbMult < 0 ) throw Standard_ConstructionError();
 
   tabMult = new AppDef_HArray1OfMultiPointConstraint (1, NbMult);
 }
@@ -81,7 +81,7 @@ Standard_Integer AppDef_MultiLine::NbPoints() const {
 void AppDef_MultiLine::SetValue (const Standard_Integer Index, 
                                const AppDef_MultiPointConstraint& MPoint) {
   if ((Index <= 0) || (Index > tabMult->Length())) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   tabMult->SetValue(Index, MPoint);
 }
@@ -89,7 +89,7 @@ void AppDef_MultiLine::SetValue (const Standard_Integer Index,
 AppDef_MultiPointConstraint AppDef_MultiLine::Value (const Standard_Integer Index) const
 {
   if ((Index <= 0) || (Index > tabMult->Length())) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return tabMult->Value(Index);
 }
index 27c47a0..5e53e51 100644 (file)
@@ -74,7 +74,7 @@ AppDef_MultiPointConstraint::AppDef_MultiPointConstraint
       (tabP2d.Length() != tabVec2d.Length()) ||
       (tabCur.Length() != tabP.Length()) ||
       (tabCur2d.Length() != tabP2d.Length())) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   tabTang = new TColgp_HArray1OfVec(1, tabVec.Length());
@@ -113,7 +113,7 @@ AppDef_MultiPointConstraint::AppDef_MultiPointConstraint
 
   if ((tabP.Length() != tabVec.Length()) ||
       (tabP2d.Length() != tabVec2d.Length())) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   tabTang = new TColgp_HArray1OfVec(1, tabVec.Length());
@@ -137,7 +137,7 @@ AppDef_MultiPointConstraint::AppDef_MultiPointConstraint (
                                       AppParCurves_MultiPoint(tabP) {
   
   if (tabP.Length() != tabVec.Length()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   tabTang = new TColgp_HArray1OfVec(1, tabVec.Length());
@@ -157,7 +157,7 @@ AppDef_MultiPointConstraint::AppDef_MultiPointConstraint
 
   if ((tabP.Length() != tabVec.Length()) ||
       (tabP.Length() != tabCur.Length())) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   tabTang = new TColgp_HArray1OfVec(1, tabVec.Length());
@@ -182,7 +182,7 @@ AppDef_MultiPointConstraint::AppDef_MultiPointConstraint
                                       AppParCurves_MultiPoint(tabP2d) {
 
   if (tabP2d.Length() != tabVec2d.Length()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   tabTang2d = new TColgp_HArray1OfVec2d(1, tabVec2d.Length());
@@ -203,7 +203,7 @@ AppDef_MultiPointConstraint::AppDef_MultiPointConstraint
 
   if ((tabP2d.Length() != tabVec2d.Length()) ||
       (tabCur2d.Length() != tabP2d.Length()))  {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   
   tabTang2d = new TColgp_HArray1OfVec2d(1, tabVec2d.Length());
@@ -226,7 +226,7 @@ void AppDef_MultiPointConstraint::SetTang (const Standard_Integer Index,
   if (tabTang.IsNull())
     tabTang = new TColgp_HArray1OfVec (1, nbP);
   if ((Index <= 0) || (Index > nbP)) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   tabTang->SetValue(Index, Tang);
 }
@@ -234,7 +234,7 @@ void AppDef_MultiPointConstraint::SetTang (const Standard_Integer Index,
 
 gp_Vec AppDef_MultiPointConstraint::Tang (const Standard_Integer Index) const {
   if ((Index <= 0) || (Index > nbP)) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return tabTang->Value(Index);
 }
@@ -248,7 +248,7 @@ void AppDef_MultiPointConstraint::SetTang2d (const Standard_Integer Index,
     
   if ((Index <= nbP) || 
       (Index > nbP+nbP2d)) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   tabTang2d->SetValue(Index-nbP, Tang2d);
 }
@@ -257,7 +257,7 @@ void AppDef_MultiPointConstraint::SetTang2d (const Standard_Integer Index,
 gp_Vec2d AppDef_MultiPointConstraint::Tang2d (const Standard_Integer Index) const {
   if ((Index <= nbP) || 
       (Index > nbP+nbP2d)) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return tabTang2d->Value(Index-nbP);
 }
@@ -267,7 +267,7 @@ void AppDef_MultiPointConstraint::SetCurv (const Standard_Integer Index, const g
   if (tabCurv.IsNull())
     tabCurv = new TColgp_HArray1OfVec (1, nbP);
   if ((Index <= 0) || (Index > nbP)) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   tabCurv->SetValue(Index, Curv);
 }
@@ -275,7 +275,7 @@ void AppDef_MultiPointConstraint::SetCurv (const Standard_Integer Index, const g
 
 gp_Vec AppDef_MultiPointConstraint::Curv (const Standard_Integer Index) const {
   if ((Index <= 0) || (Index > nbP)) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return tabCurv->Value(Index);
 }
@@ -288,7 +288,7 @@ void AppDef_MultiPointConstraint::SetCurv2d (const Standard_Integer Index,
     tabCurv2d = new TColgp_HArray1OfVec2d (1, nbP2d);
   if ((Index <= nbP) || 
       (Index > nbP+nbP2d)) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   tabCurv2d->SetValue(Index- nbP, Curv2d);
 }
@@ -298,7 +298,7 @@ void AppDef_MultiPointConstraint::SetCurv2d (const Standard_Integer Index,
 gp_Vec2d AppDef_MultiPointConstraint::Curv2d (const Standard_Integer Index) const {
   if ((Index <= nbP) ||
       (Index > nbP+nbP2d)) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return tabCurv2d->Value(Index - nbP);
 }
index 87f3c7b..842f587 100644 (file)
@@ -117,13 +117,13 @@ myWithMinMax(WithMinMax),
 myWithCutting(WithCutting)
 {
   // Verifications:
-  if (myMaxDegree < 1) Standard_DomainError::Raise();
+  if (myMaxDegree < 1) throw Standard_DomainError();
   myMaxDegree = Min (30, myMaxDegree);
   //
-  if (myMaxSegment < 1) Standard_DomainError::Raise();
+  if (myMaxSegment < 1) throw Standard_DomainError();
   //
-  if (myWithMinMax != 0 && myWithMinMax !=1 ) Standard_DomainError::Raise();
-  if (myWithCutting != 0 && myWithCutting !=1 ) Standard_DomainError::Raise();
+  if (myWithMinMax != 0 && myWithMinMax !=1 ) throw Standard_DomainError();
+  if (myWithCutting != 0 && myWithCutting !=1 ) throw Standard_DomainError();
   //
   myIsOverConstr = Standard_False;
   myIsCreated    = Standard_False;
@@ -139,7 +139,7 @@ myWithCutting(WithCutting)
       myNivCont=2;
       break ;
     default:
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
   }
   //
   myNbP2d = AppDef_MyLineTool::NbP2d(SSP); 
@@ -158,7 +158,7 @@ myWithCutting(WithCutting)
   mySmoothCriterion = new AppDef_LinearCriteria(mySSP, myFirstPoint, myLastPoint);
   myParameters = new TColStd_HArray1OfReal(myFirstPoint, myLastPoint);
   myNbPoints=myLastPoint-myFirstPoint+1;
-  if (myNbPoints <= 0) Standard_ConstructionError::Raise();
+  if (myNbPoints <= 0) throw Standard_ConstructionError();
   // 
   myTabPoints= new TColStd_HArray1OfReal(1,myDimension*myNbPoints);
   //
@@ -242,7 +242,7 @@ void AppDef_Variational::Init()
   gp_Vec2d Vt2d, Vc2d;
 
   myNbConstraints=myConstraints->Length();
-  if (myNbConstraints < 0) Standard_ConstructionError::Raise(); 
+  if (myNbConstraints < 0) throw Standard_ConstructionError();
 
   myTypConstraints = new TColStd_HArray1OfInteger(1,Max(1,2*myNbConstraints));
   myTabConstraints = new TColStd_HArray1OfReal(1,Max(1,2*myDimension*myNbConstraints));
@@ -284,7 +284,7 @@ void AppDef_Variational::Init()
                                if(myNbP2d !=0 && myNbP3d == 0 ) 
                                {
                                  if (AppDef_MyLineTool::Tangency(mySSP,ipoint,TabV2d) == Standard_False)
-                                   Standard_ConstructionError::Raise();
+                                   throw Standard_ConstructionError();
                                  for (jp2d=1;jp2d<=myNbP2d;jp2d++)
                                  {  
                                    Vt2d=TabV2d.Value(jp2d);
@@ -298,7 +298,7 @@ void AppDef_Variational::Init()
                                if(myNbP3d !=0 && myNbP2d == 0) 
                                {
                                  if (AppDef_MyLineTool::Tangency(mySSP,ipoint,TabV3d) == Standard_False)
-                                   Standard_ConstructionError::Raise();
+                                   throw Standard_ConstructionError();
                                  for (jp3d=1;jp3d<=myNbP3d;jp3d++)
                                  {  
                                    Vt3d=TabV3d.Value(jp3d);
@@ -315,7 +315,7 @@ void AppDef_Variational::Init()
                                if(myNbP3d !=0 && myNbP2d != 0) 
                                {
                                  if (AppDef_MyLineTool::Tangency(mySSP,ipoint,TabV3d,TabV2d) == Standard_False)
-                                   Standard_ConstructionError::Raise();
+                                   throw Standard_ConstructionError();
                                  for (jp3d=1;jp3d<=myNbP3d;jp3d++)
                                  {  
                                    Vt3d=TabV3d.Value(jp3d);
@@ -348,16 +348,16 @@ void AppDef_Variational::Init()
                                if(myNbP2d !=0 && myNbP3d == 0) 
                                {
                                  if (AppDef_MyLineTool::Tangency(mySSP,ipoint,TabV2d) == Standard_False )
-                                   Standard_ConstructionError::Raise();
+                                   throw Standard_ConstructionError();
                                  if (AppDef_MyLineTool::Curvature(mySSP,ipoint,TabV2dcurv) == Standard_False)
-                                   Standard_ConstructionError::Raise();
+                                   throw Standard_ConstructionError();
                                  for (jp2d=1;jp2d<=myNbP2d;jp2d++)
                                  {  
                                    Vt2d=TabV2d.Value(jp2d);
                                    Vt2d.Normalize();
                                    Vc2d=TabV2dcurv.Value(jp2d);
                                    if (Abs(Abs(Vc2d.Angle(Vt2d)) - M_PI/2.) > Precision::Angular())
-                                     Standard_ConstructionError::Raise();
+                                     throw Standard_ConstructionError();
                                    myTabConstraints->SetValue(jndex++,Vt2d.X());
                                    myTabConstraints->SetValue(jndex++,Vt2d.Y());
                                    myTabConstraints->SetValue(jndex++,Vc2d.X());
@@ -369,16 +369,16 @@ void AppDef_Variational::Init()
                                if(myNbP3d !=0 && myNbP2d == 0 ) 
                                {
                                  if (AppDef_MyLineTool::Tangency(mySSP,ipoint,TabV3d) == Standard_False )
-                                   Standard_ConstructionError::Raise();
+                                   throw Standard_ConstructionError();
                                  if (AppDef_MyLineTool::Curvature(mySSP,ipoint,TabV3dcurv) == Standard_False)
-                                   Standard_ConstructionError::Raise();
+                                   throw Standard_ConstructionError();
                                  for (jp3d=1;jp3d<=myNbP3d;jp3d++)
                                  {  
                                    Vt3d=TabV3d.Value(jp3d);
                                    Vt3d.Normalize();
                                    Vc3d=TabV3dcurv.Value(jp3d);
                                    if ( (Vc3d.Normalized()).IsNormal(Vt3d,Precision::Angular()) == Standard_False) 
-                                     Standard_ConstructionError::Raise();
+                                     throw Standard_ConstructionError();
                                    myTabConstraints->SetValue(jndex++,Vt3d.X());
                                    myTabConstraints->SetValue(jndex++,Vt3d.Y()); 
                                    myTabConstraints->SetValue(jndex++,Vt3d.Z());
@@ -391,16 +391,16 @@ void AppDef_Variational::Init()
                                if(myNbP3d !=0 && myNbP2d != 0 ) 
                                {
                                  if (AppDef_MyLineTool::Tangency(mySSP,ipoint,TabV3d,TabV2d) == Standard_False )
-                                   Standard_ConstructionError::Raise();
+                                   throw Standard_ConstructionError();
                                  if (AppDef_MyLineTool::Curvature(mySSP,ipoint,TabV3dcurv,TabV2dcurv) == Standard_False)
-                                   Standard_ConstructionError::Raise();
+                                   throw Standard_ConstructionError();
                                  for (jp3d=1;jp3d<=myNbP3d;jp3d++)
                                  {  
                                    Vt3d=TabV3d.Value(jp3d);
                                    Vt3d.Normalize();
                                    Vc3d=TabV3dcurv.Value(jp3d);
                                    if ( (Vc3d.Normalized()).IsNormal(Vt3d,Precision::Angular()) == Standard_False) 
-                                     Standard_ConstructionError::Raise();
+                                     throw Standard_ConstructionError();
                                    myTabConstraints->SetValue(jndex++,Vt3d.X());
                                    myTabConstraints->SetValue(jndex++,Vt3d.Y()); 
                                    myTabConstraints->SetValue(jndex++,Vt3d.Z());
@@ -415,7 +415,7 @@ void AppDef_Variational::Init()
                                    Vt2d.Normalize();
                                    Vc2d=TabV2dcurv.Value(jp2d);
                                    if (Abs(Abs(Vc2d.Angle(Vt2d)) - M_PI/2.) > Precision::Angular())
-                                     Standard_ConstructionError::Raise();
+                                     throw Standard_ConstructionError();
                                    myTabConstraints->SetValue(jndex++,Vt2d.X());
                                    myTabConstraints->SetValue(jndex++,Vt2d.Y());
                                    myTabConstraints->SetValue(jndex++,Vc2d.X());
@@ -426,7 +426,7 @@ void AppDef_Variational::Init()
                                }
                                break ; 
                              default:
-                               Standard_ConstructionError::Raise();
+                               throw Standard_ConstructionError();
     }
     CurMultyPoint += myNbP3d * 6 + myNbP2d * 2;
   }
@@ -455,7 +455,7 @@ void AppDef_Variational::Init()
 void AppDef_Variational::Approximate()
 
 {
-  if (myIsCreated == Standard_False )  StdFail_NotDone:: Raise();
+  if (myIsCreated == Standard_False )  throw StdFail_NotDone();
 
 
   Standard_Real WQuadratic, WQuality;
@@ -666,7 +666,7 @@ Standard_Boolean AppDef_Variational::IsOverConstrained() const
 //
 AppParCurves_MultiBSpCurve AppDef_Variational::Value() const 
 { 
-  if (myIsDone == Standard_False)  StdFail_NotDone::Raise(); 
+  if (myIsDone == Standard_False)  throw StdFail_NotDone();
   return myMBSpCurve;
 
 }
@@ -680,7 +680,7 @@ AppParCurves_MultiBSpCurve AppDef_Variational::Value() const
 //
 Standard_Real AppDef_Variational::MaxError() const 
 {
-  if (myIsDone == Standard_False)  StdFail_NotDone::Raise();
+  if (myIsDone == Standard_False)  throw StdFail_NotDone();
   return myMaxError;
 }
 //
@@ -691,7 +691,7 @@ Standard_Real AppDef_Variational::MaxError() const
 //
 Standard_Integer AppDef_Variational::MaxErrorIndex() const 
 {
-  if (myIsDone == Standard_False)  StdFail_NotDone::Raise(); 
+  if (myIsDone == Standard_False)  throw StdFail_NotDone();
   return myMaxErrorIndex;
 }
 //
@@ -704,7 +704,7 @@ Standard_Integer AppDef_Variational::MaxErrorIndex() const
 //
 Standard_Real AppDef_Variational::QuadraticError() const 
 {
-  if (myIsDone == Standard_False)  StdFail_NotDone::Raise(); 
+  if (myIsDone == Standard_False)  throw StdFail_NotDone();
   return myCriterium[0];
 }
 //
@@ -717,7 +717,7 @@ Standard_Real AppDef_Variational::QuadraticError() const
 void AppDef_Variational::Distance(math_Matrix& mat)
 
 {
-  if (myIsDone == Standard_False)  StdFail_NotDone::Raise();
+  if (myIsDone == Standard_False)  throw StdFail_NotDone();
   Standard_Integer ipoint,jp2d,jp3d,index;
   TColgp_Array1OfPnt TabP3d(1,Max(1,myNbP3d));
   TColgp_Array1OfPnt2d TabP2d(1, Max(1,myNbP2d));
@@ -766,7 +766,7 @@ void AppDef_Variational::Distance(math_Matrix& mat)
 //
 Standard_Real AppDef_Variational::AverageError() const 
 {
-  if (myIsDone == Standard_False)  StdFail_NotDone::Raise();
+  if (myIsDone == Standard_False)  throw StdFail_NotDone();
   return myAverageError;
 }
 //
@@ -777,7 +777,7 @@ Standard_Real AppDef_Variational::AverageError() const
 //
 const Handle(TColStd_HArray1OfReal)& AppDef_Variational::Parameters() const 
 {
-  if (myIsDone == Standard_False)  StdFail_NotDone::Raise();
+  if (myIsDone == Standard_False)  throw StdFail_NotDone();
   return myParameters;
 }
 //
@@ -788,7 +788,7 @@ const Handle(TColStd_HArray1OfReal)& AppDef_Variational::Parameters() const
 //
 const Handle(TColStd_HArray1OfReal)& AppDef_Variational::Knots() const 
 {
-  if (myIsDone == Standard_False)  StdFail_NotDone::Raise();
+  if (myIsDone == Standard_False)  throw StdFail_NotDone();
   return myKnots;
 }
 //
@@ -799,7 +799,7 @@ const Handle(TColStd_HArray1OfReal)& AppDef_Variational::Knots() const
 //
 void AppDef_Variational::Criterium(Standard_Real& VFirstOrder, Standard_Real& VSecondOrder, Standard_Real& VThirdOrder) const 
 {     
-  if (myIsDone == Standard_False)  StdFail_NotDone::Raise();
+  if (myIsDone == Standard_False)  throw StdFail_NotDone();
   VFirstOrder=myCriterium[1] ;
   VSecondOrder=myCriterium[2];
   VThirdOrder=myCriterium[3];
@@ -1027,7 +1027,7 @@ Standard_Boolean AppDef_Variational::SetContinuity(const GeomAbs_Shape C)
       NivCont=2;
       break ;
     default:
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
   }
   if (((myMaxDegree-NivCont)*myMaxSegment-myNbPassPoints-2*myNbTangPoints-3*myNbCurvPoints) < 0 )
     return Standard_False; 
@@ -1097,7 +1097,7 @@ Standard_Boolean AppDef_Variational::SetWithCutting(const Standard_Boolean Cutti
 //
 void AppDef_Variational::SetCriteriumWeight(const Standard_Real Percent1, const Standard_Real Percent2, const Standard_Real Percent3)
 {
-  if (Percent1 < 0 || Percent2 < 0 || Percent3 < 0 ) Standard_DomainError::Raise();
+  if (Percent1 < 0 || Percent2 < 0 || Percent3 < 0 ) throw Standard_DomainError();
   Standard_Real Total = Percent1 + Percent2 + Percent3;
   myPercent[0] = Percent1/Total;
   myPercent[1] = Percent2/Total;
@@ -1115,8 +1115,8 @@ void AppDef_Variational::SetCriteriumWeight(const Standard_Real Percent1, const
 //
 void AppDef_Variational::SetCriteriumWeight(const Standard_Integer Order, const Standard_Real Percent)
 {
-  if ( Percent < 0 ) Standard_DomainError::Raise();
-  if ( Order < 1 || Order > 3 ) Standard_ConstructionError::Raise();
+  if ( Percent < 0 ) throw Standard_DomainError();
+  if ( Order < 1 || Order > 3 ) throw Standard_ConstructionError();
   myPercent[Order-1] = Percent;
   Standard_Real Total = myPercent[0] + myPercent[1] + myPercent[2];
   myPercent[0] = myPercent[0] / Total;
@@ -2043,7 +2043,7 @@ void AppDef_Variational::InitParameters(Standard_Real& Length)
 
 
   if(Length <= Eps1) 
-    Standard_ConstructionError::Raise("AppDef_Variational::InitParameters");
+    throw Standard_ConstructionError("AppDef_Variational::InitParameters");
 
 
   for(ipoint = myFirstPoint + 1; ipoint <= myLastPoint - 1; ipoint++) 
@@ -2438,7 +2438,7 @@ void AppDef_Variational::InitCutting(const Handle(PLib_Base)& aBase,
   }
 
   if(ORCMx > myMaxDegree - myNivCont) 
-    Standard_ConstructionError::Raise("AppDef_Variational::InitCutting");
+    throw Standard_ConstructionError("AppDef_Variational::InitCutting");
 
   Standard_Integer NLibre = Max(myMaxDegree - myNivCont - (myMaxDegree + 1) / 4,
     myNivCont + 1);
@@ -2454,7 +2454,7 @@ void AppDef_Variational::InitCutting(const Handle(PLib_Base)& aBase,
 
 
   if(NbElem > myMaxSegment) 
-    Standard_ConstructionError::Raise("AppDef_Variational::InitCutting");
+    throw Standard_ConstructionError("AppDef_Variational::InitCutting");
 
 
   aCurve = new FEmTool_Curve(myDimension, NbElem, aBase, CurvTol);
index 0915499..38ccd4e 100644 (file)
@@ -1115,7 +1115,7 @@ void AppParCurves_LeastSquare::Error(Standard_Real& F,
                                     Standard_Real& MaxE2d)
 {
 
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   Standard_Integer i, j, k, i2, indexdeb, indexfin;
   Standard_Integer i21, i22;
   Standard_Real AA, BB, CC, Fi, FX, FY, FZ, AIJ;
@@ -1168,7 +1168,7 @@ void AppParCurves_LeastSquare::ErrorGradient(math_Vector& Grad,
                                             Standard_Real& MaxE3d,
                                             Standard_Real& MaxE2d)
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   Standard_Integer i, j, k, i2, indexdeb, indexfin;
   Standard_Real AA, BB, CC, Fi, FX, FY, FZ, AIJ;
 //  Standard_Real DAIJ, DAA, DBB, DCC, Gr, gr1= 0.0, gr2= 0.0;
@@ -1263,14 +1263,14 @@ Standard_Boolean AppParCurves_LeastSquare::IsDone() const
 
 AppParCurves_MultiCurve AppParCurves_LeastSquare::BezierValue() 
 {
-  if (!myknots.IsNull()) Standard_NoSuchObject::Raise();
+  if (!myknots.IsNull()) throw Standard_NoSuchObject();
   return (AppParCurves_MultiCurve)(BSplineValue());
 }
 
 
 const AppParCurves_MultiBSpCurve& AppParCurves_LeastSquare::BSplineValue() 
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
 
   Standard_Integer i, j, j2, npoints = nbP+nbP2d;;
   gp_Pnt Pt;
@@ -1302,14 +1302,14 @@ const AppParCurves_MultiBSpCurve& AppParCurves_LeastSquare::BSplineValue()
 
 const math_Matrix& AppParCurves_LeastSquare::FunctionMatrix() const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return A;
 }
 
 
 const math_Matrix& AppParCurves_LeastSquare::DerivativeFunctionMatrix() const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return DA;
 }
 
index 80cad1c..e626a61 100644 (file)
@@ -165,7 +165,7 @@ void AppParCurves_MultiBSpCurve::Value (const Standard_Integer CuIndex,
                              const Standard_Real U, gp_Pnt& Pt) const {
 
   if (Dimension(CuIndex) != 3) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
 
   TColgp_Array1OfPnt TabPoles(1, tabPoint->Length());
@@ -185,7 +185,7 @@ void AppParCurves_MultiBSpCurve::Value (const Standard_Integer CuIndex,
                              const Standard_Real U, gp_Pnt2d& Pt) const {
 
   if (Dimension(CuIndex) != 2) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
 
   TColgp_Array1OfPnt2d TabPoles(1, tabPoint->Length());
@@ -204,7 +204,7 @@ void AppParCurves_MultiBSpCurve::Value (const Standard_Integer CuIndex,
 void AppParCurves_MultiBSpCurve::D1 (const Standard_Integer CuIndex, 
                           const Standard_Real U, gp_Pnt& Pt, gp_Vec& V1) const {
   if (Dimension(CuIndex) != 3) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
 
   TColgp_Array1OfPnt TabPoles(1, tabPoint->Length());
@@ -226,7 +226,7 @@ void AppParCurves_MultiBSpCurve::D2 (const Standard_Integer CuIndex,
                            gp_Vec& V1,
                            gp_Vec& V2) const {
   if (Dimension(CuIndex) != 3) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
 
   TColgp_Array1OfPnt TabPoles(1, tabPoint->Length());
@@ -245,7 +245,7 @@ void AppParCurves_MultiBSpCurve::D2 (const Standard_Integer CuIndex,
 void AppParCurves_MultiBSpCurve::D1 (const Standard_Integer CuIndex,
                       const Standard_Real U, gp_Pnt2d& Pt, gp_Vec2d& V1) const {
   if (Dimension(CuIndex) != 2) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
 
   TColgp_Array1OfPnt2d TabPoles(1, tabPoint->Length());
@@ -267,7 +267,7 @@ void AppParCurves_MultiBSpCurve::D2 (const Standard_Integer CuIndex,
                            gp_Vec2d& V1,
                            gp_Vec2d& V2) const {
   if (Dimension(CuIndex) != 2) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
 
   TColgp_Array1OfPnt2d TabPoles(1, tabPoint->Length());
index 92ba882..7eaac94 100644 (file)
@@ -55,7 +55,7 @@ Standard_Integer AppParCurves_MultiCurve::Dimension (const Standard_Integer Inde
   Standard_Integer Lo = tabPoint->Lower();
   Standard_Integer nb = tabPoint->Value(Lo).NbPoints() + tabPoint->Value(Lo).NbPoints2d();
   if ((Index <= 0) || (Index > nb)) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return tabPoint->Value(Lo).Dimension(Index);
 }
@@ -91,7 +91,7 @@ void AppParCurves_MultiCurve::SetValue (const Standard_Integer Index,
                                  const AppParCurves_MultiPoint& MPoint) {
 
   if ((Index <= 0) || (Index > tabPoint->Length())) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   tabPoint->SetValue(Index, MPoint);
 }
@@ -100,7 +100,7 @@ void AppParCurves_MultiCurve::SetValue (const Standard_Integer Index,
 void AppParCurves_MultiCurve::Curve (const Standard_Integer CuIndex,
                               TColgp_Array1OfPnt& TabPnt) const {
   if ((CuIndex <= 0)) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   for ( Standard_Integer i = 1; i <= tabPoint->Length(); i++) {
     TabPnt(i) = tabPoint->Value(i).Point(CuIndex);
@@ -111,7 +111,7 @@ void AppParCurves_MultiCurve::Curve (const Standard_Integer CuIndex,
 void AppParCurves_MultiCurve::Curve (const Standard_Integer CuIndex,
                               TColgp_Array1OfPnt2d& TabPnt2d) const {
   if ((CuIndex <= 0)) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   for ( Standard_Integer i = 1; i <= tabPoint->Length(); i++) {
     TabPnt2d(i) = tabPoint->Value(i).Point2d(CuIndex);
@@ -124,7 +124,7 @@ const gp_Pnt& AppParCurves_MultiCurve::Pole(const Standard_Integer CuIndex,
                                            const Standard_Integer Nieme) const
 {
   if ((CuIndex <= 0) && Nieme <= 0) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return tabPoint->Value(Nieme).Point(CuIndex);
 }
@@ -133,7 +133,7 @@ const gp_Pnt2d& AppParCurves_MultiCurve::Pole2d(const Standard_Integer CuIndex,
                                            const Standard_Integer Nieme)const
 {
   if ((CuIndex <= 0) && Nieme <= 0) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return tabPoint->Value(Nieme).Point2d(CuIndex);
 }
@@ -142,7 +142,7 @@ const gp_Pnt2d& AppParCurves_MultiCurve::Pole2d(const Standard_Integer CuIndex,
 
 const AppParCurves_MultiPoint& AppParCurves_MultiCurve::Value (const Standard_Integer Index) const {
   if ((Index <= 0) || (Index > tabPoint->Length())) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return tabPoint->Value(Index);
 }
@@ -155,7 +155,7 @@ void AppParCurves_MultiCurve::Transform(const Standard_Integer CuIndex,
                                        const Standard_Real    z,
                                        const Standard_Real    dz) 
 {
-  if (Dimension(CuIndex) != 3) Standard_OutOfRange::Raise();
+  if (Dimension(CuIndex) != 3) throw Standard_OutOfRange();
 
   for (Standard_Integer i = 1 ; i <= tabPoint->Length(); i++) {
     (tabPoint->ChangeValue(i)).Transform(CuIndex, x, dx, y, dy, z, dz);
@@ -168,7 +168,7 @@ void AppParCurves_MultiCurve::Transform2d(const Standard_Integer CuIndex,
                                          const Standard_Real    y,
                                          const Standard_Real    dy) 
 {
-  if (Dimension(CuIndex) != 2) Standard_OutOfRange::Raise();
+  if (Dimension(CuIndex) != 2) throw Standard_OutOfRange();
 
   for (Standard_Integer i = 1 ; i <= tabPoint->Length(); i++) {
     (tabPoint->ChangeValue(i)).Transform2d(CuIndex, x, dx, y, dy);
@@ -179,7 +179,7 @@ void AppParCurves_MultiCurve::Transform2d(const Standard_Integer CuIndex,
 void AppParCurves_MultiCurve::Value (const Standard_Integer CuIndex, 
                              const Standard_Real U, gp_Pnt& Pt) const {
   
-  if (Dimension(CuIndex) != 3)Standard_OutOfRange::Raise();
+  if (Dimension(CuIndex) != 3)throw Standard_OutOfRange();
 
   TColgp_Array1OfPnt TabPoles(1, tabPoint->Length());
   
@@ -194,7 +194,7 @@ void AppParCurves_MultiCurve::Value (const Standard_Integer CuIndex,
 void AppParCurves_MultiCurve::Value (const Standard_Integer CuIndex, 
                              const Standard_Real U, gp_Pnt2d& Pt) const {
   if (Dimension(CuIndex) != 2) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
 
   TColgp_Array1OfPnt2d TabPole(1, tabPoint->Length());
@@ -213,7 +213,7 @@ void AppParCurves_MultiCurve::D1 (const Standard_Integer CuIndex,
                                  gp_Vec& V1) const {
 
   if (Dimension(CuIndex) != 3) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
 
   TColgp_Array1OfPnt TabPole(1, tabPoint->Length());
@@ -233,7 +233,7 @@ void AppParCurves_MultiCurve::D2 (const Standard_Integer CuIndex,
                            gp_Vec& V2) const {
 
   if (Dimension(CuIndex) != 3) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
 
   TColgp_Array1OfPnt TabPole(1, tabPoint->Length());
@@ -250,7 +250,7 @@ void AppParCurves_MultiCurve::D1 (const Standard_Integer CuIndex,
                       const Standard_Real U, gp_Pnt2d& Pt, gp_Vec2d& V1) const {
 
   if (Dimension(CuIndex) != 2) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
 
   TColgp_Array1OfPnt2d TabPole(1, tabPoint->Length());
@@ -270,7 +270,7 @@ void AppParCurves_MultiCurve::D2 (const Standard_Integer CuIndex,
                            gp_Vec2d& V2) const {
 
   if (Dimension(CuIndex) != 2) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
 
   TColgp_Array1OfPnt2d TabPole(1, tabPoint->Length());
index cd46435..1103f9e 100644 (file)
@@ -115,7 +115,7 @@ void AppParCurves_MultiPoint::Transform(const Standard_Integer CuIndex,
                                        const Standard_Real    z,
                                        const Standard_Real    dz) 
 {
-  if (Dimension(CuIndex) != 3) Standard_OutOfRange::Raise();
+  if (Dimension(CuIndex) != 3) throw Standard_OutOfRange();
 
   gp_Pnt P, newP;
   P = Point(CuIndex);
@@ -130,7 +130,7 @@ void AppParCurves_MultiPoint::Transform2d(const Standard_Integer CuIndex,
                                          const Standard_Real    y,
                                          const Standard_Real    dy) 
 {
-  if (Dimension(CuIndex) != 2) Standard_OutOfRange::Raise();
+  if (Dimension(CuIndex) != 2) throw Standard_OutOfRange();
 
   gp_Pnt2d P, newP;
   P = Point2d(CuIndex);
index dbb1d90..3654130 100644 (file)
@@ -40,7 +40,7 @@ inline Standard_Integer AppParCurves_MultiPoint::NbPoints2d() const {
 inline Standard_Integer AppParCurves_MultiPoint::Dimension(const Standard_Integer Index) const
 {
   if (Index < 0 || Index > (nbP + nbP2d)) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   if (Index <= nbP) {
     return 3;
index e1b867a..0c4fae4 100644 (file)
@@ -312,7 +312,7 @@ void Approx_CurveOnSurface_Eval2d::Evaluate (Standard_Integer *Dimension,
                                              const Standard_Boolean only2d)
 {
   myIsDone = Standard_False;
-  if(only3d && only2d) Standard_ConstructionError::Raise();
+  if(only3d && only2d) throw Standard_ConstructionError();
   GeomAbs_Shape Order  = S;
 
   Handle( Adaptor2d_HCurve2d ) TrimmedC2D = C2D->Trim( First, Last, Precision::PConfusion() );
index 84bea9e..04f3021 100644 (file)
@@ -74,7 +74,7 @@ static void findfourpoints(const Standard_Real ,
 {
   Standard_Integer i, j;
   Standard_Integer NbInt = Si->Length() - 1;
-  if (NbInt < 3) Standard_ConstructionError::Raise("Approx_CurvlinFunc::GetUParameter");
+  if (NbInt < 3) throw Standard_ConstructionError("Approx_CurvlinFunc::GetUParameter");
 
   if(NInterval < 1) NInterval = 1;
   else if(NInterval > NbInt - 2) NInterval = NbInt - 2;
@@ -325,7 +325,7 @@ void Approx_CurvlinFunc::Intervals(TColStd_Array1OfReal& T, const GeomAbs_Shape
 
 void Approx_CurvlinFunc::Trim(const Standard_Real First, const Standard_Real Last, const Standard_Real Tol)
 {
-  if (First < 0 || Last >1) Standard_OutOfRange::Raise("Approx_CurvlinFunc::Trim");
+  if (First < 0 || Last >1) throw Standard_OutOfRange("Approx_CurvlinFunc::Trim");
   if ((Last - First) < Tol) return;
 
   Standard_Real FirstU, LastU;
@@ -461,7 +461,7 @@ Standard_Real Approx_CurvlinFunc::GetUParameter(Adaptor3d_Curve& C,
 #ifdef OCCT_DEBUG_CHRONO
   InitChron(chr_uparam);
 #endif
-  if(S < 0 || S > 1) Standard_ConstructionError::Raise("Approx_CurvlinFunc::GetUParameter");
+  if(S < 0 || S > 1) throw Standard_ConstructionError("Approx_CurvlinFunc::GetUParameter");
 
   if(NumberOfCurve == 1) {
     InitUArray = myUi_1;
@@ -527,7 +527,7 @@ Standard_Real Approx_CurvlinFunc::GetSParameter(Adaptor3d_Curve& C, const Standa
 
 Standard_Boolean Approx_CurvlinFunc::EvalCase1(const Standard_Real S, const Standard_Integer Order, TColStd_Array1OfReal& Result) const
 {
-  if(myCase != 1) Standard_ConstructionError::Raise("Approx_CurvlinFunc::EvalCase1");
+  if(myCase != 1) throw Standard_ConstructionError("Approx_CurvlinFunc::EvalCase1");
 
   gp_Pnt C;
   gp_Vec dC_dU, dC_dS, d2C_dU2, d2C_dS2;
@@ -576,7 +576,7 @@ Standard_Boolean Approx_CurvlinFunc::EvalCase1(const Standard_Real S, const Stan
 
 Standard_Boolean Approx_CurvlinFunc::EvalCase2(const Standard_Real S, const Standard_Integer Order, TColStd_Array1OfReal& Result) const
 {
-  if(myCase != 2) Standard_ConstructionError::Raise("Approx_CurvlinFunc::EvalCase2");
+  if(myCase != 2) throw Standard_ConstructionError("Approx_CurvlinFunc::EvalCase2");
 
   Standard_Boolean Done;
 
@@ -587,7 +587,7 @@ Standard_Boolean Approx_CurvlinFunc::EvalCase2(const Standard_Real S, const Stan
 
 Standard_Boolean Approx_CurvlinFunc::EvalCase3(const Standard_Real S, const Standard_Integer Order, TColStd_Array1OfReal& Result)
 {
-  if(myCase != 3) Standard_ConstructionError::Raise("Approx_CurvlinFunc::EvalCase3");
+  if(myCase != 3) throw Standard_ConstructionError("Approx_CurvlinFunc::EvalCase3");
   
   TColStd_Array1OfReal tmpRes1(0, 4), tmpRes2(0, 4);
   Standard_Boolean Done;
@@ -629,7 +629,7 @@ Standard_Boolean Approx_CurvlinFunc::EvalCurOnSur(const Standard_Real S, const S
     Length = myLength2;
   }
   else 
-    Standard_ConstructionError::Raise("Approx_CurvlinFunc::EvalCurOnSur");
+    throw Standard_ConstructionError("Approx_CurvlinFunc::EvalCurOnSur");
 
   Standard_Real Mag, dU_dS, d2U_dS2, dV_dU, dW_dU, dV_dS, dW_dS, d2V_dS2, d2W_dS2, d2V_dU2, d2W_dU2;
   gp_Pnt2d C2D;
index 1f31e78..3ad64ad 100644 (file)
@@ -604,7 +604,7 @@ void Approx_SameParameter::Build(const Standard_Real Tolerance)
     BSplCLib::Interpolate(3,FlatKnots,InterpolationParameters,ContactOrder,
       1,Poles(1),inversion_problem);
     if(inversion_problem) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
 
     // Test if par2d(par3d) is monotonous function or not           ----- IFV, Jan 2000
@@ -841,7 +841,7 @@ void Approx_SameParameter::Build(const Standard_Real Tolerance)
                           1,Poles(1),inversion_problem);
     if(inversion_problem)
     {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
 
     Standard_Real besttol = sqrt(besttol2);
index 681f288..590e713 100644 (file)
@@ -610,7 +610,7 @@ SurfShape(Standard_Integer& UDegree,
          Standard_Integer& NbUKnots,
          Standard_Integer& NbVKnots) const
 {
-  if (!done) {StdFail_NotDone::Raise("Approx_SweepApproximation");}
+  if (!done) {throw StdFail_NotDone("Approx_SweepApproximation");}
   UDegree  = udeg;
   VDegree  = vdeg;
   NbUPoles = tabPoles->ColLength();
@@ -627,7 +627,7 @@ Surface(TColgp_Array2OfPnt& TPoles,
        TColStd_Array1OfInteger& TUMults,
        TColStd_Array1OfInteger& TVMults) const
 {
-  if (!done) {StdFail_NotDone::Raise("Approx_SweepApproximation");}
+  if (!done) {throw StdFail_NotDone("Approx_SweepApproximation");}
   TPoles   = tabPoles->Array2();
   TWeights = tabWeights->Array2();
   TUKnots  = tabUKnots->Array1();
@@ -640,7 +640,7 @@ Standard_Real Approx_SweepApproximation::MaxErrorOnSurf() const
 {
  Standard_Integer ii;
  Standard_Real MaxError = 0, err;
- if (!done) {StdFail_NotDone::Raise("Approx_SweepApproximation");}
+ if (!done) {throw StdFail_NotDone("Approx_SweepApproximation");}
 
  if (myFunc->IsRational()) {
    TColStd_Array1OfReal Wmin(1, Num1DSS);
@@ -664,7 +664,7 @@ Standard_Real Approx_SweepApproximation::MaxErrorOnSurf() const
 {
  Standard_Integer ii;
  Standard_Real MoyError = 0, err;
- if (!done) {StdFail_NotDone::Raise("Approx_SweepApproximation");}
+ if (!done) {throw StdFail_NotDone("Approx_SweepApproximation");}
 
  if (myFunc->IsRational()) {
    TColStd_Array1OfReal Wmin(1, Num1DSS);
@@ -689,8 +689,8 @@ void Approx_SweepApproximation::Curves2dShape(Standard_Integer& Degree,
                                              Standard_Integer& NbPoles,
                                              Standard_Integer& NbKnots) const
 {
-  if (!done) {StdFail_NotDone::Raise("Approx_SweepApproximation");}
-  if (seqPoles2d.Length() == 0) {Standard_DomainError::Raise("Approx_SweepApproximation");}
+  if (!done) {throw StdFail_NotDone("Approx_SweepApproximation");}
+  if (seqPoles2d.Length() == 0) {throw Standard_DomainError("Approx_SweepApproximation");}
   Degree = deg2d;
   NbPoles = seqPoles2d(1)->Length();
   NbKnots = tab2dKnots->Length();
@@ -701,8 +701,8 @@ void Approx_SweepApproximation::Curve2d(const Standard_Integer Index,
                                        TColStd_Array1OfReal& TKnots,
                                        TColStd_Array1OfInteger& TMults) const
 {
-  if (!done) {StdFail_NotDone::Raise("Approx_SweepApproximation");}
-  if (seqPoles2d.Length() == 0) {Standard_DomainError::Raise("Approx_SweepApproximation");}
+  if (!done) {throw StdFail_NotDone("Approx_SweepApproximation");}
+  if (seqPoles2d.Length() == 0) {throw Standard_DomainError("Approx_SweepApproximation");}
   TPoles = seqPoles2d(Index)->Array1();
   TKnots  = tab2dKnots->Array1();
   TMults  = tab2dMults->Array1(); 
@@ -710,19 +710,19 @@ void Approx_SweepApproximation::Curve2d(const Standard_Integer Index,
 
  Standard_Real Approx_SweepApproximation::Max2dError(const Standard_Integer Index) const
 {
-  if (!done) {StdFail_NotDone::Raise("Approx_SweepApproximation");}
+  if (!done) {throw StdFail_NotDone("Approx_SweepApproximation");}
   return tab2dError->Value(Index);
 }
 
  Standard_Real Approx_SweepApproximation::Average2dError(const Standard_Integer Index) const
 {
-  if (!done) {StdFail_NotDone::Raise("Approx_SweepApproximation");}
+  if (!done) {throw StdFail_NotDone("Approx_SweepApproximation");}
   return Ave2dError->Value(Index); 
 }
 
 Standard_Real Approx_SweepApproximation::TolCurveOnSurf(const Standard_Integer Index) const
 {
-  if (!done) {StdFail_NotDone::Raise("Approx_SweepApproximation");}
+  if (!done) {throw StdFail_NotDone("Approx_SweepApproximation");}
   return  COnSurfErr->Value(Index);
 }
 
index 5770d53..3ab47f5 100644 (file)
@@ -29,95 +29,95 @@ inline  Standard_Boolean Approx_SweepApproximation::IsDone() const
  
 inline  Standard_Integer Approx_SweepApproximation::UDegree() const
 {
-  if (!done) {StdFail_NotDone::Raise(" Approx_SweepApproximation");}
+  if (!done) {throw StdFail_NotDone(" Approx_SweepApproximation");}
   return udeg;
 }
 
  
 inline  Standard_Integer Approx_SweepApproximation::VDegree() const
 {
-  if (!done) {StdFail_NotDone::Raise(" Approx_SweepApproximation");}
+  if (!done) {throw StdFail_NotDone(" Approx_SweepApproximation");}
   return vdeg;
 }
 
  
 inline const TColgp_Array2OfPnt& Approx_SweepApproximation::SurfPoles() const
 {
-  if (!done) {StdFail_NotDone::Raise(" Approx_SweepApproximation");}
+  if (!done) {throw StdFail_NotDone(" Approx_SweepApproximation");}
   return tabPoles->Array2();
 }
 
  
 inline const TColStd_Array2OfReal& Approx_SweepApproximation::SurfWeights() const
 {
-  if (!done) {StdFail_NotDone::Raise(" Approx_SweepApproximation");}
+  if (!done) {throw StdFail_NotDone(" Approx_SweepApproximation");}
   return tabWeights->Array2();
 }
 
  
 inline const TColStd_Array1OfReal& Approx_SweepApproximation::SurfUKnots() const
 {
-  if (!done) {StdFail_NotDone::Raise(" Approx_SweepApproximation");}
+  if (!done) {throw StdFail_NotDone(" Approx_SweepApproximation");}
   return tabUKnots->Array1();
 }
 
  
 inline const TColStd_Array1OfReal& Approx_SweepApproximation::SurfVKnots() const
 {
-  if (!done) {StdFail_NotDone::Raise(" Approx_SweepApproximation");}
+  if (!done) {throw StdFail_NotDone(" Approx_SweepApproximation");}
   return tabVKnots->Array1();
 }
 
  
 inline const TColStd_Array1OfInteger& Approx_SweepApproximation::SurfUMults() const
 {
-  if (!done) {StdFail_NotDone::Raise(" Approx_SweepApproximation");}
+  if (!done) {throw StdFail_NotDone(" Approx_SweepApproximation");}
   return tabUMults->Array1();
 }
 
  
 inline const TColStd_Array1OfInteger& Approx_SweepApproximation::SurfVMults() const
 {
-  if (!done) {StdFail_NotDone::Raise(" Approx_SweepApproximation");}
+  if (!done) {throw StdFail_NotDone(" Approx_SweepApproximation");}
   return tabVMults->Array1();
 }
 
  
 inline  Standard_Integer Approx_SweepApproximation::NbCurves2d() const
 {
-  if (!done) {StdFail_NotDone::Raise(" Approx_SweepApproximation");}
+  if (!done) {throw StdFail_NotDone(" Approx_SweepApproximation");}
   return Num2DSS;
 }
 
  
 inline  Standard_Integer Approx_SweepApproximation::Curves2dDegree() const
 {
-  if (!done) {StdFail_NotDone::Raise(" Approx_SweepApproximation");}
-  if (seqPoles2d.Length() == 0) {Standard_DomainError::Raise();}
+  if (!done) {throw StdFail_NotDone(" Approx_SweepApproximation");}
+  if (seqPoles2d.Length() == 0) {throw Standard_DomainError();}
   return deg2d;
 }
 
  
 inline const TColgp_Array1OfPnt2d& Approx_SweepApproximation::Curve2dPoles(const Standard_Integer Index) const
 {
-  if (!done) {StdFail_NotDone::Raise(" Approx_SweepApproximation");}
- if (seqPoles2d.Length() == 0) {Standard_DomainError::Raise();}
+  if (!done) {throw StdFail_NotDone(" Approx_SweepApproximation");}
+ if (seqPoles2d.Length() == 0) {throw Standard_DomainError();}
   return seqPoles2d(Index)->Array1();
 }
 
  
 inline const TColStd_Array1OfReal& Approx_SweepApproximation::Curves2dKnots() const
 {
-  if (!done) {StdFail_NotDone::Raise(" Approx_SweepApproximation");}
-  if (seqPoles2d.Length() == 0) {Standard_DomainError::Raise();}
+  if (!done) {throw StdFail_NotDone(" Approx_SweepApproximation");}
+  if (seqPoles2d.Length() == 0) {throw Standard_DomainError();}
   return tab2dKnots->Array1();
 }
 
  
 inline const TColStd_Array1OfInteger& Approx_SweepApproximation::Curves2dMults() const
 {
-  if (!done) {StdFail_NotDone::Raise(" Approx_SweepApproximation");}
- if (seqPoles2d.Length() == 0) {Standard_DomainError::Raise();}
+  if (!done) {throw StdFail_NotDone(" Approx_SweepApproximation");}
+ if (seqPoles2d.Length() == 0) {throw Standard_DomainError();}
   return tab2dMults->Array1();
 }
 
index 634b77f..afba0ae 100644 (file)
@@ -26,37 +26,33 @@ IMPLEMENT_STANDARD_RTTIEXT(Approx_SweepFunction,MMgt_TShared)
 // Standard_Boolean Approx_SweepFunction::D1(const Standard_Real Param,const Standard_Real First,const Standard_Real Last,TColgp_Array1OfPnt& Poles,TColgp_Array1OfVec& DPoles,TColgp_Array1OfPnt2d& Poles2d,TColgp_Array1OfVec2d& DPoles2d,TColStd_Array1OfReal& Weigths,TColStd_Array1OfReal& DWeigths) 
 Standard_Boolean Approx_SweepFunction::D1(const Standard_Real ,const Standard_Real ,const Standard_Real ,TColgp_Array1OfPnt& ,TColgp_Array1OfVec& ,TColgp_Array1OfPnt2d& ,TColgp_Array1OfVec2d& ,TColStd_Array1OfReal& ,TColStd_Array1OfReal& ) 
 {
- Standard_NotImplemented::Raise("Approx_SweepFunction::D1");
- return Standard_False;
+ throw Standard_NotImplemented("Approx_SweepFunction::D1");
 }
 
 // Standard_Boolean Approx_SweepFunction::D2(const Standard_Real Param,const Standard_Real First,const Standard_Real Last,TColgp_Array1OfPnt& Poles,TColgp_Array1OfVec& DPoles,TColgp_Array1OfVec& D2Poles,TColgp_Array1OfPnt2d& Poles2d,TColgp_Array1OfVec2d& DPoles2d,TColgp_Array1OfVec2d& D2Poles2d,TColStd_Array1OfReal& Weigths,TColStd_Array1OfReal& DWeigths,TColStd_Array1OfReal& D2Weigths) 
  Standard_Boolean Approx_SweepFunction::D2(const Standard_Real ,const Standard_Real ,const Standard_Real ,TColgp_Array1OfPnt& ,TColgp_Array1OfVec& ,TColgp_Array1OfVec& ,TColgp_Array1OfPnt2d& ,TColgp_Array1OfVec2d& ,TColgp_Array1OfVec2d& ,TColStd_Array1OfReal& ,TColStd_Array1OfReal& ,TColStd_Array1OfReal& ) 
 {
- Standard_NotImplemented::Raise("Approx_SweepFunction::D2");
- return Standard_False;
+ throw Standard_NotImplemented("Approx_SweepFunction::D2");
 }
 
 // void Approx_SweepFunction::Resolution(const Standard_Integer Index,const Standard_Real Tol,Standard_Real& TolU,Standard_Real& TolV) const
  void Approx_SweepFunction::Resolution(const Standard_Integer ,const Standard_Real ,Standard_Real& ,Standard_Real& ) const
 {
- Standard_NotImplemented::Raise("Approx_SweepFunction::Resolution");  
+ throw Standard_NotImplemented("Approx_SweepFunction::Resolution");
 }
 
  gp_Pnt Approx_SweepFunction::BarycentreOfSurf() const
 {
- Standard_NotImplemented::Raise("Approx_SweepFunction::BarycentreOfSurf");
- return gp_Pnt(0.,0.,0.);
+ throw Standard_NotImplemented("Approx_SweepFunction::BarycentreOfSurf");
 }
 
  Standard_Real Approx_SweepFunction::MaximalSection() const
 {
-  Standard_NotImplemented::Raise("Approx_SweepFunction::MaximalSection()");
-  return 0;
+  throw Standard_NotImplemented("Approx_SweepFunction::MaximalSection()");
 }
 
 // void Approx_SweepFunction::GetMinimalWeight(TColStd_Array1OfReal& Weigths) const
  void Approx_SweepFunction::GetMinimalWeight(TColStd_Array1OfReal& ) const
 {
Standard_NotImplemented::Raise("Approx_SweepFunction::GetMinimalWeight");
throw Standard_NotImplemented("Approx_SweepFunction::GetMinimalWeight");
 }
index 6d7102b..cad7427 100644 (file)
@@ -26,7 +26,7 @@ DEFINE_STANDARD_HANDLE(Aspect_AspectFillAreaDefinitionError, Standard_OutOfRange
 
 #if !defined No_Exception && !defined No_Aspect_AspectFillAreaDefinitionError
   #define Aspect_AspectFillAreaDefinitionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Aspect_AspectFillAreaDefinitionError::Raise(MESSAGE);
+  if (CONDITION) throw Aspect_AspectFillAreaDefinitionError(MESSAGE);
 #else
   #define Aspect_AspectFillAreaDefinitionError_Raise_if(CONDITION, MESSAGE)
 #endif
index 38eae75..abde5a8 100644 (file)
@@ -26,7 +26,7 @@ DEFINE_STANDARD_HANDLE(Aspect_AspectLineDefinitionError, Standard_OutOfRange)
 
 #if !defined No_Exception && !defined No_Aspect_AspectLineDefinitionError
   #define Aspect_AspectLineDefinitionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Aspect_AspectLineDefinitionError::Raise(MESSAGE);
+  if (CONDITION) throw Aspect_AspectLineDefinitionError(MESSAGE);
 #else
   #define Aspect_AspectLineDefinitionError_Raise_if(CONDITION, MESSAGE)
 #endif
index 825a742..1451779 100644 (file)
@@ -26,7 +26,7 @@ DEFINE_STANDARD_HANDLE(Aspect_AspectMarkerDefinitionError, Standard_OutOfRange)
 
 #if !defined No_Exception && !defined No_Aspect_AspectMarkerDefinitionError
   #define Aspect_AspectMarkerDefinitionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Aspect_AspectMarkerDefinitionError::Raise(MESSAGE);
+  if (CONDITION) throw Aspect_AspectMarkerDefinitionError(MESSAGE);
 #else
   #define Aspect_AspectMarkerDefinitionError_Raise_if(CONDITION, MESSAGE)
 #endif
index 8a071fb..6c82d11 100644 (file)
@@ -26,7 +26,7 @@ DEFINE_STANDARD_HANDLE(Aspect_BadAccess, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Aspect_BadAccess
   #define Aspect_BadAccess_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Aspect_BadAccess::Raise(MESSAGE);
+  if (CONDITION) throw Aspect_BadAccess(MESSAGE);
 #else
   #define Aspect_BadAccess_Raise_if(CONDITION, MESSAGE)
 #endif
index e15349a..e119a7a 100755 (executable)
@@ -89,7 +89,7 @@ void Aspect_DisplayConnection::Init()
     TCollection_AsciiString aMessage;
     aMessage += "Can not connect to the server \"";
     aMessage += myDisplayName + "\"";
-    Aspect_DisplayConnectionDefinitionError::Raise (aMessage.ToCString());
+    throw Aspect_DisplayConnectionDefinitionError(aMessage.ToCString());
   }
 }
 
index 41e24ae..434769b 100644 (file)
@@ -26,7 +26,7 @@ DEFINE_STANDARD_HANDLE(Aspect_DisplayConnectionDefinitionError, Standard_OutOfRa
 
 #if !defined No_Exception && !defined No_Aspect_DisplayConnectionDefinitionError
   #define Aspect_DisplayConnectionDefinitionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Aspect_DisplayConnectionDefinitionError::Raise(MESSAGE);
+  if (CONDITION) throw Aspect_DisplayConnectionDefinitionError(MESSAGE);
 #else
   #define Aspect_DisplayConnectionDefinitionError_Raise_if(CONDITION, MESSAGE)
 #endif
index 1581d58..465784b 100644 (file)
@@ -26,7 +26,7 @@ DEFINE_STANDARD_HANDLE(Aspect_DriverDefinitionError, Standard_OutOfRange)
 
 #if !defined No_Exception && !defined No_Aspect_DriverDefinitionError
   #define Aspect_DriverDefinitionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Aspect_DriverDefinitionError::Raise(MESSAGE);
+  if (CONDITION) throw Aspect_DriverDefinitionError(MESSAGE);
 #else
   #define Aspect_DriverDefinitionError_Raise_if(CONDITION, MESSAGE)
 #endif
index 1f3bbad..cca7eca 100644 (file)
@@ -44,7 +44,7 @@ Aspect_GenId::Aspect_GenId (const Standard_Integer theLow,
 {
   if (theLow > theUpper)
   {
-    Aspect_IdentDefinitionError::Raise ("GenId Create Error: wrong interval");
+    throw Aspect_IdentDefinitionError("GenId Create Error: wrong interval");
   }
 }
 
@@ -121,7 +121,7 @@ Standard_Integer Aspect_GenId::Next()
   }
   else if (myFreeCount < 1)
   {
-    Aspect_IdentDefinitionError::Raise ("GenId Next Error: Available == 0");
+    throw Aspect_IdentDefinitionError("GenId Next Error: Available == 0");
   }
 
   --myFreeCount;
index 5c4b9f0..f9deefd 100644 (file)
@@ -26,7 +26,7 @@ DEFINE_STANDARD_HANDLE(Aspect_GraphicDeviceDefinitionError, Standard_OutOfRange)
 
 #if !defined No_Exception && !defined No_Aspect_GraphicDeviceDefinitionError
   #define Aspect_GraphicDeviceDefinitionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Aspect_GraphicDeviceDefinitionError::Raise(MESSAGE);
+  if (CONDITION) throw Aspect_GraphicDeviceDefinitionError(MESSAGE);
 #else
   #define Aspect_GraphicDeviceDefinitionError_Raise_if(CONDITION, MESSAGE)
 #endif
index ecb91a0..cd0d9ba 100644 (file)
@@ -26,7 +26,7 @@ DEFINE_STANDARD_HANDLE(Aspect_IdentDefinitionError, Standard_OutOfRange)
 
 #if !defined No_Exception && !defined No_Aspect_IdentDefinitionError
   #define Aspect_IdentDefinitionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Aspect_IdentDefinitionError::Raise(MESSAGE);
+  if (CONDITION) throw Aspect_IdentDefinitionError(MESSAGE);
 #else
   #define Aspect_IdentDefinitionError_Raise_if(CONDITION, MESSAGE)
 #endif
index 08df89a..572675a 100644 (file)
@@ -26,7 +26,7 @@ DEFINE_STANDARD_HANDLE(Aspect_WindowDefinitionError, Standard_OutOfRange)
 
 #if !defined No_Exception && !defined No_Aspect_WindowDefinitionError
   #define Aspect_WindowDefinitionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Aspect_WindowDefinitionError::Raise(MESSAGE);
+  if (CONDITION) throw Aspect_WindowDefinitionError(MESSAGE);
 #else
   #define Aspect_WindowDefinitionError_Raise_if(CONDITION, MESSAGE)
 #endif
index 42bdfa9..6c7a494 100644 (file)
@@ -26,7 +26,7 @@ DEFINE_STANDARD_HANDLE(Aspect_WindowError, Standard_OutOfRange)
 
 #if !defined No_Exception && !defined No_Aspect_WindowError
   #define Aspect_WindowError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Aspect_WindowError::Raise(MESSAGE);
+  if (CONDITION) throw Aspect_WindowError(MESSAGE);
 #else
   #define Aspect_WindowError_Raise_if(CONDITION, MESSAGE)
 #endif
index 22265f9..0a73b8b 100644 (file)
@@ -173,7 +173,7 @@ void BOPAlgo_Algo::UserBreak() const
     return;
   }
   if (myProgressIndicator->UserBreak()) {
-    Standard_NotImplemented::Raise("");
+    throw Standard_NotImplemented("");
   }
 } 
 //  myErrorStatus
index 8b249f8..657c397 100644 (file)
@@ -662,7 +662,7 @@ void BOPTools_AlgoTools2D::MakePCurveOnFace
   //
   if(aC2D.IsNull())
   {
-    Standard_ConstructionError::Raise("BOPTools_AlgoTools2D::MakePCurveOnFace : PCurve is Null");
+    throw Standard_ConstructionError("BOPTools_AlgoTools2D::MakePCurveOnFace : PCurve is Null");
   }
   //
   TolReached2d=aTolR;
@@ -717,8 +717,7 @@ void  BOPTools_AlgoTools2D::MakePCurveOfType
   case GeomAbs_BezierCurve : 
   case GeomAbs_OtherCurve : 
     default :
-    Standard_NotImplemented::Raise
-      ("BOPTools_AlgoTools2D::MakePCurveOfType");
+    throw Standard_NotImplemented("BOPTools_AlgoTools2D::MakePCurveOfType");
     break;
   }
 }
index 2cfc5d2..682a471 100644 (file)
@@ -452,7 +452,7 @@ void  BRep_Builder::MakeFace(TopoDS_Face& F,
   Handle(BRep_TFace) TF = new BRep_TFace();
   if(!F.IsNull() && F.Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::MakeFace");
+    throw TopoDS_LockedShape("BRep_Builder::MakeFace");
   }
   TF->Surface(S);
   TF->Tolerance(Tol);
@@ -471,7 +471,7 @@ void  BRep_Builder::MakeFace(TopoDS_Face&                      F,
   Handle(BRep_TFace) TF = new BRep_TFace();
   if(!F.IsNull() && F.Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::MakeFace");
+    throw TopoDS_LockedShape("BRep_Builder::MakeFace");
   }
   TF->Triangulation(T);
   MakeShape(F, TF);
@@ -491,7 +491,7 @@ void  BRep_Builder::MakeFace(TopoDS_Face& F,
   Handle(BRep_TFace) TF = new BRep_TFace();
   if(!F.IsNull() && F.Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::MakeFace");
+    throw TopoDS_LockedShape("BRep_Builder::MakeFace");
   }
   TF->Surface(S);
   TF->Tolerance(Tol);
@@ -513,7 +513,7 @@ void  BRep_Builder::UpdateFace(const TopoDS_Face& F,
   const Handle(BRep_TFace)& TF = *((Handle(BRep_TFace)*) &F.TShape());
   if(TF->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateFace");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateFace");
   }
   TF->Surface(S);
   TF->Tolerance(Tol);
@@ -533,7 +533,7 @@ void  BRep_Builder::UpdateFace(const TopoDS_Face& F,
   const Handle(BRep_TFace)& TF = *((Handle(BRep_TFace)*) &F.TShape());
   if(TF->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateFace");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateFace");
   }
   TF->Triangulation(T);
   F.TShape()->Modified(Standard_True);
@@ -551,7 +551,7 @@ void  BRep_Builder::UpdateFace(const TopoDS_Face& F,
   const Handle(BRep_TFace)& TF = *((Handle(BRep_TFace)*) &F.TShape());
   if(TF->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateFace");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateFace");
   }
   TF->Tolerance(Tol);
   F.TShape()->Modified(Standard_True);
@@ -569,7 +569,7 @@ void  BRep_Builder::NaturalRestriction(const TopoDS_Face& F,
   const Handle(BRep_TFace)& TF = (*((Handle(BRep_TFace)*) &F.TShape()));
   if(TF->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::NaturalRestriction");
+    throw TopoDS_LockedShape("BRep_Builder::NaturalRestriction");
   }
   TF->NaturalRestriction(N);
   F.TShape()->Modified(Standard_True);
@@ -586,7 +586,7 @@ void  BRep_Builder::MakeEdge(TopoDS_Edge& E) const
   Handle(BRep_TEdge) TE = new BRep_TEdge();
   if(!E.IsNull() && E.Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::MakeEdge");
+    throw TopoDS_LockedShape("BRep_Builder::MakeEdge");
   }
   MakeShape(E,TE);
 }
@@ -605,7 +605,7 @@ void  BRep_Builder::UpdateEdge(const TopoDS_Edge& E,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateEdge");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateEdge");
   }
   const TopLoc_Location l = L.Predivided(E.Location());
 
@@ -630,7 +630,7 @@ void  BRep_Builder::UpdateEdge(const TopoDS_Edge& E,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateEdge");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateEdge");
   }
   const TopLoc_Location l = L.Predivided(E.Location());
 
@@ -657,7 +657,7 @@ void  BRep_Builder::UpdateEdge(const TopoDS_Edge& E,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateEdge");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateEdge");
   }
   const TopLoc_Location l = L.Predivided(E.Location());
 
@@ -683,7 +683,7 @@ void  BRep_Builder::UpdateEdge(const TopoDS_Edge& E,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateEdge");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateEdge");
   }
   const TopLoc_Location l = L.Predivided(E.Location());
 
@@ -711,7 +711,7 @@ void  BRep_Builder::UpdateEdge(const TopoDS_Edge& E,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateEdge");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateEdge");
   }
   const TopLoc_Location l = L.Predivided(E.Location());
 
@@ -734,7 +734,7 @@ void  BRep_Builder::UpdateEdge(const TopoDS_Edge& E,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateEdge");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateEdge");
   }
   BRep_ListOfCurveRepresentation& lcr = TE->ChangeCurves();
   BRep_ListIteratorOfListOfCurveRepresentation itcr(lcr);
@@ -774,7 +774,7 @@ void  BRep_Builder::UpdateEdge(const TopoDS_Edge& E,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateEdge");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateEdge");
   }
   const TopLoc_Location l = L.Predivided(E.Location());
 
@@ -825,7 +825,7 @@ void  BRep_Builder::UpdateEdge(const TopoDS_Edge& E,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateEdge");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateEdge");
   }
   const TopLoc_Location l = L.Predivided(E.Location());
 
@@ -888,7 +888,7 @@ void  BRep_Builder::UpdateEdge(const TopoDS_Edge&            E,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateEdge");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateEdge");
   }
   TopLoc_Location l = L.Predivided(E.Location());
 
@@ -946,7 +946,7 @@ void  BRep_Builder::UpdateEdge(const TopoDS_Edge&            E,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateEdge");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateEdge");
   }
   TopLoc_Location l = L.Predivided(E.Location());
   
@@ -986,7 +986,7 @@ void  BRep_Builder::UpdateEdge(const TopoDS_Edge& E,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateEdge");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateEdge");
   }
   TE->UpdateTolerance(Tol);
   TE->Modified(Standard_True);
@@ -1024,7 +1024,7 @@ void  BRep_Builder::Continuity(const TopoDS_Edge& E,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::Continuity");
+    throw TopoDS_LockedShape("BRep_Builder::Continuity");
   }
   const TopLoc_Location l1 = L1.Predivided(E.Location());
   const TopLoc_Location l2 = L2.Predivided(E.Location());
@@ -1045,7 +1045,7 @@ void  BRep_Builder::SameParameter(const TopoDS_Edge& E,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::SameParameter");
+    throw TopoDS_LockedShape("BRep_Builder::SameParameter");
   }
   TE->SameParameter(S);
   TE->Modified(Standard_True);
@@ -1062,7 +1062,7 @@ void  BRep_Builder::SameRange(const TopoDS_Edge& E,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::SameRange");
+    throw TopoDS_LockedShape("BRep_Builder::SameRange");
   }
   TE->SameRange(S);
   TE->Modified(Standard_True);
@@ -1079,7 +1079,7 @@ void  BRep_Builder::Degenerated(const TopoDS_Edge& E,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::Degenerated");
+    throw TopoDS_LockedShape("BRep_Builder::Degenerated");
   }
   TE->Degenerated(D);
   if (D) {
@@ -1104,7 +1104,7 @@ void  BRep_Builder::Range(const TopoDS_Edge&  E,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::Range");
+    throw TopoDS_LockedShape("BRep_Builder::Range");
   }
   BRep_ListOfCurveRepresentation& lcr = TE->ChangeCurves();
   BRep_ListIteratorOfListOfCurveRepresentation itcr(lcr);
@@ -1135,7 +1135,7 @@ void  BRep_Builder::Range(const TopoDS_Edge& E,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::Range");
+    throw TopoDS_LockedShape("BRep_Builder::Range");
   }
   const TopLoc_Location l = L.Predivided(E.Location());
 
@@ -1154,7 +1154,7 @@ void  BRep_Builder::Range(const TopoDS_Edge& E,
   }
   
   if (!itcr.More())
-    Standard_DomainError::Raise("BRep_Builder::Range, no pcurve");
+    throw Standard_DomainError("BRep_Builder::Range, no pcurve");
   
   TE->Modified(Standard_True);
 }
@@ -1171,7 +1171,7 @@ void  BRep_Builder::Transfert(const TopoDS_Edge& Ein,
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &Ein.TShape());
   if(TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::Transfert");
+    throw TopoDS_LockedShape("BRep_Builder::Transfert");
   }
   const Standard_Real tol = TE->Tolerance();
 
@@ -1223,7 +1223,7 @@ void  BRep_Builder::UpdateVertex(const TopoDS_Vertex& V,
   const Handle(BRep_TVertex)& TV = *((Handle(BRep_TVertex)*) &V.TShape());
   if(TV->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateVertex");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateVertex");
   }
   TV->Pnt(P.Transformed(V.Location().Inverted().Transformation()));
   TV->UpdateTolerance(Tol);
@@ -1243,14 +1243,14 @@ void  BRep_Builder::UpdateVertex(const TopoDS_Vertex& V,
 {
   if (Precision::IsPositiveInfinite(Par) ||
       Precision::IsNegativeInfinite(Par))
-    Standard_DomainError::Raise("BRep_Builder::Infinite parameter");
+    throw Standard_DomainError("BRep_Builder::Infinite parameter");
   
   const Handle(BRep_TVertex)& TV = *((Handle(BRep_TVertex)*) &V.TShape());
   const Handle(BRep_TEdge)& TE = *((Handle(BRep_TEdge)*) &E.TShape());
 
   if(TV->Locked() || TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateVertex");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateVertex");
   }
 
   TopLoc_Location L = E.Location().Predivided(V.Location());
@@ -1326,7 +1326,7 @@ void  BRep_Builder::UpdateVertex(const TopoDS_Vertex& V,
 {
   if (Precision::IsPositiveInfinite(Par) ||
       Precision::IsNegativeInfinite(Par))
-    Standard_DomainError::Raise("BRep_Builder::Infinite parameter");
+    throw Standard_DomainError("BRep_Builder::Infinite parameter");
   
   // Find the curve representation
   TopLoc_Location l = L.Predivided(V.Location());
@@ -1336,7 +1336,7 @@ void  BRep_Builder::UpdateVertex(const TopoDS_Vertex& V,
   
   if(TV->Locked() || TE->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateVertex");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateVertex");
   }
   
   // Search the vertex in the edge
@@ -1386,7 +1386,7 @@ void  BRep_Builder::UpdateVertex(const TopoDS_Vertex& V,
   }
   
   if (!itcr.More())
-    Standard_DomainError::Raise("BRep_Builder:: no pcurve");
+    throw Standard_DomainError("BRep_Builder:: no pcurve");
   
   TV->UpdateTolerance(Tol);
   TE->Modified(Standard_True);
@@ -1407,7 +1407,7 @@ void  BRep_Builder::UpdateVertex(const TopoDS_Vertex& Ve,
   
   if(TV->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateVertex");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateVertex");
   }
   
   TopLoc_Location L;
@@ -1432,7 +1432,7 @@ void  BRep_Builder::UpdateVertex(const TopoDS_Vertex& V,
     
   if(TV->Locked())
   {
-    TopoDS_LockedShape::Raise("BRep_Builder::UpdateVertex");
+    throw TopoDS_LockedShape("BRep_Builder::UpdateVertex");
   }
   
   TV->UpdateTolerance(Tol);
index dedf017..1ce978e 100644 (file)
@@ -49,7 +49,7 @@ BRep_CurveOn2Surfaces::BRep_CurveOn2Surfaces(const Handle(Geom_Surface)& S1,
 
 void  BRep_CurveOn2Surfaces::D0(const Standard_Real , gp_Pnt& )const 
 {
-  Standard_NullObject::Raise("BRep_CurveOn2Surfaces::D0");
+  throw Standard_NullObject("BRep_CurveOn2Surfaces::D0");
 }
 
 
index 29362dd..6986648 100644 (file)
@@ -193,8 +193,7 @@ Standard_Boolean  BRep_CurveRepresentation::IsPolygonOnSurface
 
 const Handle(Geom_Curve)&  BRep_CurveRepresentation::Curve3D()const 
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
-    return *((Handle(Geom_Curve)*) NULL);
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 //=======================================================================
@@ -204,7 +203,7 @@ const Handle(Geom_Curve)&  BRep_CurveRepresentation::Curve3D()const
 
 void BRep_CurveRepresentation::Curve3D(const Handle(Geom_Curve)&)
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 
@@ -218,8 +217,7 @@ void BRep_CurveRepresentation::Curve3D(const Handle(Geom_Curve)&)
 
 const Handle(Geom_Surface)&  BRep_CurveRepresentation::Surface()const 
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
-    return *((Handle(Geom_Surface)*) NULL);
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 
@@ -230,8 +228,7 @@ const Handle(Geom_Surface)&  BRep_CurveRepresentation::Surface()const
 
 const Handle(Geom2d_Curve)&  BRep_CurveRepresentation::PCurve()const 
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
-    return *((Handle(Geom2d_Curve)*) NULL);
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 //=======================================================================
@@ -241,8 +238,7 @@ const Handle(Geom2d_Curve)&  BRep_CurveRepresentation::PCurve()const
 
 const Handle(Geom2d_Curve)&  BRep_CurveRepresentation::PCurve2()const 
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
-    return *((Handle(Geom2d_Curve)*) NULL);
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 //=======================================================================
@@ -252,7 +248,7 @@ const Handle(Geom2d_Curve)&  BRep_CurveRepresentation::PCurve2()const
 
 void  BRep_CurveRepresentation::PCurve(const Handle(Geom2d_Curve)&)
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 //=======================================================================
@@ -262,7 +258,7 @@ void  BRep_CurveRepresentation::PCurve(const Handle(Geom2d_Curve)&)
 
 void  BRep_CurveRepresentation::PCurve2(const Handle(Geom2d_Curve)&)
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 
@@ -273,8 +269,7 @@ void  BRep_CurveRepresentation::PCurve2(const Handle(Geom2d_Curve)&)
 
 const GeomAbs_Shape&  BRep_CurveRepresentation::Continuity()const 
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
-    return *((GeomAbs_Shape*) NULL);
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 //=======================================================================
@@ -284,7 +279,7 @@ const GeomAbs_Shape&  BRep_CurveRepresentation::Continuity()const
 
 void BRep_CurveRepresentation::Continuity(const GeomAbs_Shape )
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 
@@ -295,8 +290,7 @@ void BRep_CurveRepresentation::Continuity(const GeomAbs_Shape )
 
 const Handle(Geom_Surface)&  BRep_CurveRepresentation::Surface2()const 
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
-    return *((Handle(Geom_Surface)*) NULL);
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 
@@ -307,8 +301,7 @@ const Handle(Geom_Surface)&  BRep_CurveRepresentation::Surface2()const
 
 const TopLoc_Location&  BRep_CurveRepresentation::Location2()const 
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
-    return *((TopLoc_Location*) NULL);
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 
@@ -320,8 +313,7 @@ const TopLoc_Location&  BRep_CurveRepresentation::Location2()const
 
 const Handle(Poly_Polygon3D)&  BRep_CurveRepresentation::Polygon3D()const 
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
-    return *((Handle(Poly_Polygon3D)*) NULL);
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 //=======================================================================
@@ -331,7 +323,7 @@ const Handle(Poly_Polygon3D)&  BRep_CurveRepresentation::Polygon3D()const
 
 void BRep_CurveRepresentation::Polygon3D(const Handle(Poly_Polygon3D)&)
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 
@@ -342,8 +334,7 @@ void BRep_CurveRepresentation::Polygon3D(const Handle(Poly_Polygon3D)&)
 
 const Handle(Poly_Polygon2D)&  BRep_CurveRepresentation::Polygon()const 
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
-  return *((Handle(Poly_Polygon2D)*) NULL);
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 
@@ -354,7 +345,7 @@ const Handle(Poly_Polygon2D)&  BRep_CurveRepresentation::Polygon()const
 
 void BRep_CurveRepresentation::Polygon(const Handle(Poly_Polygon2D)&)
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 //=======================================================================
@@ -364,8 +355,7 @@ void BRep_CurveRepresentation::Polygon(const Handle(Poly_Polygon2D)&)
 
 const Handle(Poly_PolygonOnTriangulation)& BRep_CurveRepresentation::PolygonOnTriangulation2() const
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
-  return *((Handle(Poly_PolygonOnTriangulation)*) NULL);
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 //=======================================================================
@@ -376,7 +366,7 @@ const Handle(Poly_PolygonOnTriangulation)& BRep_CurveRepresentation::PolygonOnTr
 void BRep_CurveRepresentation::PolygonOnTriangulation2
   (const Handle(Poly_PolygonOnTriangulation)&) 
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 
@@ -388,7 +378,7 @@ void BRep_CurveRepresentation::PolygonOnTriangulation2
 void BRep_CurveRepresentation::PolygonOnTriangulation
   (const Handle(Poly_PolygonOnTriangulation)&)
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 
@@ -400,8 +390,7 @@ void BRep_CurveRepresentation::PolygonOnTriangulation
 const Handle(Poly_PolygonOnTriangulation)& BRep_CurveRepresentation::PolygonOnTriangulation()
 const
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
-  return *(Handle(Poly_PolygonOnTriangulation)*)NULL;
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 //=======================================================================
 //function : Triangulation
@@ -411,8 +400,7 @@ const
 const Handle(Poly_Triangulation)& BRep_CurveRepresentation::Triangulation()
 const
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
-  return *(Handle(Poly_Triangulation)*)NULL;
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 
@@ -424,8 +412,7 @@ const
 
 const Handle(Poly_Polygon2D)&  BRep_CurveRepresentation::Polygon2()const 
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
-  return *((Handle(Poly_Polygon2D)*) NULL);
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
 
@@ -436,6 +423,6 @@ const Handle(Poly_Polygon2D)&  BRep_CurveRepresentation::Polygon2()const
 
 void BRep_CurveRepresentation::Polygon2(const Handle(Poly_Polygon2D)&)
 {
-  Standard_DomainError::Raise("BRep_CurveRepresentation");
+  throw Standard_DomainError("BRep_CurveRepresentation");
 }
 
index 2f8f20c..6a60ec8 100644 (file)
@@ -117,8 +117,7 @@ Standard_Boolean  BRep_PointRepresentation::IsPointOnSurface
 
 Standard_Real  BRep_PointRepresentation::Parameter2()const 
 {
-  Standard_DomainError::Raise("BRep_PointRepresentation");
-    return 0;
+  throw Standard_DomainError("BRep_PointRepresentation");
 }
 
 
@@ -129,7 +128,7 @@ Standard_Real  BRep_PointRepresentation::Parameter2()const
 
 void  BRep_PointRepresentation::Parameter2(const Standard_Real )
 {
-  Standard_DomainError::Raise("BRep_PointRepresentation");
+  throw Standard_DomainError("BRep_PointRepresentation");
 }
 
 
@@ -140,8 +139,7 @@ void  BRep_PointRepresentation::Parameter2(const Standard_Real )
 
 const Handle(Geom_Curve)&  BRep_PointRepresentation::Curve()const 
 {
-  Standard_DomainError::Raise("BRep_PointRepresentation");
-    return *((Handle(Geom_Curve)*) NULL);
+  throw Standard_DomainError("BRep_PointRepresentation");
 }
 
 
@@ -152,7 +150,7 @@ const Handle(Geom_Curve)&  BRep_PointRepresentation::Curve()const
 
 void  BRep_PointRepresentation::Curve(const Handle(Geom_Curve)& )
 {
-  Standard_DomainError::Raise("BRep_PointRepresentation");
+  throw Standard_DomainError("BRep_PointRepresentation");
 }
 
 
@@ -163,8 +161,7 @@ void  BRep_PointRepresentation::Curve(const Handle(Geom_Curve)& )
 
 const Handle(Geom2d_Curve)&  BRep_PointRepresentation::PCurve()const 
 {
-  Standard_DomainError::Raise("BRep_PointRepresentation");
-    return *((Handle(Geom2d_Curve)*) NULL);
+  throw Standard_DomainError("BRep_PointRepresentation");
 }
 
 
@@ -175,7 +172,7 @@ const Handle(Geom2d_Curve)&  BRep_PointRepresentation::PCurve()const
 
 void  BRep_PointRepresentation::PCurve(const Handle(Geom2d_Curve)& )
 {
-  Standard_DomainError::Raise("BRep_PointRepresentation");
+  throw Standard_DomainError("BRep_PointRepresentation");
 }
 
 
@@ -186,8 +183,7 @@ void  BRep_PointRepresentation::PCurve(const Handle(Geom2d_Curve)& )
 
 const Handle(Geom_Surface)&  BRep_PointRepresentation::Surface()const 
 {
-  Standard_DomainError::Raise("BRep_PointRepresentation");
-    return *((Handle(Geom_Surface)*) NULL);
+  throw Standard_DomainError("BRep_PointRepresentation");
 }
 
 
@@ -198,7 +194,7 @@ const Handle(Geom_Surface)&  BRep_PointRepresentation::Surface()const
 
 void  BRep_PointRepresentation::Surface(const Handle(Geom_Surface)& )
 {
-  Standard_DomainError::Raise("BRep_PointRepresentation");
+  throw Standard_DomainError("BRep_PointRepresentation");
 }
 
 
index 3fa6c65..d87c2ca 100644 (file)
@@ -1190,7 +1190,7 @@ gp_Pnt  BRep_Tool::Pnt(const TopoDS_Vertex& V)
   
   if (TV == 0)
   {
-    Standard_NullObject::Raise("BRep_Tool:: TopoDS_Vertex hasn't gp_Pnt");
+    throw Standard_NullObject("BRep_Tool:: TopoDS_Vertex hasn't gp_Pnt");
   }
 
   const gp_Pnt& P = TV->Pnt();
@@ -1213,7 +1213,7 @@ Standard_Real  BRep_Tool::Tolerance(const TopoDS_Vertex& V)
 
   if (aTVert == 0)
   {
-    Standard_NullObject::Raise("BRep_Tool:: TopoDS_Vertex hasn't gp_Pnt");
+    throw Standard_NullObject("BRep_Tool:: TopoDS_Vertex hasn't gp_Pnt");
   }
 
   Standard_Real p = aTVert->Tolerance();
@@ -1338,8 +1338,7 @@ Standard_Real  BRep_Tool::Parameter(const TopoDS_Vertex& V,
     }
   }
   
-  Standard_NoSuchObject::Raise("BRep_Tool:: no parameter on edge");
-  return 0;
+  throw Standard_NoSuchObject("BRep_Tool:: no parameter on edge");
 }
 
 //=======================================================================
@@ -1449,8 +1448,7 @@ Standard_Real BRep_Tool::Parameter(const TopoDS_Vertex& V,
   
 //----------------------------------------------------------   
  
-  Standard_NoSuchObject::Raise("BRep_Tool:: no parameter on edge");
-  return 0;
+  throw Standard_NoSuchObject("BRep_Tool:: no parameter on edge");
 }
 
 //=======================================================================
@@ -1491,8 +1489,7 @@ gp_Pnt2d  BRep_Tool::Parameters(const TopoDS_Vertex& V,
       else              return Pl;//Ambiguity (natural) for degenerated edges.
     }
   }
-  Standard_NoSuchObject::Raise("BRep_Tool:: no parameters on surface");
-  return gp_Pnt2d(0,0);
+  throw Standard_NoSuchObject("BRep_Tool:: no parameters on surface");
 }
 //=======================================================================
 //function : IsClosed
index c1b0751..4960d8d 100644 (file)
@@ -104,7 +104,7 @@ void BRepAdaptor_Curve::Initialize(const TopoDS_Edge& E)
       myConSurf->ChangeCurve().Load(HC, HS);
     }
     else {
-      Standard_NullObject::Raise("BRepAdaptor_Curve::No geometry");
+      throw Standard_NullObject("BRepAdaptor_Curve::No geometry");
     }
   }
   myTrsf = L.Transformation();
@@ -661,7 +661,7 @@ Handle(Geom_BSplineCurve) BRepAdaptor_Curve::BSpline() const
 Handle(Geom_OffsetCurve) BRepAdaptor_Curve::OffsetCurve() const
 {
   if ( !Is3DCurve() || myCurve.GetType() != GeomAbs_OffsetCurve)
-    Standard_NoSuchObject::Raise("BRepAdaptor_Curve::OffsetCurve");
+    throw Standard_NoSuchObject("BRepAdaptor_Curve::OffsetCurve");
 
   Handle(Geom_OffsetCurve) anOffC = myCurve.OffsetCurve();
   return myTrsf.Form() == gp_Identity
index a9f359e..d8e5b92 100644 (file)
@@ -299,10 +299,10 @@ void BRepAlgo_AsDes::Replace(const TopoDS_Shape& OldS,
 void BRepAlgo_AsDes::Remove(const TopoDS_Shape& SS)
 {
   if (down.IsBound(SS)) {
-    Standard_ConstructionError::Raise(" BRepAlgo_AsDes::Remove");
+    throw Standard_ConstructionError(" BRepAlgo_AsDes::Remove");
   }
   if (!up.IsBound(SS)) {
-    Standard_ConstructionError::Raise(" BRepAlgo_AsDes::Remove");
+    throw Standard_ConstructionError(" BRepAlgo_AsDes::Remove");
   }
   TopTools_ListIteratorOfListOfShape it(up(SS));
   for (; it.More(); it.Next()) {
index 496750f..2e101e4 100644 (file)
@@ -51,7 +51,7 @@ void BRepAlgo_Image::Bind(const TopoDS_Shape& OldS,
                            const TopoDS_Shape& NewS)
 {
   if (down.IsBound(OldS)) {
-    Standard_ConstructionError::Raise(" BRepAlgo_Image::Bind");
+    throw Standard_ConstructionError(" BRepAlgo_Image::Bind");
     return;
   }
   TopTools_ListOfShape L;
@@ -70,7 +70,7 @@ void BRepAlgo_Image::Bind(const TopoDS_Shape& OldS,
                            const TopTools_ListOfShape& L)
 {  
   if (HasImage(OldS)) {
-    Standard_ConstructionError::Raise(" BRepAlgo_Image::Bind");
+    throw Standard_ConstructionError(" BRepAlgo_Image::Bind");
     return; 
   }
   TopTools_ListIteratorOfListOfShape it(L);
@@ -102,7 +102,7 @@ void BRepAlgo_Image::Clear()
 void BRepAlgo_Image::Add(const TopoDS_Shape& OldS, const TopoDS_Shape& NewS)
 {
   if (!HasImage(OldS)) {    
-    Standard_ConstructionError::Raise(" BRepAlgo_Image::Add");
+    throw Standard_ConstructionError(" BRepAlgo_Image::Add");
   }
   down(OldS).Append(NewS);
   up.Bind(NewS,OldS);
@@ -131,7 +131,7 @@ void BRepAlgo_Image::Add(const TopoDS_Shape&         OldS,
 void BRepAlgo_Image::Remove(const TopoDS_Shape& S)
 {
   if (!up.IsBound(S)) {
-    Standard_ConstructionError::Raise(" BRepAlgo_Image::Remove");
+    throw Standard_ConstructionError(" BRepAlgo_Image::Remove");
   }
   const TopoDS_Shape& OldS = up(S);
   TopTools_ListOfShape& L = down(OldS);
@@ -176,7 +176,7 @@ Standard_Boolean  BRepAlgo_Image::IsImage(const TopoDS_Shape& S) const
 const TopoDS_Shape&  BRepAlgo_Image::ImageFrom(const TopoDS_Shape& S) const 
 {
   if (!up.IsBound(S)) {
-    Standard_ConstructionError::Raise(" BRepAlgo_Image::ImageFrom");
+    throw Standard_ConstructionError(" BRepAlgo_Image::ImageFrom");
   }  
   return up(S);
 }
@@ -190,7 +190,7 @@ const TopoDS_Shape&  BRepAlgo_Image::Root(const TopoDS_Shape& S)
 const 
 {
   if (!up.IsBound(S)) {
-    Standard_ConstructionError::Raise(" BRepAlgo_Image::FirstImageFrom");
+    throw Standard_ConstructionError(" BRepAlgo_Image::FirstImageFrom");
   }
 
   TopoDS_Shape S1 = up(S);
index e2b5c05..d43d831 100644 (file)
@@ -111,7 +111,7 @@ void BRepAlgoAPI_Algo::UserBreak() const
     return;
   }
   if (myProgressIndicator->UserBreak()) {
-    Standard_NotImplemented::Raise("");
+    throw Standard_NotImplemented("");
   }
 } 
 //=======================================================================
index 8f652cd..db04c8b 100644 (file)
@@ -47,10 +47,6 @@ public:
 
   DEFINE_STANDARD_ALLOC
 
-  
-  //! Raises Construction Error
-  Standard_EXPORT BRepApprox_TheFunctionOfTheInt2SOfThePrmPrmSvSurfacesOfApprox();
-  
   Standard_EXPORT BRepApprox_TheFunctionOfTheInt2SOfThePrmPrmSvSurfacesOfApprox(const BRepAdaptor_Surface& S1, const BRepAdaptor_Surface& S2);
   
   Standard_EXPORT Standard_Integer NbVariables() const;
index e2e8417..9ade0f1 100644 (file)
@@ -49,10 +49,6 @@ public:
 
   DEFINE_STANDARD_ALLOC
 
-  
-  //! Raises Construction Error
-  Standard_EXPORT BRepApprox_TheInt2SOfThePrmPrmSvSurfacesOfApprox();
-  
   //! compute the solution point with the close point
   Standard_EXPORT BRepApprox_TheInt2SOfThePrmPrmSvSurfacesOfApprox(const TColStd_Array1OfReal& Param, const BRepAdaptor_Surface& S1, const BRepAdaptor_Surface& S2, const Standard_Real TolTangency);
   
index 2488ec6..cffad99 100644 (file)
@@ -32,7 +32,7 @@ inline Standard_Boolean BRepBlend_Extremity::HasTangent () const
 
 inline const gp_Vec& BRepBlend_Extremity::Tangent () const
 {
-  if (!hastang) {Standard_DomainError::Raise();} 
+  if (!hastang) {throw Standard_DomainError();}
   return tang;
 }
 
@@ -57,7 +57,7 @@ inline Standard_Boolean BRepBlend_Extremity::IsVertex() const
 
 inline const Handle(Adaptor3d_HVertex)& BRepBlend_Extremity::Vertex () const
 {
-  if (!isvtx) {Standard_DomainError::Raise();}
+  if (!isvtx) {throw Standard_DomainError();}
   return vtx;
 }
 
index e92bd55..49d276d 100644 (file)
@@ -66,13 +66,13 @@ inline const Blend_Point& BRepBlend_Line::Point(const Standard_Integer Index) co
 
 inline IntSurf_TypeTrans BRepBlend_Line::TransitionOnS1 () const
 {
-  if (!hass1) {Standard_DomainError::Raise();}
+  if (!hass1) {throw Standard_DomainError();}
   return tras1;
 }
 
 inline IntSurf_TypeTrans BRepBlend_Line::TransitionOnS2 () const
 {
-  if (!hass2) {Standard_DomainError::Raise();}
+  if (!hass2) {throw Standard_DomainError();}
   return tras2;
 }
 
@@ -98,7 +98,7 @@ inline const BRepBlend_Extremity& BRepBlend_Line::EndPointOnSecond() const
 
 inline IntSurf_TypeTrans BRepBlend_Line::TransitionOnS () const
 {
-  if (!hass1) {Standard_DomainError::Raise();}
+  if (!hass1) {throw Standard_DomainError();}
   return tras1;
 }
 
index 8f423cd..6e781d9 100644 (file)
@@ -407,7 +407,7 @@ Standard_Boolean BRepBlend_RstRstConstRad::IsTangencyPoint() const
 
 const gp_Vec& BRepBlend_RstRstConstRad::TangentOnRst1() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tgrst1;
 }
 
@@ -418,7 +418,7 @@ const gp_Vec& BRepBlend_RstRstConstRad::TangentOnRst1() const
 
 const gp_Vec2d& BRepBlend_RstRstConstRad::Tangent2dOnRst1() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tg2drst1;
 }
 
@@ -429,7 +429,7 @@ const gp_Vec2d& BRepBlend_RstRstConstRad::Tangent2dOnRst1() const
 
 const gp_Vec& BRepBlend_RstRstConstRad::TangentOnRst2() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tgrst2;
 }
 
@@ -440,7 +440,7 @@ const gp_Vec& BRepBlend_RstRstConstRad::TangentOnRst2() const
 
 const gp_Vec2d& BRepBlend_RstRstConstRad::Tangent2dOnRst2() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tg2drst2;
 }
 
index afe84f8..4a7a50a 100644 (file)
@@ -479,7 +479,7 @@ Standard_Boolean BRepBlend_RstRstEvolRad::IsTangencyPoint() const
 
 const gp_Vec& BRepBlend_RstRstEvolRad::TangentOnRst1() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tgrst1;
 }
 
@@ -490,7 +490,7 @@ const gp_Vec& BRepBlend_RstRstEvolRad::TangentOnRst1() const
 
 const gp_Vec2d& BRepBlend_RstRstEvolRad::Tangent2dOnRst1() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tg2drst1;
 }
 
@@ -501,7 +501,7 @@ const gp_Vec2d& BRepBlend_RstRstEvolRad::Tangent2dOnRst1() const
 
 const gp_Vec& BRepBlend_RstRstEvolRad::TangentOnRst2() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tgrst2;
 }
 
@@ -512,7 +512,7 @@ const gp_Vec& BRepBlend_RstRstEvolRad::TangentOnRst2() const
 
 const gp_Vec2d& BRepBlend_RstRstEvolRad::Tangent2dOnRst2() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tg2drst2;
 }
 
index 32af8c8..a291aa3 100644 (file)
@@ -512,7 +512,7 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::Complete(Blend_RstRstFunction&   F
                                                       Blend_CurvPointFuncInv& FinvP2, 
                                                       const Standard_Real     Pmin) 
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   if (iscomplete) {return Standard_True;}
   if (sens >0.) {
     previousP = line->Point(1);
index fbdf643..aa7b133 100644 (file)
@@ -32,7 +32,7 @@ inline Standard_Boolean BRepBlend_RstRstLineBuilder::IsDone() const
 
 inline const Handle(BRepBlend_Line)& BRepBlend_RstRstLineBuilder::Line() const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return line;
 }
 
index 2e08453..cdca3bd 100644 (file)
@@ -516,7 +516,7 @@ Standard_Boolean BRepBlend_SurfRstConstRad::IsTangencyPoint() const
 
 const gp_Vec& BRepBlend_SurfRstConstRad::TangentOnS() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tgs;
 }
 
@@ -527,7 +527,7 @@ const gp_Vec& BRepBlend_SurfRstConstRad::TangentOnS() const
 
 const gp_Vec2d& BRepBlend_SurfRstConstRad::Tangent2dOnS() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tg2ds;
 }
 
@@ -538,7 +538,7 @@ const gp_Vec2d& BRepBlend_SurfRstConstRad::Tangent2dOnS() const
 
 const gp_Vec& BRepBlend_SurfRstConstRad::TangentOnRst() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tgrst;
 }
 
@@ -549,7 +549,7 @@ const gp_Vec& BRepBlend_SurfRstConstRad::TangentOnRst() const
 
 const gp_Vec2d& BRepBlend_SurfRstConstRad::Tangent2dOnRst() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tg2drst;
 }
 
index b47bc38..1658d7c 100644 (file)
@@ -568,7 +568,7 @@ const gp_Pnt2d& BRepBlend_SurfRstEvolRad::Pnt2dOnRst() const
 //=======================================================================
 const gp_Vec& BRepBlend_SurfRstEvolRad::TangentOnS() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tgs;
 }
 
@@ -578,7 +578,7 @@ const gp_Vec& BRepBlend_SurfRstEvolRad::TangentOnS() const
 //=======================================================================
 const gp_Vec2d& BRepBlend_SurfRstEvolRad::Tangent2dOnS() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tg2ds;
 }
 
@@ -588,7 +588,7 @@ const gp_Vec2d& BRepBlend_SurfRstEvolRad::Tangent2dOnS() const
 //=======================================================================
 const gp_Vec& BRepBlend_SurfRstEvolRad::TangentOnRst() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tgrst;
 }
 
@@ -598,7 +598,7 @@ const gp_Vec& BRepBlend_SurfRstEvolRad::TangentOnRst() const
 //=======================================================================
 const gp_Vec2d& BRepBlend_SurfRstEvolRad::Tangent2dOnRst() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tg2drst;
 }
 
index 4689af8..40adf8d 100644 (file)
@@ -474,7 +474,7 @@ Standard_Boolean BRepBlend_SurfRstLineBuilder::Complete(Blend_SurfRstFunction&
                                                        Blend_SurfCurvFuncInv&  FinvC,
                                                        const Standard_Real     Pmin) 
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   if (iscomplete) {return Standard_True;}
   if (sens >0.) {
     previousP = line->Point(1);
index 7190f28..7af29bc 100644 (file)
@@ -32,7 +32,7 @@ inline Standard_Boolean BRepBlend_SurfRstLineBuilder::IsDone() const
 
 inline const Handle(BRepBlend_Line)& BRepBlend_SurfRstLineBuilder::Line() const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return line;
 }
 
index d770f7f..13cee1f 100644 (file)
@@ -53,7 +53,7 @@ Standard_Boolean  BRepBuilderAPI_Command::IsDone()const
 void  BRepBuilderAPI_Command::Check()const 
 {
   if (!myDone)
-    StdFail_NotDone::Raise("BRep_API: command not done");
+    throw StdFail_NotDone("BRep_API: command not done");
 }
 
 
index 7644cce..2ecc36d 100644 (file)
@@ -83,7 +83,7 @@ static Handle(Geom2d_Curve)
                         const Standard_Boolean theIsReverse = Standard_False)
 {
   if((theIndex < 0) || (theIndex > 3))
-    Standard_OutOfRange::Raise("BRepBuilderAPI_FastSewing.cxx, Get2DCurve(): OUT of Range");
+    throw Standard_OutOfRange("BRepBuilderAPI_FastSewing.cxx, Get2DCurve(): OUT of Range");
   
   Handle(Geom2d_Curve) a2dCurv;
 
@@ -677,7 +677,7 @@ void BRepBuilderAPI_FastSewing::FS_Edge::
     a3dCurv = aSurf->UIso(aUf);
     break;
   default:
-    Standard_OutOfRange::Raise("FS_Edge::CreateTopologicalEdge()");
+    throw Standard_OutOfRange("FS_Edge::CreateTopologicalEdge()");
     break;
   }
 
index bf3557d..f82288b 100644 (file)
@@ -72,7 +72,7 @@ BRepBuilderAPI_ModifyShape::BRepBuilderAPI_ModifyShape
 void BRepBuilderAPI_ModifyShape::DoModif ()
 {
   if (myInitialShape.IsNull() || myModification.IsNull()) {
-    Standard_NullObject::Raise();
+    throw Standard_NullObject();
   }
   myModifier.Perform(myModification);
   if (myModifier.IsDone()) {
index feb9f80..fa90710 100644 (file)
@@ -149,11 +149,12 @@ Handle(Geom2d_Curve) BRepBuilderAPI_Sewing::SameRange(const Handle(Geom2d_Curve)
     GeomLib::SameRange(Precision::PConfusion(),CurvePtr,FirstOnCurve,LastOnCurve,
                       RequestedFirst,RequestedLast,NewCurvePtr);
   }
-  catch (Standard_Failure) {
+  catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout << "Exception in BRepBuilderAPI_Sewing::SameRange: ";
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
   }
   return NewCurvePtr;
 }
@@ -321,11 +322,12 @@ void BRepBuilderAPI_Sewing::SameParameter(const TopoDS_Edge& edge) const
     
     BRepLib::SameParameter(edge);
   }
-  catch (Standard_Failure) {
+  catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout << "Exception in BRepBuilderAPI_Sewing::SameParameter: ";
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
   }
 }
 
@@ -4348,12 +4350,13 @@ void BRepBuilderAPI_Sewing::ProjectPointsOnCurve(const TColgp_Array1OfPnt& arrPn
         }
       }
     }
-    catch (Standard_Failure) {
-      worktol = MinTolerance();
+    catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
       cout << "Exception in BRepBuilderAPI_Sewing::ProjectPointsOnCurve: ";
-      Standard_Failure::Caught()->Print(cout); cout << endl;
+      anException.Print(cout); cout << endl;
 #endif
+      (void)anException;
+      worktol = MinTolerance();
     }
     if (!isProjected && isConsiderEnds) {
       if (Min(distF2,distL2) < worktol * worktol) {
index d6078c0..869eb7c 100644 (file)
@@ -43,7 +43,7 @@ void BRepCheck_Analyzer::Init(const TopoDS_Shape& S,
          const Standard_Boolean B)
 {
   if (S.IsNull()) {
-    Standard_NullObject::Raise();
+    throw Standard_NullObject();
   }
   myShape = S;
   myMap.Clear();
@@ -133,13 +133,13 @@ void BRepCheck_Analyzer::Perform(const TopoDS_Shape& S)
           Handle(BRepCheck_Edge)::DownCast(aRes)->SetStatus(ste);
         }
       }
-      catch(Standard_Failure)
-      {
+      catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
         cout<<"BRepCheck_Analyzer : ";
-        Standard_Failure::Caught()->Print(cout);  
+        anException.Print(cout);  
         cout<<endl;
 #endif
+        (void)anException;
         if ( ! myMap(S).IsNull() )
         {
           myMap(S)->SetFailStatus(S);
@@ -163,13 +163,13 @@ void BRepCheck_Analyzer::Perform(const TopoDS_Shape& S)
           if (MapS.Add(aVertex))
             myMap(aVertex)->InContext(S);
         }
-        catch(Standard_Failure)
-        {
+        catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
           cout<<"BRepCheck_Analyzer : ";
-          Standard_Failure::Caught()->Print(cout);  
+          anException.Print(cout);  
           cout<<endl;
 #endif
+          (void)anException;
           if ( ! myMap(S).IsNull() )
             myMap(S)->SetFailStatus(S);
 
@@ -201,13 +201,13 @@ void BRepCheck_Analyzer::Perform(const TopoDS_Shape& S)
             myMap(exp.Current())->InContext(S);
           }
         }
-        catch(Standard_Failure)
-        {
+        catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
           cout<<"BRepCheck_Analyzer : ";
-          Standard_Failure::Caught()->Print(cout);  
+          anException.Print(cout);  
           cout<<endl;
 #endif
+          (void)anException;
           if ( ! myMap(S).IsNull() )
           {
             myMap(S)->SetFailStatus(S);
@@ -261,13 +261,13 @@ void BRepCheck_Analyzer::Perform(const TopoDS_Shape& S)
             }
           }
         }
-        catch(Standard_Failure)
-        {
+        catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
           cout<<"BRepCheck_Analyzer : ";
-          Standard_Failure::Caught()->Print(cout);  
+          anException.Print(cout);  
           cout<<endl;
 #endif
+          (void)anException;
           if ( ! myMap(S).IsNull() )
           {
             myMap(S)->SetFailStatus(S);
@@ -314,13 +314,13 @@ void BRepCheck_Analyzer::Perform(const TopoDS_Shape& S)
             }
           }
         }
-        catch(Standard_Failure)
-        {
+        catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
           cout<<"BRepCheck_Analyzer : ";
-          Standard_Failure::Caught()->Print(cout);  
+          anException.Print(cout);  
           cout<<endl;
 #endif
+          (void)anException;
           if ( ! myMap(S).IsNull() )
           {
             myMap(S)->SetFailStatus(S);
@@ -361,13 +361,13 @@ void BRepCheck_Analyzer::Perform(const TopoDS_Shape& S)
           Handle(BRepCheck_Face)::DownCast(myMap(S))->SetUnorientable();
         }
       }
-      catch(Standard_Failure)
-      {
+      catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
         cout<<"BRepCheck_Analyzer : ";
-        Standard_Failure::Caught()->Print(cout);  
+        anException.Print(cout);  
         cout<<endl;
 #endif
+        (void)anException;
         if ( ! myMap(S).IsNull() )
         {
           myMap(S)->SetFailStatus(S);
@@ -402,13 +402,13 @@ void BRepCheck_Analyzer::Perform(const TopoDS_Shape& S)
               OCC_CATCH_SIGNALS
                 myMap(aShell)->InContext(S);
             }
-          catch(Standard_Failure)
-            {
+          catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
               cout<<"BRepCheck_Analyzer : ";
-              Standard_Failure::Caught()->Print(cout);  
+              anException.Print(cout);  
               cout<<endl;
 #endif
+              (void)anException;
               if ( ! myMap(S).IsNull() )
                 {
                   myMap(S)->SetFailStatus(S);
index 6d8d33d..81b51c8 100644 (file)
@@ -771,18 +771,6 @@ Standard_Boolean BRepClass3d_SolidExplorer::FindAPointInTheFace
 BRepClass3d_SolidExplorer::BRepClass3d_SolidExplorer() 
 {
 }
-#include <Standard_ConstructionError.hxx>
-
-//=======================================================================
-//function : BRepClass3d_SolidExplorer
-//purpose  : Raise if called.
-//=======================================================================
-
-//BRepClass3d_SolidExplorer::BRepClass3d_SolidExplorer(const BRepClass3d_SolidExplorer& Oth) 
-BRepClass3d_SolidExplorer::BRepClass3d_SolidExplorer(const BRepClass3d_SolidExplorer& ) 
-{
-  Standard_ConstructionError::Raise("Magic constructor not allowed");
-}
 
 //=======================================================================
 //function : BRepClass3d_SolidExplorer
index 834e7f0..9e93d07 100644 (file)
@@ -53,9 +53,6 @@ public:
   
   Standard_EXPORT BRepClass3d_SolidExplorer();
   
-  //! Raise if called.
-  Standard_EXPORT BRepClass3d_SolidExplorer(const BRepClass3d_SolidExplorer& Oth);
-  
   Standard_EXPORT BRepClass3d_SolidExplorer(const TopoDS_Shape& S);
   
   Standard_EXPORT virtual ~BRepClass3d_SolidExplorer();
@@ -152,6 +149,10 @@ public:
   
   Standard_EXPORT void Destroy();
 
+private:
+
+  Standard_EXPORT BRepClass3d_SolidExplorer(const BRepClass3d_SolidExplorer& Oth);
+
 protected:
 
   Standard_EXPORT TopAbs_State ClassifyUVPoint
index bf380fa..f54f28b 100644 (file)
@@ -410,7 +410,7 @@ Standard_Boolean BRepExtrema_DistShapeShape::Perform()
 Standard_Real BRepExtrema_DistShapeShape::Value() const 
 { 
   if (!myIsDone)
-    StdFail_NotDone::Raise("BRepExtrema_DistShapeShape::Value: There's no solution ");
+    throw StdFail_NotDone("BRepExtrema_DistShapeShape::Value: There's no solution ");
 
   return myDistRef;
 }
@@ -423,7 +423,7 @@ Standard_Real BRepExtrema_DistShapeShape::Value() const
 TopoDS_Shape BRepExtrema_DistShapeShape::SupportOnShape1(const Standard_Integer N) const
 { 
   if (!myIsDone)
-    StdFail_NotDone::Raise("BRepExtrema_DistShapeShape::SupportOnShape1: There's no solution ");
+    throw StdFail_NotDone("BRepExtrema_DistShapeShape::SupportOnShape1: There's no solution ");
 
   const BRepExtrema_SolutionElem &sol = mySolutionsShape1.Value(N);
   switch (sol.SupportKind())
@@ -443,7 +443,7 @@ TopoDS_Shape BRepExtrema_DistShapeShape::SupportOnShape1(const Standard_Integer
 TopoDS_Shape BRepExtrema_DistShapeShape::SupportOnShape2(const Standard_Integer N) const 
 { 
   if (!myIsDone)
-    StdFail_NotDone::Raise("BRepExtrema_DistShapeShape::SupportOnShape2: There's no solution ");
+    throw StdFail_NotDone("BRepExtrema_DistShapeShape::SupportOnShape2: There's no solution ");
 
   const BRepExtrema_SolutionElem &sol = mySolutionsShape2.Value(N);
   switch (sol.SupportKind())
@@ -463,12 +463,11 @@ TopoDS_Shape BRepExtrema_DistShapeShape::SupportOnShape2(const Standard_Integer
 void BRepExtrema_DistShapeShape::ParOnEdgeS1(const Standard_Integer N, Standard_Real& t) const 
 { 
   if (!myIsDone)
-    StdFail_NotDone::Raise("BRepExtrema_DistShapeShape::ParOnEdgeS1: There's no solution");
+    throw StdFail_NotDone("BRepExtrema_DistShapeShape::ParOnEdgeS1: There's no solution");
 
   const BRepExtrema_SolutionElem &sol = mySolutionsShape1.Value(N);
   if (sol.SupportKind() != BRepExtrema_IsOnEdge)
-    BRepExtrema_UnCompatibleShape::Raise
-      ("BRepExtrema_DistShapeShape::ParOnEdgeS1: ParOnEdgeS1 is impossible without EDGE");
+    throw BRepExtrema_UnCompatibleShape("BRepExtrema_DistShapeShape::ParOnEdgeS1: ParOnEdgeS1 is impossible without EDGE");
 
   sol.EdgeParameter(t);
 }
@@ -481,12 +480,11 @@ void BRepExtrema_DistShapeShape::ParOnEdgeS1(const Standard_Integer N, Standard_
 void BRepExtrema_DistShapeShape::ParOnEdgeS2(const Standard_Integer N,  Standard_Real& t) const 
 { 
   if (!myIsDone)
-    StdFail_NotDone::Raise("BRepExtrema_DistShapeShape::ParOnEdgeS2: There's no solution");
+    throw StdFail_NotDone("BRepExtrema_DistShapeShape::ParOnEdgeS2: There's no solution");
 
   const BRepExtrema_SolutionElem &sol = mySolutionsShape2.Value(N);
   if (sol.SupportKind() != BRepExtrema_IsOnEdge)
-    BRepExtrema_UnCompatibleShape::Raise
-      ("BRepExtrema_DistShapeShape::ParOnEdgeS2: ParOnEdgeS2 is impossible without EDGE");
+    throw BRepExtrema_UnCompatibleShape("BRepExtrema_DistShapeShape::ParOnEdgeS2: ParOnEdgeS2 is impossible without EDGE");
  
   sol.EdgeParameter(t);
 }
@@ -499,12 +497,11 @@ void BRepExtrema_DistShapeShape::ParOnEdgeS2(const Standard_Integer N,  Standard
 void BRepExtrema_DistShapeShape::ParOnFaceS1(const Standard_Integer N,  Standard_Real& u,  Standard_Real& v) const 
 { 
   if (!myIsDone)
-    StdFail_NotDone::Raise("BRepExtrema_DistShapeShape::ParOnFaceS1: There's no solution");
+    throw StdFail_NotDone("BRepExtrema_DistShapeShape::ParOnFaceS1: There's no solution");
 
   const BRepExtrema_SolutionElem &sol = mySolutionsShape1.Value(N);
   if (sol.SupportKind() != BRepExtrema_IsInFace)
-    BRepExtrema_UnCompatibleShape::Raise
-      ("BRepExtrema_DistShapeShape::ParOnFaceS1: ParOnFaceS1 is impossible without FACE");
+    throw BRepExtrema_UnCompatibleShape("BRepExtrema_DistShapeShape::ParOnFaceS1: ParOnFaceS1 is impossible without FACE");
   
   sol.FaceParameter(u, v);
 }
@@ -517,12 +514,11 @@ void BRepExtrema_DistShapeShape::ParOnFaceS1(const Standard_Integer N,  Standard
 void BRepExtrema_DistShapeShape::ParOnFaceS2(const Standard_Integer N,  Standard_Real& u, Standard_Real& v) const 
 { 
   if (!myIsDone)
-    StdFail_NotDone::Raise("BRepExtrema_DistShapeShape::ParOnFaceS2: There's no solution");
+    throw StdFail_NotDone("BRepExtrema_DistShapeShape::ParOnFaceS2: There's no solution");
 
   const BRepExtrema_SolutionElem &sol = mySolutionsShape2.Value(N);
   if (sol.SupportKind() != BRepExtrema_IsInFace)
-    BRepExtrema_UnCompatibleShape::Raise
-      ("BRepExtrema_DistShapeShape::ParOnFaceS2:ParOnFaceS2 is impossible without FACE ");
+    throw BRepExtrema_UnCompatibleShape("BRepExtrema_DistShapeShape::ParOnFaceS2:ParOnFaceS2 is impossible without FACE ");
   
   sol.FaceParameter(u, v);
 }
index 4b3aa54..240e826 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(BRepExtrema_UnCompatibleShape, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_BRepExtrema_UnCompatibleShape
   #define BRepExtrema_UnCompatibleShape_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) BRepExtrema_UnCompatibleShape::Raise(MESSAGE);
+  if (CONDITION) throw BRepExtrema_UnCompatibleShape(MESSAGE);
 #else
   #define BRepExtrema_UnCompatibleShape_Raise_if(CONDITION, MESSAGE)
 #endif
index 48750b6..edea267 100644 (file)
@@ -66,7 +66,7 @@ void BRepFeat_MakeCylindricalHole::Perform(const Standard_Real Radius)
 {
   const TopoDS_Shape& aObject=myArguments.First();
   if (aObject.IsNull() || !myAxDef) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   myIsBlind = Standard_False;
@@ -120,7 +120,7 @@ void BRepFeat_MakeCylindricalHole::PerformThruNext(const Standard_Real Radius,
   //
   const TopoDS_Shape& aObject=myArguments.First();
   if (aObject.IsNull() || !myAxDef) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   myIsBlind = Standard_False;
@@ -251,7 +251,7 @@ void BRepFeat_MakeCylindricalHole::PerformUntilEnd(const Standard_Real Radius,
   //
   const TopoDS_Shape& aObject=myArguments.First();
   if (aObject.IsNull() || !myAxDef) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   myIsBlind = Standard_False;
@@ -344,7 +344,7 @@ void BRepFeat_MakeCylindricalHole::Perform(const Standard_Real Radius,
   //
   const TopoDS_Shape& aObject=myArguments.First();
   if (aObject.IsNull() || !myAxDef) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   myIsBlind = Standard_False;
@@ -449,7 +449,7 @@ void BRepFeat_MakeCylindricalHole::PerformBlind(const Standard_Real Radius,
   //
   const TopoDS_Shape& aObject=myArguments.First();
   if (aObject.IsNull() || !myAxDef || Length <= 0.) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   myIsBlind = Standard_True;
index 1150188..f83906a 100644 (file)
@@ -177,7 +177,7 @@ void BRepFeat_MakeDPrism::Add(const TopoDS_Edge& E,
     }
   }
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   for (exp.Init(myPbase,TopAbs_EDGE);exp.More();exp.Next()) {
@@ -186,7 +186,7 @@ void BRepFeat_MakeDPrism::Add(const TopoDS_Edge& E,
     }
   }
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   if (!mySlface.IsBound(F)) {
@@ -298,11 +298,11 @@ void BRepFeat_MakeDPrism::Perform(const TopoDS_Shape& Until)
   if (trc) cout << "BRepFeat_MakeDPrism::Perform(Until)" << endl;
 #endif
   if (Until.IsNull()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   TopExp_Explorer exp(Until, TopAbs_FACE);
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   //  myPbase.Orientation(TopAbs_FORWARD);
 
@@ -434,7 +434,7 @@ void BRepFeat_MakeDPrism::Perform(const TopoDS_Shape& From,
   if (trc) cout << "BRepFeat_MakeDPrism::Perform(From,Until)" << endl;
 #endif
   if (From.IsNull() || Until.IsNull()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   if (!mySkface.IsNull()) {
@@ -457,11 +457,11 @@ void BRepFeat_MakeDPrism::Perform(const TopoDS_Shape& From,
 
   TopExp_Explorer exp(From, TopAbs_FACE);
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   exp.Init(Until, TopAbs_FACE);
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   mySFrom = From;
   Standard_Boolean Trff = TransformShapeFU(0);
@@ -652,7 +652,7 @@ void BRepFeat_MakeDPrism::PerformFromEnd(const TopoDS_Shape& Until)
   if (trc) cout << "BRepFeat_MakeDPrism::PerformFromEnd(From,Until)" << endl;
 #endif
   if (Until.IsNull()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   if (!mySkface.IsNull() && Until.IsSame(mySkface)) {
     PerformUntilEnd();
@@ -661,7 +661,7 @@ void BRepFeat_MakeDPrism::PerformFromEnd(const TopoDS_Shape& Until)
   TopExp_Explorer exp;
   exp.Init(Until, TopAbs_FACE);
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   //  myPbase.Orientation(TopAbs_FORWARD);
   myPerfSelection = BRepFeat_SelectionShU;
@@ -876,7 +876,7 @@ void BRepFeat_MakeDPrism::PerformUntilHeight(const TopoDS_Shape& Until,
   }
   TopExp_Explorer exp(Until, TopAbs_FACE);
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   //  myPbase.Orientation(TopAbs_FORWARD);
   myGluedF.Clear();
index bc72f95..7b87354 100644 (file)
@@ -782,7 +782,7 @@ void BRepFeat_MakeLinearForm::Add(const TopoDS_Edge& E,
       }
     }
     if (!exp.More()) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   
     if (!mySlface.IsBound(F)) {
index 593fa13..c69f9f3 100644 (file)
@@ -143,7 +143,7 @@ void BRepFeat_MakePipe::Add(const TopoDS_Edge& E,
     }
   }
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   for (exp.Init(myPbase,TopAbs_EDGE);exp.More();exp.Next()) {
@@ -152,7 +152,7 @@ void BRepFeat_MakePipe::Add(const TopoDS_Edge& E,
     }
   }
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   if (!mySlface.IsBound(F)) {
@@ -249,11 +249,11 @@ void BRepFeat_MakePipe::Perform(const TopoDS_Shape& Until)
   if (trc) cout << "BRepFeat_MakePipe::Perform(Until)" << endl;
 #endif
   if (Until.IsNull()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   TopExp_Explorer exp(Until, TopAbs_FACE);
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   myGluedF.Clear();
   myPerfSelection = BRepFeat_SelectionU;
@@ -293,7 +293,7 @@ void BRepFeat_MakePipe::Perform(const TopoDS_Shape& From,
   if (trc) cout << "BRepFeat_MakePipe::Perform(From,Until)" << endl;
 #endif
   if (From.IsNull() || Until.IsNull()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   if (!mySkface.IsNull()) {
     if (From.IsSame(mySkface)) {
@@ -310,11 +310,11 @@ void BRepFeat_MakePipe::Perform(const TopoDS_Shape& From,
   PerfSelectionValid();
   TopExp_Explorer exp(From, TopAbs_FACE);
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   exp.Init(Until, TopAbs_FACE);
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   mySFrom = From;
   TransformShapeFU(0);
index 80c8233..01e62e0 100644 (file)
@@ -176,7 +176,7 @@ void BRepFeat_MakePrism::Add(const TopoDS_Edge& E,
     }
   }
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   
   for (exp.Init(myPbase,TopAbs_EDGE);exp.More();exp.Next()) {
@@ -185,7 +185,7 @@ void BRepFeat_MakePrism::Add(const TopoDS_Edge& E,
     }
   }
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   
   if (!mySlface.IsBound(F)) {
@@ -327,11 +327,11 @@ void BRepFeat_MakePrism::Perform(const TopoDS_Shape& Until)
   if (trc) cout << "BRepFeat_MakePrism::Perform(Until)" << endl;
 #endif
   if (Until.IsNull()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   TopExp_Explorer exp(Until, TopAbs_FACE);
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   myGluedF.Clear();
   myPerfSelection = BRepFeat_SelectionU;
@@ -473,7 +473,7 @@ void BRepFeat_MakePrism::Perform(const TopoDS_Shape& From,
   if (trc) cout << "BRepFeat_MakePrism::Perform(From,Until)" << endl;
 #endif
   if (From.IsNull() || Until.IsNull()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   if (!mySkface.IsNull()) {
@@ -495,11 +495,11 @@ void BRepFeat_MakePrism::Perform(const TopoDS_Shape& From,
   
   TopExp_Explorer exp(From, TopAbs_FACE);
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   exp.Init(Until, TopAbs_FACE);
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   mySFrom = From;
   Standard_Boolean Trff = TransformShapeFU(0);
@@ -749,7 +749,7 @@ void BRepFeat_MakePrism::PerformFromEnd(const TopoDS_Shape& Until)
   if (trc) cout << "BRepFeat_MakePrism::PerformFromEnd(From,Until)" << endl;
 #endif
   if (Until.IsNull()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   if (!mySkface.IsNull() && Until.IsSame(mySkface)) {
     myDir.Reverse();
@@ -759,7 +759,7 @@ void BRepFeat_MakePrism::PerformFromEnd(const TopoDS_Shape& Until)
   TopExp_Explorer exp;
   exp.Init(Until, TopAbs_FACE);
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   myPerfSelection = BRepFeat_SelectionShU;
   PerfSelectionValid();
@@ -959,7 +959,7 @@ void BRepFeat_MakePrism::PerformUntilHeight(const TopoDS_Shape& Until,
   }
   TopExp_Explorer exp(Until, TopAbs_FACE);
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   myGluedF.Clear();
   myPerfSelection = BRepFeat_NoSelection;
index 193b123..c171d8b 100644 (file)
@@ -176,7 +176,7 @@ void BRepFeat_MakeRevol::Add(const TopoDS_Edge& E,
     }
   }
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   for (exp.Init(myPbase,TopAbs_EDGE);exp.More();exp.Next()) {
@@ -185,7 +185,7 @@ void BRepFeat_MakeRevol::Add(const TopoDS_Edge& E,
     }
   }
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   if (!mySlface.IsBound(F)) {
@@ -345,11 +345,11 @@ void BRepFeat_MakeRevol::Perform(const TopoDS_Shape& Until)
   Standard_Boolean TourComplet = Standard_False;
 
   if (Until.IsNull()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   TopExp_Explorer exp(Until, TopAbs_FACE);
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   if (!mySkface.IsNull() && Until.IsSame(mySkface)) {
     Angle = 2*M_PI;
@@ -510,7 +510,7 @@ void BRepFeat_MakeRevol::Perform(const TopoDS_Shape& From,
   if (trc) cout << "BRepFeat_MakeRevol::Perform(From,Until)" << endl;
 #endif
   if (From.IsNull() || Until.IsNull()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   if (!mySkface.IsNull()) {
     if (From.IsSame(mySkface)) {
@@ -532,11 +532,11 @@ void BRepFeat_MakeRevol::Perform(const TopoDS_Shape& From,
 
   TopExp_Explorer exp(From, TopAbs_FACE);
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   exp.Init(Until, TopAbs_FACE);
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   mySFrom = From;
@@ -699,7 +699,7 @@ void BRepFeat_MakeRevol::PerformUntilAngle(const TopoDS_Shape& Until,
   }
   TopExp_Explorer exp(Until, TopAbs_FACE);
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   if (!mySkface.IsNull() && Until.IsSame(mySkface)) {
     Perform(Angle);
index c22947e..3ab743a 100644 (file)
@@ -1002,7 +1002,7 @@ void BRepFeat_MakeRevolutionForm::Add(const TopoDS_Edge& E,
       }
     }
     if (!exp.More()) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   
     if (!mySlface.IsBound(F)) {
index b141b9c..0155338 100644 (file)
@@ -653,8 +653,7 @@ void BRepFill::Axe (const TopoDS_Shape&       Spine,
        L = FS.Location();
       }
       else {
-       Standard_NoSuchObject::Raise 
-         ("BRepFill_Evolved : The Face is not planar");
+       throw Standard_NoSuchObject("BRepFill_Evolved : The Face is not planar");
       }
     }
   }
@@ -663,7 +662,7 @@ void BRepFill::Axe (const TopoDS_Shape&       Spine,
     S = BRep_Tool::Surface(aFace, L);
   }
   
-  if (S.IsNull()) Standard_DomainError::Raise("BRepFill_Evolved::Axe");
+  if (S.IsNull()) throw Standard_DomainError("BRepFill_Evolved::Axe");
     
   if (!L.IsIdentity())
     S = Handle(Geom_Surface)::DownCast(S->Transformed(L.Transformation()));
index c0eab66..3a24479 100644 (file)
@@ -851,7 +851,7 @@ void BRepFill_CompatibleWires::Perform (const Standard_Boolean WithRotation)
   else {
     // There are open and closed sections :
     // not processed
-    Standard_DomainError::Raise("Sections must be all closed or all open");
+    throw Standard_DomainError("Sections must be all closed or all open");
   }
   
 }
@@ -893,7 +893,7 @@ void BRepFill_CompatibleWires::
     //allClosed = (allClosed && myWork(i).Closed());
   }
   if (!allClosed)
-    Standard_NoSuchObject::Raise("BRepFill_CompatibleWires::SameNumberByPolarMethod : the wires must be closed");
+    throw Standard_NoSuchObject("BRepFill_CompatibleWires::SameNumberByPolarMethod : the wires must be closed");
   
   // sections ponctuelles, sections bouclantes ?
   if (myDegen1) ideb++;
@@ -974,7 +974,7 @@ void BRepFill_CompatibleWires::
     // sequence of vertices of the first wire
     SeqOfVertices(wire1,SeqV);
     if (SeqV.Length()>NbMaxV) 
-      Standard_NoSuchObject::Raise("BRepFill::SameNumberByPolarMethod failed");
+      throw Standard_NoSuchObject("BRepFill::SameNumberByPolarMethod failed");
     
     // loop on vertices of wire1
     for (ii=1;ii<=SeqV.Length();ii++) {
@@ -1049,7 +1049,7 @@ void BRepFill_CompatibleWires::
     // sequence of vertices of the first wire
     SeqOfVertices(wire1,SeqV);
     if ( SeqV.Length()>NbMaxV || SeqV.Length()>SizeMap ) 
-      Standard_NoSuchObject::Raise("BRepFill::SameNumberByPolarMethod failed");
+      throw Standard_NoSuchObject("BRepFill::SameNumberByPolarMethod failed");
     
 
     // next wire 
@@ -1171,7 +1171,7 @@ void BRepFill_CompatibleWires::
        }
       } //end of for(; itW.More(); itW.Next())
     if (Esol.IsNull())
-      Standard_ConstructionError::Raise("BRepFill :: profiles are inconsistent");
+      throw Standard_ConstructionError("BRepFill :: profiles are inconsistent");
     MW.Add(Esol);
 
     TopTools_ListOfShape ConnectedEdges;
@@ -1237,7 +1237,7 @@ void BRepFill_CompatibleWires::
     if (nbmin>nbEdges) nbmin = nbEdges;
   }
   if (nbmin!=nbmax) {
-    Standard_NoSuchObject::Raise("BRepFill_CompatibleWires::SameNumberByPolarMethod failed");
+    throw Standard_NoSuchObject("BRepFill_CompatibleWires::SameNumberByPolarMethod failed");
   }
 
   //Fill <myMap>
@@ -1456,7 +1456,7 @@ void BRepFill_CompatibleWires::SameNumberByACR(const  Standard_Boolean  report)
     if (nbmin>nbEdges(i)) nbmin = nbEdges(i);
   }
   if (nbmax!=nbmin) 
-    Standard_NoSuchObject::Raise("BRepFill_CompatibleWires::SameNumberByACR failed");
+    throw Standard_NoSuchObject("BRepFill_CompatibleWires::SameNumberByACR failed");
 }
 
 //=======================================================================
@@ -1501,7 +1501,7 @@ void BRepFill_CompatibleWires::ComputeOrigin(const  Standard_Boolean /*polar*/ )
   }
 */
   if (!allClosed) 
-    Standard_NoSuchObject::Raise("BRepFill_CompatibleWires::ComputeOrigin : the wires must be closed");
+    throw Standard_NoSuchObject("BRepFill_CompatibleWires::ComputeOrigin : the wires must be closed");
 
 /*  
   // Max number of possible cuts
@@ -1836,7 +1836,7 @@ void BRepFill_CompatibleWires::ComputeOrigin(const  Standard_Boolean /*polar*/ )
       gp_Pnt Pmini,P1,P2;
       SeqOfVertices(wire,SeqV);
       if (SeqV.Length()>NbMaxV) 
-       Standard_NoSuchObject::Raise("BRepFill::ComputeOrigin failed");
+       throw Standard_NoSuchObject("BRepFill::ComputeOrigin failed");
       if (!polar) {
        // choix du vertex le plus proche comme origine
        distmini = Precision::Infinite();
@@ -2060,7 +2060,7 @@ void BRepFill_CompatibleWires::SearchOrigin()
     allOpen = (allOpen && !myWork(i).Closed());
   }
   if (!allOpen)
-    Standard_NoSuchObject::Raise("BRepFill_CompatibleWires::SearchOrigin : the wires must be open");
+    throw Standard_NoSuchObject("BRepFill_CompatibleWires::SearchOrigin : the wires must be open");
 
   // init
 
index 49d01e0..c21401f 100644 (file)
@@ -56,13 +56,13 @@ BRepFill_CurveConstraint :: BRepFill_CurveConstraint (const Handle(Adaptor3d_HCu
   myLProp=SLP;
   myOrder=Tang;
   if ((Tang<-1)||(Tang>2))
-    Standard_Failure::Raise("BRepFill : The continuity is not G0 G1 or G2"); 
+    throw Standard_Failure("BRepFill : The continuity is not G0 G1 or G2");
   myNbPoints=NPt;
 myConstG0=Standard_True;
 myConstG1=Standard_True;
 myConstG2=Standard_True;
  if (myFrontiere.IsNull())
-    Standard_Failure::Raise("BRepFill_CurveConstraint : Curve must be on a Surface"); 
+    throw Standard_Failure("BRepFill_CurveConstraint : Curve must be on a Surface");
   Handle(Geom_Surface) Surf;
   Handle(GeomAdaptor_HSurface) GS1;
   GS1 = Handle(GeomAdaptor_HSurface)::DownCast(myFrontiere->ChangeCurve().GetSurface());
index 5423f22..583ed0c 100644 (file)
@@ -263,19 +263,19 @@ static Standard_Boolean GoodOrientation(const Bnd_Box& B,
 #ifdef OCCT_DEBUG
          cout << "Error in MakeWire" << endl;
 #endif 
-         Standard_ConstructionError::Raise("BRepFill_Draft");
+         throw Standard_ConstructionError("BRepFill_Draft");
        }
       }
       else {
 #ifdef OCCT_DEBUG
          cout << "No Free Borders !" << endl;
 #endif 
-         Standard_ConstructionError::Raise("BRepFill_Draft");
+         throw Standard_ConstructionError("BRepFill_Draft");
       }
       break;
     }
     default :
-      Standard_ConstructionError::Raise("BRepFill_Draft");
+      throw Standard_ConstructionError("BRepFill_Draft");
   }
 
   // Attention to closed non declared wires !
index 4986b5e..f106567 100644 (file)
@@ -396,7 +396,7 @@ void BRepFill_Evolved::PrivatePerform(const TopoDS_Face&     Spine,
   myMap.Clear();
 
   if (myJoinType > GeomAbs_Arc)  {
-    Standard_NotImplemented::Raise();
+    throw Standard_NotImplemented();
   }
 
   TopTools_ListOfShape               WorkProf;
@@ -2369,8 +2369,7 @@ TopLoc_Location BRepFill_Evolved::FindLocation(const TopoDS_Face& Face)
       L = FS.Location();
     }
     else
-      Standard_NoSuchObject::Raise
-      ("BRepFill_Evolved : The Face is not planar");
+      throw Standard_NoSuchObject("BRepFill_Evolved : The Face is not planar");
   }
 
   if (!L.IsIdentity())
@@ -2686,7 +2685,7 @@ const TopoDS_Wire PutProfilAt (const TopoDS_Wire&     ProfRef,
 
   C2d = BRep_Tool::CurveOnSurface(E,F,First,Last);
   if (C2d.IsNull()) {
-    Standard_ConstructionError::Raise("ConstructionError in PutProfilAt"); 
+    throw Standard_ConstructionError("ConstructionError in PutProfilAt");
   }
 
   if (E.Orientation() == TopAbs_REVERSED) {
@@ -2937,8 +2936,7 @@ TopAbs_Orientation OriEdgeInFace (const TopoDS_Edge& E,
       return Exp.Current().Orientation();
     }
   }
-  Standard_ConstructionError::Raise("BRepFill_Evolved::OriEdgeInFace");
-  return E.Orientation();
+  throw Standard_ConstructionError("BRepFill_Evolved::OriEdgeInFace");
 }
 
 
index 3a8ff73..b0c8ccd 100644 (file)
@@ -328,7 +328,7 @@ void BRepFill_Filling::AddConstraints( const BRepFill_SequenceOfEdgeFaceAndOrder
          Standard_Real f, l;
          BRep_Tool::CurveOnSurface( CurEdge, C2d, Surface, loc, f, l);
          if (Surface.IsNull()) {
-           Standard_Failure::Raise( "Add" );
+           throw Standard_Failure( "Add" );
            return;
          }
          Surface = Handle(Geom_Surface)::DownCast(Surface->Copy());
@@ -708,7 +708,7 @@ void BRepFill_Filling::Build()
   
   TopoDS_Wire FinalWire = WireFromList(FinalEdges);
   if (!(FinalWire.Closed()))
-    Standard_Failure::Raise("Wire is not closed");
+    throw Standard_Failure("Wire is not closed");
   
   myFace = BRepLib_MakeFace( Surface, FinalWire );
 }
index 19c47ba..d71ba4d 100644 (file)
@@ -94,7 +94,7 @@ Standard_Integer DetectKPart(const TopoDS_Edge& Edge1,
   else {
     curv1 = BRep_Tool::Curve(Edge1, loc, first1, last1);
     if (curv1.IsNull())
-      Standard_NullObject::Raise("Null 3D curve in edge");
+      throw Standard_NullObject("Null 3D curve in edge");
     curv1 = 
       Handle(Geom_Curve)::DownCast(curv1->Transformed(loc.Transformation()));
     ff = first1;
@@ -161,7 +161,7 @@ Standard_Integer DetectKPart(const TopoDS_Edge& Edge1,
     else {
       curv = BRep_Tool::Curve(Edge2, loc, first2, last2);
       if (curv.IsNull())
-        Standard_NullObject::Raise("Null 3D curve in edge");
+        throw Standard_NullObject("Null 3D curve in edge");
       curv = 
        Handle(Geom_Curve)::DownCast(curv->Transformed(loc.Transformation()));
       ff = first2;
@@ -341,7 +341,7 @@ void CreateKPart(const TopoDS_Edge& Edge1,const TopoDS_Edge& Edge2,
   else {
     C1 = BRep_Tool::Curve(Edge1, loc, a1, b1);
     if (C1.IsNull())
-      Standard_NullObject::Raise("Null 3D curve in edge");
+      throw Standard_NullObject("Null 3D curve in edge");
     C1 = Handle(Geom_Curve)::DownCast(C1->Transformed(loc.Transformation()));
     aa = a1;
     bb = b1;
@@ -366,7 +366,7 @@ void CreateKPart(const TopoDS_Edge& Edge1,const TopoDS_Edge& Edge2,
   else {
     C2 = BRep_Tool::Curve(Edge2, loc, a1, b1);
     if (C2.IsNull())
-      Standard_NullObject::Raise("Null 3D curve in edge");
+      throw Standard_NullObject("Null 3D curve in edge");
     C2 = Handle(Geom_Curve)::DownCast(C2->Transformed(loc.Transformation()));
     if (Edge2.Orientation() == TopAbs_REVERSED) {
       C2->Reverse();
@@ -669,7 +669,7 @@ void BRepFill_Generator::Perform()
        else {
          C1 = BRep_Tool::Curve(Edge1,L1,f1,l1);
           if (C1.IsNull())
-            Standard_NullObject::Raise("Null 3D curve in edge");
+            throw Standard_NullObject("Null 3D curve in edge");
        }
        if (degen2) {
          Extremities(1) = BRep_Tool::Pnt(V2l);
@@ -679,7 +679,7 @@ void BRepFill_Generator::Perform()
        else {
          C2 = BRep_Tool::Curve(Edge2,L2,f2,l2);
           if (C2.IsNull())
-            Standard_NullObject::Raise("Null 3D curve in edge");
+            throw Standard_NullObject("Null 3D curve in edge");
        }
        
        // compute the location
index 281dd55..b51f7fe 100644 (file)
@@ -68,7 +68,7 @@ static Standard_Boolean isIsoU(const TopoDS_Face& Face,
 
   C = BRep_Tool::CurveOnSurface(Edge,Face, f, l);
   if ( C.IsNull()) {
-    Standard_ConstructionError::Raise ("BRepFill_MultiLine : Edge without PCurve");
+    throw Standard_ConstructionError("BRepFill_MultiLine : Edge without PCurve");
   }
 
   gp_Dir2d D = C->DN(f,1);
@@ -635,7 +635,7 @@ static gp_Pnt2d ValueOnFace(const Standard_Real        U,
         cout << "MultiLine : D1 = D2 and the Curve is not a circle" << endl;
         cout << "  ---> ValueOnFace failed at parameter U = " << U << endl;
 #endif
-        Standard_ConstructionError::Raise("BRepFill_MultiLine: ValueOnFace");
+        throw Standard_ConstructionError("BRepFill_MultiLine: ValueOnFace");
       }
     }
     else if ( D1 < D2) {
index 5cc63bd..dedee68 100644 (file)
@@ -644,15 +644,15 @@ void BRepFill_OffsetWire::Perform (const Standard_Real Offset,
       PerformWithBiLo(myWorkSpine,Offset,myBilo,myLink,myJoinType,Alt);
     }
   }
-  catch (Standard_Failure)//Every exception was caught.
-  {
-    myShape.Nullify();
-    myIsDone = Standard_False;
+  catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout<<"An exception was caught in BRepFill_OffsetWire::Perform : ";
-    Standard_Failure::Caught()->Print(cout);
+    anException.Print(cout);
     cout<<endl;
 #endif
+    (void)anException;
+    myShape.Nullify();
+    myIsDone = Standard_False;
 
     return;
   }
@@ -669,7 +669,7 @@ void BRepFill_OffsetWire::Perform (const Standard_Real Offset,
       if (!aWire.Closed()) {
         myShape.Nullify();
         myIsDone = Standard_False;
-        Standard_ConstructionError::Raise("Offset wire is not closed.");
+        throw Standard_ConstructionError("Offset wire is not closed.");
       }
     }
   }
@@ -1602,10 +1602,7 @@ void BRepFill_OffsetWire::FixHoles()
     TopExp::Vertices( Base, Vf, Vl );
     if(Vf.IsNull() || Vl.IsNull())
     {
-      Standard_Failure::Raise("BRepFill_OffsetWire::FixHoles(): Wrong wire.");
-#ifdef OCCT_DEBUG
-      BRepTools::Write(Base, "Base");
-#endif
+      throw Standard_Failure("BRepFill_OffsetWire::FixHoles(): Wrong wire.");
     }
     gp_Pnt Pf, Pl;
     Pf = BRep_Tool::Pnt(Vf);
@@ -1621,13 +1618,7 @@ void BRepFill_OffsetWire::FixHoles()
 
       if(V1.IsNull() || V2.IsNull())
       {
-        Standard_Failure::Raise("BRepFill_OffsetWire::FixHoles(): Wrong wire.");
-#ifdef OCCT_DEBUG
-        BRepTools::Write(Base, "Base");
-        char name[128];
-        sprintf(name,"Wire_%d",i);
-        BRepTools::Write(aWire, name);
-#endif
+        throw Standard_Failure("BRepFill_OffsetWire::FixHoles(): Wrong wire.");
       }
 
       gp_Pnt P1, P2;
index 46bee4d..c514052 100644 (file)
@@ -469,7 +469,7 @@ TopoDS_Face BRepFill_Pipe::Face(const TopoDS_Edge& ESpine,
   // *************************************************
   iprof = FindEdge(myProfile, EProfile, count);
 
-  if (!iprof) Standard_DomainError::Raise(
+  if (!iprof) throw Standard_DomainError(
               "BRepFill_Pipe::Face : Edge not in the Profile");
 
 
@@ -480,7 +480,7 @@ TopoDS_Face BRepFill_Pipe::Face(const TopoDS_Edge& ESpine,
  for (ii=1; ii<=myLoc->NbLaw() && (!ispin); ii++) 
     if  (ESpine.IsSame(myLoc->Edge(ii))) ispin = ii;
 
-  if (!ispin) Standard_DomainError::Raise(
+  if (!ispin) throw Standard_DomainError(
     "BRepFill_Pipe::Edge  : Edge not in the Spine");
 
   theFace = TopoDS::Face(myFaces->Value(iprof, ispin));
@@ -501,7 +501,7 @@ TopoDS_Edge BRepFill_Pipe::Edge(const TopoDS_Edge&   ESpine,
   // Search if VProfile is a Vertex of myProfile
   // *************************************************
   iprof = FindVertex(myProfile, VProfile, count);
-  if (!iprof) Standard_DomainError::Raise(
+  if (!iprof) throw Standard_DomainError(
        "BRepFill_Pipe::Edge : Vertex not in the Profile");
 
 
@@ -513,7 +513,7 @@ TopoDS_Edge BRepFill_Pipe::Edge(const TopoDS_Edge&   ESpine,
   for (ii=1; ii<=myLoc->NbLaw() && (!ispin); ii++) 
     if  (ESpine.IsSame(myLoc->Edge(ii))) ispin = ii;
 
-  if (!ispin) Standard_DomainError::Raise(
+  if (!ispin) throw Standard_DomainError(
     "BRepFill_Pipe::Edge  : Edge not in the Spine");
 
 
@@ -550,7 +550,7 @@ TopoDS_Shape BRepFill_Pipe::Section(const TopoDS_Vertex& VSpine) const
  for (ii=1; ii<=myLoc->NbLaw()+1 && (!ispin); ii++) 
     if  (VSpine.IsSame(myLoc->Vertex(ii))) ispin = ii;
 
-  if (!ispin) Standard_DomainError::Raise(
+  if (!ispin) throw Standard_DomainError(
     "BRepFill_Pipe::Section  : Vertex not in the Spine");
 
   BRep_Builder B;
@@ -672,7 +672,7 @@ TopoDS_Shape BRepFill_Pipe::MakeShape(const TopoDS_Shape& S,
 
   case TopAbs_SOLID :
   case TopAbs_COMPSOLID :
-    Standard_DomainError::Raise("BRepFill_Pipe::profile contains solids");
+    throw Standard_DomainError("BRepFill_Pipe::profile contains solids");
     break;
 
   case TopAbs_COMPOUND :
@@ -897,7 +897,7 @@ Standard_Integer BRepFill_Pipe::FindEdge(const TopoDS_Shape& S,
 
   case TopAbs_SOLID :
   case TopAbs_COMPSOLID :
-    Standard_DomainError::Raise("BRepFill_Pipe::SOLID or COMPSOLID");
+    throw Standard_DomainError("BRepFill_Pipe::SOLID or COMPSOLID");
     break;
   default:
     break;
@@ -963,7 +963,7 @@ Standard_Integer BRepFill_Pipe::FindVertex(const TopoDS_Shape& S,
 
   case TopAbs_SOLID :
   case TopAbs_COMPSOLID :
-    Standard_DomainError::Raise("BRepFill_Pipe::SOLID or COMPSOLID");
+    throw Standard_DomainError("BRepFill_Pipe::SOLID or COMPSOLID");
     break;
   default:
     break;
index d975770..41379ca 100644 (file)
@@ -124,7 +124,7 @@ static Standard_Boolean ComputeSection(const TopoDS_Wire& W1,
   BRepFill_CompatibleWires CW(SSh);
   CW.SetPercent(0.1);
   CW.Perform();
-  if (!CW.IsDone()) StdFail_NotDone::Raise("Uncompatible wires");
+  if (!CW.IsDone()) throw StdFail_NotDone("Uncompatible wires");
   GeomFill_SequenceOfTrsf EmptyTrsfs;
   Handle(BRepFill_NSections) SL = new (BRepFill_NSections) (CW.Shape(),EmptyTrsfs,SR,0.,1.);
   Standard_Real US = p1/(p1+p2);
@@ -356,7 +356,7 @@ BRepFill_PipeShell::BRepFill_PipeShell(const TopoDS_Wire& Spine)
     BRepFill_CompatibleWires CW(Seq);
     CW.SetPercent(0.1);
     CW.Perform();
-    if (!CW.IsDone()) StdFail_NotDone::Raise("Uncompatible wires");
+    if (!CW.IsDone()) throw StdFail_NotDone("Uncompatible wires");
     TheGuide = TopoDS::Wire(CW.Shape().Value(2));
   }
   else if (GuideClose) {
@@ -825,7 +825,7 @@ void BRepFill_PipeShell::SetForceApproxC1(const Standard_Boolean ForceApproxC1)
  Standard_Boolean BRepFill_PipeShell::MakeSolid() 
 { 
   if (myShape.IsNull()) 
-    StdFail_NotDone::Raise("PipeShell is not built");
+    throw StdFail_NotDone("PipeShell is not built");
   Standard_Boolean B = myShape.Closed();
   BRep_Builder BS;
 
@@ -919,7 +919,7 @@ const TopoDS_Shape& BRepFill_PipeShell::LastShape() const
 void BRepFill_PipeShell::Generated(const TopoDS_Shape&   theShape,
                                   TopTools_ListOfShape& theList) 
 {
-  //   Standard_NotImplemented::Raise("Generated:Pas Fait");
+  //   throw Standard_NotImplemented("Generated:Pas Fait");
   
   theList.Clear();
 
@@ -938,7 +938,7 @@ void BRepFill_PipeShell::Generated(const TopoDS_Shape&   theShape,
  void BRepFill_PipeShell::Prepare() 
 {
   TopoDS_Wire theSect;
-  if (!IsReady()) StdFail_NotDone::Raise("PipeShell");
+  if (!IsReady()) throw StdFail_NotDone("PipeShell");
   if (!myLocation.IsNull() && !mySection.IsNull()) return; // It is ready
  
   //Check set of section for right configuration of punctual sections
@@ -953,7 +953,7 @@ void BRepFill_PipeShell::Generated(const TopoDS_Shape&   theShape,
          wdeg = wdeg && (BRep_Tool::Degenerated(anEdge));
        }
       if (wdeg)
-       Standard_Failure::Raise("Wrong usage of punctual sections");
+       throw Standard_Failure("Wrong usage of punctual sections");
     }
   if (mySeq.Length() <= 2)
     {
@@ -965,7 +965,7 @@ void BRepFill_PipeShell::Generated(const TopoDS_Shape&   theShape,
            wdeg = wdeg && (BRep_Tool::Degenerated(anEdge));
          }
       if (wdeg)
-       Standard_Failure::Raise("Wrong usage of punctual sections");
+       throw Standard_Failure("Wrong usage of punctual sections");
     }
 
   // Construction of the law of location  
@@ -984,7 +984,7 @@ void BRepFill_PipeShell::Generated(const TopoDS_Shape&   theShape,
          } 
          default :
            { // Not planned!
-             Standard_ConstructionError::Raise("PipeShell");
+             throw Standard_ConstructionError("PipeShell");
            }
        }
     }  
@@ -1146,7 +1146,7 @@ void BRepFill_PipeShell::Generated(const TopoDS_Shape&   theShape,
       }
     }
     else {
-      Standard_ConstructionError::Raise("PipeShell : uncompatible wires");
+      throw Standard_ConstructionError("PipeShell : uncompatible wires");
     }
     mySection = new (BRepFill_NSections) (WorkingSections,Transformations,Param,V1,V2);
     
index 5cff512..b65b5f8 100644 (file)
@@ -60,7 +60,7 @@ BRepFill_Section::BRepFill_Section(const TopoDS_Shape& Profile,
       wire.Closed( Standard_True );
     }
   else
-    Standard_Failure::Raise("BRepFill_Section: bad shape type of section");
+    throw Standard_Failure("BRepFill_Section: bad shape type of section");
 }
 
 void BRepFill_Section::Set(const Standard_Boolean IsLaw)
index 292d2b4..1a8ea20 100644 (file)
@@ -196,7 +196,7 @@ BRepFill_SectionPlacement(const Handle(BRepFill_LocationLaw)& Law,
 //     BRepExtrema_DistShapeShape Ext(mySection, myLaw->Wire());
     
 //     if (! Ext.IsDone()) 
-//        Standard_ConstructionError::Raise("Distance Vertex/Spine");
+//        throw Standard_ConstructionError("Distance Vertex/Spine");
 
 //     if (Ext.SupportTypeShape2(1) == BRepExtrema_IsOnEdge) {
 //       TopoDS_Shape sbis = Ext.SupportOnShape2(1);
@@ -317,7 +317,7 @@ BRepFill_SectionPlacement(const Handle(BRepFill_LocationLaw)& Law,
     }
   }
   
-  if (Bof) Standard_ConstructionError::Raise("Interval non trouve !!");
+  if (Bof) throw Standard_ConstructionError("Interval non trouve !!");
   Ind1 = Index(Ind1);
   if (Ind2) Ind2 = Index(Ind2);
   
index 0b46b68..9e35334 100644 (file)
@@ -719,7 +719,7 @@ static TopoDS_Edge BuildEdge(Handle(Geom_Curve)& C3d,
     char* Temp = name ;
     DrawTrSurf::Set(Temp, C3d);
 //    DrawTrSurf::Set(name, C3d);
-    Standard_ConstructionError::Raise("BRepFill_Sweep::BuildEdge");
+    throw Standard_ConstructionError("BRepFill_Sweep::BuildEdge");
 #endif
   }
 
@@ -1419,7 +1419,7 @@ static TopoDS_Edge BuildEdge(const Handle(Geom_Surface)& S,
       DrawTrSurf::Set(Temp,Iso);
 //      DrawTrSurf::Set(name,Iso);
 #endif
-      Standard_ConstructionError::Raise("BRepFill_Sweep::BuildEdge");
+      throw Standard_ConstructionError("BRepFill_Sweep::BuildEdge");
     }
 
     E = MkE.Edge();
@@ -1903,7 +1903,7 @@ BRepFill_Sweep::BRepFill_Sweep(const Handle(BRepFill_SectionLaw)& Section,
       char* Temp = name ;
       DrawTrSurf::Set(Temp,Iso);
 //       DrawTrSurf::Set(name,Iso);
-      Standard_ConstructionError::Raise("BRepFill_Sweep::BuildEdge");
+      throw Standard_ConstructionError("BRepFill_Sweep::BuildEdge");
 #endif
        return Standard_False;  
      }
index 5051e8c..f5f7d05 100644 (file)
@@ -196,7 +196,7 @@ static void EvalParameters(const Geom2dAdaptor_Curve& Bis,
   gp_Pnt P;
 
   if ( !Intersector.IsDone()) {
-    StdFail_NotDone::Raise("BRepFill_TrimSurfaceTool::IntersectWith");
+    throw StdFail_NotDone("BRepFill_TrimSurfaceTool::IntersectWith");
   }
 
   NbPoints = Intersector.NbPoints();
@@ -260,7 +260,7 @@ static void EvalParametersBis(const Geom2dAdaptor_Curve& Bis,
   gp_Pnt P;
 
   if ( !Intersector.IsDone()) {
-    StdFail_NotDone::Raise("BRepFill_TrimSurfaceTool::IntersectWith");
+    throw StdFail_NotDone("BRepFill_TrimSurfaceTool::IntersectWith");
   }
 
   NbPoints = Intersector.NbPoints();
index a619d02..025d27c 100644 (file)
@@ -224,7 +224,7 @@ static void EvalParameters(const TopoDS_Edge&          Edge,
     Intersector = Geom2dInt_GInter(ABis, AC, TolC, Tol);
 
     if ( !Intersector.IsDone()) {
-      StdFail_NotDone::Raise("BRepFill_TrimSurfaceTool::IntersectWith");
+      throw StdFail_NotDone("BRepFill_TrimSurfaceTool::IntersectWith");
     }
 
     NbPoints = Intersector.NbPoints();
@@ -259,7 +259,7 @@ static void EvalParameters(const TopoDS_Edge&          Edge,
       Intersector = Geom2dInt_GInter(ABis, AC, TolC, Tol*10);
 
       if ( !Intersector.IsDone()) {
-        StdFail_NotDone::Raise("BRepFill_TrimSurfaceTool::IntersectWith");
+        throw StdFail_NotDone("BRepFill_TrimSurfaceTool::IntersectWith");
       }
 
       NbPoints = Intersector.NbPoints();
@@ -376,7 +376,7 @@ static void EvalParameters(const TopoDS_Edge&          Edge,
       break;
                                       }
     default:
-      Standard_NotImplemented::Raise(" BRepFill_TrimSurfaceTool");
+      throw Standard_NotImplemented(" BRepFill_TrimSurfaceTool");
     }
 
     gp_Vec2d D12d = Bis->DN(UBis,1);
index 0696dc3..0bf8e39 100644 (file)
@@ -228,7 +228,7 @@ Standard_Boolean BRepIntCurveSurface_Inter::FindPoint()
 IntCurveSurface_IntersectionPoint BRepIntCurveSurface_Inter::Point() const 
 {
   if(myCurrentindex==0) 
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   const IntCurveSurface_IntersectionPoint& ICPS = myIntcs.Point(myCurrentindex);
   return(IntCurveSurface_IntersectionPoint(ICPS.Pnt(),
                                           myCurrentU,     // ICPS.U(),
@@ -245,7 +245,7 @@ IntCurveSurface_IntersectionPoint BRepIntCurveSurface_Inter::Point() const
 Standard_Real BRepIntCurveSurface_Inter::U() const 
 {
   if(myCurrentindex==0) 
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   //-- return(myIntcs.Point(myCurrentindex).U());
   return(myCurrentU);
 }
@@ -257,7 +257,7 @@ Standard_Real BRepIntCurveSurface_Inter::U() const
 Standard_Real BRepIntCurveSurface_Inter::V() const 
 {
   if(myCurrentindex==0) 
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   //-- return(myIntcs.Point(myCurrentindex).V());
   return(myCurrentV);
 }
@@ -269,7 +269,7 @@ Standard_Real BRepIntCurveSurface_Inter::V() const
 Standard_Real BRepIntCurveSurface_Inter::W() const 
 {
   if(myCurrentindex==0) 
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   return(myIntcs.Point(myCurrentindex).W());
 }
 
@@ -280,7 +280,7 @@ Standard_Real BRepIntCurveSurface_Inter::W() const
 TopAbs_State BRepIntCurveSurface_Inter::State() const 
 {
   if(myCurrentindex==0) 
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   //-- return(classifier.State());
   return(myCurrentstate);
 }
@@ -292,7 +292,7 @@ TopAbs_State BRepIntCurveSurface_Inter::State() const
 IntCurveSurface_TransitionOnCurve BRepIntCurveSurface_Inter::Transition() const 
 {
   if(myCurrentindex==0) 
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   return(myIntcs.Point(myCurrentindex).Transition());
 }
 
@@ -311,7 +311,7 @@ const TopoDS_Face& BRepIntCurveSurface_Inter::Face() const
 //===========================================================================
 const gp_Pnt& BRepIntCurveSurface_Inter::Pnt() const { 
   if(myCurrentindex==0) 
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   return(myIntcs.Point(myCurrentindex).Pnt());
 }
 
index 9472bc2..cbbb7dc 100644 (file)
@@ -50,7 +50,7 @@ GeomAbs_Shape BRepLProp::Continuity(const BRepAdaptor_Curve& C1,
   BRepLProp_CLProps clp1(C1,u1,n1,tl);
   BRepLProp_CLProps clp2(C2,u2,n2,tl);
   if(!(clp1.Value().IsEqual(clp2.Value(),tl))) {
-    Standard_Failure::Raise("Courbes non jointives");
+    throw Standard_Failure("Courbes non jointives");
   }
   Standard_Integer min = Min(n1,n2);
   if ( min >= 1 ) {
index cba18bc..c763e2e 100644 (file)
@@ -1959,12 +1959,13 @@ static void EncodeRegularity(const TopoDS_Shape&        theShape,
         BRepLib::EncodeRegularity(E, F1, F2, theTolAng);
     }
   }
-  catch (Standard_Failure) {
+  catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout << "Warning: Exception in BRepLib::EncodeRegularity(): ";
-    Standard_Failure::Caught()->Print(cout);
+    anException.Print(cout);
     cout << endl;
 #endif
+    (void)anException;
   }
 }
 
index a52bbe6..7eb7bd4 100644 (file)
@@ -49,7 +49,7 @@ Standard_Boolean  BRepLib_Command::IsDone()const
 void  BRepLib_Command::Check()const 
 {
   if (!myDone)
-    StdFail_NotDone::Raise("BRep_API: command not done");
+    throw StdFail_NotDone("BRep_API: command not done");
 }
 
 
index 255631b..fb0c0f4 100644 (file)
@@ -187,7 +187,7 @@ static void MakeClosedCurve(Handle(Geom_Curve)& C, const gp_Pnt& PF,
       porig = aPrj.Point().Parameter();
     }
     else {
-      Standard_ConstructionError::Raise("FuseEdges : Projection failed for closed curve");
+      throw Standard_ConstructionError("FuseEdges : Projection failed for closed curve");
     }
   }
            
@@ -217,7 +217,7 @@ BRepLib_FuseEdges::BRepLib_FuseEdges(const TopoDS_Shape& theShape,
  myResultEdgesDone(Standard_False),myNbConnexEdge(0), myConcatBSpl(Standard_False)
 {
 //  if (theShape.ShapeType() != TopAbs_SHELL && theShape.ShapeType() != TopAbs_SOLID)
-//    Standard_ConstructionError::Raise("FuseEdges");
+//    throw Standard_ConstructionError("FuseEdges");
   Standard_NullObject_Raise_if(theShape.IsNull(),"FuseEdges");
   myMapFaces.Clear();
 
@@ -471,7 +471,7 @@ void BRepLib_FuseEdges::BuildListResultEdges()
            aTC = new Geom_TrimmedCurve(aC, f, l);
            if (!Concat.Add(aTC, Precision::Confusion())) {
                   // cannot merge curves
-             Standard_ConstructionError::Raise("FuseEdges : Concatenation failed");
+             throw Standard_ConstructionError("FuseEdges : Concatenation failed");
            }
          }
          C = Concat.BSplineCurve();                    
@@ -490,7 +490,7 @@ void BRepLib_FuseEdges::BuildListResultEdges()
        gp_Pnt aPf = C->Value(f);
        gp_Pnt aPl = C->Value(l);
        if(aPf.Distance(aPl) > Precision::Confusion()) {
-           Standard_ConstructionError::Raise("FuseEdges : Curve must be closed");
+           throw Standard_ConstructionError("FuseEdges : Curve must be closed");
        }
        gp_Pnt PF = BRep_Tool::Pnt(VF);
        if(PF.Distance(aPf) > Precision::Confusion()) {
@@ -499,7 +499,7 @@ void BRepLib_FuseEdges::BuildListResultEdges()
        //
        ME.Init(C, VF, VL, f, l);
        if (!ME.IsDone()) {
-         Standard_ConstructionError::Raise("FuseEdges : MakeEdge failed for closed curve");
+         throw Standard_ConstructionError("FuseEdges : MakeEdge failed for closed curve");
        }
       }
       else {
@@ -521,10 +521,10 @@ void BRepLib_FuseEdges::BuildListResultEdges()
 
          ME.Init(ExtC,VF,VL);
          if (!ME.IsDone()) 
-           Standard_ConstructionError::Raise("FuseEdges : Fusion failed");
+           throw Standard_ConstructionError("FuseEdges : Fusion failed");
        }
        else
-         Standard_ConstructionError::Raise("FuseEdges : Fusion failed");
+         throw Standard_ConstructionError("FuseEdges : Fusion failed");
       }
 
       NewEdge = ME.Edge();
index 300a4f9..729a8e4 100644 (file)
@@ -88,7 +88,7 @@ void BRepMAT2d_LinkTopoBilo::Perform(const BRepMAT2d_Explorer&       Explo,
     }
   }
   else {
-    Standard_ConstructionError::Raise("BRepMAT2d_LinkTopoBilo::Perform");
+    throw Standard_ConstructionError("BRepMAT2d_LinkTopoBilo::Perform");
   }
   
 }
index 9bcb9d1..b7d2adb 100644 (file)
@@ -571,9 +571,9 @@ Standard_CString BRepMesh_Dump(void*            theMeshHandlePtr,
     if (!BRepTools::Write(aMesh, theFileNameStr))
       return "Error: write failed";
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    return Standard_Failure::Caught()->GetMessageString();
+    return anException.GetMessageString();
   }
 
   return theFileNameStr;
index a7e8b48..62ff759 100644 (file)
@@ -2446,9 +2446,9 @@ Standard_CString BRepMesh_DumpPoly(void*            thePolygon,
     if (!BRepTools::Write(aMesh, theFileNameStr))
       return "Error: write failed";
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    return Standard_Failure::Caught()->GetMessageString();
+    return anException.GetMessageString();
   }
 
   return theFileNameStr;
index 761cdec..81808bc 100644 (file)
@@ -45,7 +45,7 @@ public:
     else
     {
       if (myIndex[1] >= 0)
-        Standard_OutOfRange::Raise("BRepMesh_PairOfIndex::Append, more than two index to store");
+        throw Standard_OutOfRange("BRepMesh_PairOfIndex::Append, more than two index to store");
 
       myIndex[1] = theIndex;
     }
@@ -55,7 +55,7 @@ public:
   inline void Prepend(const Standard_Integer theIndex)
   {
     if (myIndex[1] >= 0)
-      Standard_OutOfRange::Raise ("BRepMesh_PairOfIndex::Prepend, more than two index to store");
+      throw Standard_OutOfRange("BRepMesh_PairOfIndex::Prepend, more than two index to store");
 
     myIndex[1] = myIndex[0];
     myIndex[0] = theIndex;
@@ -92,7 +92,7 @@ public:
   inline Standard_Integer Index(const Standard_Integer thePairPos) const
   {
     if (thePairPos != 1 && thePairPos != 2)
-      Standard_OutOfRange::Raise ("BRepMesh_PairOfIndex::Index, requested index is out of range");
+      throw Standard_OutOfRange("BRepMesh_PairOfIndex::Index, requested index is out of range");
 
     return myIndex[thePairPos - 1];
   }
@@ -104,7 +104,7 @@ public:
                        const Standard_Integer theIndex)
   {
     if (thePairPos != 1 && thePairPos != 2)
-      Standard_OutOfRange::Raise ("BRepMesh_PairOfIndex::SetIndex, requested index is out of range");
+      throw Standard_OutOfRange("BRepMesh_PairOfIndex::SetIndex, requested index is out of range");
 
     myIndex[thePairPos - 1] = theIndex;
   }
@@ -114,7 +114,7 @@ public:
   inline void RemoveIndex(const Standard_Integer thePairPos)
   {
     if (thePairPos != 1 && thePairPos != 2)
-      Standard_OutOfRange::Raise ("BRepMesh_PairOfIndex::RemoveIndex, requested index is out of range");
+      throw Standard_OutOfRange("BRepMesh_PairOfIndex::RemoveIndex, requested index is out of range");
 
     if ( thePairPos == 1 )
       myIndex[0] = myIndex[1];
index 397f8ee..2063070 100644 (file)
@@ -451,7 +451,7 @@ static Standard_Boolean FindParameter(const TopoDS_Vertex& V,
     }
   }
   
-  //Standard_NoSuchObject::Raise("BRep_Tool:: no parameter on edge");
+  //throw Standard_NoSuchObject("BRep_Tool:: no parameter on edge");
   return Standard_False;
 }
 
@@ -1644,11 +1644,7 @@ void BRepOffset_MakeOffset::SelfInter(TopTools_MapOfShape& /*Modif*/)
   }    
 #endif  
 
-  Standard_NotImplemented::Raise();
-
-#ifdef OCCT_DEBUG
-  if ( ChronBuild) Clock.Show();
-#endif
+  throw Standard_NotImplemented();
 }
 
 
@@ -3947,7 +3943,7 @@ void TrimEdge(TopoDS_Edge&                  NE,
         gp_Pnt thePoint = BRep_Tool::Pnt(V);
         GeomAPI_ProjectPointOnCurve Projector(thePoint, theCurve);
         if (Projector.NbPoints() == 0)
-          Standard_ConstructionError::Raise("BRepOffset_MakeOffset::TrimEdge no projection");
+          throw Standard_ConstructionError("BRepOffset_MakeOffset::TrimEdge no projection");
         U = Projector.LowerDistanceParameter();
       }
       if (U < UMin) {
@@ -3959,7 +3955,7 @@ void TrimEdge(TopoDS_Edge&                  NE,
     }
     //
     if (V1.IsNull() || V2.IsNull()) {
-      Standard_ConstructionError::Raise("BRepOffset_MakeOffset::TrimEdge");
+      throw Standard_ConstructionError("BRepOffset_MakeOffset::TrimEdge");
     }
     if (!V1.IsSame(V2)) {
       NE.Free( Standard_True );
index 989c2a8..d6325b4 100644 (file)
@@ -1115,7 +1115,7 @@ void BRepOffset_Offset::Init(const TopoDS_Edge&     Path,
   GeomFill_Pipe Pipe(HCP, HEdge1, HEdge2, Abs(Offset));
   Pipe.Perform(Tol, Polynomial, Conti);
   if (!Pipe.IsDone())
-    Standard_ConstructionError::Raise ("GeomFill_Pipe : Cannot make a surface");
+    throw Standard_ConstructionError("GeomFill_Pipe : Cannot make a surface");
   Standard_Real ErrorPipe = Pipe.ErrorOnSurf();
 
   Handle(Geom_Surface) S = Pipe.Surface();
@@ -1584,7 +1584,7 @@ void BRepOffset_Offset::Init(const TopoDS_Edge&  Edge,
   GeomFill_Pipe Pipe(CP,myOffset);
   Pipe.Perform();
   if (!Pipe.IsDone())
-    Standard_ConstructionError::Raise ("GeomFill_Pipe : Cannot make a surface");
+    throw Standard_ConstructionError("GeomFill_Pipe : Cannot make a surface");
 
   BRepLib_MakeFace MF(Pipe.Surface(), Precision::Confusion());
   myFace = MF.Face();
index 89d5676..4c8b98c 100644 (file)
@@ -178,8 +178,7 @@ TopAbs_Orientation BRepOffset_Tool::OriEdgeInFace (const TopoDS_Edge& E,
       return Exp.Current().Orientation();
     }
   }
-  Standard_ConstructionError::Raise("BRepOffset_Tool::OriEdgeInFace");
-  return E.Orientation();
+  throw Standard_ConstructionError("BRepOffset_Tool::OriEdgeInFace");
 }
 
 
@@ -473,8 +472,7 @@ static void BuildPCurves (const TopoDS_Edge&  E,
     B.UpdateEdge (E,C2d,F,BRep_Tool::Tolerance(E));
   }
   else {
-    Standard_ConstructionError::Raise("BRepOffset_Tool::BuildPCurves");
-    cout <<"Echec ProjLib"<<endl;
+    throw Standard_ConstructionError("BRepOffset_Tool::BuildPCurves");
   }
 }
 
index 032cf84..419912e 100644 (file)
@@ -148,7 +148,7 @@ static void BuildDomains(TopoDS_Face&               myFace,
   if (myFace.IsNull()) {
     myFace   = BRepBuilderAPI_MakeFace(TopoDS::Wire(WorkWires.First()),Standard_True);
     if (myFace.IsNull())
-      StdFail_NotDone::Raise ("BRepOffsetAPI_MakeOffset : the wire is not planar");
+      throw StdFail_NotDone("BRepOffsetAPI_MakeOffset : the wire is not planar");
   }
 //  Modified by Sergey KHROMOV - Thu Apr 26 16:04:43 2001 Begin
   TopExp_Explorer anExp(myFace, TopAbs_WIRE);
@@ -189,7 +189,7 @@ static void BuildDomains(TopoDS_Face&               myFace,
   }
   FR.Perform();
   if (!FR.IsDone()) {
-    StdFail_NotDone::Raise ("BRepOffsetAPI_MakeOffset : Build Domains");
+    throw StdFail_NotDone("BRepOffsetAPI_MakeOffset : Build Domains");
   }
   TopTools_ListOfShape Faces;
 #ifdef OCCT_DEBUG
@@ -354,13 +354,13 @@ void BRepOffsetAPI_MakeOffset::Perform(const Standard_Real Offset,
     else
       Done();
   }
-  catch(Standard_Failure) //Every exception was caught.
-  {
+  catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout<<"An exception was caught in BRepOffsetAPI_MakeOffset::Perform : ";
-    Standard_ConstructionError::Caught()->Print(cout); 
+    anException.Print(cout); 
     cout<<endl;
 #endif
+    (void)anException;
     NotDone();
     myShape.Nullify();
   }
index 35ef490..9fe1e61 100644 (file)
@@ -277,7 +277,7 @@ void BRepOffsetAPI_MakePipeShell::SetMaxSegments(const Standard_Integer NewMaxSe
 //=======================================================================
  Standard_Boolean BRepOffsetAPI_MakePipeShell::MakeSolid() 
 {
-  if (!IsDone()) StdFail_NotDone::Raise("BRepOffsetAPI_MakePipeShell::MakeSolid");
+  if (!IsDone()) throw StdFail_NotDone("BRepOffsetAPI_MakePipeShell::MakeSolid");
   Standard_Boolean Ok;
   Ok = myPipe->MakeSolid();
   if (Ok) myShape = myPipe->Shape();
index 18038cd..fa39fff 100644 (file)
@@ -193,7 +193,7 @@ static TopoDS_Solid MakeSolid(TopoDS_Shell& shell, const TopoDS_Wire& wire1,
   TopoDS_Face& face1, TopoDS_Face& face2)
 {
   if (shell.IsNull())
-    StdFail_NotDone::Raise("Thrusections is not build");
+    throw StdFail_NotDone("Thrusections is not build");
   Standard_Boolean B = shell.Closed();
   BRep_Builder BB;
 
@@ -346,7 +346,7 @@ void BRepOffsetAPI_ThruSections::Build()
       wdeg = wdeg && (BRep_Tool::Degenerated(anEdge));
     }
     if (wdeg)
-      Standard_Failure::Raise("Wrong usage of punctual sections");
+      throw Standard_Failure("Wrong usage of punctual sections");
   }
   if (myWires.Length() <= 2)
   {
@@ -358,7 +358,7 @@ void BRepOffsetAPI_ThruSections::Build()
         wdeg = wdeg && (BRep_Tool::Degenerated(anEdge));
       }
       if (wdeg)
-        Standard_Failure::Raise("Wrong usage of punctual sections");
+        throw Standard_Failure("Wrong usage of punctual sections");
   }
 
   if (myWCheck) {
@@ -878,7 +878,7 @@ static Handle(Geom_BSplineCurve) EdgeToBSpline (const TopoDS_Edge& theEdge)
     Standard_Real aFirst, aLast;
     Handle(Geom_Curve) aCurve = BRep_Tool::Curve (theEdge, aLoc, aFirst, aLast);
     if (aCurve.IsNull())
-      Standard_NullObject::Raise("Null 3D curve in edge");
+      throw Standard_NullObject("Null 3D curve in edge");
 
     // convert its part used by edge to bspline; note that if edge curve is bspline,
     // conversion made via trimmed curve is still needed -- it will copy it, segment 
@@ -1106,7 +1106,7 @@ void BRepOffsetAPI_ThruSections::CriteriumWeight(Standard_Real& W1, Standard_Rea
 
 void BRepOffsetAPI_ThruSections::SetCriteriumWeight(const Standard_Real W1, const Standard_Real W2, const Standard_Real W3)
 {
-  if (W1 < 0 || W2 < 0 || W3 < 0 ) Standard_DomainError::Raise();
+  if (W1 < 0 || W2 < 0 || W3 < 0 ) throw Standard_DomainError();
   myCritWeights[0] = W1;
   myCritWeights[1] = W2;
   myCritWeights[2] = W3;
index 28cd3c3..721a4ff 100644 (file)
@@ -40,11 +40,11 @@ BRepPrim_Cone::BRepPrim_Cone(const Standard_Real Angle,
        myRadius(Radius)
 {
   if (Height < Precision::Confusion())
-    Standard_DomainError::Raise("cone with null height");
+    throw Standard_DomainError("cone with null height");
   if (myHalfAngle*Height < Precision::Confusion())
-    Standard_DomainError::Raise("cone with null angle");
+    throw Standard_DomainError("cone with null angle");
   if ((M_PI/2 - myHalfAngle)*Height < Precision::Confusion())
-    Standard_DomainError::Raise("cone with angle > PI/2");
+    throw Standard_DomainError("cone with angle > PI/2");
   
   // cut at top
   VMax(Height / Cos(myHalfAngle));
@@ -63,7 +63,7 @@ BRepPrim_Cone::BRepPrim_Cone(const Standard_Real Angle) :
        myRadius(0.)
 {
   if ((Angle < 0) || (Angle > M_PI/2)) 
-    Standard_DomainError::Raise("cone with angle <0 or > PI/2");
+    throw Standard_DomainError("cone with angle <0 or > PI/2");
   VMin(0.);
   SetMeridian();
 }
@@ -81,7 +81,7 @@ BRepPrim_Cone::BRepPrim_Cone(const Standard_Real Angle,
        myRadius(0.)
 {
   if ((Angle < 0) || (Angle > M_PI/2)) 
-    Standard_DomainError::Raise("cone with angle <0 or > PI/2");
+    throw Standard_DomainError("cone with angle <0 or > PI/2");
   VMin(0.);
   SetMeridian();
 }
@@ -97,7 +97,7 @@ BRepPrim_Cone::BRepPrim_Cone(const Standard_Real Angle,
        myHalfAngle(Angle)
 {
   if ((Angle < 0) || (Angle > M_PI/2)) 
-    Standard_DomainError::Raise("cone with angle <0 or > PI/2");
+    throw Standard_DomainError("cone with angle <0 or > PI/2");
   VMin(0.);
   SetMeridian();
 }
@@ -190,11 +190,11 @@ void BRepPrim_Cone::SetParameters(const Standard_Real R1,
 {
   if (((R1 != 0) && (R1 < Precision::Confusion())) ||
       ((R2 != 0) && (R2 < Precision::Confusion())))
-    Standard_DomainError::Raise("cone with negative or too small radius");
+    throw Standard_DomainError("cone with negative or too small radius");
   if (Abs(R1-R2) < Precision::Confusion())
-    Standard_DomainError::Raise("cone with two identic radii");
+    throw Standard_DomainError("cone with two identic radii");
   if (H < Precision::Confusion())
-    Standard_DomainError::Raise("cone with negative or null height");
+    throw Standard_DomainError("cone with negative or null height");
 
   myRadius = R1;
   myHalfAngle = ATan((R2 - R1) / H);
index 9d331bb..70be550 100644 (file)
@@ -93,12 +93,12 @@ void BRepPrim_FaceBuilder::Init(const BRep_Builder& B,
   Standard_Real USMin,USMax,VSMin,VSMax;
   S->Bounds(USMin,USMax,VSMin,VSMax);
   
-  if (UMin >= UMax) Standard_ConstructionError::Raise("BRepPrim_FaceBuilder");
-  if (VMin >= VMax) Standard_ConstructionError::Raise("BRepPrim_FaceBuilder");
-  if (UMin < USMin) Standard_ConstructionError::Raise("BRepPrim_FaceBuilder");
-  if (UMax > USMax) Standard_ConstructionError::Raise("BRepPrim_FaceBuilder");
-  if (VMin < VSMin) Standard_ConstructionError::Raise("BRepPrim_FaceBuilder");
-  if (VMax > VSMax) Standard_ConstructionError::Raise("BRepPrim_FaceBuilder");
+  if (UMin >= UMax) throw Standard_ConstructionError("BRepPrim_FaceBuilder");
+  if (VMin >= VMax) throw Standard_ConstructionError("BRepPrim_FaceBuilder");
+  if (UMin < USMin) throw Standard_ConstructionError("BRepPrim_FaceBuilder");
+  if (UMax > USMax) throw Standard_ConstructionError("BRepPrim_FaceBuilder");
+  if (VMin < VSMin) throw Standard_ConstructionError("BRepPrim_FaceBuilder");
+  if (VMax > VSMax) throw Standard_ConstructionError("BRepPrim_FaceBuilder");
 
   // Make the vertices
   B.MakeVertex(myVertex[0],S->Value(UMin,VMin),Precision::Confusion());
index 89692f9..391ffac 100644 (file)
@@ -67,7 +67,7 @@ static Standard_Integer BRepPrim_Wedge_NumDir2
 {
   Standard_Integer i1 = BRepPrim_Wedge_NumDir1(d1);
   Standard_Integer i2 = BRepPrim_Wedge_NumDir1(d2);
-  if ( i1/2 == i2/2 ) Standard_DomainError::Raise();
+  if ( i1/2 == i2/2 ) throw Standard_DomainError();
   return tab[i1][i2];
 }
 
@@ -86,7 +86,7 @@ static Standard_Integer BRepPrim_Wedge_NumDir3
   Standard_Integer i3 = BRepPrim_Wedge_NumDir1(d3);
   if (( i1/2 == i2/2 ) ||
       ( i2/2 == i3/2 ) ||
-      ( i3/2 == i1/2 )) Standard_DomainError::Raise();
+      ( i3/2 == i1/2 )) throw Standard_DomainError();
   return val[i1]+val[i2]+val[i3];
 }
 
@@ -102,13 +102,13 @@ static void BRepPrim_Wedge_Check(const Standard_Boolean V[],
 {
   Standard_Integer i;
   for (i = 0; i < NBVERTICES; i++)
-    if (V[i]) Standard_DomainError::Raise();
+    if (V[i]) throw Standard_DomainError();
   for (i = 0; i < NBEDGES; i++)
-    if (E[i]) Standard_DomainError::Raise();
+    if (E[i]) throw Standard_DomainError();
   for (i = 0; i < NBWIRES; i++)
-    if (W[i]) Standard_DomainError::Raise();
+    if (W[i]) throw Standard_DomainError();
   for (i = 0; i < NBFACES; i++)
-    if (F[i]) Standard_DomainError::Raise();
+    if (F[i]) throw Standard_DomainError();
 }
 
 //=======================================================================
@@ -161,7 +161,7 @@ BRepPrim_GWedge::BRepPrim_GWedge (const BRepPrim_Builder& B,
   if ( ( dx <= Precision::Confusion() ) ||
        ( dy <= Precision::Confusion() ) ||
        ( dz <= Precision::Confusion() ) )
-    Standard_DomainError::Raise();
+    throw Standard_DomainError();
   BRepPrim_Wedge_Init(ShellBuilt,VerticesBuilt,EdgesBuilt,
                        WiresBuilt,FacesBuilt);
 }
@@ -195,7 +195,7 @@ BRepPrim_GWedge::BRepPrim_GWedge (const BRepPrim_Builder& B,
        ( dy <= Precision::Confusion() ) ||
        ( dz <= Precision::Confusion() ) ||
        ( ltx < 0 ) )
-    Standard_DomainError::Raise();
+    throw Standard_DomainError();
   BRepPrim_Wedge_Init(ShellBuilt,VerticesBuilt,EdgesBuilt,
                        WiresBuilt,FacesBuilt);
 }
@@ -236,7 +236,7 @@ BRepPrim_GWedge::BRepPrim_GWedge (const BRepPrim_Builder& B,
        ( ZMax-ZMin <= Precision::Confusion() ) ||
        ( Z2Max-Z2Min < 0 ) ||
        ( X2Max-X2Min < 0 ) )
-    Standard_DomainError::Raise();
+    throw Standard_DomainError();
   BRepPrim_Wedge_Init(ShellBuilt,VerticesBuilt,EdgesBuilt,
                        WiresBuilt,FacesBuilt);
 }
@@ -658,7 +658,7 @@ gp_Lin BRepPrim_GWedge::Line
   (const BRepPrim_Direction d1,
    const BRepPrim_Direction d2)
 {
-  if (!HasEdge(d1,d2)) Standard_DomainError::Raise();
+  if (!HasEdge(d1,d2)) throw Standard_DomainError();
 
   Standard_Integer i = BRepPrim_Wedge_NumDir2(d1,d2);
 
@@ -799,7 +799,7 @@ const TopoDS_Edge& BRepPrim_GWedge::Edge
        (const BRepPrim_Direction d1,
        const BRepPrim_Direction d2)
 {
-  if (!HasEdge(d1,d2)) Standard_DomainError::Raise();
+  if (!HasEdge(d1,d2)) throw Standard_DomainError();
 
   Standard_Integer i = BRepPrim_Wedge_NumDir2(d1,d2);
 
@@ -894,7 +894,7 @@ gp_Pnt  BRepPrim_GWedge::Point
    const BRepPrim_Direction d2,
    const BRepPrim_Direction d3)
 {
-  if (!HasVertex(d1,d2,d3)) Standard_DomainError::Raise();
+  if (!HasVertex(d1,d2,d3)) throw Standard_DomainError();
 
   Standard_Integer i = BRepPrim_Wedge_NumDir3(d1,d2,d3);
 
@@ -969,7 +969,7 @@ const TopoDS_Vertex& BRepPrim_GWedge::Vertex
        const BRepPrim_Direction d2,
        const BRepPrim_Direction d3)
 {
-  if (!HasVertex(d1,d2,d3)) Standard_DomainError::Raise();
+  if (!HasVertex(d1,d2,d3)) throw Standard_DomainError();
 
   Standard_Integer i = BRepPrim_Wedge_NumDir3(d1,d2,d3);
 
index f20ebc6..3cd65c3 100644 (file)
@@ -81,13 +81,13 @@ static void BRepPrim_OneAxis_Check(const Standard_Boolean V[],
 {
   Standard_Integer i;
   for (i = 0; i < NBVERTICES; i++)
-    if (V[i]) Standard_DomainError::Raise();
+    if (V[i]) throw Standard_DomainError();
   for (i = 0; i < NBEDGES; i++)
-    if (E[i]) Standard_DomainError::Raise();
+    if (E[i]) throw Standard_DomainError();
   for (i = 0; i < NBWIRES; i++)
-    if (W[i]) Standard_DomainError::Raise();
+    if (W[i]) throw Standard_DomainError();
   for (i = 0; i < NBFACES; i++)
-    if (F[i]) Standard_DomainError::Raise();
+    if (F[i]) throw Standard_DomainError();
 }
 
 //=======================================================================
index d5ad20b..c401e6d 100644 (file)
@@ -123,7 +123,7 @@ void BRepProj_Projection::BuildSection (const TopoDS_Shape& theShape,
     aShape = C;
   }
   if ( aShape.IsNull() )
-    Standard_ConstructionError::Raise(__FILE__": target shape has no faces");
+    throw Standard_ConstructionError(__FILE__": target shape has no faces");
 
   // build section computing pcurves on the shape
 //  BRepAlgoAPI_Section aSectionTool (aShape, theTool, Standard_False);
@@ -178,7 +178,7 @@ BRepProj_Projection::BRepProj_Projection(const TopoDS_Shape& Wire,
   Standard_NullObject_Raise_if((Wire.IsNull() || Shape.IsNull()),__FILE__": null input shape");
   if (Wire.ShapeType() != TopAbs_EDGE && 
       Wire.ShapeType() != TopAbs_WIRE ) 
-    Standard_ConstructionError::Raise(__FILE__": projected shape is neither wire nor edge");
+    throw Standard_ConstructionError(__FILE__": projected shape is neither wire nor edge");
 
   // compute the "length" of the cylindrical surface to build
   Standard_Real mdis = DistanceIn(Wire, Shape);
@@ -214,7 +214,7 @@ BRepProj_Projection::BRepProj_Projection (const TopoDS_Shape& Wire,
   Standard_NullObject_Raise_if((Wire.IsNull() || Shape.IsNull()),__FILE__": null input shape");
   if (Wire.ShapeType() != TopAbs_EDGE && 
       Wire.ShapeType() != TopAbs_WIRE ) 
-    Standard_ConstructionError::Raise(__FILE__": projected shape is neither wire nor edge");
+    throw Standard_ConstructionError(__FILE__": projected shape is neither wire nor edge");
 
   // if Wire is only an edge, transform it into a Wire
   TopoDS_Wire aWire;
@@ -240,7 +240,7 @@ BRepProj_Projection::BRepProj_Projection (const TopoDS_Shape& Wire,
   // compute the ratio of the scale transformation
   Standard_Real Scale = PC.Distance(P);
   if ( Abs (Scale) < Precision::Confusion() ) 
-    Standard_ConstructionError::Raise("Projection");
+    throw Standard_ConstructionError("Projection");
   Scale = 1. + mdis / Scale;
   
   // move the base of the conical surface by scaling it with ratio Scale
index 6472c67..5a2668a 100644 (file)
@@ -137,16 +137,16 @@ TopoDS_Shape BRepSweep_NumLinearRegularSweep::Shape (const TopoDS_Shape& aGenS,
         myBuilder.MakeShell(myShapes(iGenS,iDirS));
         break;
       case TopAbs_SOLID :
-        Standard_NoSuchObject::Raise("Solids are not Processed");
+        throw Standard_NoSuchObject("Solids are not Processed");
         break;
       case TopAbs_COMPSOLID :
-        Standard_NoSuchObject::Raise("Solids are not Processed");
+        throw Standard_NoSuchObject("Solids are not Processed");
         break;
       case TopAbs_COMPOUND :
         myBuilder.MakeCompound(myShapes(iGenS,iDirS));
         break;
       default:
-        Standard_NoSuchObject::Raise("Unknown Shape"); 
+        throw Standard_NoSuchObject("Unknown Shape");
         break;
       }
       bGenS = aGenS;
@@ -230,16 +230,16 @@ TopoDS_Shape BRepSweep_NumLinearRegularSweep::Shape (const TopoDS_Shape& aGenS,
         myBuilder.MakeCompSolid(myShapes(iGenS,iDirS));
         break;
       case TopAbs_SOLID :
-        Standard_NoSuchObject::Raise("Solids are not Processed");
+        throw Standard_NoSuchObject("Solids are not Processed");
         break;
       case TopAbs_COMPSOLID :
-        Standard_NoSuchObject::Raise("Solids are not Processed");
+        throw Standard_NoSuchObject("Solids are not Processed");
         break;
       case TopAbs_COMPOUND :
         myBuilder.MakeCompound(myShapes(iGenS,iDirS));
         break;
       default:
-        Standard_NoSuchObject::Raise("Unknown Shape"); 
+        throw Standard_NoSuchObject("Unknown Shape");
         break;
       }
       bGenS = aGenS;
@@ -374,16 +374,16 @@ TopoDS_Shape BRepSweep_NumLinearRegularSweep::Shape (const TopoDS_Shape& aGenS,
         myBuilder.MakeCompSolid(myShapes(iGenS,iDirS));
         break;
       case TopAbs_SOLID :
-        Standard_NoSuchObject::Raise("Solids are not Processed");
+        throw Standard_NoSuchObject("Solids are not Processed");
         break;
       case TopAbs_COMPSOLID :
-        Standard_NoSuchObject::Raise("Solids are not Processed");
+        throw Standard_NoSuchObject("Solids are not Processed");
         break;
       case TopAbs_COMPOUND :
         myBuilder.MakeCompound(myShapes(iGenS,iDirS));
         break;
       default:
-        Standard_NoSuchObject::Raise("Unknown Shape"); 
+        throw Standard_NoSuchObject("Unknown Shape");
         break;
       }
       bDirS = aDirS;
index 400671e..79fc035 100644 (file)
@@ -461,7 +461,7 @@ void  BRepSweep_Rotation::SetGeneratingPCurve
       if (!aTrimmedCurve.IsNull()) {
         GL = Handle(Geom_Line)::DownCast(aTrimmedCurve->BasisCurve());
         if (GL.IsNull()) {
-            Standard_ConstructionError::Raise("BRepSweep_Rotation::SetGeneratingPCurve");
+            throw Standard_ConstructionError("BRepSweep_Rotation::SetGeneratingPCurve");
         }
       }
     }
index fff1366..b195b67 100644 (file)
@@ -970,7 +970,7 @@ static Standard_Integer scalexyz(Draw_Interpretor& /*di*/, Standard_Integer n, c
   aGTrsf.SetVectorialPart(rot);
   BRepBuilderAPI_GTransform aBRepGTrsf (aShapeBase, aGTrsf, Standard_False);
   if (!aBRepGTrsf.IsDone())
-    Standard_ConstructionError::Raise("Scaling not done");
+    throw Standard_ConstructionError("Scaling not done");
   TopoDS_Shape Result = aBRepGTrsf.Shape();
 
   DBRep::Set(a[1], Result);
index ff9e5fb..60f6510 100644 (file)
@@ -1000,9 +1000,9 @@ static Standard_Integer checkshape(Draw_Interpretor& theCommands,
       }
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     theCommands<<"checkshape exception : ";
-    theCommands << Standard_Failure::Caught()->GetMessageString();
+    theCommands << anException.GetMessageString();
     theCommands<<"\n";
     return 1;
   }
index 9e51956..7bead0b 100644 (file)
@@ -204,13 +204,13 @@ static Standard_Integer plate (Draw_Interpretor & di,Standard_Integer n,const ch
     DBRep::Set(name, E);
     MW.Add(E);
     if (MW.IsDone()==Standard_False) {
-      Standard_Failure::Raise("mkWire is over ");
+      throw Standard_Failure("mkWire is over ");
     }
       
   }
   TopoDS_Wire W;
   W=MW.Wire();
-  if (!(W.Closed())) Standard_Failure::Raise("Wire is not closed");
+  if (!(W.Closed())) throw Standard_Failure("Wire is not closed");
   BRepBuilderAPI_MakeFace MF(Henri.Surface(),W,Standard_True);
   DBRep::Set(a[1],MF.Face());
   return 0;
@@ -437,12 +437,12 @@ static Standard_Integer approxplate (Draw_Interpretor & di,Standard_Integer n,co
     BRepLib::BuildCurve3d(E);
     MW.Add(E);
     if (MW.IsDone()==Standard_False) {
-      Standard_Failure::Raise("mkWire is over ");
+      throw Standard_Failure("mkWire is over ");
     }
   }
   TopoDS_Wire W;
   W=MW.Wire();
-  if (!(W.Closed())) Standard_Failure::Raise("Wire is not closed");
+  if (!(W.Closed())) throw Standard_Failure("Wire is not closed");
   BRepBuilderAPI_MakeFace MF(support,W,Standard_True);
   DBRep::Set(a[1],MF.Face());
 
index 37e832f..3dda731 100644 (file)
@@ -36,9 +36,9 @@ const char* BRepTools_Write (const char* theFileStr, void* theShapePtr)
     else
       return "Error: write failed";
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    return Standard_Failure::Caught()->GetMessageString();
+    return anException.GetMessageString();
   }
 }
 
@@ -58,9 +58,9 @@ const char* BRepTools_Dump (void* theShapePtr)
 
     return "Shape dumped to cout";
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    return Standard_Failure::Caught()->GetMessageString();
+    return anException.GetMessageString();
   }
 }
 
@@ -82,9 +82,9 @@ const char* BRepTools_DumpLoc (void* theLocationPtr)
 
     return "Location dumped to cout";
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    return Standard_Failure::Caught()->GetMessageString();
+    return anException.GetMessageString();
   }
 }
 
index 76169ff..9123e8f 100644 (file)
@@ -126,7 +126,7 @@ Standard_Boolean BRepTools_GTrsfModification::NewSurface
        }
     }
     else{
-      Standard_NoSuchObject::Raise("BRepTools_GTrsfModification : Pb no BSpline/Bezier Type Surface");
+      throw Standard_NoSuchObject("BRepTools_GTrsfModification : Pb no BSpline/Bezier Type Surface");
     }
 
   L.Identity();
@@ -175,7 +175,7 @@ Standard_Boolean BRepTools_GTrsfModification::NewCurve
        }
       }
       else {
-        Standard_NoSuchObject::Raise("BRepTools_GTrsfModification : Pb no BSpline/Bezier Type Curve");
+        throw Standard_NoSuchObject("BRepTools_GTrsfModification : Pb no BSpline/Bezier Type Curve");
       }
     C = new Geom_TrimmedCurve(C, f, l);
   }
index eb8cf01..edfe56d 100644 (file)
@@ -119,7 +119,7 @@ static TopTools_IndexedMapOfShape MapE, MapF;
 void BRepTools_Modifier::Perform(const Handle(BRepTools_Modification)& M, const Handle(Message_ProgressIndicator) & aProgress)
 {
   if (myShape.IsNull()) {
-    Standard_NullObject::Raise();
+    throw Standard_NullObject();
   }
 #ifdef DEBUG_Modifier
   MapE.Clear(); MapF.Clear();
index bb3fd23..338bfd9 100644 (file)
@@ -24,7 +24,7 @@
 inline const TopoDS_Shape& BRepTools_Modifier::ModifiedShape
   (const TopoDS_Shape& S) const
 {
-  if (!myMap.IsBound(S)) { Standard_NoSuchObject::Raise();}
+  if (!myMap.IsBound(S)) { throw Standard_NoSuchObject();}
   return myMap(S);
 }
 
index 8aea7b8..698aa71 100644 (file)
@@ -192,8 +192,7 @@ Standard_Boolean BRepTools_TrsfModification::NewCurve2d
     if ( gtrsf.Form() != gp_Identity) {
       NewC = GeomLib::GTransform(NewC,gtrsf);
       if (NewC.IsNull()) {
-       Standard_DomainError::Raise("TrsfModification:Error in NewCurve2d");
-         return Standard_False;
+       throw Standard_DomainError("TrsfModification:Error in NewCurve2d");
        }
       newf = NewC->FirstParameter();
       newl = NewC->LastParameter();
index 1df2c1d..49e4e4e 100644 (file)
@@ -604,8 +604,7 @@ TopAbs_Orientation BRepTools_WireExplorer::Orientation() const
       return it.Value().Orientation();
     it.Next();
   }
-  Standard_NoSuchObject::Raise("BRepTools_WireExplorer::Orientation");
-  return TopAbs_FORWARD;
+  throw Standard_NoSuchObject("BRepTools_WireExplorer::Orientation");
 }
 
 //=======================================================================
index 1b3b5de..f81c2a7 100644 (file)
@@ -686,6 +686,5 @@ const BRepTopAdaptor_FClass2d &  BRepTopAdaptor_FClass2d::Copy(const BRepTopAdap
 #ifdef OCCT_DEBUG
   cerr<<"Copy not allowed in BRepTopAdaptor_FClass2d"<<endl;
 #endif
-  Standard_ConstructionError::Raise();
-  return(*this);
+  throw Standard_ConstructionError();
 }
index db15eae..0b608df 100644 (file)
@@ -69,7 +69,7 @@ static
 //=======================================================================
   void BRepTopAdaptor_TopolTool::Initialize()
 {
-  Standard_NotImplemented::Raise("BRepTopAdaptor_TopolTool::Initialize()");
+  throw Standard_NotImplemented("BRepTopAdaptor_TopolTool::Initialize()");
 }
 //=======================================================================
 //function : Initialize
@@ -79,7 +79,7 @@ static
 {
   Handle(BRepAdaptor_HSurface) brhs = 
     Handle(BRepAdaptor_HSurface)::DownCast(S);
-  if (brhs.IsNull()) {Standard_ConstructionError::Raise();}
+  if (brhs.IsNull()) {throw Standard_ConstructionError();}
   TopoDS_Shape s_wnt = ((BRepAdaptor_Surface *)&(brhs->Surface()))->Face();
   s_wnt.Orientation(TopAbs_FORWARD);
   myFace = TopoDS::Face(s_wnt);
@@ -105,7 +105,7 @@ static
   void BRepTopAdaptor_TopolTool::Initialize(const Handle(Adaptor2d_HCurve2d)& C)
 {
   myCurve = Handle(BRepAdaptor_HCurve2d)::DownCast(C);
-  if (myCurve.IsNull()) {Standard_ConstructionError::Raise();}
+  if (myCurve.IsNull()) {throw Standard_ConstructionError();}
 }
 //=======================================================================
 //function : Init
@@ -506,11 +506,11 @@ Standard_Real BRepTopAdaptor_TopolTool::Tol3d(const Handle(Adaptor2d_HCurve2d)&
 {
   Handle(BRepAdaptor_HCurve2d) brhc = Handle(BRepAdaptor_HCurve2d)::DownCast(C);
   if (brhc.IsNull())
-    Standard_DomainError::Raise("BRepTopAdaptor_TopolTool: arc has no 3d representation");
+    throw Standard_DomainError("BRepTopAdaptor_TopolTool: arc has no 3d representation");
   const BRepAdaptor_Curve2d& brc = (const BRepAdaptor_Curve2d &)brhc->Curve2d();
   const TopoDS_Edge& edge = brc.Edge();
   if (edge.IsNull())
-    Standard_DomainError::Raise("BRepTopAdaptor_TopolTool: arc has no 3d representation");
+    throw Standard_DomainError("BRepTopAdaptor_TopolTool: arc has no 3d representation");
   return BRep_Tool::Tolerance(edge);
 }
 
@@ -523,10 +523,10 @@ Standard_Real BRepTopAdaptor_TopolTool::Tol3d(const Handle(Adaptor3d_HVertex)& V
 {
   Handle(BRepTopAdaptor_HVertex) brhv = Handle(BRepTopAdaptor_HVertex)::DownCast(V);
   if (brhv.IsNull())
-    Standard_DomainError::Raise("BRepTopAdaptor_TopolTool: vertex has no 3d representation");
+    throw Standard_DomainError("BRepTopAdaptor_TopolTool: vertex has no 3d representation");
   const TopoDS_Vertex& ver = brhv->Vertex();
   if (ver.IsNull())
-    Standard_DomainError::Raise("BRepTopAdaptor_TopolTool: vertex has no 3d representation");
+    throw Standard_DomainError("BRepTopAdaptor_TopolTool: vertex has no 3d representation");
   return BRep_Tool::Tolerance(ver);
 }
 
@@ -539,9 +539,9 @@ gp_Pnt BRepTopAdaptor_TopolTool::Pnt(const Handle(Adaptor3d_HVertex)& V) const
 {
   Handle(BRepTopAdaptor_HVertex) brhv = Handle(BRepTopAdaptor_HVertex)::DownCast(V);
   if (brhv.IsNull())
-    Standard_DomainError::Raise("BRepTopAdaptor_TopolTool: vertex has no 3d representation");
+    throw Standard_DomainError("BRepTopAdaptor_TopolTool: vertex has no 3d representation");
   const TopoDS_Vertex& ver = brhv->Vertex();
   if (ver.IsNull())
-    Standard_DomainError::Raise("BRepTopAdaptor_TopolTool: vertex has no 3d representation");
+    throw Standard_DomainError("BRepTopAdaptor_TopolTool: vertex has no 3d representation");
   return BRep_Tool::Pnt(ver);
 }
index 5db74e7..3e4b688 100644 (file)
@@ -2810,7 +2810,7 @@ void BSplCLib::Trimming(const Standard_Integer         Degree,
   mm[0] = mm[1] = Degree;
   if (!PrepareInsertKnots( Degree, Periodic, Knots, Mults, K, &M, 
                          nbpoles, nbknots, Epsilon( U1), 0))
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
 
   TColStd_Array1OfReal    TempPoles(1, nbpoles*Dimension);
   TColStd_Array1OfReal    TempKnots(1, nbknots);
@@ -3040,7 +3040,7 @@ void  BSplCLib::Interpolate(const Standard_Integer         Degree,
                            UpperBandWidth,
                            LowerBandWidth) ;
   if(ErrorCode)
-    Standard_OutOfRange::Raise("BSplCLib::Interpolate");
+    throw Standard_OutOfRange("BSplCLib::Interpolate");
 
   ErrorCode =
   BSplCLib::FactorBandedMatrix(InterpolationMatrix,
@@ -3048,7 +3048,7 @@ void  BSplCLib::Interpolate(const Standard_Integer         Degree,
                            LowerBandWidth,
                            InversionProblem) ;
   if(ErrorCode)
-    Standard_OutOfRange::Raise("BSplCLib::Interpolate");
+    throw Standard_OutOfRange("BSplCLib::Interpolate");
 
   ErrorCode  =
   BSplCLib::SolveBandedSystem(InterpolationMatrix,
@@ -3057,7 +3057,7 @@ void  BSplCLib::Interpolate(const Standard_Integer         Degree,
                              ArrayDimension,
                               Poles) ;
   if(ErrorCode)
-    Standard_OutOfRange::Raise("BSplCLib::Interpolate");
+    throw Standard_OutOfRange("BSplCLib::Interpolate");
 }
 
 //=======================================================================
@@ -3089,7 +3089,7 @@ void  BSplCLib::Interpolate(const Standard_Integer         Degree,
                            UpperBandWidth,
                            LowerBandWidth) ;
   if(ErrorCode)
-    Standard_OutOfRange::Raise("BSplCLib::Interpolate");
+    throw Standard_OutOfRange("BSplCLib::Interpolate");
 
   ErrorCode =
   BSplCLib::FactorBandedMatrix(InterpolationMatrix,
@@ -3097,7 +3097,7 @@ void  BSplCLib::Interpolate(const Standard_Integer         Degree,
                            LowerBandWidth,
                            InversionProblem) ;
   if(ErrorCode)
-    Standard_OutOfRange::Raise("BSplCLib::Interpolate");
+    throw Standard_OutOfRange("BSplCLib::Interpolate");
 
   ErrorCode  =
   BSplCLib::SolveBandedSystem(InterpolationMatrix,
@@ -3108,7 +3108,7 @@ void  BSplCLib::Interpolate(const Standard_Integer         Degree,
                               Poles,
                              Weights) ;
   if(ErrorCode)
-    Standard_OutOfRange::Raise("BSplCLib::Interpolate");
+    throw Standard_OutOfRange("BSplCLib::Interpolate");
 }
 
 //=======================================================================
index 6d7cbad..c368ba7 100644 (file)
@@ -1075,7 +1075,7 @@ void BSplCLib::FunctionMultiply
   
   if (Poles.Length() != num_bspline_poles ||
       NewPoles.Length() != num_new_poles) {
-    Standard_ConstructionError::Raise();  
+    throw Standard_ConstructionError();
   }
   Standard_Real  * array_of_poles =
     (Standard_Real *) &Poles(Poles.Lower()) ;
@@ -1114,7 +1114,7 @@ void BSplCLib::FunctionReparameterise
   
   if (Poles.Length() != num_bspline_poles ||
       NewPoles.Length() != num_new_poles) {
-    Standard_ConstructionError::Raise();  
+    throw Standard_ConstructionError();
   }
   Standard_Real  * array_of_poles =
     (Standard_Real *) &Poles(Poles.Lower()) ;
index 58ad873..fe68f85 100644 (file)
@@ -1363,7 +1363,7 @@ void BSplCLib::MovePointAndTangent (const Standard_Real      U,
   num_poles = Poles.Length() ;
   
   if (NewPoles.Length() != num_poles) {
-    Standard_ConstructionError::Raise(); 
+    throw Standard_ConstructionError();
   }
   delta_array = (Standard_Real *)  &Delta ;
   delta_derivative_array = (Standard_Real *)&DeltaDerivatives ;
@@ -1433,7 +1433,7 @@ void BSplCLib::FunctionMultiply
   
   if (Poles.Length() != num_bspline_poles ||
       NewPoles.Length() != num_new_poles) {
-    Standard_ConstructionError::Raise();  
+    throw Standard_ConstructionError();
   }
   Standard_Real  * array_of_poles =
     (Standard_Real *) &Poles(Poles.Lower()) ;
@@ -1472,7 +1472,7 @@ void BSplCLib::FunctionReparameterise
   
   if (Poles.Length() != num_bspline_poles ||
       NewPoles.Length() != num_new_poles) {
-    Standard_ConstructionError::Raise();  
+    throw Standard_ConstructionError();
   }
   Standard_Real  * array_of_poles =
     (Standard_Real *) &Poles(Poles.Lower()) ;
index da58821..a741ee6 100644 (file)
@@ -3517,7 +3517,7 @@ void BSplSLib::FunctionMultiply
                 result,
                 error_code) ;
        if (error_code) {
-         Standard_ConstructionError::Raise();
+         throw Standard_ConstructionError();
        }
        gp_Pnt& P = NewNumerator(ii,jj);
        P.SetX(P.X() * result);
@@ -3537,6 +3537,6 @@ void BSplSLib::FunctionMultiply
                Status) ;
   }
   else {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 }
index 8fb6506..cc1c50b 100644 (file)
@@ -954,7 +954,7 @@ void BiTgte_Blend::Perform(const Standard_Boolean BuildShape)
   for ( ;expf.More(); expf.Next()) Sew->Add(expf.Current());
   Sew->Perform();
   TopoDS_Shape SewedShape = Sew->SewedShape();
-  if ( SewedShape.IsNull()) Standard_Failure::Raise("Sewing aux fraises");
+  if ( SewedShape.IsNull()) throw Standard_Failure("Sewing aux fraises");
 
   // Check if the sewing modified the orientation.
   expf.Init(myShape,TopAbs_FACE);
@@ -1173,7 +1173,7 @@ const
 const TopoDS_Face& BiTgte_Blend::Face(const TopoDS_Shape& CenterLine) const
 {
   if ( !myMapSF.IsBound(CenterLine)) {
-    Standard_DomainError::Raise("BiTgte_Blend::Face");
+    throw Standard_DomainError("BiTgte_Blend::Face");
   }
 
   return myMapSF(CenterLine).Face();
index a81bce5..e112884 100644 (file)
@@ -128,8 +128,7 @@ Standard_Real BiTgte_CurveOnEdge::LastParameter() const
 
 GeomAbs_Shape BiTgte_CurveOnEdge::Continuity() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  return GeomAbs_C0;
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -140,8 +139,7 @@ GeomAbs_Shape BiTgte_CurveOnEdge::Continuity() const
 
 Standard_Integer BiTgte_CurveOnEdge::NbIntervals(const GeomAbs_Shape) const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  return 0;
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -153,7 +151,7 @@ Standard_Integer BiTgte_CurveOnEdge::NbIntervals(const GeomAbs_Shape) const
 void BiTgte_CurveOnEdge::Intervals(TColStd_Array1OfReal&,
                                    const GeomAbs_Shape) const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -166,9 +164,7 @@ Handle(Adaptor3d_HCurve) BiTgte_CurveOnEdge::Trim(const Standard_Real,
                                                   const Standard_Real,
                                                   const Standard_Real) const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  Handle(BiTgte_HCurveOnEdge) HC;
-  return HC;
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -179,8 +175,7 @@ Handle(Adaptor3d_HCurve) BiTgte_CurveOnEdge::Trim(const Standard_Real,
 
 Standard_Boolean BiTgte_CurveOnEdge::IsClosed() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  return Standard_False;
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -191,8 +186,7 @@ Standard_Boolean BiTgte_CurveOnEdge::IsClosed() const
 
 Standard_Boolean BiTgte_CurveOnEdge::IsPeriodic() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  return Standard_False;
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -203,8 +197,7 @@ Standard_Boolean BiTgte_CurveOnEdge::IsPeriodic() const
 
 Standard_Real BiTgte_CurveOnEdge::Period() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  return 0.;
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -242,7 +235,7 @@ void BiTgte_CurveOnEdge::D0(const Standard_Real U,gp_Pnt& P) const
 
 void BiTgte_CurveOnEdge::D1(const Standard_Real,gp_Pnt& ,gp_Vec& ) const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -254,7 +247,7 @@ void BiTgte_CurveOnEdge::D1(const Standard_Real,gp_Pnt& ,gp_Vec& ) const
 void BiTgte_CurveOnEdge::D2(const Standard_Real ,gp_Pnt&,
                             gp_Vec& ,gp_Vec&) const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -266,7 +259,7 @@ void BiTgte_CurveOnEdge::D2(const Standard_Real ,gp_Pnt&,
 void BiTgte_CurveOnEdge::D3(const Standard_Real ,gp_Pnt&,
                             gp_Vec& ,gp_Vec& ,gp_Vec& ) const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -278,8 +271,7 @@ void BiTgte_CurveOnEdge::D3(const Standard_Real ,gp_Pnt&,
 gp_Vec BiTgte_CurveOnEdge::DN(const Standard_Real,
                               const Standard_Integer) const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  return gp_Vec();
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -290,8 +282,7 @@ gp_Vec BiTgte_CurveOnEdge::DN(const Standard_Real,
 
 Standard_Real BiTgte_CurveOnEdge::Resolution(const Standard_Real) const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  return 0.;
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -313,8 +304,7 @@ GeomAbs_CurveType BiTgte_CurveOnEdge::GetType() const
 
 gp_Lin BiTgte_CurveOnEdge::Line() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  return gp_Lin();
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -326,8 +316,7 @@ gp_Lin BiTgte_CurveOnEdge::Line() const
 gp_Circ BiTgte_CurveOnEdge::Circle() const
 {
   if ( myType != GeomAbs_Circle) {
-    Standard_NoSuchObject::Raise("BiTgte_CurveOnEdge::Circle");
-    return gp_Circ();
+    throw Standard_NoSuchObject("BiTgte_CurveOnEdge::Circle");
   }
 
   return myCirc;
@@ -341,8 +330,7 @@ gp_Circ BiTgte_CurveOnEdge::Circle() const
 
 gp_Elips BiTgte_CurveOnEdge::Ellipse() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  return gp_Elips();
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -353,8 +341,7 @@ gp_Elips BiTgte_CurveOnEdge::Ellipse() const
 
 gp_Hypr BiTgte_CurveOnEdge::Hyperbola() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  return gp_Hypr();
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -365,8 +352,7 @@ gp_Hypr BiTgte_CurveOnEdge::Hyperbola() const
 
 gp_Parab BiTgte_CurveOnEdge::Parabola() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  return gp_Parab();
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -377,8 +363,7 @@ gp_Parab BiTgte_CurveOnEdge::Parabola() const
 
 Standard_Integer BiTgte_CurveOnEdge::Degree() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  return 0;
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -389,8 +374,7 @@ Standard_Integer BiTgte_CurveOnEdge::Degree() const
 
 Standard_Boolean BiTgte_CurveOnEdge::IsRational() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  return Standard_False;
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -401,8 +385,7 @@ Standard_Boolean BiTgte_CurveOnEdge::IsRational() const
 
 Standard_Integer BiTgte_CurveOnEdge::NbPoles() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  return 0;
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -413,8 +396,7 @@ Standard_Integer BiTgte_CurveOnEdge::NbPoles() const
 
 Standard_Integer BiTgte_CurveOnEdge::NbKnots() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  return 0;
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -425,9 +407,7 @@ Standard_Integer BiTgte_CurveOnEdge::NbKnots() const
 
 Handle(Geom_BezierCurve) BiTgte_CurveOnEdge::Bezier() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  Handle(Geom_BezierCurve) B;
-  return B;
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
@@ -438,9 +418,7 @@ Handle(Geom_BezierCurve) BiTgte_CurveOnEdge::Bezier() const
 
 Handle(Geom_BSplineCurve) BiTgte_CurveOnEdge::BSpline() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnEdge");
-  Handle(Geom_BSplineCurve) B;
-  return B;
+  throw Standard_NotImplemented("BiTgte_CurveOnEdge");
 }
 
 
index 3276153..2bdf0a2 100644 (file)
@@ -100,8 +100,7 @@ Standard_Real BiTgte_CurveOnVertex::LastParameter() const
 
 GeomAbs_Shape BiTgte_CurveOnVertex::Continuity() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  return GeomAbs_C0;
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -112,8 +111,7 @@ GeomAbs_Shape BiTgte_CurveOnVertex::Continuity() const
 
 Standard_Integer BiTgte_CurveOnVertex::NbIntervals(const GeomAbs_Shape) const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  return 0;
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -125,7 +123,7 @@ Standard_Integer BiTgte_CurveOnVertex::NbIntervals(const GeomAbs_Shape) const
 void BiTgte_CurveOnVertex::Intervals(TColStd_Array1OfReal&,
                                      const GeomAbs_Shape) const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -139,9 +137,7 @@ Handle(Adaptor3d_HCurve) BiTgte_CurveOnVertex::Trim(const Standard_Real,
                                                     const Standard_Real) 
 const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  Handle(BiTgte_HCurveOnVertex) HC;
-  return HC;
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -152,8 +148,7 @@ const
 
 Standard_Boolean BiTgte_CurveOnVertex::IsClosed() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  return Standard_False;
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -164,8 +159,7 @@ Standard_Boolean BiTgte_CurveOnVertex::IsClosed() const
 
 Standard_Boolean BiTgte_CurveOnVertex::IsPeriodic() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  return Standard_False;
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -176,8 +170,7 @@ Standard_Boolean BiTgte_CurveOnVertex::IsPeriodic() const
 
 Standard_Real BiTgte_CurveOnVertex::Period() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  return 0.;
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -210,7 +203,7 @@ void BiTgte_CurveOnVertex::D0(const Standard_Real /*U*/,gp_Pnt& P) const
 
 void BiTgte_CurveOnVertex::D1(const Standard_Real ,gp_Pnt& ,gp_Vec&) const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -222,7 +215,7 @@ void BiTgte_CurveOnVertex::D1(const Standard_Real ,gp_Pnt& ,gp_Vec&) const
 void BiTgte_CurveOnVertex::D2(const Standard_Real,gp_Pnt&,
                               gp_Vec& ,gp_Vec& ) const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -237,7 +230,7 @@ void BiTgte_CurveOnVertex::D3(const Standard_Real,
                               gp_Vec& ,
                               gp_Vec& ) const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -249,8 +242,7 @@ void BiTgte_CurveOnVertex::D3(const Standard_Real,
 gp_Vec BiTgte_CurveOnVertex::DN(const Standard_Real,
                                 const Standard_Integer) const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  return gp_Vec();
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -261,8 +253,7 @@ gp_Vec BiTgte_CurveOnVertex::DN(const Standard_Real,
 
 Standard_Real BiTgte_CurveOnVertex::Resolution(const Standard_Real) const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  return 0.;
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -284,8 +275,7 @@ GeomAbs_CurveType BiTgte_CurveOnVertex::GetType() const
 
 gp_Lin BiTgte_CurveOnVertex::Line() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  return gp_Lin();
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -296,8 +286,7 @@ gp_Lin BiTgte_CurveOnVertex::Line() const
 
 gp_Circ BiTgte_CurveOnVertex::Circle() const
 {
-  Standard_NoSuchObject::Raise("BiTgte_CurveOnVertex::Circle");
-  return gp_Circ();
+  throw Standard_NoSuchObject("BiTgte_CurveOnVertex::Circle");
 }
 
 
@@ -308,8 +297,7 @@ gp_Circ BiTgte_CurveOnVertex::Circle() const
 
 gp_Elips BiTgte_CurveOnVertex::Ellipse() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  return gp_Elips();
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -320,8 +308,7 @@ gp_Elips BiTgte_CurveOnVertex::Ellipse() const
 
 gp_Hypr BiTgte_CurveOnVertex::Hyperbola() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  return gp_Hypr();
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -332,8 +319,7 @@ gp_Hypr BiTgte_CurveOnVertex::Hyperbola() const
 
 gp_Parab BiTgte_CurveOnVertex::Parabola() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  return gp_Parab();
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -344,8 +330,7 @@ gp_Parab BiTgte_CurveOnVertex::Parabola() const
 
 Standard_Integer BiTgte_CurveOnVertex::Degree() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  return 0;
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -356,8 +341,7 @@ Standard_Integer BiTgte_CurveOnVertex::Degree() const
 
 Standard_Boolean BiTgte_CurveOnVertex::IsRational() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  return Standard_False;
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -368,8 +352,7 @@ Standard_Boolean BiTgte_CurveOnVertex::IsRational() const
 
 Standard_Integer BiTgte_CurveOnVertex::NbPoles() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  return 0;
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -380,8 +363,7 @@ Standard_Integer BiTgte_CurveOnVertex::NbPoles() const
 
 Standard_Integer BiTgte_CurveOnVertex::NbKnots() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  return 0;
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -392,9 +374,7 @@ Standard_Integer BiTgte_CurveOnVertex::NbKnots() const
 
 Handle(Geom_BezierCurve) BiTgte_CurveOnVertex::Bezier() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  Handle(Geom_BezierCurve) B;
-  return B;
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
@@ -405,9 +385,7 @@ Handle(Geom_BezierCurve) BiTgte_CurveOnVertex::Bezier() const
 
 Handle(Geom_BSplineCurve) BiTgte_CurveOnVertex::BSpline() const
 {
-  Standard_NotImplemented::Raise("BiTgte_CurveOnVertex");
-  Handle(Geom_BSplineCurve) B;
-  return B;
+  throw Standard_NotImplemented("BiTgte_CurveOnVertex");
 }
 
 
index 5f54223..e9e2dd7 100644 (file)
@@ -62,9 +62,7 @@ const Handle(Standard_Transient)& BinDrivers::Factory(const Standard_GUID& theGU
     return model_rd;
   }
 
-  Standard_Failure::Raise ("BinDrivers : unknown GUID");
-  static Handle(Standard_Transient) aNullHandle;
-  return aNullHandle;
+  throw Standard_Failure("BinDrivers : unknown GUID");
 }
 
 //=======================================================================
index 69d0a44..1923746 100644 (file)
@@ -71,12 +71,11 @@ void BinDrivers_DocumentRetrievalDriver::ReadShapeSection
         Handle(BinMNaming_NamedShapeDriver)::DownCast (aDriver);
       aNamedShapeDriver->ReadShapeSection (theIS);
     }
-    catch(Standard_Failure) {
-      Handle(Standard_Failure) aFailure = Standard_Failure::Caught();
+    catch(Standard_Failure const& anException) {
       const TCollection_ExtendedString aMethStr
         ("BinDrivers_DocumentRetrievalDriver: ");
       WriteMessage (aMethStr + "error of Shape Section " +
-        aFailure->GetMessageString());
+        anException.GetMessageString());
     }
   }
 }
index f1179c1..6416c8d 100644 (file)
@@ -87,7 +87,7 @@ void BinDrivers_DocumentStorageDriver::SetWithTriangles (const Handle(CDM_Messag
   Handle(BinMNaming_NamedShapeDriver) aShapesDriver = Handle(BinMNaming_NamedShapeDriver)::DownCast(aDriver);
   if (aShapesDriver.IsNull())
   {
-    Standard_NotImplemented::Raise("Internal Error - TNaming_NamedShape is not found!");
+    throw Standard_NotImplemented("Internal Error - TNaming_NamedShape is not found!");
   }
 
   aShapesDriver->SetWithTriangles (theWithTriangulation);
@@ -112,12 +112,11 @@ void BinDrivers_DocumentStorageDriver::WriteShapeSection
         Handle(BinMNaming_NamedShapeDriver)::DownCast (aDriver);
       aNamedShapeDriver->WriteShapeSection (theOS);
     }
-    catch(Standard_Failure) {
+    catch(Standard_Failure const& anException) {
       TCollection_ExtendedString anErrorStr ("Error: ");
-      Handle(Standard_Failure) aFailure = Standard_Failure::Caught();
       TCollection_ExtendedString aStr = 
        anErrorStr + "BinDrivers_DocumentStorageDriver, Shape Section :";
-      WriteMessage (aStr  + aFailure->GetMessageString());
+      WriteMessage (aStr  + anException.GetMessageString());
     }
   }
    
index d3d2fd0..7c689c8 100644 (file)
@@ -61,9 +61,7 @@ const Handle(Standard_Transient)& BinLDrivers::Factory(const Standard_GUID& theG
     return model_rd;
   }
 
-  Standard_Failure::Raise ("BinLDrivers : unknown GUID");
-  static Handle(Standard_Transient) aNullHandle;
-  return aNullHandle;
+  throw Standard_Failure("BinLDrivers : unknown GUID");
 }
 
 //=======================================================================
index 3c165aa..d06a7dd 100644 (file)
@@ -62,8 +62,7 @@ void BinMDF_ADriverTable::AssignIds
       myMapId.Bind (aType, i);
     }
     else {
-      Standard_NoSuchObject::Raise
-        ((TCollection_AsciiString("BinMDF_ADriverTable::AssignIds : ") +
+      throw Standard_NoSuchObject((TCollection_AsciiString("BinMDF_ADriverTable::AssignIds : ") +
           "the type " + aType->Name() + " has not been registered").ToCString());
     }
   }
index 1fbe784..b66fd4a 100644 (file)
@@ -46,9 +46,8 @@ static Standard_Character EvolutionToChar(const TNaming_Evolution theEvol)
     case TNaming_SELECTED     : return 'S';
     case TNaming_REPLACE      : return 'M'; // for compatibility case TNaming_REPLACE      : return 'R';
   default:
-    Standard_DomainError::Raise("TNaming_Evolution:: Evolution Unknown");
+    throw Standard_DomainError("TNaming_Evolution:: Evolution Unknown");
   }
-  return 'P'; // To avoid compilation error message.
 }
 
 //=======================================================================
@@ -62,9 +61,8 @@ static TNaming_Evolution EvolutionToEnum(const Standard_Character theEvol)
     case 'S': return TNaming_SELECTED;
     case 'R': return TNaming_MODIFY; //for compatibility //TNaming_REPLACE;
   default:
-    Standard_DomainError::Raise("TNaming_Evolution:: Evolution Unknown");
+    throw Standard_DomainError("TNaming_Evolution:: Evolution Unknown");
   }
-  return TNaming_PRIMITIVE; // To avoid compilation error message.
 }
 //=======================================================================
 static Standard_Character OrientationToChar(const TopAbs_Orientation theOrient)
@@ -75,9 +73,8 @@ static Standard_Character OrientationToChar(const TopAbs_Orientation theOrient)
     case TopAbs_INTERNAL   : return 'I';
     case TopAbs_EXTERNAL   : return 'E';
   default:
-    Standard_DomainError::Raise("TopAbs_Orientation:: Orientation Unknown");
+    throw Standard_DomainError("TopAbs_Orientation:: Orientation Unknown");
   }
-  return 'F'; // To avoid compilation error message.
 }
 //=======================================================================
 static TopAbs_Orientation CharToOrientation(const Standard_Character  theCharOrient)
@@ -88,9 +85,8 @@ static TopAbs_Orientation CharToOrientation(const Standard_Character  theCharOri
     case 'I':  return TopAbs_INTERNAL;
     case 'E':  return TopAbs_EXTERNAL;
   default:
-    Standard_DomainError::Raise("TopAbs_Orientation:: Orientation Unknown");
+    throw Standard_DomainError("TopAbs_Orientation:: Orientation Unknown");
   }
-  return TopAbs_FORWARD; // To avoid compilation error message.
 }
 
 //=======================================================================
@@ -217,7 +213,7 @@ Standard_Boolean BinMNaming_NamedShapeDriver::Paste
       aBuilder.Modify(anOldShape, aNewShape); // for compatibility aBuilder.Replace(anOldShape, aNewShape);
       break;
       default :
-        Standard_DomainError::Raise("TNaming_Evolution:: Evolution Unknown");
+        throw Standard_DomainError("TNaming_Evolution:: Evolution Unknown");
     }
     anOldShape.Nullify();
     aNewShape.Nullify();
index da51b2d..8c93b43 100644 (file)
@@ -58,9 +58,8 @@ static Standard_Character NameTypeToChar(const TNaming_NameType theNameType)
     case TNaming_WIREIN       : return 'W';
     case TNaming_SHELLIN      : return 'H';
   default:
-    Standard_DomainError::Raise("TNaming_NameType:: Name Type Unknown");
+    throw Standard_DomainError("TNaming_NameType:: Name Type Unknown");
   }
-  return 'N'; // To avoid compilation error message.
 }
 
 //=======================================================================
@@ -80,9 +79,8 @@ static TNaming_NameType CharTypeToName(const Standard_Character theCharType)
     case 'W'  : return TNaming_WIREIN;
     case 'H'  : return TNaming_SHELLIN;
   default:
-    Standard_DomainError::Raise("TNaming_NameType:: Name Type Unknown");
+    throw Standard_DomainError("TNaming_NameType:: Name Type Unknown");
   }
-  return TNaming_UNKNOWN; // To avoid compilation error message.
 }
 
 //=======================================================================
index e44cf8f..11d4d46 100644 (file)
@@ -84,7 +84,7 @@ Standard_OStream& BinTools::PutExtChar(Standard_OStream& OS, const Standard_ExtC
 Standard_IStream& BinTools::GetReal(Standard_IStream& IS, Standard_Real& aValue)
 {
   if(!IS.read ((char*)&aValue, sizeof(Standard_Real)))
-    Storage_StreamTypeMismatchError::Raise();
+    throw Storage_StreamTypeMismatchError();
 #if DO_INVERSE
   aValue = InverseReal (aValue);
 #endif
@@ -99,7 +99,7 @@ Standard_IStream& BinTools::GetReal(Standard_IStream& IS, Standard_Real& aValue)
 Standard_IStream& BinTools::GetInteger(Standard_IStream& IS, Standard_Integer& aValue)
 {
   if(!IS.read ((char*)&aValue, sizeof(Standard_Integer)))
-    Storage_StreamTypeMismatchError::Raise();;
+    throw Storage_StreamTypeMismatchError();;
 #if DO_INVERSE
   aValue = InverseInt (aValue);
 #endif
@@ -114,7 +114,7 @@ Standard_IStream& BinTools::GetInteger(Standard_IStream& IS, Standard_Integer& a
 Standard_IStream& BinTools::GetExtChar(Standard_IStream& IS, Standard_ExtCharacter& theValue)
 {
   if(!IS.read ((char*)&theValue, sizeof(Standard_ExtCharacter)))
-    Storage_StreamTypeMismatchError::Raise();;
+    throw Storage_StreamTypeMismatchError();;
 #if DO_INVERSE
   theValue = InverseExtChar (theValue);
 #endif
index 440abda..0f34bf7 100644 (file)
@@ -329,15 +329,14 @@ void BinTools_Curve2dSet::WriteCurve2d(const Handle(Geom2d_Curve)& C,
       OS << Handle(Geom2d_OffsetCurve)::DownCast(C);
     }
     else {
-      Standard_Failure::Raise("UNKNOWN CURVE2d TYPE");
+      throw Standard_Failure("UNKNOWN CURVE2d TYPE");
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     Standard_SStream aMsg;
     aMsg << "EXCEPTION in BinTools_Curve2dSet::WriteCurve2d(..)" << endl;
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
-    aMsg << anExc << endl;
-    Standard_Failure::Raise(aMsg);
+    aMsg << anException << endl;
+    throw Standard_Failure(aMsg.str().c_str());
   }  
 }
 
@@ -673,18 +672,17 @@ Standard_IStream& BinTools_Curve2dSet::ReadCurve2d(Standard_IStream& IS,
     default:
       {
        C = NULL;
-        Standard_Failure::Raise("UNKNOWN CURVE2d TYPE");
+        throw Standard_Failure("UNKNOWN CURVE2d TYPE");
       }
       break;
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     C = NULL;
     Standard_SStream aMsg;
     aMsg <<"EXCEPTION in BinTools_Curve2dSet::ReadCurve2d(...)" << endl;
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
-    aMsg << anExc << endl;
-    Standard_Failure::Raise(aMsg);
+    aMsg << anException << endl;
+    throw Standard_Failure(aMsg.str().c_str());
   }
   return IS;
 }
@@ -705,7 +703,7 @@ void  BinTools_Curve2dSet::Read(Standard_IStream& IS)
 #ifdef OCCT_DEBUG
     cout <<"Curve2dSet buffer: " << buffer << endl;
 #endif
-    Standard_Failure::Raise(aMsg);
+    throw Standard_Failure(aMsg.str().c_str());
     return;
   }
 
index f0bb5f9..7f89e62 100644 (file)
@@ -342,15 +342,14 @@ void BinTools_CurveSet::WriteCurve(const Handle(Geom_Curve)& C,
       OS << Handle(Geom_OffsetCurve)::DownCast(C);
     }
     else {
-      Standard_Failure::Raise("UNKNOWN CURVE TYPE");
+      throw Standard_Failure("UNKNOWN CURVE TYPE");
     }
   }
-   catch(Standard_Failure) {
+   catch(Standard_Failure const& anException) {
      Standard_SStream aMsg;
      aMsg << "EXCEPTION in BinTools_CurveSet::WriteCurve(..)" << endl;
-     Handle(Standard_Failure) anExc = Standard_Failure::Caught();
-     aMsg << anExc << endl;
-     Standard_Failure::Raise(aMsg);
+     aMsg << anException << endl;
+     throw Standard_Failure(aMsg.str().c_str());
    }  
 }
 
@@ -693,16 +692,16 @@ Standard_IStream& BinTools_CurveSet::ReadCurve(Standard_IStream& IS,
     default:
       {
        C = NULL;
-       Standard_Failure::Raise("UNKNOWN CURVE TYPE");
+       throw Standard_Failure("UNKNOWN CURVE TYPE");
       }
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     C = NULL;
     Standard_SStream aMsg;
     aMsg <<"EXCEPTION in BinTools_CurveSet::ReadCurve(..)" << endl;
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
-    Standard_Failure::Raise(aMsg);
+    aMsg << anException << endl;
+    throw Standard_Failure(aMsg.str().c_str());
   }
   return IS;
 }
@@ -722,7 +721,7 @@ void  BinTools_CurveSet::Read(Standard_IStream& IS)
 #ifdef OCCT_DEBUG
     cout <<"CurveSet buffer: " << buffer << endl;
 #endif
-    Standard_Failure::Raise(aMsg);
+    throw Standard_Failure(aMsg.str().c_str());
     return;
   }
 
index 326357c..9f4d36e 100644 (file)
@@ -196,12 +196,11 @@ void  BinTools_LocationSet::Write(Standard_OStream& OS) const
       }
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     Standard_SStream aMsg;
     aMsg << "EXCEPTION in BinTools_LocatioSet::Write(..)" << endl;
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
-    aMsg << anExc << endl;
-    Standard_Failure::Raise(aMsg);
+    aMsg << anException << endl;
+    throw Standard_Failure(aMsg.str().c_str());
   }
 }
 
@@ -220,7 +219,7 @@ void  BinTools_LocationSet::Read(Standard_IStream& IS)
   if (IS.fail() || (strcmp(buffer,"Locations"))) {
     Standard_SStream aMsg;
     aMsg << "BinTools_LocationSet::Read: Not a location table"<<endl;
-    Standard_Failure::Raise(aMsg);
+    throw Standard_Failure(aMsg.str().c_str());
     return;
   }
 
@@ -252,16 +251,15 @@ void  BinTools_LocationSet::Read(Standard_IStream& IS)
       } else {
        Standard_SStream aMsg;
        aMsg << "Unexpected location's type = " << aTypLoc << endl;
-       Standard_Failure::Raise(aMsg);
+       throw Standard_Failure(aMsg.str().c_str());
       }    
       if (!L.IsIdentity()) myMap.Add(L);
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     Standard_SStream aMsg;
     aMsg << "EXCEPTION in BinTools_LocationSet::Read(..)" << endl;
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
-    aMsg << anExc << endl;
-    Standard_Failure::Raise(aMsg);
+    aMsg << anException << endl;
+    throw Standard_Failure(aMsg.str().c_str());
   }
 }
index 3f0d45b..8ff8b01 100644 (file)
@@ -425,7 +425,7 @@ void  BinTools_ShapeSet::Read(Standard_IStream& IS)
   if (IS.fail() || strcmp(buffer,"TShapes")) {
     Standard_SStream aMsg;
     aMsg << "BinTools_ShapeSet::Read: Not a TShape table"<<endl;
-    Standard_Failure::Raise(aMsg);    
+    throw Standard_Failure(aMsg.str().c_str());
     return;
   }
 
@@ -746,12 +746,11 @@ void  BinTools_ShapeSet::WriteGeometry(const TopoDS_Shape& S,
        OS << (Standard_Byte) 0;//without triangulation
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     Standard_SStream aMsg;
     aMsg << "EXCEPTION in BinTools_ShapeSet::WriteGeometry(S,OS)" << endl;
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
-    aMsg << anExc << endl;
-    Standard_Failure::Raise(aMsg);
+    aMsg << anException << endl;
+    throw Standard_Failure(aMsg.str().c_str());
   }
 }
 
@@ -872,7 +871,7 @@ void  BinTools_ShapeSet::ReadGeometry(const TopAbs_ShapeEnum T,
            {
               Standard_SStream aMsg;
              aMsg << "BinTools_SurfaceSet::ReadGeometry: UnExpected BRep_PointRepresentation = "<< val <<endl;
-             Standard_Failure::Raise(aMsg);
+             throw Standard_Failure(aMsg.str().c_str());
              }
          }
          
@@ -1067,7 +1066,7 @@ void  BinTools_ShapeSet::ReadGeometry(const TopAbs_ShapeEnum T,
            {
               Standard_SStream aMsg;
              aMsg <<"Unexpected Curve Representation ="<< val << endl;
-             Standard_Failure::Raise(aMsg);
+             throw Standard_Failure(aMsg.str().c_str());
            }
             
           }
@@ -1154,17 +1153,16 @@ void  BinTools_ShapeSet::ReadGeometry(const TopAbs_ShapeEnum T,
       {
         Standard_SStream aMsg;
         aMsg << "Unexpected topology type = "<< T <<endl;
-        Standard_Failure::Raise(aMsg);
+        throw Standard_Failure(aMsg.str().c_str());
         break;
       }
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     Standard_SStream aMsg;
     aMsg << "EXCEPTION in BinTools_ShapeSet::ReadGeometry(S,OS)" << endl;
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
-    aMsg << anExc << endl;
-    Standard_Failure::Raise(aMsg);
+    aMsg << anException << endl;
+    throw Standard_Failure(aMsg.str().c_str());
   }
 }
 
@@ -1217,12 +1215,11 @@ void BinTools_ShapeSet::WritePolygonOnTriangulation(Standard_OStream& OS) const
        BinTools::PutBool(OS, Standard_False);
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     Standard_SStream aMsg;
     aMsg << "EXCEPTION in BinTools_ShapeSet::WritePolygonOnTriangulation(..)" << endl;
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
-    aMsg << anExc << endl;
-    Standard_Failure::Raise(aMsg);
+    aMsg << anException << endl;
+    throw Standard_Failure(aMsg.str().c_str());
   }
 }
 
@@ -1236,7 +1233,7 @@ void BinTools_ShapeSet::ReadPolygonOnTriangulation(Standard_IStream& IS)
   char buffer[255];
   IS >> buffer;
   if (IS.fail() || (strstr(buffer,"PolygonOnTriangulations") == NULL)) {
-    Standard_Failure::Raise("BinTools_ShapeSet::ReadPolygonOnTriangulation: Not a PolygonOnTriangulation section");
+    throw Standard_Failure("BinTools_ShapeSet::ReadPolygonOnTriangulation: Not a PolygonOnTriangulation section");
   }
   Standard_Integer i, j, val, nbpol = 0, nbnodes =0;
   Standard_Boolean hasparameters;
@@ -1271,12 +1268,11 @@ void BinTools_ShapeSet::ReadPolygonOnTriangulation(Standard_IStream& IS)
       myNodes.Add(Poly);
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     Standard_SStream aMsg;
     aMsg << "EXCEPTION in BinTools_ShapeSet::ReadPolygonOnTriangulation(..)" << endl;
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
-    aMsg << anExc << endl;
-    Standard_Failure::Raise(aMsg);
+    aMsg << anException << endl;
+    throw Standard_Failure(aMsg.str().c_str());
   }
 }
 
@@ -1318,12 +1314,11 @@ void BinTools_ShapeSet::WritePolygon3D(Standard_OStream& OS)const
       }
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     Standard_SStream aMsg;
     aMsg << "EXCEPTION in BinTools_ShapeSet::WritePolygon3D(..)" << endl;
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
-    aMsg << anExc << endl;
-    Standard_Failure::Raise(aMsg);
+    aMsg << anException << endl;
+    throw Standard_Failure(aMsg.str().c_str());
   }
 }
 //=======================================================================
@@ -1343,7 +1338,7 @@ void BinTools_ShapeSet::ReadPolygon3D(Standard_IStream& IS)
 #ifdef OCCT_DEBUG
     cout <<"Buffer: " << buffer << endl;
 #endif
-    Standard_Failure::Raise("BinTools_ShapeSet::ReadPolygon3D: Not a Polygon3D section");
+    throw Standard_Failure("BinTools_ShapeSet::ReadPolygon3D: Not a Polygon3D section");
   }
   Handle(Poly_Polygon3D) P;
   IS >> nbpol;
@@ -1374,12 +1369,11 @@ void BinTools_ShapeSet::ReadPolygon3D(Standard_IStream& IS)
       myPolygons3D.Add(P);
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     Standard_SStream aMsg;
     aMsg << "EXCEPTION in BinTools_ShapeSet::ReadPolygon3D(..)" << endl;
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
-    aMsg << anExc << endl;
-    Standard_Failure::Raise(aMsg);
+    aMsg << anException << endl;
+    throw Standard_Failure(aMsg.str().c_str());
   }
 }
 
@@ -1431,12 +1425,11 @@ void BinTools_ShapeSet::WriteTriangulation(Standard_OStream& OS) const
       }
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     Standard_SStream aMsg;
     aMsg << "EXCEPTION in BinTools_ShapeSet::WriteTriangulation(..)" << endl;
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
-    aMsg << anExc << endl;
-    Standard_Failure::Raise(aMsg);
+    aMsg << anException << endl;
+    throw Standard_Failure(aMsg.str().c_str());
   }
 }
 
@@ -1457,7 +1450,7 @@ void BinTools_ShapeSet::ReadTriangulation(Standard_IStream& IS)
   IS >> buffer;
 
   if (IS.fail() || (strstr(buffer,"Triangulations") == NULL)) {
-    Standard_Failure::Raise("BinTools_ShapeSet::Triangulation: Not a Triangulation section");
+    throw Standard_Failure("BinTools_ShapeSet::Triangulation: Not a Triangulation section");
   }
   IS >> nbtri;
   IS.get();// remove LF 
@@ -1502,12 +1495,11 @@ void BinTools_ShapeSet::ReadTriangulation(Standard_IStream& IS)
       myTriangulations.Add(T);
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     Standard_SStream aMsg;
     aMsg << "EXCEPTION in BinTools_ShapeSet::ReadTriangulation(..)" << endl;
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
-    aMsg << anExc << endl;
-    Standard_Failure::Raise(aMsg);
+    aMsg << anException << endl;
+    throw Standard_Failure(aMsg.str().c_str());
   }
 }
 
index 6dd2fa2..c43fe79 100644 (file)
@@ -420,15 +420,14 @@ void BinTools_SurfaceSet::WriteSurface(const Handle(Geom_Surface)& S,
       OS << Handle(Geom_OffsetSurface)::DownCast(S);
     }
     else {
-      Standard_Failure::Raise("UNKNOWN SURFACE TYPE");
+      throw Standard_Failure("UNKNOWN SURFACE TYPE");
     }
   }
-   catch(Standard_Failure) {
+   catch(Standard_Failure const& anException) {
      Standard_SStream aMsg;
     aMsg << "EXCEPTION in BinTools_SurfaceSet::WriteSurface(..)" << endl;
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
-    aMsg << anExc << endl;
-    Standard_Failure::Raise(aMsg);
+    aMsg << anException << endl;
+    throw Standard_Failure(aMsg.str().c_str());
   }  
 }
 
@@ -854,18 +853,17 @@ Standard_IStream& BinTools_SurfaceSet::ReadSurface(Standard_IStream& IS,
     default :
       {
        S = NULL;
-       Standard_Failure::Raise("UNKNOWN SURFACE TYPE");        
+       throw Standard_Failure("UNKNOWN SURFACE TYPE");
       }
       break;
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     S = NULL;
     Standard_SStream aMsg;
     aMsg << "EXCEPTION in BinTools_SurfaceSet::ReadSurface(..)" << endl;
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
-    aMsg << anExc << endl;
-    Standard_Failure::Raise(aMsg);
+    aMsg << anException << endl;
+    throw Standard_Failure(aMsg.str().c_str());
   }
   return IS;
 }
@@ -885,7 +883,7 @@ void  BinTools_SurfaceSet::Read(Standard_IStream& IS)
 #ifdef OCCT_DEBUG
     cout <<"SurfaceSet buffer: " << buffer << endl;
 #endif
-    Standard_Failure::Raise(aMsg);
+    throw Standard_Failure(aMsg.str().c_str());
     return;
   }
 
index cf14f7c..7db8886 100644 (file)
@@ -56,9 +56,7 @@ const Handle(Standard_Transient)& BinXCAFDrivers::Factory(const Standard_GUID& t
   }
 
 
-  Standard_Failure::Raise ("XCAFBinDrivers : unknown GUID");
-  static Handle(Standard_Transient) aNullHandle;
-  return aNullHandle;
+  throw Standard_Failure("XCAFBinDrivers : unknown GUID");
 }
 
 //=======================================================================
index ca2aaee..baeda5f 100644 (file)
@@ -789,7 +789,7 @@ void Bisector_BisecAna::Perform(const Handle(Geom2d_Curve)& afirstcurve   ,
     break;
 
     default :
-      StdFail_NotDone::Raise();
+      throw StdFail_NotDone();
     break;
   }
 }
@@ -1222,7 +1222,7 @@ void Bisector_BisecAna::SetTrim(const Handle(Geom2d_Curve)& )
     }
   }
   else {
-    Standard_NotImplemented::Raise();
+    throw Standard_NotImplemented();
   }
     
   // Determination domaine d intersection de la Bissectrice.
@@ -1542,7 +1542,7 @@ Standard_Integer Bisector_BisecAna::NbIntervals() const
 //=============================================================================
 Standard_Real Bisector_BisecAna::IntervalFirst(const Standard_Integer I) const
 {
-  if (I != 1) Standard_OutOfRange::Raise();
+  if (I != 1) throw Standard_OutOfRange();
   return FirstParameter();
 }
 
@@ -1552,7 +1552,7 @@ Standard_Real Bisector_BisecAna::IntervalFirst(const Standard_Integer I) const
 //=============================================================================
 Standard_Real Bisector_BisecAna::IntervalLast(const Standard_Integer I) const
 {  
-  if (I != 1) Standard_OutOfRange::Raise();
+  if (I != 1) throw Standard_OutOfRange();
   return LastParameter();
 }
 
index 71b380b..3689f9e 100644 (file)
@@ -335,7 +335,7 @@ Standard_Boolean Bisector_BisecCC::IsEmpty() const
 //=============================================================================
 void Bisector_BisecCC::Reverse()
 {
-  Standard_NotImplemented::Raise();  
+  throw Standard_NotImplemented();
 }
 
 //=============================================================================
@@ -1000,10 +1000,9 @@ gp_Vec2d Bisector_BisecCC::DN(const Standard_Real    U,
   case 2 : return V2;
   case 3 : return V3;
   default: {
-    Standard_NotImplemented::Raise();
+    throw Standard_NotImplemented();
            }
   }
-  return V1;
 }
 
 //=============================================================================
@@ -1394,8 +1393,7 @@ Handle(Geom2d_Curve) Bisector_BisecCC::Curve(const Standard_Integer I) const
 {
   if      (I == 1) return curve1;
   else if (I == 2) return curve2;
-  else             Standard_OutOfRange::Raise();  
-  return curve1;
+  else             throw Standard_OutOfRange();
 }
 
 //=============================================================================
@@ -1491,7 +1489,7 @@ void Bisector_BisecCC::Curve(const Standard_Integer      I,
 {
   if      (I == 1) curve1 = C;
   else if (I == 2) curve2 = C;
-  else             Standard_OutOfRange::Raise();  
+  else             throw Standard_OutOfRange();
 }
 
 //=============================================================================
@@ -1503,7 +1501,7 @@ void Bisector_BisecCC::Sign(const Standard_Integer      I,
 {
   if      (I == 1) sign1 = S;
   else if (I == 2) sign2 = S;
-  else             Standard_OutOfRange::Raise();  
+  else             throw Standard_OutOfRange();
 }
 
 //=============================================================================
@@ -1533,7 +1531,7 @@ void Bisector_BisecCC::IsConvex(const Standard_Integer     I,
 {
   if      (I == 1) isConvex1 = IsConvex;
   else if (I == 2) isConvex2 = IsConvex;
-  else             Standard_OutOfRange::Raise();  
+  else             throw Standard_OutOfRange();
 }
 
 //=============================================================================
index 8abf8d9..ad03ff2 100644 (file)
@@ -163,7 +163,7 @@ Standard_Boolean Bisector_BisecPC::IsExtendAtEnd() const
 //=============================================================================
 void Bisector_BisecPC::Reverse()
 {
-  Standard_NotImplemented::Raise();
+  throw Standard_NotImplemented();
 }
 
 //=============================================================================
@@ -600,10 +600,9 @@ gp_Vec2d Bisector_BisecPC::DN (const Standard_Real     U,
   case 2 : return V2;
   case 3 : return V3;
   default: {
-    Standard_NotImplemented::Raise();
+    throw Standard_NotImplemented();
     }
   }
-  return V1;
 }
 
 //=============================================================================
@@ -640,7 +639,7 @@ Standard_Real Bisector_BisecPC::SearchBound (const Standard_Real U1,
 //=============================================================================
 void Bisector_BisecPC::CuspFilter()
 {
-  Standard_NotImplemented::Raise();
+  throw Standard_NotImplemented();
 }
 
 //=============================================================================
index a107a82..f434ef4 100644 (file)
@@ -54,6 +54,5 @@ Standard_Boolean Blend_CSFunction::Section (const Blend_Point& /*P*/,
 
 Standard_Real Blend_CSFunction::GetMinimalDistance() const
 {
-  Standard_NotImplemented::Raise("Blend_CSFunction::GetMinimalDistance");
-  return RealLast();
+  throw Standard_NotImplemented("Blend_CSFunction::GetMinimalDistance");
 }
index 54e71a6..62c35cc 100644 (file)
@@ -21,6 +21,6 @@ inline Standard_Boolean Blend_CSWalking::IsDone () const
 
 inline const Handle(TheLine)& Blend_CSWalking::Line () const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return line;
 }
index 3204fd2..e86ee57 100644 (file)
@@ -136,7 +136,7 @@ Standard_Boolean Blend_CSWalking::Complete(Blend_CSFunction& Func,
 //                                        Blend_CSFuncInv& FuncInv,
                                           const Standard_Real Pmin)
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   if (iscomplete) {return Standard_True;}
 
 /*
index fa1a431..c86e158 100644 (file)
@@ -38,7 +38,7 @@ inline Standard_Real Blend_Point::Parameter () const
 inline void Blend_Point::ParametersOnS1 (Standard_Real& U1,
                                         Standard_Real& V1) const
 {
-  if (!hass1) {Standard_DomainError::Raise();}
+  if (!hass1) {throw Standard_DomainError();}
   U1 = u1;
   V1 = v1;
 }
@@ -46,7 +46,7 @@ inline void Blend_Point::ParametersOnS1 (Standard_Real& U1,
 inline void Blend_Point::ParametersOnS2 (Standard_Real& U2,
                                         Standard_Real& V2) const
 {
-  if (!hass2) {Standard_DomainError::Raise();}
+  if (!hass2) {throw Standard_DomainError();}
   U2 = u2;
   V2 = v2;
 }
@@ -59,25 +59,25 @@ inline Standard_Boolean Blend_Point::IsTangencyPoint () const
 
 inline const gp_Vec& Blend_Point::TangentOnS1 () const
 {
-  if (istgt) {Standard_DomainError::Raise();}
+  if (istgt) {throw Standard_DomainError();}
   return tg1;
 }
 
 inline const gp_Vec& Blend_Point::TangentOnS2 () const
 {
-  if (istgt) {Standard_DomainError::Raise();}
+  if (istgt) {throw Standard_DomainError();}
   return tg2;
 }
 
 inline gp_Vec2d Blend_Point::Tangent2dOnS1 () const
 {
-  if (istgt || !hass1) {Standard_DomainError::Raise();}
+  if (istgt || !hass1) {throw Standard_DomainError();}
   return gp_Vec2d(utg12d,vtg12d);
 }
 
 inline gp_Vec2d Blend_Point::Tangent2dOnS2 () const
 {
-  if (istgt || !hass2) {Standard_DomainError::Raise();}
+  if (istgt || !hass2) {throw Standard_DomainError();}
   return gp_Vec2d(utg22d,vtg22d);
 }
 
@@ -94,32 +94,32 @@ inline const gp_Pnt& Blend_Point::PointOnC () const
 inline void Blend_Point::ParametersOnS (Standard_Real& U1,
                                        Standard_Real& V1) const
 {
-  if (!hass1) {Standard_DomainError::Raise();}
+  if (!hass1) {throw Standard_DomainError();}
   U1 = u1;
   V1 = v1;
 }
 
 inline Standard_Real Blend_Point::ParameterOnC () const
 {
-  if (!hasc2) {Standard_DomainError::Raise();}
+  if (!hasc2) {throw Standard_DomainError();}
   return pc2;
 }
 
 inline const gp_Vec& Blend_Point::TangentOnS () const
 {
-  if (istgt || !hass1) {Standard_DomainError::Raise();}
+  if (istgt || !hass1) {throw Standard_DomainError();}
   return tg1;
 }
 
 inline const gp_Vec& Blend_Point::TangentOnC () const
 {
-  if (istgt) {Standard_DomainError::Raise();}
+  if (istgt) {throw Standard_DomainError();}
   return tg2;
 }
 
 inline gp_Vec2d Blend_Point::Tangent2d () const
 {
-  if (istgt || !hass1) {Standard_DomainError::Raise();}
+  if (istgt || !hass1) {throw Standard_DomainError();}
   return gp_Vec2d(utg12d,vtg12d);
 }
 
@@ -136,24 +136,24 @@ inline const gp_Pnt& Blend_Point::PointOnC2 () const
 
 inline Standard_Real Blend_Point::ParameterOnC1 () const
 {
-  if (!hasc1) {Standard_DomainError::Raise();}
+  if (!hasc1) {throw Standard_DomainError();}
   return pc1;
 }
 
 inline Standard_Real Blend_Point::ParameterOnC2 () const
 {
-  if (!hasc2) {Standard_DomainError::Raise();}
+  if (!hasc2) {throw Standard_DomainError();}
   return pc2;
 }
 
 inline const gp_Vec& Blend_Point::TangentOnC1 () const
 {
-  if (istgt || !hass1) {Standard_DomainError::Raise();}
+  if (istgt || !hass1) {throw Standard_DomainError();}
   return tg1;
 }
 
 inline const gp_Vec& Blend_Point::TangentOnC2 () const
 {
-  if (istgt) {Standard_DomainError::Raise();}
+  if (istgt) {throw Standard_DomainError();}
   return tg2;
 }
index 75a5cb8..b6925cb 100644 (file)
@@ -37,8 +37,7 @@ const gp_Pnt& Blend_RstRstFunction::Pnt2() const
 
 Standard_Real Blend_RstRstFunction::GetMinimalDistance() const
 {
-  Standard_NotImplemented::Raise("Blend_RstRstFunction::GetMinimalDistance");
-  return RealLast();
+  throw Standard_NotImplemented("Blend_RstRstFunction::GetMinimalDistance");
 }
 
 
index 706e459..b49a87e 100644 (file)
@@ -36,7 +36,4 @@ const gp_Pnt& Blend_SurfRstFunction::Pnt2() const
 }
 
 Standard_Real Blend_SurfRstFunction::GetMinimalDistance() const
-{
-  Standard_NotImplemented::Raise("Blend_SurfRstFunction::GetMinimalDistance");
-  return RealLast();
-}
+{  throw Standard_NotImplemented("Blend_SurfRstFunction::GetMinimalDistance");}
index 4f014d3..1ebdf48 100644 (file)
@@ -31,6 +31,6 @@ inline Standard_Boolean Blend_Walking::TwistOnS2() const
 
 inline const Handle(TheLine)& Blend_Walking::Line () const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return line;
 }
index 8f205cf..16373be 100644 (file)
@@ -445,7 +445,7 @@ Standard_Boolean Blend_Walking::PerformFirstSection (Blend_Function& Func,
     break;
   default:
     {
-      Standard_Failure::Raise("Blend_Walking::PerformFirstSection : echec");
+      throw Standard_Failure("Blend_Walking::PerformFirstSection : echec");
     }
   }
   if (sens < 0.0)
@@ -465,7 +465,7 @@ Standard_Boolean Blend_Walking::Continu(Blend_Function& Func,
                                        Blend_FuncInv& FuncInv,
                                        const Standard_Real P)
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   const Blend_Point& firstBP =  line->Point(1);
   const Blend_Point& lastBP =  line->Point(line->NbPoints());
 
@@ -492,7 +492,7 @@ Standard_Boolean Blend_Walking::Continu(Blend_Function& Func,
                                        const Standard_Real P,
                                        const Standard_Boolean OnS1)
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   TheExtremity Ext1,Ext2;
   if (sens < 0.) {
     Ext1 = line->StartPointOnFirst();
@@ -553,7 +553,7 @@ Standard_Boolean Blend_Walking::Complete(Blend_Function& Func,
                                         Blend_FuncInv& FuncInv,
                                         const Standard_Real Pmin)
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   if (iscomplete) {return Standard_True;}
 
   if (sens >0.) {
index bc2bf89..a7aba14 100644 (file)
@@ -134,7 +134,7 @@ void BlendFunc_CSCircular::Set(const Standard_Real Param)
 
 void BlendFunc_CSCircular::Set(const Standard_Real, const Standard_Real)
 {
-  Standard_NotImplemented::Raise("BlendFunc_CSCircular::Set");
+  throw Standard_NotImplemented("BlendFunc_CSCircular::Set");
 }
 
 //=======================================================================
@@ -469,7 +469,7 @@ Standard_Boolean BlendFunc_CSCircular::IsTangencyPoint () const
 const gp_Vec& BlendFunc_CSCircular::TangentOnS () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_CSCircular::TangentOnS");
+    throw Standard_DomainError("BlendFunc_CSCircular::TangentOnS");
   return tgs;
 }
 
@@ -481,7 +481,7 @@ const gp_Vec& BlendFunc_CSCircular::TangentOnS () const
 const gp_Vec& BlendFunc_CSCircular::TangentOnC () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_CSCircular::TangentOnC");
+    throw Standard_DomainError("BlendFunc_CSCircular::TangentOnC");
   return tgc;
 }
 
@@ -493,7 +493,7 @@ const gp_Vec& BlendFunc_CSCircular::TangentOnC () const
 const gp_Vec2d& BlendFunc_CSCircular::Tangent2d () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_CSCircular::Tangent2d");
+    throw Standard_DomainError("BlendFunc_CSCircular::Tangent2d");
   return tg2d;
 }
 
@@ -592,7 +592,7 @@ Standard_Boolean BlendFunc_CSCircular::GetSection(const Standard_Real Param,
                                                  TColgp_Array1OfVec& tabV)
 {
   Standard_Integer NbPoint=tabP.Length();
-  if (NbPoint != tabV.Length() || NbPoint < 2) {Standard_RangeError::Raise();}
+  if (NbPoint != tabV.Length() || NbPoint < 2) {throw Standard_RangeError();}
 
   Standard_Integer i, lowp = tabP.Lower(), lowv = tabV.Lower();
 
index 2d28d13..26e033a 100644 (file)
@@ -104,7 +104,7 @@ void BlendFunc_CSConstRad::Set(const Standard_Real Param)
 
 void BlendFunc_CSConstRad::Set(const Standard_Real, const Standard_Real)
 {
-  Standard_NotImplemented::Raise("BlendFunc_CSConstRad::Set");
+  throw Standard_NotImplemented("BlendFunc_CSConstRad::Set");
 }
 
 
@@ -451,7 +451,7 @@ Standard_Boolean BlendFunc_CSConstRad::IsTangencyPoint () const
 const gp_Vec& BlendFunc_CSConstRad::TangentOnS () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_CSConstRad::TangentOnS");
+    throw Standard_DomainError("BlendFunc_CSConstRad::TangentOnS");
   return tgs;
 }
 
@@ -463,7 +463,7 @@ const gp_Vec& BlendFunc_CSConstRad::TangentOnS () const
 const gp_Vec& BlendFunc_CSConstRad::TangentOnC () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_CSConstRad::TangentOnC");
+    throw Standard_DomainError("BlendFunc_CSConstRad::TangentOnC");
   return tgc;
 }
 
@@ -475,7 +475,7 @@ const gp_Vec& BlendFunc_CSConstRad::TangentOnC () const
 const gp_Vec2d& BlendFunc_CSConstRad::Tangent2d () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_CSConstRad::Tangent2d");
+    throw Standard_DomainError("BlendFunc_CSConstRad::Tangent2d");
   return tg2d;
 }
 
@@ -548,8 +548,7 @@ void BlendFunc_CSConstRad::Section(const Standard_Real Param,
 
 Standard_Boolean BlendFunc_CSConstRad::Section(const Blend_Point&, TColgp_Array1OfPnt&, TColgp_Array1OfVec&, TColgp_Array1OfVec&, TColgp_Array1OfPnt2d&, TColgp_Array1OfVec2d&, TColgp_Array1OfVec2d&, TColStd_Array1OfReal&, TColStd_Array1OfReal&, TColStd_Array1OfReal&)
 {
- Standard_DomainError::Raise("BlendFunc_CSConstRad::Section : Not implemented");
- return Standard_False ;
+ throw Standard_DomainError("BlendFunc_CSConstRad::Section : Not implemented");
 }
 
 //=======================================================================
@@ -565,7 +564,7 @@ Standard_Boolean BlendFunc_CSConstRad::GetSection(const Standard_Real Param,
                                                  TColgp_Array1OfVec& tabV)
 {
   Standard_Integer NbPoint=tabP.Length();
-  if (NbPoint != tabV.Length() || NbPoint < 2) {Standard_RangeError::Raise();}
+  if (NbPoint != tabV.Length() || NbPoint < 2) {throw Standard_RangeError();}
 
   Standard_Integer i, lowp = tabP.Lower(), lowv = tabV.Lower();
 
index 264803a..6321d00 100644 (file)
@@ -396,7 +396,7 @@ Standard_Boolean BlendFunc_ChAsym::IsTangencyPoint () const
 const gp_Vec& BlendFunc_ChAsym::TangentOnS1 () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_ChAsym::TangentOnS1");
+    throw Standard_DomainError("BlendFunc_ChAsym::TangentOnS1");
   return tg1;
 }
 
@@ -409,7 +409,7 @@ const gp_Vec& BlendFunc_ChAsym::TangentOnS1 () const
 const gp_Vec2d& BlendFunc_ChAsym::Tangent2dOnS1 () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_ChAsym::Tangent2dOnS1");
+    throw Standard_DomainError("BlendFunc_ChAsym::Tangent2dOnS1");
   return tg12d;
 }
 
@@ -421,7 +421,7 @@ const gp_Vec2d& BlendFunc_ChAsym::Tangent2dOnS1 () const
 const gp_Vec& BlendFunc_ChAsym::TangentOnS2 () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_ChAsym::TangentOnS2");
+    throw Standard_DomainError("BlendFunc_ChAsym::TangentOnS2");
   return tg2;
 }
 
@@ -434,7 +434,7 @@ const gp_Vec& BlendFunc_ChAsym::TangentOnS2 () const
 const gp_Vec2d& BlendFunc_ChAsym::Tangent2dOnS2 () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_ChAsym::Tangent2dOnS2");
+    throw Standard_DomainError("BlendFunc_ChAsym::Tangent2dOnS2");
   return tg22d;
 }
 
@@ -447,7 +447,7 @@ const gp_Vec2d& BlendFunc_ChAsym::Tangent2dOnS2 () const
 Standard_Boolean BlendFunc_ChAsym::TwistOnS1() const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_ChAsym::TwistOnS1");
+    throw Standard_DomainError("BlendFunc_ChAsym::TwistOnS1");
   return tg1.Dot(nplan) < 0.;
 }
 
@@ -459,7 +459,7 @@ Standard_Boolean BlendFunc_ChAsym::TwistOnS1() const
 Standard_Boolean BlendFunc_ChAsym::TwistOnS2() const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_ChAsym::TwistOnS2");
+    throw Standard_DomainError("BlendFunc_ChAsym::TwistOnS2");
   return tg2.Dot(nplan) < 0.;
 }
 
@@ -557,8 +557,7 @@ Standard_Boolean BlendFunc_ChAsym::IsRational () const
 //=======================================================================
 Standard_Real BlendFunc_ChAsym::GetSectionSize() const 
 {
-  Standard_NotImplemented::Raise("BlendFunc_ChAsym::GetSectionSize()");
-  return 0.;
+  throw Standard_NotImplemented("BlendFunc_ChAsym::GetSectionSize()");
 }
 
 //=======================================================================
index 3a835dc..80aa521 100644 (file)
@@ -384,8 +384,7 @@ Standard_Boolean BlendFunc_Chamfer::IsRational() const
 //=======================================================================
 Standard_Real BlendFunc_Chamfer::GetSectionSize() const 
 {
-  Standard_NotImplemented::Raise("BlendFunc_Chamfer::GetSectionSize()");
-  return 0;
+  throw Standard_NotImplemented("BlendFunc_Chamfer::GetSectionSize()");
 }
 
 //=======================================================================
index 461b1c7..ab071fe 100644 (file)
@@ -1029,7 +1029,7 @@ Standard_Boolean BlendFunc_ConstRad::IsTangencyPoint () const
 const gp_Vec& BlendFunc_ConstRad::TangentOnS1 () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_ConstRad::TangentOnS1");
+    throw Standard_DomainError("BlendFunc_ConstRad::TangentOnS1");
   return tg1;
 }
 
@@ -1042,7 +1042,7 @@ const gp_Vec& BlendFunc_ConstRad::TangentOnS1 () const
 const gp_Vec& BlendFunc_ConstRad::TangentOnS2 () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_ConstRad::TangentOnS2");
+    throw Standard_DomainError("BlendFunc_ConstRad::TangentOnS2");
   return tg2;
 }
 
@@ -1055,7 +1055,7 @@ const gp_Vec& BlendFunc_ConstRad::TangentOnS2 () const
 const gp_Vec2d& BlendFunc_ConstRad::Tangent2dOnS1 () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_ConstRad::Tangent2dOnS1");
+    throw Standard_DomainError("BlendFunc_ConstRad::Tangent2dOnS1");
   return tg12d;
 }
 
@@ -1068,7 +1068,7 @@ const gp_Vec2d& BlendFunc_ConstRad::Tangent2dOnS1 () const
 const gp_Vec2d& BlendFunc_ConstRad::Tangent2dOnS2 () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_ConstRad::Tangent2dOnS2");
+    throw Standard_DomainError("BlendFunc_ConstRad::Tangent2dOnS2");
   return tg22d;
 }
 
@@ -1128,7 +1128,7 @@ void BlendFunc_ConstRad::Tangent(const Standard_Real U1,
 Standard_Boolean BlendFunc_ConstRad::TwistOnS1() const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_ConstRad::TwistOnS1");
+    throw Standard_DomainError("BlendFunc_ConstRad::TwistOnS1");
   return tg1.Dot(nplan) < 0.;
 }
 
@@ -1140,7 +1140,7 @@ Standard_Boolean BlendFunc_ConstRad::TwistOnS1() const
 Standard_Boolean BlendFunc_ConstRad::TwistOnS2() const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_ConstRad::TwistOnS2");
+    throw Standard_DomainError("BlendFunc_ConstRad::TwistOnS2");
   return tg2.Dot(nplan) < 0.;
 }
 
index 17337c4..1ef5ec4 100644 (file)
@@ -149,7 +149,7 @@ Standard_Boolean BlendFunc_Corde::IsTangencyPoint () const
 const gp_Vec& BlendFunc_Corde::TangentOnS () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_Corde::TangentOnS");
+    throw Standard_DomainError("BlendFunc_Corde::TangentOnS");
   return tgs;
 }
 
@@ -162,7 +162,7 @@ const gp_Vec& BlendFunc_Corde::TangentOnS () const
 const gp_Vec2d& BlendFunc_Corde::Tangent2dOnS () const
 {
   if (istangent) 
-    Standard_DomainError::Raise("BlendFunc_Corde::Tangent2dOnS");
+    throw Standard_DomainError("BlendFunc_Corde::Tangent2dOnS");
   return tg2d;
 }
 
index c666f49..5de3e48 100644 (file)
@@ -1115,7 +1115,7 @@ void BlendFunc_EvolRad::Tangent(const Standard_Real U1,
 
 Standard_Boolean BlendFunc_EvolRad::TwistOnS1() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tg1.Dot(nplan) < 0.;
 }
 
@@ -1126,7 +1126,7 @@ Standard_Boolean BlendFunc_EvolRad::TwistOnS1() const
 
 Standard_Boolean BlendFunc_EvolRad::TwistOnS2() const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tg2.Dot(nplan) < 0.;
 }
 
@@ -1226,7 +1226,7 @@ Standard_Boolean BlendFunc_EvolRad::IsTangencyPoint () const
 
 const gp_Vec& BlendFunc_EvolRad::TangentOnS1 () const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tg1;
 }
 
@@ -1238,7 +1238,7 @@ const gp_Vec& BlendFunc_EvolRad::TangentOnS1 () const
 
 const gp_Vec& BlendFunc_EvolRad::TangentOnS2 () const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tg2;
 }
 
@@ -1250,7 +1250,7 @@ const gp_Vec& BlendFunc_EvolRad::TangentOnS2 () const
 
 const gp_Vec2d& BlendFunc_EvolRad::Tangent2dOnS1 () const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tg12d;
 }
 
@@ -1262,7 +1262,7 @@ const gp_Vec2d& BlendFunc_EvolRad::Tangent2dOnS1 () const
 
 const gp_Vec2d& BlendFunc_EvolRad::Tangent2dOnS2 () const
 {
-  if (istangent) {Standard_DomainError::Raise();}
+  if (istangent) {throw Standard_DomainError();}
   return tg22d;
 }
 
index 5585fc3..0b5289e 100644 (file)
@@ -57,7 +57,7 @@ void BlendFunc_Ruled::Set(const Standard_Real Param)
 void BlendFunc_Ruled::Set(const Standard_Real,
                           const Standard_Real)
 {
-  Standard_NotImplemented::Raise("BlendFunc_Ruled::Set");
+  throw Standard_NotImplemented("BlendFunc_Ruled::Set");
 }
 
 void BlendFunc_Ruled::GetTolerance(math_Vector& Tolerance,
@@ -417,27 +417,27 @@ Standard_Boolean BlendFunc_Ruled::IsTangencyPoint () const
 const gp_Vec& BlendFunc_Ruled::TangentOnS1 () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_Ruled::TangentOnS1");
+    throw Standard_DomainError("BlendFunc_Ruled::TangentOnS1");
   return tg1;
 }
 
 const gp_Vec& BlendFunc_Ruled::TangentOnS2 () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_Ruled::TangentOnS2");
+    throw Standard_DomainError("BlendFunc_Ruled::TangentOnS2");
   return tg2;
 }
 const gp_Vec2d& BlendFunc_Ruled::Tangent2dOnS1 () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_Ruled::Tangent2dOnS1");
+    throw Standard_DomainError("BlendFunc_Ruled::Tangent2dOnS1");
   return tg12d;
 }
 
 const gp_Vec2d& BlendFunc_Ruled::Tangent2dOnS2 () const
 {
   if (istangent)
-    Standard_DomainError::Raise("BlendFunc_Ruled::Tangent2dOnS2");
+    throw Standard_DomainError("BlendFunc_Ruled::Tangent2dOnS2");
   return tg22d;
 }
 
@@ -451,7 +451,7 @@ Standard_Boolean BlendFunc_Ruled::GetSection(const Standard_Real Param,
 
 {
   Standard_Integer NbPoint=tabP.Length();
-  if (NbPoint != tabV.Length() || NbPoint < 2) {Standard_RangeError::Raise();}
+  if (NbPoint != tabV.Length() || NbPoint < 2) {throw Standard_RangeError();}
 
   Standard_Integer i, lowp = tabP.Lower(), lowv = tabV.Lower();
 
@@ -548,8 +548,7 @@ Standard_Boolean BlendFunc_Ruled::IsRational () const
 //=======================================================================
 Standard_Real BlendFunc_Ruled::GetSectionSize() const 
 {
-  Standard_NotImplemented::Raise("BlendFunc_Ruled::GetSectionSize()");
-  return 0;
+  throw Standard_NotImplemented("BlendFunc_Ruled::GetSectionSize()");
 }
 
 //=======================================================================
index 360e6e9..62451ef 100644 (file)
@@ -169,7 +169,7 @@ void Bnd_Box::Get (Standard_Real& theXmin,
 {
   if (IsVoid())
   {
-    Standard_ConstructionError::Raise ("Bnd_Box is void");
+    throw Standard_ConstructionError("Bnd_Box is void");
   }
 
   if (IsOpenXmin()) theXmin = -Bnd_Precision_Infinite;
@@ -196,8 +196,7 @@ gp_Pnt Bnd_Box::CornerMin() const
   gp_Pnt aCornerMin;
   if (IsVoid())
   {
-    Standard_ConstructionError::Raise ("Bnd_Box is void");
-    return aCornerMin;
+    throw Standard_ConstructionError("Bnd_Box is void");
   }
   if (IsOpenXmin()) aCornerMin.SetX (-Bnd_Precision_Infinite);
   else              aCornerMin.SetX (Xmin - Gap);
@@ -218,8 +217,7 @@ gp_Pnt Bnd_Box::CornerMax() const
   gp_Pnt aCornerMax;
   if (IsVoid())
   {
-    Standard_ConstructionError::Raise ("Bnd_Box is void");
-    return aCornerMax;
+    throw Standard_ConstructionError("Bnd_Box is void");
   }
   if (IsOpenXmax()) aCornerMax.SetX (Bnd_Precision_Infinite);
   else              aCornerMax.SetX (Xmax + Gap);
index 8e6bdb5..02263e9 100644 (file)
@@ -77,7 +77,7 @@ void Bnd_Box2d::Get (Standard_Real& x, Standard_Real& y,
                     Standard_Real& Xm, Standard_Real& Ym) const
 {
   if(Flags & VoidMask)
-    Standard_ConstructionError::Raise("Bnd_Box is void");
+    throw Standard_ConstructionError("Bnd_Box is void");
   Standard_Real pinf = 1e+100; //-- Precision::Infinite();
   if (Flags & XminMask) x = -pinf;
   else                  x =  Xmin-Gap;
index 439008f..2afd47f 100644 (file)
@@ -37,7 +37,7 @@ public:
                                                     myFirst(theMin), myLast(theMax)
   {
     if(myLast < myFirst)
-      Standard_ConstructionError::Raise("Last < First");
+      throw Standard_ConstructionError("Last < First");
   };
 
   //! Replaces <this> with common-part of <this> and theOther
index b581764..2f2ef91 100644 (file)
@@ -306,7 +306,7 @@ void BndLib::Add( const gp_Lin& L,const Standard_Real P1,
 
   if (Precision::IsNegativeInfinite(P1)) {
     if (Precision::IsNegativeInfinite(P2)) {
-      Standard_Failure::Raise("BndLib::bad parameter");
+      throw Standard_Failure("BndLib::bad parameter");
     }
     else if (Precision::IsPositiveInfinite(P2)) {
       OpenMinMax(L.Direction(),B);
@@ -323,7 +323,7 @@ void BndLib::Add( const gp_Lin& L,const Standard_Real P1,
       B.Add(ElCLib::Value(0.,L));
     }
     else if (Precision::IsPositiveInfinite(P2)) {
-      Standard_Failure::Raise("BndLib::bad parameter");
+      throw Standard_Failure("BndLib::bad parameter");
     }
     else {
       OpenMax(L.Direction(),B);
@@ -351,7 +351,7 @@ void BndLib::Add( const gp_Lin2d& L,const Standard_Real P1,
 
   if (Precision::IsNegativeInfinite(P1)) {
     if (Precision::IsNegativeInfinite(P2)) {
-      Standard_Failure::Raise("BndLib::bad parameter");
+      throw Standard_Failure("BndLib::bad parameter");
     }
     else if (Precision::IsPositiveInfinite(P2)) {
       OpenMinMax(L.Direction(),B);
@@ -368,7 +368,7 @@ void BndLib::Add( const gp_Lin2d& L,const Standard_Real P1,
       B.Add(ElCLib::Value(0.,L));
     }
     else if (Precision::IsPositiveInfinite(P2)) {
-      Standard_Failure::Raise("BndLib::bad parameter");
+      throw Standard_Failure("BndLib::bad parameter");
     }
     else {
       OpenMax(L.Direction(),B);
@@ -767,7 +767,7 @@ void BndLib::Add( const gp_Parab& P,const Standard_Real P1,
 
   if (Precision::IsNegativeInfinite(P1)) {
     if (Precision::IsNegativeInfinite(P2)) {
-      Standard_Failure::Raise("BndLib::bad parameter");
+      throw Standard_Failure("BndLib::bad parameter");
     }
     else if (Precision::IsPositiveInfinite(P2)) {
       B.OpenXmax();B.OpenYmax();B.OpenZmax();
@@ -782,7 +782,7 @@ void BndLib::Add( const gp_Parab& P,const Standard_Real P1,
       B.OpenXmin();B.OpenYmin();B.OpenZmin();
     }
     else if (Precision::IsPositiveInfinite(P2)) {
-      Standard_Failure::Raise("BndLib::bad parameter");
+      throw Standard_Failure("BndLib::bad parameter");
     }
     else {
       B.Add(ElCLib::Value(P2,P));
@@ -811,7 +811,7 @@ void BndLib::Add( const gp_Parab2d& P,const Standard_Real P1,
 
   if (Precision::IsNegativeInfinite(P1)) {
     if (Precision::IsNegativeInfinite(P2)) {
-      Standard_Failure::Raise("BndLib::bad parameter");
+      throw Standard_Failure("BndLib::bad parameter");
     }
     else if (Precision::IsPositiveInfinite(P2)) {
       B.OpenXmax();B.OpenYmax();
@@ -826,7 +826,7 @@ void BndLib::Add( const gp_Parab2d& P,const Standard_Real P1,
       B.OpenXmin();B.OpenYmin();
     }
     else if (Precision::IsPositiveInfinite(P2)) {
-      Standard_Failure::Raise("BndLib::bad parameter");
+      throw Standard_Failure("BndLib::bad parameter");
     }
     else {
       B.Add(ElCLib::Value(P2,P));
@@ -861,7 +861,7 @@ void BndLib::Add(const gp_Hypr& H,
 {
   if (Precision::IsNegativeInfinite(P1)) {
     if (Precision::IsNegativeInfinite(P2)) {
-      Standard_Failure::Raise("BndLib::bad parameter");
+      throw Standard_Failure("BndLib::bad parameter");
     }
     else if (Precision::IsPositiveInfinite(P2)) {
       B.OpenXmax();B.OpenYmax();B.OpenZmax();
@@ -876,7 +876,7 @@ void BndLib::Add(const gp_Hypr& H,
       B.OpenXmin();B.OpenYmin();B.OpenZmin();
     }
     else if (Precision::IsPositiveInfinite(P2)) {
-      Standard_Failure::Raise("BndLib::bad parameter");
+      throw Standard_Failure("BndLib::bad parameter");
     }
     else {
       B.Add(ElCLib::Value(P2,H));
@@ -904,7 +904,7 @@ void BndLib::Add(const gp_Hypr2d& H,const Standard_Real P1,
   
   if (Precision::IsNegativeInfinite(P1)) {
     if (Precision::IsNegativeInfinite(P2)) {
-      Standard_Failure::Raise("BndLib::bad parameter");
+      throw Standard_Failure("BndLib::bad parameter");
     }
     else if (Precision::IsPositiveInfinite(P2)) {
       B.OpenXmax();B.OpenYmax();
@@ -919,7 +919,7 @@ void BndLib::Add(const gp_Hypr2d& H,const Standard_Real P1,
       B.OpenXmin();B.OpenYmin();
     }
     else if (Precision::IsPositiveInfinite(P2)) {
-      Standard_Failure::Raise("BndLib::bad parameter");
+      throw Standard_Failure("BndLib::bad parameter");
     }
     else {
       B.Add(ElCLib::Value(P2,H));
@@ -963,7 +963,7 @@ void BndLib::Add( const gp_Cylinder& S,const Standard_Real UMin,
   {
     if (Precision::IsNegativeInfinite(VMax))
     {
-      Standard_Failure::Raise("BndLib::bad parameter");
+      throw Standard_Failure("BndLib::bad parameter");
     }
     else if (Precision::IsPositiveInfinite(VMax))
     {
@@ -983,7 +983,7 @@ void BndLib::Add( const gp_Cylinder& S,const Standard_Real UMin,
     }
     else if (Precision::IsPositiveInfinite(VMax))
     {
-      Standard_Failure::Raise("BndLib::bad parameter");
+      throw Standard_Failure("BndLib::bad parameter");
     }
     else
     {
@@ -1057,7 +1057,7 @@ void BndLib::Add(const gp_Cone& S,const Standard_Real UMin,
   {
     if (Precision::IsNegativeInfinite(VMax)) 
     {
-      Standard_Failure::Raise("BndLib::bad parameter");
+      throw Standard_Failure("BndLib::bad parameter");
     }
     else if (Precision::IsPositiveInfinite(VMax)) 
     {
@@ -1081,7 +1081,7 @@ void BndLib::Add(const gp_Cone& S,const Standard_Real UMin,
     }
     else if (Precision::IsPositiveInfinite(VMax)) 
     {
-      Standard_Failure::Raise("BndLib::bad parameter");
+      throw Standard_Failure("BndLib::bad parameter");
     }
     else 
     {
index 3992409..99ff38a 100644 (file)
@@ -222,12 +222,12 @@ Handle(CDM_Document) CDF_Application::Retrieve(const Handle(CDM_MetaData)& aMeta
     case PCDM_RS_UnknownDocument: 
       aMsg << "could not find the referenced document: " << aMetaData->Path() << "; not found."  <<(char)0 << endl;
       myRetrievableStatus = PCDM_RS_UnknownDocument;
-      Standard_Failure::Raise(aMsg);
+      throw Standard_Failure(aMsg.str().c_str());
       break;
     case PCDM_RS_PermissionDenied:      
       aMsg << "Could not find the referenced document: " << aMetaData->Path() << "; permission denied. " <<(char)0 << endl;
       myRetrievableStatus = PCDM_RS_PermissionDenied;
-      Standard_Failure::Raise(aMsg);
+      throw Standard_Failure(aMsg.str().c_str());
       break;
     default:
       break;
@@ -245,7 +245,7 @@ Handle(CDM_Document) CDF_Application::Retrieve(const Handle(CDM_MetaData)& aMeta
     {
       Standard_SStream aMsg;
       aMsg << "Could not determine format for the file " << aMetaData->FileName() << (char)0;
-      Standard_NoSuchObject::Raise(aMsg);
+      throw Standard_NoSuchObject(aMsg.str().c_str());
     }
     Handle(PCDM_Reader) theReader = ReaderFromFormat (aFormat);
         
@@ -267,12 +267,12 @@ Handle(CDM_Document) CDF_Application::Retrieve(const Handle(CDM_MetaData)& aMeta
       OCC_CATCH_SIGNALS
       theReader->Read(aMetaData->FileName(),theDocument,this);
     } 
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
       myRetrievableStatus = theReader->GetStatus();
       if(myRetrievableStatus  > PCDM_RS_AlreadyRetrieved){
        Standard_SStream aMsg;
-       aMsg << Standard_Failure::Caught() << endl;
-       Standard_Failure::Raise(aMsg);
+       aMsg << anException << endl;
+       throw Standard_Failure(aMsg.str().c_str());
       }        
     }
     myRetrievableStatus = theReader->GetStatus();    
@@ -333,13 +333,13 @@ Handle(CDM_Document) CDF_Application::Read (Standard_IStream& theIStream)
     
     aFormat = PCDM_ReadWriter::FileFormat (theIStream, dData);
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
     myRetrievableStatus = PCDM_RS_FormatFailure;
     
     Standard_SStream aMsg;
-    aMsg << Standard_Failure::Caught() << endl;
-    Standard_Failure::Raise(aMsg);
+    aMsg << anException << endl;
+    throw Standard_Failure(aMsg.str().c_str());
   }
 
   if (aFormat.IsEmpty())
@@ -361,14 +361,14 @@ Handle(CDM_Document) CDF_Application::Read (Standard_IStream& theIStream)
   
     aReader->Read (theIStream, dData, aDoc, this);
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
     myRetrievableStatus = aReader->GetStatus();
     if (myRetrievableStatus  > PCDM_RS_AlreadyRetrieved)
     {
       Standard_SStream aMsg;
-      aMsg << Standard_Failure::Caught() << endl;
-      Standard_Failure::Raise(aMsg);
+      aMsg << anException << endl;
+      throw Standard_Failure(aMsg.str().c_str());
     }  
   }
 
@@ -397,7 +397,7 @@ Handle(PCDM_Reader) CDF_Application::ReaderFromFormat(const TCollection_Extended
     Standard_SStream aMsg; 
     aMsg << "Could not found the item:" << aResourceName <<(char)0;
     myRetrievableStatus = PCDM_RS_WrongResource;
-    Standard_NoSuchObject::Raise(aMsg);
+    throw Standard_NoSuchObject(aMsg.str().c_str());
   }
 
   // Get GUID as a string.
@@ -414,11 +414,11 @@ Handle(PCDM_Reader) CDF_Application::ReaderFromFormat(const TCollection_Extended
     OCC_CATCH_SIGNALS
     aReader = Handle(PCDM_RetrievalDriver)::DownCast(Plugin::Load(aPluginId));  
   } 
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
     myReaders.Add(theFormat, aReader);
     myRetrievableStatus = PCDM_RS_WrongResource;
-    Standard_Failure::Caught()->Reraise();
+    throw anException;
   }    
   if (!aReader.IsNull()) {
     aReader->SetFormat(theFormat);
@@ -452,7 +452,7 @@ Handle(PCDM_StorageDriver) CDF_Application::WriterFromFormat(const TCollection_E
     myWriters.Add(theFormat, aDriver);
     Standard_SStream aMsg; 
     aMsg << "Could not found the resource definition:" << aResourceName <<(char)0;
-    Standard_NoSuchObject::Raise(aMsg);
+    throw Standard_NoSuchObject(aMsg.str().c_str());
   }
 
   // Get GUID as a string.
@@ -469,11 +469,11 @@ Handle(PCDM_StorageDriver) CDF_Application::WriterFromFormat(const TCollection_E
     OCC_CATCH_SIGNALS
     aDriver = Handle(PCDM_StorageDriver)::DownCast(Plugin::Load(aPluginId));
   } 
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
     myWriters.Add(theFormat, aDriver);
     myRetrievableStatus = PCDM_RS_WrongResource;
-    Standard_Failure::Caught()->Reraise();
+    throw anException;
   }    
   if (aDriver.IsNull()) 
   {
index 2c4f95e..a8c84c3 100644 (file)
@@ -180,7 +180,7 @@ TCollection_ExtendedString CDF_FWOSDriver::DefaultFolder()
     else {
       theDefaultFolder=UTL::xgetenv("TEMP");
       if(theDefaultFolder.Length()==0)
-        Standard_Failure::Raise("cannot determine default folder; HOMEDRIVE and TEMP are undefined");
+        throw Standard_Failure("cannot determine default folder; HOMEDRIVE and TEMP are undefined");
     }
 #else
     TCollection_ExtendedString home=UTL::xgetenv("HOME");
index d37ca37..4b9e173 100644 (file)
@@ -31,7 +31,7 @@ DEFINE_STANDARD_HANDLE(CDF_MetaDataDriverError, Standard_Failure)
 
 #if !defined No_Exception && !defined No_CDF_MetaDataDriverError
   #define CDF_MetaDataDriverError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) CDF_MetaDataDriverError::Raise(MESSAGE);
+  if (CONDITION) throw CDF_MetaDataDriverError(MESSAGE);
 #else
   #define CDF_MetaDataDriverError_Raise_if(CONDITION, MESSAGE)
 #endif
index 5fc200a..afd7511 100644 (file)
 
 IMPLEMENT_STANDARD_RTTIEXT(CDF_StoreList,Standard_Transient)
 
-static void CAUGHT(TCollection_ExtendedString& status,const TCollection_ExtendedString& what) {
-  Handle(Standard_Failure) F = Standard_Failure::Caught();
+static void CAUGHT(const Standard_Failure& theException,TCollection_ExtendedString& status,const TCollection_ExtendedString& what) {
   status += what;
-  status += F->GetMessageString();
+  status += theException.GetMessageString();
 }
 
 CDF_StoreList::CDF_StoreList(const Handle(CDM_Document)& aDocument) {
@@ -91,7 +90,7 @@ PCDM_StoreStatus CDF_StoreList::Store (Handle(CDM_MetaData)& aMetaData, TCollect
           Handle(CDF_Application) anApp = Handle(CDF_Application)::DownCast (theDocument->Application());
           if (anApp.IsNull())
           {
-            Standard_Failure::Raise("Document has no application, cannot save!");
+            throw Standard_Failure("Document has no application, cannot save!");
           }
           Handle(PCDM_StorageDriver) aDocumentStorageDriver = 
             anApp->WriterFromFormat(theDocument->StorageFormat());
@@ -99,13 +98,13 @@ PCDM_StoreStatus CDF_StoreList::Store (Handle(CDM_MetaData)& aMetaData, TCollect
           {
             Standard_SStream aMsg;
             aMsg <<"No storage driver does exist for this format: " << theDocument->StorageFormat() << (char)0;
-            Standard_Failure::Raise(aMsg);
+            throw Standard_Failure(aMsg.str().c_str());
           }
 
           if(!theMetaDataDriver->FindFolder(theDocument->RequestedFolder())) {
             Standard_SStream aMsg; aMsg << "could not find the active dbunit";
             aMsg << TCollection_ExtendedString(theDocument->RequestedFolder())<< (char)0;
-            Standard_NoSuchObject::Raise(aMsg);
+            throw Standard_NoSuchObject(aMsg.str().c_str());
           }
           TCollection_ExtendedString theName=theMetaDataDriver->BuildFileName(theDocument);
 
@@ -122,12 +121,12 @@ PCDM_StoreStatus CDF_StoreList::Store (Handle(CDM_MetaData)& aMetaData, TCollect
       }
     }
 
-    catch (CDF_MetaDataDriverError) {
-      CAUGHT(aStatusAssociatedText,TCollection_ExtendedString("metadatadriver failed; reason:"));
+    catch (CDF_MetaDataDriverError anException) {
+      CAUGHT(anException, aStatusAssociatedText, TCollection_ExtendedString("metadatadriver failed; reason:"));
       status = PCDM_SS_DriverFailure;
     }
-    catch (Standard_Failure) {
-      CAUGHT(aStatusAssociatedText,TCollection_ExtendedString("driver failed; reason:"));
+    catch (Standard_Failure const& anException) {
+      CAUGHT(anException, aStatusAssociatedText, TCollection_ExtendedString("driver failed; reason:"));
       status = PCDM_SS_Failure; 
     }
   }
index 4a23520..1b78a09 100644 (file)
@@ -243,7 +243,7 @@ Standard_Boolean CDM_Document::IsInSession
   if(aReferenceIdentifier == 0) return Standard_True;
   Handle(CDM_Reference) theReference=Reference(aReferenceIdentifier);
   if(theReference.IsNull())
-    Standard_NoSuchObject::Raise("CDM_Document::IsInSession: "
+    throw Standard_NoSuchObject("CDM_Document::IsInSession: "
                                  "invalid reference identifier");
   return theReference->IsInSession();
 }
@@ -259,7 +259,7 @@ Standard_Boolean CDM_Document::IsStored
   if(aReferenceIdentifier == 0) return IsStored();
   Handle(CDM_Reference) theReference=Reference(aReferenceIdentifier);
   if(theReference.IsNull())
-    Standard_NoSuchObject::Raise("CDM_Document::IsInSession: "
+    throw Standard_NoSuchObject("CDM_Document::IsInSession: "
                                  "invalid reference identifier");
   return theReference->IsStored();
 }
@@ -273,7 +273,7 @@ TCollection_ExtendedString CDM_Document::Name
                                 (const Standard_Integer aReferenceIdentifier) const
 {
   if(!IsStored(aReferenceIdentifier))
-    Standard_DomainError::Raise("CDM_Document::Name: document is not stored");
+    throw Standard_DomainError("CDM_Document::Name: document is not stored");
 
   if(aReferenceIdentifier == 0) return myMetaData->Name();
 
@@ -599,7 +599,7 @@ Handle(CDM_Document) CDM_Document::FindFromPresentation
     Standard_SStream aMsg;
     aMsg <<"No document having this presentation: " << x << " does exist."
          << endl << (char)0;
-    Standard_NoSuchObject::Raise(aMsg);
+    throw Standard_NoSuchObject(aMsg.str().c_str());
   }
   return getPresentations()(x);
 }
@@ -694,7 +694,7 @@ void CDM_Document::UnsetIsStored()
 Handle(CDM_MetaData) CDM_Document::MetaData() const
 {
   if(myMetaData.IsNull())
-    Standard_NoSuchObject::Raise("cannot furnish the MetaData of an object "
+    throw Standard_NoSuchObject("cannot furnish the MetaData of an object "
                                  "which is not stored");
   return myMetaData;
 }
@@ -726,7 +726,7 @@ TCollection_ExtendedString CDM_Document::RequestedComment() const
 
 TCollection_ExtendedString CDM_Document::Folder() const {
   if(myMetaData.IsNull())
-    Standard_NoSuchObject::Raise("cannot furnish the folder of an object "
+    throw Standard_NoSuchObject("cannot furnish the folder of an object "
                                  "which is not stored");
   return myMetaData->Folder();
 }
@@ -885,17 +885,17 @@ void CDM_Document::Close()
 {
   switch (CanClose()) {
   case CDM_CCS_NotOpen: 
-    Standard_Failure::Raise("cannot close a document that has not been opened");
+    throw Standard_Failure("cannot close a document that has not been opened");
     break;
   case CDM_CCS_UnstoredReferenced:
-     Standard_Failure::Raise("cannot close an unstored document which is referenced");
+     throw Standard_Failure("cannot close an unstored document which is referenced");
     break;
   case CDM_CCS_ModifiedReferenced:
-    Standard_Failure::Raise("cannot close a document which is referenced when "
+    throw Standard_Failure("cannot close a document which is referenced when "
                             "the document has been modified since it was stored.");
     break;
   case CDM_CCS_ReferenceRejection:
-    Standard_Failure::Raise("cannot close this document because a document "
+    throw Standard_Failure("cannot close this document because a document "
                             "referencing it refuses");
     break;
   default:
@@ -967,7 +967,7 @@ void CDM_Document::CloseReference (const Handle(CDM_Document)& /*aDocument*/,
 const Handle(CDM_Application)& CDM_Document::Application() const
 {
   if(!IsOpened())
-    Standard_Failure::Raise("this document has not yet been opened "
+    throw Standard_Failure("this document has not yet been opened "
                             "by any application");
   return myApplication;
 }
@@ -1125,7 +1125,7 @@ Handle(Resource_Manager) CDM_Document::StorageResource()
     Standard_SStream aMsg;
     aMsg << "this document of format "<< StorageFormat()
          << " has not yet been opened by any application. "<< endl;
-    Standard_Failure::Raise(aMsg);
+    throw Standard_Failure(aMsg.str().c_str());
   }
   return myApplication->Resources();
 }  
index 22a9e6f..b40750e 100644 (file)
@@ -159,7 +159,7 @@ Standard_Real CPnts_AbscissaPoint::Length(const Adaptor3d_Curve& C,
 //  FG.Init(f3d,(Standard_Address)&C);
   math_GaussSingleIntegration TheLength(FG, U1, U2, order(C));
   if (!TheLength.IsDone()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   return Abs(TheLength.Value());
 }
@@ -180,7 +180,7 @@ Standard_Real CPnts_AbscissaPoint::Length(const Adaptor2d_Curve2d& C,
 //  FG.Init(f2d,(Standard_Address)&C);
   math_GaussSingleIntegration TheLength(FG, U1, U2, order(C));
   if (!TheLength.IsDone()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   return Abs(TheLength.Value());
 }
@@ -202,7 +202,7 @@ Standard_Real CPnts_AbscissaPoint::Length(const Adaptor3d_Curve& C,
 //  FG.Init(f3d,(Standard_Address)&C);
   math_GaussSingleIntegration TheLength(FG, U1, U2, order(C), Tol);
   if (!TheLength.IsDone()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   return Abs(TheLength.Value());
 }
@@ -224,7 +224,7 @@ Standard_Real CPnts_AbscissaPoint::Length(const Adaptor2d_Curve2d& C,
 //  FG.Init(f2d,(Standard_Address)&C);
   math_GaussSingleIntegration TheLength(FG, U1, U2, order(C), Tol);
   if (!TheLength.IsDone()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   return Abs(TheLength.Value());
 }
index d5e0899..35e84cb 100644 (file)
@@ -304,8 +304,7 @@ const CSLib_Class2d& CSLib_Class2d::Copy(const CSLib_Class2d& ) const
 #ifdef OCCT_DEBUG
   cerr<<"Copy not allowed in CSLib_Class2d"<<endl;
 #endif
-  Standard_ConstructionError::Raise();
-  return *this;
+  throw Standard_ConstructionError();
 }
 //=======================================================================
 //function : Transform2d
index f6cc1b4..0df834c 100644 (file)
@@ -174,17 +174,17 @@ void ChFi2d_AnaFilletAlgo::Init(const TopoDS_Wire& theWire, const gp_Pln& thePla
       e2 = TopoDS::Edge(itr.Value());
   }
   if (e1.IsNull() || e2.IsNull())
-    Standard_TypeMismatch::Raise("The algorithm expects a wire consisting of two linear or circular edges.");
+    throw Standard_TypeMismatch("The algorithm expects a wire consisting of two linear or circular edges.");
 
   // Left neighbour.
   BRepAdaptor_Curve AC1(e1);
   if (AC1.GetType() != GeomAbs_Line && AC1.GetType() != GeomAbs_Circle)
-    Standard_TypeMismatch::Raise("A segment or an arc of circle is expected.");
+    throw Standard_TypeMismatch("A segment or an arc of circle is expected.");
 
   TopoDS_Vertex v1, v2;
   TopExp::Vertices(e1, v1, v2, Standard_True);
   if (v1.IsNull() || v2.IsNull())
-    Standard_Failure::Raise("An infinite edge.");
+    throw Standard_Failure("An infinite edge.");
 
   gp_Pnt P1 = BRep_Tool::Pnt(v1);
   gp_Pnt P2 = BRep_Tool::Pnt(v2);
@@ -209,11 +209,11 @@ void ChFi2d_AnaFilletAlgo::Init(const TopoDS_Wire& theWire, const gp_Pln& thePla
   // Right neighbour.
   BRepAdaptor_Curve AC2(e2);
   if (AC2.GetType() != GeomAbs_Line && AC2.GetType() != GeomAbs_Circle)
-    Standard_TypeMismatch::Raise("A segment or an arc of circle is expected.");
+    throw Standard_TypeMismatch("A segment or an arc of circle is expected.");
 
   TopExp::Vertices(e2, v1, v2, Standard_True);
   if (v1.IsNull() || v2.IsNull())
-    Standard_Failure::Raise("An infinite edge.");
+    throw Standard_Failure("An infinite edge.");
 
   P1 = BRep_Tool::Pnt(v1);
   P2 = BRep_Tool::Pnt(v2);
@@ -247,7 +247,7 @@ void ChFi2d_AnaFilletAlgo::Init(const TopoDS_Edge& theEdge1, const TopoDS_Edge&
   TopExp::Vertices(theEdge1, v11, v12, Standard_True);
   TopExp::Vertices(theEdge2, v21, v22, Standard_True);
   if (v11.IsNull() || v12.IsNull() || v21.IsNull() || v22.IsNull())
-    Standard_Failure::Raise("An infinite edge.");
+    throw Standard_Failure("An infinite edge.");
 
   gp_Pnt p11 = BRep_Tool::Pnt(v11);
   gp_Pnt p12 = BRep_Tool::Pnt(v12);
@@ -264,7 +264,7 @@ void ChFi2d_AnaFilletAlgo::Init(const TopoDS_Edge& theEdge1, const TopoDS_Edge&
     pcommon = p12;
   }
   else
-    Standard_Failure::Raise("The edges have no common point.");
+    throw Standard_Failure("The edges have no common point.");
 
   // Reverse the edges in case of need (to construct a wire).
   Standard_Boolean is1stReversed(Standard_False), is2ndReversed(Standard_False);
@@ -284,7 +284,7 @@ void ChFi2d_AnaFilletAlgo::Init(const TopoDS_Edge& theEdge1, const TopoDS_Edge&
   else
     mkWire.Add(theEdge2);
   if (!mkWire.IsDone())
-    Standard_Failure::Raise("Can't make a wire.");
+    throw Standard_Failure("Can't make a wire.");
 
   const TopoDS_Wire& W = mkWire.Wire();
   Init(W, thePlane);
index 8726577..0eff8be 100644 (file)
@@ -90,7 +90,7 @@ void ChFi2d_FilletAlgo::Init(const TopoDS_Wire& theWire, const gp_Pln& thePlane)
       break;
   }
   if (theEdge1.IsNull() || theEdge2.IsNull())
-    Standard_ConstructionError::Raise("The fillet algorithms expects a wire consisting of two edges.");
+    throw Standard_ConstructionError("The fillet algorithms expects a wire consisting of two edges.");
   Init(theEdge1, theEdge2, thePlane);
 }
 
index a3b63c1..cd1d265 100644 (file)
@@ -230,7 +230,7 @@ void  ChFi3d_Builder::Compute()
 #endif 
   
   if (myListStripe.IsEmpty())
-    Standard_Failure::Raise("There are no suitable edges for chamfer or fillet");
+    throw Standard_Failure("There are no suitable edges for chamfer or fillet");
   
   Reset();
   myDS = new TopOpeBRepDS_HDataStructure();
@@ -272,11 +272,11 @@ void  ChFi3d_Builder::Compute()
       OCC_CATCH_SIGNALS
       PerformSetOfSurf(itel.Value());
     }
-    catch(Standard_Failure) {
-      Handle(Standard_Failure) exc = Standard_Failure::Caught();
+    catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
-      cout <<"EXCEPTION Stripe compute " << exc << endl;
+      cout <<"EXCEPTION Stripe compute " << anException << endl;
 #endif
+      (void)anException;
       badstripes.Append(itel.Value());
       done = Standard_True;
       if (itel.Value()->Spine()->ErrorStatus()==ChFiDS_Ok) 
@@ -302,12 +302,11 @@ void  ChFi3d_Builder::Compute()
         OCC_CATCH_SIGNALS
         PerformFilletOnVertex(j);
       }
-      catch(Standard_Failure)
-      {
-        Handle(Standard_Failure) exc = Standard_Failure::Caught();
+      catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
-        cout <<"EXCEPTION Corner compute " << exc << endl;
+        cout <<"EXCEPTION Corner compute " << anException << endl;
 #endif
+        (void)anException;
         badvertices.Append(myVDataMap.FindKey(j));
         hasresult=Standard_False;
         done = Standard_True;
@@ -358,11 +357,11 @@ void  ChFi3d_Builder::Compute()
          OCC_CATCH_SIGNALS
          ChFi3d_StripeEdgeInter (st, aCheckStripe, DStr, tol2d);
        }
-       catch(Standard_Failure) {
-         Handle(Standard_Failure) exc = Standard_Failure::Caught();
+       catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
-         cout <<"EXCEPTION Fillets compute " << exc << endl;
+         cout <<"EXCEPTION Fillets compute " << anException << endl;
 #endif
+         (void)anException;
          badstripes.Append(itel.Value());
          hasresult=Standard_False;
          done = Standard_False;
index 9af214b..9cf33a4 100644 (file)
@@ -1221,7 +1221,7 @@ void ChFi3d_ProjectPCurv(const Handle(Adaptor3d_HCurve)&   HCg,
         }
         break;
       default:
-        Standard_NotImplemented::Raise("echec approximation de la pcurve ");
+        throw Standard_NotImplemented("echec approximation de la pcurve ");
       }
   }
 }
@@ -1885,7 +1885,7 @@ Standard_Integer ChFi3d_SolidIndex(const Handle(ChFiDS_Spine)&  sp,
   ChFiDS_Map&                  MapESh)
 {
   if(sp.IsNull() || sp->NbEdges() == 0) 
-    Standard_Failure::Raise("SolidIndex : Spine incomplete");
+    throw Standard_Failure("SolidIndex : Spine incomplete");
   TopoDS_Shape edref= sp->Edges(1);
   TopoDS_Shape shellousolid;
   if(!MapESo(edref).IsEmpty()) shellousolid = MapESo(edref).First();
@@ -2836,7 +2836,7 @@ void ChFi3d_StripeEdgeInter (const Handle(ChFiDS_Stripe)& theStripe1,
         Precision::PConfusion());
       if (anIntersector.NbSegments() > 0 ||
         anIntersector.NbPoints() > 0)
-        StdFail_NotDone::Raise ("StripeEdgeInter : fillets have too big radiuses");
+        throw StdFail_NotDone("StripeEdgeInter : fillets have too big radiuses");
     }
   }
 }
@@ -2864,7 +2864,7 @@ Standard_Integer ChFi3d_IndexOfSurfData(const TopoDS_Vertex& V1,
     sens = -1;
     if(CD->SetOfSurfData().IsNull()) return 0;
     else if (Vref.IsSame(V1)) Index = CD->SetOfSurfData()->Length();
-    else Standard_ConstructionError::Raise("");
+    else throw Standard_ConstructionError("");
   }
   return Index; 
 }  
@@ -2891,9 +2891,8 @@ TopoDS_Edge ChFi3d_EdgeFromV1(const TopoDS_Vertex& V1,
     else Vref = TopExp::LastVertex(E1); 
     sens = -1;
     if (Vref.IsSame(V1)) return E1;
-    else Standard_ConstructionError::Raise("");
+    else throw Standard_ConstructionError("");
   }
-  return E;
 }
 //=======================================================================
 //function : ConvTol2dToTol3d
@@ -3816,7 +3815,7 @@ void ChFi3d_Parameters(const Handle(Geom_Surface)& S,
     {
       GeomAPI_ProjectPointOnSurf tool(p3d,S);
       if ( tool.NbPoints() != 1 )
-        StdFail_NotDone::Raise("");
+        throw StdFail_NotDone("");
       else
         tool.Parameters(1,u,v);
     }
@@ -3871,12 +3870,12 @@ void ChFi3d_TrimCurve(const Handle(Geom_Curve)& gc,
     {
       GeomAPI_ProjectPointOnCurve tool(FirstP,gc);
       if ( tool.NbPoints() != 1 )
-        StdFail_NotDone::Raise("");
+        throw StdFail_NotDone("");
       else
         uf = tool.Parameter(1);
       tool.Init(LastP,gc);
       if ( tool.NbPoints() != 1 )
-        StdFail_NotDone::Raise("");
+        throw StdFail_NotDone("");
       else
         ul = tool.Parameter(1);
     }
@@ -4103,7 +4102,7 @@ Standard_EXPORT
     //
     Bof = BRepLib::BuildCurve3d(E);
     if (!Bof) {
-      Standard_ConstructionError::Raise("PerformElSpine : BuildCurve3d error");
+      throw Standard_ConstructionError("PerformElSpine : BuildCurve3d error");
     }
     //
     Cv = BRep_Tool::Curve(E, First, Last);
@@ -4162,7 +4161,7 @@ Standard_EXPORT
     if (!Bof) {
       Bof = Concat.Add( TC, 200.*epsV, Standard_True );
       if (!Bof) {
-        Standard_ConstructionError::Raise("PerformElSpine: spine merged error");
+        throw Standard_ConstructionError("PerformElSpine: spine merged error");
       }
     }
     Eold = E;
index 8526465..d8b9560 100644 (file)
@@ -346,7 +346,7 @@ Standard_Boolean ChFi3d_Builder::FaceTangency(const TopoDS_Edge& E0,
   //It is checked if the connection is not on a regular edge.
   for (It.Initialize(myEFMap(E1)), Nbf= 0 ;It.More();It.Next(), Nbf++) {
     if (Nbf>1) 
-      Standard_ConstructionError::Raise("ChFi3d_Builder:only 2 faces");
+      throw Standard_ConstructionError("ChFi3d_Builder:only 2 faces");
     F[Nbf] = TopoDS::Face(It.Value());
   }      
   if(Nbf < 2) return Standard_False;
@@ -365,7 +365,7 @@ Standard_Boolean ChFi3d_Builder::FaceTangency(const TopoDS_Edge& E0,
        !BRep_Tool::Degenerated(Ec)) {
       for (It.Initialize(myEFMap(Ec)), Nbf= 0 ;It.More();It.Next(), Nbf++) {
        if (Nbf>1) 
-         Standard_ConstructionError::Raise("ChFi3d_Builder:only 2 faces");
+         throw Standard_ConstructionError("ChFi3d_Builder:only 2 faces");
        F[Nbf] = TopoDS::Face(It.Value());
       }      
       if(Nbf < 2) return Standard_False;
index 3fb0194..c7d003f 100644 (file)
@@ -972,7 +972,7 @@ void ChFi3d_Builder::StartSol(const Handle(ChFiDS_Stripe)&      Stripe,
     }
   }
   Spine->SetErrorStatus(ChFiDS_StartsolFailure);
-  Standard_Failure::Raise("StartSol echec");
+  throw Standard_Failure("StartSol echec");
 }
 
 //=======================================================================
@@ -1008,7 +1008,7 @@ static void  ChFi3d_BuildPlane (TopOpeBRepDS_DataStructure&    DStr,
       return; // everything is good !
     }
   }
-  Standard_Failure::Raise("ChFi3d_BuildPlane : echec .");
+  throw Standard_Failure("ChFi3d_BuildPlane : echec .");
 }
 
 //=======================================================================
@@ -1164,16 +1164,13 @@ ChFi3d_Builder::StartSol(const Handle(ChFiDS_Spine)&    Spine,
     // it is necessary to find the new support face of the fillet : 
     // connected to FRef along the newedge.
     if(newedge.IsNull()) {
-      Standard_Failure::Raise
-       ("StartSol : chain is not possible, new obstacle not found");
+      throw Standard_Failure("StartSol : chain is not possible, new obstacle not found");
     }
     if(IsG1(myEFMap,newedge,Fref,Fv)){
-      Standard_Failure::Raise
-       ("StartSol : chain is not possible, config non processed");
+      throw Standard_Failure("StartSol : chain is not possible, config non processed");
     }
     else if(Fv.IsNull()){
-      Standard_Failure::Raise
-       ("StartSol : chain is not possible, new obstacle not found");
+      throw Standard_Failure("StartSol : chain is not possible, new obstacle not found");
     }
     else{
       HS->ChangeSurface().Initialize(Fv);
@@ -1786,7 +1783,7 @@ static void InsertAfter (Handle(ChFiDS_Stripe)&   Stripe,
                         Handle(ChFiDS_SurfData)& Item)
 {
   if (Ref == Item) 
-    Standard_Failure::Raise("InsertAfter : twice the same surfdata.");
+    throw Standard_Failure("InsertAfter : twice the same surfdata.");
   
   ChFiDS_SequenceOfSurfData& Seq = 
     Stripe->ChangeSetOfSurfData()->ChangeSequence();
@@ -1835,7 +1832,7 @@ static void InsertBefore (Handle(ChFiDS_Stripe)&   Stripe,
                          Handle(ChFiDS_SurfData)& Item)
 {
   if (Ref == Item) 
-    Standard_Failure::Raise("InsertBefore : twice the same surfdata.");
+    throw Standard_Failure("InsertBefore : twice the same surfdata.");
   
   ChFiDS_SequenceOfSurfData& Seq = 
     Stripe->ChangeSetOfSurfData()->ChangeSequence();
@@ -2054,7 +2051,7 @@ void ChFi3d_Builder::PerformSetOfSurfOnElSpine
        if(forward) Guide.FirstParameter(wf);
        else Guide.LastParameter(wl);
       }
-      else Standard_Failure::Raise("PerformSetOfSurfOnElSpine : Chaining is impossible.");
+      else throw Standard_Failure("PerformSetOfSurfOnElSpine : Chaining is impossible.");
     }
     
     // Definition of the domain of patch It1, It2
@@ -2188,7 +2185,7 @@ void ChFi3d_Builder::PerformSetOfSurfOnElSpine
       }
       else { // Otherwise invalidation of the stripe.
         Spine->SetErrorStatus(ChFiDS_WalkingFailure);
-       Standard_Failure::Raise("CallPerformSurf : Path failed!");
+       throw Standard_Failure("CallPerformSurf : Path failed!");
       }
     }
     
@@ -2581,7 +2578,7 @@ void ChFi3d_Builder::PerformSetOfKGen(Handle(ChFiDS_Stripe)& Stripe,
       Standard_Boolean possibleon2 = (don2 < 2*(ddeb + dfin));
       if((tw1 && !possibleon1) || (tw2 && !possibleon2)) {
         Spine->SetErrorStatus(ChFiDS_TwistedSurface);
-       Standard_Failure::Raise("adjustment by reprocessing the non-written points");
+       throw Standard_Failure("adjustment by reprocessing the non-written points");
       }
       
       // It is checked if there are presentable neighbors
@@ -2616,8 +2613,7 @@ void ChFi3d_Builder::PerformSetOfKGen(Handle(ChFiDS_Stripe)& Stripe,
       if(tw1){
        if(!yaprevon1 || !yanexton1){
           Spine->SetErrorStatus(ChFiDS_TwistedSurface);
-         Standard_Failure::Raise
-           ("adjustment by reprocessing the non-written points: no neighbor");
+         throw Standard_Failure("adjustment by reprocessing the non-written points: no neighbor");
        }
        ChFiDS_FaceInterference& previntf1 = prevsd->ChangeInterferenceOnS1();
        ChFiDS_FaceInterference& nextintf1 = nextsd->ChangeInterferenceOnS1();
@@ -2675,8 +2671,7 @@ void ChFi3d_Builder::PerformSetOfKGen(Handle(ChFiDS_Stripe)& Stripe,
       }
       if(tw2){
        if(!yaprevon2 || !yanexton2){
-         Standard_Failure::Raise
-           ("adjustment by reprocessing the non-written points: no neighbor");
+         throw Standard_Failure("adjustment by reprocessing the non-written points: no neighbor");
        }
        ChFiDS_FaceInterference& previntf2 = prevsd->ChangeInterferenceOnS2();
        ChFiDS_FaceInterference& nextintf2 = nextsd->ChangeInterferenceOnS2();
index 3579aa8..b63ad08 100644 (file)
@@ -638,7 +638,7 @@ void ChFi3d_Builder::PerformOneCorner(const Standard_Integer Index,
 
   if (onsame) {
     if (!CV1.IsOnArc() && !CV2.IsOnArc())
-      Standard_Failure::Raise("Corner OnSame : no point on arc");
+      throw Standard_Failure("Corner OnSame : no point on arc");
     else if (CV1.IsOnArc() && CV2.IsOnArc()) {
        Standard_Boolean sur1 = 0, sur2 = 0;
       for(ex.Init(CV1.Arc(),TopAbs_VERTEX); ex.More(); ex.Next()) {
@@ -699,8 +699,7 @@ void ChFi3d_Builder::PerformOneCorner(const Standard_Integer Index,
       }
     }
 
-    if (Fv.IsNull()) StdFail_NotDone::Raise
-      ("OneCorner : face at end not found");
+    if (Fv.IsNull()) throw StdFail_NotDone("OneCorner : face at end not found");
 
     Fv.Orientation(TopAbs_FORWARD);
     Fad.Orientation(TopAbs_FORWARD);
@@ -718,8 +717,7 @@ void ChFi3d_Builder::PerformOneCorner(const Standard_Integer Index,
        }
       }
     }
-    if (Arcprol.IsNull()) /*StdFail_NotDone::Raise
-      ("OneCorner : edge a prolonger non trouve");*/
+    if (Arcprol.IsNull()) /*throw StdFail_NotDone("OneCorner : edge a prolonger non trouve");*/
     {
       PerformIntersectionAtEnd(Index);
       return;
@@ -857,7 +855,7 @@ void ChFi3d_Builder::PerformOneCorner(const Standard_Integer Index,
     if (!ChFi3d_ComputeCurves(HGs,HBs,Pardeb,Parfin,Cc,
                              Ps,
                              Pc,tolesp,tol2d,tolreached))
-      Standard_Failure::Raise("OneCorner : echec calcul intersection");
+      throw Standard_Failure("OneCorner : echec calcul intersection");
 
     Udeb = Cc->FirstParameter();
     Ufin = Cc->LastParameter();
@@ -909,7 +907,7 @@ void ChFi3d_Builder::PerformOneCorner(const Standard_Integer Index,
     }
   }
   else { // (!inters)
-    Standard_NotImplemented::Raise("OneCorner : bouchon non ecrit");
+    throw Standard_NotImplemented("OneCorner : bouchon non ecrit");
   }
   Standard_Integer IShape = DStr.AddShape(Fv);
   TopAbs_Orientation Et = TopAbs_FORWARD;
@@ -1010,7 +1008,7 @@ void ChFi3d_Builder::PerformOneCorner(const Standard_Integer Index,
                               tol2d, Precision::PConfusion());
        if (anIntersector.NbSegments() > 0 ||
            anIntersector.NbPoints() > 0)
-         StdFail_NotDone::Raise ("OneCorner : fillets have too big radiuses");
+         throw StdFail_NotDone("OneCorner : fillets have too big radiuses");
       }
     }
     TopOpeBRepDS_ListIteratorOfListOfInterference
@@ -1035,7 +1033,7 @@ void ChFi3d_Builder::PerformOneCorner(const Standard_Integer Index,
                             tol2d, Precision::PConfusion());
       if (anIntersector.NbSegments() > 0 ||
          anIntersector.NbPoints() > 0)
-       StdFail_NotDone::Raise ("OneCorner : fillets have too big radiuses");
+       throw StdFail_NotDone("OneCorner : fillets have too big radiuses");
     }
     // 31/01/02 akm ^^^
     DStr.ChangeShapeInterferences(IShape).Append(Interfc);
@@ -1268,7 +1266,7 @@ void ChFi3d_Builder::PerformOneCorner(const Standard_Integer Index,
     //Standard_Real tolreached;
     if (!ChFi3d_ComputeCurves(HBop,HBs,Pardeb,Parfin,zob3d,zob2dop,
                              zob2dv,tolesp,tol2d,tolreached))
-      Standard_Failure::Raise("OneCorner : echec calcul intersection");
+      throw Standard_Failure("OneCorner : echec calcul intersection");
 
     Udeb = zob3d->FirstParameter();
     Ufin = zob3d->LastParameter();
@@ -1970,8 +1968,7 @@ void ChFi3d_Builder::PerformIntersectionAtEnd(const Standard_Integer Index)
          ChFi3d_cherche_face1(myEFMap(E),F1,Face[nb]);
          cherche_edge1(Face[nb-1],Face[nb],Edge[nb]);
          nb++;
-         if (nb>=nn) Standard_Failure::Raise
-           ("IntersectionAtEnd : the max number of faces reached");
+         if (nb>=nn) throw Standard_Failure("IntersectionAtEnd : the max number of faces reached");
        }
        if (!findonf2)  Edge[nb]=CV2.Arc();
       }
@@ -1992,8 +1989,7 @@ void ChFi3d_Builder::PerformIntersectionAtEnd(const Standard_Integer Index)
          ChFi3d_cherche_face1(myEFMap(E),F2,Face[nb]);
          cherche_edge1(Face[nb-1],Face[nb],Edge[nb]);
          nb++;
-         if (nb>=nn) Standard_Failure::Raise
-           ("IntersectionAtEnd : the max number of faces reached");
+         if (nb>=nn) throw Standard_Failure("IntersectionAtEnd : the max number of faces reached");
        }
        Edge[nb]=CV2.Arc();
       }
@@ -2159,7 +2155,7 @@ void ChFi3d_Builder::PerformIntersectionAtEnd(const Standard_Integer Index)
         ChFiDS_FaceInterference& Fi = Fd->ChangeInterferenceOnS1();
         if (!IntersUpdateOnSame (HGs,HBs,c3df,F1,Face[0],Edge[0],Vtx,isfirst,10*tolesp, // in
                                 Fi,CV1,pfac1,Ufi))   // out
-         Standard_Failure::Raise("IntersectionAtEnd: pb intersection Face - Fi");
+         throw Standard_Failure("IntersectionAtEnd: pb intersection Face - Fi");
         Fi1 = Fi;
         if (intersOnSameFailed) { // probable at fillet building
          // look for paredge2
@@ -2357,7 +2353,7 @@ void ChFi3d_Builder::PerformIntersectionAtEnd(const Standard_Integer Index)
          }
        }
       }
-      else Standard_Failure::Raise("IntersectionAtEnd: pb intersection Face cb");
+      else throw Standard_Failure("IntersectionAtEnd: pb intersection Face cb");
     }
     else {
       Hc2 = BRep_Tool::CurveOnSurface(E2,Face[nbface-1],Ubid,Ubid);
@@ -2401,7 +2397,7 @@ void ChFi3d_Builder::PerformIntersectionAtEnd(const Standard_Integer Index)
       ChFiDS_FaceInterference& Fi = Fd->ChangeInterferenceOnS2();
       if (!IntersUpdateOnSame (HGs,HBs,c3df,F2,F,Edge[nb],Vtx,isfirst,10*tolesp, // in
                               Fi,CV2,pfac2,Ufi))   // out
-       Standard_Failure::Raise("IntersectionAtEnd: pb intersection Face - Fi");
+       throw Standard_Failure("IntersectionAtEnd: pb intersection Face - Fi");
       Fi2 = Fi;
       if (intersOnSameFailed) { // probable at fillet building
         // look for paredge2
@@ -2600,7 +2596,7 @@ void ChFi3d_Builder::PerformIntersectionAtEnd(const Standard_Integer Index)
         else if (containV(F1,V2) || containV(F2,V2))
           ori=TopAbs_REVERSED;
         else
-         Standard_Failure::Raise("IntersectionAtEnd : pb orientation");
+         throw Standard_Failure("IntersectionAtEnd : pb orientation");
 
         if (containV(F1,V1) && containV(F1,V2)) {
           dist1=(BRep_Tool::Pnt(V1)).Distance(BRep_Tool::Pnt(Vtx));
@@ -3835,7 +3831,7 @@ void ChFi3d_Builder::IntersectMoreCorner(const Standard_Integer Index)
 #endif
   {
     if(!CV1.IsOnArc() && !CV2.IsOnArc())
-      Standard_Failure::Raise("Corner intersmore : no point on arc");
+      throw Standard_Failure("Corner intersmore : no point on arc");
     else if(CV1.IsOnArc() && CV2.IsOnArc()){
       Standard_Boolean sur2 = 0;
       for(ex.Init(CV1.Arc(),TopAbs_VERTEX); ex.More(); ex.Next()){
@@ -3890,8 +3886,7 @@ void ChFi3d_Builder::IntersectMoreCorner(const Standard_Integer Index)
       }
     }
 
-    if(Fv.IsNull()) StdFail_NotDone::Raise
-      ("OneCorner : face at end is not found");
+    if(Fv.IsNull()) throw StdFail_NotDone("OneCorner : face at end is not found");
 
     Fv.Orientation(TopAbs_FORWARD);
     Fad.Orientation(TopAbs_FORWARD);
@@ -3917,8 +3912,7 @@ void ChFi3d_Builder::IntersectMoreCorner(const Standard_Integer Index)
     cherche_face(myVFMap(Vtx),Arcprol,Fad,Fv,Fv,Fopbis);
     Fop.Orientation(TopAbs_FORWARD);
 
-    if(Arcprol.IsNull()) StdFail_NotDone::Raise
-      ("OneCorner : edge to be extended is not found");
+    if(Arcprol.IsNull()) throw StdFail_NotDone("OneCorner : edge to be extended is not found");
     for(ex.Init(Fopbis,TopAbs_EDGE); ex.More(); ex.Next()){
       if(Arcprol.IsSame(ex.Current())) {
        OArcprolop = ex.Current().Orientation();
@@ -4046,7 +4040,7 @@ void ChFi3d_Builder::IntersectMoreCorner(const Standard_Integer Index)
     if (!ChFi3d_ComputeCurves(HGs,HBs,Pardeb,Parfin,Cc,
                              Ps,
                              Pc,tolesp,tol2d,tolreached))
-    Standard_Failure::Raise("OneCorner : failed calculation intersection");
+    throw Standard_Failure("OneCorner : failed calculation intersection");
 
     Udeb = Cc->FirstParameter();
     Ufin = Cc->LastParameter();
@@ -4099,7 +4093,7 @@ void ChFi3d_Builder::IntersectMoreCorner(const Standard_Integer Index)
   }
 
   else{
-    Standard_NotImplemented::Raise("OneCorner : cap not written");
+    throw Standard_NotImplemented("OneCorner : cap not written");
   }
   Standard_Integer IShape = DStr.AddShape(Fv);
   TopAbs_Orientation Et = TopAbs_FORWARD;
@@ -4314,7 +4308,7 @@ void ChFi3d_Builder::IntersectMoreCorner(const Standard_Integer Index)
 //    Standard_Real tolreached;
     if (!ChFi3d_ComputeCurves(HBop,HBs,Pardeb,Parfin,zob3d,zob2dop,
                              zob2dv,tolesp,tol2d,tolreached))
-      Standard_Failure::Raise("OneCorner : echec calcul intersection");
+      throw Standard_Failure("OneCorner : echec calcul intersection");
 
     Udeb = zob3d->FirstParameter();
     Ufin = zob3d->LastParameter();
index a2c40e2..cb5a341 100644 (file)
@@ -1138,8 +1138,7 @@ void  ChFi3d_Builder::PerformMoreThreeCorner(const Standard_Integer Jndex,
       nbcouture++;
     }
     else ChFi3d_cherche_edge(V1,Evive,Fcur,Enext,VV);
-    if (Enext.IsNull())Standard_Failure::Raise
-    ("PerformMoreThreeCorner: pb in the parsing of edges and faces"); 
+    if (Enext.IsNull())throw Standard_Failure("PerformMoreThreeCorner: pb in the parsing of edges and faces");
     if (Enext.IsSame(edgelibre1)|| Enext.IsSame(edgelibre2)) {
       CD.SetValue(ii, cdbid);
       Index.SetValue(ii, 0);
index 87f0f76..f7b8237 100644 (file)
@@ -78,7 +78,7 @@ void  ChFi3d_Builder::SimulSurf(Handle(ChFiDS_SurfData)&            ,
                                const Standard_Boolean              ,
                                const math_Vector&                  )
 {
-  Standard_Failure::Raise("SimulSurf Not Implemented");
+  throw Standard_Failure("SimulSurf Not Implemented");
 }
 
 //=======================================================================
@@ -111,7 +111,7 @@ void  ChFi3d_Builder::SimulSurf(Handle(ChFiDS_SurfData)&            ,
                                const Standard_Boolean              ,
                                const math_Vector&                  )
 {
-  Standard_Failure::Raise("SimulSurf Not Implemented");
+  throw Standard_Failure("SimulSurf Not Implemented");
 }
 
 
@@ -151,7 +151,7 @@ void  ChFi3d_Builder::SimulSurf(Handle(ChFiDS_SurfData)&            ,
                                const Standard_Boolean              ,
                                const math_Vector&                  )
 {
-  Standard_Failure::Raise("SimulSurf Not Implemented");
+  throw Standard_Failure("SimulSurf Not Implemented");
 }
 
 
@@ -187,7 +187,7 @@ void  ChFi3d_Builder::PerformSurf(ChFiDS_SequenceOfSurfData&          ,
                                  const Standard_Boolean              ,
                                  const math_Vector&                  )
 {
-  Standard_Failure::Raise("PerformSurf Not Implemented");
+  throw Standard_Failure("PerformSurf Not Implemented");
 }
 
 //=======================================================================
@@ -221,7 +221,7 @@ void  ChFi3d_Builder::PerformSurf(ChFiDS_SequenceOfSurfData&          ,
                                  const Standard_Boolean              ,
                                  const math_Vector&                  )
 {
-  Standard_Failure::Raise("PerformSurf Not Implemented");
+  throw Standard_Failure("PerformSurf Not Implemented");
 
 }
 
@@ -266,6 +266,6 @@ void  ChFi3d_Builder::PerformSurf(ChFiDS_SequenceOfSurfData&          ,
                                  const Standard_Boolean              ,
                                  const math_Vector&                  )
 {
-  Standard_Failure::Raise("PerformSurf Not Implemented");
+  throw Standard_Failure("PerformSurf Not Implemented");
 
 }
index 2ca83fa..e086d05 100644 (file)
@@ -301,7 +301,7 @@ void  ChFi3d_ChBuilder::SetDist(const Standard_Real    Dis,
 
     }
     else
-      Standard_DomainError::Raise("the face is not common to any of edges of the contour");
+      throw Standard_DomainError("the face is not common to any of edges of the contour");
 
   }
 }
@@ -440,7 +440,7 @@ void  ChFi3d_ChBuilder::SetDists(const Standard_Real    Dis1,
       else csp->SetDists(Dis1,Dis2);
     }
     else
-      Standard_DomainError::Raise("the face is not common to any of edges of the contour");
+      throw Standard_DomainError("the face is not common to any of edges of the contour");
 
   }
 }
@@ -589,7 +589,7 @@ void  ChFi3d_ChBuilder::SetDistAngle(const Standard_Real    Dis,
       }
     }
     else
-      Standard_DomainError::Raise("the face is not common to any edges of the contour");
+      throw Standard_DomainError("the face is not common to any edges of the contour");
 
   }
 }
@@ -808,8 +808,7 @@ ChFi3d_ChBuilder::SimulSurf(Handle(ChFiDS_SurfData)&            Data,
     chsp = Handle(ChFiDS_ChamfSpine)::DownCast(Spine);
   
   if (chsp.IsNull()) 
-    Standard_ConstructionError::Raise
-      ("SimulSurf : this is not the spine of a chamfer");
+    throw Standard_ConstructionError("SimulSurf : this is not the spine of a chamfer");
 
 
   Standard_Real radius;
@@ -1204,7 +1203,7 @@ void  ChFi3d_ChBuilder::SimulSurf(Handle(ChFiDS_SurfData)&            ,
                                const Standard_Boolean              ,
                                const math_Vector&                  )
 {
-  Standard_Failure::Raise("SimulSurf Not Implemented");
+  throw Standard_Failure("SimulSurf Not Implemented");
 }
 void  ChFi3d_ChBuilder::SimulSurf(Handle(ChFiDS_SurfData)&            ,
                                const Handle(ChFiDS_HElSpine)&      , 
@@ -1231,7 +1230,7 @@ void  ChFi3d_ChBuilder::SimulSurf(Handle(ChFiDS_SurfData)&            ,
                                const Standard_Boolean              ,
                                const math_Vector&                  )
 {
-  Standard_Failure::Raise("SimulSurf Not Implemented");
+  throw Standard_Failure("SimulSurf Not Implemented");
 }
 void  ChFi3d_ChBuilder::SimulSurf(Handle(ChFiDS_SurfData)&            ,
                                const Handle(ChFiDS_HElSpine)&      ,
@@ -1264,7 +1263,7 @@ void  ChFi3d_ChBuilder::SimulSurf(Handle(ChFiDS_SurfData)&            ,
                                const Standard_Boolean              ,
                                const math_Vector&                  )
 {
-  Standard_Failure::Raise("SimulSurf Not Implemented");
+  throw Standard_Failure("SimulSurf Not Implemented");
 }
 //------------------------MODIFS---------------------------------------
 //=======================================================================
@@ -1289,8 +1288,7 @@ Standard_Boolean ChFi3d_ChBuilder::PerformFirstSection
     chsp = Handle(ChFiDS_ChamfSpine)::DownCast(Spine);
   
   if (chsp.IsNull()) 
-    Standard_ConstructionError::Raise
-      ("PerformSurf : this is not the spine of a chamfer");
+    throw Standard_ConstructionError("PerformSurf : this is not the spine of a chamfer");
 
   Standard_Real TolGuide = HGuide->Resolution(tolesp) ;
 
@@ -1602,8 +1600,7 @@ ChFi3d_ChBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          SeqData,
     chsp = Handle(ChFiDS_ChamfSpine)::DownCast(Spine);
   
   if (chsp.IsNull()) 
-    Standard_ConstructionError::Raise
-      ("PerformSurf : this is not the spine of a chamfer");
+    throw Standard_ConstructionError("PerformSurf : this is not the spine of a chamfer");
   
   Standard_Boolean gd1,gd2,gf1,gf2;
   Handle(BRepBlend_Line) lin;
@@ -1626,7 +1623,7 @@ ChFi3d_ChBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          SeqData,
                       gd1,gd2,gf1,gf2,RecOnS1,RecOnS2);
     if(!done) return Standard_False; // ratrappage possible PMN 14/05/1998
     done = CompleteData(Data,Func,lin,S1,S2,Or,gd1,gd2,gf1,gf2);
-    if(!done) Standard_Failure::Raise("PerformSurf : Fail of approximation!");
+    if(!done) throw Standard_Failure("PerformSurf : Fail of approximation!");
   }
   else if (chsp->IsChamfer() == ChFiDS_TwoDist) {
     BRepBlend_Chamfer  Func(S1,S2,HGuide);
@@ -1642,7 +1639,7 @@ ChFi3d_ChBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          SeqData,
                       gd1,gd2,gf1,gf2,RecOnS1,RecOnS2);
     if(!done) return Standard_False; // ratrappage possible PMN 14/05/1998
     done = CompleteData(Data,Func,lin,S1,S2,Or,gd1,gd2,gf1,gf2);
-    if(!done) Standard_Failure::Raise("PerformSurf : Fail of approximation!");
+    if(!done) throw Standard_Failure("PerformSurf : Fail of approximation!");
   }
   else {
     Standard_Real d1, angle;
@@ -1664,7 +1661,7 @@ ChFi3d_ChBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          SeqData,
 
       if(!done) return Standard_False; // ratrappage possible PMN 14/05/1998
       done = CompleteData(Data,Func,lin,S1,S2,Or,gd1,gd2,gf1,gf2);
-      if(!done) Standard_Failure::Raise("PerformSurf : Fail of approximation!");
+      if(!done) throw Standard_Failure("PerformSurf : Fail of approximation!");
     }
     else {
       Standard_Real Rtemp;
@@ -1695,7 +1692,7 @@ ChFi3d_ChBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          SeqData,
       Data->ChangeVertexLastOnS2() = tmp;
       if(!done) return Standard_False; // ratrappage possible PMN 14/05/1998
       done = CompleteData(Data,Func,lin,S1,S2,Or2,gd1,gd2,gf1,gf2, Standard_True);
-      if(!done) Standard_Failure::Raise("PerformSurf : Fail of approximation!");
+      if(!done) throw Standard_Failure("PerformSurf : Fail of approximation!");
     }      
 
   }
@@ -1727,7 +1724,7 @@ void  ChFi3d_ChBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          ,
                                  const Standard_Boolean              ,
                                  const math_Vector&                  )
 {
-  Standard_Failure::Raise("PerformSurf Not Implemented");
+  throw Standard_Failure("PerformSurf Not Implemented");
 }
 void  ChFi3d_ChBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          ,
                                  const Handle(ChFiDS_HElSpine)&      , 
@@ -1755,7 +1752,7 @@ void  ChFi3d_ChBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          ,
                                  const Standard_Boolean              ,
                                  const math_Vector&                  )
 {
-  Standard_Failure::Raise("PerformSurf Not Implemented");
+  throw Standard_Failure("PerformSurf Not Implemented");
 
 }
 void  ChFi3d_ChBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          ,
@@ -1790,7 +1787,7 @@ void  ChFi3d_ChBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          ,
                                  const Standard_Boolean              ,
                                  const math_Vector&                  )
 {
-  Standard_Failure::Raise("PerformSurf Not Implemented");
+  throw Standard_Failure("PerformSurf Not Implemented");
 
 }
 //=======================================================================
index 0b496f6..7dca1c2 100644 (file)
@@ -315,9 +315,9 @@ void ChFi3d_ChBuilder::PerformThreeCorner(const Standard_Integer Jndex)
     deb = (pivot+1)%3 ; fin = (pivot+2)%3;
     CornerAllSame = Standard_True;
   } 
-  else Standard_Failure::Raise("FD en vis a vis non trouvees");
+  else throw Standard_Failure("FD en vis a vis non trouvees");
   if (!okinter)
-     Standard_Failure::Raise("Echec intersection PCurves OnCommonFace");
+     throw Standard_Failure("Echec intersection PCurves OnCommonFace");
 
   // on a le pivot, le CD deb et le CD fin (enfin on espere !?!) :
   // -------------------------------------------------------------
@@ -328,7 +328,7 @@ void ChFi3d_ChBuilder::PerformThreeCorner(const Standard_Integer Jndex)
      cheminement et creations de Surf data mutantes a 3 ou 5 cotes!!!
      NON TRAITE !!!!!! (pour l instant)*/
   if(i[pivot][deb] != i[pivot][fin]){
-    Standard_NotImplemented::Raise("coin mutant non programme");
+    throw Standard_NotImplemented("coin mutant non programme");
   }
   /* Autre Remarque : dans le cas ou les indices des Surf data
      du deb (de la fin) sur lesquelles ont ete trouvees les intersections
@@ -337,7 +337,7 @@ void ChFi3d_ChBuilder::PerformThreeCorner(const Standard_Integer Jndex)
      PerformSetOfSurf adapte.*/
   if(oksea[pivot] && 
      (i[deb][pivot] != i[deb][fin] || i[fin][pivot] != i[fin][deb])){
-    Standard_NotImplemented::Raise("coin sur plusieurs faces non programme");
+    throw Standard_NotImplemented("coin sur plusieurs faces non programme");
   }
   
   Handle(ChFiDS_SurfData)& 
@@ -501,7 +501,7 @@ void ChFi3d_ChBuilder::PerformThreeCorner(const Standard_Integer Jndex)
                             p3d[fin],p2d[fin],p3d[deb],p2d[deb],
                             gcpiv,pivpc1,pivpc2,deru,derv,ptbid,
                             tolesp,tol2d,tolrcoinpiv))
-      StdFail_NotDone::Raise("echec calcul intersection coin-pivot");
+      throw StdFail_NotDone("echec calcul intersection coin-pivot");
     gp_Vec norpiv = deru.Crossed(derv);
     
     //intersection coin-deb
@@ -518,7 +518,7 @@ void ChFi3d_ChBuilder::PerformThreeCorner(const Standard_Integer Jndex)
                             p3d[pivot],p2d1,p3d[fin],p2d2,
                             gcdeb,debpc1,debpc2,deru,derv,ptbid,
                             tolesp,tol2d,tolrcoindeb))
-      StdFail_NotDone::Raise("echec calcul intersection coin-deb"); 
+      throw StdFail_NotDone("echec calcul intersection coin-deb");
     Icf = DStr.AddCurve(TopOpeBRepDS_Curve(gcdeb,tolrcoindeb));    
 
     //intersection coin-fin
@@ -537,7 +537,7 @@ void ChFi3d_ChBuilder::PerformThreeCorner(const Standard_Integer Jndex)
                             p3dface,p2d1,p3d[deb],p2d2,
                             gcfin,finpc1,finpc2,deru,derv,ptbid,
                             tolesp,tol2d,tolrcoinfin)) 
-      StdFail_NotDone::Raise("echec calcul intersection coin-face");
+      throw StdFail_NotDone("echec calcul intersection coin-face");
     Icl = DStr.AddCurve(TopOpeBRepDS_Curve(gcfin,tolrcoinfin));  
     
     //!c1triangle: intersection coin-face[pivot]
index 6724171..b7b1d89 100644 (file)
@@ -620,8 +620,7 @@ ChFi3d_FilBuilder::SimulSurf(Handle(ChFiDS_SurfData)&            Data,
                             Standard_Integer&                   intl)
 {
   Handle(ChFiDS_FilSpine) fsp = Handle(ChFiDS_FilSpine)::DownCast(Spine);
-  if(fsp.IsNull()) Standard_ConstructionError::Raise
-    ("SimulSurf : this is not the spine of the fillet");
+  if(fsp.IsNull()) throw Standard_ConstructionError("SimulSurf : this is not the spine of the fillet");
   Handle(BRepBlend_Line) lin;
 #ifdef OCCT_DEBUG
 //  TopAbs_Orientation Or = S1->ChangeSurface().Face().Orientation();
@@ -766,8 +765,7 @@ void  ChFi3d_FilBuilder::SimulSurf(Handle(ChFiDS_SurfData)&            Data,
                                   const math_Vector&                  Soldep)
 {
   Handle(ChFiDS_FilSpine) fsp = Handle(ChFiDS_FilSpine)::DownCast(Spine);
-  if(fsp.IsNull()) Standard_ConstructionError::Raise
-    ("PerformSurf : this is not the spine of the fillet");
+  if(fsp.IsNull()) throw Standard_ConstructionError("PerformSurf : this is not the spine of the fillet");
   Handle(BRepBlend_Line) lin;
   
   // Flexible parameters!
@@ -802,7 +800,7 @@ void  ChFi3d_FilBuilder::SimulSurf(Handle(ChFiDS_SurfData)&            Data,
                     PFirst,MaxStep,locfleche,TolGuide,First,Last,
                     Soldep,4,Inside,Appro,Forward,RecP,RecS,RecRst);
     if(!done) {
-      Standard_Failure::Raise("SimulSurf : Failed process!");
+      throw Standard_Failure("SimulSurf : Failed process!");
     }
     Standard_Integer nbp = lin->NbPoints();
     sec = new ChFiDS_SecHArray1(1,nbp);
@@ -840,7 +838,7 @@ void  ChFi3d_FilBuilder::SimulSurf(Handle(ChFiDS_SurfData)&            Data,
                     func,finv,finvp,finvc,
                     PFirst,MaxStep,locfleche,TolGuide,First,Last,
                     Soldep,4,Inside,Appro,Forward,RecP,RecS,RecRst);
-    if(!done) Standard_Failure::Raise("SimulSurf : Fail !");
+    if(!done) throw Standard_Failure("SimulSurf : Fail !");
     Standard_Integer nbp = lin->NbPoints();
     sec = new ChFiDS_SecHArray1(1,nbp);
     for(Standard_Integer i = 1; i <= nbp; i++){
@@ -901,8 +899,7 @@ void  ChFi3d_FilBuilder::SimulSurf(Handle(ChFiDS_SurfData)&            Data,
                                   const math_Vector&                  Soldep)
 {
   Handle(ChFiDS_FilSpine) fsp = Handle(ChFiDS_FilSpine)::DownCast(Spine);
-  if(fsp.IsNull()) Standard_ConstructionError::Raise
-    ("PerformSurf : it is not the spine of a fillet");
+  if(fsp.IsNull()) throw Standard_ConstructionError("PerformSurf : it is not the spine of a fillet");
   Handle(BRepBlend_Line) lin;
   
   // Flexible parameters!
@@ -936,7 +933,7 @@ void  ChFi3d_FilBuilder::SimulSurf(Handle(ChFiDS_SurfData)&            Data,
                     func,finv,finvp,finvc,
                     PFirst,MaxStep,locfleche,TolGuide,First,Last,
                     Soldep,4,Inside,Appro,Forward,RecP,RecS,RecRst);
-    if(!done) Standard_Failure::Raise("SimulSurf : Failed Processing!");
+    if(!done) throw Standard_Failure("SimulSurf : Failed Processing!");
     Standard_Integer nbp = lin->NbPoints();
     sec = new ChFiDS_SecHArray1(1,nbp);
     for(Standard_Integer i = 1; i <= nbp; i++){
@@ -973,7 +970,7 @@ void  ChFi3d_FilBuilder::SimulSurf(Handle(ChFiDS_SurfData)&            Data,
                     func,finv,finvp,finvc,
                     PFirst,MaxStep,locfleche,TolGuide,First,Last,
                     Soldep,4,Inside,Appro,Forward,RecP,RecS,RecRst);
-    if(!done) Standard_Failure::Raise("SimulSurf : Fail !");
+    if(!done) throw Standard_Failure("SimulSurf : Fail !");
     Standard_Integer nbp = lin->NbPoints();
     sec = new ChFiDS_SecHArray1(1,nbp);
     for(Standard_Integer i = 1; i <= nbp; i++){
@@ -1042,8 +1039,7 @@ void  ChFi3d_FilBuilder::SimulSurf(Handle(ChFiDS_SurfData)&            Data,
                                   const math_Vector&                  Soldep)
 {
   Handle(ChFiDS_FilSpine) fsp = Handle(ChFiDS_FilSpine)::DownCast(Spine);
-  if(fsp.IsNull()) Standard_ConstructionError::Raise
-    ("PerformSurf : it is not the spine of a fillet");
+  if(fsp.IsNull()) throw Standard_ConstructionError("PerformSurf : it is not the spine of a fillet");
   Handle(BRepBlend_Line) lin;
   
   // Flexible parameters!
@@ -1086,7 +1082,7 @@ void  ChFi3d_FilBuilder::SimulSurf(Handle(ChFiDS_SurfData)&            Data,
                     func, finv1, finvp1, finv2, finvp2,
                     PFirst, MaxStep, locfleche, TolGuide, First, Last,
                     Soldep, 4, Inside, Appro, Forward, RecP1, RecRst1, RecP2, RecRst2);
-    if(!done) Standard_Failure::Raise("SimulSurf : Failed processing!");
+    if(!done) throw Standard_Failure("SimulSurf : Failed processing!");
     Standard_Integer nbp = lin->NbPoints();
     sec = new ChFiDS_SecHArray1(1,nbp);
     for(Standard_Integer i = 1; i <= nbp; i++){
@@ -1137,7 +1133,7 @@ void  ChFi3d_FilBuilder::SimulSurf(Handle(ChFiDS_SurfData)&            Data,
                     PFirst, MaxStep, locfleche, TolGuide, First, Last,
                     Soldep, 4, Inside, Appro, Forward, RecP1, RecRst1, RecP2, RecRst2);
 
-    if(!done) Standard_Failure::Raise("SimulSurf : Fail !");
+    if(!done) throw Standard_Failure("SimulSurf : Fail !");
     Standard_Integer nbp = lin->NbPoints();
     sec = new ChFiDS_SecHArray1(1, nbp);
     for(Standard_Integer i = 1; i <= nbp; i++){
@@ -1193,8 +1189,7 @@ Standard_Boolean ChFi3d_FilBuilder::PerformFirstSection
  TopAbs_State&                       Pos2) const 
 {
   Handle(ChFiDS_FilSpine) fsp = Handle(ChFiDS_FilSpine)::DownCast(Spine);
-  if(fsp.IsNull()) Standard_ConstructionError::Raise
-    ("PerformSurf : this is not the spine of a fillet");
+  if(fsp.IsNull()) throw Standard_ConstructionError("PerformSurf : this is not the spine of a fillet");
   Standard_Real TolGuide = HGuide->Resolution(tolesp);
   if(fsp->IsConstant()){
     BRepBlend_ConstRad Func(S1,S2,HGuide);
@@ -1247,8 +1242,7 @@ ChFi3d_FilBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          SeqData,
 #endif
   Handle(ChFiDS_SurfData) Data = SeqData(1);
   Handle(ChFiDS_FilSpine) fsp = Handle(ChFiDS_FilSpine)::DownCast(Spine);
-  if(fsp.IsNull()) Standard_ConstructionError::Raise
-    ("PerformSurf : this is not the spine of a fillet");
+  if(fsp.IsNull()) throw Standard_ConstructionError("PerformSurf : this is not the spine of a fillet");
   Standard_Boolean gd1,gd2,gf1,gf2, maybesingular;
   Handle(BRepBlend_Line) lin;
   TopAbs_Orientation Or = S1->ChangeSurface().Face().Orientation();
@@ -1287,7 +1281,7 @@ ChFi3d_FilBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          SeqData,
          ChFi3d_ResultChron(ch , t_completedata);// result perf CompleteData
 #endif 
 
-    if(!done) Standard_Failure::Raise("PerformSurf : Failed approximation!");
+    if(!done) throw Standard_Failure("PerformSurf : Failed approximation!");
     maybesingular = (Func.GetMinimalDistance()<=100*tolapp3d);
   }
   else {
@@ -1321,7 +1315,7 @@ ChFi3d_FilBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          SeqData,
          ChFi3d_ResultChron(ch , t_completedata);// result perf CompleteData
 #endif 
 
-    if(!done) Standard_Failure::Raise("PerformSurf : Failed approximation!");
+    if(!done) throw Standard_Failure("PerformSurf : Failed approximation!");
     maybesingular = (Func.GetMinimalDistance()<=100*tolapp3d); 
   }
   if (maybesingular) SplitSurf(SeqData, lin);
@@ -1361,8 +1355,7 @@ void  ChFi3d_FilBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          SeqData
 {
   Handle(ChFiDS_SurfData)  Data = SeqData(1);
   Handle(ChFiDS_FilSpine) fsp = Handle(ChFiDS_FilSpine)::DownCast(Spine);
-  if(fsp.IsNull()) Standard_ConstructionError::Raise
-    ("PerformSurf : this is not the spine of a fillet");
+  if(fsp.IsNull()) throw Standard_ConstructionError("PerformSurf : this is not the spine of a fillet");
   Handle(BRepBlend_Line) lin;
   Standard_Real PFirst = First;
   Standard_Boolean maybesingular;
@@ -1393,11 +1386,11 @@ void  ChFi3d_FilBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          SeqData
                       Soldep,Inside,Appro,Forward,RecP,RecS,RecRst);
     if(!done) {
        Spine->SetErrorStatus(ChFiDS_WalkingFailure); 
-       Standard_Failure::Raise("PerformSurf : Failed processing!");
+       throw Standard_Failure("PerformSurf : Failed processing!");
     }
     TopAbs_Orientation Or = HS2->ChangeSurface().Face().Orientation();
     done = CompleteData(Data,func,lin,HS1,HS2,Or,1);
-    if(!done) Standard_Failure::Raise("PerformSurf : Failed approximation!");
+    if(!done) throw Standard_Failure("PerformSurf : Failed approximation!");
     maybesingular = (func.GetMinimalDistance()<=100*tolapp3d); 
   }
   else {
@@ -1423,11 +1416,11 @@ void  ChFi3d_FilBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          SeqData
                       Soldep,Inside,Appro,Forward,RecP,RecS,RecRst);
     if(!done) {
       Spine->SetErrorStatus(ChFiDS_WalkingFailure);
-      Standard_Failure::Raise("PerformSurf : Failed processing!");
+      throw Standard_Failure("PerformSurf : Failed processing!");
     }
     TopAbs_Orientation Or = HS2->ChangeSurface().Face().Orientation();
     done = CompleteData(Data,func,lin,HS1,HS2,Or,1);
-    if(!done) Standard_Failure::Raise("PerformSurf : Failed approximation!");
+    if(!done) throw Standard_Failure("PerformSurf : Failed approximation!");
    maybesingular = (func.GetMinimalDistance()<=100*tolapp3d); 
   }
   if (maybesingular) SplitSurf(SeqData, lin);
@@ -1466,8 +1459,7 @@ void  ChFi3d_FilBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          SeqData
 {
   Handle(ChFiDS_SurfData) Data = SeqData(1);;
   Handle(ChFiDS_FilSpine) fsp = Handle(ChFiDS_FilSpine)::DownCast(Spine);
-  if(fsp.IsNull()) Standard_ConstructionError::Raise
-    ("PerformSurf : this is not the spine of a fillet");
+  if(fsp.IsNull()) throw Standard_ConstructionError("PerformSurf : this is not the spine of a fillet");
   Handle(BRepBlend_Line) lin;
   Standard_Real PFirst = First;
   Standard_Boolean maybesingular;
@@ -1498,11 +1490,11 @@ void  ChFi3d_FilBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          SeqData
                       Soldep,Inside,Appro,Forward,RecP,RecS,RecRst);
     if(!done) {
       Spine->SetErrorStatus(ChFiDS_WalkingFailure);
-      Standard_Failure::Raise("PerformSurf : Failed processing!");
+      throw Standard_Failure("PerformSurf : Failed processing!");
     }
     TopAbs_Orientation Or = HS1->ChangeSurface().Face().Orientation();
     done = CompleteData(Data,func,lin,HS1,HS2,Or,0);
-    if(!done) Standard_Failure::Raise("PerformSurf : Failed approximation!");
+    if(!done) throw Standard_Failure("PerformSurf : Failed approximation!");
     maybesingular = (func.GetMinimalDistance()<=100*tolapp3d); 
   }
   else {
@@ -1529,11 +1521,11 @@ void  ChFi3d_FilBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          SeqData
                       Soldep,Inside,Appro,Forward,RecP,RecS,RecRst);
     if(!done) {
       Spine->SetErrorStatus(ChFiDS_WalkingFailure);
-      Standard_Failure::Raise("PerformSurf : Failed processing!");
+      throw Standard_Failure("PerformSurf : Failed processing!");
     }
     TopAbs_Orientation Or = HS1->ChangeSurface().Face().Orientation();
     done = CompleteData(Data,func,lin,HS1,HS2,Or,0);
-    if(!done) Standard_Failure::Raise("PerformSurf : Failed approximation!");
+    if(!done) throw Standard_Failure("PerformSurf : Failed approximation!");
     maybesingular = (func.GetMinimalDistance()<=100*tolapp3d); 
   }
   if (maybesingular) SplitSurf(SeqData, lin); 
@@ -1583,8 +1575,7 @@ void  ChFi3d_FilBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          SeqData
 {
   Handle(ChFiDS_SurfData) Data = SeqData(1);;
   Handle(ChFiDS_FilSpine) fsp = Handle(ChFiDS_FilSpine)::DownCast(Spine);
-  if(fsp.IsNull()) Standard_ConstructionError::Raise
-    ("PerformSurf : this is not the spine of a fillet");
+  if(fsp.IsNull()) throw Standard_ConstructionError("PerformSurf : this is not the spine of a fillet");
   Handle(BRepBlend_Line) lin;
   Standard_Real PFirst = First;
   Standard_Boolean maybesingular;
@@ -1622,11 +1613,11 @@ void  ChFi3d_FilBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          SeqData
                       Soldep, Inside, Appro, Forward, RecP1, RecRst1, RecP2, RecRst2);
     if(!done) {
        Spine->SetErrorStatus(ChFiDS_WalkingFailure);
-       Standard_Failure::Raise("PerformSurf : Failed processing!");
+       throw Standard_Failure("PerformSurf : Failed processing!");
     }
     TopAbs_Orientation Or = HS1->ChangeSurface().Face().Orientation();
     done = CompleteData(Data, func, lin, HS1, HS2, Or);
-    if(!done) Standard_Failure::Raise("PerformSurf : Failed approximation!");
+    if(!done) throw Standard_Failure("PerformSurf : Failed approximation!");
     maybesingular = (func.GetMinimalDistance()<=100*tolapp3d); 
   }
   else {
@@ -1665,11 +1656,11 @@ void  ChFi3d_FilBuilder::PerformSurf(ChFiDS_SequenceOfSurfData&          SeqData
 
     if(!done) {
       Spine->SetErrorStatus(ChFiDS_WalkingFailure);
-      Standard_Failure::Raise("PerformSurf : Failed processing!");
+      throw Standard_Failure("PerformSurf : Failed processing!");
     }
     TopAbs_Orientation Or = HS1->ChangeSurface().Face().Orientation();
     done = CompleteData(Data, func, lin, HS1, HS2, Or);
-    if(!done) Standard_Failure::Raise("PerformSurf : Failed approximation!");
+    if(!done) throw Standard_Failure("PerformSurf : Failed approximation!");
     maybesingular = (func.GetMinimalDistance()<=100*tolapp3d); 
 
 
index 038b873..fc219ee 100644 (file)
@@ -302,7 +302,7 @@ void ChFi3d_FilBuilder::PerformTwoCorner(const Standard_Integer Index)
     Isd1=ChFi3d_IndexOfSurfData(Vtx,st1,Sens1);
     Isd2=ChFi3d_IndexOfSurfData(Vtx,st2,Sens2);
   }
-   // StdFail_NotDone::Raise("TwoCorner : no common face");
+   // throw StdFail_NotDone("TwoCorner : no common face");
   Standard_Integer IFaArc1 = 3-IFaCo1, IFaArc2 = 3-IFaCo2;
   SeqFil1 = st1->ChangeSetOfSurfData()->ChangeSequence();
   SeqFil2 = st2->ChangeSetOfSurfData()->ChangeSequence();
@@ -712,7 +712,7 @@ void ChFi3d_FilBuilder::PerformTwoCorner(const Standard_Integer Index)
     else {
       //it is necessary to make difference with
       if(!OkinterCC) {
-       Standard_Failure::Raise("TwoCorner : No intersection pc pc");
+       throw Standard_Failure("TwoCorner : No intersection pc pc");
       }
       Handle(ChFiDS_Stripe) stsam, stdif;
       Handle(ChFiDS_SurfData) sdsam, sddif;
@@ -732,15 +732,14 @@ void ChFi3d_FilBuilder::PerformTwoCorner(const Standard_Integer Index)
        ifacodif = IFaCo1; ifaopdif = IFaArc1; isfirstdif = isfirst1;
       }
       else {
-       Standard_Failure::Raise("TwoCorner : Config unknown");
+       throw Standard_Failure("TwoCorner : Config unknown");
       }
       //It is checked if surface ondiff has a point on arc from the side opposed
       //to the common face and if this arc is connected to the base face  
       //opposed to common face of the surface onsame.
       ChFiDS_CommonPoint& cpopdif = sddif->ChangeVertex(isfirstdif,ifaopdif);
       if(!cpopdif.IsOnArc()) {
-       Standard_Failure::Raise
-         ("TwoCorner : No point on restriction on surface OnDiff");
+       throw Standard_Failure("TwoCorner : No point on restriction on surface OnDiff");
       }
       const TopoDS_Edge& Arcopdif = cpopdif.Arc();
       const TopoDS_Face& Fopsam = TopoDS::Face(DStr.Shape(sdsam->Index(ifaopsam)));
@@ -750,8 +749,7 @@ void ChFi3d_FilBuilder::PerformTwoCorner(const Standard_Integer Index)
          break;
        }
        else if(!ex.More()) {
-         Standard_Failure::Raise
-           ("TwoCorner : No common face to loop the contour");
+         throw Standard_Failure("TwoCorner : No common face to loop the contour");
        }
       }
 #ifdef OCCT_DEBUG
@@ -828,7 +826,7 @@ void ChFi3d_FilBuilder::PerformTwoCorner(const Standard_Integer Index)
 #ifdef OCCT_DEBUG
       ChFi3d_ResultChron(ch , t_remplissage);// result perf filling 
 #endif 
-      if(!done) Standard_Failure::Raise("concavites inverted : fail");
+      if(!done) throw Standard_Failure("concavites inverted : fail");
 #ifdef OCCT_DEBUG
       ChFi3d_InitChron(ch); // init perf update DS
 #endif 
index cbfd18e..4cb49e9 100644 (file)
@@ -39,7 +39,7 @@ ChFiDS_Spine(Tol)
 
 void ChFiDS_ChamfSpine::GetDist(Standard_Real& Dis) const
 {
-  if (mChamf != ChFiDS_Sym)   Standard_Failure::Raise("Chamfer is not symetric");
+  if (mChamf != ChFiDS_Sym)   throw Standard_Failure("Chamfer is not symetric");
   Dis = d1;
 }
 
@@ -66,7 +66,7 @@ void ChFiDS_ChamfSpine::SetDist(const Standard_Real Dis)
 void ChFiDS_ChamfSpine::Dists(Standard_Real& Dis1,
                              Standard_Real& Dis2)const
 {
-  if (mChamf != ChFiDS_TwoDist)  Standard_Failure::Raise("Chamfer is not a Two Dists Chamfer");
+  if (mChamf != ChFiDS_TwoDist)  throw Standard_Failure("Chamfer is not a Two Dists Chamfer");
   Dis1 = d1;
   Dis2 = d2;
 }
@@ -95,7 +95,7 @@ void ChFiDS_ChamfSpine::GetDistAngle(Standard_Real& Dis,
                                     Standard_Real& Angle,
                                     Standard_Boolean& DisOnF1)const
 {
-  if (mChamf != ChFiDS_DistAngle)  Standard_Failure::Raise("Chamfer is not a Two Dists Chamfer");
+  if (mChamf != ChFiDS_DistAngle)  throw Standard_Failure("Chamfer is not a Two Dists Chamfer");
   Dis     = d1;
   Angle   = angle;
   DisOnF1 = dison1;
index 4b4a29f..528e0f3 100644 (file)
@@ -86,7 +86,7 @@ void  ChFiDS_CommonPoint::SetParameter(const Standard_Real Param)
 const TopoDS_Edge&  ChFiDS_CommonPoint::Arc()const 
 {
   if (!isonarc){
-    Standard_DomainError::Raise("CommonPoint not on Arc"); 
+    throw Standard_DomainError("CommonPoint not on Arc");
   }
   return arc;
 }
@@ -100,7 +100,7 @@ const TopoDS_Edge&  ChFiDS_CommonPoint::Arc()const
 TopAbs_Orientation  ChFiDS_CommonPoint::TransitionOnArc()const 
 {
   if (!isonarc){
-    Standard_DomainError::Raise("CommonPoint not on Arc"); 
+    throw Standard_DomainError("CommonPoint not on Arc");
   }
   return traarc;
 }
@@ -114,7 +114,7 @@ TopAbs_Orientation  ChFiDS_CommonPoint::TransitionOnArc()const
 Standard_Real  ChFiDS_CommonPoint::ParameterOnArc()const 
 {
   if (!isonarc){
-    Standard_DomainError::Raise("CommonPoint not on Arc"); 
+    throw Standard_DomainError("CommonPoint not on Arc");
   }
   return prmarc;
 }
index 35a6523..30249bd 100644 (file)
@@ -88,7 +88,7 @@ inline void  ChFiDS_CommonPoint::SetVertex(const TopoDS_Vertex& V)
 
  inline const TopoDS_Vertex&  ChFiDS_CommonPoint::Vertex()const 
 {
-  if (!isvtx) {Standard_DomainError::Raise();}
+  if (!isvtx) {throw Standard_DomainError();}
   return vtx;
 }
 
@@ -120,7 +120,7 @@ inline void  ChFiDS_CommonPoint::SetVertex(const TopoDS_Vertex& V)
  inline const gp_Vec&  ChFiDS_CommonPoint::Vector()const 
 {
   if (!hasvector) {
-    Standard_DomainError::Raise("ChFiDS_CommonPoint::Vector");
+    throw Standard_DomainError("ChFiDS_CommonPoint::Vector");
   }
   return vector;
 }
index e5d7237..f5c0200 100644 (file)
@@ -182,7 +182,7 @@ void ChFiDS_ElSpine::SetPeriodic(const Standard_Boolean I)
 
 Standard_Real ChFiDS_ElSpine::Period() const
 {
-  if(!periodic) Standard_Failure::Raise("ElSpine non periodique");
+  if(!periodic) throw Standard_Failure("ElSpine non periodique");
   return period;
 }
 
@@ -293,7 +293,7 @@ void ChFiDS_ElSpine::SaveLastParameter()
 
 void ChFiDS_ElSpine::SetOrigin(const Standard_Real O)
 {
-  if(!periodic) Standard_Failure::Raise("Elspine non periodique");
+  if(!periodic) throw Standard_Failure("Elspine non periodique");
   Handle(Geom_BSplineCurve) bs = Handle(Geom_BSplineCurve)::DownCast(curve.Curve());
   if(!bs.IsNull()) {
     bs->SetOrigin(O,Precision::PConfusion());
index 1ce9a6d..78dc1f6 100644 (file)
@@ -332,7 +332,7 @@ Standard_Real  ChFiDS_FilSpine::Radius(const Standard_Integer IE)const
       par = parandrad(i).X();
       rad = parandrad(i).Y();
       if (Abs( rad-StartRad ) > Precision::Confusion())
-       Standard_DomainError::Raise("Edge is not constant");
+       throw Standard_DomainError("Edge is not constant");
       if (Abs( Ul-par ) <= gp::Resolution())
        return StartRad;
       if (par > Ul)
@@ -348,7 +348,7 @@ Standard_Real  ChFiDS_FilSpine::Radius(const Standard_Integer IE)const
 
 Standard_Real  ChFiDS_FilSpine::Radius()const 
 {
-  if (!IsConstant()) Standard_DomainError::Raise("Spine is not constant");
+  if (!IsConstant()) throw Standard_DomainError("Spine is not constant");
   return parandrad(1).Y();
 }
 
@@ -416,7 +416,7 @@ static void mklaw(Law_Laws&                  res,
 
   if(npr.IsEmpty()){
     if( Rdeb < 0. && Rfin <0. ) 
-      Standard_DomainError::Raise("Impossible to create the law");
+      throw Standard_DomainError("Impossible to create the law");
     else if(Rdeb < 0. || Rfin <0.){
       Standard_Real r = (Rfin<0.)? Rdeb  : Rfin;
       Handle(Law_Constant) loi = new Law_Constant();
@@ -548,7 +548,7 @@ Handle(Law_Composite) ChFiDS_FilSpine::ComputeLaw
     }
     if(k > len){ // no !
       if(parandrad.IsEmpty()) 
-       Standard_DomainError::Raise("Radius not defined");
+       throw Standard_DomainError("Radius not defined");
       Standard_Integer nbp = parandrad.Length();
       if(nbp > 1){
        deb = parandrad.First().X();
@@ -587,7 +587,7 @@ Handle(Law_Composite) ChFiDS_FilSpine::ComputeLaw
       if (IsConstant(iprec)){
        Rdeb = Radius(iprec);
       }
-      else Standard_DomainError::Raise("AppendLaw : previous constant is missing!");
+      else throw Standard_DomainError("AppendLaw : previous constant is missing!");
       lawencours = Standard_True;
     }
     // the raduis at end.
@@ -599,7 +599,7 @@ Handle(Law_Composite) ChFiDS_FilSpine::ComputeLaw
       if (IsConstant(isuiv)) {
        Rfin = Radius(isuiv);
       }
-      else Standard_DomainError::Raise("AppendLaw : next constant is missing!");
+      else throw Standard_DomainError("AppendLaw : next constant is missing!");
     }
   }
   else{
@@ -618,10 +618,10 @@ Handle(Law_Composite) ChFiDS_FilSpine::ComputeLaw
        if (IsConstant(ind(1) - 1)){
          Rdeb = Radius(ind(1) - 1);
        }
-       else Standard_DomainError::Raise("AppendLaw : previous constant is missing");
+       else throw Standard_DomainError("AppendLaw : previous constant is missing");
       }
       else if(parandrad.IsEmpty()){
-       Standard_DomainError::Raise("AppendLaw : no radius on vertex");
+       throw Standard_DomainError("AppendLaw : no radius on vertex");
       }
       else Rdeb = -1.;
       lawencours = Standard_True;
@@ -631,10 +631,10 @@ Handle(Law_Composite) ChFiDS_FilSpine::ComputeLaw
     else{
       if(ind(nbed) < len){
        if (IsConstant(ind(nbed) + 1)) Rfin = Radius(ind(nbed) + 1);
-       else Standard_DomainError::Raise("AppendLaw : next constant is missing");
+       else throw Standard_DomainError("AppendLaw : next constant is missing");
       }
       else if(parandrad.IsEmpty()){
-       Standard_DomainError::Raise("AppendLaw : no radius on vertex");
+       throw Standard_DomainError("AppendLaw : no radius on vertex");
       }
       else Rfin = -1.;
     }
@@ -729,11 +729,11 @@ Handle(Law_Composite) ChFiDS_FilSpine::Law(const Handle(ChFiDS_HElSpine)& Els) c
 Handle(Law_Function)& ChFiDS_FilSpine::ChangeLaw(const TopoDS_Edge& E)
 {
   if(!SplitDone()) {
-    Standard_DomainError::Raise("ChFiDS_FilSpine::ChangeLaw : the limits are not up-to-date");
+    throw Standard_DomainError("ChFiDS_FilSpine::ChangeLaw : the limits are not up-to-date");
   }
   Standard_Integer IE = Index(E);
   if (IsConstant(IE)) {
-    Standard_DomainError::Raise("ChFiDS_FilSpine::ChangeLaw : no law on constant edges");
+    throw Standard_DomainError("ChFiDS_FilSpine::ChangeLaw : no law on constant edges");
   }
   Handle(ChFiDS_HElSpine) hsp = ElSpine(IE);
   Standard_Real w = 0.5*(FirstParameter(IE) + LastParameter(IE));
index ec80ccc..f99213a 100644 (file)
@@ -335,7 +335,7 @@ Standard_Real ChFiDS_Spine::Absc(const TopoDS_Vertex& V) const
 
 Standard_Real ChFiDS_Spine::Period() const
 {
-  if(!IsPeriodic()) Standard_Failure::Raise("Non-periodic Spine");
+  if(!IsPeriodic()) throw Standard_Failure("Non-periodic Spine");
   return abscissa->Value(abscissa->Upper());
 }
 
@@ -358,8 +358,7 @@ Standard_Real ChFiDS_Spine::Resolution(const Standard_Real R3d) const
 
 void  ChFiDS_Spine::SetFirstTgt(const Standard_Real W)
 {
-  if(IsPeriodic()) Standard_Failure::Raise
-    ("No extension by tangent on periodic contours"); 
+  if(IsPeriodic()) throw Standard_Failure("No extension by tangent on periodic contours");
 #ifdef OCCT_DEBUG
   if(W >= Precision::Confusion()) 
     cout<<"Interior extension at start of the guideline"<<endl;
@@ -381,8 +380,7 @@ void  ChFiDS_Spine::SetFirstTgt(const Standard_Real W)
 
 void  ChFiDS_Spine::SetLastTgt(const Standard_Real W)
 {
-  if(IsPeriodic()) Standard_Failure::Raise
-    ("No extension by tangent periodic contours"); 
+  if(IsPeriodic()) throw Standard_Failure("No extension by tangent periodic contours");
 
 #ifdef OCCT_DEBUG
   Standard_Real L = W - abscissa->Value(abscissa->Upper());
index 6e99b14..06b562e 100644 (file)
@@ -41,7 +41,7 @@ inline Standard_Boolean ChFiDS_SurfData::IsOnCurve1() const
 
 inline Standard_Integer  ChFiDS_SurfData::IndexOfC1() const
 {
-  if(!isoncurv1) Standard_Failure::Raise("Interference pas sur courbe");
+  if(!isoncurv1) throw Standard_Failure("Interference pas sur courbe");
   return indexOfC1;
 }
 
@@ -83,7 +83,7 @@ inline Standard_Boolean ChFiDS_SurfData::IsOnCurve2() const
 
 inline Standard_Integer  ChFiDS_SurfData::IndexOfC2() const
 {
-  if(!isoncurv2) Standard_Failure::Raise("Interference pas sur courbe");
+  if(!isoncurv2) throw Standard_Failure("Interference pas sur courbe");
   return indexOfC2;
 }
 
@@ -303,10 +303,10 @@ inline Standard_Boolean ChFiDS_SurfData::IsOnCurve(const Standard_Integer OnS) c
 inline Standard_Integer  ChFiDS_SurfData::IndexOfC(const Standard_Integer OnS) const
 {
   if(OnS == 1) {
-    if(!isoncurv1) Standard_Failure::Raise("Interference pas sur courbe");
+    if(!isoncurv1) throw Standard_Failure("Interference pas sur courbe");
     return indexOfC1;
   }
-  if(!isoncurv2) Standard_Failure::Raise("Interference pas sur courbe");
+  if(!isoncurv2) throw Standard_Failure("Interference pas sur courbe");
   return indexOfC2;
 }
 
index 71cbf73..0d6c3a5 100644 (file)
                                    Wref,OrFace2,Standard_False);
     }
     else{
-      Standard_NotImplemented::Raise("particular case not written");
+      throw Standard_NotImplemented("particular case not written");
     }
   }
   else if(!CSpine.IsNull()){
                                       Wref,OrFace2,Standard_False); 
       }
       else{
-       Standard_NotImplemented::Raise("particular case not written");
+       throw Standard_NotImplemented("particular case not written");
       }
     }
     else if (CSpine->IsChamfer() == ChFiDS_TwoDist) {    
                                       Wref,OrFace2,Standard_False); 
       }
       else{
-       Standard_NotImplemented::Raise("particular case not written");
+       throw Standard_NotImplemented("particular case not written");
       }
     }
     else {
                                      Wref,OrFace2,Standard_False, DisOnP); 
       }
       else{
-       Standard_NotImplemented::Raise("particular case not written");
+       throw Standard_NotImplemented("particular case not written");
       }
     }
   }
@@ -342,8 +342,7 @@ Standard_Boolean ChFiKPart_ComputeData::ComputeCorner
   GeomAbs_SurfaceType typ1 = S1->GetType();
   GeomAbs_SurfaceType typ2 = S2->GetType();
   if ( typ1 != GeomAbs_Plane ){
-    Standard_ConstructionError::Raise
-      ("la face du conge torique doit etre plane");
+    throw Standard_ConstructionError("la face du conge torique doit etre plane");
   }
   // The guideline is the circle corresponding 
   // to the section of S2, and other construction elements.
@@ -428,8 +427,7 @@ Standard_Boolean ChFiKPart_ComputeData::ComputeCorner
   if (typ != GeomAbs_Plane ||
       typ1 != GeomAbs_Plane ||
       typ2 != GeomAbs_Plane){
-    Standard_ConstructionError::Raise
-      ("torus joint only between the planes");
+    throw Standard_ConstructionError("torus joint only between the planes");
   }
   return ChFiKPart_MakeRotule(DStr,Data,S->Plane(),S1->Plane(),
                              S2->Plane(),OS,OS1,OS2,Radius,OfS);
index d04ff71..0165d0b 100644 (file)
@@ -166,11 +166,11 @@ void ChFiKPart_ProjPC(const GeomAdaptor_Curve& Cg,
       break;
 #endif
       default :
-      Standard_NotImplemented::Raise("failed approximation of the pcurve ");
+      throw Standard_NotImplemented("failed approximation of the pcurve ");
     }
   }
   else {
-    Standard_NotImplemented::Raise("approximate pcurve on the left surface");
+    throw Standard_NotImplemented("approximate pcurve on the left surface");
   }
 }
 
index 69cbeb7..94bf61c 100644 (file)
@@ -82,11 +82,11 @@ Cocoa_Window::Cocoa_Window (const Standard_CString theTitle,
 #else
   if (thePxWidth <= 0 || thePxHeight <= 0)
   {
-    Aspect_WindowDefinitionError::Raise ("Coordinate(s) out of range");
+    throw Aspect_WindowDefinitionError("Coordinate(s) out of range");
   }
   else if (NSApp == NULL)
   {
-    Aspect_WindowDefinitionError::Raise ("Cocoa application should be instantiated before window");
+    throw Aspect_WindowDefinitionError("Cocoa application should be instantiated before window");
     return;
   }
 
@@ -103,7 +103,7 @@ Cocoa_Window::Cocoa_Window (const Standard_CString theTitle,
                                               defer: NO];
   if (myHWindow == NULL)
   {
-    Aspect_WindowDefinitionError::Raise ("Unable to create window");
+    throw Aspect_WindowDefinitionError("Unable to create window");
   }
   myHView = [[myHWindow contentView] retain];
 
index d7a0599..86a84a5 100644 (file)
@@ -438,9 +438,9 @@ void Contap_ContAna::Perform (const gp_Cone& C,
 
 gp_Lin Contap_ContAna::Line (const Standard_Integer Index) const
 {
-  if (!done) {StdFail_NotDone::Raise();}
-  if (typL != GeomAbs_Line || nbSol == 0) {Standard_DomainError::Raise();}
-  if (Index <=0 || Index > nbSol) {Standard_OutOfRange::Raise();}
+  if (!done) {throw StdFail_NotDone();}
+  if (typL != GeomAbs_Line || nbSol == 0) {throw Standard_DomainError();}
+  if (Index <=0 || Index > nbSol) {throw Standard_OutOfRange();}
   switch (Index) {
   case 1:
     return gp_Lin(pt1,dir1);
@@ -451,6 +451,5 @@ gp_Lin Contap_ContAna::Line (const Standard_Integer Index) const
   case 4:
     return gp_Lin(pt4,dir4);
   }
-  Standard_OutOfRange::Raise("Program error in Contap_ContAna");
-  return gp_Lin();
+  throw Standard_OutOfRange("Program error in Contap_ContAna");
 }
index b802d3f..5c9bbeb 100644 (file)
@@ -28,20 +28,20 @@ inline Standard_Boolean Contap_ContAna::IsDone () const
 
 inline Standard_Integer Contap_ContAna::NbContours () const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return nbSol;
 }
 
 inline GeomAbs_CurveType Contap_ContAna::TypeContour () const
 {
-  if (!done) {StdFail_NotDone::Raise();}
-  if (nbSol == 0) {Standard_DomainError::Raise();}
+  if (!done) {throw StdFail_NotDone();}
+  if (nbSol == 0) {throw Standard_DomainError();}
   return typL;
 }
 
 inline gp_Circ Contap_ContAna::Circle () const
 {
-  if (!done) {StdFail_NotDone::Raise();}
-  if (typL != GeomAbs_Circle || nbSol == 0) {Standard_DomainError::Raise();}
+  if (!done) {throw StdFail_NotDone();}
+  if (typL != GeomAbs_Circle || nbSol == 0) {throw Standard_DomainError();}
   return gp_Circ(gp_Ax2(pt1,dir1,dir2),prm);
 }
index ab4ebfb..d23c73f 100644 (file)
@@ -141,7 +141,7 @@ void Contap_Contour::Init (const gp_Pnt& Eye)
 void Contap_Contour::Perform (const Handle(Adaptor3d_HSurface)& Surf,
                               const Handle(Adaptor3d_TopolTool)& Domain)
 {
-  if (!modeset) {Standard_ConstructionError::Raise();}
+  if (!modeset) {throw Standard_ConstructionError();}
   mySFunc.Set(Surf);
   myAFunc.Set(Surf);
 
index 7ba89c0..7835022 100644 (file)
@@ -28,21 +28,21 @@ inline Standard_Boolean Contap_Contour::IsEmpty () const
 
 inline Standard_Integer Contap_Contour::NbLines () const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return slin.Length();
 }
 
 inline const Contap_Line & 
 Contap_Contour::Line (const Standard_Integer Index) const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return slin(Index);
 }
 
 inline Contap_SurfFunction & 
 Contap_Contour::SurfaceFunction ()
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return mySFunc;
 }
 
index 2b6b561..9589cce 100644 (file)
@@ -325,7 +325,7 @@ void Contap_HContTool::Value(const Handle(Adaptor2d_HCurve2d)&,
                              Standard_Real&,
                              Standard_Real&)
 {
-  Standard_OutOfRange::Raise();
+  throw Standard_OutOfRange();
 }
 
 Standard_Boolean Contap_HContTool::IsVertex(const Handle(Adaptor2d_HCurve2d)&,
@@ -338,7 +338,7 @@ void Contap_HContTool::Vertex(const Handle(Adaptor2d_HCurve2d)&,
                               const Standard_Integer,
                               Handle(Adaptor3d_HVertex)&)
 {
-  Standard_OutOfRange::Raise();
+  throw Standard_OutOfRange();
 }
 
 Standard_Integer Contap_HContTool::NbSegments(const Handle(Adaptor2d_HCurve2d)&)
@@ -351,8 +351,7 @@ Standard_Boolean Contap_HContTool::HasFirstPoint
  const Standard_Integer,
  Standard_Integer&)
 {
-  Standard_OutOfRange::Raise();
-  return Standard_False;
+  throw Standard_OutOfRange();
 }
 
 Standard_Boolean Contap_HContTool::HasLastPoint
@@ -360,8 +359,7 @@ Standard_Boolean Contap_HContTool::HasLastPoint
  const Standard_Integer,
  Standard_Integer&)
 {
-  Standard_OutOfRange::Raise();
-  return Standard_False;
+  throw Standard_OutOfRange();
 }
 
 Standard_Boolean Contap_HContTool::IsAllSolution
index a090690..0a3e8d6 100644 (file)
@@ -100,6 +100,6 @@ IntSurf_TypeTrans Contap_Line::TransitionOnS() const {
 
 const Handle(Adaptor2d_HCurve2d)& Contap_Line::Arc () const
 {
-  if (typL != Contap_Restriction) {Standard_DomainError::Raise();}
+  if (typL != Contap_Restriction) {throw Standard_DomainError();}
   return thearc;
 }
index b087db8..a5e5dc0 100644 (file)
@@ -50,23 +50,23 @@ inline Contap_IType Contap_Line::TypeContour () const
 }
 
 inline Standard_Integer Contap_Line::NbPnts () const {
-  if (typL != Contap_Walking) {Standard_DomainError::Raise();}
+  if (typL != Contap_Walking) {throw Standard_DomainError();}
   return(curv->NbPoints());
 }
 
 inline const IntSurf_PntOn2S& Contap_Line::Point (const Standard_Integer Index) const {
-  if (typL != Contap_Walking) {Standard_DomainError::Raise();}
+  if (typL != Contap_Walking) {throw Standard_DomainError();}
   return(curv->Value(Index));
 }
 
 inline gp_Lin Contap_Line::Line () const
 {
-  if (typL != Contap_Lin) {Standard_DomainError::Raise();}
+  if (typL != Contap_Lin) {throw Standard_DomainError();}
   return gp_Lin(pt,dir1);
 }
 
 inline gp_Circ Contap_Line::Circle () const
 {
-  if (typL != Contap_Circle) {Standard_DomainError::Raise();}
+  if (typL != Contap_Circle) {throw Standard_DomainError();}
   return gp_Circ(gp_Ax2(pt,dir1,dir2),rad);
 }
index 89a5252..81cdd64 100644 (file)
@@ -96,25 +96,25 @@ inline Standard_Boolean Contap_Point::IsOnArc () const{
 
 inline const Handle(Adaptor2d_HCurve2d)& Contap_Point::Arc () const {
 
-  if (!onarc) {Standard_DomainError::Raise();}
+  if (!onarc) {throw Standard_DomainError();}
   return arc;
 }
 
 inline const IntSurf_Transition& Contap_Point::TransitionOnLine () const {
 
-  if (!onarc) {Standard_DomainError::Raise();}
+  if (!onarc) {throw Standard_DomainError();}
   return traline;
 }
 
 inline const IntSurf_Transition& Contap_Point::TransitionOnArc () const {
 
-  if (!onarc) {Standard_DomainError::Raise();}
+  if (!onarc) {throw Standard_DomainError();}
   return traarc;
 }
 
 inline Standard_Real Contap_Point::ParameterOnArc () const {
 
-  if (!onarc) {Standard_DomainError::Raise();}
+  if (!onarc) {throw Standard_DomainError();}
   return prmarc;
 }
 
@@ -124,6 +124,6 @@ inline Standard_Boolean Contap_Point::IsVertex () const {
 
 inline const Handle(Adaptor3d_HVertex)& Contap_Point::Vertex () const {
 
-  if (!isvtx) {Standard_DomainError::Raise();}
+  if (!isvtx) {throw Standard_DomainError();}
   return vtx;
 }
index bad8a05..c3762ff 100644 (file)
@@ -70,13 +70,13 @@ inline Standard_Real Contap_SurfFunction::Tolerance () const
 
 inline const gp_Vec& Contap_SurfFunction::Direction3d()
 {
-  if (IsTangent()) StdFail_UndefinedDerivative::Raise();       
+  if (IsTangent()) throw StdFail_UndefinedDerivative();
   return d3d;
 }
 
 inline const gp_Dir2d& Contap_SurfFunction::Direction2d()
 {
-  if (IsTangent()) StdFail_UndefinedDerivative::Raise();       
+  if (IsTangent()) throw StdFail_UndefinedDerivative();
   return d2d;
 }
 
index 46757e2..be06a04 100644 (file)
@@ -132,7 +132,7 @@ Convert_CircleToBSplineCurve::Convert_CircleToBSplineCurve
   Standard_Real Eps = Precision::PConfusion();
 
   if ( (delta > (2*M_PI + Eps)) || (delta <= 0.0e0) ) {
-    Standard_DomainError::Raise( "Convert_CircleToBSplineCurve");
+    throw Standard_DomainError( "Convert_CircleToBSplineCurve");
   }
 
   Standard_Integer ii;
index 0e0cfd6..1399723 100644 (file)
@@ -60,8 +60,8 @@ Convert_CompPolynomialToPoles::Convert_CompPolynomialToPoles(
      MaxDegree  <= 0              ||
      Dimension  <= 0              ||
      PolynomialIntervals->RowLength() != 2) {
-   Standard_ConstructionError::
-   Raise("Convert_CompPolynomialToPoles:bad arguments");
+   throw Standard_ConstructionError
+   ("Convert_CompPolynomialToPoles:bad arguments");
  } 
  myDegree = 0 ;
 
@@ -72,8 +72,8 @@ Convert_CompPolynomialToPoles::Convert_CompPolynomialToPoles(
    myDegree = Max(NumCoeffPerCurve->Value(ii)-1,myDegree) ;
  }
  if ((Continuity > myDegree)&& (NumCurves>1)) {
-   Standard_ConstructionError::
-   Raise("Convert_CompPolynomialToPoles:Continuity is too great");
+   throw Standard_ConstructionError
+   ("Convert_CompPolynomialToPoles:Continuity is too great");
  } 
 //
 //  prepare output
@@ -117,8 +117,8 @@ Convert_CompPolynomialToPoles(const Standard_Integer NumCurves,
      MaxDegree  <= 0              ||
      Dimension  <= 0              ||
      PolynomialIntervals.RowLength() != 2) {
-   Standard_ConstructionError::
-   Raise("Convert_CompPolynomialToPoles:bad arguments");
+   throw Standard_ConstructionError
+   ("Convert_CompPolynomialToPoles:bad arguments");
  } 
  myDegree = 0 ;
 
@@ -144,8 +144,8 @@ Convert_CompPolynomialToPoles(const Standard_Integer NumCurves,
  new TColStd_HArray1OfInteger(1, NumCurves + 1) ;
  for (ii = 2 ; ii < NumCurves + 1 ; ii++) {
    if ((Continuity(ii) > myDegree)&& (NumCurves>1)) {
-     Standard_ConstructionError::
-     Raise("Convert_CompPolynomialToPoles:Continuity is too great");
+     throw Standard_ConstructionError
+     ("Convert_CompPolynomialToPoles:Continuity is too great");
    }
 
    myMults -> SetValue(ii, myDegree-Continuity(ii) );
@@ -174,8 +174,8 @@ Convert_CompPolynomialToPoles(const Standard_Integer Dimension,
      Dimension  <= 0              ||
      PolynomialIntervals.Length() != 2) 
    {
-     Standard_ConstructionError::
-     Raise("Convert_CompPolynomialToPoles:bad arguments");
+     throw Standard_ConstructionError
+     ("Convert_CompPolynomialToPoles:bad arguments");
    }
 
  TColStd_Array2OfReal ThePolynomialIntervals(1,1,1,2);
@@ -293,8 +293,8 @@ Perform(const Standard_Integer NumCurves,
                       poles_array[0],
                       inversion_problem) ;
  if (inversion_problem != 0) {
-  Standard_ConstructionError::
-  Raise("Convert_CompPolynomialToPoles:inversion_problem");
+  throw Standard_ConstructionError
+  ("Convert_CompPolynomialToPoles:inversion_problem");
  } 
  myDone = Standard_True ;
 }
index 7ca0086..a78a88b 100644 (file)
@@ -107,7 +107,7 @@ gp_Pnt2d Convert_ConicToBSplineCurve::Pole
   (const Standard_Integer Index) const 
 {
   if (Index < 1 || Index > nbPoles)
-    Standard_OutOfRange::Raise(" ");
+    throw Standard_OutOfRange(" ");
   return poles->Value (Index);
 }
 
@@ -121,7 +121,7 @@ Standard_Real Convert_ConicToBSplineCurve::Weight
   (const Standard_Integer Index) const 
 {
   if (Index < 1 || Index > nbPoles)
-    Standard_OutOfRange::Raise(" ");
+    throw Standard_OutOfRange(" ");
   return weights->Value (Index);
 }
 
@@ -135,7 +135,7 @@ Standard_Real Convert_ConicToBSplineCurve::Knot
   (const Standard_Integer Index) const 
 {
   if (Index < 1 || Index > nbKnots)
-    Standard_OutOfRange::Raise(" ");
+    throw Standard_OutOfRange(" ");
   return knots->Value (Index);
 }
 
@@ -149,7 +149,7 @@ Standard_Integer Convert_ConicToBSplineCurve::Multiplicity
   (const Standard_Integer Index) const 
 {
   if (Index < 1 || Index > nbKnots)
-    Standard_OutOfRange::Raise(" ");
+    throw Standard_OutOfRange(" ");
   return mults->Value (Index);
 }
 //=======================================================================
@@ -269,7 +269,7 @@ void AlgorithmicCosAndSin(Standard_Integer               Degree,
    if (num_poles != CosNumerator.Length() ||
        num_poles != SinNumerator.Length() ||
        num_poles != Denominator.Length() ) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
       }
    TColStd_Array1OfReal      parameters(1,num_poles)  ;
    TColgp_Array1OfPnt        poles_array(1,num_poles) ;
@@ -366,14 +366,14 @@ void Convert_ConicToBSplineCurve::BuildCosAndSin(
   case Convert_TgtThetaOver2_1:
     num_spans = 1 ;
     if (delta > 0.9999 * M_PI) {
-      Standard_ConstructionError::Raise() ; 
+      throw Standard_ConstructionError() ; 
       }
     tgt_theta_flag = 1 ;
     break ;
   case Convert_TgtThetaOver2_2:
     num_spans = 2 ;
     if (delta > 1.9999 * M_PI) {
-      Standard_ConstructionError::Raise() ;
+      throw Standard_ConstructionError() ;
       }
     tgt_theta_flag = 1 ;
     break ;
@@ -637,7 +637,7 @@ void Convert_ConicToBSplineCurve::BuildCosAndSin(
 
   if (Parameterisation != Convert_TgtThetaOver2 &&
       Parameterisation != Convert_RationalC1) {
-      Standard_ConstructionError::Raise() ;
+      throw Standard_ConstructionError() ;
       }
   Handle(TColStd_HArray1OfReal) temp_cos_ptr,
   temp_sin_ptr,
index 9fa07c5..918e0e8 100644 (file)
@@ -40,12 +40,12 @@ Convert_GridPolynomialToPoles(
   if ((NumCoeffPerSurface->Lower()!=1 ) || 
       (NumCoeffPerSurface->Upper()!= 2) )
     {
-      Standard_DomainError::Raise("Convert : Wrong Coefficients");
+      throw Standard_DomainError("Convert : Wrong Coefficients");
     } 
   if ((Coefficients->Lower()!=1 ) || 
       (Coefficients->Upper()!= 3*(MaxUDegree+1)*(MaxVDegree+1)))
     {
-      Standard_DomainError::Raise("Convert : Wrong Coefficients");
+      throw Standard_DomainError("Convert : Wrong Coefficients");
     }  
 
   // Les Degres
@@ -53,11 +53,9 @@ Convert_GridPolynomialToPoles(
   myVDegree = NumCoeffPerSurface->Value(2)-1;
 
   if (myUDegree > MaxUDegree) 
-     Standard_DomainError::Raise
-       ("Convert : Incoherence beetween NumCoeffPerSurface and MaxUDegree");
+     throw Standard_DomainError("Convert : Incoherence beetween NumCoeffPerSurface and MaxUDegree");
   if (myVDegree > MaxVDegree) 
-     Standard_DomainError::Raise
-       ("Convert : Incoherence beetween NumCoeffPerSurface and MaxVDegree");
+     throw Standard_DomainError("Convert : Incoherence beetween NumCoeffPerSurface and MaxVDegree");
 
   Handle(TColStd_HArray2OfInteger) NumCoeff = 
     new (TColStd_HArray2OfInteger)(1, 1, 1, 2);
@@ -102,14 +100,14 @@ Convert_GridPolynomialToPoles(
      (NumCoeffPerSurface->LowerCol()!=1) || 
      (NumCoeffPerSurface->UpperCol()!=2) )
     {
-      Standard_DomainError::Raise("Convert : Wrong NumCoeffPerSurface");
+      throw Standard_DomainError("Convert : Wrong NumCoeffPerSurface");
     }
 
   if ((Coefficients->Lower()!=1 ) || 
       (Coefficients->Upper()!= 3*NbUSurfaces*NbVSurfaces*
        (RealUDegree + 1) * (RealVDegree + 1)) )
     {
-      Standard_DomainError::Raise("Convert : Wrong Coefficients");
+      throw Standard_DomainError("Convert : Wrong Coefficients");
     }
      
   // Calcul des degree
@@ -121,11 +119,9 @@ Convert_GridPolynomialToPoles(
   }
 
   if (myUDegree > RealUDegree) 
-     Standard_DomainError::Raise
-       ("Convert : Incoherence beetween NumCoeffPerSurface and MaxUDegree");
+     throw Standard_DomainError("Convert : Incoherence beetween NumCoeffPerSurface and MaxUDegree");
   if (myVDegree > RealVDegree) 
-     Standard_DomainError::Raise
-       ("Convert : Incoherence beetween NumCoeffPerSurface and MaxVDegree");
+     throw Standard_DomainError("Convert : Incoherence beetween NumCoeffPerSurface and MaxVDegree");
 
   Perform (UContinuity, VContinuity, 
           RealUDegree, RealVDegree,
index d111885..19147aa 100644 (file)
@@ -206,7 +206,7 @@ void BuildHermitePolynomialCosAndSin
 {
 
   if (num_poles%2 != 0) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   Standard_Integer ii;
   Standard_Integer ordre_deriv = num_poles/2;
@@ -286,7 +286,7 @@ void BuildHermitePolynomialCosAndSin
                        ContactOrderArray,Poles,InversionPb);
 
   if (InversionPb !=0) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   for (ii=1; ii<=num_poles; ii++) {
     CosNumeratorPtr->SetValue(ii,Poles(ii).X());
index b2ff8cc..ca90da9 100644 (file)
@@ -35,9 +35,9 @@ Standard_EXPORT const char* DBRep_Set (const char* theNameStr, void* theShapePtr
     DBRep::Set (theNameStr, *(TopoDS_Shape*)theShapePtr);
     return theNameStr;
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    return Standard_Failure::Caught()->GetMessageString();
+    return anException.GetMessageString();
   }
 }
 
@@ -68,9 +68,9 @@ Standard_EXPORT const char* DBRep_SetComp(const char* theNameStr, void* theListP
     DBRep::Set(theNameStr, aC);
     return theNameStr;
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    return Standard_Failure::Caught()->GetMessageString();
+    return anException.GetMessageString();
   }
 }
 
index 77ae98f..61d0104 100644 (file)
@@ -255,14 +255,14 @@ void DDF_IOStream::ReadExtendedLine(TCollection_ExtendedString& buffer)
   while (!fin && !IsEnd()) {
     myIStream->get(c);
     check++; 
-//    if (!(check % 2)) Storage_StreamExtCharParityError::Raise();
+//    if (!(check % 2)) throw Storage_StreamExtCharParityError();
     i = (Standard_ExtCharacter)c;
     if (c == '\0') fin = Standard_True;
     i = (i << 8);
 
     myIStream->get(c);
     check++;
-//    if ((check % 2) != 0) Storage_StreamExtCharParityError::Raise();
+//    if ((check % 2) != 0) throw Storage_StreamExtCharParityError();
 //    cout << check << endl;
     j = (Standard_ExtCharacter)c;
     if (c != '\n') fin = Standard_False;
@@ -270,7 +270,7 @@ void DDF_IOStream::ReadExtendedLine(TCollection_ExtendedString& buffer)
     buffer += (Standard_ExtCharacter)i;
   }
 
-//  if ((check % 2) != 0) Storage_StreamExtCharParityError::Raise();
+//  if ((check % 2) != 0) throw Storage_StreamExtCharParityError();
 //  cout << check << endl;
 }
 
@@ -390,7 +390,7 @@ void DDF_IOStream::SkipObject()
 Storage_BaseDriver& DDF_IOStream::PutReference(const Standard_Integer aValue)
 {
   *myOStream << aValue << " ";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise("PutReference");
+  if (myOStream->bad()) throw Storage_StreamWriteError("PutReference");
   return *this;
 }
 
@@ -402,7 +402,7 @@ Storage_BaseDriver& DDF_IOStream::PutReference(const Standard_Integer aValue)
 Storage_BaseDriver& DDF_IOStream::PutCharacter(const Standard_Character aValue)
 {
   *myOStream << aValue << " ";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise("PutCharacter");
+  if (myOStream->bad()) throw Storage_StreamWriteError("PutCharacter");
   return *this;
 }
 
@@ -414,7 +414,7 @@ Storage_BaseDriver& DDF_IOStream::PutCharacter(const Standard_Character aValue)
 Storage_BaseDriver& DDF_IOStream::PutExtCharacter(const Standard_ExtCharacter aValue)
 {
   *myOStream << (short )aValue << " ";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise("PutExtCharacter");
+  if (myOStream->bad()) throw Storage_StreamWriteError("PutExtCharacter");
   return *this;
 }
 
@@ -426,7 +426,7 @@ Storage_BaseDriver& DDF_IOStream::PutExtCharacter(const Standard_ExtCharacter aV
 Storage_BaseDriver& DDF_IOStream::PutInteger(const Standard_Integer aValue)
 {
   *myOStream << aValue << " ";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise("PutInteger");
+  if (myOStream->bad()) throw Storage_StreamWriteError("PutInteger");
   return *this;
 }
 
@@ -438,7 +438,7 @@ Storage_BaseDriver& DDF_IOStream::PutInteger(const Standard_Integer aValue)
 Storage_BaseDriver& DDF_IOStream::PutBoolean(const Standard_Boolean aValue)
 {
   *myOStream << ((Standard_Integer)aValue) << " ";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise("PutBoolean");
+  if (myOStream->bad()) throw Storage_StreamWriteError("PutBoolean");
   return *this;
 }
 
@@ -450,7 +450,7 @@ Storage_BaseDriver& DDF_IOStream::PutBoolean(const Standard_Boolean aValue)
 Storage_BaseDriver& DDF_IOStream::PutReal(const Standard_Real aValue)
 {
   *myOStream << ((Standard_Real)aValue) << " ";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise("PutReal");
+  if (myOStream->bad()) throw Storage_StreamWriteError("PutReal");
   return *this;
 }
 
@@ -462,7 +462,7 @@ Storage_BaseDriver& DDF_IOStream::PutReal(const Standard_Real aValue)
 Storage_BaseDriver& DDF_IOStream::PutShortReal(const Standard_ShortReal aValue)
 {
   *myOStream << aValue << " ";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise("PutShortReal");
+  if (myOStream->bad()) throw Storage_StreamWriteError("PutShortReal");
   return *this;
 }
 
@@ -477,7 +477,7 @@ Storage_BaseDriver& DDF_IOStream::PutShortReal(const Standard_ShortReal aValue)
 
 Storage_BaseDriver& DDF_IOStream::GetReference(Standard_Integer& aValue)
 {
-  if (!(*myIStream >> aValue)) Storage_StreamTypeMismatchError::Raise("GetReference");
+  if (!(*myIStream >> aValue)) throw Storage_StreamTypeMismatchError("GetReference");
   return *this;
 }
 
@@ -488,7 +488,7 @@ Storage_BaseDriver& DDF_IOStream::GetReference(Standard_Integer& aValue)
 
 Storage_BaseDriver& DDF_IOStream::GetCharacter(Standard_Character& aValue)
 {
-  if (!(*myIStream >> aValue)) Storage_StreamTypeMismatchError::Raise("GetCharacter");
+  if (!(*myIStream >> aValue)) throw Storage_StreamTypeMismatchError("GetCharacter");
   return *this;
 }
 
@@ -500,7 +500,7 @@ Storage_BaseDriver& DDF_IOStream::GetCharacter(Standard_Character& aValue)
 Storage_BaseDriver& DDF_IOStream::GetExtCharacter(Standard_ExtCharacter& aValue)
 {
   short aChar = 0;
-  if (!(*myIStream >> aChar)) Storage_StreamTypeMismatchError::Raise("GetExtCharacter");
+  if (!(*myIStream >> aChar)) throw Storage_StreamTypeMismatchError("GetExtCharacter");
   aValue = aChar;
   return *this;
 }
@@ -512,7 +512,7 @@ Storage_BaseDriver& DDF_IOStream::GetExtCharacter(Standard_ExtCharacter& aValue)
 
 Storage_BaseDriver& DDF_IOStream::GetInteger(Standard_Integer& aValue)
 {
-  if (!(*myIStream >> aValue)) Storage_StreamTypeMismatchError::Raise("GetInteger");
+  if (!(*myIStream >> aValue)) throw Storage_StreamTypeMismatchError("GetInteger");
   return *this;
 }
 
@@ -523,7 +523,7 @@ Storage_BaseDriver& DDF_IOStream::GetInteger(Standard_Integer& aValue)
 
 Storage_BaseDriver& DDF_IOStream::GetBoolean(Standard_Boolean& aValue)
 {
-  if (!(*myIStream >> aValue)) Storage_StreamTypeMismatchError::Raise("GetBoolean");
+  if (!(*myIStream >> aValue)) throw Storage_StreamTypeMismatchError("GetBoolean");
   return *this;
 }
 
@@ -534,7 +534,7 @@ Storage_BaseDriver& DDF_IOStream::GetBoolean(Standard_Boolean& aValue)
 
 Storage_BaseDriver& DDF_IOStream::GetReal(Standard_Real& aValue)
 {
-  if (!(*myIStream >> aValue)) Storage_StreamTypeMismatchError::Raise("GetReal");
+  if (!(*myIStream >> aValue)) throw Storage_StreamTypeMismatchError("GetReal");
   return *this;
 }
 
@@ -545,7 +545,7 @@ Storage_BaseDriver& DDF_IOStream::GetReal(Standard_Real& aValue)
 
 Storage_BaseDriver& DDF_IOStream::GetShortReal(Standard_ShortReal& aValue)
 {
-  if (!(*myIStream >> aValue)) Storage_StreamTypeMismatchError::Raise("GetShortReal");
+  if (!(*myIStream >> aValue)) throw Storage_StreamTypeMismatchError("GetShortReal");
   return *this;
 }
 
@@ -574,7 +574,7 @@ Storage_Error DDF_IOStream::BeginWriteInfoSection()
 {
   *myOStream << DDF_IOStream::MagicNumber() << '\n';
   *myOStream << "BEGIN_INFO_SECTION\n";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
 
   return Storage_VSOk;
 }
@@ -608,11 +608,11 @@ void DDF_IOStream::WriteInfo(const Standard_Integer nbObj,
   WriteExtendedLine(dataType);
   *myOStream << userInfo.Length() << "\n";
 
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
 
   for (i = 1; i <= userInfo.Length(); i++) {
     *myOStream << userInfo.Value(i).ToCString() << "\n";
-    if (myOStream->bad()) Storage_StreamWriteError::Raise();
+    if (myOStream->bad()) throw Storage_StreamWriteError();
   }
 }
 
@@ -625,7 +625,7 @@ void DDF_IOStream::WriteInfo(const Standard_Integer nbObj,
 Storage_Error DDF_IOStream::EndWriteInfoSection() 
 {
   *myOStream << "END_INFO_SECTION\n";
-  if (myOStream->bad())  Storage_StreamWriteError::Raise();
+  if (myOStream->bad())  throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -677,7 +677,7 @@ void DDF_IOStream::ReadInfo(Standard_Integer& nbObj,
                        TCollection_ExtendedString& dataType,
                        TColStd_SequenceOfAsciiString& userInfo) 
 {
-  if (!(*myIStream >> nbObj)) Storage_StreamTypeMismatchError::Raise("ReadInfo 1");
+  if (!(*myIStream >> nbObj)) throw Storage_StreamTypeMismatchError("ReadInfo 1");
 
   FlushEndOfLine();
 
@@ -691,7 +691,7 @@ void DDF_IOStream::ReadInfo(Standard_Integer& nbObj,
 
   Standard_Integer i,len = 0;
 
-  if (!(*myIStream >> len)) Storage_StreamTypeMismatchError::Raise("ReadInfo 2");
+  if (!(*myIStream >> len)) throw Storage_StreamTypeMismatchError("ReadInfo 2");
 
   FlushEndOfLine();
 
@@ -733,7 +733,7 @@ Storage_Error DDF_IOStream::EndReadInfoSection()
 Storage_Error DDF_IOStream::BeginWriteCommentSection() 
 {
   *myOStream << "BEGIN_COMMENT_SECTION\n";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -748,11 +748,11 @@ void DDF_IOStream::WriteComment(const TColStd_SequenceOfExtendedString& aCom)
 
  aSize = aCom.Length();
  *myOStream << aSize << "\n";
- if (myOStream->bad()) Storage_StreamWriteError::Raise();
+ if (myOStream->bad()) throw Storage_StreamWriteError();
 
  for (i = 1; i <= aSize; i++) {
    WriteExtendedLine(aCom.Value(i));
-   if (myOStream->bad()) Storage_StreamWriteError::Raise();
+   if (myOStream->bad()) throw Storage_StreamWriteError();
  }
 }
 
@@ -764,7 +764,7 @@ void DDF_IOStream::WriteComment(const TColStd_SequenceOfExtendedString& aCom)
 Storage_Error DDF_IOStream::EndWriteCommentSection() 
 {
   *myOStream << "END_COMMENT_SECTION\n";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -792,7 +792,7 @@ void DDF_IOStream::ReadComment(TColStd_SequenceOfExtendedString& aCom)
   TCollection_ExtendedString line;
   Standard_Integer           len,i;
 
-  if (!(*myIStream >> len)) Storage_StreamTypeMismatchError::Raise("ReadComment");
+  if (!(*myIStream >> len)) throw Storage_StreamTypeMismatchError("ReadComment");
   
   FlushEndOfLine();  
 
@@ -823,7 +823,7 @@ Storage_Error DDF_IOStream::EndReadCommentSection()
 Storage_Error DDF_IOStream::BeginWriteTypeSection() 
 {
   *myOStream << "BEGIN_TYPE_SECTION\n";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -835,7 +835,7 @@ Storage_Error DDF_IOStream::BeginWriteTypeSection()
 void DDF_IOStream::SetTypeSectionSize(const Standard_Integer aSize) 
 {
   *myOStream << aSize << "\n";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -847,7 +847,7 @@ void DDF_IOStream::WriteTypeInformations(const Standard_Integer typeNum,
                                      const TCollection_AsciiString& typeName) 
 {
   *myOStream << typeNum << " " << typeName.ToCString() << "\n";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -858,7 +858,7 @@ void DDF_IOStream::WriteTypeInformations(const Standard_Integer typeNum,
 Storage_Error DDF_IOStream::EndWriteTypeSection() 
 {
   *myOStream << "END_TYPE_SECTION\n";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -883,7 +883,7 @@ Standard_Integer DDF_IOStream::TypeSectionSize()
 {
   Standard_Integer i;
 
-  if (!(*myIStream >> i)) Storage_StreamTypeMismatchError::Raise("TypeSectionSize");
+  if (!(*myIStream >> i)) throw Storage_StreamTypeMismatchError("TypeSectionSize");
 
   FlushEndOfLine();
 
@@ -898,8 +898,8 @@ Standard_Integer DDF_IOStream::TypeSectionSize()
 void DDF_IOStream::ReadTypeInformations(Standard_Integer& typeNum,
                                    TCollection_AsciiString& typeName) 
 {
-  if (!(*myIStream >> typeNum)) Storage_StreamTypeMismatchError::Raise("ReadTypeInformations 1");
-  if (!(*myIStream >> typeName)) Storage_StreamTypeMismatchError::Raise("ReadTypeInformations 2");
+  if (!(*myIStream >> typeNum)) throw Storage_StreamTypeMismatchError("ReadTypeInformations 1");
+  if (!(*myIStream >> typeName)) throw Storage_StreamTypeMismatchError("ReadTypeInformations 2");
   FlushEndOfLine();
 }
 
@@ -925,7 +925,7 @@ Storage_Error DDF_IOStream::EndReadTypeSection()
 Storage_Error DDF_IOStream::BeginWriteRootSection() 
 {
   *myOStream << "BEGIN_ROOT_SECTION\n";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -937,7 +937,7 @@ Storage_Error DDF_IOStream::BeginWriteRootSection()
 void DDF_IOStream::SetRootSectionSize(const Standard_Integer aSize) 
 {
   *myOStream << aSize << "\n";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -948,7 +948,7 @@ void DDF_IOStream::SetRootSectionSize(const Standard_Integer aSize)
 void DDF_IOStream::WriteRoot(const TCollection_AsciiString& rootName, const Standard_Integer aRef, const TCollection_AsciiString& rootType) 
 {
   *myOStream << aRef << " " << rootName.ToCString() << " " << rootType.ToCString() << "\n";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -959,7 +959,7 @@ void DDF_IOStream::WriteRoot(const TCollection_AsciiString& rootName, const Stan
 Storage_Error DDF_IOStream::EndWriteRootSection() 
 {
   *myOStream << "END_ROOT_SECTION\n";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -984,7 +984,7 @@ Standard_Integer DDF_IOStream::RootSectionSize()
 {
   Standard_Integer i;
 
-  if (!(*myIStream >> i)) Storage_StreamTypeMismatchError::Raise("RootSectionSize");
+  if (!(*myIStream >> i)) throw Storage_StreamTypeMismatchError("RootSectionSize");
   
   FlushEndOfLine();
   
@@ -998,7 +998,7 @@ Standard_Integer DDF_IOStream::RootSectionSize()
 
 void DDF_IOStream::ReadRoot(TCollection_AsciiString& rootName, Standard_Integer& aRef,TCollection_AsciiString& rootType) 
 {
-  if (!(*myIStream >> aRef)) Storage_StreamTypeMismatchError::Raise("ReadRoot");
+  if (!(*myIStream >> aRef)) throw Storage_StreamTypeMismatchError("ReadRoot");
   ReadWord(rootName);
   ReadWord(rootType);
 }
@@ -1023,7 +1023,7 @@ Storage_Error DDF_IOStream::EndReadRootSection()
 Storage_Error DDF_IOStream::BeginWriteRefSection() 
 {
   *myOStream << "BEGIN_REF_SECTION\n";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -1035,7 +1035,7 @@ Storage_Error DDF_IOStream::BeginWriteRefSection()
 void DDF_IOStream::SetRefSectionSize(const Standard_Integer aSize) 
 {
   *myOStream << aSize << "\n";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1047,7 +1047,7 @@ void DDF_IOStream::WriteReferenceType(const Standard_Integer reference,
                                  const Standard_Integer typeNum) 
 {
   *myOStream << reference << " " << typeNum << "\n";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1058,7 +1058,7 @@ void DDF_IOStream::WriteReferenceType(const Standard_Integer reference,
 Storage_Error DDF_IOStream::EndWriteRefSection() 
 {
   *myOStream << "END_REF_SECTION\n";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -1083,7 +1083,7 @@ Standard_Integer DDF_IOStream::RefSectionSize()
 {
   Standard_Integer i;
 
-  if (!(*myIStream >> i)) Storage_StreamTypeMismatchError::Raise("RefSectionSize");
+  if (!(*myIStream >> i)) throw Storage_StreamTypeMismatchError("RefSectionSize");
   FlushEndOfLine();
 
   return i;
@@ -1097,8 +1097,8 @@ Standard_Integer DDF_IOStream::RefSectionSize()
 void DDF_IOStream::ReadReferenceType(Standard_Integer& reference,
                                 Standard_Integer& typeNum) 
 {
-  if (!(*myIStream >> reference)) Storage_StreamTypeMismatchError::Raise("ReadReferenceType 1");
-  if (!(*myIStream >> typeNum)) Storage_StreamTypeMismatchError::Raise("ReadReferenceType 2");
+  if (!(*myIStream >> reference)) throw Storage_StreamTypeMismatchError("ReadReferenceType 1");
+  if (!(*myIStream >> typeNum)) throw Storage_StreamTypeMismatchError("ReadReferenceType 2");
   FlushEndOfLine();
 }
 
@@ -1124,7 +1124,7 @@ Storage_Error DDF_IOStream::EndReadRefSection()
 Storage_Error DDF_IOStream::BeginWriteDataSection() 
 {
   *myOStream << "BEGIN_DATA_SECTION";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -1137,7 +1137,7 @@ void DDF_IOStream::WritePersistentObjectHeader(const Standard_Integer aRef,
                                           const Standard_Integer aType) 
 {
   *myOStream << "\n#" << aRef << "=%" << aType;
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1148,7 +1148,7 @@ void DDF_IOStream::WritePersistentObjectHeader(const Standard_Integer aRef,
 void DDF_IOStream::BeginWritePersistentObjectData() 
 {
   *myOStream << "( ";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1159,7 +1159,7 @@ void DDF_IOStream::BeginWritePersistentObjectData()
 void DDF_IOStream::BeginWriteObjectData() 
 {
   *myOStream << "( ";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1170,7 +1170,7 @@ void DDF_IOStream::BeginWriteObjectData()
 void DDF_IOStream::EndWriteObjectData() 
 {
   *myOStream << ") ";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1181,7 +1181,7 @@ void DDF_IOStream::EndWriteObjectData()
 void DDF_IOStream::EndWritePersistentObjectData() 
 {
   *myOStream << ")";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1192,7 +1192,7 @@ void DDF_IOStream::EndWritePersistentObjectData()
 Storage_Error DDF_IOStream::EndWriteDataSection() 
 {
   *myOStream << "\nEND_DATA_SECTION\n";
-  if (myOStream->bad()) Storage_StreamWriteError::Raise();
+  if (myOStream->bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -1222,17 +1222,17 @@ void DDF_IOStream::ReadPersistentObjectHeader(Standard_Integer& aRef,
 
   while (c != '#') {
     if (IsEnd() || (c != ' ') || (c == '\n')) {
-      Storage_StreamFormatError::Raise();
+      throw Storage_StreamFormatError();
     }
     myIStream->get(c);
   }
 
-  if (!(*myIStream >> aRef)) Storage_StreamTypeMismatchError::Raise("ReadPersistentObjectHeader 1");
+  if (!(*myIStream >> aRef)) throw Storage_StreamTypeMismatchError("ReadPersistentObjectHeader 1");
   myIStream->get(c);
 
   while (c != '=') {
     if (IsEnd() || (c != ' ') || (c == '\n')) {
-      Storage_StreamFormatError::Raise();
+      throw Storage_StreamFormatError();
     }
     myIStream->get(c);
   }
@@ -1241,12 +1241,12 @@ void DDF_IOStream::ReadPersistentObjectHeader(Standard_Integer& aRef,
 
   while (c != '%') {
     if (IsEnd() || (c != ' ') || (c == '\n')) {
-      Storage_StreamFormatError::Raise();
+      throw Storage_StreamFormatError();
     }
     myIStream->get(c);
   }
 
-  if (!(*myIStream >> aType)) Storage_StreamTypeMismatchError::Raise("ReadPersistentObjectHeader 2");
+  if (!(*myIStream >> aType)) throw Storage_StreamTypeMismatchError("ReadPersistentObjectHeader 2");
 }
 
 //=======================================================================
@@ -1260,7 +1260,7 @@ void DDF_IOStream::BeginReadPersistentObjectData()
   myIStream->get(c);
   while (c != '(') {
     if (IsEnd() || (c != ' ') || (c == '\n')) {
-      Storage_StreamFormatError::Raise();
+      throw Storage_StreamFormatError();
     }
     myIStream->get(c);
   }
@@ -1277,7 +1277,7 @@ void DDF_IOStream::BeginReadObjectData()
   myIStream->get(c);
   while (c != '(') {
     if (IsEnd() || (c != ' ') || (c == '\n')) {
-      Storage_StreamFormatError::Raise("BeginReadObjectData");
+      throw Storage_StreamFormatError("BeginReadObjectData");
     }
     myIStream->get(c);
   }
@@ -1294,7 +1294,7 @@ void DDF_IOStream::EndReadObjectData()
   myIStream->get(c);
   while (c != ')') {
     if (IsEnd() || (c != ' ') || (c == '\n')) {
-      Storage_StreamFormatError::Raise("EndReadObjectData");
+      throw Storage_StreamFormatError("EndReadObjectData");
     }
     myIStream->get(c);
   }
@@ -1312,7 +1312,7 @@ void DDF_IOStream::EndReadPersistentObjectData()
   myIStream->get(c);
   while (c != ')') {
     if (IsEnd() || (c != ' ') || (c == '\n')) {
-      Storage_StreamFormatError::Raise("EndReadPersistentObjectData");
+      throw Storage_StreamFormatError("EndReadPersistentObjectData");
     }
     myIStream->get(c);
   }
@@ -1320,7 +1320,7 @@ void DDF_IOStream::EndReadPersistentObjectData()
   myIStream->get(c);
   while (c != '\n') {
     if (IsEnd() || (c != ' ')) {
-      Storage_StreamFormatError::Raise();
+      throw Storage_StreamFormatError();
     }
     myIStream->get(c);
   }
index aefe5e7..9d92585 100644 (file)
@@ -80,7 +80,7 @@ static Standard_Integer DDocStd_DumpCommand (Draw_Interpretor& di,
       else if (AD->IsKind(STANDARD_TYPE(TDF_DeltaOnRemoval)))      {removed.Append(AD);}
       else if (AD->IsKind(STANDARD_TYPE(TDF_DeltaOnModification))) {modified.Append(AD);}
       else {
-       Standard_DomainError::Raise("DDocStd_DumpCommand : unknown delta");
+       throw Standard_DomainError("DDocStd_DumpCommand : unknown delta");
       }
     }
     //
index cc4645b..487be22 100644 (file)
@@ -1948,13 +1948,9 @@ static Standard_Integer DNaming_TestSingle (Draw_Interpretor& theDI,
                isSelected = MakeXSelection(auxObj, aCurShape, aCntObj, Geometry, Orientation);
            }
        }
-       catch (Standard_Failure) {
-         Handle(Standard_Failure) aFailure =  Standard_Failure::Caught();
+       catch (Standard_Failure const& anException) {
          cout << "%%%INFO:Error: ::TestSingleSelection failed :";
-         if (!aFailure.IsNull()) 
-           cout << aFailure->GetMessageString() << endl;
-         else
-           cout << "%%%INFO:Error: ::TestSingleSelection : Standard_Failure with null caught failure"<< endl;
+         cout << anException.GetMessageString() << endl;
        }
        catch(...) {
          cout << "%%%INFO:Error: ::TestSingleSelection selection failed : unknown exception type";
@@ -2086,13 +2082,9 @@ static Standard_Integer DNaming_Multiple (Draw_Interpretor& theDI,
                isSelected = MakeXSelection(auxObj, aCurShape, aCntObj, Geometry, Orientation);
            }
        }
-       catch (Standard_Failure) {
-         Handle(Standard_Failure) aFailure =  Standard_Failure::Caught();
+       catch (Standard_Failure const& anException) {
          cout << "%%%INFO:Error: ::TestSingleSelection failed :";
-         if (!aFailure.IsNull()) 
-           cout << aFailure->GetMessageString() << endl;
-         else
-           cout << "%%%INFO:Error: ::TestSingleSelection : Standard_Failure with null caught failure"<< endl;
+         cout << anException.GetMessageString() << endl;
        }
        catch(...) {
          cout << "%%%INFO:Error: ::TestSingleSelection selection failed : unknown exception type";
index 4c0eb9d..7128b65 100644 (file)
@@ -139,7 +139,7 @@ Standard_Integer DNaming_TransformationDriver::Execute(Handle(TFunction_Logbook)
       Handle(TDataStd_UAttribute) aLineObj  = DNaming::GetObjectArg(aFunction, PTRANSF_LINE);
       Handle(TNaming_NamedShape) aLineNS = DNaming::GetObjectValue(aLineObj);
       gp_Ax1 anAxis;
-      if(!DNaming::ComputeAxis(aLineNS, anAxis)) Standard_Failure::Raise();
+      if(!DNaming::ComputeAxis(aLineNS, anAxis)) throw Standard_Failure();
       gp_Vec aVector(anAxis.Direction());
       aVector.Normalize();
       Standard_Real anOffset = DNaming::GetReal(aFunction,PTRANSF_OFF)->Get();
@@ -150,7 +150,7 @@ Standard_Integer DNaming_TransformationDriver::Execute(Handle(TFunction_Logbook)
       Handle(TDataStd_UAttribute) aLineObj  = DNaming::GetObjectArg(aFunction, PTRANSF_LINE);
       Handle(TNaming_NamedShape) aLineNS = DNaming::GetObjectValue(aLineObj);
       gp_Ax1 anAxis;
-      if(!DNaming::ComputeAxis(aLineNS, anAxis)) Standard_Failure::Raise();
+      if(!DNaming::ComputeAxis(aLineNS, anAxis)) throw Standard_Failure();
 
       Standard_Real anAngle = DNaming::GetReal(aFunction,PTRANSF_ANG)->Get();
       aTransformation.SetRotation(anAxis, anAngle);
@@ -159,11 +159,11 @@ Standard_Integer DNaming_TransformationDriver::Execute(Handle(TFunction_Logbook)
       Handle(TNaming_NamedShape) aNS = DNaming::GetObjectValue(aPlaneObj);
       
       if(aNS.IsNull() ||  aNS->IsEmpty() || aNS->Get().IsNull() || 
-        aNS->Get().ShapeType() != TopAbs_FACE) Standard_Failure::Raise();
+        aNS->Get().ShapeType() != TopAbs_FACE) throw Standard_Failure();
       TopoDS_Face aFace = TopoDS::Face(aNS->Get());
       Handle(Geom_Surface) aSurf = BRep_Tool::Surface(aFace);
       GeomLib_IsPlanarSurface isPlanarSurface (aSurf);
-      if(!isPlanarSurface.IsPlanar()) Standard_Failure::Raise();
+      if(!isPlanarSurface.IsPlanar()) throw Standard_Failure();
       gp_Pln aPlane = isPlanarSurface.Plan();
       gp_Ax2 aMirrorAx2 = aPlane.Position().Ax2();
       aTransformation.SetMirror(aMirrorAx2);
index 48ebb45..9f8bf52 100644 (file)
@@ -48,7 +48,7 @@ Standard_Real Draft::Angle(const TopoDS_Face& F,
   if (TypeS != STANDARD_TYPE(Geom_Plane) &&
       TypeS != STANDARD_TYPE(Geom_ConicalSurface) &&
       TypeS != STANDARD_TYPE(Geom_CylindricalSurface)) {
-    Standard_DomainError::Raise();
+    throw Standard_DomainError();
   }
 
   Standard_Real Angle;
@@ -68,7 +68,7 @@ Standard_Real Draft::Angle(const TopoDS_Face& F,
     gp_Cylinder Cy(Handle(Geom_CylindricalSurface)::DownCast(S)->Cylinder());
     Standard_Real testdir = D.Dot(Cy.Axis().Direction());
     if (Abs(testdir) <= 1.-Precision::Angular()) {
-      Standard_DomainError::Raise();
+      throw Standard_DomainError();
     }
     Angle = 0.;
   }
@@ -76,7 +76,7 @@ Standard_Real Draft::Angle(const TopoDS_Face& F,
     gp_Cone Co(Handle(Geom_ConicalSurface)::DownCast(S)->Cone());
     Standard_Real testdir = D.Dot(Co.Axis().Direction());
     if (Abs(testdir) <= 1.-Precision::Angular()) {
-      Standard_DomainError::Raise();
+      throw Standard_DomainError();
     }
     Standard_Real umin,umax,vmin,vmax;
     BRepTools::UVBounds(F,umin,umax,vmin,vmax);
index 8273692..c61e9c5 100644 (file)
@@ -111,7 +111,7 @@ Standard_Boolean Draft_Modification::Add(const TopoDS_Face& F,
   const Standard_Boolean Flag)
 {
   if (!badShape.IsNull()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   if (myComp) {
@@ -130,7 +130,7 @@ Standard_Boolean Draft_Modification::Add(const TopoDS_Face& F,
 void Draft_Modification::Remove(const TopoDS_Face& F)
 {
   if (!myFMap.Contains(F) || myComp) {
-    Standard_NoSuchObject::Raise();
+    throw Standard_NoSuchObject();
   }
 
   conneF.Clear();
@@ -229,10 +229,10 @@ const TopoDS_Shape& Draft_Modification::ProblematicShape() const
 const TopTools_ListOfShape & Draft_Modification::ConnectedFaces(const TopoDS_Face& F)
 {
   if (!myFMap.Contains(F)) {
-    Standard_NoSuchObject::Raise();
+    throw Standard_NoSuchObject();
   }
   if (!IsDone()) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   conneF.Clear();
   curFace = myFMap.FindFromKey(F).RootFace();
@@ -259,7 +259,7 @@ const TopTools_ListOfShape & Draft_Modification::ConnectedFaces(const TopoDS_Fac
 const TopTools_ListOfShape & Draft_Modification::ModifiedFaces()
 {
   if (!badShape.IsNull()) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   conneF.Clear();
 
@@ -289,7 +289,7 @@ Standard_Boolean Draft_Modification::NewSurface(const TopoDS_Face& F,
   Standard_Boolean& RevWires,
   Standard_Boolean& RevFace)
 {
-  if (!IsDone()) {Standard_DomainError::Raise();}
+  if (!IsDone()) {throw Standard_DomainError();}
 
   if (!myFMap.Contains(F) || !myFMap.FindFromKey(F).NewGeometry()) {
     return Standard_False;
@@ -319,7 +319,7 @@ Standard_Boolean Draft_Modification::NewCurve(const TopoDS_Edge& E,
   TopLoc_Location& L, 
   Standard_Real& Tol)
 {
-  if (!IsDone()) {Standard_DomainError::Raise();}
+  if (!IsDone()) {throw Standard_DomainError();}
 
   if (!myEMap.Contains(E)) 
     return Standard_False;
@@ -347,7 +347,7 @@ Standard_Boolean Draft_Modification::NewPoint(const TopoDS_Vertex& V,
   gp_Pnt& P, 
   Standard_Real& Tol)
 {
-  if (!IsDone()) {Standard_DomainError::Raise();};
+  if (!IsDone()) {throw Standard_DomainError();};
 
   if (!myVMap.Contains(V)) {
     return Standard_False;
@@ -372,7 +372,7 @@ Standard_Boolean Draft_Modification::NewCurve2d(const TopoDS_Edge& E,
   Standard_Real& Tol)
 {
 
-  if (!IsDone()) {Standard_DomainError::Raise();};
+  if (!IsDone()) {throw Standard_DomainError();};
 
   if (!myEMap.Contains(E)) {
     return Standard_False;
@@ -479,7 +479,7 @@ Standard_Boolean Draft_Modification::NewParameter(const TopoDS_Vertex& V,
   Standard_Real& Tol)
 {
 
-  if (!IsDone()) {Standard_DomainError::Raise();};
+  if (!IsDone()) {throw Standard_DomainError();};
 
   if (!myVMap.Contains(V)) {
     return Standard_False;
index 26bd310..4581de9 100644 (file)
@@ -691,7 +691,7 @@ Standard_Boolean Draft_Modification::Propagate ()
 
 void Draft_Modification::Perform ()
 {
-  if (!badShape.IsNull())  Standard_ConstructionError::Raise();
+  if (!badShape.IsNull())  throw Standard_ConstructionError();
 
   if (!myComp) {
     myComp = Standard_True;
@@ -2066,7 +2066,7 @@ static Standard_Real Parameter(const Handle(Geom_Curve)& C,
     GeomAdaptor_Curve TheCurve(C);
     Extrema_ExtPC myExtPC(P,TheCurve);
     if (!myExtPC.IsDone()) {
-      Standard_Failure::Raise("Draft_Modification_1::Parameter: ExtremaPC not done.");
+      throw Standard_Failure("Draft_Modification_1::Parameter: ExtremaPC not done.");
     }
     if (myExtPC.NbExt() >= 1) {
       Standard_Real Dist2, Dist2Min = myExtPC.SquareDistance(1);
index b677a72..98cb57a 100644 (file)
@@ -85,7 +85,7 @@ Standard_Real Draft_VertexInfo::Parameter (const TopoDS_Edge& E)
       return itp.Value();
     }
   }
-  Standard_DomainError::Raise(); return 0;
+  throw Standard_DomainError();
 }
 
 
@@ -103,7 +103,7 @@ Standard_Real& Draft_VertexInfo::ChangeParameter (const TopoDS_Edge& E)
       return itp.Value();
     }
   }
-  Standard_DomainError::Raise(); return itp.Value();
+  throw Standard_DomainError();
 }
 
 
index f1d7989..4baf75f 100644 (file)
@@ -515,7 +515,7 @@ void Draw::Load(Draw_Interpretor& theDI, const TCollection_AsciiString& theKey,
       Standard_SStream aMsg; aMsg << "Could not find the resource:";
       aMsg << theKey.ToCString()<< endl;
       cout << "could not find the resource:"<<theKey.ToCString()<< endl;
-      Draw_Failure::Raise(aMsg);
+      throw Draw_Failure(aMsg.str().c_str());
     }
 
     TCollection_AsciiString aPluginLibrary("");
@@ -542,7 +542,7 @@ void Draw::Load(Draw_Interpretor& theDI, const TCollection_AsciiString& theKey,
 #ifdef OCCT_DEBUG
       cout << "could not open: "  << aPluginResource->Value(theKey.ToCString())<< " ; reason: "<< error.ToCString() << endl;
 #endif
-      Draw_Failure::Raise(aMsg);
+      throw Draw_Failure(aMsg.str().c_str());
     }
     f = aSharedLibrary.DlSymb("PLUGINFACTORY");
     if( f == NULL ) {
@@ -550,7 +550,7 @@ void Draw::Load(Draw_Interpretor& theDI, const TCollection_AsciiString& theKey,
       Standard_SStream aMsg; aMsg << "Could not find the factory in: ";
       aMsg << aPluginResource->Value(theKey.ToCString());
       aMsg << error.ToCString();
-      Draw_Failure::Raise(aMsg);
+      throw Draw_Failure(aMsg.str().c_str());
     }
     theMapOfFunctions.Bind(theKey, f);
   }
index 87407e7..2eb08cb 100644 (file)
@@ -36,8 +36,8 @@ Standard_EXPORT const char* Draw_Eval (const char *theCommandStr)
     cout << theCommands.Result() << endl;
     return theCommands.Result();
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    return Standard_Failure::Caught()->GetMessageString();
+    return anException.GetMessageString();
   }
 }
index 8733847..6f7e831 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Draw_Failure, Standard_Failure)
 
 #if !defined No_Exception && !defined No_Draw_Failure
   #define Draw_Failure_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Draw_Failure::Raise(MESSAGE);
+  if (CONDITION) throw Draw_Failure(MESSAGE);
 #else
   #define Draw_Failure_Raise_if(CONDITION, MESSAGE)
 #endif
index 0b696b6..d84973e 100644 (file)
@@ -167,10 +167,7 @@ static Standard_Integer CommandCmd
     if (fres != 0) 
       code = TCL_ERROR;
   }
-  catch (Standard_Failure) {
-
-    Handle(Standard_Failure) E = Standard_Failure::Caught();
-
+  catch (Standard_Failure const& anException) {
     // fail if Draw_ExitOnCatch is set
     // MKV 29.03.05
 #if ((TCL_MAJOR_VERSION > 8) || ((TCL_MAJOR_VERSION == 8) && (TCL_MINOR_VERSION >= 4))) && !defined(USE_NON_CONST)
@@ -181,7 +178,7 @@ static Standard_Integer CommandCmd
                          "Draw_ExitOnCatch",TCL_GLOBAL_ONLY);
 #endif
 
-    cout << "An exception was caught " << E << endl;
+    cout << "An exception was caught " << anException << endl;
 
     if (cc && Draw::Atoi(cc)) {
 #ifdef _WIN32
@@ -193,7 +190,7 @@ static Standard_Integer CommandCmd
 
     // get the error message
     Standard_SStream ss;
-    ss << "** Exception ** " << E << ends;
+    ss << "** Exception ** " << anException << ends;
     Tcl_SetResult(interp,(char*)(ss.str().c_str()),TCL_VOLATILE);
     code = TCL_ERROR;
   }
index b2a86de..2100a35 100644 (file)
@@ -133,7 +133,7 @@ Standard_Boolean DrawDim::Lin (const TopoDS_Edge& e,
       return Standard_True;
     }
     else if (vf.IsNull() || vl.IsNull()) {
-      Standard_DomainError::Raise("DrawDim::Lin : semi infinite edge");
+      throw Standard_DomainError("DrawDim::Lin : semi infinite edge");
     }
     else {    
       l = L->Lin();   
index ad947f4..2265c4f 100644 (file)
@@ -54,7 +54,7 @@ void DrawDim_Dimension::SetValue (const Standard_Real avalue)
 
 Standard_Real DrawDim_Dimension::GetValue() const 
 {
-  if (!is_valued) Standard_DomainError::Raise();
+  if (!is_valued) throw Standard_DomainError();
   return myValue;
 }
 
index 75680aa..fe1667b 100644 (file)
@@ -51,9 +51,9 @@ const char* DrawTrSurf_Set (const char* theNameStr, void* theHandlePtr)
 
     return "Error: Not a geometric object";
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    return Standard_Failure::Caught()->GetMessageString();
+    return anException.GetMessageString();
   }
 }
 
@@ -71,9 +71,9 @@ const char* DrawTrSurf_SetPnt (const char* theNameStr, void* thePntPtr)
     DrawTrSurf::Set (theNameStr, aP);
     return buff;
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    return Standard_Failure::Caught()->GetMessageString();
+    return anException.GetMessageString();
   }
 }
 
@@ -91,9 +91,9 @@ const char* DrawTrSurf_SetPnt2d (const char* theNameStr, void* thePnt2dPtr)
     DrawTrSurf::Set (theNameStr, aP);
     return buff;
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    return Standard_Failure::Caught()->GetMessageString();
+    return anException.GetMessageString();
   }
 }
 
index ad41be8..43083e8 100644 (file)
@@ -30,10 +30,10 @@ void Expr_BinaryExpression::SetFirstOperand (const Handle(Expr_GeneralExpression
   Handle(Expr_BinaryExpression) me;
   me = this;
   if (exp == me) {
-    Expr_InvalidOperand::Raise();
+    throw Expr_InvalidOperand();
   }
   if (exp->Contains(me)) {
-    Expr_InvalidOperand::Raise();
+    throw Expr_InvalidOperand();
   }
   myFirstOperand = exp;
 }
@@ -43,10 +43,10 @@ void Expr_BinaryExpression::SetSecondOperand (const Handle(Expr_GeneralExpressio
   Handle(Expr_BinaryExpression) me;
   me = this;
   if (exp == me) {
-    Expr_InvalidOperand::Raise();
+    throw Expr_InvalidOperand();
   }
   if (exp->Contains(me)) {
-    Expr_InvalidOperand::Raise();
+    throw Expr_InvalidOperand();
   }
   mySecondOperand = exp;
 }
@@ -76,10 +76,9 @@ const Handle(Expr_GeneralExpression)& Expr_BinaryExpression::SubExpression (cons
       return mySecondOperand;
     }
     else {
-      Standard_OutOfRange::Raise();
+      throw Standard_OutOfRange();
     }
   }
- return *(  ( Handle(Expr_GeneralExpression)* )NULL  );
 }
 
 Standard_Boolean Expr_BinaryExpression::ContainsUnknowns () const
index 6a41e08..1557944 100644 (file)
@@ -43,7 +43,7 @@ IMPLEMENT_STANDARD_RTTIEXT(Expr_BinaryFunction,Expr_BinaryExpression)
 Expr_BinaryFunction::Expr_BinaryFunction (const Handle(Expr_GeneralFunction)& func, const Handle(Expr_GeneralExpression)& exp1, const Handle(Expr_GeneralExpression)& exp2)
 {
   if (func->NbOfVariables() != 2) {
-    Expr_InvalidFunction::Raise();
+    throw Expr_InvalidFunction();
   }
   myFunction = func;
   CreateFirstOperand(exp1);
index d2d1258..a4bd9bf 100644 (file)
@@ -136,7 +136,7 @@ Handle(Expr_GeneralExpression) Expr_Difference::Derivative (const Handle(Expr_Na
 Handle(Expr_GeneralExpression) Expr_Difference::NDerivative (const Handle(Expr_NamedUnknown)& X, const Standard_Integer N) const
 {
   if (N <= 0) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   if (!Contains(X)) {
     return new Expr_NumericValue(0.0);
index c8bb746..d7f8d79 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Expr_ExprFailure, Standard_Failure)
 
 #if !defined No_Exception && !defined No_Expr_ExprFailure
   #define Expr_ExprFailure_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Expr_ExprFailure::Raise(MESSAGE);
+  if (CONDITION) throw Expr_ExprFailure(MESSAGE);
 #else
   #define Expr_ExprFailure_Raise_if(CONDITION, MESSAGE)
 #endif
index 0ee80e4..86f28e7 100644 (file)
@@ -36,7 +36,7 @@ Expr_FunctionDerivative::Expr_FunctionDerivative (const Handle(Expr_GeneralFunct
   myFunction = func;
   myDerivate = withX;
   if (deg <= 0) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   myDegree = deg;
   UpdateExpression();
@@ -55,7 +55,7 @@ Handle(Expr_NamedUnknown) Expr_FunctionDerivative::Variable (const Standard_Inte
 Standard_Real Expr_FunctionDerivative::Evaluate (const Expr_Array1OfNamedUnknown& vars, const TColStd_Array1OfReal& values) const
 {
   if (vars.Length() != values.Length()) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return myExp->Evaluate(vars,values);
 }
index 77b1861..4103db7 100644 (file)
@@ -34,7 +34,7 @@ Standard_Boolean Expr_GeneralExpression::IsShareable() const
  Handle(Expr_GeneralExpression) Expr_GeneralExpression::NDerivative (const Handle(Expr_NamedUnknown)& X, const Standard_Integer N) const
  {
    if (N <= 0) {
-     Standard_OutOfRange::Raise();
+     throw Standard_OutOfRange();
    }
    Handle(Expr_GeneralExpression) first = Derivative(X);
    if (N > 1) {
@@ -47,7 +47,7 @@ Standard_Boolean Expr_GeneralExpression::IsShareable() const
  Standard_Real Expr_GeneralExpression::EvaluateNumeric() const
  {
    if (ContainsUnknowns()) {
-     Expr_NotEvaluable::Raise();
+     throw Expr_NotEvaluable();
    }
    Expr_Array1OfNamedUnknown tabvr(1,1);
    TColStd_Array1OfReal tabvl(1,1);
index a11a665..5150baa 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Expr_InvalidAssignment, Expr_ExprFailure)
 
 #if !defined No_Exception && !defined No_Expr_InvalidAssignment
   #define Expr_InvalidAssignment_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Expr_InvalidAssignment::Raise(MESSAGE);
+  if (CONDITION) throw Expr_InvalidAssignment(MESSAGE);
 #else
   #define Expr_InvalidAssignment_Raise_if(CONDITION, MESSAGE)
 #endif
index 285eb2a..04c3d59 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Expr_InvalidFunction, Expr_ExprFailure)
 
 #if !defined No_Exception && !defined No_Expr_InvalidFunction
   #define Expr_InvalidFunction_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Expr_InvalidFunction::Raise(MESSAGE);
+  if (CONDITION) throw Expr_InvalidFunction(MESSAGE);
 #else
   #define Expr_InvalidFunction_Raise_if(CONDITION, MESSAGE)
 #endif
index 2653368..9c3dd9c 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Expr_InvalidOperand, Expr_ExprFailure)
 
 #if !defined No_Exception && !defined No_Expr_InvalidOperand
   #define Expr_InvalidOperand_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Expr_InvalidOperand::Raise(MESSAGE);
+  if (CONDITION) throw Expr_InvalidOperand(MESSAGE);
 #else
   #define Expr_InvalidOperand_Raise_if(CONDITION, MESSAGE)
 #endif
index fd413f6..ee3631c 100644 (file)
@@ -33,9 +33,7 @@ Expr_NamedConstant::Expr_NamedConstant(const TCollection_AsciiString& name, cons
 
 const Handle(Expr_GeneralExpression)& Expr_NamedConstant::SubExpression (const Standard_Integer ) const
 {
- Standard_OutOfRange::Raise();
- Handle(Expr_GeneralExpression)* bid = new Handle(Expr_GeneralExpression);
- return *bid;
+ throw Standard_OutOfRange();
 }
 
 Handle(Expr_GeneralExpression) Expr_NamedConstant::Simplified () const
index 4408817..7856260 100644 (file)
@@ -63,7 +63,7 @@ Handle(Expr_NamedUnknown) Expr_NamedFunction::Variable (const Standard_Integer i
 Standard_Real Expr_NamedFunction::Evaluate (const Expr_Array1OfNamedUnknown& vars, const TColStd_Array1OfReal& values) const
 {
   if (vars.Length() != values.Length()) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return myExp->Evaluate(vars,values);
 }
index 7415120..41385a1 100644 (file)
@@ -39,7 +39,7 @@ Expr_NamedUnknown::Expr_NamedUnknown(const TCollection_AsciiString& name)
 const Handle(Expr_GeneralExpression)& Expr_NamedUnknown::AssignedExpression () const
 {
   if (!IsAssigned()) {
-    Expr_NotAssigned::Raise();
+    throw Expr_NotAssigned();
   }
   return myExpression;
 }
@@ -48,7 +48,7 @@ void Expr_NamedUnknown::Assign (const Handle(Expr_GeneralExpression)& exp)
 {
   Handle(Expr_NamedUnknown) me = this;
   if (exp->Contains(me)) {
-    Expr_InvalidAssignment::Raise();
+    throw Expr_InvalidAssignment();
   }
   myExpression = exp;
 }
@@ -57,10 +57,10 @@ void Expr_NamedUnknown::Assign (const Handle(Expr_GeneralExpression)& exp)
 const Handle(Expr_GeneralExpression)& Expr_NamedUnknown::SubExpression (const Standard_Integer I) const
 {
   if (!IsAssigned()) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   if (I != 1) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return AssignedExpression();
 }
@@ -149,7 +149,7 @@ void Expr_NamedUnknown::Replace (const Handle(Expr_NamedUnknown)& var, const Han
     if (myExpression == var) {
       Handle(Expr_NamedUnknown) me = this;
       if (with->Contains(me)) {
-       Expr_InvalidOperand::Raise();
+       throw Expr_InvalidOperand();
       }
       Assign(with);
     }
@@ -180,7 +180,7 @@ Standard_Real Expr_NamedUnknown::Evaluate(const Expr_Array1OfNamedUnknown& vars,
        return vals(i-vars.Lower()+vals.Lower());
       }
     }
-    Expr_NotEvaluable::Raise();
+    throw Expr_NotEvaluable();
   }
   return myExpression->Evaluate(vars,vals);
 }
index 5e61253..5abcb99 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Expr_NotAssigned, Expr_ExprFailure)
 
 #if !defined No_Exception && !defined No_Expr_NotAssigned
   #define Expr_NotAssigned_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Expr_NotAssigned::Raise(MESSAGE);
+  if (CONDITION) throw Expr_NotAssigned(MESSAGE);
 #else
   #define Expr_NotAssigned_Raise_if(CONDITION, MESSAGE)
 #endif
index 6df3679..775eefa 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Expr_NotEvaluable, Expr_ExprFailure)
 
 #if !defined No_Exception && !defined No_Expr_NotEvaluable
   #define Expr_NotEvaluable_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Expr_NotEvaluable::Raise(MESSAGE);
+  if (CONDITION) throw Expr_NotEvaluable(MESSAGE);
 #else
   #define Expr_NotEvaluable_Raise_if(CONDITION, MESSAGE)
 #endif
index 284c2c2..43c9f5f 100644 (file)
@@ -47,9 +47,7 @@ Standard_Integer Expr_NumericValue::NbSubExpressions() const
 
 const Handle(Expr_GeneralExpression)& Expr_NumericValue::SubExpression(const Standard_Integer) const
 {
-  Standard_OutOfRange::Raise();
-  Handle(Expr_GeneralExpression)* bid=NULL;
-  return *bid;
+  throw Standard_OutOfRange();
 }
 
 Handle(Expr_GeneralExpression) Expr_NumericValue::Simplified() const
index 186a1cb..3bd37ec 100644 (file)
@@ -39,10 +39,10 @@ void Expr_PolyExpression::SetOperand (const Handle(Expr_GeneralExpression)& exp,
 {
   Handle(Expr_PolyExpression) me = this;
   if (exp == me) {
-    Expr_InvalidOperand::Raise();
+    throw Expr_InvalidOperand();
   }
   if (exp->Contains(me)) {
-    Expr_InvalidOperand::Raise();
+    throw Expr_InvalidOperand();
   }
   myOperands(index) = exp;
 }
@@ -55,7 +55,7 @@ void Expr_PolyExpression::AddOperand (const Handle(Expr_GeneralExpression)& exp)
 void Expr_PolyExpression::RemoveOperand (const Standard_Integer index)
 {
   if (myOperands.Length() <= 2) {
-    Standard_DimensionMismatch::Raise();
+    throw Standard_DimensionMismatch();
   }
   myOperands.Remove(index);
 }
index 57ed6e4..a8df5a1 100644 (file)
@@ -61,7 +61,7 @@ Standard_Boolean Expr_RUIterator::More () const
 void Expr_RUIterator::Next ()
 {
   if (!More()) {
-    Standard_NoMoreObject::Raise();
+    throw Standard_NoMoreObject();
   }
   myCurrent++;
 }
index 468ccdd..28eb3ed 100644 (file)
@@ -57,7 +57,7 @@ Standard_Boolean Expr_RelationIterator::More () const
 void Expr_RelationIterator::Next ()
 {
   if (!More()) {
-    Standard_NoMoreObject::Raise();
+    throw Standard_NoMoreObject();
   }
   current++;
 }
@@ -65,7 +65,7 @@ void Expr_RelationIterator::Next ()
 Handle(Expr_SingleRelation) Expr_RelationIterator::Value () const
 {
   if (!More()) {
-    Standard_NoSuchObject::Raise();
+    throw Standard_NoSuchObject();
   }
   return myRelation(current);
 }
index 4a29c10..7690959 100644 (file)
@@ -96,9 +96,7 @@ Standard_Integer Expr_SingleRelation::NbOfSubRelations () const
 
 Handle(Expr_GeneralRelation) Expr_SingleRelation::SubRelation (const Standard_Integer ) const
 {
- Standard_OutOfRange::Raise();
- Handle(Expr_GeneralRelation) bid;
- return bid;
+ throw Standard_OutOfRange();
 }
 
 Standard_Integer Expr_SingleRelation::NbOfSingleRelations() const
index b1aa2b6..f3a1889 100644 (file)
@@ -125,7 +125,7 @@ Handle(Expr_GeneralExpression) Expr_Sum::Derivative (const Handle(Expr_NamedUnkn
 Handle(Expr_GeneralExpression) Expr_Sum::NDerivative (const Handle(Expr_NamedUnknown)& X, const Standard_Integer N) const
 {
   if (N <= 0) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   Expr_SequenceOfGeneralExpression opsder;
   Standard_Integer i;
index a754e95..40241b8 100644 (file)
@@ -51,10 +51,10 @@ void Expr_SystemRelation::Remove (const Handle(Expr_GeneralRelation)& relation)
   }
 
   if (alreadyHere) {
-    Standard_NoSuchObject::Raise();
+    throw Standard_NoSuchObject();
   }
   if (myRelations.Length() <= 1) {
-    Standard_DimensionMismatch::Raise();
+    throw Standard_DimensionMismatch();
   }
   myRelations.Remove(position);
 }
index 4266037..2dc22f9 100644 (file)
@@ -29,10 +29,10 @@ void Expr_UnaryExpression::SetOperand (const Handle(Expr_GeneralExpression)& exp
 {
   Handle(Expr_UnaryExpression) me = this;
   if (exp == me) {
-    Expr_InvalidOperand::Raise();
+    throw Expr_InvalidOperand();
   }
   if (exp->Contains(me)) {
-    Expr_InvalidOperand::Raise();
+    throw Expr_InvalidOperand();
   }
   myOperand = exp;
 }
@@ -50,7 +50,7 @@ Standard_Integer Expr_UnaryExpression::NbSubExpressions () const
 const Handle(Expr_GeneralExpression)& Expr_UnaryExpression::SubExpression (const Standard_Integer I) const
 {
   if (I != 1) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return myOperand;
 }
index d6d431e..ab2c057 100644 (file)
@@ -42,7 +42,7 @@ IMPLEMENT_STANDARD_RTTIEXT(Expr_UnaryFunction,Expr_UnaryExpression)
 Expr_UnaryFunction::Expr_UnaryFunction (const Handle(Expr_GeneralFunction)& func, const Handle(Expr_GeneralExpression)& exp)
 {
   if (func->NbOfVariables() != 1) {
-    Expr_InvalidFunction::Raise();
+    throw Expr_InvalidFunction();
   }
   myFunction = func;
   CreateOperand(exp);
index 25ffe63..9273ca8 100644 (file)
@@ -79,7 +79,7 @@ Handle(Expr_GeneralExpression) Expr_UnaryMinus::Derivative (const Handle(Expr_Na
 Handle(Expr_GeneralExpression) Expr_UnaryMinus::NDerivative (const Handle(Expr_NamedUnknown)& X, const Standard_Integer N) const
 {
   if (N <= 0) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   Handle(Expr_GeneralExpression) myder = Operand();
   myder = myder->NDerivative(X,N);
index 40be0f9..27bbc35 100644 (file)
@@ -50,7 +50,7 @@ Standard_Boolean Expr_UnknownIterator::More() const
 void Expr_UnknownIterator::Next ()
 {
   if (!More()) {
-    Standard_NoMoreObject::Raise();
+    throw Standard_NoMoreObject();
   }
   myCurrent++;
 }
index 593b54f..c747a1e 100644 (file)
@@ -62,7 +62,7 @@ Standard_Boolean ExprIntrp_GenExp::IsDone() const
 Handle(Expr_GeneralExpression) ExprIntrp_GenExp::Expression () const
 {
   if (!done) {
-    Standard_NoSuchObject::Raise();
+    throw Standard_NoSuchObject();
   }
   return myExpression;
 }
index c101950..5a207ec 100644 (file)
@@ -61,7 +61,7 @@ Standard_Boolean ExprIntrp_GenRel::IsDone() const
 Handle(Expr_GeneralRelation) ExprIntrp_GenRel::Relation () const
 {
   if (!done) {
-    Standard_NoSuchObject::Raise();
+    throw Standard_NoSuchObject();
   }
   return myRelation;
 }
index 4603d01..8ac96bb 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(ExprIntrp_SyntaxError, Standard_Failure)
 
 #if !defined No_Exception && !defined No_ExprIntrp_SyntaxError
   #define ExprIntrp_SyntaxError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) ExprIntrp_SyntaxError::Raise(MESSAGE);
+  if (CONDITION) throw ExprIntrp_SyntaxError(MESSAGE);
 #else
   #define ExprIntrp_SyntaxError_Raise_if(CONDITION, MESSAGE)
 #endif
index 61df40a..e9f6d3c 100644 (file)
@@ -87,7 +87,7 @@ extern "C" void ExprIntrp_Derivation()
     namexp = new Expr_NamedUnknown(thename);
   }
   if (!namexp->IsKind(STANDARD_TYPE(Expr_NamedUnknown))) {
-    ExprIntrp_SyntaxError::Raise();
+    throw ExprIntrp_SyntaxError();
   }
   ExprIntrp_Recept.Push(namexp);
 }
@@ -119,7 +119,7 @@ extern "C" void ExprIntrp_DiffDegreeVar()
   const TCollection_AsciiString& aStr = ExprIntrp_GetResult();
   const char* s = aStr.ToCString();
   if ( *s != 'X' && *s != 'x' ) {
-    ExprIntrp_SyntaxError::Raise();
+    throw ExprIntrp_SyntaxError();
   }
   s++;
   Standard_Integer rank = atoi(s);
@@ -146,7 +146,7 @@ extern "C" void ExprIntrp_VerDiffDegree()
   Standard_Integer deg = aStr.IntegerValue();
   Standard_Integer thedeg = ExprIntrp_Recept.PopValue();
   if (deg != thedeg) {
-    ExprIntrp_SyntaxError::Raise();
+    throw ExprIntrp_SyntaxError();
   }
   ExprIntrp_Recept.PushValue(deg);
 }
@@ -156,7 +156,7 @@ extern "C" void ExprIntrp_EndDifferential()
   TCollection_AsciiString name = ExprIntrp_Recept.PopName();
   Handle(Expr_GeneralFunction) thefunc = ExprIntrp_Recept.GetFunction(name);
   if (thefunc.IsNull()) {
-    ExprIntrp_SyntaxError::Raise();
+    throw ExprIntrp_SyntaxError();
   }
   Standard_Integer rank,degree;
   Handle(Expr_NamedUnknown) thediff;
@@ -166,7 +166,7 @@ extern "C" void ExprIntrp_EndDifferential()
     rank = ExprIntrp_Recept.PopValue();
     degree = ExprIntrp_Recept.PopValue();
     if ((rank > nbvars) || (rank < 1)) {
-      ExprIntrp_SyntaxError::Raise();
+      throw ExprIntrp_SyntaxError();
     }
     thediff = thefunc->Variable(rank);
     thefunc = new Expr_FunctionDerivative(thefunc,thediff,degree);
@@ -178,7 +178,7 @@ extern "C" void ExprIntrp_EndDiffFunction()
 {
   Handle(Expr_GeneralFunction) thefunc = ExprIntrp_Recept.PopFunction();
   if (thefunc.IsNull()) {
-    ExprIntrp_SyntaxError::Raise();
+    throw ExprIntrp_SyntaxError();
   }
   Standard_Integer nbargs = thefunc->NbOfVariables();
   if (nbargs == 1) {
@@ -191,7 +191,7 @@ extern "C" void ExprIntrp_EndDiffFunction()
     Handle(Expr_GeneralExpression) arg2 = ExprIntrp_Recept.Pop();
     Handle(Expr_GeneralExpression) arg1 = ExprIntrp_Recept.Pop();
     if (arg1.IsNull()) {
-      ExprIntrp_SyntaxError::Raise();
+      throw ExprIntrp_SyntaxError();
     }
     Handle(Expr_BinaryFunction) res =
       new Expr_BinaryFunction(thefunc,arg1,arg2);
@@ -203,7 +203,7 @@ extern "C" void ExprIntrp_EndDiffFunction()
     for (Standard_Integer i = 1; i<= nbargs; i++) {
       arg = ExprIntrp_Recept.Pop();
       if (arg.IsNull()) {
-       ExprIntrp_SyntaxError::Raise();
+       throw ExprIntrp_SyntaxError();
       }
       tabarg(nbargs-i+1) = arg;
     }
@@ -289,7 +289,7 @@ extern "C" void ExprIntrp_EndDerFunction()
     Expr_UnknownIterator rit(resstand);
     while (rit.More()) {
       if (!var.IsNull()) {
-       ExprIntrp_SyntaxError::Raise();
+       throw ExprIntrp_SyntaxError();
       }
       else {
        var = rit.Value();
@@ -300,7 +300,7 @@ extern "C" void ExprIntrp_EndDerFunction()
       rit.Next();
     }
     if (var.IsNull()) {
-      ExprIntrp_SyntaxError::Raise();
+      throw ExprIntrp_SyntaxError();
     }
     else {
       Handle(Expr_GeneralExpression) res = resstand->NDerivative(var,ExprIntrp_Recept.PopValue());
@@ -310,11 +310,11 @@ extern "C" void ExprIntrp_EndDerFunction()
   else {
     Handle(Expr_NamedFunction) thefunc = ExprIntrp_Recept.GetFunction(name);
     if (thefunc.IsNull()) {
-      ExprIntrp_SyntaxError::Raise();
+      throw ExprIntrp_SyntaxError();
     }
     Standard_Integer nbargs = thefunc->NbOfVariables();
     if (nbargs != 1) {
-      ExprIntrp_SyntaxError::Raise();
+      throw ExprIntrp_SyntaxError();
     }
     Handle(Expr_NamedUnknown) var = thefunc->Variable(1);
     Handle(Expr_FunctionDerivative) thefuncder = 
@@ -337,7 +337,7 @@ extern "C" void ExprIntrp_EndFunction()
   else {
     Handle(Expr_NamedFunction) thefunc = ExprIntrp_Recept.GetFunction(name);
     if (thefunc.IsNull()) {
-      ExprIntrp_SyntaxError::Raise();
+      throw ExprIntrp_SyntaxError();
       }
     Standard_Integer nbargs = thefunc->NbOfVariables();
     if (nbargs == 1) {
@@ -348,7 +348,7 @@ extern "C" void ExprIntrp_EndFunction()
     else if (nbargs == 2) {
       Handle(Expr_GeneralExpression) arg1 = ExprIntrp_Recept.Pop();
       if (arg1.IsNull()) {
-       ExprIntrp_SyntaxError::Raise();
+       throw ExprIntrp_SyntaxError();
       }
       Handle(Expr_BinaryFunction) res =
        new Expr_BinaryFunction(thefunc,arg1,op);
@@ -361,7 +361,7 @@ extern "C" void ExprIntrp_EndFunction()
       for (Standard_Integer i = 1; i< nbargs; i++) {
        arg = ExprIntrp_Recept.Pop();
        if (arg.IsNull()) {
-         ExprIntrp_SyntaxError::Raise();
+         throw ExprIntrp_SyntaxError();
        }
        tabarg(nbargs-i) = arg;
       }
@@ -465,10 +465,10 @@ extern "C" void ExprIntrp_Deassign()
   const TCollection_AsciiString& thename = ExprIntrp_GetResult();
   Handle(Expr_NamedExpression) nameexp = ExprIntrp_Recept.GetNamed(thename);
   if (nameexp.IsNull()) {
-    ExprIntrp_SyntaxError::Raise();
+    throw ExprIntrp_SyntaxError();
   }
   if (!nameexp->IsKind(STANDARD_TYPE(Expr_NamedUnknown))) {
-    ExprIntrp_SyntaxError::Raise();
+    throw ExprIntrp_SyntaxError();
   }
   Handle(Expr_NamedUnknown) var = Handle(Expr_NamedUnknown)::DownCast(nameexp);
   var->Deassign();
@@ -488,7 +488,7 @@ extern "C" void ExprIntrp_close()
 extern "C" void ExprIntrperror(char* msg)
 {
   ExprIntrp_close();
-  ExprIntrp_SyntaxError::Raise(msg);
+  throw ExprIntrp_SyntaxError(msg);
 }
 
 
@@ -537,7 +537,7 @@ extern "C" void ExprIntrp_EndOfAssign()
   }
   else {
     if (!namexp->IsKind(STANDARD_TYPE(Expr_NamedUnknown))) {
-      ExprIntrp_SyntaxError::Raise();
+      throw ExprIntrp_SyntaxError();
     }
     namu = Handle(Expr_NamedUnknown)::DownCast(namexp);
   }
index 1970024..827774e 100644 (file)
@@ -27,7 +27,7 @@ Fonction:
     definition de la courbe.
 -----------------------------------------------------------------------------*/
 
-  if (NbU < 2) { Standard_OutOfRange::Raise(); }
+  if (NbU < 2) { throw Standard_OutOfRange(); }
 
   Standard_Real U = Tool1::FirstParameter(C);
   Standard_Real PasU = (Tool1::LastParameter(C) - U)/ (NbU - 1);
@@ -63,7 +63,7 @@ Fonction:
     definition de la courbe.
 -----------------------------------------------------------------------------*/
 
-  if (NbU < 2) { Standard_OutOfRange::Raise(); }
+  if (NbU < 2) { throw Standard_OutOfRange(); }
   Standard_Real U1, U2, U11, U12;
   Standard_Real Uinf = Tool1::FirstParameter(C);
   Standard_Real Ulast = Tool1::LastParameter(C);
index fffd4c8..211dd84 100644 (file)
@@ -291,8 +291,8 @@ Standard_Boolean Extrema_ExtCC::IsParallel() const
 
 Standard_Real Extrema_ExtCC::SquareDistance(const Standard_Integer N) const 
 {
-  if(!myDone) StdFail_NotDone::Raise();
-  if ((N <= 0) || (N > mynbext)) Standard_OutOfRange::Raise();
+  if(!myDone) throw StdFail_NotDone();
+  if ((N <= 0) || (N > mynbext)) throw Standard_OutOfRange();
   return mySqDist.Value(N);
 }
 
@@ -304,7 +304,7 @@ Standard_Real Extrema_ExtCC::SquareDistance(const Standard_Integer N) const
 
 Standard_Integer Extrema_ExtCC::NbExt() const
 {
-  if(!myDone) StdFail_NotDone::Raise();
+  if(!myDone) throw StdFail_NotDone();
   return mynbext;
 }
 
@@ -318,8 +318,8 @@ void Extrema_ExtCC::Points(const Standard_Integer N,
                            Extrema_POnCurv& P1,
                            Extrema_POnCurv& P2) const
 {
-  if(!myDone) StdFail_NotDone::Raise();
-  if ((N <= 0) || (N > mynbext)) Standard_OutOfRange::Raise();
+  if(!myDone) throw StdFail_NotDone();
+  if ((N <= 0) || (N > mynbext)) throw Standard_OutOfRange();
   P1 = mypoints.Value(2*N-1);
   P2 = mypoints.Value(2*N);
 }
index 1bbe5d8..ba2b880 100644 (file)
@@ -396,15 +396,15 @@ Standard_Boolean Extrema_ExtCC2d::IsDone() const
 
 Standard_Real Extrema_ExtCC2d::SquareDistance(const Standard_Integer N) const 
 {
-  if(!myDone) StdFail_NotDone::Raise();
-  if ((N <= 0) || (N > mynbext)) Standard_OutOfRange::Raise();
+  if(!myDone) throw StdFail_NotDone();
+  if ((N <= 0) || (N > mynbext)) throw Standard_OutOfRange();
   return mySqDist.Value(N);
 }
 
 
 Standard_Integer Extrema_ExtCC2d::NbExt() const
 {
-  if(!myDone) StdFail_NotDone::Raise();
+  if(!myDone) throw StdFail_NotDone();
   return mynbext;
 }
 
@@ -413,8 +413,8 @@ void Extrema_ExtCC2d::Points(const Standard_Integer N,
                              Extrema_POnCurv2d& P1,
                              Extrema_POnCurv2d& P2) const
 {
-  if(!myDone) StdFail_NotDone::Raise();
-  if ((N <= 0) || (N > mynbext)) Standard_OutOfRange::Raise();
+  if(!myDone) throw StdFail_NotDone();
+  if ((N <= 0) || (N > mynbext)) throw Standard_OutOfRange();
   P1 = mypoints.Value(2*N-1);
   P2 = mypoints.Value(2*N);
 }
@@ -558,7 +558,7 @@ void Extrema_ExtCC2d::Results(const Extrema_ECC2d& AlgExt,
 
 Standard_Boolean Extrema_ExtCC2d::IsParallel() const
 {
-  if (!myDone) StdFail_NotDone::Raise();
+  if (!myDone) throw StdFail_NotDone();
   return myIsPar;
 }
 
index c912150..1b8ae22 100644 (file)
@@ -410,16 +410,16 @@ Standard_Boolean Extrema_ExtCS::IsParallel() const
 
 Standard_Real Extrema_ExtCS::SquareDistance(const Standard_Integer N) const
 {
-  if(!myDone) StdFail_NotDone::Raise();
-  if (myIsPar && N != 1) StdFail_InfiniteSolutions::Raise();
-  if ((N < 1) || (N > mySqDist.Length())) Standard_OutOfRange::Raise();
+  if(!myDone) throw StdFail_NotDone();
+  if (myIsPar && N != 1) throw StdFail_InfiniteSolutions();
+  if ((N < 1) || (N > mySqDist.Length())) throw Standard_OutOfRange();
   return mySqDist.Value(N);
 }
 
 
 Standard_Integer Extrema_ExtCS::NbExt() const
 {
-  if(!myDone) StdFail_NotDone::Raise();
+  if(!myDone) throw StdFail_NotDone();
   return myPOnC.Length();
 }
 
@@ -429,7 +429,7 @@ void Extrema_ExtCS::Points(const Standard_Integer N,
   Extrema_POnCurv&       P1,
   Extrema_POnSurf&       P2) const
 {
-  if(!myDone) StdFail_NotDone::Raise();
+  if(!myDone) throw StdFail_NotDone();
   P1 = myPOnC.Value(N);
   P2 = myPOnS.Value(N);
 }
index 2e01301..18003ed 100644 (file)
@@ -90,21 +90,21 @@ class ExtremaExtElC_TrigonometricRoots {
   //
   Standard_Integer NbSolutions() { 
     if(!done) {
-      StdFail_NotDone::Raise();
+      throw StdFail_NotDone();
     }
     return NbRoots; 
   }
   //
   Standard_Boolean InfiniteRoots() { 
     if(!done) {
-      StdFail_NotDone::Raise();
+      throw StdFail_NotDone();
     }
     return infinite_roots; 
   }
   //
   Standard_Real Value(const Standard_Integer& n) {
     if((!done)||(n>NbRoots)) {
-      StdFail_NotDone::Raise();
+      throw StdFail_NotDone();
     }
     return Roots[n-1];
   }
@@ -1024,78 +1024,7 @@ Extrema_ExtElC::Extrema_ExtElC (const gp_Circ& C1,
     }// if (!bOut || !bIn) {
   }// else
 }
-//=======================================================================
-//function : Extrema_ExtElC
-//purpose  : 
-//=======================================================================
-Extrema_ExtElC::Extrema_ExtElC (const gp_Circ&, const gp_Elips&)
-{
-  Standard_NotImplemented::Raise();
-}
-//=======================================================================
-//function : Extrema_ExtElC
-//purpose  : 
-//=======================================================================
-Extrema_ExtElC::Extrema_ExtElC (const gp_Circ&, const gp_Hypr&)
-{
-  Standard_NotImplemented::Raise();
-}
-//=======================================================================
-//function : Extrema_ExtElC
-//purpose  : 
-//=======================================================================
-Extrema_ExtElC::Extrema_ExtElC (const gp_Circ&, const gp_Parab&)
-{
-  Standard_NotImplemented::Raise();
-}
-//=======================================================================
-//function : Extrema_ExtElC
-//purpose  : 
-//=======================================================================
-Extrema_ExtElC::Extrema_ExtElC (const gp_Elips&, const gp_Elips&)
-{
-  Standard_NotImplemented::Raise();
-}
-//=======================================================================
-//function : Extrema_ExtElC
-//purpose  : 
-//=======================================================================
-Extrema_ExtElC::Extrema_ExtElC (const gp_Elips&, const gp_Hypr&)
-{
-  Standard_NotImplemented::Raise();
-}
-//=======================================================================
-//function : Extrema_ExtElC
-//purpose  : 
-//=======================================================================
-Extrema_ExtElC::Extrema_ExtElC (const gp_Elips&, const gp_Parab&)
-{
-  Standard_NotImplemented::Raise();
-}
-//=======================================================================
-//function : Extrema_ExtElC
-//purpose  : 
-//=======================================================================
-Extrema_ExtElC::Extrema_ExtElC (const gp_Hypr&, const gp_Hypr&)
-{
-  Standard_NotImplemented::Raise();
-}
-//=======================================================================
-//function : Extrema_ExtElC
-//purpose  : 
-//=======================================================================
-Extrema_ExtElC::Extrema_ExtElC (const gp_Hypr&, const gp_Parab&)
-{
-  Standard_NotImplemented::Raise();
-}
-//=======================================================================
-//function : Extrema_ExtElC
-//purpose  : 
-//=======================================================================
-Extrema_ExtElC::Extrema_ExtElC (const gp_Parab&, const gp_Parab&)
-{
-  Standard_NotImplemented::Raise();
-}
+
 //=======================================================================
 //function : IsDone
 //purpose  : 
@@ -1110,7 +1039,7 @@ Standard_Boolean Extrema_ExtElC::IsDone () const {
 Standard_Boolean Extrema_ExtElC::IsParallel () const
 {
   if (!IsDone()) { 
-    StdFail_NotDone::Raise(); 
+    throw StdFail_NotDone();
   }
   return myIsPar;
 }
@@ -1121,7 +1050,7 @@ Standard_Boolean Extrema_ExtElC::IsParallel () const
 Standard_Integer Extrema_ExtElC::NbExt () const
 {
   if (IsParallel()) {
-    StdFail_InfiniteSolutions::Raise(); 
+    throw StdFail_InfiniteSolutions();
   }
   return myNbExt;
 }
@@ -1132,16 +1061,16 @@ Standard_Integer Extrema_ExtElC::NbExt () const
 Standard_Real Extrema_ExtElC::SquareDistance (const Standard_Integer N) const
 {
   if (!myDone) { 
-    StdFail_NotDone::Raise(); 
+    throw StdFail_NotDone();
   }
   if (myIsPar) {
     if (N < 1 || N > 2) { 
-      Standard_OutOfRange::Raise(); 
+      throw Standard_OutOfRange();
     }
   }
   else {  
     if (N < 1 || N > NbExt()) { 
-      Standard_OutOfRange::Raise(); 
+      throw Standard_OutOfRange();
     }
   }
   return mySqDist[N-1];
@@ -1155,7 +1084,7 @@ void Extrema_ExtElC::Points (const Standard_Integer N,
                             Extrema_POnCurv& P2) const
 {
   if (N < 1 || N > NbExt()) { 
-    Standard_OutOfRange::Raise(); 
+    throw Standard_OutOfRange();
   }
   P1 = myPoint[N-1][0];
   P2 = myPoint[N-1][1];
index 0c3667f..c6e720c 100644 (file)
@@ -73,42 +73,6 @@ public:
   //! The circles can be parallel or identical.
   Standard_EXPORT Extrema_ExtElC(const gp_Circ& C1, const gp_Circ& C2);
   
-  //! Calculates the distance between a circle and an
-  //! elipse.
-  Standard_EXPORT Extrema_ExtElC(const gp_Circ& C1, const gp_Elips& C2);
-  
-  //! Calculates the distance between a circle and a
-  //! hyperbola.
-  Standard_EXPORT Extrema_ExtElC(const gp_Circ& C1, const gp_Hypr& C2);
-  
-  //! Calculates the distance between a circle and a
-  //! parabola.
-  Standard_EXPORT Extrema_ExtElC(const gp_Circ& C1, const gp_Parab& C2);
-  
-  //! Calculates the distance between two elipses.
-  //! The elipses can be parallel or identical.
-  Standard_EXPORT Extrema_ExtElC(const gp_Elips& C1, const gp_Elips& C2);
-  
-  //! Calculates the distance between an elipse and a
-  //! hyperbola.
-  Standard_EXPORT Extrema_ExtElC(const gp_Elips& C1, const gp_Hypr& C2);
-  
-  //! Calculates the distance between an elipse and a
-  //! parabola.
-  Standard_EXPORT Extrema_ExtElC(const gp_Elips& C1, const gp_Parab& C2);
-  
-  //! Calculates the distance between two hyperbolas.
-  //! The hyperbolas can be parallel or identical.
-  Standard_EXPORT Extrema_ExtElC(const gp_Hypr& C1, const gp_Hypr& C2);
-  
-  //! Calculates the distance between a hyperbola and a
-  //! parabola.
-  Standard_EXPORT Extrema_ExtElC(const gp_Hypr& C1, const gp_Parab& C2);
-  
-  //! Calculates the distance between two parabolas
-  //! The parabolas can be parallel or identical.
-  Standard_EXPORT Extrema_ExtElC(const gp_Parab& C1, const gp_Parab& C2);
-  
   //! Returns True if the distances are found.
   Standard_EXPORT Standard_Boolean IsDone() const;
   
index 1c237e8..ac245de 100644 (file)
@@ -405,55 +405,19 @@ Extrema_ExtElC2d::Extrema_ExtElC2d (const gp_Circ2d& C1, const gp_Parab2d& C2)
 }
 //============================================================================
 
-Extrema_ExtElC2d::Extrema_ExtElC2d (const gp_Elips2d&, const gp_Elips2d&)
-{
-  Standard_NotImplemented::Raise();
-}
-//============================================================================
-
-Extrema_ExtElC2d::Extrema_ExtElC2d (const gp_Elips2d&, const gp_Hypr2d&)
-{
-  Standard_NotImplemented::Raise();
-}
-//============================================================================
-
-Extrema_ExtElC2d::Extrema_ExtElC2d (const gp_Elips2d&, const gp_Parab2d&)
-{
-  Standard_NotImplemented::Raise();
-}
-//============================================================================
-
-Extrema_ExtElC2d::Extrema_ExtElC2d (const gp_Hypr2d&, const gp_Hypr2d&)
-{
-  Standard_NotImplemented::Raise();
-}
-//============================================================================
-
-Extrema_ExtElC2d::Extrema_ExtElC2d (const gp_Hypr2d&, const gp_Parab2d&)
-{
-  Standard_NotImplemented::Raise();
-}
-//============================================================================
-
-Extrema_ExtElC2d::Extrema_ExtElC2d (const gp_Parab2d&, const gp_Parab2d&)
-{
-  Standard_NotImplemented::Raise();
-}
-//============================================================================
-
 Standard_Boolean Extrema_ExtElC2d::IsDone () const { return myDone; }
 //============================================================================
 
 Standard_Boolean Extrema_ExtElC2d::IsParallel () const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myIsPar;
 }
 //============================================================================
 
 Standard_Integer Extrema_ExtElC2d::NbExt () const
 {
-  if (IsParallel()) { StdFail_InfiniteSolutions::Raise(); }
+  if (IsParallel()) { throw StdFail_InfiniteSolutions(); }
   return myNbExt;
 }
 //============================================================================
@@ -461,7 +425,7 @@ Standard_Integer Extrema_ExtElC2d::NbExt () const
 Standard_Real Extrema_ExtElC2d::SquareDistance (const Standard_Integer N) const
 {
   if (!(N == 1 && myDone)) {
-    if (N < 1 || N > NbExt()) { Standard_OutOfRange::Raise(); }
+    if (N < 1 || N > NbExt()) { throw Standard_OutOfRange(); }
   }
   return mySqDist[N-1];
 }
@@ -471,7 +435,7 @@ void Extrema_ExtElC2d::Points (const Standard_Integer N,
                               Extrema_POnCurv2d& P1, 
                               Extrema_POnCurv2d& P2) const
 {
-  if (N < 1 || N > NbExt()) { Standard_OutOfRange::Raise(); }
+  if (N < 1 || N > NbExt()) { throw Standard_OutOfRange(); }
   P1 = myPoint[N-1][0];
   P2 = myPoint[N-1][1];
 }
index 0284357..708149b 100644 (file)
@@ -85,30 +85,6 @@ public:
   //! parabola.
   Standard_EXPORT Extrema_ExtElC2d(const gp_Circ2d& C1, const gp_Parab2d& C2);
   
-  //! Calculates the distance between two elipses.
-  //! The elipses can be parallel or identical.
-  Standard_EXPORT Extrema_ExtElC2d(const gp_Elips2d& C1, const gp_Elips2d& C2);
-  
-  //! Calculates the distance between an elipse and a
-  //! hyperbola.
-  Standard_EXPORT Extrema_ExtElC2d(const gp_Elips2d& C1, const gp_Hypr2d& C2);
-  
-  //! Calculates the distance between an elipse and a
-  //! parabola.
-  Standard_EXPORT Extrema_ExtElC2d(const gp_Elips2d& C1, const gp_Parab2d& C2);
-  
-  //! Calculates the distance between two hyperbolas.
-  //! The hyperbolas can be parallel or identical.
-  Standard_EXPORT Extrema_ExtElC2d(const gp_Hypr2d& C1, const gp_Hypr2d& C2);
-  
-  //! Calculates the distance between a hyperbola and a
-  //! parabola.
-  Standard_EXPORT Extrema_ExtElC2d(const gp_Hypr2d& C1, const gp_Parab2d& C2);
-  
-  //! Calculates the distance between two parabolas
-  //! The parabolas can be parallel or identical.
-  Standard_EXPORT Extrema_ExtElC2d(const gp_Parab2d& C1, const gp_Parab2d& C2);
-  
   //! Returns True if the distances are found.
   Standard_EXPORT Standard_Boolean IsDone() const;
   
index 6051920..67b5732 100644 (file)
@@ -195,9 +195,7 @@ void Extrema_ExtElCS::Perform(const gp_Lin& C,
 
 Extrema_ExtElCS::Extrema_ExtElCS(const gp_Lin& C,
                                 const gp_Cone& S)
-{
-  Perform(C, S);
-}
+{  Perform(C, S);}
 
 
 
@@ -206,7 +204,7 @@ Extrema_ExtElCS::Extrema_ExtElCS(const gp_Lin& C,
 void Extrema_ExtElCS::Perform(const gp_Lin& ,
                              const gp_Cone& )
 {
-  Standard_NotImplemented::Raise();
+  throw Standard_NotImplemented();
 
 }
 
@@ -295,9 +293,7 @@ void Extrema_ExtElCS::Perform(const gp_Lin& C,
 
 Extrema_ExtElCS::Extrema_ExtElCS(const gp_Lin& C,
                                 const gp_Torus& S)
-{
-  Perform(C, S);
-}
+{  Perform(C, S);}
 
 
 
@@ -306,7 +302,7 @@ Extrema_ExtElCS::Extrema_ExtElCS(const gp_Lin& C,
 void Extrema_ExtElCS::Perform(const gp_Lin& ,
                              const gp_Torus& )
 {
-  Standard_NotImplemented::Raise();
+  throw Standard_NotImplemented();
 
 }
 
@@ -523,9 +519,7 @@ void Extrema_ExtElCS::Perform(const gp_Circ& C,
 
 Extrema_ExtElCS::Extrema_ExtElCS(const gp_Circ& C,
                                 const gp_Cone& S)
-{
-  Perform(C, S);
-}
+{  Perform(C, S);}
 
 
 
@@ -534,7 +528,7 @@ Extrema_ExtElCS::Extrema_ExtElCS(const gp_Circ& C,
 void Extrema_ExtElCS::Perform(const gp_Circ& ,
                         const gp_Cone& )
 {
-  Standard_NotImplemented::Raise();
+  throw Standard_NotImplemented();
 
 }
 
@@ -542,9 +536,7 @@ void Extrema_ExtElCS::Perform(const gp_Circ& ,
 
 Extrema_ExtElCS::Extrema_ExtElCS(const gp_Circ& C,
                                 const gp_Sphere& S)
-{
-  Perform(C, S);
-}
+{  Perform(C, S);}
 
 
 
@@ -553,15 +545,13 @@ Extrema_ExtElCS::Extrema_ExtElCS(const gp_Circ& C,
 void Extrema_ExtElCS::Perform(const gp_Circ& ,
                              const gp_Sphere& )
 {
-  Standard_NotImplemented::Raise();
+  throw Standard_NotImplemented();
 
 }
 
 Extrema_ExtElCS::Extrema_ExtElCS(const gp_Circ& C,
                                 const gp_Torus& S)
-{
-  Perform(C, S);
-}
+{  Perform(C, S);}
 
 
 
@@ -570,7 +560,7 @@ Extrema_ExtElCS::Extrema_ExtElCS(const gp_Circ& C,
 void Extrema_ExtElCS::Perform(const gp_Circ& ,
                              const gp_Torus& )
 {
-  Standard_NotImplemented::Raise();
+  throw Standard_NotImplemented();
 
 }
 
@@ -643,13 +633,13 @@ Standard_Boolean Extrema_ExtElCS::IsDone() const
 
 Standard_Integer Extrema_ExtElCS::NbExt() const
 {
-  if (myIsPar) StdFail_InfiniteSolutions::Raise();
+  if (myIsPar) throw StdFail_InfiniteSolutions();
   return myNbExt;
 }
 
 Standard_Real Extrema_ExtElCS::SquareDistance(const Standard_Integer N) const
 {
-  if (myIsPar && N != 1) StdFail_InfiniteSolutions::Raise();
+  if (myIsPar && N != 1) throw StdFail_InfiniteSolutions();
   return mySqDist->Value(N);
 }
 
@@ -658,7 +648,7 @@ void Extrema_ExtElCS::Points(const Standard_Integer N,
                             Extrema_POnCurv& P1,
                             Extrema_POnSurf& P2) const
 {
-  if (myIsPar) StdFail_InfiniteSolutions::Raise();
+  if (myIsPar) throw StdFail_InfiniteSolutions();
   P1 = myPoint1->Value(N);
   P2 = myPoint2->Value(N);
 }
index 4ba055c..0c5dd2b 100644 (file)
@@ -58,9 +58,7 @@ void Extrema_ExtElSS::Perform(const gp_Pln& S1, const gp_Pln& S2)
 
 
 Extrema_ExtElSS::Extrema_ExtElSS(const gp_Pln& S1, const gp_Sphere& S2)
-{
-  Perform(S1, S2);
-}
+{  Perform(S1, S2);}
 
 
 //void Extrema_ExtElSS::Perform(const gp_Pln& S1, const gp_Sphere& S2)
@@ -70,30 +68,25 @@ void Extrema_ExtElSS::Perform(const gp_Pln& , const gp_Sphere& )
   myDone = Standard_True;
   myIsPar = Standard_False;
   myNbExt = 0;
-  Standard_NotImplemented::Raise();
+  throw Standard_NotImplemented();
 }
 
 Extrema_ExtElSS::Extrema_ExtElSS(const gp_Sphere& S1, const gp_Sphere& S2)
-{
-  Perform(S1, S2);
-}
+{  Perform(S1, S2);}
 
 
 //void Extrema_ExtElSS::Perform(const gp_Sphere& S1, const gp_Sphere& S2)
 void Extrema_ExtElSS::Perform(const gp_Sphere& , const gp_Sphere& )
 {
-
   myDone = Standard_True;
   myIsPar = Standard_False;
   myNbExt = 0;
-  Standard_NotImplemented::Raise();
+  throw Standard_NotImplemented();
 }
 
 
 Extrema_ExtElSS::Extrema_ExtElSS(const gp_Sphere& S1, const gp_Cylinder& S2)
-{
-  Perform(S1, S2);
-}
+{  Perform(S1, S2);}
 
 
 //void Extrema_ExtElSS::Perform(const gp_Sphere& S1, const gp_Cylinder& S2)
@@ -103,13 +96,11 @@ void Extrema_ExtElSS::Perform(const gp_Sphere& , const gp_Cylinder& )
   myDone = Standard_True;
   myIsPar = Standard_False;
   myNbExt = 0;
-  Standard_NotImplemented::Raise();
+  throw Standard_NotImplemented();
 }
 
 Extrema_ExtElSS::Extrema_ExtElSS(const gp_Sphere& S1, const gp_Cone& S2)
-{
-  Perform(S1, S2);
-}
+{  Perform(S1, S2);}
 
 
 //void Extrema_ExtElSS::Perform(const gp_Sphere& S1, const gp_Cone& S2)
@@ -119,14 +110,12 @@ void Extrema_ExtElSS::Perform(const gp_Sphere& , const gp_Cone& )
   myDone = Standard_True;
   myIsPar = Standard_False;
   myNbExt = 0;
-  Standard_NotImplemented::Raise();
+  throw Standard_NotImplemented();
 }
 
 
 Extrema_ExtElSS::Extrema_ExtElSS(const gp_Sphere& S1, const gp_Torus& S2)
-{
-  Perform(S1, S2);
-}
+{  Perform(S1, S2);}
 
 
 //void Extrema_ExtElSS::Perform(const gp_Sphere& S1, const gp_Torus& S2)
@@ -136,7 +125,7 @@ void Extrema_ExtElSS::Perform(const gp_Sphere& , const gp_Torus& )
   myDone = Standard_True;
   myIsPar = Standard_False;
   myNbExt = 0;
-  Standard_NotImplemented::Raise();
+  throw Standard_NotImplemented();
 }
 
 
@@ -148,23 +137,23 @@ Standard_Boolean Extrema_ExtElSS::IsDone() const
 
 Standard_Boolean Extrema_ExtElSS::IsParallel() const
 {
-  if(!myDone) StdFail_NotDone::Raise();
+  if(!myDone) throw StdFail_NotDone();
   return myIsPar;
 }
 
 
 Standard_Integer Extrema_ExtElSS::NbExt() const
 {
-  if(!myDone) StdFail_NotDone::Raise();
-  if (myIsPar) StdFail_InfiniteSolutions::Raise();
+  if(!myDone) throw StdFail_NotDone();
+  if (myIsPar) throw StdFail_InfiniteSolutions();
   return myNbExt;
 }
 
 
 Standard_Real Extrema_ExtElSS::SquareDistance(const Standard_Integer N) const
 {
-  if(!myDone) StdFail_NotDone::Raise();
-  if (myIsPar && N != 1) StdFail_InfiniteSolutions::Raise();
+  if(!myDone) throw StdFail_NotDone();
+  if (myIsPar && N != 1) throw StdFail_InfiniteSolutions();
   return mySqDist->Value(N);
 }
 
@@ -173,8 +162,8 @@ void Extrema_ExtElSS::Points(const Standard_Integer N,
                             Extrema_POnSurf&       P1,
                             Extrema_POnSurf&       P2) const
 {
-  if(!myDone) StdFail_NotDone::Raise();
-  if (myIsPar) StdFail_InfiniteSolutions::Raise();
+  if(!myDone) throw StdFail_NotDone();
+  if (myIsPar) throw StdFail_InfiniteSolutions();
   P1 = myPOnS1->Value(N);
   P2 = myPOnS2->Value(N);
 }
index e0ce3d9..6cccc46 100644 (file)
@@ -442,28 +442,28 @@ Standard_Boolean Extrema_ExtPElC::IsDone () const { return myDone; }
 
 Standard_Integer Extrema_ExtPElC::NbExt () const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myNbExt;
 }
 //=============================================================================
 
 Standard_Real Extrema_ExtPElC::SquareDistance (const Standard_Integer N) const
 {
-  if ((N < 1) || (N > NbExt())) { Standard_OutOfRange::Raise(); }
+  if ((N < 1) || (N > NbExt())) { throw Standard_OutOfRange(); }
   return mySqDist[N-1];
 }
 //=============================================================================
 
 Standard_Boolean Extrema_ExtPElC::IsMin (const Standard_Integer N) const
 {
-  if ((N < 1) || (N > NbExt())) { Standard_OutOfRange::Raise(); }
+  if ((N < 1) || (N > NbExt())) { throw Standard_OutOfRange(); }
   return myIsMin[N-1];
 }
 //=============================================================================
 
 const Extrema_POnCurv& Extrema_ExtPElC::Point (const Standard_Integer N) const
 {
-  if ((N < 1) || (N > NbExt())) { Standard_OutOfRange::Raise(); }
+  if ((N < 1) || (N > NbExt())) { throw Standard_OutOfRange(); }
   return myPoint[N-1];
 }
 //=============================================================================
index 4e40342..8773309 100644 (file)
@@ -325,28 +325,28 @@ Standard_Boolean Extrema_ExtPElC2d::IsDone () const { return myDone; }
 
 Standard_Integer Extrema_ExtPElC2d::NbExt () const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myNbExt;
 }
 //=============================================================================
 
 Standard_Real Extrema_ExtPElC2d::SquareDistance (const Standard_Integer N) const
 {
-  if ((N < 1) || (N > NbExt())) { Standard_OutOfRange::Raise(); }
+  if ((N < 1) || (N > NbExt())) { throw Standard_OutOfRange(); }
   return mySqDist[N-1];
 }
 //=============================================================================
 
 Standard_Boolean Extrema_ExtPElC2d::IsMin (const Standard_Integer N) const
 {
-  if ((N < 1) || (N > NbExt())) { Standard_OutOfRange::Raise(); }
+  if ((N < 1) || (N > NbExt())) { throw Standard_OutOfRange(); }
   return myIsMin[N-1];
 }
 //=============================================================================
 
 const Extrema_POnCurv2d& Extrema_ExtPElC2d::Point (const Standard_Integer N) const
 {
-  if ((N < 1) || (N > NbExt())) { Standard_OutOfRange::Raise(); }
+  if ((N < 1) || (N > NbExt())) { throw Standard_OutOfRange(); }
   return myPoint[N-1];
 }
 //=============================================================================
index 57de9bf..59d5bfe 100644 (file)
@@ -408,23 +408,23 @@ Standard_Boolean Extrema_ExtPElS::IsDone () const { return myDone; }
 
 Standard_Integer Extrema_ExtPElS::NbExt () const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myNbExt;
 }
 //=============================================================================
 
 Standard_Real Extrema_ExtPElS::SquareDistance (const Standard_Integer N) const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
-  if ((N < 1) || (N > myNbExt)) { Standard_OutOfRange::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
+  if ((N < 1) || (N > myNbExt)) { throw Standard_OutOfRange(); }
   return mySqDist[N-1];
 }
 //=============================================================================
 
 const Extrema_POnSurf& Extrema_ExtPElS::Point (const Standard_Integer N) const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
-  if ((N < 1) || (N > myNbExt)) { Standard_OutOfRange::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
+  if ((N < 1) || (N > myNbExt)) { throw Standard_OutOfRange(); }
   return myPoint[N-1];
 }
 //=============================================================================
index 02ae328..5329a15 100644 (file)
@@ -438,7 +438,7 @@ Standard_Boolean Extrema_ExtPExtS::IsDone () const { return myDone; }
 
 Standard_Integer Extrema_ExtPExtS::NbExt () const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   if (myIsAnalyticallyComputable)
     return myNbExt;
   else
@@ -448,8 +448,8 @@ Standard_Integer Extrema_ExtPExtS::NbExt () const
 
 Standard_Real Extrema_ExtPExtS::SquareDistance (const Standard_Integer N) const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
-  if ((N < 1) || (N > myNbExt)) { Standard_OutOfRange::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
+  if ((N < 1) || (N > myNbExt)) { throw Standard_OutOfRange(); }
   if (myIsAnalyticallyComputable)
     // modified by NIZHNY-MKK  Thu Sep 18 14:48:39 2003.BEGIN
     //     return myValue[N];
@@ -462,8 +462,8 @@ Standard_Real Extrema_ExtPExtS::SquareDistance (const Standard_Integer N) const
 
 const Extrema_POnSurf& Extrema_ExtPExtS::Point (const Standard_Integer N) const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
-  if ((N < 1) || (N > myNbExt)) { Standard_OutOfRange::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
+  if ((N < 1) || (N > myNbExt)) { throw Standard_OutOfRange(); }
   if (myIsAnalyticallyComputable) {
     // modified by NIZHNY-MKK  Thu Sep 18 14:47:40 2003.BEGIN
     //     return myPoint[N];
index e92e9d8..1196c8a 100644 (file)
@@ -523,7 +523,7 @@ Standard_Boolean Extrema_ExtPRevS::IsDone() const
 
 Standard_Integer Extrema_ExtPRevS::NbExt() const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myNbExt;
 }
 
@@ -535,8 +535,8 @@ Standard_Integer Extrema_ExtPRevS::NbExt() const
 
 Standard_Real Extrema_ExtPRevS::SquareDistance(const Standard_Integer N) const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
-  if ((N < 1) || (N > myNbExt)) { Standard_OutOfRange::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
+  if ((N < 1) || (N > myNbExt)) { throw Standard_OutOfRange(); }
   if (myIsAnalyticallyComputable)
     return mySqDist[N-1];
   else
@@ -549,8 +549,8 @@ Standard_Real Extrema_ExtPRevS::SquareDistance(const Standard_Integer N) const
 
 const Extrema_POnSurf& Extrema_ExtPRevS::Point(const Standard_Integer N) const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
-  if ((N < 1) || (N > myNbExt)) { Standard_OutOfRange::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
+  if ((N < 1) || (N > myNbExt)) { throw Standard_OutOfRange(); }
   if (myIsAnalyticallyComputable)
     return myPoint[N-1];
   else
index 97075e6..dd85af9 100644 (file)
@@ -371,22 +371,22 @@ Standard_Boolean Extrema_ExtPS::IsDone() const
 
 Standard_Real Extrema_ExtPS::SquareDistance(const Standard_Integer N) const
 {
-  if(!myDone) StdFail_NotDone::Raise();
-  if ((N < 1) || (N > mySqDist.Length())) Standard_OutOfRange::Raise();
+  if(!myDone) throw StdFail_NotDone();
+  if ((N < 1) || (N > mySqDist.Length())) throw Standard_OutOfRange();
   return mySqDist.Value(N);
 }
 
 
 Standard_Integer Extrema_ExtPS::NbExt() const
 {
-  if(!myDone) StdFail_NotDone::Raise();
+  if(!myDone) throw StdFail_NotDone();
   return mySqDist.Length();
 }
 
 
 const Extrema_POnSurf& Extrema_ExtPS::Point(const Standard_Integer N) const
 {
-  if(!myDone) StdFail_NotDone::Raise();
+  if(!myDone) throw StdFail_NotDone();
   return myPoints.Value(N);
 }
 
index 3975b01..88b32de 100644 (file)
@@ -241,16 +241,16 @@ Standard_Boolean Extrema_ExtSS::IsParallel() const
 
 Standard_Real Extrema_ExtSS::SquareDistance(const Standard_Integer N) const
 {
-  if(!myDone) StdFail_NotDone::Raise();
-  if (myIsPar && N != 1) StdFail_InfiniteSolutions::Raise();
-  if ((N < 1) || (N > mySqDist.Length())) Standard_OutOfRange::Raise();
+  if(!myDone) throw StdFail_NotDone();
+  if (myIsPar && N != 1) throw StdFail_InfiniteSolutions();
+  if ((N < 1) || (N > mySqDist.Length())) throw Standard_OutOfRange();
   return mySqDist.Value(N);
 }
 
 
 Standard_Integer Extrema_ExtSS::NbExt() const
 {
-  if(!myDone) StdFail_NotDone::Raise();
+  if(!myDone) throw StdFail_NotDone();
   return mySqDist.Length();
 }
 
@@ -260,7 +260,7 @@ void Extrema_ExtSS::Points(const Standard_Integer N,
                           Extrema_POnSurf&       P1,
                           Extrema_POnSurf&       P2) const
 {
-  if(!myDone) StdFail_NotDone::Raise();
+  if(!myDone) throw StdFail_NotDone();
   P1 = myPOnS1.Value(N);
   P2 = myPOnS2.Value(N);
 }
index bfc0f7b..5f65332 100644 (file)
@@ -112,7 +112,7 @@ Standard_Integer Extrema_FuncExtCS::NbEquations() const
 Standard_Boolean Extrema_FuncExtCS::Value(const math_Vector& UV, 
                                          math_Vector& F)
 {
-  if (!myCinit || !mySinit) Standard_TypeMismatch::Raise();
+  if (!myCinit || !mySinit) throw Standard_TypeMismatch();
 
   myt = UV(1);
   myU = UV(2);
@@ -155,7 +155,7 @@ Standard_Boolean Extrema_FuncExtCS::Values(const math_Vector& UV,
                                           math_Vector& F, 
                                           math_Matrix& Df)
 {
-  if (!myCinit || !mySinit) Standard_TypeMismatch::Raise();
+  if (!myCinit || !mySinit) throw Standard_TypeMismatch();
 
   myt = UV(1);
   myU = UV(2);
@@ -195,7 +195,7 @@ Standard_Boolean Extrema_FuncExtCS::Values(const math_Vector& UV,
 
 Standard_Integer Extrema_FuncExtCS::GetStateNumber()
 {
-  if (!myCinit || !mySinit) Standard_TypeMismatch::Raise();
+  if (!myCinit || !mySinit) throw Standard_TypeMismatch();
 #if 0
   math_Vector Sol(1, 3), UVSol(1, 3);
   UVSol(1) = myt; UVSol(2) = myU; UVSol(3) = myV;
@@ -236,7 +236,7 @@ Standard_Integer Extrema_FuncExtCS::NbExt() const
 
 Standard_Real Extrema_FuncExtCS::SquareDistance(const Standard_Integer N) const 
 {
-  if (!myCinit || !mySinit) Standard_TypeMismatch::Raise();
+  if (!myCinit || !mySinit) throw Standard_TypeMismatch();
   return mySqDist.Value(N);
 }
 
@@ -247,7 +247,7 @@ Standard_Real Extrema_FuncExtCS::SquareDistance(const Standard_Integer N) const
 
 const Extrema_POnCurv& Extrema_FuncExtCS::PointOnCurve(const Standard_Integer N) const 
 {
-  if (!myCinit || !mySinit) Standard_TypeMismatch::Raise();
+  if (!myCinit || !mySinit) throw Standard_TypeMismatch();
   return myPoint1.Value(N);
 }
 
@@ -258,7 +258,7 @@ const Extrema_POnCurv& Extrema_FuncExtCS::PointOnCurve(const Standard_Integer N)
 
 const Extrema_POnSurf& Extrema_FuncExtCS::PointOnSurface(const Standard_Integer N) const 
 {
-  if (!myCinit || !mySinit) Standard_TypeMismatch::Raise();
+  if (!myCinit || !mySinit) throw Standard_TypeMismatch();
   return myPoint2.Value(N);
 }
 
index 8d83e39..f7c7a80 100644 (file)
@@ -161,7 +161,7 @@ void Extrema_FuncExtPC::SetPoint(const Pnt& P)
 Standard_Boolean Extrema_FuncExtPC::Value (const Standard_Real U, Standard_Real& F)
 {
   if (!myPinit || !myCinit)
-    Standard_TypeMismatch::Raise("No init");
+    throw Standard_TypeMismatch("No init");
 
   myU = U;
   Vec D1c;
@@ -271,7 +271,7 @@ Standard_Boolean Extrema_FuncExtPC::Value (const Standard_Real U, Standard_Real&
 
 Standard_Boolean Extrema_FuncExtPC::Derivative (const Standard_Real U, Standard_Real& D1f)
 {
-  if (!myPinit || !myCinit) Standard_TypeMismatch::Raise();
+  if (!myPinit || !myCinit) throw Standard_TypeMismatch();
   Standard_Real F;
   return Values(U,F,D1f);  /* on fait appel a Values pour simplifier la
                            sauvegarde de l'etat. */
@@ -283,7 +283,7 @@ Standard_Boolean Extrema_FuncExtPC::Values (const Standard_Real U,
                                             Standard_Real& D1f)
 {
   if (!myPinit || !myCinit)
-    Standard_TypeMismatch::Raise("No init");
+    throw Standard_TypeMismatch("No init");
 
   Pnt myPc_old = myPc, myP_old = myP;
 
@@ -377,7 +377,7 @@ Standard_Boolean Extrema_FuncExtPC::Values (const Standard_Real U,
 
 Standard_Integer Extrema_FuncExtPC::GetStateNumber ()
 {
-  if (!myPinit || !myCinit) Standard_TypeMismatch::Raise();
+  if (!myPinit || !myCinit) throw Standard_TypeMismatch();
   mySqDist.Append(myPc.SquareDistance(myP));
 
   // It is necessary to always compute myD1f.
@@ -402,19 +402,19 @@ Standard_Integer Extrema_FuncExtPC::NbExt () const { return mySqDist.Length(); }
 
 Standard_Real Extrema_FuncExtPC::SquareDistance (const Standard_Integer N) const
 {
-  if (!myPinit || !myCinit) Standard_TypeMismatch::Raise();
+  if (!myPinit || !myCinit) throw Standard_TypeMismatch();
   return mySqDist.Value(N);
 }
 //=============================================================================
 Standard_Boolean Extrema_FuncExtPC::IsMin (const Standard_Integer N) const
 {
-  if (!myPinit || !myCinit) Standard_TypeMismatch::Raise();
+  if (!myPinit || !myCinit) throw Standard_TypeMismatch();
   return (myIsMin.Value(N) == 1);
 }
 //=============================================================================
 const POnC & Extrema_FuncExtPC::Point (const Standard_Integer N) const
 {
-  if (!myPinit || !myCinit) Standard_TypeMismatch::Raise();
+  if (!myPinit || !myCinit) throw Standard_TypeMismatch();
   return myPoint.Value(N);
 }
 //=============================================================================
index 17a4eba..c401f4c 100644 (file)
@@ -118,7 +118,7 @@ Standard_Integer Extrema_FuncExtSS::NbEquations () const { return 4;}
 Standard_Boolean Extrema_FuncExtSS::Value (const math_Vector& UV, 
                                           math_Vector& F)
 {
-  if (!myS1init || !myS2init) Standard_TypeMismatch::Raise();
+  if (!myS1init || !myS2init) throw Standard_TypeMismatch();
   myU1 = UV(1);
   myV1 = UV(2);
   myU2 = UV(3);
@@ -159,7 +159,7 @@ Standard_Boolean Extrema_FuncExtSS::Values (const math_Vector& UV,
                                            math_Vector& F,
                                            math_Matrix& Df)
 {
-  if (!myS1init || !myS2init) Standard_TypeMismatch::Raise();
+  if (!myS1init || !myS2init) throw Standard_TypeMismatch();
   myU1 = UV(1);
   myV1 = UV(2);
   myU2 = UV(3);
@@ -206,7 +206,7 @@ Standard_Boolean Extrema_FuncExtSS::Values (const math_Vector& UV,
 
 Standard_Integer Extrema_FuncExtSS::GetStateNumber ()
 {
-  if (!myS1init || !myS2init) Standard_TypeMismatch::Raise();
+  if (!myS1init || !myS2init) throw Standard_TypeMismatch();
 #if 0
   math_Vector Sol(1, 4), UVSol(1, 4);
   UVSol(1) = myU1; UVSol(2) = myV1; UVSol(3) = myU2; UVSol(4) = myV2;
@@ -237,7 +237,7 @@ Standard_Integer Extrema_FuncExtSS::NbExt () const
 
 Standard_Real Extrema_FuncExtSS::SquareDistance (const Standard_Integer N) const
 {
-  if (!myS1init || !myS2init) Standard_TypeMismatch::Raise();
+  if (!myS1init || !myS2init) throw Standard_TypeMismatch();
   return mySqDist.Value(N);
 }
 
@@ -248,7 +248,7 @@ Standard_Real Extrema_FuncExtSS::SquareDistance (const Standard_Integer N) const
 
 const Extrema_POnSurf& Extrema_FuncExtSS::PointOnS1 (const Standard_Integer N) const
 {
-  if (!myS1init || !myS2init) Standard_TypeMismatch::Raise();
+  if (!myS1init || !myS2init) throw Standard_TypeMismatch();
   return myPoint1.Value(N);
 }
 //=======================================================================
@@ -258,7 +258,7 @@ const Extrema_POnSurf& Extrema_FuncExtSS::PointOnS1 (const Standard_Integer N) c
 
 const Extrema_POnSurf& Extrema_FuncExtSS::PointOnS2 (const Standard_Integer N) const
 {
-  if (!myS1init || !myS2init) Standard_TypeMismatch::Raise();
+  if (!myS1init || !myS2init) throw Standard_TypeMismatch();
   return myPoint2.Value(N);
 }
 
index 06346cc..867ff8a 100644 (file)
@@ -73,7 +73,7 @@ Standard_Integer Extrema_FuncPSNorm::NbEquations () const { return 2;}
 Standard_Boolean Extrema_FuncPSNorm::Value (const math_Vector& UV, 
                                            math_Vector& F)
 {
-  if (!myPinit || !mySinit) Standard_TypeMismatch::Raise();
+  if (!myPinit || !mySinit) throw Standard_TypeMismatch();
   myU = UV(1);
   myV = UV(2);
   gp_Vec Dus, Dvs;
@@ -100,7 +100,7 @@ Standard_Boolean Extrema_FuncPSNorm::Values (const math_Vector& UV,
                                             math_Vector& F,
                                             math_Matrix& Df)
 {
-  if (!myPinit || !mySinit) Standard_TypeMismatch::Raise();
+  if (!myPinit || !mySinit) throw Standard_TypeMismatch();
   myU = UV(1);
   myV = UV(2);
   gp_Vec Dus, Dvs, Duus, Dvvs, Duvs;
@@ -123,7 +123,7 @@ Standard_Boolean Extrema_FuncPSNorm::Values (const math_Vector& UV,
 
 Standard_Integer Extrema_FuncPSNorm::GetStateNumber ()
 {
-  if (!myPinit || !mySinit) Standard_TypeMismatch::Raise();
+  if (!myPinit || !mySinit) throw Standard_TypeMismatch();
   //comparison of solution with previous solutions
   Standard_Integer i = 1, nbSol = mySqDist.Length();
   Standard_Real tol2d = Precision::PConfusion() * Precision::PConfusion();
@@ -151,13 +151,13 @@ Standard_Integer Extrema_FuncPSNorm::NbExt () const
 
 Standard_Real Extrema_FuncPSNorm::SquareDistance (const Standard_Integer N) const
 {
-  if (!myPinit || !mySinit) Standard_TypeMismatch::Raise();
+  if (!myPinit || !mySinit) throw Standard_TypeMismatch();
   return mySqDist.Value(N);
 }
 //=============================================================================
 
 const Extrema_POnSurf& Extrema_FuncPSNorm::Point (const Standard_Integer N) const
 {
-  if (!myPinit || !mySinit) Standard_TypeMismatch::Raise();
+  if (!myPinit || !mySinit) throw Standard_TypeMismatch();
   return myPoint.Value(N);
 }
index 2ed746d..d6ed889 100644 (file)
@@ -509,8 +509,8 @@ Standard_Boolean Extrema_GExtPC::IsDone() const
 
 Standard_Real Extrema_GExtPC::SquareDistance(const Standard_Integer N) const 
 {
-  if(!mydone) StdFail_NotDone::Raise();
-  if ((N < 1) || (N > mySqDist.Length())) Standard_OutOfRange::Raise();
+  if(!mydone) throw StdFail_NotDone();
+  if ((N < 1) || (N > mySqDist.Length())) throw Standard_OutOfRange();
   return mySqDist.Value(N);
 }
 
@@ -522,7 +522,7 @@ Standard_Real Extrema_GExtPC::SquareDistance(const Standard_Integer N) const
 
 Standard_Integer Extrema_GExtPC::NbExt() const
 {
-  if(!mydone) StdFail_NotDone::Raise();
+  if(!mydone) throw StdFail_NotDone();
   return mySqDist.Length();
 }
 
@@ -534,8 +534,8 @@ Standard_Integer Extrema_GExtPC::NbExt() const
 
 Standard_Boolean Extrema_GExtPC::IsMin(const Standard_Integer N) const
 {
-  if(!mydone) StdFail_NotDone::Raise();
-  if ((N < 1) || (N > mySqDist.Length())) Standard_OutOfRange::Raise();
+  if(!mydone) throw StdFail_NotDone();
+  if ((N < 1) || (N > mySqDist.Length())) throw Standard_OutOfRange();
   return myismin.Value(N);
 }
 
@@ -548,8 +548,8 @@ Standard_Boolean Extrema_GExtPC::IsMin(const Standard_Integer N) const
 
 const ThePOnC & Extrema_GExtPC::Point(const Standard_Integer N) const
 {
-  if(!mydone) StdFail_NotDone::Raise();
-  if ((N < 1) || (N > mySqDist.Length())) Standard_OutOfRange::Raise();
+  if(!mydone) throw StdFail_NotDone();
+  if ((N < 1) || (N > mySqDist.Length())) throw Standard_OutOfRange();
   return mypoint.Value(N);
 }
 
index 3f5eb2e..dde9351 100644 (file)
@@ -317,7 +317,7 @@ Standard_Boolean Extrema_GLocateExtPC::IsDone () const
 
 Standard_Real Extrema_GLocateExtPC::SquareDistance () const 
 {
-  if (!myDone) { StdFail_NotDone::Raise(); }
+  if (!myDone) { throw StdFail_NotDone(); }
   Standard_Real d=0;
   if ((type == GeomAbs_BezierCurve)) {
     d =  myLocExtPC.SquareDistance();
@@ -343,7 +343,7 @@ Standard_Real Extrema_GLocateExtPC::SquareDistance () const
 
 Standard_Boolean Extrema_GLocateExtPC::IsMin () const 
 {
-  if (!myDone) { StdFail_NotDone::Raise(); }
+  if (!myDone) { throw StdFail_NotDone(); }
   Standard_Boolean b=0;
   if ((type == GeomAbs_BezierCurve)) {
     b = myLocExtPC.IsMin();
@@ -369,7 +369,7 @@ Standard_Boolean Extrema_GLocateExtPC::IsMin () const
 
 const ThePOnC & Extrema_GLocateExtPC::Point () const 
 {
-  if (!myDone) { StdFail_NotDone::Raise(); }
+  if (!myDone) { throw StdFail_NotDone(); }
   if (type == GeomAbs_BezierCurve) {
     return myLocExtPC.Point();
   }
index edf0247..0e96f09 100644 (file)
@@ -374,7 +374,7 @@ Standard_Boolean Extrema_GenExtCS::IsDone() const
 //=======================================================================
 Standard_Integer Extrema_GenExtCS::NbExt() const 
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myF.NbExt();
 }
 
@@ -384,7 +384,7 @@ Standard_Integer Extrema_GenExtCS::NbExt() const
 //=======================================================================
 Standard_Real Extrema_GenExtCS::SquareDistance(const Standard_Integer N) const 
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myF.SquareDistance(N);
 }
 
@@ -394,7 +394,7 @@ Standard_Real Extrema_GenExtCS::SquareDistance(const Standard_Integer N) const
 //=======================================================================
 const Extrema_POnCurv& Extrema_GenExtCS::PointOnCurve(const Standard_Integer N) const 
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myF.PointOnCurve(N);
 }
 
@@ -404,7 +404,7 @@ const Extrema_POnCurv& Extrema_GenExtCS::PointOnCurve(const Standard_Integer N)
 //=======================================================================
 const Extrema_POnSurf& Extrema_GenExtCS::PointOnSurface(const Standard_Integer N) const 
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myF.PointOnSurface(N);
 }
 
index 8f95821..f3d26aa 100644 (file)
@@ -195,7 +195,7 @@ Standard_Boolean Extrema_GenExtPC::IsDone () const {
 
 Standard_Integer Extrema_GenExtPC::NbExt () const {
 
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myF.NbExt();
 }
 
@@ -207,7 +207,7 @@ Standard_Integer Extrema_GenExtPC::NbExt () const {
 
 Standard_Real Extrema_GenExtPC::SquareDistance (const Standard_Integer N) const {
 
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myF.SquareDistance(N);
 }
 
@@ -219,7 +219,7 @@ Standard_Real Extrema_GenExtPC::SquareDistance (const Standard_Integer N) const
 
 Standard_Boolean Extrema_GenExtPC::IsMin (const Standard_Integer N) const {
 
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myF.IsMin(N);
 }
 
@@ -231,7 +231,7 @@ Standard_Boolean Extrema_GenExtPC::IsMin (const Standard_Integer N) const {
 
 const POnC & Extrema_GenExtPC::Point (const Standard_Integer N) const 
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myF.Point(N);
 }
 //=============================================================================
index 6c949bc..5165bab 100644 (file)
@@ -298,7 +298,7 @@ void Extrema_GenExtPS::Initialize(const Adaptor3d_Surface& S,
   myvsup = Vsup;
 
   if ((myusample < 2) ||
-      (myvsample < 2)) { Standard_OutOfRange::Raise(); }
+      (myvsample < 2)) { throw Standard_OutOfRange(); }
 
   myF.Initialize(S);
 
@@ -960,21 +960,21 @@ Standard_Boolean Extrema_GenExtPS::IsDone () const { return myDone; }
 
 Standard_Integer Extrema_GenExtPS::NbExt () const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myF.NbExt();
 }
 //=============================================================================
 
 Standard_Real Extrema_GenExtPS::SquareDistance (const Standard_Integer N) const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myF.SquareDistance(N);
 }
 //=============================================================================
 
 const Extrema_POnSurf& Extrema_GenExtPS::Point (const Standard_Integer N) const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myF.Point(N);
 }
 //=============================================================================
index 4d7ffd5..ffb3489 100644 (file)
@@ -402,7 +402,7 @@ Standard_Boolean Extrema_GenExtSS::IsDone() const
 
 Standard_Integer Extrema_GenExtSS::NbExt() const 
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myF.NbExt();
 
 }
@@ -414,7 +414,7 @@ Standard_Integer Extrema_GenExtSS::NbExt() const
 
 Standard_Real Extrema_GenExtSS::SquareDistance(const Standard_Integer N) const 
 {  
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myF.SquareDistance(N);
 }
 
@@ -425,7 +425,7 @@ Standard_Real Extrema_GenExtSS::SquareDistance(const Standard_Integer N) const
 
 const Extrema_POnSurf& Extrema_GenExtSS::PointOnS1(const Standard_Integer N) const 
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myF.PointOnS1(N);
 }
 
@@ -436,7 +436,7 @@ const Extrema_POnSurf& Extrema_GenExtSS::PointOnS1(const Standard_Integer N) con
 
 const Extrema_POnSurf& Extrema_GenExtSS::PointOnS2(const Standard_Integer N) const 
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myF.PointOnS2(N);
 }
 
index 5473856..56a77c5 100644 (file)
@@ -104,7 +104,7 @@ Standard_Boolean Extrema_GenLocateExtCC::IsDone () const { return myDone; }
 
 Standard_Real Extrema_GenLocateExtCC::SquareDistance() const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return mySqDist;
 }
 //=============================================================================
@@ -112,7 +112,7 @@ Standard_Real Extrema_GenLocateExtCC::SquareDistance() const
 void Extrema_GenLocateExtCC::Point (POnC& P1, POnC& P2)
      const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   P1 = myPoint1;
   P2 = myPoint2;
 }
index 8d0439d..880715a 100644 (file)
@@ -123,7 +123,7 @@ Standard_Boolean Extrema_GenLocateExtCS::IsDone() const
 
 Standard_Real Extrema_GenLocateExtCS::SquareDistance() const 
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return mySqDist;
 }
 
@@ -134,7 +134,7 @@ Standard_Real Extrema_GenLocateExtCS::SquareDistance() const
 
 const Extrema_POnCurv& Extrema_GenLocateExtCS::PointOnCurve() const 
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myPoint1;
 }
 
@@ -145,7 +145,7 @@ const Extrema_POnCurv& Extrema_GenLocateExtCS::PointOnCurve() const
 
 const Extrema_POnSurf& Extrema_GenLocateExtCS::PointOnSurface() const 
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myPoint2;
 }
 
index 0aa900e..7908247 100644 (file)
@@ -139,7 +139,7 @@ Standard_Boolean Extrema_GenLocateExtPC::IsDone () const
 
 Standard_Real Extrema_GenLocateExtPC::SquareDistance() const 
 {
-  if (!myDone) { StdFail_NotDone::Raise(); }
+  if (!myDone) { throw StdFail_NotDone(); }
   return myF.SquareDistance(1);
 }
 
@@ -151,7 +151,7 @@ Standard_Real Extrema_GenLocateExtPC::SquareDistance() const
 
 Standard_Boolean Extrema_GenLocateExtPC::IsMin () const 
 {
-  if (!myDone) { StdFail_NotDone::Raise(); }
+  if (!myDone) { throw StdFail_NotDone(); }
   return myF.IsMin(1);
 }
 
@@ -163,7 +163,7 @@ Standard_Boolean Extrema_GenLocateExtPC::IsMin () const
 
 const POnC & Extrema_GenLocateExtPC::Point () const 
 {
-  if (!myDone) { StdFail_NotDone::Raise(); }
+  if (!myDone) { throw StdFail_NotDone(); }
   return myF.Point(1);
 }
 
index b48ef0b..262270c 100644 (file)
@@ -116,7 +116,7 @@ Standard_Boolean Extrema_GenLocateExtPS::IsDone () const
 //=======================================================================
 Standard_Real Extrema_GenLocateExtPS::SquareDistance () const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return mySqDist;
 }
 
@@ -126,6 +126,6 @@ Standard_Real Extrema_GenLocateExtPS::SquareDistance () const
 //=======================================================================
 const Extrema_POnSurf& Extrema_GenLocateExtPS::Point () const
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myPoint;
 }
index 0d9eb7d..5e9c485 100644 (file)
@@ -129,7 +129,7 @@ Standard_Boolean Extrema_GenLocateExtSS::IsDone() const
 
 Standard_Real Extrema_GenLocateExtSS::SquareDistance() const 
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return mySqDist;
 }
 
@@ -140,7 +140,7 @@ Standard_Real Extrema_GenLocateExtSS::SquareDistance() const
 
 const Extrema_POnSurf& Extrema_GenLocateExtSS::PointOnS1() const 
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myPoint1;
 }
 
@@ -151,7 +151,7 @@ const Extrema_POnSurf& Extrema_GenLocateExtSS::PointOnS1() const
 
 const Extrema_POnSurf& Extrema_GenLocateExtSS::PointOnS2() const 
 {
-  if (!IsDone()) { StdFail_NotDone::Raise(); }
+  if (!IsDone()) { throw StdFail_NotDone(); }
   return myPoint2;
 }
 
index 0474082..ae45259 100644 (file)
@@ -54,13 +54,13 @@ Standard_Boolean Extrema_LocateExtCC::IsDone () const {
 
 Standard_Real Extrema_LocateExtCC::SquareDistance() const {
 
-  if (!myDone) { StdFail_NotDone::Raise(); }
+  if (!myDone) { throw StdFail_NotDone(); }
   return mySqDist;
 }
 
 void Extrema_LocateExtCC::Point (Extrema_POnCurv& P1, Extrema_POnCurv& P2) const {
 
-  if (!myDone) { StdFail_NotDone::Raise(); }
+  if (!myDone) { throw StdFail_NotDone(); }
   P1 = myPoint1;
   P2 = myPoint2;
 }
index ac6ec81..dae3d77 100644 (file)
@@ -77,7 +77,7 @@ Standard_Boolean Extrema_LocateExtCC2d::IsDone () const {
 
 Standard_Real Extrema_LocateExtCC2d::SquareDistance() const {
 
-  if (!myDone) { StdFail_NotDone::Raise(); }
+  if (!myDone) { throw StdFail_NotDone(); }
   return mySqDist;
 }
 
@@ -91,7 +91,7 @@ Standard_Real Extrema_LocateExtCC2d::SquareDistance() const {
 void Extrema_LocateExtCC2d::Point (Extrema_POnCurv2d& P1, 
                                    Extrema_POnCurv2d& P2) const 
 {
-  if (!myDone) { StdFail_NotDone::Raise(); }
+  if (!myDone) { throw StdFail_NotDone(); }
   P1 = myPoint1;
   P2 = myPoint2;
 }
index 517ca0e..e53e416 100644 (file)
@@ -142,7 +142,7 @@ void FEmTool_Assembly::AddMatrix(const Standard_Integer Element,
 {
 
   if(myDepTable(Dimension1, Dimension2) == 0) 
-    Standard_DomainError::Raise("FEmTool_Assembly::AddMatrix");
+    throw Standard_DomainError("FEmTool_Assembly::AddMatrix");
 
   const TColStd_Array1OfInteger & T1 = myRefTable->Value(Dimension1,Element)->Array1();
   const TColStd_Array1OfInteger & T2 = myRefTable->Value(Dimension2,Element)->Array1();
@@ -362,7 +362,7 @@ Standard_Boolean FEmTool_Assembly::Solve()
 //=======================================================================
 void FEmTool_Assembly::Solution(math_Vector& Solution) const
 {
-  if(!IsSolved) StdFail_NotDone::Raise("FEmTool_Assembly::Solution");
+  if(!IsSolved) throw StdFail_NotDone("FEmTool_Assembly::Solution");
 
   if(G.IsEmpty()) H->Solve(B, Solution);
   else {
index 5cc1ed5..92a09dc 100644 (file)
@@ -69,7 +69,7 @@ FEmTool_Curve::FEmTool_Curve(const Standard_Integer Dimension,
                                const TColStd_Array2OfReal& Coeffs) 
 {
   Standard_Integer i, j, degBase, deg;
-  if (IndexOfElement > myNbElements || IndexOfElement < 1) Standard_OutOfRange::Raise(); 
+  if (IndexOfElement > myNbElements || IndexOfElement < 1) throw Standard_OutOfRange();
   degBase = myBase->WorkDegree();
   deg = myDegree(IndexOfElement);
   Standard_Integer iBase = (IndexOfElement - 1)*(degBase + 1)*myDimension, 
@@ -108,7 +108,7 @@ FEmTool_Curve::FEmTool_Curve(const Standard_Integer Dimension,
  void FEmTool_Curve::GetElement(const Standard_Integer IndexOfElement, TColStd_Array2OfReal& Coeffs) 
 {
   Standard_Integer i, j, degBase, deg;
-  if (IndexOfElement > myNbElements || IndexOfElement < 1) Standard_OutOfRange::Raise(); 
+  if (IndexOfElement > myNbElements || IndexOfElement < 1) throw Standard_OutOfRange();
   degBase = myBase->WorkDegree();
   deg = myDegree(IndexOfElement);
   Standard_Integer iBase = (IndexOfElement - 1)*(degBase + 1)*myDimension, 
@@ -286,7 +286,7 @@ FEmTool_Curve::FEmTool_Curve(const Standard_Integer Dimension,
                            Standard_Real& Length) 
 {
   Standard_Integer Low, High, deg, degBase, i, Ptr;
-  if(FirstU > LastU) Standard_OutOfRange::Raise("FEmTool_Curve::Length");  
+  if(FirstU > LastU) throw Standard_OutOfRange("FEmTool_Curve::Length");
   
   if(myKnots->Value(1) > FirstU) Low = 1;
   else
@@ -403,7 +403,7 @@ FEmTool_Curve::FEmTool_Curve(const Standard_Integer Dimension,
     HasPoly(IndexOfElement) = HasDeri(IndexOfElement) = HasSecn(IndexOfElement) = 0;
     myLength(IndexOfElement) = -1;
   }
-  else if(Degree > myBase->WorkDegree()) Standard_OutOfRange::Raise("FEmTool_Curve::SetDegree");
+  else if(Degree > myBase->WorkDegree()) throw Standard_OutOfRange("FEmTool_Curve::SetDegree");
 }
 
 
index 77fb467..500c299 100644 (file)
@@ -25,7 +25,7 @@ FEmTool_ElementsOfRefMatrix::FEmTool_ElementsOfRefMatrix(const Handle(PLib_Base)
        myBase(TheBase)
 {
   if(DerOrder < 0 || DerOrder > 3) 
-    Standard_ConstructionError::Raise("FEmTool_ElementsOfRefMatrix");
+    throw Standard_ConstructionError("FEmTool_ElementsOfRefMatrix");
 
   myDerOrder = DerOrder;
   myNbEquations = (myBase->WorkDegree()+2)*(myBase->WorkDegree()+1)/2;
@@ -44,7 +44,7 @@ Standard_Integer FEmTool_ElementsOfRefMatrix::NbEquations() const
 
 Standard_Boolean FEmTool_ElementsOfRefMatrix::Value(const math_Vector& X, math_Vector& F) 
 {
-  if(F.Length() < myNbEquations) Standard_OutOfRange::Raise("FEmTool_ElementsOfRefMatrix::Value");
+  if(F.Length() < myNbEquations) throw Standard_OutOfRange("FEmTool_ElementsOfRefMatrix::Value");
 
   Standard_Real u = X(X.Lower());
   TColStd_Array1OfReal Basis(0,myBase->WorkDegree()), Aux(0,myBase->WorkDegree());
index d8f57c0..8f84c22 100644 (file)
@@ -49,7 +49,7 @@ FEmTool_LinearFlexion::FEmTool_LinearFlexion(const Standard_Integer WorkDegree,
 
   if (myOrder != Order) {
     //Calculating RefMatrix
-    if (WorkDegree > WDeg) Standard_ConstructionError::Raise("Degree too high");
+    if (WorkDegree > WDeg) throw Standard_ConstructionError("Degree too high");
     Order = myOrder;
     Standard_Integer DerOrder = 2;
     Handle(PLib_HermitJacobi) theBase = new PLib_HermitJacobi(WDeg, ConstraintOrder);
@@ -78,7 +78,7 @@ FEmTool_LinearFlexion::FEmTool_LinearFlexion(const Standard_Integer WorkDegree,
 //=======================================================================
 Handle(TColStd_HArray2OfInteger) FEmTool_LinearFlexion::DependenceTable() const
 {
-  if(myCoeff.IsNull()) Standard_DomainError::Raise("FEmTool_LinearFlexion::DependenceTable");
+  if(myCoeff.IsNull()) throw Standard_DomainError("FEmTool_LinearFlexion::DependenceTable");
 
   Handle(TColStd_HArray2OfInteger) DepTab = 
     new TColStd_HArray2OfInteger(myCoeff->LowerCol(), myCoeff->UpperCol(),
@@ -149,10 +149,10 @@ void FEmTool_LinearFlexion::Hessian(const Standard_Integer Dimension1,
 
   if(Dimension1 < DepTab->LowerRow() || Dimension1 > DepTab->UpperRow() || 
      Dimension2 < DepTab->LowerCol() || Dimension2 > DepTab->UpperCol()) 
-    Standard_OutOfRange::Raise("FEmTool_LinearJerk::Hessian");
+    throw Standard_OutOfRange("FEmTool_LinearJerk::Hessian");
 
   if(DepTab->Value(Dimension1,Dimension2) == 0) 
-    Standard_DomainError::Raise("FEmTool_LinearJerk::Hessian");
+    throw Standard_DomainError("FEmTool_LinearJerk::Hessian");
 
   Standard_Integer deg = Min(RefMatrix.UpperRow(), H.RowNumber() - 1), degH = Min(2*myOrder+1, deg);
   
@@ -193,7 +193,7 @@ void FEmTool_LinearFlexion::Hessian(const Standard_Integer Dimension1,
 void FEmTool_LinearFlexion::Gradient(const Standard_Integer Dimension,math_Vector& G) 
 {
   if(Dimension < myCoeff->LowerCol() || Dimension > myCoeff->UpperCol()) 
-    Standard_OutOfRange::Raise("FEmTool_LinearFlexion::Gradient");
+    throw Standard_OutOfRange("FEmTool_LinearFlexion::Gradient");
 
   Standard_Integer deg = Min(G.Length() - 1, myCoeff->ColLength() - 1);
 
index ef93fff..4bd0194 100644 (file)
@@ -46,7 +46,7 @@ FEmTool_LinearJerk::FEmTool_LinearJerk(const Standard_Integer WorkDegree,
 
   //Calculating RefMatrix
   if (myOrder != Order) {
-    if (WorkDegree > WDeg) Standard_ConstructionError::Raise("Degree too high");
+    if (WorkDegree > WDeg) throw Standard_ConstructionError("Degree too high");
     Order = myOrder;
     Standard_Integer DerOrder = 3;
 
@@ -76,7 +76,7 @@ FEmTool_LinearJerk::FEmTool_LinearJerk(const Standard_Integer WorkDegree,
 
 Handle(TColStd_HArray2OfInteger) FEmTool_LinearJerk::DependenceTable() const
 {
-  if(myCoeff.IsNull()) Standard_DomainError::Raise("FEmTool_LinearJerk::DependenceTable");
+  if(myCoeff.IsNull()) throw Standard_DomainError("FEmTool_LinearJerk::DependenceTable");
 
   Handle(TColStd_HArray2OfInteger) DepTab = 
     new TColStd_HArray2OfInteger(myCoeff->LowerCol(), myCoeff->UpperCol(),
@@ -141,10 +141,10 @@ void FEmTool_LinearJerk::Hessian(const Standard_Integer Dimension1,
 
   if(Dimension1 < DepTab->LowerRow() || Dimension1 > DepTab->UpperRow() || 
      Dimension2 < DepTab->LowerCol() || Dimension2 > DepTab->UpperCol()) 
-    Standard_OutOfRange::Raise("FEmTool_LinearJerk::Hessian");
+    throw Standard_OutOfRange("FEmTool_LinearJerk::Hessian");
 
   if(DepTab->Value(Dimension1,Dimension2) == 0) 
-    Standard_DomainError::Raise("FEmTool_LinearJerk::Hessian");
+    throw Standard_DomainError("FEmTool_LinearJerk::Hessian");
 
   Standard_Integer deg = Min(RefMatrix.UpperRow(), H.RowNumber() - 1), degH = Min(2*myOrder+1, deg);
 
@@ -193,7 +193,7 @@ void FEmTool_LinearJerk::Hessian(const Standard_Integer Dimension1,
 void FEmTool_LinearJerk::Gradient(const Standard_Integer Dimension,math_Vector& G) 
 {
   if(Dimension < myCoeff->LowerCol() || Dimension > myCoeff->UpperCol()) 
-    Standard_OutOfRange::Raise("FEmTool_LinearJerk::Gradient");
+    throw Standard_OutOfRange("FEmTool_LinearJerk::Gradient");
 
   Standard_Integer deg = Min(G.Length() - 1, myCoeff->ColLength() - 1);
 
index c9a32dd..bd136f4 100644 (file)
@@ -46,7 +46,7 @@ FEmTool_LinearTension::FEmTool_LinearTension(const Standard_Integer WorkDegree,
 
   if (myOrder != Order) {
     //Calculating RefMatrix
-    if (WorkDegree > WDeg) Standard_ConstructionError::Raise("Degree too high");
+    if (WorkDegree > WDeg) throw Standard_ConstructionError("Degree too high");
     Order = myOrder;
     Standard_Integer DerOrder = 1;
     Handle(PLib_HermitJacobi) theBase = new PLib_HermitJacobi(WDeg, ConstraintOrder);
@@ -72,7 +72,7 @@ FEmTool_LinearTension::FEmTool_LinearTension(const Standard_Integer WorkDegree,
 
 Handle(TColStd_HArray2OfInteger) FEmTool_LinearTension::DependenceTable() const
 {
-  if(myCoeff.IsNull()) Standard_DomainError::Raise("FEmTool_LinearTension::DependenceTable");
+  if(myCoeff.IsNull()) throw Standard_DomainError("FEmTool_LinearTension::DependenceTable");
 
   Handle(TColStd_HArray2OfInteger) DepTab = 
     new TColStd_HArray2OfInteger(myCoeff->LowerCol(), myCoeff->UpperCol(),
@@ -139,10 +139,10 @@ void FEmTool_LinearTension::Hessian(const Standard_Integer Dimension1,
 
   if(Dimension1 < DepTab->LowerRow() || Dimension1 > DepTab->UpperRow() || 
      Dimension2 < DepTab->LowerCol() || Dimension2 > DepTab->UpperCol()) 
-    Standard_OutOfRange::Raise("FEmTool_LinearTension::Hessian");
+    throw Standard_OutOfRange("FEmTool_LinearTension::Hessian");
 
   if(DepTab->Value(Dimension1,Dimension2) == 0) 
-    Standard_DomainError::Raise("FEmTool_LinearTension::Hessian");
+    throw Standard_DomainError("FEmTool_LinearTension::Hessian");
 
   Standard_Integer deg = Min(RefMatrix.UpperRow(), H.RowNumber() - 1), degH = Min(2*myOrder+1, deg);
 
@@ -191,7 +191,7 @@ void FEmTool_LinearTension::Hessian(const Standard_Integer Dimension1,
  void FEmTool_LinearTension::Gradient(const Standard_Integer Dimension, math_Vector& G) 
 {
   if(Dimension < myCoeff->LowerCol() || Dimension > myCoeff->UpperCol()) 
-    Standard_OutOfRange::Raise("FEmTool_LinearTension::Gradient");
+    throw Standard_OutOfRange("FEmTool_LinearTension::Gradient");
 
   Standard_Integer deg = Min(G.Length() - 1, myCoeff->ColLength() - 1);
 
index 0295d03..345f83c 100644 (file)
@@ -148,7 +148,7 @@ FEmTool_ProfileMatrix::FEmTool_ProfileMatrix(const TColStd_Array1OfInteger& Firs
 //=======================================================================
  void FEmTool_ProfileMatrix::Solve(const math_Vector& B,math_Vector& X) const
 {
-  if (!IsDecomp) StdFail_NotDone::Raise("Decomposition must be done");
+  if (!IsDecomp) throw StdFail_NotDone("Decomposition must be done");
  
   Standard_Integer i, j, jj,DiagAddr, CurrAddr;
   Standard_Real Sum;
@@ -188,14 +188,13 @@ FEmTool_ProfileMatrix::FEmTool_ProfileMatrix(const TColStd_Array1OfInteger& Firs
 
  Standard_Boolean FEmTool_ProfileMatrix::Prepare() 
 {
-  Standard_NotImplemented::Raise("FEmTool_ProfileMatrix::Prepare");
-  return Standard_False;  
+  throw Standard_NotImplemented("FEmTool_ProfileMatrix::Prepare");
 }
 
 // void FEmTool_ProfileMatrix::Solve(const math_Vector& B,const math_Vector& Init,math_Vector& X,math_Vector& Residual,const Standard_Real Tolerance,const Standard_Integer NbIterations) const
  void FEmTool_ProfileMatrix::Solve(const math_Vector& ,const math_Vector& ,math_Vector& ,math_Vector& ,const Standard_Real ,const Standard_Integer ) const
 {
-  Standard_NotImplemented::Raise("FEmTool_ProfileMatrix::Solve");
+  throw Standard_NotImplemented("FEmTool_ProfileMatrix::Solve");
 }
 
 
index ea6a124..a978db7 100644 (file)
@@ -198,9 +198,9 @@ Storage_BaseDriver& FSD_BinaryFile::PutReference(const Standard_Integer aValue)
 #if OCCT_BINARY_FILE_DO_INVERSE
   Standard_Integer t = InverseInt (aValue);
   
-  if (!fwrite(&t,sizeof(Standard_Integer),1,myStream)) Storage_StreamWriteError::Raise();
+  if (!fwrite(&t,sizeof(Standard_Integer),1,myStream)) throw Storage_StreamWriteError();
 #else
-  if (!fwrite(&aValue,sizeof(Standard_Integer),1,myStream)) Storage_StreamWriteError::Raise();
+  if (!fwrite(&aValue,sizeof(Standard_Integer),1,myStream)) throw Storage_StreamWriteError();
 #endif
   return *this;
 }
@@ -212,7 +212,7 @@ Storage_BaseDriver& FSD_BinaryFile::PutReference(const Standard_Integer aValue)
 
 Storage_BaseDriver& FSD_BinaryFile::PutCharacter(const Standard_Character aValue)
 {
-  if (!fwrite(&aValue,sizeof(Standard_Character),1,myStream)) Storage_StreamWriteError::Raise();
+  if (!fwrite(&aValue,sizeof(Standard_Character),1,myStream)) throw Storage_StreamWriteError();
   return *this;
 }
 
@@ -226,9 +226,9 @@ Storage_BaseDriver& FSD_BinaryFile::PutExtCharacter(const Standard_ExtCharacter
 #if OCCT_BINARY_FILE_DO_INVERSE
   Standard_ExtCharacter t = InverseExtChar (aValue);
 
-  if (!fwrite(&t,sizeof(Standard_ExtCharacter),1,myStream)) Storage_StreamWriteError::Raise();
+  if (!fwrite(&t,sizeof(Standard_ExtCharacter),1,myStream)) throw Storage_StreamWriteError();
 #else
-  if (!fwrite(&aValue,sizeof(Standard_ExtCharacter),1,myStream)) Storage_StreamWriteError::Raise();
+  if (!fwrite(&aValue,sizeof(Standard_ExtCharacter),1,myStream)) throw Storage_StreamWriteError();
 #endif
   return *this;
 }
@@ -243,9 +243,9 @@ Storage_BaseDriver& FSD_BinaryFile::PutInteger(const Standard_Integer aValue)
 #if OCCT_BINARY_FILE_DO_INVERSE
   Standard_Integer t = InverseInt (aValue);
   
-  if (!fwrite(&t,sizeof(Standard_Integer),1,myStream)) Storage_StreamWriteError::Raise();
+  if (!fwrite(&t,sizeof(Standard_Integer),1,myStream)) throw Storage_StreamWriteError();
 #else
-  if (!fwrite(&aValue,sizeof(Standard_Integer),1,myStream)) Storage_StreamWriteError::Raise();
+  if (!fwrite(&aValue,sizeof(Standard_Integer),1,myStream)) throw Storage_StreamWriteError();
 #endif
 
   return *this;
@@ -270,7 +270,7 @@ Standard_Integer FSD_BinaryFile::PutInteger (Standard_OStream&      theOStream,
     theOStream.write ((char*)&t, sizeof(Standard_Integer));
     if (theOStream.fail())
     {
-      Storage_StreamWriteError::Raise();
+      throw Storage_StreamWriteError();
     }
   }
 
@@ -289,7 +289,7 @@ Storage_BaseDriver& FSD_BinaryFile::PutBoolean(const Standard_Boolean aValue)
 #else
   Standard_Integer t = aValue ? 1 : 0;
 #endif
-  if (!fwrite(&t,sizeof(Standard_Integer),1,myStream)) Storage_StreamWriteError::Raise();
+  if (!fwrite(&t,sizeof(Standard_Integer),1,myStream)) throw Storage_StreamWriteError();
   return *this;
 }
 
@@ -303,9 +303,9 @@ Storage_BaseDriver& FSD_BinaryFile::PutReal(const Standard_Real aValue)
 #if OCCT_BINARY_FILE_DO_INVERSE
   Standard_Real t = InverseReal (aValue);
   
-  if (!fwrite(&t,sizeof(Standard_Real),1,myStream)) Storage_StreamWriteError::Raise();
+  if (!fwrite(&t,sizeof(Standard_Real),1,myStream)) throw Storage_StreamWriteError();
 #else
-  if (!fwrite(&aValue,sizeof(Standard_Real),1,myStream)) Storage_StreamWriteError::Raise();
+  if (!fwrite(&aValue,sizeof(Standard_Real),1,myStream)) throw Storage_StreamWriteError();
 #endif
   return *this;
 }
@@ -320,9 +320,9 @@ Storage_BaseDriver& FSD_BinaryFile::PutShortReal(const Standard_ShortReal aValue
 #if OCCT_BINARY_FILE_DO_INVERSE
   Standard_ShortReal t = InverseShortReal (aValue);
 
-  if (!fwrite(&t,sizeof(Standard_ShortReal),1,myStream)) Storage_StreamWriteError::Raise();
+  if (!fwrite(&t,sizeof(Standard_ShortReal),1,myStream)) throw Storage_StreamWriteError();
 #else
-  if (!fwrite(&aValue,sizeof(Standard_ShortReal),1,myStream)) Storage_StreamWriteError::Raise();
+  if (!fwrite(&aValue,sizeof(Standard_ShortReal),1,myStream)) throw Storage_StreamWriteError();
 #endif
   return *this;
 }
@@ -335,7 +335,7 @@ Storage_BaseDriver& FSD_BinaryFile::PutShortReal(const Standard_ShortReal aValue
 Storage_BaseDriver& FSD_BinaryFile::GetReference(Standard_Integer& aValue)
 {
   if (!fread(&aValue,sizeof(Standard_Integer),1,myStream))
-    Storage_StreamTypeMismatchError::Raise();
+    throw Storage_StreamTypeMismatchError();
 #if OCCT_BINARY_FILE_DO_INVERSE
   aValue = InverseInt (aValue);
 #endif
@@ -352,7 +352,7 @@ void FSD_BinaryFile::GetReference(Standard_IStream& theIStream, Standard_Integer
 
   if (theIStream.gcount() != sizeof(Standard_Integer))
   {
-    Storage_StreamTypeMismatchError::Raise();
+    throw Storage_StreamTypeMismatchError();
   }
 
 #if OCCT_BINARY_FILE_DO_INVERSE
@@ -368,7 +368,7 @@ void FSD_BinaryFile::GetReference(Standard_IStream& theIStream, Standard_Integer
 Storage_BaseDriver& FSD_BinaryFile::GetCharacter(Standard_Character& aValue)
 {
   if (!fread(&aValue,sizeof(Standard_Character),1,myStream))
-    Storage_StreamTypeMismatchError::Raise();
+    throw Storage_StreamTypeMismatchError();
   return *this;
 }
 
@@ -380,7 +380,7 @@ Storage_BaseDriver& FSD_BinaryFile::GetCharacter(Standard_Character& aValue)
 Storage_BaseDriver& FSD_BinaryFile::GetExtCharacter(Standard_ExtCharacter& aValue)
 {
   if (!fread(&aValue,sizeof(Standard_ExtCharacter),1,myStream))
-    Storage_StreamTypeMismatchError::Raise();
+    throw Storage_StreamTypeMismatchError();
 #if OCCT_BINARY_FILE_DO_INVERSE
   aValue = InverseExtChar (aValue);
 #endif
@@ -395,7 +395,7 @@ Storage_BaseDriver& FSD_BinaryFile::GetExtCharacter(Standard_ExtCharacter& aValu
 Storage_BaseDriver& FSD_BinaryFile::GetInteger(Standard_Integer& aValue)
 {
   if (!fread(&aValue,sizeof(Standard_Integer),1,myStream))
-    Storage_StreamTypeMismatchError::Raise();
+    throw Storage_StreamTypeMismatchError();
 #if OCCT_BINARY_FILE_DO_INVERSE
   aValue = InverseInt (aValue);
 #endif
@@ -413,7 +413,7 @@ void FSD_BinaryFile::GetInteger (Standard_IStream& theIStream, Standard_Integer&
 
   if (theIStream.gcount() != sizeof(Standard_Integer))
   {
-    Storage_StreamTypeMismatchError::Raise();
+    throw Storage_StreamTypeMismatchError();
   }
    
 #if OCCT_BINARY_FILE_DO_INVERSE
@@ -430,7 +430,7 @@ Storage_BaseDriver& FSD_BinaryFile::GetBoolean(Standard_Boolean& aValue)
 {
   Standard_Integer anInt = 0;
   if (!fread(&anInt,sizeof(Standard_Integer),1,myStream))
-    Storage_StreamTypeMismatchError::Raise();
+    throw Storage_StreamTypeMismatchError();
 #if OCCT_BINARY_FILE_DO_INVERSE
   anInt = InverseInt (anInt);
 #endif
@@ -446,7 +446,7 @@ Storage_BaseDriver& FSD_BinaryFile::GetBoolean(Standard_Boolean& aValue)
 Storage_BaseDriver& FSD_BinaryFile::GetReal(Standard_Real& aValue)
 {
   if (!fread(&aValue,sizeof(Standard_Real),1,myStream))
-    Storage_StreamTypeMismatchError::Raise();
+    throw Storage_StreamTypeMismatchError();
 #if OCCT_BINARY_FILE_DO_INVERSE
   aValue = InverseReal (aValue);
 #endif
@@ -461,7 +461,7 @@ Storage_BaseDriver& FSD_BinaryFile::GetReal(Standard_Real& aValue)
 Storage_BaseDriver& FSD_BinaryFile::GetShortReal(Standard_ShortReal& aValue)
 {
   if (!fread(&aValue,sizeof(Standard_ShortReal),1,myStream))
-    Storage_StreamTypeMismatchError::Raise();
+    throw Storage_StreamTypeMismatchError();
 #if OCCT_BINARY_FILE_DO_INVERSE
   aValue = InverseShortReal (aValue);
 #endif
@@ -503,7 +503,7 @@ Storage_Error FSD_BinaryFile::BeginWriteInfoSection()
               strlen(FSD_BinaryFile::MagicNumber()),
               1,
               myStream))
-    Storage_StreamWriteError::Raise();
+    throw Storage_StreamWriteError();
   
   myHeader.binfo = ftell(myStream);
   WriteHeader();
@@ -1427,7 +1427,7 @@ void FSD_BinaryFile::WriteString(const TCollection_AsciiString& aString)
   PutInteger(size);
 
   if (size > 0) {
-    if (!fwrite(aString.ToCString(),aString.Length(),1,myStream)) Storage_StreamWriteError::Raise();
+    if (!fwrite(aString.ToCString(),aString.Length(),1,myStream)) throw Storage_StreamWriteError();
   }
 }
 
@@ -1450,7 +1450,7 @@ Standard_Integer FSD_BinaryFile::WriteString (Standard_OStream&              the
     theOStream.write (theString.ToCString(), theString.Length());
     if (theOStream.fail())
     {
-      Storage_StreamWriteError::Raise();
+      throw Storage_StreamWriteError();
     }
   }
 
@@ -1469,7 +1469,7 @@ void FSD_BinaryFile::ReadString(TCollection_AsciiString& aString)
   GetInteger(size);
   if (size > 0) {
     Standard_Character *c = (Standard_Character *)Standard::Allocate((size+1) * sizeof(Standard_Character));
-    if (!fread(c,size,1,myStream)) Storage_StreamWriteError::Raise();
+    if (!fread(c,size,1,myStream)) throw Storage_StreamWriteError();
     c[size] = '\0';
     aString = c;
     Standard::Free(c);
@@ -1495,14 +1495,14 @@ void FSD_BinaryFile::ReadString (Standard_IStream& theIStream, TCollection_Ascii
 
     if (!theIStream.good())
     {
-      Storage_StreamReadError::Raise();
+      throw Storage_StreamReadError();
     }
 
     theIStream.read (c, size);
 
     if (theIStream.gcount() != size)
     {
-      Storage_StreamReadError::Raise();
+      throw Storage_StreamReadError();
     }
 
     c[size] = '\0';
@@ -1546,7 +1546,7 @@ void FSD_BinaryFile::WriteExtendedString(const TCollection_ExtendedString& aStri
     anExtStr = aString.ToExtString();
 #endif
     if (!fwrite(anExtStr,sizeof(Standard_ExtCharacter)*aString.Length(),1,myStream))
-      Storage_StreamWriteError::Raise();
+      throw Storage_StreamWriteError();
   }
 }
 
@@ -1586,7 +1586,7 @@ Standard_Integer FSD_BinaryFile::WriteExtendedString (Standard_OStream&
     theOStream.write((char*)anExtStr, sizeof(Standard_ExtCharacter)*theString.Length());
     if (theOStream.fail())
     {
-      Storage_StreamWriteError::Raise();
+      throw Storage_StreamWriteError();
     }
   }
 
@@ -1607,7 +1607,7 @@ void FSD_BinaryFile::ReadExtendedString(TCollection_ExtendedString& aString)
     Standard_ExtCharacter *c = (Standard_ExtCharacter *)
       Standard::Allocate((size+1) * sizeof(Standard_ExtCharacter));
     if (!fread(c,size*sizeof(Standard_ExtCharacter),1,myStream))
-      Storage_StreamWriteError::Raise();
+      throw Storage_StreamWriteError();
     c[size] = '\0';
 #if OCCT_BINARY_FILE_DO_INVERSE
     for (Standard_Integer i=0; i < size; i++)
@@ -1637,14 +1637,14 @@ void FSD_BinaryFile::ReadExtendedString (Standard_IStream& theIStream, TCollecti
 
     if (!theIStream.good())
     {
-      Storage_StreamReadError::Raise();
+      throw Storage_StreamReadError();
     }
 
     const std::streamsize aNbBytes = std::streamsize(sizeof(Standard_ExtCharacter) * size);
     theIStream.read ((char *)c, aNbBytes);
     if (theIStream.gcount() != aNbBytes)
     {
-      Storage_StreamReadError::Raise();
+      throw Storage_StreamReadError();
     }
 
     c[size] = '\0';
index 1378512..ab00bd5 100644 (file)
@@ -428,7 +428,7 @@ void FSD_CmpFile::SkipObject()
 Storage_BaseDriver& FSD_CmpFile::PutReference(const Standard_Integer aValue)
 {
   myStream << aValue << " ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return *this;
 }
 
@@ -443,7 +443,7 @@ Storage_BaseDriver& FSD_CmpFile::PutCharacter(const Standard_Character aValue)
 
   i = aValue;
   myStream << i << " ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return *this;
 }
 
@@ -455,7 +455,7 @@ Storage_BaseDriver& FSD_CmpFile::PutCharacter(const Standard_Character aValue)
 Storage_BaseDriver& FSD_CmpFile::PutExtCharacter(const Standard_ExtCharacter aValue)
 {
   myStream << (short )aValue << " ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return *this;
 }
 
@@ -467,7 +467,7 @@ Storage_BaseDriver& FSD_CmpFile::PutExtCharacter(const Standard_ExtCharacter aVa
 Storage_BaseDriver& FSD_CmpFile::PutInteger(const Standard_Integer aValue)
 {
   myStream << aValue << " ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return *this;
 }
 
@@ -479,7 +479,7 @@ Storage_BaseDriver& FSD_CmpFile::PutInteger(const Standard_Integer aValue)
 Storage_BaseDriver& FSD_CmpFile::PutBoolean(const Standard_Boolean aValue)
 {
   myStream << ((Standard_Integer)aValue) << " ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return *this;
 }
 
@@ -491,7 +491,7 @@ Storage_BaseDriver& FSD_CmpFile::PutBoolean(const Standard_Boolean aValue)
 Storage_BaseDriver& FSD_CmpFile::PutReal(const Standard_Real aValue)
 {
   myStream << ((Standard_Real)aValue) << " ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return *this;
 }
 
@@ -503,7 +503,7 @@ Storage_BaseDriver& FSD_CmpFile::PutReal(const Standard_Real aValue)
 Storage_BaseDriver& FSD_CmpFile::PutShortReal(const Standard_ShortReal aValue)
 {
   myStream << aValue << " ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return *this;
 }
 
@@ -514,7 +514,7 @@ Storage_BaseDriver& FSD_CmpFile::PutShortReal(const Standard_ShortReal aValue)
 
 Storage_BaseDriver& FSD_CmpFile::GetReference(Standard_Integer& aValue)
 {
-  if (!(myStream >> aValue)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> aValue)) throw Storage_StreamTypeMismatchError();
 
   return *this;
 }
@@ -531,7 +531,7 @@ Storage_BaseDriver& FSD_CmpFile::GetCharacter(Standard_Character& aValue)
     // SGI : donne une erreur mais a une bonne valeur pour les caracteres ecrits
     //       signes (-80 fait ios::badbit, mais la variable i est initialisee)
     //
-    if (i == 0) Storage_StreamTypeMismatchError::Raise();
+    if (i == 0) throw Storage_StreamTypeMismatchError();
     myStream.clear(ios::goodbit);
   }
   aValue = (char)i;
@@ -547,7 +547,7 @@ Storage_BaseDriver& FSD_CmpFile::GetCharacter(Standard_Character& aValue)
 Storage_BaseDriver& FSD_CmpFile::GetExtCharacter(Standard_ExtCharacter& aValue)
 {
   short aChar = 0;
-  if (!(myStream >> aChar)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> aChar)) throw Storage_StreamTypeMismatchError();
   aValue = aChar;
   return *this;
 }
@@ -559,7 +559,7 @@ Storage_BaseDriver& FSD_CmpFile::GetExtCharacter(Standard_ExtCharacter& aValue)
 
 Storage_BaseDriver& FSD_CmpFile::GetInteger(Standard_Integer& aValue)
 {
-  if (!(myStream >> aValue)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> aValue)) throw Storage_StreamTypeMismatchError();
 
   return *this;
 }
@@ -571,7 +571,7 @@ Storage_BaseDriver& FSD_CmpFile::GetInteger(Standard_Integer& aValue)
 
 Storage_BaseDriver& FSD_CmpFile::GetBoolean(Standard_Boolean& aValue)
 {
-  if (!(myStream >> aValue)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> aValue)) throw Storage_StreamTypeMismatchError();
 
   return *this;
 }
@@ -591,14 +591,14 @@ Storage_BaseDriver& FSD_CmpFile::GetReal(Standard_Real& aValue)
     cerr << "%%%ERROR: read error of double at offset " << myStream.tellg() << endl;
     cerr << "\t buffer is" << realbuffer<< endl;
 #endif
-    Storage_StreamTypeMismatchError::Raise();
+    throw Storage_StreamTypeMismatchError();
   }
   if (!OSD::CStringToReal(realbuffer,aValue)) {
 #ifdef OCCT_DEBUG
     cerr << "%%%ERROR: read error of double at offset " << myStream.tellg() << endl;
     cerr << "\t buffer is" << realbuffer<< endl;
 #endif
-    Storage_StreamTypeMismatchError::Raise();
+    throw Storage_StreamTypeMismatchError();
   }
 
   return *this;
@@ -615,9 +615,9 @@ Storage_BaseDriver& FSD_CmpFile::GetShortReal(Standard_ShortReal& aValue)
   Standard_Real r = 0.0;
 
   realbuffer[0] = '\0';
-  if (!(myStream >> realbuffer)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> realbuffer)) throw Storage_StreamTypeMismatchError();
   if (!OSD::CStringToReal(realbuffer,r))
-    Storage_StreamTypeMismatchError::Raise();
+    throw Storage_StreamTypeMismatchError();
 
   aValue = (Standard_ShortReal)r;
 
@@ -645,7 +645,7 @@ Storage_Error FSD_CmpFile::BeginWriteInfoSection()
 {
   myStream << FSD_CmpFile::MagicNumber() << '\n';
   myStream << "BEGIN_INFO_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 
   return Storage_VSOk;
 }
@@ -678,11 +678,11 @@ void FSD_CmpFile::WriteInfo(const Standard_Integer nbObj,
   WriteExtendedLine(dataType);
   myStream << userInfo.Length() << "\n";
 
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 
   for (i = 1; i <= userInfo.Length(); i++) {
     myStream << userInfo.Value(i).ToCString() << "\n";
-    if (myStream.bad()) Storage_StreamWriteError::Raise();
+    if (myStream.bad()) throw Storage_StreamWriteError();
   }
 }
 
@@ -694,7 +694,7 @@ void FSD_CmpFile::WriteInfo(const Standard_Integer nbObj,
 Storage_Error FSD_CmpFile::EndWriteInfoSection() 
 {
   myStream << "END_INFO_SECTION\n";
-  if (myStream.bad())  Storage_StreamWriteError::Raise();
+  if (myStream.bad())  throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -736,7 +736,7 @@ void FSD_CmpFile::ReadInfo(Standard_Integer& nbObj,
                        TCollection_ExtendedString& dataType,
                        TColStd_SequenceOfAsciiString& userInfo) 
 {
-  if (!(myStream >> nbObj)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> nbObj)) throw Storage_StreamTypeMismatchError();
 
   FlushEndOfLine();
 
@@ -750,7 +750,7 @@ void FSD_CmpFile::ReadInfo(Standard_Integer& nbObj,
 
   Standard_Integer i,len = 0;
 
-  if (!(myStream >> len)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> len)) throw Storage_StreamTypeMismatchError();
 
   FlushEndOfLine();
 
@@ -792,7 +792,7 @@ Storage_Error FSD_CmpFile::EndReadInfoSection()
 Storage_Error FSD_CmpFile::BeginWriteCommentSection() 
 {
   myStream << "BEGIN_COMMENT_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -807,11 +807,11 @@ void FSD_CmpFile::WriteComment(const TColStd_SequenceOfExtendedString& aCom)
 
  aSize = aCom.Length();
  myStream << aSize << "\n";
- if (myStream.bad()) Storage_StreamWriteError::Raise();
+ if (myStream.bad()) throw Storage_StreamWriteError();
 
  for (i = 1; i <= aSize; i++) {
    WriteExtendedLine(aCom.Value(i));
-   if (myStream.bad()) Storage_StreamWriteError::Raise();
+   if (myStream.bad()) throw Storage_StreamWriteError();
  }
 }
 
@@ -823,7 +823,7 @@ void FSD_CmpFile::WriteComment(const TColStd_SequenceOfExtendedString& aCom)
 Storage_Error FSD_CmpFile::EndWriteCommentSection() 
 {
   myStream << "END_COMMENT_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -847,7 +847,7 @@ void FSD_CmpFile::ReadComment(TColStd_SequenceOfExtendedString& aCom)
   TCollection_ExtendedString line;
   Standard_Integer           len,i;
 
-  if (!(myStream >> len)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> len)) throw Storage_StreamTypeMismatchError();
   
   FlushEndOfLine();  
 
@@ -876,7 +876,7 @@ Storage_Error FSD_CmpFile::EndReadCommentSection()
 Storage_Error FSD_CmpFile::BeginWriteTypeSection() 
 {
   myStream << "BEGIN_TYPE_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -888,7 +888,7 @@ Storage_Error FSD_CmpFile::BeginWriteTypeSection()
 void FSD_CmpFile::SetTypeSectionSize(const Standard_Integer aSize) 
 {
   myStream << aSize << "\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -900,7 +900,7 @@ void FSD_CmpFile::WriteTypeInformations(const Standard_Integer typeNum,
                                      const TCollection_AsciiString& typeName) 
 {
   myStream << typeNum << " " << typeName.ToCString() << "\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -911,7 +911,7 @@ void FSD_CmpFile::WriteTypeInformations(const Standard_Integer typeNum,
 Storage_Error FSD_CmpFile::EndWriteTypeSection() 
 {
   myStream << "END_TYPE_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -934,7 +934,7 @@ Standard_Integer FSD_CmpFile::TypeSectionSize()
 {
   Standard_Integer i;
 
-  if (!(myStream >> i)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> i)) throw Storage_StreamTypeMismatchError();
 
   FlushEndOfLine();
 
@@ -949,8 +949,8 @@ Standard_Integer FSD_CmpFile::TypeSectionSize()
 void FSD_CmpFile::ReadTypeInformations(Standard_Integer& typeNum,
                                    TCollection_AsciiString& typeName) 
 {
-  if (!(myStream >> typeNum)) Storage_StreamTypeMismatchError::Raise();
-  if (!(myStream >> typeName)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> typeNum)) throw Storage_StreamTypeMismatchError();
+  if (!(myStream >> typeName)) throw Storage_StreamTypeMismatchError();
   FlushEndOfLine();
 }
 
@@ -973,7 +973,7 @@ Storage_Error FSD_CmpFile::EndReadTypeSection()
 Storage_Error FSD_CmpFile::BeginWriteRootSection() 
 {
   myStream << "BEGIN_ROOT_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -985,7 +985,7 @@ Storage_Error FSD_CmpFile::BeginWriteRootSection()
 void FSD_CmpFile::SetRootSectionSize(const Standard_Integer aSize) 
 {
   myStream << aSize << "\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -996,7 +996,7 @@ void FSD_CmpFile::SetRootSectionSize(const Standard_Integer aSize)
 void FSD_CmpFile::WriteRoot(const TCollection_AsciiString& rootName, const Standard_Integer aRef, const TCollection_AsciiString& rootType) 
 {
   myStream << aRef << " " << rootName.ToCString() << " " << rootType.ToCString() << "\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1007,7 +1007,7 @@ void FSD_CmpFile::WriteRoot(const TCollection_AsciiString& rootName, const Stand
 Storage_Error FSD_CmpFile::EndWriteRootSection() 
 {
   myStream << "END_ROOT_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -1030,7 +1030,7 @@ Standard_Integer FSD_CmpFile::RootSectionSize()
 {
   Standard_Integer i;
 
-  if (!(myStream >> i)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> i)) throw Storage_StreamTypeMismatchError();
   
   FlushEndOfLine();
   
@@ -1044,7 +1044,7 @@ Standard_Integer FSD_CmpFile::RootSectionSize()
 
 void FSD_CmpFile::ReadRoot(TCollection_AsciiString& rootName, Standard_Integer& aRef,TCollection_AsciiString& rootType) 
 {
-  if (!(myStream >> aRef)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> aRef)) throw Storage_StreamTypeMismatchError();
   ReadWord(rootName);
   ReadWord(rootType);
 }
@@ -1068,7 +1068,7 @@ Storage_Error FSD_CmpFile::EndReadRootSection()
 Storage_Error FSD_CmpFile::BeginWriteRefSection() 
 {
   myStream << "BEGIN_REF_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -1080,7 +1080,7 @@ Storage_Error FSD_CmpFile::BeginWriteRefSection()
 void FSD_CmpFile::SetRefSectionSize(const Standard_Integer aSize) 
 {
   myStream << aSize << "\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1092,7 +1092,7 @@ void FSD_CmpFile::WriteReferenceType(const Standard_Integer reference,
                                  const Standard_Integer typeNum) 
 {
   myStream << reference << " " << typeNum << "\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1103,7 +1103,7 @@ void FSD_CmpFile::WriteReferenceType(const Standard_Integer reference,
 Storage_Error FSD_CmpFile::EndWriteRefSection() 
 {
   myStream << "END_REF_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -1126,7 +1126,7 @@ Standard_Integer FSD_CmpFile::RefSectionSize()
 {
   Standard_Integer i;
 
-  if (!(myStream >> i)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> i)) throw Storage_StreamTypeMismatchError();
   FlushEndOfLine();
 
   return i;
@@ -1140,8 +1140,8 @@ Standard_Integer FSD_CmpFile::RefSectionSize()
 void FSD_CmpFile::ReadReferenceType(Standard_Integer& reference,
                                 Standard_Integer& typeNum) 
 {
-  if (!(myStream >> reference)) Storage_StreamTypeMismatchError::Raise();
-  if (!(myStream >> typeNum)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> reference)) throw Storage_StreamTypeMismatchError();
+  if (!(myStream >> typeNum)) throw Storage_StreamTypeMismatchError();
   FlushEndOfLine();
 }
 
@@ -1164,7 +1164,7 @@ Storage_Error FSD_CmpFile::EndReadRefSection()
 Storage_Error FSD_CmpFile::BeginWriteDataSection() 
 {
   myStream << "BEGIN_DATA_SECTION";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -1177,7 +1177,7 @@ void FSD_CmpFile::WritePersistentObjectHeader(const Standard_Integer aRef,
                                           const Standard_Integer aType) 
 {
   myStream << "\n#" << aRef << "%" << aType << " ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1187,7 +1187,7 @@ void FSD_CmpFile::WritePersistentObjectHeader(const Standard_Integer aRef,
 
 void FSD_CmpFile::BeginWritePersistentObjectData() 
 {
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1197,7 +1197,7 @@ void FSD_CmpFile::BeginWritePersistentObjectData()
 
 void FSD_CmpFile::BeginWriteObjectData() 
 {
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1207,7 +1207,7 @@ void FSD_CmpFile::BeginWriteObjectData()
 
 void FSD_CmpFile::EndWriteObjectData() 
 {
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1217,7 +1217,7 @@ void FSD_CmpFile::EndWriteObjectData()
 
 void FSD_CmpFile::EndWritePersistentObjectData() 
 {
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1228,7 +1228,7 @@ void FSD_CmpFile::EndWritePersistentObjectData()
 Storage_Error FSD_CmpFile::EndWriteDataSection() 
 {
   myStream << "\nEND_DATA_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -1256,23 +1256,23 @@ void FSD_CmpFile::ReadPersistentObjectHeader(Standard_Integer& aRef,
 
   while (c != '#') {
     if (IsEnd() || (c != ' ') || (c == '\r')|| (c == '\n')) {
-      Storage_StreamFormatError::Raise();
+      throw Storage_StreamFormatError();
     }
     myStream.get(c);
   }
 
-  if (!(myStream >> aRef)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> aRef)) throw Storage_StreamTypeMismatchError();
 
   myStream.get(c);
 
   while (c != '%') {
     if (IsEnd() || (c != ' ') || (c == '\r')|| (c == '\n')) {
-      Storage_StreamFormatError::Raise();
+      throw Storage_StreamFormatError();
     }
     myStream.get(c);
   }
 
-  if (!(myStream >> aType)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> aType)) throw Storage_StreamTypeMismatchError();
 //  cout << "REF:" << aRef << " TYPE:"<< aType << endl;
 }
 
@@ -1318,7 +1318,7 @@ void FSD_CmpFile::EndReadPersistentObjectData()
   myStream.get(c);
   while (c != '\n' && (c != '\r')) {
     if (IsEnd() || (c != ' ')) {
-      Storage_StreamFormatError::Raise();
+      throw Storage_StreamFormatError();
     }
     myStream.get(c);
   }
index 6a01450..1d1e1ae 100644 (file)
@@ -278,11 +278,11 @@ void FSD_File::ReadExtendedLine(TCollection_ExtendedString& buffer)
        }
       }
       else {
-       Storage_StreamExtCharParityError::Raise();      
+       throw Storage_StreamExtCharParityError();
       }
     }
     else {
-      Storage_StreamExtCharParityError::Raise();
+      throw Storage_StreamExtCharParityError();
     }
   }
 }
@@ -424,7 +424,7 @@ void FSD_File::SkipObject()
 Storage_BaseDriver& FSD_File::PutReference(const Standard_Integer aValue)
 {
   myStream << aValue << " ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return *this;
 }
 
@@ -439,7 +439,7 @@ Storage_BaseDriver& FSD_File::PutCharacter(const Standard_Character aValue)
 
   i = aValue;
   myStream << i << " ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return *this;
 }
 
@@ -451,7 +451,7 @@ Storage_BaseDriver& FSD_File::PutCharacter(const Standard_Character aValue)
 Storage_BaseDriver& FSD_File::PutExtCharacter(const Standard_ExtCharacter aValue)
 {
   myStream << (short )aValue << " ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return *this;
 }
 
@@ -463,7 +463,7 @@ Storage_BaseDriver& FSD_File::PutExtCharacter(const Standard_ExtCharacter aValue
 Storage_BaseDriver& FSD_File::PutInteger(const Standard_Integer aValue)
 {
   myStream << aValue << " ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return *this;
 }
 
@@ -475,7 +475,7 @@ Storage_BaseDriver& FSD_File::PutInteger(const Standard_Integer aValue)
 Storage_BaseDriver& FSD_File::PutBoolean(const Standard_Boolean aValue)
 {
   myStream << ((Standard_Integer)aValue) << " ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return *this;
 }
 
@@ -487,7 +487,7 @@ Storage_BaseDriver& FSD_File::PutBoolean(const Standard_Boolean aValue)
 Storage_BaseDriver& FSD_File::PutReal(const Standard_Real aValue)
 {
   myStream << ((Standard_Real)aValue) << " ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return *this;
 }
 
@@ -499,7 +499,7 @@ Storage_BaseDriver& FSD_File::PutReal(const Standard_Real aValue)
 Storage_BaseDriver& FSD_File::PutShortReal(const Standard_ShortReal aValue)
 {
   myStream << aValue << " ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return *this;
 }
 
@@ -510,7 +510,7 @@ Storage_BaseDriver& FSD_File::PutShortReal(const Standard_ShortReal aValue)
 
 Storage_BaseDriver& FSD_File::GetReference(Standard_Integer& aValue)
 {
-  if (!(myStream >> aValue)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> aValue)) throw Storage_StreamTypeMismatchError();
 
   return *this;
 }
@@ -527,7 +527,7 @@ Storage_BaseDriver& FSD_File::GetCharacter(Standard_Character& aValue)
     // SGI : donne une erreur mais a une bonne valeur pour les caracteres ecrits
     //       signes (-80 fait ios::badbit, mais la variable i est initialisee)
     //
-    if (i == 0) Storage_StreamTypeMismatchError::Raise();
+    if (i == 0) throw Storage_StreamTypeMismatchError();
     myStream.clear(ios::goodbit); // .clear(0) is not portable
   }
   aValue = (char)i;
@@ -543,7 +543,7 @@ Storage_BaseDriver& FSD_File::GetCharacter(Standard_Character& aValue)
 Storage_BaseDriver& FSD_File::GetExtCharacter(Standard_ExtCharacter& aValue)
 {
   short aChar = 0;
-  if (!(myStream >> aChar)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> aChar)) throw Storage_StreamTypeMismatchError();
   aValue = aChar;
   return *this;
 }
@@ -555,7 +555,7 @@ Storage_BaseDriver& FSD_File::GetExtCharacter(Standard_ExtCharacter& aValue)
 
 Storage_BaseDriver& FSD_File::GetInteger(Standard_Integer& aValue)
 {
-  if (!(myStream >> aValue)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> aValue)) throw Storage_StreamTypeMismatchError();
 
   return *this;
 }
@@ -567,7 +567,7 @@ Storage_BaseDriver& FSD_File::GetInteger(Standard_Integer& aValue)
 
 Storage_BaseDriver& FSD_File::GetBoolean(Standard_Boolean& aValue)
 {
-  if (!(myStream >> aValue)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> aValue)) throw Storage_StreamTypeMismatchError();
 
   return *this;
 }
@@ -583,12 +583,12 @@ Storage_BaseDriver& FSD_File::GetReal(Standard_Real& aValue)
   char realbuffer[100];
 
   realbuffer[0] = '\0';
-  if (!(myStream >> realbuffer)) Storage_StreamTypeMismatchError::Raise();
-  if (!OSD::CStringToReal(realbuffer,aValue)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> realbuffer)) throw Storage_StreamTypeMismatchError();
+  if (!OSD::CStringToReal(realbuffer,aValue)) throw Storage_StreamTypeMismatchError();
 
   return *this;
 #else
-  if (!(myStream >> aValue)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> aValue)) throw Storage_StreamTypeMismatchError();
 
   return *this;
 #endif
@@ -606,14 +606,14 @@ Storage_BaseDriver& FSD_File::GetShortReal(Standard_ShortReal& aValue)
   Standard_Real r = 0.0;
 
   realbuffer[0] = '\0';
-  if (!(myStream >> realbuffer)) Storage_StreamTypeMismatchError::Raise();
-  if (!OSD::CStringToReal(realbuffer,r)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> realbuffer)) throw Storage_StreamTypeMismatchError();
+  if (!OSD::CStringToReal(realbuffer,r)) throw Storage_StreamTypeMismatchError();
 
   aValue = r;
 
   return *this;
 #else
-  if (!(myStream >> aValue)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> aValue)) throw Storage_StreamTypeMismatchError();
  return *this;
 #endif
 }
@@ -639,7 +639,7 @@ Storage_Error FSD_File::BeginWriteInfoSection()
 {
   myStream << FSD_File::MagicNumber() << '\n';
   myStream << "BEGIN_INFO_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 
   return Storage_VSOk;
 }
@@ -672,11 +672,11 @@ void FSD_File::WriteInfo(const Standard_Integer nbObj,
   WriteExtendedLine(dataType);
   myStream << userInfo.Length() << "\n";
 
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 
   for (i = 1; i <= userInfo.Length(); i++) {
     myStream << userInfo.Value(i).ToCString() << "\n";
-    if (myStream.bad()) Storage_StreamWriteError::Raise();
+    if (myStream.bad()) throw Storage_StreamWriteError();
   }
 }
 
@@ -688,7 +688,7 @@ void FSD_File::WriteInfo(const Standard_Integer nbObj,
 Storage_Error FSD_File::EndWriteInfoSection() 
 {
   myStream << "END_INFO_SECTION\n";
-  if (myStream.bad())  Storage_StreamWriteError::Raise();
+  if (myStream.bad())  throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -730,7 +730,7 @@ void FSD_File::ReadInfo(Standard_Integer& nbObj,
                        TCollection_ExtendedString& dataType,
                        TColStd_SequenceOfAsciiString& userInfo) 
 {
-  if (!(myStream >> nbObj)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> nbObj)) throw Storage_StreamTypeMismatchError();
 
   FlushEndOfLine();
 
@@ -744,7 +744,7 @@ void FSD_File::ReadInfo(Standard_Integer& nbObj,
 
   Standard_Integer i,len = 0;
 
-  if (!(myStream >> len)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> len)) throw Storage_StreamTypeMismatchError();
 
   FlushEndOfLine();
 
@@ -786,7 +786,7 @@ Storage_Error FSD_File::EndReadInfoSection()
 Storage_Error FSD_File::BeginWriteCommentSection() 
 {
   myStream << "BEGIN_COMMENT_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -801,11 +801,11 @@ void FSD_File::WriteComment(const TColStd_SequenceOfExtendedString& aCom)
 
  aSize = aCom.Length();
  myStream << aSize << "\n";
- if (myStream.bad()) Storage_StreamWriteError::Raise();
+ if (myStream.bad()) throw Storage_StreamWriteError();
 
  for (i = 1; i <= aSize; i++) {
    WriteExtendedLine(aCom.Value(i));
-   if (myStream.bad()) Storage_StreamWriteError::Raise();
+   if (myStream.bad()) throw Storage_StreamWriteError();
  }
 }
 
@@ -817,7 +817,7 @@ void FSD_File::WriteComment(const TColStd_SequenceOfExtendedString& aCom)
 Storage_Error FSD_File::EndWriteCommentSection() 
 {
   myStream << "END_COMMENT_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -841,7 +841,7 @@ void FSD_File::ReadComment(TColStd_SequenceOfExtendedString& aCom)
   TCollection_ExtendedString line;
   Standard_Integer           len,i;
 
-  if (!(myStream >> len)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> len)) throw Storage_StreamTypeMismatchError();
   
   FlushEndOfLine();  
 
@@ -870,7 +870,7 @@ Storage_Error FSD_File::EndReadCommentSection()
 Storage_Error FSD_File::BeginWriteTypeSection() 
 {
   myStream << "BEGIN_TYPE_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -882,7 +882,7 @@ Storage_Error FSD_File::BeginWriteTypeSection()
 void FSD_File::SetTypeSectionSize(const Standard_Integer aSize) 
 {
   myStream << aSize << "\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -894,7 +894,7 @@ void FSD_File::WriteTypeInformations(const Standard_Integer typeNum,
                                      const TCollection_AsciiString& typeName) 
 {
   myStream << typeNum << " " << typeName.ToCString() << "\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -905,7 +905,7 @@ void FSD_File::WriteTypeInformations(const Standard_Integer typeNum,
 Storage_Error FSD_File::EndWriteTypeSection() 
 {
   myStream << "END_TYPE_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -928,7 +928,7 @@ Standard_Integer FSD_File::TypeSectionSize()
 {
   Standard_Integer i;
 
-  if (!(myStream >> i)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> i)) throw Storage_StreamTypeMismatchError();
 
   FlushEndOfLine();
 
@@ -943,8 +943,8 @@ Standard_Integer FSD_File::TypeSectionSize()
 void FSD_File::ReadTypeInformations(Standard_Integer& typeNum,
                                    TCollection_AsciiString& typeName) 
 {
-  if (!(myStream >> typeNum)) Storage_StreamTypeMismatchError::Raise();
-  if (!(myStream >> typeName)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> typeNum)) throw Storage_StreamTypeMismatchError();
+  if (!(myStream >> typeName)) throw Storage_StreamTypeMismatchError();
   FlushEndOfLine();
 }
 
@@ -967,7 +967,7 @@ Storage_Error FSD_File::EndReadTypeSection()
 Storage_Error FSD_File::BeginWriteRootSection() 
 {
   myStream << "BEGIN_ROOT_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -979,7 +979,7 @@ Storage_Error FSD_File::BeginWriteRootSection()
 void FSD_File::SetRootSectionSize(const Standard_Integer aSize) 
 {
   myStream << aSize << "\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -990,7 +990,7 @@ void FSD_File::SetRootSectionSize(const Standard_Integer aSize)
 void FSD_File::WriteRoot(const TCollection_AsciiString& rootName, const Standard_Integer aRef, const TCollection_AsciiString& rootType) 
 {
   myStream << aRef << " " << rootName.ToCString() << " " << rootType.ToCString() << "\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1001,7 +1001,7 @@ void FSD_File::WriteRoot(const TCollection_AsciiString& rootName, const Standard
 Storage_Error FSD_File::EndWriteRootSection() 
 {
   myStream << "END_ROOT_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -1024,7 +1024,7 @@ Standard_Integer FSD_File::RootSectionSize()
 {
   Standard_Integer i;
 
-  if (!(myStream >> i)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> i)) throw Storage_StreamTypeMismatchError();
   
   FlushEndOfLine();
   
@@ -1038,7 +1038,7 @@ Standard_Integer FSD_File::RootSectionSize()
 
 void FSD_File::ReadRoot(TCollection_AsciiString& rootName, Standard_Integer& aRef,TCollection_AsciiString& rootType) 
 {
-  if (!(myStream >> aRef)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> aRef)) throw Storage_StreamTypeMismatchError();
   ReadWord(rootName);
   ReadWord(rootType);
 }
@@ -1062,7 +1062,7 @@ Storage_Error FSD_File::EndReadRootSection()
 Storage_Error FSD_File::BeginWriteRefSection() 
 {
   myStream << "BEGIN_REF_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -1074,7 +1074,7 @@ Storage_Error FSD_File::BeginWriteRefSection()
 void FSD_File::SetRefSectionSize(const Standard_Integer aSize) 
 {
   myStream << aSize << "\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1086,7 +1086,7 @@ void FSD_File::WriteReferenceType(const Standard_Integer reference,
                                  const Standard_Integer typeNum) 
 {
   myStream << reference << " " << typeNum << "\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1097,7 +1097,7 @@ void FSD_File::WriteReferenceType(const Standard_Integer reference,
 Storage_Error FSD_File::EndWriteRefSection() 
 {
   myStream << "END_REF_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -1120,7 +1120,7 @@ Standard_Integer FSD_File::RefSectionSize()
 {
   Standard_Integer i;
 
-  if (!(myStream >> i)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> i)) throw Storage_StreamTypeMismatchError();
   FlushEndOfLine();
 
   return i;
@@ -1134,8 +1134,8 @@ Standard_Integer FSD_File::RefSectionSize()
 void FSD_File::ReadReferenceType(Standard_Integer& reference,
                                 Standard_Integer& typeNum) 
 {
-  if (!(myStream >> reference)) Storage_StreamTypeMismatchError::Raise();
-  if (!(myStream >> typeNum)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> reference)) throw Storage_StreamTypeMismatchError();
+  if (!(myStream >> typeNum)) throw Storage_StreamTypeMismatchError();
   FlushEndOfLine();
 }
 
@@ -1158,7 +1158,7 @@ Storage_Error FSD_File::EndReadRefSection()
 Storage_Error FSD_File::BeginWriteDataSection() 
 {
   myStream << "BEGIN_DATA_SECTION";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -1171,7 +1171,7 @@ void FSD_File::WritePersistentObjectHeader(const Standard_Integer aRef,
                                           const Standard_Integer aType) 
 {
   myStream << "\n#" << aRef << "=%" << aType;
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1182,7 +1182,7 @@ void FSD_File::WritePersistentObjectHeader(const Standard_Integer aRef,
 void FSD_File::BeginWritePersistentObjectData() 
 {
   myStream << "( ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1193,7 +1193,7 @@ void FSD_File::BeginWritePersistentObjectData()
 void FSD_File::BeginWriteObjectData() 
 {
   myStream << "( ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1204,7 +1204,7 @@ void FSD_File::BeginWriteObjectData()
 void FSD_File::EndWriteObjectData() 
 {
   myStream << ") ";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1215,7 +1215,7 @@ void FSD_File::EndWriteObjectData()
 void FSD_File::EndWritePersistentObjectData() 
 {
   myStream << ")";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
 }
 
 //=======================================================================
@@ -1226,7 +1226,7 @@ void FSD_File::EndWritePersistentObjectData()
 Storage_Error FSD_File::EndWriteDataSection() 
 {
   myStream << "\nEND_DATA_SECTION\n";
-  if (myStream.bad()) Storage_StreamWriteError::Raise();
+  if (myStream.bad()) throw Storage_StreamWriteError();
   return Storage_VSOk;
 }
 
@@ -1254,19 +1254,19 @@ void FSD_File::ReadPersistentObjectHeader(Standard_Integer& aRef,
 
   while (c != '#') {
     if (IsEnd() || (c != ' ') || (c == '\n')) {
-      Storage_StreamFormatError::Raise();
+      throw Storage_StreamFormatError();
     }
     myStream.get(c);
   }
 
-  if (!(myStream >> aRef)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> aRef)) throw Storage_StreamTypeMismatchError();
 
   myStream.get(c);
 
 
    while (c != '=') {
     if (IsEnd() || (c != ' ') || (c == '\n')) {
-      Storage_StreamFormatError::Raise();
+      throw Storage_StreamFormatError();
     }
     myStream.get(c);
   }
@@ -1275,12 +1275,12 @@ void FSD_File::ReadPersistentObjectHeader(Standard_Integer& aRef,
 
   while (c != '%') {
     if (IsEnd() || (c != ' ') || (c == '\n')) {
-      Storage_StreamFormatError::Raise();
+      throw Storage_StreamFormatError();
     }
     myStream.get(c);
   }
 
-  if (!(myStream >> aType)) Storage_StreamTypeMismatchError::Raise();
+  if (!(myStream >> aType)) throw Storage_StreamTypeMismatchError();
 //  cout << "REF:" << aRef << " TYPE:"<< aType << endl;
 }
 
@@ -1295,7 +1295,7 @@ void FSD_File::BeginReadPersistentObjectData()
   myStream.get(c);
   while (c != '(') {
     if (IsEnd() || (c != ' ') || (c == '\n')) {
-      Storage_StreamFormatError::Raise();
+      throw Storage_StreamFormatError();
     }
     myStream.get(c);
   }
@@ -1315,7 +1315,7 @@ void FSD_File::BeginReadObjectData()
   myStream.get(c);
   while (c != '(') {
     if (IsEnd() || (c != ' ') || (c == '\n')) {
-      Storage_StreamFormatError::Raise();
+      throw Storage_StreamFormatError();
     }
     myStream.get(c);
   }
@@ -1335,7 +1335,7 @@ void FSD_File::EndReadObjectData()
   myStream.get(c);
   while (c != ')') {
     if (IsEnd() || (c != ' ') || (c == '\n')) {
-      Storage_StreamFormatError::Raise();
+      throw Storage_StreamFormatError();
     }
     myStream.get(c);
   }
@@ -1356,7 +1356,7 @@ void FSD_File::EndReadPersistentObjectData()
   myStream.get(c);
   while (c != ')') {
     if (IsEnd() || (c != ' ') || (c == '\n')) {
-      Storage_StreamFormatError::Raise();
+      throw Storage_StreamFormatError();
     }
     myStream.get(c);
   }
@@ -1364,7 +1364,7 @@ void FSD_File::EndReadPersistentObjectData()
   myStream.get(c);
   while (c != '\n') {
     if (IsEnd() || (c != ' ')) {
-      Storage_StreamFormatError::Raise();
+      throw Storage_StreamFormatError();
     }
     myStream.get(c);
   }
index 259c67d..60dde67 100644 (file)
@@ -64,9 +64,9 @@ FairCurve_Batten::FairCurve_Batten(const gp_Pnt2d& P1,
                     Degree(9)
 {
   if (P1.IsEqual(P2, Precision::Confusion())) 
-    Standard_NullValue::Raise("FairCurve : P1 and P2 are confused");
+    throw Standard_NullValue("FairCurve : P1 and P2 are confused");
   if (Height <= 0) 
-    Standard_NegativeValue::Raise("FairCurve : Height is not positive");
+    throw Standard_NegativeValue("FairCurve : Height is not positive");
 //
 //   Initialize by a straight line (2 poles)
 //
@@ -135,7 +135,7 @@ void FairCurve_Batten::SetP1(const gp_Pnt2d& P1)
 // ==================================================================
 {
   if (P1.IsEqual(NewP2, Precision::Confusion())) 
-    Standard_NullValue::Raise("FairCurve : P1 and P2 are confused");  
+    throw Standard_NullValue("FairCurve : P1 and P2 are confused");
   Angles(P1, NewP2);
   NewP1 = P1;
 }
@@ -145,7 +145,7 @@ void FairCurve_Batten::SetP2(const gp_Pnt2d& P2)
 // ==================================================================
 {
  if (NewP1.IsEqual(P2, Precision::Confusion())) 
-    Standard_NullValue::Raise("FairCurve : P1 and P2 are confused");
+    throw Standard_NullValue("FairCurve : P1 and P2 are confused");
   Angles(NewP1, P2);
   NewP2 = P2;
 }
index 722975a..239002d 100644 (file)
@@ -51,7 +51,7 @@ inline void FairCurve_Batten::SetAngle2(const Standard_Real Angle2)
  inline void FairCurve_Batten::SetHeight(const Standard_Real Height)
 {
   if (Height <= 0) 
-    Standard_NegativeValue::Raise("FairCurve : Height is no positive");  
+    throw Standard_NegativeValue("FairCurve : Height is no positive");
   NewHeight = Height;
 }
 
index 9718f7d..9eb5dfc 100644 (file)
@@ -98,8 +98,7 @@ FilletSurf_ErrorTypeStatus FilletSurf_Builder::StatusError() const
 Standard_Integer FilletSurf_Builder::NbSurface() const 
 {
   if (IsDone()!=FilletSurf_IsNotOk)  return myIntBuild.NbSurface();
-  StdFail_NotDone::Raise("FilletSurf_Builder::NbSurface");
-  return 0;
+  throw StdFail_NotDone("FilletSurf_Builder::NbSurface");
 }
 
 //=======================================================================
@@ -109,7 +108,7 @@ Standard_Integer FilletSurf_Builder::NbSurface() const
 
 const Handle(Geom_Surface)& FilletSurf_Builder::SurfaceFillet(const Standard_Integer Index) const 
 {
-  if ( (Index<1)||(Index>NbSurface())) Standard_OutOfRange::Raise("FilletSurf_Builder::SurfaceFillet");
+  if ( (Index<1)||(Index>NbSurface())) throw Standard_OutOfRange("FilletSurf_Builder::SurfaceFillet");
   return myIntBuild.SurfaceFillet(Index); 
 }
 
@@ -120,7 +119,7 @@ const Handle(Geom_Surface)& FilletSurf_Builder::SurfaceFillet(const Standard_Int
 Standard_Real  FilletSurf_Builder::TolApp3d(const Standard_Integer Index) const 
 {
   if ( (Index<1)||(Index>NbSurface())) 
-    Standard_OutOfRange::Raise("FilletSurf_Builder::TolApp3d");
+    throw Standard_OutOfRange("FilletSurf_Builder::TolApp3d");
   return myIntBuild.TolApp3d(Index);
 }
 
@@ -131,7 +130,7 @@ Standard_Real  FilletSurf_Builder::TolApp3d(const Standard_Integer Index) const
 const TopoDS_Face& FilletSurf_Builder::SupportFace1(const Standard_Integer Index) const
 {
   if ( (Index<1)||(Index>NbSurface())) 
-    Standard_OutOfRange::Raise("FilletSurf_Builder::SupportFace1");
+    throw Standard_OutOfRange("FilletSurf_Builder::SupportFace1");
   return myIntBuild.SupportFace1(Index); 
 }
 
@@ -142,7 +141,7 @@ const TopoDS_Face& FilletSurf_Builder::SupportFace1(const Standard_Integer Index
 const TopoDS_Face& FilletSurf_Builder::SupportFace2(const Standard_Integer Index) const 
 {
  if ( (Index<1)||(Index>NbSurface())) 
-   Standard_OutOfRange::Raise("FilletSurf_Builder::SupportFace2");
+   throw Standard_OutOfRange("FilletSurf_Builder::SupportFace2");
  return myIntBuild.SupportFace2(Index);
   
 }
@@ -154,7 +153,7 @@ const TopoDS_Face& FilletSurf_Builder::SupportFace2(const Standard_Integer Index
 const Handle(Geom_Curve)& FilletSurf_Builder::CurveOnFace1(const Standard_Integer Index) const 
 {
   if ( (Index<1)||(Index>NbSurface())) 
-    Standard_OutOfRange::Raise("FilletSurf_Builder::CurveOnFace1"); 
+    throw Standard_OutOfRange("FilletSurf_Builder::CurveOnFace1");
   return myIntBuild.CurveOnFace1(Index);
 }
 
@@ -165,7 +164,7 @@ const Handle(Geom_Curve)& FilletSurf_Builder::CurveOnFace1(const Standard_Intege
 const Handle(Geom_Curve)& FilletSurf_Builder::CurveOnFace2(const Standard_Integer Index) const 
 { 
   if ( (Index<1)||(Index>NbSurface())) 
-    Standard_OutOfRange::Raise("FilletSurf_Builder::CurveOnFace2"); 
+    throw Standard_OutOfRange("FilletSurf_Builder::CurveOnFace2");
   return myIntBuild.CurveOnFace2(Index);
 }
 
@@ -176,7 +175,7 @@ const Handle(Geom_Curve)& FilletSurf_Builder::CurveOnFace2(const Standard_Intege
 const Handle(Geom2d_Curve)& FilletSurf_Builder::PCurveOnFace1(const Standard_Integer Index) const 
 { 
   if ( (Index<1)||(Index>NbSurface())) 
-    Standard_OutOfRange::Raise( "FilletSurf_Builder::PCurveOnFace1"); 
+    throw Standard_OutOfRange( "FilletSurf_Builder::PCurveOnFace1");
   return myIntBuild.PCurveOnFace1(Index);
 }
 
@@ -187,7 +186,7 @@ const Handle(Geom2d_Curve)& FilletSurf_Builder::PCurveOnFace1(const Standard_Int
 const Handle(Geom2d_Curve)& FilletSurf_Builder::PCurve1OnFillet(const Standard_Integer Index) const 
 { 
   if ( (Index<1)||(Index>NbSurface())) 
-    Standard_OutOfRange::Raise("FilletSurf_Builder::PCurve1OnFillet");
+    throw Standard_OutOfRange("FilletSurf_Builder::PCurve1OnFillet");
   return myIntBuild.PCurve1OnFillet(Index);
 }
 
@@ -198,7 +197,7 @@ const Handle(Geom2d_Curve)& FilletSurf_Builder::PCurve1OnFillet(const Standard_I
 const Handle(Geom2d_Curve)& FilletSurf_Builder::PCurveOnFace2(const Standard_Integer Index) const 
 {
   if ( (Index<1)||(Index>NbSurface())) 
-    Standard_OutOfRange::Raise("FilletSurf_Builder::PCurveOnFace2");
+    throw Standard_OutOfRange("FilletSurf_Builder::PCurveOnFace2");
   return myIntBuild.PCurveOnFace2(Index);
 }
 
@@ -209,7 +208,7 @@ const Handle(Geom2d_Curve)& FilletSurf_Builder::PCurveOnFace2(const Standard_Int
 const Handle(Geom2d_Curve)& FilletSurf_Builder::PCurve2OnFillet(const Standard_Integer Index) const 
 {
   if ( (Index<1)||(Index>NbSurface())) 
-    Standard_OutOfRange::Raise("FilletSurf_Builder::PCurve2OnFillet");
+    throw Standard_OutOfRange("FilletSurf_Builder::PCurve2OnFillet");
   return myIntBuild.PCurve2OnFillet(Index);
 }
 
@@ -220,7 +219,7 @@ const Handle(Geom2d_Curve)& FilletSurf_Builder::PCurve2OnFillet(const Standard_I
 Standard_Real FilletSurf_Builder::FirstParameter() const
 {
   if (IsDone()==FilletSurf_IsNotOk) 
-    StdFail_NotDone::Raise("FilletSurf_Builder::FirstParameter");
+    throw StdFail_NotDone("FilletSurf_Builder::FirstParameter");
   return myIntBuild.FirstParameter();
 }
 
@@ -231,7 +230,7 @@ Standard_Real FilletSurf_Builder::FirstParameter() const
 Standard_Real FilletSurf_Builder::LastParameter() const
 {
   if (IsDone()==FilletSurf_IsNotOk) 
-    StdFail_NotDone::Raise("FilletSurf_Builder::LastParameter");
+    throw StdFail_NotDone("FilletSurf_Builder::LastParameter");
   return myIntBuild.LastParameter();
 }
 
@@ -248,7 +247,7 @@ Standard_Real FilletSurf_Builder::LastParameter() const
 FilletSurf_StatusType  FilletSurf_Builder::StartSectionStatus() const 
 {
   if (IsDone()==FilletSurf_IsNotOk)
-    StdFail_NotDone::Raise("FilletSurf_Builder::StartSectionStatus" );
+    throw StdFail_NotDone("FilletSurf_Builder::StartSectionStatus" );
   return  myIntBuild.StartSectionStatus();
 }
 
@@ -265,7 +264,7 @@ FilletSurf_StatusType  FilletSurf_Builder::StartSectionStatus() const
 FilletSurf_StatusType  FilletSurf_Builder::EndSectionStatus() const 
 {
   if (IsDone()==FilletSurf_IsNotOk) 
-    StdFail_NotDone::Raise("FilletSurf_Builder::StartSectionStatus");
+    throw StdFail_NotDone("FilletSurf_Builder::StartSectionStatus");
   return  myIntBuild.EndSectionStatus(); 
 }
 
@@ -291,9 +290,8 @@ void FilletSurf_Builder::Simulate()
 Standard_Integer FilletSurf_Builder::NbSection(const Standard_Integer IndexSurf) const 
 {
   if (IsDone()==FilletSurf_IsNotOk) 
-    StdFail_NotDone::Raise("FilletSurf_Builder::NbSection)");
-  else if ( (IndexSurf<1)||(IndexSurf>NbSurface())) Standard_OutOfRange::Raise
-    ("FilletSurf_Builder::NbSection");
+    throw StdFail_NotDone("FilletSurf_Builder::NbSection)");
+  else if ( (IndexSurf<1)||(IndexSurf>NbSurface())) throw Standard_OutOfRange("FilletSurf_Builder::NbSection");
   return myIntBuild.NbSection(IndexSurf);
 }
 
@@ -308,10 +306,10 @@ void FilletSurf_Builder::Section(const Standard_Integer IndexSurf,
                                 Handle(Geom_TrimmedCurve)& Circ) const 
 {
   if ((IndexSurf<1)||(IndexSurf>NbSurface())) 
-    Standard_OutOfRange::Raise("FilletSurf_Builder::Section NbSurface");
+    throw Standard_OutOfRange("FilletSurf_Builder::Section NbSurface");
 
   else if ((IndexSec<1)||(IndexSec>NbSection(IndexSurf))) 
-    Standard_OutOfRange::Raise("FilletSurf_Builder::Section NbSection");
+    throw Standard_OutOfRange("FilletSurf_Builder::Section NbSection");
 
   else myIntBuild.Section(IndexSurf, IndexSec,Circ);
 }
index 94ec7bf..3a61290 100644 (file)
@@ -325,12 +325,10 @@ Standard_Boolean
 {
   Handle(ChFiDS_SurfData) Data = SeqData(1);
   Handle(ChFiDS_FilSpine) fsp = Handle(ChFiDS_FilSpine)::DownCast(Spine);
-  if(fsp.IsNull()) Standard_ConstructionError::Raise
-    ("PerformSurf : this is not the spine of a fillet");
+  if(fsp.IsNull()) throw Standard_ConstructionError("PerformSurf : this is not the spine of a fillet");
   Handle(BRepBlend_Line) lin;
   TopAbs_Orientation Or = S1->ChangeSurface().Face().Orientation();
-  if(!fsp->IsConstant()) Standard_ConstructionError::Raise
-    ("PerformSurf : no variable radiuses");
+  if(!fsp->IsConstant()) throw Standard_ConstructionError("PerformSurf : no variable radiuses");
   // Standard_Boolean maybesingular; //pour scinder les Surfdata singulieres 
   
   BRepBlend_ConstRad Func(S1,S2,Guide);
@@ -370,7 +368,7 @@ Standard_Boolean
                          Standard_False, Data->ChangeVertexLastOnS2(), tolesp);
   }
   done = CompleteData(Data,Func,lin,S1,S2,Or,0,0,0,0);
-  if(!done)  Standard_Failure::Raise("PerformSurf : Failed approximation!");
+  if(!done)  throw Standard_Failure("PerformSurf : Failed approximation!");
 //  maybesingular = (Func.GetMinimalDistance()<=100*tolapp3d);
   Standard_Boolean ok = Standard_False;
   if(!Forward){
@@ -414,17 +412,17 @@ Standard_Boolean
 
 void FilletSurf_InternalBuilder::PerformSurf (ChFiDS_SequenceOfSurfData& , const Handle(ChFiDS_HElSpine)& , const Handle(ChFiDS_Spine)& , const Standard_Integer , const Handle(BRepAdaptor_HSurface)& , const Handle(Adaptor3d_TopolTool)& , const Handle(BRepAdaptor_HCurve2d)& , const Handle(BRepAdaptor_HSurface)& , const Handle(BRepAdaptor_HCurve2d)& , Standard_Boolean& , const Handle(BRepAdaptor_HSurface)& , const Handle(Adaptor3d_TopolTool)& , const TopAbs_Orientation , const Standard_Real , const Standard_Real , const Standard_Real , Standard_Real& , Standard_Real& , const Standard_Boolean , const Standard_Boolean , const Standard_Boolean , const Standard_Boolean , const Standard_Boolean , const Standard_Boolean , const math_Vector& )
 {
Standard_DomainError::Raise("BlendFunc_CSConstRad::Section : Not implemented");
throw Standard_DomainError("BlendFunc_CSConstRad::Section : Not implemented");
 }
 
 void FilletSurf_InternalBuilder::PerformSurf (ChFiDS_SequenceOfSurfData& , const Handle(ChFiDS_HElSpine)& , const Handle(ChFiDS_Spine)& , const Standard_Integer , const Handle(BRepAdaptor_HSurface)& , const Handle(Adaptor3d_TopolTool)& , const TopAbs_Orientation , const Handle(BRepAdaptor_HSurface)& , const Handle(Adaptor3d_TopolTool)& , const Handle(BRepAdaptor_HCurve2d)& , const Handle(BRepAdaptor_HSurface)& , const Handle(BRepAdaptor_HCurve2d)& , Standard_Boolean& , const Standard_Real , const Standard_Real , const Standard_Real , Standard_Real& , Standard_Real& , const Standard_Boolean , const Standard_Boolean , const Standard_Boolean , const Standard_Boolean , const Standard_Boolean , const Standard_Boolean , const math_Vector& )
 {
Standard_DomainError::Raise("BlendFunc_CSConstRad::Section : Not implemented");
throw Standard_DomainError("BlendFunc_CSConstRad::Section : Not implemented");
 }
 
 void FilletSurf_InternalBuilder::PerformSurf (ChFiDS_SequenceOfSurfData& , const Handle(ChFiDS_HElSpine)& , const Handle(ChFiDS_Spine)& , const Standard_Integer , const Handle(BRepAdaptor_HSurface)& , const Handle(Adaptor3d_TopolTool)& , const Handle(BRepAdaptor_HCurve2d)& , const Handle(BRepAdaptor_HSurface)& , const Handle(BRepAdaptor_HCurve2d)& , Standard_Boolean& , const TopAbs_Orientation , const Handle(BRepAdaptor_HSurface)& , const Handle(Adaptor3d_TopolTool)& , const Handle(BRepAdaptor_HCurve2d)& , const Handle(BRepAdaptor_HSurface)& , const Handle(BRepAdaptor_HCurve2d)& , Standard_Boolean& , const TopAbs_Orientation , const Standard_Real , const Standard_Real , const Standard_Real , Standard_Real& , Standard_Real& , const Standard_Boolean , const Standard_Boolean , const Standard_Boolean , const Standard_Boolean , const Standard_Boolean , const Standard_Boolean , const Standard_Boolean , const math_Vector& )
 {
Standard_DomainError::Raise("BlendFunc_CSConstRad::Section : Not implemented");
throw Standard_DomainError("BlendFunc_CSConstRad::Section : Not implemented");
 }
 
 Standard_Boolean  FilletSurf_InternalBuilder::Done() const
index 31b3728..cca19ca 100644 (file)
@@ -47,18 +47,6 @@ GC_MakeConicalSurface::GC_MakeConicalSurface(const gp_Cone& C)
   TheCone = new Geom_ConicalSurface(C);
 }
 
-GC_MakeConicalSurface::GC_MakeConicalSurface(const gp_Cone& , //C,
-                                              const gp_Pnt&  ) //P )
-{
-  Standard_NotImplemented::Raise("GC_MakeConicalSurface");
-}
-
-GC_MakeConicalSurface::GC_MakeConicalSurface(const gp_Cone& , //C,
-                                              const Standard_Real) // Dist )
-{
-  Standard_NotImplemented::Raise("GC_MakeConicalSurface");
-}
-
 //=========================================================================
 //   Creation of a cone by four points.                                +
 //   two first give the axis.                                     +
@@ -79,22 +67,6 @@ GC_MakeConicalSurface::GC_MakeConicalSurface(const gp_Pnt& P1 ,
 }
 
 
-GC_MakeConicalSurface::GC_MakeConicalSurface(const gp_Ax1& , //Axis,
-                                              const gp_Pnt& , //P1  ,
-                                              const gp_Pnt& ) //P2   )
-{
-  Standard_NotImplemented::Raise("GC_MakeConicalSurface");
-}
-
-
-GC_MakeConicalSurface::GC_MakeConicalSurface(const gp_Lin& , //Axis,
-                                              const gp_Pnt& , //P1  ,
-                                              const gp_Pnt& ) //P2   )
-{
-  Standard_NotImplemented::Raise("GC_MakeConicalSurface");
-}
-
-
 //=========================================================================
 //=========================================================================
 
index db5c35d..b028c20 100644 (file)
@@ -86,15 +86,6 @@ public:
   //! Creates a ConicalSurface from a non persistent Cone from package gp.
   Standard_EXPORT GC_MakeConicalSurface(const gp_Cone& C);
   
-  //! Make a ConicalSurface from Geom <TheCone> parallel to another
-  //! ConicalSurface <Cone> and passing through a Pnt <Point>.
-  Standard_EXPORT GC_MakeConicalSurface(const gp_Cone& Cone, const gp_Pnt& Point);
-  
-  //! Make a ConicalSurface from Geom <TheCone> parallel to another
-  //! ConicalSurface <Cone> at the distance <Dist> which can
-  //! be greater or lower than zero.
-  Standard_EXPORT GC_MakeConicalSurface(const gp_Cone& Cone, const Standard_Real Dist);
-  
   //! Make a ConicalSurface from Geom <TheCone> passing through 3
   //! Pnt <P1>,<P2>,<P3>.
   //! Its axis is <P1P2> and the radius of its base is
@@ -106,12 +97,6 @@ public:
   //! <P3P4> is colinear to <P1P2>.
   Standard_EXPORT GC_MakeConicalSurface(const gp_Pnt& P1, const gp_Pnt& P2, const gp_Pnt& P3, const gp_Pnt& P4);
   
-  //! Make a ConicalSurface by its axis <Axis> and and two points.
-  Standard_EXPORT GC_MakeConicalSurface(const gp_Ax1& Axis, const gp_Pnt& P1, const gp_Pnt& P2);
-  
-  //! Make a ConicalSurface by its axis <Axis> and and two points.
-  Standard_EXPORT GC_MakeConicalSurface(const gp_Lin& Axis, const gp_Pnt& P1, const gp_Pnt& P2);
-  
   //! Make a ConicalSurface with two points and two radius.
   //! The axis of the solution is the line passing through
   //! <P1> and <P2>.
index 2c6e6d4..9034c5f 100644 (file)
 #include <StdFail_NotDone.hxx>
 #include <TColgp_Array1OfPnt.hxx>
 
-GC_MakePlane::GC_MakePlane(const gp_Ax2& ) //A2)
-{
-  Standard_NotImplemented::Raise("GC_MakePlane");
-}
-
 GC_MakePlane::GC_MakePlane(const gp_Pln& Pl)
 {
   TheError = gce_Done;
index 87644cb..617f96d 100644 (file)
@@ -49,17 +49,6 @@ public:
 
   DEFINE_STANDARD_ALLOC
 
-  
-
-  //! Creates a plane located in 3D space with an axis placement
-  //! two axis.  The "ZDirection" of "A2" is the direction normal
-  //! to the plane.  The "Location" point of "A2" is the origin of
-  //! the plane. The "XDirection" and "YDirection" of "A2" define
-  //! the directions of the U isoparametric and V isoparametric
-  //! curves.
-  Standard_EXPORT GC_MakePlane(const gp_Ax2& A2);
-  
-
   //! Creates a plane from a non persistent plane from package gp.
   Standard_EXPORT GC_MakePlane(const gp_Pln& Pl);
   
index 350300d..cdcf287 100644 (file)
@@ -71,20 +71,6 @@ GC_MakeTrimmedCylinder::GC_MakeTrimmedCylinder(const gp_Ax1&       A1     ,
   }
 }
 
-GC_MakeTrimmedCylinder::GC_MakeTrimmedCylinder(const gp_Cylinder& , // Cyl,
-                                                const gp_Pnt&      , // P,
-                                                const Standard_Real )//Height)
-{
-  Standard_NotImplemented::Raise("GC_MakeTrimmedCylinder");
-}
-
-GC_MakeTrimmedCylinder::GC_MakeTrimmedCylinder(const gp_Cylinder& , // Cyl,
-                                                const gp_Pnt&      , // P1,
-                                                const gp_Pnt&      ) // P2)
-{
-  Standard_NotImplemented::Raise("GC_MakeTrimmedCylinder");
-}
-
 const Handle(Geom_RectangularTrimmedSurface)& GC_MakeTrimmedCylinder::
        Value() const
 { 
index 50811ea..308de05 100644 (file)
@@ -69,26 +69,6 @@ public:
   //! In the other case it has the opposite orientation.
   Standard_EXPORT GC_MakeTrimmedCylinder(const gp_Ax1& A1, const Standard_Real Radius, const Standard_Real Height);
   
-  //! Make a RectangularTrimmedSurface <Cylinder> from gp by
-  //! a cylinder from gp.
-  //! It is trimmed by the point <P> and the heigh <Heigh>.
-  //! <Height> can be greater than zero or lower than zero.
-  //! in the first case the limit section is in the side of
-  //! the positives V paramters of <Cyl> and in the other
-  //! side if <Heigh> is lower than zero.
-  Standard_EXPORT GC_MakeTrimmedCylinder(const gp_Cylinder& Cyl, const gp_Pnt& P, const Standard_Real Height);
-  
-  //! Make a RectangularTrimmedSurface <Cylinder> from gp by
-  //! a cylinder from gp.
-  //! It is trimmed by the two points <P1> and <P2>.
-  //! Warning
-  //! If an error occurs (that is, when IsDone returns
-  //! false), the Status function returns:
-  //! -   gce_NegativeRadius if Radius is less than 0.0, or
-  //! -   gce_ConfusedPoints if the points P1 and P2 are coincident.
-  //! -   gce_ColinearPoints if the points P1, P2 and P3 are collinear.
-  Standard_EXPORT GC_MakeTrimmedCylinder(const gp_Cylinder& Cyl, const gp_Pnt& P1, const gp_Pnt& P2);
-  
   //! Returns the constructed trimmed cylinder.
   //! Exceptions
   //! StdFail_NotDone if no trimmed cylinder is constructed.
index cce1214..231d3b3 100644 (file)
@@ -398,7 +398,7 @@ GCPnts_AbscissaPoint::GCPnts_AbscissaPoint
 {
   Standard_Real L = GCPnts_AbscissaPoint::Length(C);
   if (L < Precision::Confusion()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   } 
   Standard_Real Abscis = Abscissa;
   Standard_Real UU0 = U0;
@@ -423,7 +423,7 @@ GCPnts_AbscissaPoint::GCPnts_AbscissaPoint
 /*  if (L < Precision::Confusion()) {
     cout<<"FirstParameter = "<<C.FirstParameter()<<endl;
     cout<<"LastParameter = "<<C.LastParameter()<<endl;
-    Standard_ConstructionError::Raise("GCPnts_AbscissaPoint::GCPnts_AbscissaPoint");
+    throw Standard_ConstructionError("GCPnts_AbscissaPoint::GCPnts_AbscissaPoint");
   } 
 */
   Standard_Real Abscis = Abscissa;
index 32c826d..9f71597 100644 (file)
@@ -40,7 +40,7 @@ GProp_GProps::GProp_GProps (const gp_Pnt& SystemLocation) :
 
 
 void GProp_GProps::Add (const GProp_GProps& Item, const Standard_Real Density) {
-  if (Density <= gp::Resolution())  Standard_DomainError::Raise();
+  if (Density <= gp::Resolution())  throw Standard_DomainError();
   if (loc.Distance (Item.loc) <= gp::Resolution ()) {
     gp_XYZ GXYZ = (Item.g.XYZ()).Multiplied (Item.dim * Density);
     g.SetXYZ (g.XYZ().Multiplied (dim));
index c318be8..ee4a20a 100644 (file)
@@ -130,22 +130,22 @@ Standard_Boolean GProp_PEquation::IsSpace() const {
 }
 
 gp_Pln  GProp_PEquation::Plane() const {
-  if (!IsPlanar()) Standard_NoSuchObject::Raise();
+  if (!IsPlanar()) throw Standard_NoSuchObject();
   return gp_Pln(g,v1);
 }
 gp_Lin  GProp_PEquation::Line() const {
-  if (!IsLinear()) Standard_NoSuchObject::Raise();
+  if (!IsLinear()) throw Standard_NoSuchObject();
   return gp_Lin(g,gp_Dir(v1));  
 }
 
 gp_Pnt  GProp_PEquation::Point() const {
-  if (!IsPoint()) Standard_NoSuchObject::Raise();
+  if (!IsPoint()) throw Standard_NoSuchObject();
   return g;
 }
 
 void GProp_PEquation::Box(gp_Pnt& P  , gp_Vec& V1,
                             gp_Vec& V2 , gp_Vec& V3) const {
-  if (!IsSpace()) Standard_NoSuchObject::Raise();
+  if (!IsSpace()) throw Standard_NoSuchObject();
   P = g;
   V1 = v1;
   V2 = v2;
index 86a7952..a1d0a0f 100644 (file)
@@ -72,7 +72,7 @@ void GProp_PGProps::AddPoint (const Pnt& P)
 
 void GProp_PGProps::AddPoint (const gp_Pnt& P, const Standard_Real Density)
 {
-  if (Density <= gp::Resolution())  Standard_DomainError::Raise();
+  if (Density <= gp::Resolution())  throw Standard_DomainError();
   Standard_Real Xp, Yp, Zp;
   P.Coord (Xp, Yp, Zp);
   Standard_Real Ixy = - Xp * Yp;
@@ -117,12 +117,12 @@ GProp_PGProps::GProp_PGProps (const Array2OfPnt& Pnts)
 
 GProp_PGProps::GProp_PGProps (const Array1OfPnt& Pnts,const Array1OfReal& Density)
 {
-  if (Pnts.Length() != Density.Length())  Standard_DomainError::Raise();
+  if (Pnts.Length() != Density.Length())  throw Standard_DomainError();
   Standard_Integer ip = Pnts.Lower();
   Standard_Integer id = Density.Lower();
   while (id <= Pnts.Upper()) {
     Standard_Real D = Density (id);
-    if (D <= gp::Resolution()) Standard_DomainError::Raise();
+    if (D <= gp::Resolution()) throw Standard_DomainError();
     AddPoint(Pnts (ip),D); 
     ip++;  id++;
   }      
@@ -130,7 +130,7 @@ GProp_PGProps::GProp_PGProps (const Array1OfPnt& Pnts,const Array1OfReal& Densit
 
 GProp_PGProps::GProp_PGProps (const Array2OfPnt& Pnts,const Array2OfReal& Density)
 {
-  if (Pnts.ColLength() != Density.ColLength() || Pnts.RowLength() != Density.RowLength()) Standard_DomainError::Raise();
+  if (Pnts.ColLength() != Density.ColLength() || Pnts.RowLength() != Density.RowLength()) throw Standard_DomainError();
   Standard_Integer ip = Pnts.LowerRow();
   Standard_Integer id = Density.LowerRow();
   Standard_Integer jp = Pnts.LowerCol();
@@ -138,7 +138,7 @@ GProp_PGProps::GProp_PGProps (const Array2OfPnt& Pnts,const Array2OfReal& Densit
   while (jp <= Pnts.UpperCol()) {
     while (ip <= Pnts.UpperRow()) {
       Standard_Real D = Density (id, jd);
-      if (D <= gp::Resolution())  Standard_DomainError::Raise();
+      if (D <= gp::Resolution())  throw Standard_DomainError();
       AddPoint(Pnts (ip, jp),D); 
       ip++; id++;
     }      
@@ -153,7 +153,7 @@ void GProp_PGProps::Barycentre(const Array1OfPnt&  Pnts,
                               Standard_Real&      Mass, 
                               Pnt&                G)
 {
-  if (Pnts.Length() != Density.Length())  Standard_DimensionError::Raise();
+  if (Pnts.Length() != Density.Length())  throw Standard_DimensionError();
   Standard_Integer ip = Pnts.Lower();
   Standard_Integer id = Density.Lower();
   Mass = Density (id);
@@ -177,7 +177,7 @@ void GProp_PGProps::Barycentre(const Array2OfPnt&  Pnts,
                               Standard_Real&      Mass,
                               Pnt&                G)
 {
-  if (Pnts.RowLength() != Density.RowLength() || Pnts.ColLength() != Density.ColLength()) Standard_DimensionError::Raise();
+  if (Pnts.RowLength() != Density.RowLength() || Pnts.ColLength() != Density.ColLength()) throw Standard_DimensionError();
   Standard_Integer ip = Pnts.LowerRow();
   Standard_Integer id = Density.LowerRow();
   Standard_Integer jp = Pnts.LowerCol();
index 3822460..6aa342e 100644 (file)
@@ -30,7 +30,7 @@ DEFINE_STANDARD_HANDLE(GProp_UndefinedAxis, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_GProp_UndefinedAxis
   #define GProp_UndefinedAxis_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) GProp_UndefinedAxis::Raise(MESSAGE);
+  if (CONDITION) throw GProp_UndefinedAxis(MESSAGE);
 #else
   #define GProp_UndefinedAxis_Raise_if(CONDITION, MESSAGE)
 #endif
index 4987502..abf9ab6 100644 (file)
@@ -76,7 +76,7 @@ GccAna_Circ2d2TanOn::
        Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
       !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
        Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-   GccEnt_BadQualifier::Raise();
+   throw GccEnt_BadQualifier();
      return;
    }
   gp_Circ2d C1 = Qualified1.Qualified();
@@ -346,8 +346,8 @@ void GccAna_Circ2d2TanOn::
                       GccEnt_Position& Qualif1 ,
                       GccEnt_Position& Qualif2 ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      Qualif1 = qualifier1(Index);
      Qualif2 = qualifier2(Index);
@@ -359,15 +359,15 @@ void GccAna_Circ2d2TanOn::
                     Standard_Real&      ParSol ,
                     Standard_Real&      ParArg ,
                     gp_Pnt2d&  PntSol ) const{
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      if (TheSame1(Index) == 0) {
        ParSol = par1sol(Index);
        ParArg = pararg1(Index);
        PntSol = gp_Pnt2d(pnttg1sol(Index));
      }
-     else { StdFail_NotDone::Raise(); }
+     else { throw StdFail_NotDone(); }
    }
  }
 
@@ -376,15 +376,15 @@ void GccAna_Circ2d2TanOn::
                     Standard_Real&      ParSol ,
                     Standard_Real&      ParArg ,
                     gp_Pnt2d&  PntSol ) const{
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      if (TheSame2(Index) == 0) {
        ParSol = par2sol(Index);
        ParArg = pararg2(Index);
        PntSol = gp_Pnt2d(pnttg2sol(Index));
      }
-     else { StdFail_NotDone::Raise(); }
+     else { throw StdFail_NotDone(); }
    }
  }
 
@@ -392,8 +392,8 @@ void GccAna_Circ2d2TanOn::
    CenterOn3 (const Standard_Integer    Index  ,
                     Standard_Real&      ParArg ,
                     gp_Pnt2d&  PntSol ) const{
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      ParArg = parcen3(Index);
      PntSol = pnttg1sol(Index);
@@ -403,8 +403,8 @@ void GccAna_Circ2d2TanOn::
 Standard_Boolean GccAna_Circ2d2TanOn::
    IsTheSame1 (const Standard_Integer Index) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
 
   if (TheSame1(Index) == 0) { return Standard_False; }
   return Standard_True;
@@ -413,8 +413,8 @@ Standard_Boolean GccAna_Circ2d2TanOn::
 Standard_Boolean GccAna_Circ2d2TanOn::
    IsTheSame2 (const Standard_Integer Index) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
 
   if (TheSame2(Index) == 0) { return Standard_False; }
   return Standard_True;
index e014c0f..1b38e0c 100644 (file)
@@ -75,7 +75,7 @@ GccAna_Circ2d2TanOn::
         Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
        !(Qualified2.IsEnclosed() ||
         Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
    Standard_Real Tol = Abs(Tolerance);
@@ -110,7 +110,7 @@ GccAna_Circ2d2TanOn::
    }
    else if (Qualified1.IsUnqualified()) { ok = Standard_True; }
    else { 
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
    if (ok) {
@@ -124,7 +124,7 @@ GccAna_Circ2d2TanOn::
      }
      else if (Qualified2.IsUnqualified()) { WellDone = Standard_False; }
      else { 
-       GccEnt_BadQualifier::Raise();
+       throw GccEnt_BadQualifier();
        return;
      }
    }
index 225b00a..479ff66 100644 (file)
@@ -75,7 +75,7 @@ GccAna_Circ2d2TanOn::
   NbrSol = 0;
   if (!(Qualified1.IsEnclosed() ||
        Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-  GccEnt_BadQualifier::Raise();
+  throw GccEnt_BadQualifier();
     return;
   }
   Standard_Real Tol = Abs(Tolerance);
index a10b7cc..e731cc3 100644 (file)
@@ -61,7 +61,7 @@ GccAna_Circ2d2TanOn::
        Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
       !(Qualified2.IsEnclosed() ||
        Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-  GccEnt_BadQualifier::Raise();
+  throw GccEnt_BadQualifier();
     return;
   }
 
index ca236cb..eea687f 100644 (file)
@@ -77,7 +77,7 @@ GccAna_Circ2d2TanOn::
   NbrSol = 0;
   if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
        Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-    GccEnt_BadQualifier::Raise();
+    throw GccEnt_BadQualifier();
     return;
   }
   TColStd_Array1OfReal Radius(1,2);
index eb229d1..ab9edd8 100644 (file)
@@ -79,7 +79,7 @@ GccAna_Circ2d2TanOn::
   NbrSol = 0;
   if (!(Qualified1.IsEnclosed() ||
        Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-    GccEnt_BadQualifier::Raise();
+    throw GccEnt_BadQualifier();
     return;
   }
   Standard_Real Tol = Abs(Tolerance);
index 74acf48..b0dc38b 100644 (file)
@@ -76,7 +76,7 @@ GccAna_Circ2d2TanOn::
        Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
       !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
        Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-    GccEnt_BadQualifier::Raise();
+    throw GccEnt_BadQualifier();
     return;
   }
   Standard_Real Tol= Abs(Tolerance);
index 47a7c15..4bf679a 100644 (file)
@@ -62,7 +62,7 @@ GccAna_Circ2d2TanOn::
        Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
       !(Qualified2.IsEnclosed() ||
        Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-    GccEnt_BadQualifier::Raise();
+    throw GccEnt_BadQualifier();
     return;
   }
   Standard_Real Radius=0;
index 9f07750..207edb3 100644 (file)
@@ -71,7 +71,7 @@ GccAna_Circ2d2TanOn::
   NbrSol = 0;
   if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
        Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-    GccEnt_BadQualifier::Raise();
+    throw GccEnt_BadQualifier();
     return;
   }
   Standard_Real Tol = Abs(Tolerance);
index 944f4a6..58cfae8 100644 (file)
@@ -61,7 +61,7 @@ GccAna_Circ2d2TanOn::
        Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
       !(Qualified2.IsEnclosed() ||
        Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-    GccEnt_BadQualifier::Raise();
+    throw GccEnt_BadQualifier();
     return;
   }
   gp_Lin2d L1(Qualified1.Qualified());
index 818c627..d283037 100644 (file)
@@ -68,7 +68,7 @@ GccAna_Circ2d2TanRad::
         Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
        !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
         Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
    Standard_Boolean invers = Standard_False;
@@ -87,7 +87,7 @@ GccAna_Circ2d2TanRad::
    gp_Pnt2d center1(C1.Location());
    gp_Pnt2d center2(C2.Location());
    gp_Pnt2d center3;
-   if (Radius < 0.0) { Standard_NegativeValue::Raise(); }
+   if (Radius < 0.0) { throw Standard_NegativeValue(); }
    else if ( C(2).Location().IsEqual(C(1).Location(),Precision::Confusion())){
      WellDone = Standard_True;
    }
@@ -674,8 +674,8 @@ Standard_Integer GccAna_Circ2d2TanRad::
 gp_Circ2d GccAna_Circ2d2TanRad::
    ThisSolution (const Standard_Integer Index) const 
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   return cirsol(Index);
 }
 
@@ -684,8 +684,8 @@ void GccAna_Circ2d2TanRad::
                       GccEnt_Position& Qualif1 ,
                       GccEnt_Position& Qualif2 ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   
   Qualif1 = qualifier1(Index);
   Qualif2 = qualifier2(Index);
@@ -696,15 +696,15 @@ void GccAna_Circ2d2TanRad::
               Standard_Real& ParSol,
               Standard_Real& ParArg,
               gp_Pnt2d& PntSol) const{
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      if (TheSame1(Index) == 0) {
        ParSol = par1sol(Index);
        ParArg = pararg1(Index);
        PntSol = gp_Pnt2d(pnttg1sol(Index));
      }
-     else { StdFail_NotDone::Raise(); }
+     else { throw StdFail_NotDone(); }
    }
  }
 
@@ -713,23 +713,23 @@ void GccAna_Circ2d2TanRad::
               Standard_Real& ParSol,
               Standard_Real& ParArg,
               gp_Pnt2d& PntSol) const{
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      if (TheSame2(Index) == 0) {
        ParSol = par2sol(Index);
        ParArg = pararg2(Index);
        PntSol = gp_Pnt2d(pnttg2sol(Index));
      }
-     else { StdFail_NotDone::Raise(); }
+     else { throw StdFail_NotDone(); }
    }
  }
 
 Standard_Boolean GccAna_Circ2d2TanRad::
    IsTheSame1 (const Standard_Integer Index) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
 
   if (TheSame1(Index) == 0) { return Standard_False; }
   
@@ -739,8 +739,8 @@ Standard_Boolean GccAna_Circ2d2TanRad::
 Standard_Boolean GccAna_Circ2d2TanRad::
    IsTheSame2 (const Standard_Integer Index) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   
   if (TheSame2(Index) == 0) { return Standard_False; }
   return Standard_True; 
index aa2a651..6dc567e 100644 (file)
@@ -69,7 +69,7 @@ GccAna_Circ2d2TanRad::
        Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
       !(Qualified2.IsEnclosed() || Qualified2.IsOutside() || 
        Qualified2.IsUnqualified())) {
-    GccEnt_BadQualifier::Raise();
+    throw GccEnt_BadQualifier();
     return;
   }
   Standard_Integer i ;
@@ -96,7 +96,7 @@ GccAna_Circ2d2TanRad::
   Standard_Real dist = Radius*2.0 + R1;
   Standard_Real distance = L2.Distance(center1);
   
-  if (Radius < 0.0) { Standard_NegativeValue::Raise(); }
+  if (Radius < 0.0) { throw Standard_NegativeValue(); }
   else {
     if ( distance-dist >Tol) { WellDone = Standard_True; }
     else if (Qualified1.IsEnclosed()) {
index bd78c29..c881049 100644 (file)
@@ -67,7 +67,7 @@ GccAna_Circ2d2TanRad::
   WellDone = Standard_False;
   if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
        Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-    GccEnt_BadQualifier::Raise();
+    throw GccEnt_BadQualifier();
     return;
   }
   Standard_Integer i ;
@@ -85,7 +85,7 @@ GccAna_Circ2d2TanRad::
   Standard_Real dispc1 = C1.Distance(Point2);
   gp_Dir2d dir1(Point2.XY()-(C1.Location().XY()));
   gp_Pnt2d center1(C1.Location());
-  if (Radius < 0.0) { Standard_NegativeValue::Raise(); }
+  if (Radius < 0.0) { throw Standard_NegativeValue(); }
   else {
     if ( dispc1-Radius*2.0 > Tol) { WellDone = Standard_True; }
     else if (Qualified1.IsEnclosed()) {
index 101df4c..c27f1ad 100644 (file)
@@ -70,7 +70,7 @@ GccAna_Circ2d2TanRad::
   WellDone = Standard_False;
   if (!(Qualified1.IsEnclosed() || Qualified1.IsOutside() || 
        Qualified1.IsUnqualified())) {
-    GccEnt_BadQualifier::Raise();
+    throw GccEnt_BadQualifier();
     return;
   }
   Standard_Integer nbsol = 0;
@@ -87,7 +87,7 @@ GccAna_Circ2d2TanRad::
   Standard_Real cxloc = Point2.X();
   Standard_Real cyloc = Point2.Y();
 
-  if (Radius < 0.0) { Standard_NegativeValue::Raise(); }
+  if (Radius < 0.0) { throw Standard_NegativeValue(); }
 
   else {
     if ( displ1-Radius*2.0 > Tol) { WellDone = Standard_True; }
index 99f812d..093b9db 100644 (file)
@@ -73,7 +73,7 @@ GccAna_Circ2d2TanRad::
        Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
       !(Qualified2.IsEnclosed() ||
        Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-    GccEnt_BadQualifier::Raise();
+    throw GccEnt_BadQualifier();
     return;
   }
   gp_Lin2d L1 = Qualified1.Qualified();
@@ -90,7 +90,7 @@ GccAna_Circ2d2TanRad::
   gp_Pnt2d origin2(lx2loc,ly2loc);
   gp_Dir2d normL1(x1dir,y1dir);
   gp_Dir2d normL2(x2dir,y2dir);
-  if (Radius < 0.0) { Standard_NegativeValue::Raise(); }
+  if (Radius < 0.0) { throw Standard_NegativeValue(); }
   else {
     if (L1.Direction().IsParallel(L2.Direction(),Precision::Angular())) { 
       WellDone = Standard_True;
index ae3556c..7dd0c90 100644 (file)
@@ -58,7 +58,7 @@ GccAna_Circ2d2TanRad::
   Standard_Real Tol = Abs(Tolerance);
   NbrSol = 0;
   WellDone = Standard_False;
-  if (Radius < 0.0) { Standard_NegativeValue::Raise(); }
+  if (Radius < 0.0) { throw Standard_NegativeValue(); }
   else {
     if (Point1.Distance(Point2)-Radius*2.0 > Tol) { WellDone = Standard_True; }
     else {
index 29e0de3..53382a3 100644 (file)
@@ -77,7 +77,7 @@ GccAna_Circ2d3Tan::
        Qualified2.IsOutside() || Qualified2.IsUnqualified()) ||
       !(Qualified3.IsEnclosed() || Qualified3.IsEnclosing() || 
        Qualified3.IsOutside() || Qualified3.IsUnqualified())) {
-    GccEnt_BadQualifier::Raise();
+    throw GccEnt_BadQualifier();
       return;
     }
   
@@ -808,10 +808,10 @@ gp_Circ2d GccAna_Circ2d3Tan::
    ThisSolution (const Standard_Integer Index) const 
 {
   if (!WellDone)
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   
   if (Index <= 0 ||Index > NbrSol)
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   
   return cirsol(Index); 
 }
@@ -822,8 +822,8 @@ void GccAna_Circ2d3Tan::
                       GccEnt_Position& Qualif2 ,
                       GccEnt_Position& Qualif3 ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      Qualif1 = qualifier1(Index);
      Qualif2 = qualifier2(Index);
@@ -837,10 +837,10 @@ void GccAna_Circ2d3Tan::
               Standard_Real& ParArg,
               gp_Pnt2d& PntSol) const {
    if (!WellDone) {
-     StdFail_NotDone::Raise();
+     throw StdFail_NotDone();
    }
    else if (Index <= 0 ||Index > NbrSol) {
-     Standard_OutOfRange::Raise();
+     throw Standard_OutOfRange();
    }
    else {
      if (TheSame1(Index) == 0) {
@@ -848,7 +848,7 @@ void GccAna_Circ2d3Tan::
        ParArg = pararg1(Index);
        PntSol = gp_Pnt2d(pnttg1sol(Index));
      }
-     else { StdFail_NotDone::Raise(); }
+     else { throw StdFail_NotDone(); }
    }
  }
 
@@ -858,10 +858,10 @@ void GccAna_Circ2d3Tan::
               Standard_Real& ParArg,
               gp_Pnt2d& PntSol) const{
    if (!WellDone) {
-     StdFail_NotDone::Raise();
+     throw StdFail_NotDone();
    }
    else if (Index <= 0 ||Index > NbrSol) {
-     Standard_OutOfRange::Raise();
+     throw Standard_OutOfRange();
    }
    else {
      if (TheSame2(Index) == 0) {
@@ -869,7 +869,7 @@ void GccAna_Circ2d3Tan::
        ParArg = pararg2(Index);
        PntSol = gp_Pnt2d(pnttg2sol(Index));
      }
-     else { StdFail_NotDone::Raise(); }
+     else { throw StdFail_NotDone(); }
    }
  }
 
@@ -879,10 +879,10 @@ void GccAna_Circ2d3Tan::
               Standard_Real& ParArg,
               gp_Pnt2d& PntSol) const{
    if (!WellDone) {
-     StdFail_NotDone::Raise();
+     throw StdFail_NotDone();
    }
    else if (Index <= 0 ||Index > NbrSol) {
-     Standard_OutOfRange::Raise();
+     throw Standard_OutOfRange();
    }
    else {
      if (TheSame3(Index) == 0) {
@@ -890,7 +890,7 @@ void GccAna_Circ2d3Tan::
        ParArg = pararg3(Index);
        PntSol = gp_Pnt2d(pnttg3sol(Index));
      }
-     else { StdFail_NotDone::Raise(); }
+     else { throw StdFail_NotDone(); }
    }
  }
 
@@ -898,10 +898,10 @@ Standard_Boolean GccAna_Circ2d3Tan::
    IsTheSame1 (const Standard_Integer Index) const
 {
   if (!WellDone)
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   
   if (Index <= 0 ||Index > NbrSol)
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   
   if (TheSame1(Index) == 0)
     return Standard_False;
@@ -913,10 +913,10 @@ Standard_Boolean GccAna_Circ2d3Tan::
    IsTheSame2 (const Standard_Integer Index) const
 {
   if (!WellDone)
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
 
   if (Index <= 0 ||Index > NbrSol)
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
 
   if (TheSame2(Index) == 0)
     return Standard_False;
@@ -928,10 +928,10 @@ Standard_Boolean GccAna_Circ2d3Tan::
    IsTheSame3 (const Standard_Integer Index) const
 {
   if (!WellDone)
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   
   if (Index <= 0 ||Index > NbrSol)
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
 
   if (TheSame3(Index) == 0) 
     return Standard_False;
index 7967eca..21b29bb 100644 (file)
@@ -75,7 +75,7 @@ GccAna_Circ2d3Tan::
        Qualified2.IsOutside() || Qualified2.IsUnqualified()) ||
       !(Qualified3.IsEnclosed() || 
        Qualified3.IsOutside() || Qualified3.IsUnqualified())) {
-    GccEnt_BadQualifier::Raise();
+    throw GccEnt_BadQualifier();
     return;
   }
 
index 61b92b3..289fb31 100644 (file)
@@ -76,7 +76,7 @@ pararg3(1,8)
         Qualified2.IsOutside() || Qualified2.IsUnqualified()) ||
        !(Qualified3.IsEnclosed() ||
         Qualified3.IsOutside() || Qualified3.IsUnqualified())) {
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
 
index 82a92db..e1ad96d 100644 (file)
@@ -79,7 +79,7 @@ GccAna_Circ2d3Tan::
         Qualified2.IsOutside() || Qualified2.IsUnqualified()) ||
        !(Qualified3.IsEnclosed() ||
         Qualified3.IsOutside() || Qualified3.IsUnqualified())) {
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
 
index fb79f82..e1d936c 100644 (file)
@@ -78,7 +78,7 @@ GccAna_Circ2d3Tan::
         Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
        !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
         Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
 
index 8053294..03f444d 100644 (file)
@@ -75,7 +75,7 @@ GccAna_Circ2d3Tan::
         Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
        !(Qualified2.IsEnclosed() ||
         Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
 
index 7657d2c..005760b 100644 (file)
@@ -68,7 +68,7 @@ GccAna_Circ2d3Tan::
         Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
        !(Qualified2.IsEnclosed() ||
         Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
 
index b62dd13..21c87b5 100644 (file)
@@ -70,7 +70,7 @@ GccAna_Circ2d3Tan::
    NbrSol = 0;
    if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
         Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
 
index f8a925f..33a0c0b 100644 (file)
@@ -67,7 +67,7 @@ GccAna_Circ2d3Tan::
    NbrSol = 0;
    if (!(Qualified1.IsEnclosed() ||
         Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
 
index 9d64fe1..c07893c 100644 (file)
@@ -137,8 +137,8 @@ Handle(GccInt_Bisec) GccAna_Circ2dBisec::
    Standard_Real Tol = 1.e-14;
    Handle(GccInt_Bisec) bissol;
 
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 || Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 || Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      Standard_Real xcencir1 = circle1.Location().X();
      Standard_Real ycencir1 = circle1.Location().Y();
@@ -336,7 +336,7 @@ Standard_Boolean GccAna_Circ2dBisec::
 
 Standard_Integer GccAna_Circ2dBisec::NbSolutions () const 
 {
-  if (!WellDone) StdFail_NotDone::Raise();
+  if (!WellDone) throw StdFail_NotDone();
 
   return NbrSol;
 }
index c3fdca6..869c9ea 100644 (file)
@@ -62,7 +62,7 @@ GccAna_Circ2dTanCen::
    WellDone = Standard_False;
    if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
         Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
    gp_Dir2d dirx(1.0,0.0);
@@ -254,7 +254,7 @@ Standard_Integer GccAna_Circ2dTanCen::
 gp_Circ2d GccAna_Circ2dTanCen::
    ThisSolution (const Standard_Integer Index) const 
 {
-  if (Index > NbrSol || Index <= 0) { Standard_OutOfRange::Raise(); }
+  if (Index > NbrSol || Index <= 0) { throw Standard_OutOfRange(); }
   return cirsol(Index);
 }
 
@@ -262,8 +262,8 @@ void GccAna_Circ2dTanCen::
   WhichQualifier(const Standard_Integer Index   ,
                       GccEnt_Position& Qualif1 ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      Qualif1 = qualifier1(Index);
    }
@@ -274,15 +274,15 @@ void GccAna_Circ2dTanCen::
               Standard_Real& ParSol,
               Standard_Real& ParArg,
               gp_Pnt2d& PntSol) const{
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      if (TheSame1(Index) == 0) {
        PntSol = gp_Pnt2d(pnttg1sol(Index));
        ParSol = par1sol(Index);
        ParArg = pararg1(Index);
      }
-     else { StdFail_NotDone::Raise(); }
+     else { throw StdFail_NotDone(); }
    }
  }
 
@@ -290,9 +290,9 @@ Standard_Boolean GccAna_Circ2dTanCen::
    IsTheSame1 (const Standard_Integer Index) const
 {
   if (!WellDone) 
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   if (Index <= 0 ||Index > NbrSol) 
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
  
   if (TheSame1(Index) == 0) 
     return Standard_False;
index 031a0ad..2ae5977 100644 (file)
@@ -76,13 +76,13 @@ GccAna_Circ2dTanOnRad::
    NbrSol = 0;
    if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
         Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
    TColStd_Array1OfReal Coef(1,2);
    gp_Circ2d C1 = Qualified1.Qualified();
 
-   if (Radius < 0.0) { Standard_NegativeValue::Raise(); }
+   if (Radius < 0.0) { throw Standard_NegativeValue(); }
    else {
      Standard_Integer nbsol = 0;
      Standard_Integer signe = 0;
@@ -264,7 +264,7 @@ Standard_Integer GccAna_Circ2dTanOnRad::
 gp_Circ2d GccAna_Circ2dTanOnRad::ThisSolution (const Standard_Integer Index) const 
 {
   if (Index > NbrSol || Index <= 0) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return cirsol(Index);
 }
@@ -273,8 +273,8 @@ void GccAna_Circ2dTanOnRad::
   WhichQualifier(const Standard_Integer Index   ,
                       GccEnt_Position& Qualif1 ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      Qualif1 = qualifier1(Index);
    }
@@ -286,10 +286,10 @@ void GccAna_Circ2dTanOnRad::
               Standard_Real& ParArg,
               gp_Pnt2d& PntSol) const{
    if (!WellDone) {
-     StdFail_NotDone::Raise();
+     throw StdFail_NotDone();
    }
    else if (Index <= 0 ||Index > NbrSol) {
-     Standard_OutOfRange::Raise();
+     throw Standard_OutOfRange();
    }
    else {
      ParSol = par1sol(Index);
@@ -304,10 +304,10 @@ void GccAna_Circ2dTanOnRad::
               Standard_Real& ParArg,
               gp_Pnt2d& PntSol) const{
    if (!WellDone) {
-     StdFail_NotDone::Raise();
+     throw StdFail_NotDone();
    }
    else if (Index <= 0 ||Index > NbrSol) {
-     Standard_OutOfRange::Raise();
+     throw Standard_OutOfRange();
    }
    else {
      ParArg = parcen3(Index);
@@ -318,10 +318,10 @@ void GccAna_Circ2dTanOnRad::
 Standard_Boolean GccAna_Circ2dTanOnRad::IsTheSame1 (const Standard_Integer Index) const
 {
   if (!WellDone)
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   
   if (Index <= 0 ||Index > NbrSol)
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   
   if (TheSame1(Index) == 0)
     return Standard_False;
index e8a211f..966c646 100644 (file)
@@ -64,7 +64,7 @@ GccAna_Circ2dTanOnRad::
    NbrSol = 0;
    if (!(Qualified1.IsEnclosed() ||
         Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
    Standard_Integer nbsol = 0;
@@ -74,7 +74,7 @@ GccAna_Circ2dTanOnRad::
    gp_Dir2d dir1(L1.Direction());
    gp_Dir2d normL1(-dir1.Y(),dir1.X());
 
-   if (Radius < 0.0) { Standard_NegativeValue::Raise(); }
+   if (Radius < 0.0) { throw Standard_NegativeValue(); }
    else if ((OnLine.Direction()).IsParallel(dir1,Tol)) {
      WellDone = Standard_True;
    }
index e4c666e..e5508a2 100644 (file)
@@ -67,7 +67,7 @@ GccAna_Circ2dTanOnRad::
    NbrSol = 0;
    Standard_Real dp1lin = OnLine.Distance(Point1);
 
-   if (Radius < 0.0) { Standard_NegativeValue::Raise(); }
+   if (Radius < 0.0) { throw Standard_NegativeValue(); }
    else {
      if (dp1lin > Radius+Tol) { WellDone = Standard_True; }
      Standard_Real xc;
index 15016f9..84bbcce 100644 (file)
@@ -72,14 +72,14 @@ GccAna_Circ2dTanOnRad::
    NbrSol = 0;
    if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
         Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
    gp_Circ2d C1 = Qualified1.Qualified();
    TColgp_Array1OfPnt2d Center(1,4);
    TColgp_Array1OfDir2d dir1on(1,4);
 
-   if (Radius < 0.0) { Standard_NegativeValue::Raise(); }
+   if (Radius < 0.0) { throw Standard_NegativeValue(); }
    else {
      Standard_Real R1 = C1.Radius();
      Standard_Real R2 = OnCirc.Radius();
index bd90bba..28c8931 100644 (file)
@@ -67,7 +67,7 @@ GccAna_Circ2dTanOnRad::
    NbrSol = 0;
    if (!(Qualified1.IsEnclosed() ||
         Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
 
@@ -88,7 +88,7 @@ GccAna_Circ2dTanOnRad::
 //  Processing.                                                           +
 //=========================================================================
 
-   if (Radius < 0.0) { Standard_NegativeValue::Raise(); }
+   if (Radius < 0.0) { throw Standard_NegativeValue(); }
    else {
      L1 = Qualified1.Qualified();
      if ((dist1-Radius>Tol) || (Tol<Radius-dist2)) { WellDone=Standard_True; }
index 1750252..83f8255 100644 (file)
@@ -63,7 +63,7 @@ GccAna_Circ2dTanOnRad::
    Standard_Real dist1 = Point1.Distance(OnCirc.Location())-Roncirc;
    Standard_Real dist2 = Point1.Distance(OnCirc.Location())+Roncirc;
 
-   if (Radius < 0.0) { Standard_NegativeValue::Raise(); }
+   if (Radius < 0.0) { throw Standard_NegativeValue(); }
    else if ((dist1-Radius > Tol) || (Tol < Radius-dist2)) { 
      WellDone = Standard_True; 
    }
index 67d7549..8660c36 100644 (file)
@@ -68,9 +68,9 @@ Handle(GccInt_Bisec) GccAna_CircLin2dBisec::
    ThisSolution (const Standard_Integer Index) const 
 {
   
-  if (!WellDone) StdFail_NotDone::Raise();
+  if (!WellDone) throw StdFail_NotDone();
   
-  if ((Index <=0) || (Index > NbrSol)) Standard_OutOfRange::Raise();
+  if ((Index <=0) || (Index > NbrSol)) throw Standard_OutOfRange();
   
   Handle(GccInt_Bisec) bissol;
   Standard_Real xdir = line.Direction().X();
index 8667916..6965d1e 100644 (file)
@@ -98,10 +98,10 @@ Handle(GccInt_Bisec) GccAna_CircPnt2dBisec::
 {
   
   if (!WellDone)
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   
   if ((Index <=0) || (Index > NbrSol))
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
 
   Handle(GccInt_Bisec) bissol;  
   Standard_Real xpoint = point.X();
index ecfd9eb..3ea196c 100644 (file)
@@ -100,13 +100,13 @@ GccAna_Lin2d2Tan::
    NbrSol = 0;
    if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
         Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
    gp_Circ2d C1 = Qualified1.Qualified();
    Standard_Real R1 = C1.Radius();
 
-   if (Qualified1.IsEnclosed()) { GccEnt_BadQualifier::Raise(); }
+   if (Qualified1.IsEnclosed()) { throw GccEnt_BadQualifier(); }
 // ============================
    else if (Tol < R1-ThePoint.Distance(C1.Location())) { 
      WellDone = Standard_True; 
@@ -203,7 +203,7 @@ GccAna_Lin2d2Tan::
          Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
        !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
          Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
       return;
     }
     gp_Circ2d C1 = Qualified1.Qualified();
@@ -211,7 +211,7 @@ GccAna_Lin2d2Tan::
 
     if (Qualified1.IsEnclosed() || Qualified2.IsEnclosed()) {
  // =======================================================
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
     }
     else {
       Standard_Real R1 = C1.Radius();
@@ -481,7 +481,7 @@ Standard_Integer GccAna_Lin2d2Tan::
 gp_Lin2d GccAna_Lin2d2Tan::
    ThisSolution (const Standard_Integer Index) const {
 
-   if (Index > NbrSol || Index <= 0) { Standard_OutOfRange::Raise(); }
+   if (Index > NbrSol || Index <= 0) { throw Standard_OutOfRange(); }
    return linsol(Index);
  }
 
@@ -490,8 +490,8 @@ void GccAna_Lin2d2Tan::
                       GccEnt_Position& Qualif1 ,
                       GccEnt_Position& Qualif2 ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      Qualif1 = qualifier1(Index);
      Qualif2 = qualifier2(Index);
@@ -503,8 +503,8 @@ void GccAna_Lin2d2Tan::
               Standard_Real& ParSol,
               Standard_Real& ParArg,
               gp_Pnt2d& PntSol) const {
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      ParSol = par1sol(Index);
      ParArg = pararg1(Index);
@@ -517,8 +517,8 @@ void GccAna_Lin2d2Tan::
                     Standard_Real&     ParSol ,
                     Standard_Real&     ParArg ,
                     gp_Pnt2d& PntSol ) const {
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      ParSol = par2sol(Index);
      ParArg = pararg2(Index);
index 60b0177..0ac9cb4 100644 (file)
@@ -121,7 +121,7 @@ Standard_Integer GccAna_Lin2dBisec::
    NbSolutions () const 
 {
   if (!WellDone) 
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   return NbrSol;
 }
 
@@ -129,9 +129,9 @@ gp_Lin2d GccAna_Lin2dBisec::
    ThisSolution (const Standard_Integer Index) const 
 {
   if (!WellDone) 
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   if (Index <= 0 || Index > NbrSol) 
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   return linsol(Index);
 }
 
@@ -140,8 +140,8 @@ void GccAna_Lin2dBisec::
                   Standard_Real& ParSol,
                   Standard_Real& ParArg,
                   gp_Pnt2d& PntSol) const{
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      ParSol = par1sol(Index);
      ParArg = pararg1(Index);
@@ -155,8 +155,8 @@ void GccAna_Lin2dBisec::
                   Standard_Real& ParSol,
                   Standard_Real& ParArg,
                   gp_Pnt2d& PntSol) const{
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      ParSol = par2sol(Index);
      ParArg = pararg2(Index);
index 3222ef2..db4ed1f 100644 (file)
@@ -111,14 +111,14 @@ GccAna_Lin2dTanObl::
    NbrSol = 0;
    if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
         Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
    Standard_Real Cosa = TheLine.Direction().X();
    Standard_Real Sina = TheLine.Direction().Y();
    if (Qualified1.IsEnclosed()) {
 // ============================
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
    }
    else {
      gp_Circ2d C1 = Qualified1.Qualified();
@@ -209,7 +209,7 @@ Standard_Boolean GccAna_Lin2dTanObl::
 Standard_Integer GccAna_Lin2dTanObl::
    NbSolutions () const 
 { 
-  if (!WellDone) StdFail_NotDone::Raise();
+  if (!WellDone) throw StdFail_NotDone();
   return NbrSol;
 }
 
@@ -217,9 +217,9 @@ gp_Lin2d GccAna_Lin2dTanObl::
    ThisSolution (const Standard_Integer Index) const 
 {
   if (!WellDone) 
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   if (Index <= 0 || Index > NbrSol) 
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
 
   return linsol(Index);
 }
@@ -228,8 +228,8 @@ void GccAna_Lin2dTanObl::
   WhichQualifier(const Standard_Integer Index   ,
                       GccEnt_Position& Qualif1 ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      Qualif1 = qualifier1(Index);
    }
@@ -240,8 +240,8 @@ void GccAna_Lin2dTanObl::
                     Standard_Real&     ParSol,
                     Standard_Real&     ParArg,
                     gp_Pnt2d& PntSol) const{
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      ParSol = par1sol(Index);
      ParArg = pararg1(Index);
@@ -254,8 +254,8 @@ void GccAna_Lin2dTanObl::
                   Standard_Real& ParSol,
                   Standard_Real& ParArg,
                   gp_Pnt2d& PntSol) const{
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      ParSol = par2sol(Index);
      ParArg = pararg2(Index);
index 2859b89..e839f4e 100644 (file)
@@ -82,14 +82,14 @@ GccAna_Lin2dTanPar::
    NbrSol = 0;
    if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
         Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
      return;
    }
    gp_Circ2d C1 = Qualified1.Qualified();
    Standard_Real xdir = (Lin1.Direction()).X();
    Standard_Real ydir = (Lin1.Direction()).Y();
 
-   if (Qualified1.IsEnclosed()) { GccEnt_BadQualifier::Raise(); }
+   if (Qualified1.IsEnclosed()) { throw GccEnt_BadQualifier(); }
 // ============================
    else if (Qualified1.IsEnclosing()) {
 // ==================================
@@ -130,14 +130,14 @@ Standard_Boolean GccAna_Lin2dTanPar::
 Standard_Integer GccAna_Lin2dTanPar::NbSolutions () const 
 {
   if (!WellDone) 
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   return NbrSol;
 }
 
 gp_Lin2d GccAna_Lin2dTanPar::ThisSolution (const Standard_Integer Index) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 || Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 || Index > NbrSol) { throw Standard_OutOfRange(); }
   return linsol(Index);
 }
 
@@ -145,8 +145,8 @@ void GccAna_Lin2dTanPar::
   WhichQualifier(const Standard_Integer Index   ,
                       GccEnt_Position& Qualif1 ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      Qualif1 = qualifier1(Index);
    }
@@ -157,8 +157,8 @@ void GccAna_Lin2dTanPar::
               Standard_Real& ParSol,
               Standard_Real& ParArg,
               gp_Pnt2d& Pnt) const {
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      ParSol = par1sol(Index);
      ParArg = pararg1(Index);
index 6cb7b88..63560f2 100644 (file)
@@ -145,7 +145,7 @@ GccAna_Lin2dTanPer::
 
    if (Qualified1.IsEnclosed()) {
 // ============================
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
    }
    else if (Qualified1.IsEnclosing()) {
 // ==================================
@@ -215,7 +215,7 @@ GccAna_Lin2dTanPer::
 
    if (Qualified1.IsEnclosed()) {
 // ============================
-     GccEnt_BadQualifier::Raise();
+     throw GccEnt_BadQualifier();
    }
    else if (Qualified1.IsEnclosing()) {
 // ==================================
@@ -268,15 +268,15 @@ Standard_Boolean GccAna_Lin2dTanPer::
 Standard_Integer GccAna_Lin2dTanPer::
    NbSolutions () const 
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); } 
+  if (!WellDone) { throw StdFail_NotDone(); } 
   return NbrSol;
 }
 
 gp_Lin2d GccAna_Lin2dTanPer::
    ThisSolution (const Standard_Integer Index) const 
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); } 
-  if (Index <= 0 || Index > NbrSol) { Standard_RangeError::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); } 
+  if (Index <= 0 || Index > NbrSol) { throw Standard_RangeError(); }
   return linsol(Index);
 }
 
@@ -284,8 +284,8 @@ void GccAna_Lin2dTanPer::
   WhichQualifier(const Standard_Integer Index   ,
                       GccEnt_Position& Qualif1 ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     Qualif1 = qualifier1(Index);
   }
@@ -296,8 +296,8 @@ void GccAna_Lin2dTanPer::
               Standard_Real& ParSol,
               Standard_Real& ParArg,
               gp_Pnt2d& Pnt) const{
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      ParSol = par1sol(Index);
      ParArg = pararg1(Index);
@@ -310,8 +310,8 @@ void GccAna_Lin2dTanPer::
                   Standard_Real& ParSol,
                   Standard_Real& ParArg,
                   gp_Pnt2d& PntSol) const {
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      ParSol = par2sol(Index);
      ParArg = pararg2(Index);
index fadcd34..6ffc603 100644 (file)
@@ -84,7 +84,7 @@ Handle(GccInt_Bisec) GccAna_LinPnt2dBisec::
    ThisSolution () const 
 {
   if (!WellDone)
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
 
   return bissol;
 }
index 37a3a28..a79b847 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(GccAna_NoSolution, Standard_Failure)
 
 #if !defined No_Exception && !defined No_GccAna_NoSolution
   #define GccAna_NoSolution_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) GccAna_NoSolution::Raise(MESSAGE);
+  if (CONDITION) throw GccAna_NoSolution(MESSAGE);
 #else
   #define GccAna_NoSolution_Raise_if(CONDITION, MESSAGE)
 #endif
index 0fa2784..2f4423c 100644 (file)
@@ -63,7 +63,7 @@ Standard_Boolean GccAna_Pnt2dBisec::
 
 gp_Lin2d GccAna_Pnt2dBisec::
    ThisSolution () const {
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (!HasSol) { GccAna_NoSolution::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (!HasSol) { throw GccAna_NoSolution(); }
    return linsol;
  }
index 0c273be..38c45c4 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(GccEnt_BadQualifier, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_GccEnt_BadQualifier
   #define GccEnt_BadQualifier_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) GccEnt_BadQualifier::Raise(MESSAGE);
+  if (CONDITION) throw GccEnt_BadQualifier(MESSAGE);
 #else
   #define GccEnt_BadQualifier_Raise_if(CONDITION, MESSAGE)
 #endif
index 13dd740..ac6037b 100644 (file)
@@ -30,37 +30,31 @@ IMPLEMENT_STANDARD_RTTIEXT(GccInt_Bisec,MMgt_TShared)
 
 gp_Circ2d GccInt_Bisec::
   Circle() const { 
-    Standard_NotImplemented::Raise();
-    return gp_Circ2d();
+    throw Standard_NotImplemented();
     }
 
 gp_Elips2d GccInt_Bisec::
   Ellipse() const { 
-    Standard_NotImplemented::Raise();
-    return gp_Elips2d();
+    throw Standard_NotImplemented();
     }
 
 gp_Hypr2d GccInt_Bisec::
   Hyperbola() const { 
-    Standard_NotImplemented::Raise();
-    return gp_Hypr2d();
+    throw Standard_NotImplemented();
     }
 
 gp_Lin2d GccInt_Bisec::
   Line() const {
-    Standard_NotImplemented::Raise();
-    return gp_Lin2d();
+    throw Standard_NotImplemented();
     }
 
 gp_Parab2d GccInt_Bisec::
   Parabola() const { 
-    Standard_NotImplemented::Raise();
-    return gp_Parab2d();
+    throw Standard_NotImplemented();
     }
 
 gp_Pnt2d GccInt_Bisec::
   Point() const { 
-    Standard_NotImplemented::Raise();
-    return gp_Pnt2d();
+    throw Standard_NotImplemented();
     }
 
index 195d56f..c2c07e7 100644 (file)
@@ -65,20 +65,20 @@ static void CheckCurveData
  const Standard_Boolean            Periodic)
 {
   if (Degree < 1 || Degree > Geom_BSplineCurve::MaxDegree()) {
-    Standard_ConstructionError::Raise();  
+    throw Standard_ConstructionError();
   }
   
-  if (CPoles.Length() < 2)                Standard_ConstructionError::Raise();
-  if (CKnots.Length() != CMults.Length()) Standard_ConstructionError::Raise();
+  if (CPoles.Length() < 2)                throw Standard_ConstructionError();
+  if (CKnots.Length() != CMults.Length()) throw Standard_ConstructionError();
   
   for (Standard_Integer I = CKnots.Lower(); I < CKnots.Upper(); I++) {
     if (CKnots (I+1) - CKnots (I) <= Epsilon (Abs(CKnots (I)))) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   }
   
   if (CPoles.Length() != BSplCLib::NbPoles(Degree,Periodic,CMults))
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
 }
 
 //=======================================================================
@@ -187,12 +187,12 @@ Geom_BSplineCurve::Geom_BSplineCurve
                  Periodic);
 
   if (Weights.Length() != Poles.Length())
-    Standard_ConstructionError::Raise("Geom_BSplineCurve");
+    throw Standard_ConstructionError("Geom_BSplineCurve");
 
   Standard_Integer i;
   for (i = Weights.Lower(); i <= Weights.Upper(); i++) {
     if (Weights(i) <= gp::Resolution())  
-      Standard_ConstructionError::Raise("Geom_BSplineCurve");
+      throw Standard_ConstructionError("Geom_BSplineCurve");
   }
   
   // check really rational
@@ -237,7 +237,7 @@ void Geom_BSplineCurve::IncreaseDegree  (const Standard_Integer Degree)
   if (Degree == deg) return;
   
   if (Degree < deg || Degree > Geom_BSplineCurve::MaxDegree()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   Standard_Integer FromK1 = FirstUKnotIndex ();
   Standard_Integer ToK2   = LastUKnotIndex  ();
@@ -372,7 +372,7 @@ void  Geom_BSplineCurve::InsertKnots(const TColStd_Array1OfReal& Knots,
   if (!BSplCLib::PrepareInsertKnots(deg,periodic,
                                    knots->Array1(),mults->Array1(),
                                    Knots,&Mults,nbpoles,nbknots,Epsilon,Add))
-    Standard_ConstructionError::Raise("Geom_BSplineCurve::InsertKnots");
+    throw Standard_ConstructionError("Geom_BSplineCurve::InsertKnots");
 
   if (nbpoles == poles->Length()) return;
 
@@ -430,10 +430,10 @@ Standard_Boolean  Geom_BSplineCurve::RemoveKnot(const Standard_Integer Index,
   Standard_Integer I2  = LastUKnotIndex  ();
 
   if ( !periodic && (Index <= I1 || Index >= I2) ) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   else if ( periodic  && (Index < I1 || Index > I2)) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   
   const TColgp_Array1OfPnt   & oldpoles   = poles->Array1();
@@ -526,7 +526,7 @@ void Geom_BSplineCurve::Segment(const Standard_Real U1,
                                const Standard_Real U2)
 {
   if (U2 < U1)
-    Standard_DomainError::Raise("Geom_BSplineCurve::Segment");
+    throw Standard_DomainError("Geom_BSplineCurve::Segment");
   
   Standard_Real NewU1, NewU2;
   Standard_Real U,DU=0,aDDU=0;
@@ -541,7 +541,7 @@ void Geom_BSplineCurve::Segment(const Standard_Real U1,
     Standard_Real Period = LastParameter() - FirstParameter();
     DU = U2 - U1;
     if (DU - Period > Precision::PConfusion())
-      Standard_DomainError::Raise("Geom_BSplineCurve::Segment");
+      throw Standard_DomainError("Geom_BSplineCurve::Segment");
     if (DU > Period)
       DU = Period;
     aDDU = DU;
@@ -683,20 +683,20 @@ void Geom_BSplineCurve::SetKnot
 (const Standard_Integer Index,
  const Standard_Real K)
 {
-  if (Index < 1 || Index > knots->Length())     Standard_OutOfRange::Raise();
+  if (Index < 1 || Index > knots->Length())     throw Standard_OutOfRange();
   Standard_Real DK = Abs(Epsilon (K));
   if (Index == 1) { 
-    if (K >= knots->Value(2) - DK) Standard_ConstructionError::Raise();
+    if (K >= knots->Value(2) - DK) throw Standard_ConstructionError();
   }
   else if (Index == knots->Length()) {
     if (K <= knots->Value (knots->Length()-1) + DK)  {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   }
   else {
     if (K <= knots->Value(Index-1) + DK ||
        K >= knots->Value(Index+1) - DK ) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   }
   if (K != knots->Value (Index)) {
@@ -784,14 +784,14 @@ void Geom_BSplineCurve::SetPeriodic ()
 void Geom_BSplineCurve::SetOrigin(const Standard_Integer Index)
 {
   if (!periodic)
-    Standard_NoSuchObject::Raise("Geom_BSplineCurve::SetOrigin");
+    throw Standard_NoSuchObject("Geom_BSplineCurve::SetOrigin");
 
   Standard_Integer i,k;
   Standard_Integer first = FirstUKnotIndex();
   Standard_Integer last  = LastUKnotIndex();
 
   if ((Index < first) || (Index > last))
-    Standard_DomainError::Raise("Geom_BSplineCurve::SetOrigin");
+    throw Standard_DomainError("Geom_BSplineCurve::SetOrigin");
 
   Standard_Integer nbknots = knots->Length();
   Standard_Integer nbpoles = poles->Length();
@@ -874,7 +874,7 @@ void Geom_BSplineCurve::SetOrigin(const Standard_Real U,
                                  const Standard_Real Tol)
 {
   if (!periodic)
-    Standard_NoSuchObject::Raise("Geom_BSplineCurve::SetOrigin");
+    throw Standard_NoSuchObject("Geom_BSplineCurve::SetOrigin");
   //U est il dans la period.
   Standard_Real uf = FirstParameter(), ul = LastParameter();
   Standard_Real u = U, period = ul - uf;
@@ -973,7 +973,7 @@ void Geom_BSplineCurve::SetPole
 (const Standard_Integer Index,
  const gp_Pnt& P)
 {
-  if (Index < 1 || Index > poles->Length()) Standard_OutOfRange::Raise();
+  if (Index < 1 || Index > poles->Length()) throw Standard_OutOfRange();
   poles->SetValue (Index, P);
   maxderivinvok = 0;
 }
@@ -1001,9 +1001,9 @@ void Geom_BSplineCurve::SetWeight
 (const Standard_Integer Index,
  const Standard_Real W)
 {
-  if (Index < 1 || Index > poles->Length())   Standard_OutOfRange::Raise();
+  if (Index < 1 || Index > poles->Length())   throw Standard_OutOfRange();
 
-  if (W <= gp::Resolution ())     Standard_ConstructionError::Raise();
+  if (W <= gp::Resolution ())     throw Standard_ConstructionError();
 
 
   Standard_Boolean rat = IsRational() || (Abs(W - 1.) > gp::Resolution());
@@ -1040,7 +1040,7 @@ void Geom_BSplineCurve::MovePoint(const Standard_Real U,
 {
   if (Index1 < 1 || Index1 > poles->Length() || 
       Index2 < 1 || Index2 > poles->Length() || Index1 > Index2) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   TColgp_Array1OfPnt npoles(1, poles->Length());
   gp_Pnt P0;
index 2d7153a..8bbd8cb 100644 (file)
@@ -62,35 +62,35 @@ static void CheckSurfaceData
 {
   if (UDegree < 1 || UDegree > Geom_BSplineSurface::MaxDegree () || 
       VDegree < 1 || VDegree > Geom_BSplineSurface::MaxDegree ()) {
-    Standard_ConstructionError::Raise("Geom_BSplineSurface");
+    throw Standard_ConstructionError("Geom_BSplineSurface");
   }
   if (SPoles.ColLength () < 2 || SPoles.RowLength () < 2) {
-    Standard_ConstructionError::Raise("Geom_BSplineSurface");
+    throw Standard_ConstructionError("Geom_BSplineSurface");
   }
 
   if (SUKnots.Length() != SUMults.Length() ||
       SVKnots.Length() != SVMults.Length()) {
-    Standard_ConstructionError::Raise("Geom_BSplineSurface");
+    throw Standard_ConstructionError("Geom_BSplineSurface");
   }
 
   Standard_Integer i;
   for (i = SUKnots.Lower(); i < SUKnots.Upper(); i++) {
     if (SUKnots(i+1) - SUKnots(i) <= Epsilon(Abs(SUKnots(i)))) {
-      Standard_ConstructionError::Raise("Geom_BSplineSurface");
+      throw Standard_ConstructionError("Geom_BSplineSurface");
     }
   }
 
   for (i = SVKnots.Lower(); i < SVKnots.Upper(); i++) {
     if (SVKnots(i+1) - SVKnots(i) <= Epsilon(Abs(SVKnots(i)))) {
-      Standard_ConstructionError::Raise("Geom_BSplineSurface");
+      throw Standard_ConstructionError("Geom_BSplineSurface");
     }
   }
   
   if (SPoles.ColLength() != BSplCLib::NbPoles(UDegree,UPeriodic,SUMults))
-    Standard_ConstructionError::Raise("Geom_BSplineSurface");
+    throw Standard_ConstructionError("Geom_BSplineSurface");
 
   if (SPoles.RowLength() != BSplCLib::NbPoles(VDegree,VPeriodic,SVMults))
-    Standard_ConstructionError::Raise("Geom_BSplineSurface");
+    throw Standard_ConstructionError("Geom_BSplineSurface");
 }
 
 //=======================================================================
@@ -237,16 +237,16 @@ Geom_BSplineSurface::Geom_BSplineSurface
   // check weights
 
   if (Weights.ColLength() != Poles.ColLength())
-    Standard_ConstructionError::Raise("Geom_BSplineSurface");
+    throw Standard_ConstructionError("Geom_BSplineSurface");
 
   if (Weights.RowLength() != Poles.RowLength())
-    Standard_ConstructionError::Raise("Geom_BSplineSurface");
+    throw Standard_ConstructionError("Geom_BSplineSurface");
 
   Standard_Integer i,j;
   for (i = Weights.LowerRow(); i <= Weights.UpperRow(); i++) {
     for (j = Weights.LowerCol(); j <= Weights.UpperCol(); j++) {
       if (Weights(i,j) <= gp::Resolution())  
-       Standard_ConstructionError::Raise("Geom_BSplineSurface");
+       throw Standard_ConstructionError("Geom_BSplineSurface");
     }
   }
   
@@ -357,7 +357,7 @@ void Geom_BSplineSurface::IncreaseDegree (const Standard_Integer UDegree,
 { 
   if (UDegree != udeg) {
     if ( UDegree < udeg || UDegree > Geom_BSplineSurface::MaxDegree())
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     
     Standard_Integer FromK1 = FirstUKnotIndex();
     Standard_Integer ToK2   = LastUKnotIndex();
@@ -409,7 +409,7 @@ void Geom_BSplineSurface::IncreaseDegree (const Standard_Integer UDegree,
 
   if (VDegree != vdeg) {
     if ( VDegree < vdeg || VDegree > Geom_BSplineSurface::MaxDegree())
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     
     Standard_Integer FromK1 = FirstVKnotIndex();
     Standard_Integer ToK2   = LastVKnotIndex();
@@ -539,14 +539,14 @@ void Geom_BSplineSurface::Segment(const Standard_Real U1,
                                  const Standard_Real V2) 
 {
   if ((U2 < U1) || (V2 < V1))
-    Standard_DomainError::Raise("Geom_BSplineSurface::Segment");
+    throw Standard_DomainError("Geom_BSplineSurface::Segment");
   Standard_Real deltaU = Max(Abs(U2),Abs(U1));
   Standard_Real EpsU = Epsilon(deltaU);
   deltaU = U2 - U1;
   if (uperiodic) {
     Standard_Real aUPeriod = uknots->Last() - uknots->First();
     if (deltaU - aUPeriod > Precision::PConfusion())
-      Standard_DomainError::Raise("Geom_BSplineSurface::Segment");
+      throw Standard_DomainError("Geom_BSplineSurface::Segment");
     if (deltaU > aUPeriod)
       deltaU = aUPeriod;
   }
@@ -557,7 +557,7 @@ void Geom_BSplineSurface::Segment(const Standard_Real U1,
   if (vperiodic) {
     Standard_Real aVPeriod = vknots->Last() - vknots->First();
     if (deltaV - aVPeriod > Precision::PConfusion())
-      Standard_DomainError::Raise("Geom_BSplineSurface::Segment");
+      throw Standard_DomainError("Geom_BSplineSurface::Segment");
     if (deltaV > aVPeriod)
       deltaV = aVPeriod;
   }
@@ -761,14 +761,14 @@ void Geom_BSplineSurface::CheckAndSegment(const Standard_Real U1,
 {
 
   if ((U2 < U1) || (V2 < V1))
-    Standard_DomainError::Raise("Geom_BSplineSurface::CheckAndSegment");
+    throw Standard_DomainError("Geom_BSplineSurface::CheckAndSegment");
   Standard_Real deltaU = Max(Abs(U2),Abs(U1));
   Standard_Real EpsU = Epsilon(deltaU);
   deltaU = U2 - U1;
   if (uperiodic) {
     Standard_Real aUPeriod = uknots->Last() - uknots->First();
     if (deltaU - aUPeriod > Precision::PConfusion())
-      Standard_DomainError::Raise("Geom_BSplineSurface::CheckAndSegment");
+      throw Standard_DomainError("Geom_BSplineSurface::CheckAndSegment");
     if (deltaU > aUPeriod)
       deltaU = aUPeriod;
   }
@@ -779,7 +779,7 @@ void Geom_BSplineSurface::CheckAndSegment(const Standard_Real U1,
   if (vperiodic) {
     Standard_Real aVPeriod = vknots->Last() - vknots->First();
     if (deltaV - aVPeriod > Precision::PConfusion())
-      Standard_DomainError::Raise("Geom_BSplineSurface::CheckAndSegment");
+      throw Standard_DomainError("Geom_BSplineSurface::CheckAndSegment");
     if (deltaV > aVPeriod)
       deltaV = aVPeriod;
   }
@@ -992,22 +992,22 @@ void Geom_BSplineSurface::SetUKnot
 (const Standard_Integer UIndex,
  const Standard_Real    K      )
 {
-  if (UIndex < 1 || UIndex > uknots->Length()) Standard_OutOfRange::Raise();
+  if (UIndex < 1 || UIndex > uknots->Length()) throw Standard_OutOfRange();
 
   Standard_Integer NewIndex = UIndex;
   Standard_Real DU = Abs(Epsilon (K));
   if (UIndex == 1) {
-    if (K >= uknots->Value (2) - DU) Standard_ConstructionError::Raise();
+    if (K >= uknots->Value (2) - DU) throw Standard_ConstructionError();
   }
   else if (UIndex == uknots->Length()) {
     if (K <= uknots->Value (uknots->Length()-1) + DU)  {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   }
   else {
     if (K <= uknots->Value (NewIndex-1) + DU || 
        K >= uknots->Value (NewIndex+1) - DU ) { 
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     } 
   }
   
@@ -1029,16 +1029,16 @@ void Geom_BSplineSurface::SetUKnots (const TColStd_Array1OfReal& UK) {
   Standard_Integer Upper = UK.Upper();
   if (Lower < 1 || Lower > uknots->Length() ||
       Upper < 1 || Upper > uknots->Length() ) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   if (Lower > 1) {
     if (Abs (UK (Lower) - uknots->Value (Lower-1)) <= gp::Resolution()) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   }
   if (Upper < uknots->Length ()) {
     if (Abs (UK (Upper) - uknots->Value (Upper+1)) <= gp::Resolution()) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   }
   Standard_Real K1 = UK (Lower);
@@ -1046,7 +1046,7 @@ void Geom_BSplineSurface::SetUKnots (const TColStd_Array1OfReal& UK) {
     uknots->SetValue (i, UK(i));
     if (i != Lower) {
       if (Abs (UK(i) - K1) <= gp::Resolution()) {
-        Standard_ConstructionError::Raise();
+        throw Standard_ConstructionError();
       }
       K1 = UK (i);
     }
@@ -1079,23 +1079,23 @@ void Geom_BSplineSurface::SetVKnot
 (const Standard_Integer VIndex,
  const Standard_Real    K)
 {
-  if (VIndex < 1 || VIndex > vknots->Length())  Standard_OutOfRange::Raise();
+  if (VIndex < 1 || VIndex > vknots->Length())  throw Standard_OutOfRange();
   Standard_Integer NewIndex = VIndex + vknots->Lower() - 1;
   Standard_Real DV = Abs(Epsilon (K));
   if (VIndex == 1) {
     if (K >=  vknots->Value (2) - DV) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   }
   else if (VIndex == vknots->Length()) {
     if (K <= vknots->Value (vknots->Length()-1) + DV)  {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   }
   else {
     if (K <= vknots->Value (NewIndex-1) + DV || 
        K >= vknots->Value (NewIndex+1) - DV ) { 
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     } 
   }
   
@@ -1117,16 +1117,16 @@ void Geom_BSplineSurface::SetVKnots (const TColStd_Array1OfReal& VK) {
   Standard_Integer Upper = VK.Upper();
   if (Lower < 1 || Lower > vknots->Length() ||
       Upper < 1 || Upper > vknots->Length() ) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   if (Lower > 1) {
     if (Abs (VK (Lower) - vknots->Value (Lower-1)) <= gp::Resolution()) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   }
   if (Upper < vknots->Length ()) {
     if (Abs (VK (Upper) - vknots->Value (Upper+1)) <= gp::Resolution()) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   }
   Standard_Real K1 = VK (Lower);
@@ -1134,7 +1134,7 @@ void Geom_BSplineSurface::SetVKnots (const TColStd_Array1OfReal& VK) {
     vknots->SetValue (i, VK(i));
     if (i != Lower) {
       if (Abs (VK(i) - K1) <= gp::Resolution()) {
-        Standard_ConstructionError::Raise();
+        throw Standard_ConstructionError();
       }
       K1 = VK (i);
     }
@@ -1326,7 +1326,7 @@ void Geom_BSplineSurface::PeriodicNormalization
     Period =  aMaxVal - aMinVal;
 
     if(Period <= eps) 
-      Standard_OutOfRange::Raise("Geom_BSplineSurface::PeriodicNormalization: Uparameter is too great number");
+      throw Standard_OutOfRange("Geom_BSplineSurface::PeriodicNormalization: Uparameter is too great number");
 
     Standard_Boolean isLess, isGreater;
     isLess = aMinVal - Uparameter > 0;
@@ -1345,7 +1345,7 @@ void Geom_BSplineSurface::PeriodicNormalization
     Period = aMaxVal - aMinVal;
 
     if(Period <= eps) 
-      Standard_OutOfRange::Raise("Geom_BSplineSurface::PeriodicNormalization: Vparameter is too great number");
+      throw Standard_OutOfRange("Geom_BSplineSurface::PeriodicNormalization: Vparameter is too great number");
 
     Standard_Boolean isLess, isGreater;
     isLess = aMinVal - Vparameter > 0;
@@ -1368,11 +1368,11 @@ void Geom_BSplineSurface::SetWeight (const Standard_Integer UIndex,
                                     const Standard_Integer VIndex,
                                     const Standard_Real    Weight)
 {
-  if (Weight <= gp::Resolution())  Standard_ConstructionError::Raise(); 
+  if (Weight <= gp::Resolution())  throw Standard_ConstructionError();
   TColStd_Array2OfReal & Weights = weights->ChangeArray2();
   if (UIndex < 1 || UIndex > Weights.ColLength() ||
       VIndex < 1 || VIndex > Weights.RowLength() ) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   Weights (UIndex+Weights.LowerRow()-1, VIndex+Weights.LowerCol()-1) = Weight;
   Rational(Weights, urational, vrational);
@@ -1389,18 +1389,18 @@ void Geom_BSplineSurface::SetWeightCol
 {
   TColStd_Array2OfReal & Weights = weights->ChangeArray2();   
   if (VIndex < 1 || VIndex > Weights.RowLength()) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   if (CPoleWeights.Lower() < 1 || 
       CPoleWeights.Lower() > Weights.ColLength() ||
       CPoleWeights.Upper() < 1 ||
       CPoleWeights.Upper() > Weights.ColLength()  ) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   Standard_Integer I = CPoleWeights.Lower();
   while (I <= CPoleWeights.Upper()) {
     if (CPoleWeights(I) <= gp::Resolution()) { 
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
     Weights (I+Weights.LowerRow()-1, VIndex+Weights.LowerCol()-1) = 
       CPoleWeights (I);
@@ -1421,20 +1421,20 @@ void Geom_BSplineSurface::SetWeightRow
 {
   TColStd_Array2OfReal & Weights = weights->ChangeArray2();   
   if (UIndex < 1 || UIndex > Weights.ColLength()) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   if (CPoleWeights.Lower() < 1 ||
       CPoleWeights.Lower() > Weights.RowLength() ||
       CPoleWeights.Upper() < 1 ||
       CPoleWeights.Upper() > Weights.RowLength()  ) {
     
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   Standard_Integer I = CPoleWeights.Lower();
 
   while (I <= CPoleWeights.Upper()) {
     if (CPoleWeights(I)<=gp::Resolution()) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
     Weights (UIndex+Weights.LowerRow()-1, I+Weights.LowerCol()-1) = 
       CPoleWeights (I);
index 3a768cc..db99bfc 100644 (file)
@@ -922,14 +922,14 @@ void Geom_BSplineSurface::SetVPeriodic ()
 void Geom_BSplineSurface::SetUOrigin(const Standard_Integer Index)
 {
   if (!uperiodic)
-    Standard_NoSuchObject::Raise("Geom_BSplineSurface::SetUOrigin");
+    throw Standard_NoSuchObject("Geom_BSplineSurface::SetUOrigin");
 
   Standard_Integer i,j,k;
   Standard_Integer first = FirstUKnotIndex();
   Standard_Integer last  = LastUKnotIndex();
 
   if ((Index < first) || (Index > last))
-    Standard_DomainError::Raise("Geom_BSplineCurve::SetUOrigin");
+    throw Standard_DomainError("Geom_BSplineCurve::SetUOrigin");
 
   Standard_Integer nbknots = uknots->Length();
   Standard_Integer nbpoles = poles->ColLength();
@@ -1020,14 +1020,14 @@ void Geom_BSplineSurface::SetUOrigin(const Standard_Integer Index)
 void Geom_BSplineSurface::SetVOrigin(const Standard_Integer Index)
 {
   if (!vperiodic)
-    Standard_NoSuchObject::Raise("Geom_BSplineSurface::SetVOrigin");
+    throw Standard_NoSuchObject("Geom_BSplineSurface::SetVOrigin");
 
   Standard_Integer i,j,k;
   Standard_Integer first = FirstVKnotIndex();
   Standard_Integer last  = LastVKnotIndex();
 
   if ((Index < first) || (Index > last))
-    Standard_DomainError::Raise("Geom_BSplineCurve::SetVOrigin");
+    throw Standard_DomainError("Geom_BSplineCurve::SetVOrigin");
 
   Standard_Integer nbknots = vknots->Length();
   Standard_Integer nbpoles = poles->RowLength();
@@ -1489,11 +1489,11 @@ void Geom_BSplineSurface::SetPoleCol (const Standard_Integer      VIndex,
                                      const TColgp_Array1OfPnt&   CPoles)
 {
   if (VIndex < 1 || VIndex > poles->RowLength()) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
     }
   if (CPoles.Lower() < 1 || CPoles.Lower() > poles->ColLength() || 
       CPoles.Upper() < 1 || CPoles.Upper() > poles->ColLength()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
     }
 
   TColgp_Array2OfPnt & Poles = poles->ChangeArray2();
@@ -1525,11 +1525,11 @@ void Geom_BSplineSurface::SetPoleRow (const Standard_Integer    UIndex,
                                      const TColgp_Array1OfPnt& CPoles)
 {
   if (UIndex < 1 || UIndex > poles->ColLength()  ) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
     }
   if (CPoles.Lower() < 1 || CPoles.Lower() > poles->RowLength() || 
       CPoles.Upper() < 1 || CPoles.Upper() > poles->RowLength() ) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
     }
 
   TColgp_Array2OfPnt & Poles = poles->ChangeArray2();
@@ -1599,7 +1599,7 @@ void Geom_BSplineSurface::MovePoint(const Standard_Real U,
       UIndex2 < 1 || UIndex2 > poles->UpperRow() || UIndex1 > UIndex2 ||
       VIndex1 < 1 || VIndex1 > poles->UpperCol() || 
       VIndex2 < 1 || VIndex2 > poles->UpperCol() || VIndex1 > VIndex2) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
 
   TColgp_Array2OfPnt npoles(1, poles->UpperRow(), 1, poles->UpperCol());
@@ -1774,7 +1774,7 @@ void  Geom_BSplineSurface::InsertUKnots
                                     uknots->Array1(),umults->Array1(),
                                     Knots,&Mults,nbpoles,nbknots,
                                     ParametricTolerance,Add))
-    Standard_ConstructionError::Raise("Geom_BSplineSurface::InsertUKnots");
+    throw Standard_ConstructionError("Geom_BSplineSurface::InsertUKnots");
   
   if ( nbpoles == poles->ColLength()) return;
 
@@ -1841,7 +1841,7 @@ void  Geom_BSplineSurface::InsertVKnots
                                     vknots->Array1(),vmults->Array1(),
                                     Knots,&Mults,nbpoles,nbknots,
                                     ParametricTolerance, Add))
-    Standard_ConstructionError::Raise("Geom_BSplineSurface::InsertVKnots");
+    throw Standard_ConstructionError("Geom_BSplineSurface::InsertVKnots");
   
   if ( nbpoles == poles->RowLength()) return;
 
@@ -1906,10 +1906,10 @@ Standard_Boolean  Geom_BSplineSurface::RemoveUKnot
   Standard_Integer I2 = LastUKnotIndex  ();
   
   if ( !uperiodic && (Index <= I1 || Index >= I2) ) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   else if ( uperiodic  && (Index < I1 || Index > I2)) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   
   const TColgp_Array2OfPnt   & oldpoles = poles->Array2();
@@ -1987,10 +1987,10 @@ Standard_Boolean  Geom_BSplineSurface::RemoveVKnot
   Standard_Integer I2 = LastVKnotIndex  ();
   
   if ( !vperiodic && (Index <= I1 || Index >= I2) ) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   else if ( vperiodic  && (Index < I1 || Index > I2)) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   
   const TColgp_Array2OfPnt   & oldpoles = poles->Array2();
index 6cba548..e25133d 100644 (file)
@@ -69,7 +69,7 @@ Geom_BezierCurve::Geom_BezierCurve(const TColgp_Array1OfPnt& Poles)
 {
   Standard_Integer nbpoles = Poles.Length();
   if(nbpoles < 2 || nbpoles > (Geom_BezierCurve::MaxDegree() + 1))
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   //  copy the poles
   Handle(TColgp_HArray1OfPnt) npoles =
     new TColgp_HArray1OfPnt(1,nbpoles);
@@ -92,7 +92,7 @@ Geom_BezierCurve::Geom_BezierCurve(const TColgp_Array1OfPnt&  Poles,
   // copy the poles
   Standard_Integer nbpoles = Poles.Length();
   if(nbpoles < 2 || nbpoles > (Geom_BezierCurve::MaxDegree() + 1))
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
 
   Handle(TColgp_HArray1OfPnt) npoles =
     new TColgp_HArray1OfPnt(1,nbpoles);
@@ -103,12 +103,12 @@ Geom_BezierCurve::Geom_BezierCurve(const TColgp_Array1OfPnt&  Poles,
   // check  the weights
 
   if (Weights.Length() != nbpoles)
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
 
   Standard_Integer i;
   for (i = 1; i <= nbpoles; i++) {
     if (Weights(i) <= gp::Resolution()) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   }
   
@@ -137,7 +137,7 @@ void Geom_BezierCurve::Increase (const Standard_Integer Deg)
 
   if(Deg < Degree() ||
      Deg > Geom_BezierCurve::MaxDegree()) 
-    Standard_ConstructionError::Raise("Geom_BezierCurve::Increase");
+    throw Standard_ConstructionError("Geom_BezierCurve::Increase");
 
   Handle(TColgp_HArray1OfPnt) npoles =
     new TColgp_HArray1OfPnt(1,Deg+1);
@@ -206,10 +206,10 @@ void Geom_BezierCurve::InsertPoleAfter
 
   if(nbpoles >= Geom_BezierCurve::MaxDegree() ||
      Weight <= gp::Resolution())
-    Standard_ConstructionError::Raise("Geom_BezierCurve::InsertPoleAfter");
+    throw Standard_ConstructionError("Geom_BezierCurve::InsertPoleAfter");
 
   if(Index < 0 || Index > nbpoles)
-    Standard_OutOfRange::Raise("Geom_BezierCurve::InsertPoleAfter");
+    throw Standard_OutOfRange("Geom_BezierCurve::InsertPoleAfter");
 
   Standard_Integer i;
 
@@ -292,10 +292,10 @@ void Geom_BezierCurve::RemovePole
   Standard_Integer nbpoles = NbPoles();
 
   if(nbpoles <= 2)
-    Standard_ConstructionError::Raise("Geom_BezierCurve::RemovePole");
+    throw Standard_ConstructionError("Geom_BezierCurve::RemovePole");
 
   if(Index < 1 || Index > nbpoles)
-    Standard_OutOfRange::Raise("Geom_BezierCurve::RemovePole");
+    throw Standard_OutOfRange("Geom_BezierCurve::RemovePole");
 
   Standard_Integer i;
 
@@ -406,7 +406,7 @@ void Geom_BezierCurve::SetPole (const Standard_Integer Index,
                                const gp_Pnt& P)
 {
   if(Index < 1 || Index > NbPoles())
-    Standard_OutOfRange::Raise("Geom_BezierCurve::SetPole");
+    throw Standard_OutOfRange("Geom_BezierCurve::SetPole");
   
   TColgp_Array1OfPnt& cpoles = poles->ChangeArray1();
   cpoles(Index) = P;
@@ -440,9 +440,9 @@ void Geom_BezierCurve::SetWeight(const Standard_Integer Index,
   Standard_Integer nbpoles = NbPoles();
   
   if(Index < 1 || Index > nbpoles)
-    Standard_OutOfRange::Raise("Geom_BezierCurve::SetWeight");
+    throw Standard_OutOfRange("Geom_BezierCurve::SetWeight");
   if(Weight <= gp::Resolution ())
-    Standard_ConstructionError::Raise("Geom_BezierCurve::SetWeight");
+    throw Standard_ConstructionError("Geom_BezierCurve::SetWeight");
   
   // compute new rationality
   Standard_Boolean wasrat = IsRational();
@@ -579,7 +579,7 @@ gp_Vec Geom_BezierCurve::DN (const Standard_Real U,
                             const Standard_Integer N) const
 {
   if(N < 1) 
-    Standard_RangeError::Raise("Geom_BezierCurve::DN");
+    throw Standard_RangeError("Geom_BezierCurve::DN");
   gp_Vec V;
 
   TColStd_Array1OfReal bidknots(1,2); bidknots(1) = 0.; bidknots(2) = 1.;
@@ -658,7 +658,7 @@ Standard_Integer Geom_BezierCurve::NbPoles () const
 const gp_Pnt& Geom_BezierCurve::Pole (const Standard_Integer Index) const
 {
   if(Index < 1 || Index > poles->Length()) 
-    Standard_OutOfRange::Raise("Geom_BezierCurve::Pole");
+    throw Standard_OutOfRange("Geom_BezierCurve::Pole");
   return poles->Value(Index);
 }
 
@@ -670,7 +670,7 @@ const gp_Pnt& Geom_BezierCurve::Pole (const Standard_Integer Index) const
 void Geom_BezierCurve::Poles (TColgp_Array1OfPnt& P) const
 {
   if(P.Length() != poles->Length()) 
-    Standard_DimensionError::Raise("Geom_BezierCurve::Poles");
+    throw Standard_DimensionError("Geom_BezierCurve::Poles");
   P = poles->Array1();
 }
 
@@ -694,7 +694,7 @@ Standard_Real Geom_BezierCurve::Weight
 (const Standard_Integer Index) const
 {
   if(Index < 1 || Index > poles->Length()) 
-    Standard_OutOfRange::Raise("Geom_BezierCurve::Weight");
+    throw Standard_OutOfRange("Geom_BezierCurve::Weight");
   if (IsRational())
     return weights->Value(Index);
   else
@@ -712,7 +712,7 @@ void Geom_BezierCurve::Weights
 
   Standard_Integer nbpoles = NbPoles();
   if(W.Length() != nbpoles)
-    Standard_DimensionError::Raise("Geom_BezierCurve::Weights");
+    throw Standard_DimensionError("Geom_BezierCurve::Weights");
   if (IsRational())
     W = weights->Array1();
   else {
index 9d5364f..c6ede95 100644 (file)
@@ -369,7 +369,7 @@ Geom_BezierSurface::Geom_BezierSurface
   Standard_Integer NbVPoles = SurfacePoles.RowLength();
   if (NbUPoles < 2 || NbUPoles > MaxDegree()+1 ||
       NbVPoles < 2 || NbVPoles > MaxDegree()+1) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   
   Handle(TColgp_HArray2OfPnt) npoles = 
@@ -401,7 +401,7 @@ Geom_BezierSurface::Geom_BezierSurface
       NbVPoles < 2 || NbVPoles > MaxDegree()+1 ||
       NbVPoles != PoleWeights.RowLength()      ||
       NbUPoles != PoleWeights.ColLength()      ) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   
   Standard_Integer Row = PoleWeights.LowerRow();
@@ -410,7 +410,7 @@ Geom_BezierSurface::Geom_BezierSurface
     Row = PoleWeights.LowerRow();
     while (Row <= PoleWeights.UpperRow()) {
       if (PoleWeights(Row, Col) <= gp::Resolution()) {
-        Standard_ConstructionError::Raise();
+        throw Standard_ConstructionError();
       }
       Row++;
     }
@@ -542,7 +542,7 @@ void Geom_BezierSurface::Increase (const Standard_Integer UDeg,
 {
   if (UDeg < UDegree() || UDeg > Geom_BezierSurface::MaxDegree() ||
       VDeg < VDegree() || VDeg > Geom_BezierSurface::MaxDegree() )  {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   Standard_Integer oldUDeg = UDegree();
@@ -624,9 +624,9 @@ void Geom_BezierSurface::InsertPoleColAfter
    const TColgp_Array1OfPnt& CPoles)
 {
   const TColgp_Array2OfPnt & Poles = poles->Array2();
-  if (VIndex < 1 || VIndex > Poles.RowLength())  Standard_OutOfRange::Raise();
+  if (VIndex < 1 || VIndex > Poles.RowLength())  throw Standard_OutOfRange();
   if (CPoles.Length() != Poles.ColLength()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   Handle(TColgp_HArray2OfPnt) npoles =
@@ -665,15 +665,15 @@ void Geom_BezierSurface::InsertPoleColAfter
    const TColStd_Array1OfReal& CPoleWeights)
 {
   const TColgp_Array2OfPnt & Poles = poles->Array2();
-  if (VIndex < 1 || VIndex > Poles.RowLength())  Standard_OutOfRange::Raise();
+  if (VIndex < 1 || VIndex > Poles.RowLength())  throw Standard_OutOfRange();
   if (CPoles.Length() != Poles.ColLength() ||
       CPoleWeights.Length() != CPoles.Length()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
     }
   Standard_Integer Index = CPoleWeights.Lower();
   while (Index <= CPoleWeights.Upper()) {
     if (CPoleWeights (Index) <= gp::Resolution()) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
       }
     Index++;
   }
@@ -727,9 +727,9 @@ void Geom_BezierSurface::InsertPoleRowAfter (const Standard_Integer UIndex,
                                             const TColgp_Array1OfPnt& CPoles)
 {
   const TColgp_Array2OfPnt & Poles = poles->Array2();
-  if (UIndex < 1 || UIndex > Poles.ColLength())  Standard_OutOfRange::Raise();
+  if (UIndex < 1 || UIndex > Poles.ColLength())  throw Standard_OutOfRange();
   if (CPoles.Length() != Poles.RowLength()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   Handle(TColgp_HArray2OfPnt) npoles =
@@ -770,15 +770,15 @@ void Geom_BezierSurface::InsertPoleRowAfter
    const TColStd_Array1OfReal& CPoleWeights)
 {
   const TColgp_Array2OfPnt & Poles = poles->Array2();
-  if (UIndex < 1 || UIndex > Poles.ColLength())  Standard_OutOfRange::Raise();
+  if (UIndex < 1 || UIndex > Poles.ColLength())  throw Standard_OutOfRange();
   if (CPoles.Length() != Poles.RowLength() ||
       CPoleWeights.Length() != CPoles.Length()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   Standard_Integer Index = CPoleWeights.Lower();
   while (Index <= CPoleWeights.Upper()) {
     if (CPoleWeights(Index) <= gp::Resolution()) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
     Index++;
   }
@@ -831,8 +831,8 @@ void Geom_BezierSurface::InsertPoleRowBefore
 void Geom_BezierSurface::RemovePoleCol (const Standard_Integer VIndex)
 {
   const TColgp_Array2OfPnt & Poles = poles->Array2();
-  if (VIndex < 1 || VIndex > Poles.RowLength())  Standard_OutOfRange::Raise(); 
-  if (Poles.RowLength() <= 2)             Standard_ConstructionError::Raise();
+  if (VIndex < 1 || VIndex > Poles.RowLength())  throw Standard_OutOfRange();
+  if (Poles.RowLength() <= 2)             throw Standard_ConstructionError();
 
   Handle(TColgp_HArray2OfPnt) npoles =
     new TColgp_HArray2OfPnt(1,poles->ColLength(),1,poles->RowLength()-1);
@@ -866,8 +866,8 @@ void Geom_BezierSurface::RemovePoleCol (const Standard_Integer VIndex)
 void Geom_BezierSurface::RemovePoleRow (const Standard_Integer UIndex)
 {
   const TColgp_Array2OfPnt & Poles = poles->Array2();
-  if (UIndex < 1 || UIndex > Poles.ColLength()) Standard_OutOfRange::Raise();
-  if (Poles.ColLength() <= 2)            Standard_ConstructionError::Raise();
+  if (UIndex < 1 || UIndex > Poles.ColLength()) throw Standard_OutOfRange();
+  if (Poles.ColLength() <= 2)            throw Standard_ConstructionError();
 
   Handle(TColgp_HArray2OfPnt) npoles =
     new TColgp_HArray2OfPnt(1,poles->ColLength()-1,1,poles->RowLength());
@@ -1000,7 +1000,7 @@ void Geom_BezierSurface::SetPole
   if (UIndex < 1                 ||
       UIndex > Poles.ColLength() ||
       VIndex < 1                 ||
-      VIndex > Poles.RowLength() )    Standard_OutOfRange::Raise();
+      VIndex > Poles.RowLength() )    throw Standard_OutOfRange();
   
   Poles (UIndex, VIndex) = P;
 }
@@ -1018,12 +1018,12 @@ void Geom_BezierSurface::SetPole
 {
 
   if (Weight <= gp::Resolution())     
-    Standard_ConstructionError::Raise("Geom_BezierSurface::SetPole");
+    throw Standard_ConstructionError("Geom_BezierSurface::SetPole");
   if (UIndex < 1                 || 
       UIndex > poles->ColLength() ||
       VIndex < 1                 ||
       VIndex > poles->RowLength())    
-    Standard_OutOfRange::Raise("Geom_BezierSurface::SetPole");
+    throw Standard_OutOfRange("Geom_BezierSurface::SetPole");
 
   poles->SetValue(UIndex, VIndex, P);
   
@@ -1041,7 +1041,7 @@ void Geom_BezierSurface::SetPoleCol
    const TColStd_Array1OfReal& CPoleWeights)
 {
   TColgp_Array2OfPnt & Poles = poles->ChangeArray2();
-  if (VIndex < 1 || VIndex > Poles.RowLength()) Standard_OutOfRange::Raise();
+  if (VIndex < 1 || VIndex > Poles.RowLength()) throw Standard_OutOfRange();
 
   if (CPoles.Lower() < 1                     || 
       CPoles.Lower() > Poles.ColLength()     || 
@@ -1049,7 +1049,7 @@ void Geom_BezierSurface::SetPoleCol
       CPoles.Upper() > Poles.ColLength()     ||
       CPoleWeights.Lower() != CPoles.Lower() ||
       CPoleWeights.Upper() != CPoles.Upper()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
      
   Standard_Integer I;
@@ -1068,13 +1068,13 @@ void Geom_BezierSurface::SetPoleCol (const Standard_Integer      VIndex,
                                     const TColgp_Array1OfPnt&   CPoles)
 {
   TColgp_Array2OfPnt & Poles = poles->ChangeArray2();
-  if (VIndex < 1 || VIndex > Poles.RowLength())  Standard_OutOfRange::Raise();
+  if (VIndex < 1 || VIndex > Poles.RowLength())  throw Standard_OutOfRange();
 
   if (CPoles.Lower() < 1                 || 
       CPoles.Lower() > Poles.ColLength() || 
       CPoles.Upper() < 1                 ||
       CPoles.Upper() > Poles.ColLength()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   for (Standard_Integer I = CPoles.Lower(); I <= CPoles.Upper(); I++) {
     Poles (I, VIndex) = CPoles (I);
@@ -1090,12 +1090,12 @@ void Geom_BezierSurface::SetPoleRow (const Standard_Integer    UIndex,
                                     const TColgp_Array1OfPnt& CPoles)
 {
   TColgp_Array2OfPnt & Poles = poles->ChangeArray2();
-  if (UIndex < 1 || UIndex > Poles.ColLength())  Standard_OutOfRange::Raise();
+  if (UIndex < 1 || UIndex > Poles.ColLength())  throw Standard_OutOfRange();
 
   if (CPoles.Lower() < 1                 ||
       CPoles.Lower() > Poles.RowLength() || 
       CPoles.Upper() < 1                 || 
-      CPoles.Upper() > Poles.RowLength())  Standard_ConstructionError::Raise();
+      CPoles.Upper() > Poles.RowLength())  throw Standard_ConstructionError();
 
   for (Standard_Integer I = CPoles.Lower(); I <= CPoles.Upper(); I++) {
     Poles (UIndex, I) = CPoles (I);
@@ -1113,7 +1113,7 @@ void Geom_BezierSurface::SetPoleRow
    const TColStd_Array1OfReal& CPoleWeights)
 {
   TColgp_Array2OfPnt & Poles = poles->ChangeArray2();
-  if (UIndex < 1 || UIndex > Poles.ColLength())   Standard_OutOfRange::Raise();
+  if (UIndex < 1 || UIndex > Poles.ColLength())   throw Standard_OutOfRange();
 
   if (CPoles.Lower() < 1                     || 
       CPoles.Lower() > Poles.RowLength()     || 
@@ -1121,7 +1121,7 @@ void Geom_BezierSurface::SetPoleRow
       CPoles.Upper() > Poles.RowLength()     ||
       CPoleWeights.Lower() != CPoles.Lower() ||
       CPoleWeights.Upper() != CPoles.Upper()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   Standard_Integer I;
@@ -1156,12 +1156,12 @@ void Geom_BezierSurface::SetWeight (const Standard_Integer UIndex,
 
   TColStd_Array2OfReal & Weights = weights->ChangeArray2();
   if (Weight <= gp::Resolution())      
-    Standard_ConstructionError::Raise("Geom_BezierSurface::SetWeight");
+    throw Standard_ConstructionError("Geom_BezierSurface::SetWeight");
 
   if (UIndex < 1                   || 
       UIndex > Weights.ColLength() ||
       VIndex < 1                   || 
-      VIndex > Weights.RowLength())    Standard_OutOfRange::Raise();
+      VIndex > Weights.RowLength())    throw Standard_OutOfRange();
 
   if (Abs (Weight - Weights (UIndex, VIndex)) > gp::Resolution()) {
     Weights (UIndex, VIndex) = Weight;
@@ -1192,16 +1192,16 @@ void Geom_BezierSurface::SetWeightCol
   }
 
   TColStd_Array2OfReal & Weights = weights->ChangeArray2();
-  if (VIndex < 1 || VIndex > Weights.RowLength()) Standard_OutOfRange::Raise();
+  if (VIndex < 1 || VIndex > Weights.RowLength()) throw Standard_OutOfRange();
 
   if (CPoleWeights.Length() !=  Weights.ColLength())  {
-    Standard_ConstructionError::Raise("Geom_BezierSurface::SetWeightCol");
+    throw Standard_ConstructionError("Geom_BezierSurface::SetWeightCol");
   }
 
   I = CPoleWeights.Lower();
   while (I <= CPoleWeights.Upper()) {
     if (CPoleWeights(I) <= gp::Resolution()) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
     Weights (I, VIndex) = CPoleWeights (I);
     I++;
@@ -1234,18 +1234,18 @@ void Geom_BezierSurface::SetWeightRow
 
   TColStd_Array2OfReal & Weights = weights->ChangeArray2();
   if (UIndex < 1 || UIndex > Weights.ColLength()) 
-    Standard_OutOfRange::Raise("Geom_BezierSurface::SetWeightRow");
+    throw Standard_OutOfRange("Geom_BezierSurface::SetWeightRow");
   if (CPoleWeights.Lower() < 1 ||
       CPoleWeights.Lower() > Weights.RowLength() ||
       CPoleWeights.Upper() < 1 ||
       CPoleWeights.Upper() > Weights.RowLength()  ) {
-    Standard_ConstructionError::Raise("Geom_BezierSurface::SetWeightRow");
+    throw Standard_ConstructionError("Geom_BezierSurface::SetWeightRow");
   }
 
   I = CPoleWeights.Lower();
   while (I <= CPoleWeights.Upper()) {
     if (CPoleWeights(I) <= gp::Resolution())  {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
     Weights (UIndex, I) = CPoleWeights (I);
     I++;
index eb8da30..2ed3d42 100644 (file)
@@ -71,7 +71,7 @@ Geom_Circle::Geom_Circle (const gp_Circ& C) : radius (C.Radius()) {
 
 Geom_Circle::Geom_Circle (const Ax2& A2, const Standard_Real R) : radius (R) {
 
-  if (R < 0.0) Standard_ConstructionError::Raise();
+  if (R < 0.0) throw Standard_ConstructionError();
   pos = A2;
 }
 
@@ -153,7 +153,7 @@ void Geom_Circle::SetCirc (const gp_Circ& C) {
 
 void Geom_Circle::SetRadius (const Standard_Real R) { 
 
-   if (R < 0.0)  Standard_ConstructionError::Raise();
+   if (R < 0.0)  throw Standard_ConstructionError();
    radius = R;
 }
 
index 2f7292f..5dd0e70 100644 (file)
@@ -77,7 +77,7 @@ Geom_ConicalSurface::Geom_ConicalSurface ( const Ax3& A3 ,
 {
 
   if (R < 0.0 || Abs(Ang) <= gp::Resolution() || Abs(Ang) >= M_PI/2.0 - gp::Resolution()) 
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   
   pos = A3;
 }
@@ -206,7 +206,7 @@ void Geom_ConicalSurface::SetCone (const gp_Cone& C) {
 
 void Geom_ConicalSurface::SetRadius (const Standard_Real R) {
 
-  if (R < 0.0)  Standard_ConstructionError::Raise();
+  if (R < 0.0)  throw Standard_ConstructionError();
   radius = R;
 }
 
@@ -219,7 +219,7 @@ void Geom_ConicalSurface::SetRadius (const Standard_Real R) {
 void Geom_ConicalSurface::SetSemiAngle (const Standard_Real Ang) {
 
   if (Abs(Ang) <= gp::Resolution() || Abs(Ang) >= M_PI/2.0 - gp::Resolution()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   semiAngle = Ang;
 }
index bb01d90..dd500cb 100644 (file)
@@ -89,7 +89,7 @@ Geom_CylindricalSurface::Geom_CylindricalSurface ( const Ax3& A3,
                                                   const Standard_Real R) 
 : radius (R) {
 
-  if (R < 0.0) Standard_ConstructionError::Raise();
+  if (R < 0.0) throw Standard_ConstructionError();
   pos = A3;
 }
 
@@ -168,7 +168,7 @@ void Geom_CylindricalSurface::SetCylinder (const gp_Cylinder& C) {
 
 void Geom_CylindricalSurface::SetRadius (const Standard_Real R) {
 
-  if (R < 0.0) { Standard_ConstructionError::Raise(); }
+  if (R < 0.0) { throw Standard_ConstructionError(); }
   radius = R;
 }
 
index 89b0289..296bb01 100644 (file)
@@ -77,7 +77,7 @@ Geom_Ellipse::Geom_Ellipse ( const Ax2& A,
   : majorRadius (MajorRadius), minorRadius (MinorRadius) {
 
    if (MajorRadius < MinorRadius || MinorRadius < 0.0 ) {
-     Standard_ConstructionError::Raise();
+     throw Standard_ConstructionError();
    }
    pos = A;
 }
@@ -145,7 +145,7 @@ void Geom_Ellipse::SetElips (const gp_Elips& E) {
 
 void Geom_Ellipse::SetMajorRadius (const Standard_Real MajorRadius) {
 
-  if (MajorRadius < minorRadius)  Standard_ConstructionError::Raise ();
+  if (MajorRadius < minorRadius)  throw Standard_ConstructionError();
   else                            majorRadius = MajorRadius; 
 }
 
@@ -158,7 +158,7 @@ void Geom_Ellipse::SetMajorRadius (const Standard_Real MajorRadius) {
 void Geom_Ellipse::SetMinorRadius (const Standard_Real MinorRadius) {
 
    if (MinorRadius < 0 || majorRadius < MinorRadius) {
-     Standard_ConstructionError::Raise();
+     throw Standard_ConstructionError();
    }
    else { minorRadius = MinorRadius; }
 }
index 43d963a..1b6e53d 100644 (file)
@@ -37,8 +37,7 @@ typedef gp_Trsf               Trsf;
 Handle(Geom_Geometry) Geom_Geometry::Copy() const {
 
    Handle(Geom_Geometry) G;
-   Standard_ConstructionError::Raise();
-   return G;
+   throw Standard_ConstructionError();
 }
 
 
index f46cc92..9c06858 100644 (file)
@@ -79,7 +79,7 @@ Geom_Hyperbola::Geom_Hyperbola ( const Ax2& A,
  : majorRadius (MajorRadius), minorRadius (MinorRadius) {
 
   if (MajorRadius < 0.0 || MinorRadius < 0.0) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   pos = A;
 }
@@ -148,7 +148,7 @@ void Geom_Hyperbola::SetHypr (const gp_Hypr& H) {
 
 void Geom_Hyperbola::SetMajorRadius (const Standard_Real MajorRadius) {
 
-  if (MajorRadius < 0.0) Standard_ConstructionError::Raise();
+  if (MajorRadius < 0.0) throw Standard_ConstructionError();
   else                   majorRadius = MajorRadius;
 }
 
@@ -160,7 +160,7 @@ void Geom_Hyperbola::SetMajorRadius (const Standard_Real MajorRadius) {
 
 void Geom_Hyperbola::SetMinorRadius (const Standard_Real MinorRadius) {
 
-  if (MinorRadius < 0.0)  Standard_ConstructionError::Raise();
+  if (MinorRadius < 0.0)  throw Standard_ConstructionError();
   else                    minorRadius = MinorRadius;
 }
 
index 4b3a0ae..5bdffdd 100644 (file)
@@ -218,7 +218,7 @@ void Geom_OffsetCurve::SetBasisCurve (const Handle(Geom_Curve)& C,
 
     // Raise exception if still C0
     if (isC0)
-      Standard_ConstructionError::Raise("Offset on C0 curve");
+      throw Standard_ConstructionError("Offset on C0 curve");
   }
   //
   if(isTrimmed)
@@ -333,7 +333,7 @@ gp_Vec Geom_OffsetCurve::DN (const Standard_Real U, const Standard_Integer N) co
       D3( U, Ptemp, Vtemp, Vtemp, VN);
       break;
     default:
-      Standard_NotImplemented::Raise("Exception: "
+      throw Standard_NotImplemented("Exception: "
         "Derivative order is greater than 3. Cannot compute of derivative.");
   }
   
index 156f2fd..207deca 100644 (file)
@@ -206,7 +206,7 @@ void Geom_OffsetSurface::SetBasisSurface (const Handle(Geom_Surface)& S,
 
     // Raise exception if still C0
     if (isC0)
-      Standard_ConstructionError::Raise("Offset with no C1 Surface");
+      throw Standard_ConstructionError("Offset with no C1 Surface");
   }
 
   if(isTrimmed)
@@ -341,7 +341,7 @@ void Geom_OffsetSurface::D0 (const Standard_Real U, const Standard_Real V, gp_Pn
 {
 #ifdef CHECK  
   if (myBasisSurfContinuity == GeomAbs_C0)
-    Geom_UndefinedValue::Raise();
+    throw Geom_UndefinedValue();
 #endif
   if (equivSurf.IsNull())
     myEvaluator->D0(U, V, P);
@@ -361,7 +361,7 @@ void Geom_OffsetSurface::D1 (const Standard_Real U, const Standard_Real V,
 #ifdef CHECK  
   if (myBasisSurfContinuity == GeomAbs_C0 ||
       myBasisSurfContinuity == GeomAbs_C1)
-    Geom_UndefinedDerivative::Raise();
+    throw Geom_UndefinedDerivative();
 #endif
   if (equivSurf.IsNull())
     myEvaluator->D1(U, V, P, D1U, D1V);
@@ -383,7 +383,7 @@ void Geom_OffsetSurface::D2 (const Standard_Real U, const Standard_Real V,
   if (myBasisSurfContinuity == GeomAbs_C0 ||
       myBasisSurfContinuity == GeomAbs_C1 ||
       myBasisSurfContinuity == GeomAbs_C2)
-    Geom_UndefinedDerivative::Raise();
+    throw Geom_UndefinedDerivative();
 #endif
   if (equivSurf.IsNull())
     myEvaluator->D2(U, V, P, D1U, D1V, D2U, D2V, D2UV);
@@ -404,7 +404,7 @@ void Geom_OffsetSurface::D3 (const Standard_Real U, const Standard_Real V,
 {
 #ifdef CHECK  
   if (!(basisSurf->IsCNu (4) && basisSurf->IsCNv (4))) { 
-    Geom_UndefinedDerivative::Raise();
+    throw Geom_UndefinedDerivative();
   }
 #endif
   if (equivSurf.IsNull())
@@ -424,7 +424,7 @@ gp_Vec Geom_OffsetSurface::DN (const Standard_Real    U, const Standard_Real
   Standard_RangeError_Raise_if (Nu < 0 || Nv < 0 || Nu + Nv < 1, " ");
 #ifdef CHECK  
   if (!(basisSurf->IsCNu (Nu) && basisSurf->IsCNv (Nv))) { 
-    Geom_UndefinedDerivative::Raise();
+    throw Geom_UndefinedDerivative();
   }
 #endif  
   gp_Vec D(0,0,0);
index 9357b08..df217d5 100644 (file)
@@ -464,7 +464,7 @@ Standard_Boolean  Geom_OsculatingSurface::BuildOsculatingSurface
 #ifdef OCCT_DEBUG
     cout<<" surface osculatrice nulle "<<endl;
 #endif
-    //Standard_ConstructionError::Raise("Geom_OsculatingSurface");
+    //throw Standard_ConstructionError("Geom_OsculatingSurface");
     OsculSurf=Standard_False;
   }
   else
index ee9b455..4115c29 100644 (file)
@@ -72,7 +72,7 @@ Geom_Parabola::Geom_Parabola (const gp_Parab& Prb)
 Geom_Parabola::Geom_Parabola (const Ax2& A2, const Standard_Real Focal) 
  : focalLength (Focal) {
    
-  if(Focal < 0.0)  Standard_ConstructionError::Raise();
+  if(Focal < 0.0)  throw Standard_ConstructionError();
   pos = A2;
 }
 
@@ -158,7 +158,7 @@ Standard_Real Geom_Parabola::Parameter () const         { return 2.0 * focalLeng
 
 void Geom_Parabola::SetFocal (const Standard_Real Focal) {
 
-   if (Focal < 0.0)  Standard_ConstructionError::Raise();
+   if (Focal < 0.0)  throw Standard_ConstructionError();
    focalLength = Focal;
 }
 
index fc2ba15..eec0b8a 100644 (file)
@@ -235,8 +235,7 @@ void Geom_RectangularTrimmedSurface::SetTrim(const Standard_Real U1,
   }
   else {
     if ( U1 == U2)
-      Standard_ConstructionError::Raise
-       ("Geom_RectangularTrimmedSurface::U1==U2");
+      throw Standard_ConstructionError("Geom_RectangularTrimmedSurface::U1==U2");
 
     if (basisSurf->IsUPeriodic()) {
       UsameSense = USense;
@@ -263,8 +262,7 @@ void Geom_RectangularTrimmedSurface::SetTrim(const Standard_Real U1,
       
       if ((Udeb-utrim1 > Precision::PConfusion()) ||
          (utrim2-Ufin > Precision::PConfusion()))
-       Standard_ConstructionError::Raise
-         ("Geom_RectangularTrimmedSurface::U parameters out of range");
+       throw Standard_ConstructionError("Geom_RectangularTrimmedSurface::U parameters out of range");
 
     }
   }
@@ -277,8 +275,7 @@ void Geom_RectangularTrimmedSurface::SetTrim(const Standard_Real U1,
   }
   else {
     if ( V1 == V2)
-      Standard_ConstructionError::Raise
-       ("Geom_RectangularTrimmedSurface::V1==V2");
+      throw Standard_ConstructionError("Geom_RectangularTrimmedSurface::V1==V2");
 
     if (basisSurf->IsVPeriodic()) {
       VsameSense = VSense;
@@ -305,8 +302,7 @@ void Geom_RectangularTrimmedSurface::SetTrim(const Standard_Real U1,
       
       if ((Vdeb-vtrim1 > Precision::PConfusion()) ||
          (vtrim2-Vfin > Precision::PConfusion()))
-       Standard_ConstructionError::Raise
-         ("Geom_RectangularTrimmedSurface::V parameters out of range");
+       throw Standard_ConstructionError("Geom_RectangularTrimmedSurface::V parameters out of range");
 
     }
   }
index 22aea20..a373e59 100644 (file)
@@ -67,7 +67,7 @@ Handle(Geom_Geometry) Geom_SphericalSurface::Copy () const {
 Geom_SphericalSurface::Geom_SphericalSurface (const Ax3& A, const Standard_Real R) 
 : radius (R) {
 
-  if (R < 0.0) Standard_ConstructionError::Raise();
+  if (R < 0.0) throw Standard_ConstructionError();
   pos = A;
 }
 
@@ -161,7 +161,7 @@ Standard_Boolean Geom_SphericalSurface::IsVPeriodic () const
 
 void Geom_SphericalSurface::SetRadius (const Standard_Real R) {
 
-  if (R < 0.0) { Standard_ConstructionError::Raise(); }
+  if (R < 0.0) { throw Standard_ConstructionError(); }
   radius = R;
 }
 
index 2f82001..d1b86e4 100644 (file)
@@ -363,8 +363,7 @@ Vec Geom_SurfaceOfRevolution::DN (const Standard_Real    U , const Standard_Real
 
 Ax2 Geom_SurfaceOfRevolution::ReferencePlane() const {
         
-   Standard_NotImplemented::Raise ();
-   return gp_Ax2();
+   throw Standard_NotImplemented();
 }
 
 
index 6e08a4c..2cba526 100644 (file)
@@ -78,7 +78,7 @@ Geom_ToroidalSurface::Geom_ToroidalSurface
 : majorRadius (MajorRadius), minorRadius (MinorRadius) {
 
   if (MinorRadius < 0.0 || MajorRadius < 0.0) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   else {
     pos = A3;
@@ -192,7 +192,7 @@ Standard_Boolean Geom_ToroidalSurface::IsVPeriodic () const {
 void Geom_ToroidalSurface::SetMajorRadius (const Standard_Real MajorRadius) {
 
   if (MajorRadius - minorRadius <= gp::Resolution())
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   else 
     majorRadius = MajorRadius;
 }
@@ -206,7 +206,7 @@ void Geom_ToroidalSurface::SetMajorRadius (const Standard_Real MajorRadius) {
 void Geom_ToroidalSurface::SetMinorRadius (const Standard_Real MinorRadius) {
 
   if (MinorRadius < 0.0 || majorRadius - MinorRadius <= gp::Resolution())
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   else 
     minorRadius = MinorRadius;
 }
index 6fe4d6a..7fc9347 100644 (file)
@@ -121,7 +121,7 @@ void Geom_TrimmedCurve::SetTrim (const Standard_Real U1,
 {
    Standard_Boolean sameSense = Standard_True;
    if (U1 == U2) 
-     Standard_ConstructionError::Raise("Geom_TrimmedCurve::U1 == U2");
+     throw Standard_ConstructionError("Geom_TrimmedCurve::U1 == U2");
 
    Standard_Real Udeb = basisCurve->FirstParameter();
    Standard_Real Ufin = basisCurve->LastParameter();
@@ -153,8 +153,7 @@ void Geom_TrimmedCurve::SetTrim (const Standard_Real U1,
 
      if ((Udeb - uTrim1 > Precision::PConfusion()) ||
         (uTrim2 - Ufin > Precision::PConfusion()))
-      Standard_ConstructionError::Raise
-       ("Geom_TrimmedCurve::parameters out of range");
+      throw Standard_ConstructionError("Geom_TrimmedCurve::parameters out of range");
        
 
    }
index 9c177e7..fcd2bc3 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Geom_UndefinedDerivative, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Geom_UndefinedDerivative
   #define Geom_UndefinedDerivative_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Geom_UndefinedDerivative::Raise(MESSAGE);
+  if (CONDITION) throw Geom_UndefinedDerivative(MESSAGE);
 #else
   #define Geom_UndefinedDerivative_Raise_if(CONDITION, MESSAGE)
 #endif
index 255d280..173084d 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Geom_UndefinedValue, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Geom_UndefinedValue
   #define Geom_UndefinedValue_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Geom_UndefinedValue::Raise(MESSAGE);
+  if (CONDITION) throw Geom_UndefinedValue(MESSAGE);
 #else
   #define Geom_UndefinedValue_Raise_if(CONDITION, MESSAGE)
 #endif
index 163276a..b4cc7df 100644 (file)
@@ -63,20 +63,20 @@ static void CheckCurveData
  const Standard_Boolean            Periodic)
 {
   if (Degree < 1 || Degree > Geom2d_BSplineCurve::MaxDegree()) {
-    Standard_ConstructionError::Raise("BSpline curve : invalid degree");  
+    throw Standard_ConstructionError("BSpline curve : invalid degree");
   }
   
-  if (CPoles.Length() < 2)                Standard_ConstructionError::Raise("BSpline curve : at least 2 poles required");
-  if (CKnots.Length() != CMults.Length()) Standard_ConstructionError::Raise("BSpline curve : Knot and Mult array size mismatch");
+  if (CPoles.Length() < 2)                throw Standard_ConstructionError("BSpline curve : at least 2 poles required");
+  if (CKnots.Length() != CMults.Length()) throw Standard_ConstructionError("BSpline curve : Knot and Mult array size mismatch");
   
   for (Standard_Integer I = CKnots.Lower(); I < CKnots.Upper(); I++) {
     if (CKnots (I+1) - CKnots (I) <= Epsilon (Abs(CKnots (I)))) {
-      Standard_ConstructionError::Raise("BSpline curve : Knots interval values too close");
+      throw Standard_ConstructionError("BSpline curve : Knots interval values too close");
     }
   }
   
   if (CPoles.Length() != BSplCLib::NbPoles(Degree,Periodic,CMults))
-    Standard_ConstructionError::Raise("BSpline curve : # Poles and degree mismatch");
+    throw Standard_ConstructionError("BSpline curve : # Poles and degree mismatch");
 }
 
 //=======================================================================
@@ -183,12 +183,12 @@ Geom2d_BSplineCurve::Geom2d_BSplineCurve
                  Periodic);
 
   if (Weights.Length() != Poles.Length())
-    Standard_ConstructionError::Raise("Geom2d_BSplineCurve :Weights and Poles array size mismatch");
+    throw Standard_ConstructionError("Geom2d_BSplineCurve :Weights and Poles array size mismatch");
 
   Standard_Integer i;
   for (i = Weights.Lower(); i <= Weights.Upper(); i++) {
     if (Weights(i) <= gp::Resolution()) {
-      Standard_ConstructionError::Raise("Geom2d_BSplineCurve: Weights values too small");
+      throw Standard_ConstructionError("Geom2d_BSplineCurve: Weights values too small");
     }
   }
   
@@ -234,7 +234,7 @@ void Geom2d_BSplineCurve::IncreaseDegree
   if (Degree == deg) return;
 
   if (Degree < deg || Degree > Geom2d_BSplineCurve::MaxDegree()) {
-    Standard_ConstructionError::Raise("BSpline curve : IncreaseDegree : bad degree value");
+    throw Standard_ConstructionError("BSpline curve : IncreaseDegree : bad degree value");
   }
 
   Standard_Integer FromK1 = FirstUKnotIndex ();
@@ -371,7 +371,7 @@ void  Geom2d_BSplineCurve::InsertKnots(const TColStd_Array1OfReal& Knots,
   if (!BSplCLib::PrepareInsertKnots(deg,periodic,
                                    knots->Array1(),mults->Array1(),
                                    Knots,&Mults,nbpoles,nbknots,Epsilon,Add))
-    Standard_ConstructionError::Raise("Geom2d_BSplineCurve::InsertKnots");
+    throw Standard_ConstructionError("Geom2d_BSplineCurve::InsertKnots");
 
   if (nbpoles == poles->Length()) return;
 
@@ -431,7 +431,7 @@ Standard_Boolean  Geom2d_BSplineCurve::RemoveKnot
   Standard_Integer I2  = LastUKnotIndex  ();
 
   if (Index < I1 || Index > I2)  {
-    Standard_OutOfRange::Raise("BSpline curve : RemoveKnot : index out of range");
+    throw Standard_OutOfRange("BSpline curve : RemoveKnot : index out of range");
   }
   
   const TColgp_Array1OfPnt2d & oldpoles   = poles->Array1();
@@ -495,12 +495,12 @@ void Geom2d_BSplineCurve::InsertPoleAfter
  const gp_Pnt2d& P,
  const Standard_Real Weight)
 {
-  if (Index < 0 || Index > poles->Length())  Standard_OutOfRange::Raise("BSpline curve : InsertPoleAfter: Index and #pole mismatch");
+  if (Index < 0 || Index > poles->Length())  throw Standard_OutOfRange("BSpline curve : InsertPoleAfter: Index and #pole mismatch");
 
-  if (Weight <= gp::Resolution())     Standard_ConstructionError::Raise("BSpline curve : InsertPoleAfter: Weight too small");
+  if (Weight <= gp::Resolution())     throw Standard_ConstructionError("BSpline curve : InsertPoleAfter: Weight too small");
 
   if (knotSet == GeomAbs_NonUniform || knotSet == GeomAbs_PiecewiseBezier) {
-    Standard_ConstructionError::Raise("BSpline curve : InsertPoleAfter : bad knotSet type");
+    throw Standard_ConstructionError("BSpline curve : InsertPoleAfter : bad knotSet type");
   }
 
   const TColStd_Array1OfReal& cknots   = knots->Array1();
@@ -597,12 +597,12 @@ void Geom2d_BSplineCurve::InsertPoleBefore
 void Geom2d_BSplineCurve::RemovePole
 (const Standard_Integer Index)
 {
-  if (Index < 1 || Index > poles->Length())  Standard_OutOfRange::Raise("BSpline curve :RemovePole : Index and #pole mismatch");
+  if (Index < 1 || Index > poles->Length())  throw Standard_OutOfRange("BSpline curve :RemovePole : Index and #pole mismatch");
 
-  if (poles->Length() <= 2)           Standard_ConstructionError::Raise("BSpline curve : RemovePole : #pole is already minimum");
+  if (poles->Length() <= 2)           throw Standard_ConstructionError("BSpline curve : RemovePole : #pole is already minimum");
 
   if (knotSet == GeomAbs_NonUniform || knotSet == GeomAbs_PiecewiseBezier) 
-    Standard_ConstructionError::Raise("BSpline curve : RemovePole: bad knotSet type");
+    throw Standard_ConstructionError("BSpline curve : RemovePole: bad knotSet type");
 
   Standard_Integer i;
   Handle(TColStd_HArray1OfReal) nknots =
@@ -686,7 +686,7 @@ void Geom2d_BSplineCurve::Segment(const Standard_Real aU1,
                                  const Standard_Real aU2)
 {
   if (aU2 < aU1)
-    Standard_DomainError::Raise("Geom2d_BSplineCurve::Segment");
+    throw Standard_DomainError("Geom2d_BSplineCurve::Segment");
   //
   Standard_Real AbsUMax = Max(Abs(FirstParameter()),Abs(LastParameter()));
   Standard_Real Eps = Max (Epsilon(AbsUMax), Precision::PConfusion());
@@ -727,7 +727,7 @@ void Geom2d_BSplineCurve::Segment(const Standard_Real aU1,
     Standard_Real Period = LastParameter() - FirstParameter();
     DU = U2 - U1;
     if (DU - Period > Precision::PConfusion())
-      Standard_DomainError::Raise("Geom2d_BSplineCurve::Segment");
+      throw Standard_DomainError("Geom2d_BSplineCurve::Segment");
     if (DU > Period)
       DU = Period;
   }
@@ -845,20 +845,20 @@ void Geom2d_BSplineCurve::SetKnot
 (const Standard_Integer Index,
  const Standard_Real K)
 {
-  if (Index < 1 || Index > knots->Length())     Standard_OutOfRange::Raise("BSpline curve : SetKnot:  Index and #pole mismatch");
+  if (Index < 1 || Index > knots->Length())     throw Standard_OutOfRange("BSpline curve : SetKnot:  Index and #pole mismatch");
   Standard_Real DK = Abs(Epsilon (K));
   if (Index == 1) { 
-    if (K >= knots->Value(2) - DK) Standard_ConstructionError::Raise("BSpline curve :SetKnot :K out of range");
+    if (K >= knots->Value(2) - DK) throw Standard_ConstructionError("BSpline curve :SetKnot :K out of range");
   }
   else if (Index == knots->Length()) {
     if (K <= knots->Value (knots->Length()-1) + DK)  {
-      Standard_ConstructionError::Raise("BSpline curve : SetKnot : K out of range");
+      throw Standard_ConstructionError("BSpline curve : SetKnot : K out of range");
     }
   }
   else {
     if (K <= knots->Value(Index-1) + DK ||
        K >= knots->Value(Index+1) - DK ) {
-      Standard_ConstructionError::Raise("BSpline curve : SetKnot: K out of range");
+      throw Standard_ConstructionError("BSpline curve : SetKnot: K out of range");
     }
   }
   if (K != knots->Value (Index)) {
@@ -946,13 +946,13 @@ void Geom2d_BSplineCurve::SetPeriodic ()
 void Geom2d_BSplineCurve::SetOrigin(const Standard_Integer Index)
 {
   if (!periodic)
-    Standard_NoSuchObject::Raise("Geom2d_BSplineCurve::SetOrigin");
+    throw Standard_NoSuchObject("Geom2d_BSplineCurve::SetOrigin");
   Standard_Integer i,k;
   Standard_Integer first = FirstUKnotIndex();
   Standard_Integer last  = LastUKnotIndex();
 
   if ((Index < first) || (Index > last))
-  Standard_DomainError::Raise("Geom2d_BSplineCurve::SetOrigin");
+  throw Standard_DomainError("Geom2d_BSplineCurve::SetOrigin");
 
   Standard_Integer nbknots = knots->Length();
   Standard_Integer nbpoles = poles->Length();
@@ -1087,7 +1087,7 @@ void Geom2d_BSplineCurve::SetPole
 (const Standard_Integer Index,
  const gp_Pnt2d& P)
 {
-  if (Index < 1 || Index > poles->Length()) Standard_OutOfRange::Raise("BSpline curve : SetPole : index and #pole mismatch");
+  if (Index < 1 || Index > poles->Length()) throw Standard_OutOfRange("BSpline curve : SetPole : index and #pole mismatch");
   poles->SetValue (Index, P);
   maxderivinvok = 0;
 }
@@ -1115,9 +1115,9 @@ void Geom2d_BSplineCurve::SetWeight
 (const Standard_Integer Index,
  const Standard_Real W)
 {
-  if (Index < 1 || Index > poles->Length())   Standard_OutOfRange::Raise("BSpline curve : SetWeight: Index and #pole mismatch");
+  if (Index < 1 || Index > poles->Length())   throw Standard_OutOfRange("BSpline curve : SetWeight: Index and #pole mismatch");
 
-  if (W <= gp::Resolution ())     Standard_ConstructionError::Raise("BSpline curve : SetWeight: Weight too small");
+  if (W <= gp::Resolution ())     throw Standard_ConstructionError("BSpline curve : SetWeight: Weight too small");
 
 
   Standard_Boolean rat = IsRational() || (Abs(W - 1.) > gp::Resolution());
@@ -1155,7 +1155,7 @@ void Geom2d_BSplineCurve::MovePoint(const Standard_Real U,
 {
   if (Index1 < 1 || Index1 > poles->Length() || 
       Index2 < 1 || Index2 > poles->Length() || Index1 > Index2) {
-    Standard_OutOfRange::Raise("BSpline curve :  MovePoint: Index and #pole mismatch");
+    throw Standard_OutOfRange("BSpline curve :  MovePoint: Index and #pole mismatch");
   }
   TColgp_Array1OfPnt2d npoles(1, poles->Length());
   gp_Pnt2d P0;
index 76e4e68..38250af 100644 (file)
@@ -106,12 +106,12 @@ Geom2d_BezierCurve::Geom2d_BezierCurve
   Standard_Integer nbpoles = Poles.Length();
   
   if (Weights.Length() != nbpoles)
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   
   Standard_Integer i;
   for (i = 1; i <= nbpoles; i++) {
     if (Weights(i) <= gp::Resolution()) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   }
   
index 87ba84e..3bac3eb 100644 (file)
@@ -72,7 +72,7 @@ Geom2d_Circle::Geom2d_Circle (const Ax2d& A, const Standard_Real Radius,
                              const Standard_Boolean Sense)
 : radius(Radius) {
   
-   if (Radius < 0.0) { Standard_ConstructionError::Raise(); }
+   if (Radius < 0.0) { throw Standard_ConstructionError(); }
    pos = gp_Ax22d(A, Sense);
 }
 
@@ -85,7 +85,7 @@ Geom2d_Circle::Geom2d_Circle (const gp_Ax22d& A, const Standard_Real Radius)
 
 : radius (Radius) {
 
-   if (Radius < 0.0) { Standard_ConstructionError::Raise(); }
+   if (Radius < 0.0) { throw Standard_ConstructionError(); }
    pos = A;
 }
 
@@ -108,7 +108,7 @@ void Geom2d_Circle::SetCirc2d (const gp_Circ2d& C) {
 
 void Geom2d_Circle::SetRadius (const Standard_Real R) 
 { 
-  if (R < 0.0) { Standard_ConstructionError::Raise(); }
+  if (R < 0.0) { throw Standard_ConstructionError(); }
   radius = R;
 }
 
index d2aa265..e9dbbbc 100644 (file)
@@ -80,7 +80,7 @@ Geom2d_Ellipse::Geom2d_Ellipse (const Ax2d& MajorAxis,
 :majorRadius (MajorRadius), minorRadius (MinorRadius){
 
   if (MajorRadius < MinorRadius || MinorRadius < 0.0 ) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   pos = gp_Ax22d(MajorAxis, Sense);
 }
@@ -97,7 +97,7 @@ Geom2d_Ellipse::Geom2d_Ellipse (const gp_Ax22d& Axis,
 : majorRadius (MajorRadius), minorRadius (MinorRadius)
 {
   if (MajorRadius < MinorRadius || MinorRadius < 0.0 ) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   pos = Axis;
 }
@@ -124,7 +124,7 @@ void Geom2d_Ellipse::SetElips2d (const gp_Elips2d& E)
 void Geom2d_Ellipse::SetMajorRadius (const Standard_Real MajorRadius) 
 {
   if (MajorRadius < minorRadius) 
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   else                           
     majorRadius = MajorRadius; 
 }
@@ -138,7 +138,7 @@ void Geom2d_Ellipse::SetMajorRadius (const Standard_Real MajorRadius)
 void Geom2d_Ellipse::SetMinorRadius (const Standard_Real MinorRadius) 
 {
    if (MinorRadius < 0 || majorRadius < MinorRadius) 
-     { Standard_ConstructionError::Raise(); }
+     { throw Standard_ConstructionError(); }
    else 
      { minorRadius = MinorRadius; }
 }
index 9d4915f..ef357a8 100644 (file)
@@ -82,7 +82,7 @@ Geom2d_Hyperbola::Geom2d_Hyperbola (const Ax2d& A,
 : majorRadius (MajorRadius), minorRadius (MinorRadius) 
 {
   if( MajorRadius < 0.0|| MinorRadius < 0.0) 
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   pos = gp_Ax22d(A, Sense);
 }
 
@@ -97,7 +97,7 @@ Geom2d_Hyperbola::Geom2d_Hyperbola (const gp_Ax22d& Axis,
 : majorRadius (MajorRadius), minorRadius (MinorRadius) 
 {
   if( MajorRadius < 0.0|| MinorRadius < 0.0)
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   pos = Axis;
 }
 
@@ -123,7 +123,7 @@ void Geom2d_Hyperbola::SetHypr2d (const gp_Hypr2d& H)
 void Geom2d_Hyperbola::SetMajorRadius (const Standard_Real MajorRadius) 
 {
   if (MajorRadius < 0.0) 
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   else                   
     majorRadius = MajorRadius;
 }
@@ -137,7 +137,7 @@ void Geom2d_Hyperbola::SetMajorRadius (const Standard_Real MajorRadius)
 void Geom2d_Hyperbola::SetMinorRadius (const Standard_Real MinorRadius) 
 {
   if (MinorRadius < 0.0 ) 
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   else
     minorRadius = MinorRadius;
 }
index 0f323a9..2c4ea95 100644 (file)
@@ -146,7 +146,7 @@ void Geom2d_OffsetCurve::SetBasisCurve (const Handle(Geom2d_Curve)& C,
 
     // Raise exception if still C0
     if (isC0)
-      Standard_ConstructionError::Raise("Offset on C0 curve");
+      throw Standard_ConstructionError("Offset on C0 curve");
   }
   //
   if(isTrimmed)
@@ -265,7 +265,7 @@ gp_Vec2d Geom2d_OffsetCurve::DN (const Standard_Real U,
   case 2: D2( U, PBidon, VBidon, VN); break;
   case 3: D3( U, PBidon, VBidon, VBidon, VN); break;
   default:
-    Standard_NotImplemented::Raise("Exception: Derivative order is greater than 3. "
+    throw Standard_NotImplemented("Exception: Derivative order is greater than 3. "
       "Cannot compute of derivative.");
   }
   
index 91194f1..f7bfd21 100644 (file)
@@ -77,7 +77,7 @@ Geom2d_Parabola::Geom2d_Parabola (const Ax2d& MirrorAxis,
                                  const Standard_Boolean Sense) 
 : focalLength (Focal) 
 {
-  if (Focal < 0.0) { Standard_ConstructionError::Raise(); }
+  if (Focal < 0.0) { throw Standard_ConstructionError(); }
   pos = gp_Ax22d(MirrorAxis, Sense);
 }
 
@@ -90,7 +90,7 @@ Geom2d_Parabola::Geom2d_Parabola (const Ax2d& MirrorAxis,
 Geom2d_Parabola::Geom2d_Parabola (const gp_Ax22d& Axis, const Standard_Real Focal)
 : focalLength (Focal) 
 {
-  if (Focal < 0.0) { Standard_ConstructionError::Raise(); }
+  if (Focal < 0.0) { throw Standard_ConstructionError(); }
   pos  = Axis;
 }
 
@@ -114,7 +114,7 @@ Geom2d_Parabola::Geom2d_Parabola (const Ax2d& D, const Pnt2d& F) {
 
 void Geom2d_Parabola::SetFocal (const Standard_Real Focal) 
 {
-  if (Focal < 0.0) Standard_ConstructionError::Raise();
+  if (Focal < 0.0) throw Standard_ConstructionError();
   focalLength = Focal;
 }
 
index 42343ca..9cbfa69 100644 (file)
@@ -72,7 +72,7 @@ Geom2d_TrimmedCurve::Geom2d_TrimmedCurve (const Handle(Geom2d_Curve)& C,
      uTrim1 (U1),
      uTrim2 (U2)
 {
-  if(C.IsNull()) Standard_ConstructionError::Raise("Geom2d_TrimmedCurve:: C is null");
+  if(C.IsNull()) throw Standard_ConstructionError("Geom2d_TrimmedCurve:: C is null");
   // kill trimmed basis curves
   Handle(Geom2d_TrimmedCurve) T = Handle(Geom2d_TrimmedCurve)::DownCast(C);
   if (!T.IsNull())
@@ -118,7 +118,7 @@ void Geom2d_TrimmedCurve::SetTrim (const Standard_Real U1,
 {
   Standard_Boolean sameSense = Standard_True;
   if (U1 == U2)
-    Standard_ConstructionError::Raise("Geom2d_TrimmedCurve::U1 == U2");
+    throw Standard_ConstructionError("Geom2d_TrimmedCurve::U1 == U2");
 
   Standard_Real Udeb = basisCurve->FirstParameter();
   Standard_Real Ufin = basisCurve->LastParameter();
@@ -149,8 +149,7 @@ void Geom2d_TrimmedCurve::SetTrim (const Standard_Real U1,
 
     if ((Udeb - uTrim1 > Precision::PConfusion()) ||
        (uTrim2 - Ufin > Precision::PConfusion()))   {
-      Standard_ConstructionError::Raise
-       ("Geom_TrimmedCurve::parameters out of range");
+      throw Standard_ConstructionError("Geom_TrimmedCurve::parameters out of range");
     }
   }    
 
index 7c41332..9a4e654 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Geom2d_UndefinedDerivative, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Geom2d_UndefinedDerivative
   #define Geom2d_UndefinedDerivative_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Geom2d_UndefinedDerivative::Raise(MESSAGE);
+  if (CONDITION) throw Geom2d_UndefinedDerivative(MESSAGE);
 #else
   #define Geom2d_UndefinedDerivative_Raise_if(CONDITION, MESSAGE)
 #endif
index bd129bc..be6ed83 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Geom2d_UndefinedValue, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Geom2d_UndefinedValue
   #define Geom2d_UndefinedValue_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Geom2d_UndefinedValue::Raise(MESSAGE);
+  if (CONDITION) throw Geom2d_UndefinedValue(MESSAGE);
 #else
   #define Geom2d_UndefinedValue_Raise_if(CONDITION, MESSAGE)
 #endif
index cca173e..e355599 100644 (file)
@@ -216,17 +216,3 @@ void Geom2dAPI_InterCurveCurve::Segment
   theCurve1 = new Geom2d_TrimmedCurve(myCurve1, aU1, aU2);
   theCurve2 = new Geom2d_TrimmedCurve(myCurve2, aV1, aV2);
 }
-
-//=======================================================================
-//function : Segment
-//purpose  : 
-//=======================================================================
-
-void Geom2dAPI_InterCurveCurve::Segment (const Standard_Integer Index,
-                                         Handle(Geom2d_Curve)&) const 
-{
-  Standard_NotImplemented::Raise(" ");
-  (void)Index; // avoid compiler warning in Release mode
-  Standard_OutOfRange_Raise_if(Index < 0 || Index > NbSegments(),
-                              "Geom2dAPI_InterCurveCurve::Segment");
-}
index f3c41af..bb0adeb 100644 (file)
@@ -119,19 +119,6 @@ public:
   //! computing of self-intersections on a curve.
   Standard_EXPORT void Segment (const Standard_Integer Index, Handle(Geom2d_Curve)& Curve1, Handle(Geom2d_Curve)& Curve2) const;
   
-  //! Use this syntax to get solutions of
-  //! tangential intersections only in case of a self-intersected curve.
-  //! Output value Curve1 is the intersection segment of the curve
-  //! defined by number Index. An intersection segment is a
-  //! portion of the initial curve limited by two points. The distance
-  //! between each point of this segment to another portion of the curve is
-  //! less or equal to the tolerance value assigned at the time of
-  //! construction or in the function Init (this value is defaulted to 1.0e-6).
-  //! Exceptions
-  //! Standard_OutOfRange if Index is not in the range [ 1,NbSegments ],
-  //! where NbSegments is the number of computed tangential intersections.
-  Standard_EXPORT void Segment (const Standard_Integer Index, Handle(Geom2d_Curve)& Curve1) const;
-  
   //! return the algorithmic object from Intersection.
     const Geom2dInt_GInter& Intersector() const;
 
index 6b62098..919e4d2 100644 (file)
@@ -148,7 +148,7 @@ static void BuildPeriodicTangent(
   gp_Vec2d a_vector ;
   
   if (PointsArray.Length() < 3) {
-    Standard_ConstructionError::Raise(); 
+    throw Standard_ConstructionError();
     }   
  
   if (!TangentFlags.Value(1)) {
@@ -194,7 +194,7 @@ static void BuildTangents(const TColgp_Array1OfPnt2d&      PointsArray,
  degree = 3 ;
 
  if ( PointsArray.Length() < 3) {
-   Standard_ConstructionError::Raise(); 
+   throw Standard_ConstructionError();
    }   
  if (PointsArray.Length() == 3) {
    degree = 2 ;
@@ -333,7 +333,7 @@ myTangentRequest(Standard_False)
                                   myPoints->Upper()) ;
 
  if (!result) {
-   Standard_ConstructionError::Raise();
+   throw Standard_ConstructionError();
    }
  BuildParameters(PeriodicFlag,
                 PointsPtr->Array1(),
@@ -373,7 +373,7 @@ myTangentRequest(Standard_False)
 
  if (PeriodicFlag) {
    if ((PointsPtr->Length()) + 1 != ParametersPtr->Length()) {
-     Standard_ConstructionError::Raise();
+     throw Standard_ConstructionError();
    }
  }
  myTangents = 
@@ -384,13 +384,13 @@ myTangentRequest(Standard_False)
                                    myPoints->Upper()) ;
  
  if (!result) {
-   Standard_ConstructionError::Raise();
+   throw Standard_ConstructionError();
    }
                
  result =
  CheckParameters(ParametersPtr->Array1()) ;
  if (!result) {
-   Standard_ConstructionError::Raise();
+   throw Standard_ConstructionError();
    }
        
  for (ii = myPoints->Lower() ; ii <= myPoints->Upper() ; ii++) {
@@ -414,7 +414,7 @@ void Geom2dAPI_Interpolate::Load(
  myTangentFlags = TangentFlagsPtr ;
  if (Tangents.Length() != myPoints->Length() ||
      TangentFlagsPtr->Length() != myPoints->Length()) {
-   Standard_ConstructionError::Raise();
+   throw Standard_ConstructionError();
    }
  result  = 
    CheckTangents(Tangents,
@@ -432,7 +432,7 @@ void Geom2dAPI_Interpolate::Load(
                  myParameters->Array1()) ; 
   }
  else {
-   Standard_ConstructionError::Raise();
+   throw Standard_ConstructionError();
    }
  
   
@@ -457,7 +457,7 @@ void Geom2dAPI_Interpolate::Load(const gp_Vec2d& InitialTangent,
                  myTangentFlags->Array1(),
                  myTolerance) ;
   if (!result) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
     }
   ScaleTangents(myPoints->Array1(),
                myTangents->ChangeArray1(),
@@ -899,7 +899,7 @@ void Geom2dAPI_Interpolate::PerformNonPeriodic()
 const Handle(Geom2d_BSplineCurve)& Geom2dAPI_Interpolate::Curve() const 
 {
   if ( !myIsDone) 
-    StdFail_NotDone::Raise(" ");
+    throw StdFail_NotDone(" ");
   return myCurve;
 }
 
index c1a394d..0bf24b4 100644 (file)
@@ -317,7 +317,7 @@ void Geom2dAPI_PointsToBSpline::Init
    const GeomAbs_Shape         Continuity,
    const Standard_Real         Tol2D)
 {
-  if (Params.Length() != Points.Length()) Standard_OutOfRange::Raise("");
+  if (Params.Length() != Points.Length()) throw Standard_OutOfRange("");
 
   Standard_Real Tol3D = 0.; // dummy argument for BSplineCompute.
   Standard_Integer Nbp = Params.Length();
@@ -468,7 +468,7 @@ void Geom2dAPI_PointsToBSpline::Init
 const Handle(Geom2d_BSplineCurve)& Geom2dAPI_PointsToBSpline::Curve() const 
 {
   if ( !myIsDone) 
-    StdFail_NotDone::Raise(" ");
+    throw StdFail_NotDone(" ");
   return myCurve;
 }
 
index 87bb50a..a07354e 100644 (file)
@@ -90,7 +90,7 @@ Handle(Geom2d_Curve) Geom2dAdaptor::MakeCurve
     break;
     
   default:
-    Standard_DomainError::Raise("Geom2dAdaptor::MakeCurve, OtherCurve");
+    throw Standard_DomainError("Geom2dAdaptor::MakeCurve, OtherCurve");
 
   }
 
index b025ffe..82cb392 100644 (file)
@@ -255,19 +255,16 @@ GeomAbs_Shape Geom2dAdaptor_Curve::Continuity() const
     case GeomAbs_G2: return GeomAbs_G2;
 
     default:
-      Standard_NoSuchObject::Raise("Geom2dAdaptor_Curve::Continuity");
+      throw Standard_NoSuchObject("Geom2dAdaptor_Curve::Continuity");
     }
   }
 
   else if (myTypeCurve == GeomAbs_OtherCurve) {
-    Standard_NoSuchObject::Raise("Geom2dAdaptor_Curve::Continuity");
+    throw Standard_NoSuchObject("Geom2dAdaptor_Curve::Continuity");
   }
   else {
     return GeomAbs_CN;
   }
-
-  // portage WNT
-  return GeomAbs_CN;
 }
 
 //=======================================================================
@@ -288,7 +285,7 @@ Standard_Integer Geom2dAdaptor_Curve::NbIntervals(const GeomAbs_Shape S) const
       switch ( S) {
       case GeomAbs_G1:
       case GeomAbs_G2:
-       Standard_DomainError::Raise("Geom2dAdaptor_Curve::NbIntervals");
+       throw Standard_DomainError("Geom2dAdaptor_Curve::NbIntervals");
        break;
       case GeomAbs_C0:
        myNbIntervals = 1;
@@ -360,7 +357,7 @@ Standard_Integer Geom2dAdaptor_Curve::NbIntervals(const GeomAbs_Shape S) const
     switch(S){
     case GeomAbs_G1:
     case GeomAbs_G2:
-      Standard_DomainError::Raise("GeomAdaptor_Curve::NbIntervals");
+      throw Standard_DomainError("GeomAdaptor_Curve::NbIntervals");
       break;
     case GeomAbs_C0: BaseS = GeomAbs_C1; break;
     case GeomAbs_C1: BaseS = GeomAbs_C2; break;
@@ -393,7 +390,7 @@ void Geom2dAdaptor_Curve::Intervals(TColStd_Array1OfReal& T,
       switch ( S) {
       case GeomAbs_G1:
       case GeomAbs_G2:
-       Standard_DomainError::Raise("Geom2dAdaptor_Curve::NbIntervals");
+       throw Standard_DomainError("Geom2dAdaptor_Curve::NbIntervals");
        break;
       case GeomAbs_C0:
        myNbIntervals = 1;
@@ -476,7 +473,7 @@ void Geom2dAdaptor_Curve::Intervals(TColStd_Array1OfReal& T,
     switch(S){
     case GeomAbs_G1:
     case GeomAbs_G2:
-      Standard_DomainError::Raise("GeomAdaptor_Curve::NbIntervals");
+      throw Standard_DomainError("GeomAdaptor_Curve::NbIntervals");
       break;
     case GeomAbs_C0: BaseS = GeomAbs_C1; break;
     case GeomAbs_C1: BaseS = GeomAbs_C2; break;
@@ -910,9 +907,7 @@ Standard_Integer Geom2dAdaptor_Curve::Degree() const
   else if (myTypeCurve == GeomAbs_BSplineCurve)
     return myBSplineCurve->Degree();
   else
-    Standard_NoSuchObject::Raise();
-  // portage WNT 
-  return 0;
+    throw Standard_NoSuchObject();
 }
 
 //=======================================================================
@@ -943,9 +938,7 @@ Standard_Integer Geom2dAdaptor_Curve::NbPoles() const
   else if (myTypeCurve == GeomAbs_BSplineCurve)
     return myBSplineCurve->NbPoles();
   else
-    Standard_NoSuchObject::Raise();
-  // portage WNT 
-  return 0;
+    throw Standard_NoSuchObject();
 }
 
 //=======================================================================
@@ -956,7 +949,7 @@ Standard_Integer Geom2dAdaptor_Curve::NbPoles() const
 Standard_Integer Geom2dAdaptor_Curve::NbKnots() const
 {
   if ( myTypeCurve != GeomAbs_BSplineCurve)
-    Standard_NoSuchObject::Raise("Geom2dAdaptor_Curve::NbKnots");
+    throw Standard_NoSuchObject("Geom2dAdaptor_Curve::NbKnots");
   return myBSplineCurve->NbKnots();
 }
 
index 155ab49..ca83717 100644 (file)
@@ -66,7 +66,7 @@ inline GeomAbs_CurveType Geom2dAdaptor_Curve::GetType() const
 
 inline void Geom2dAdaptor_Curve::Load(const Handle(Geom2d_Curve)& C) 
 {
-  if ( C.IsNull()) Standard_NullObject::Raise();
+  if ( C.IsNull()) throw Standard_NullObject();
   
   load(C,C->FirstParameter(),C->LastParameter());
 }
@@ -80,9 +80,9 @@ inline void Geom2dAdaptor_Curve::Load(const Handle(Geom2d_Curve)& C,
                                                  const Standard_Real UFirst,
                                                  const Standard_Real ULast) 
 {
-  if ( C.IsNull()) Standard_NullObject::Raise();
+  if ( C.IsNull()) throw Standard_NullObject();
 
-  if ( UFirst > ULast) Standard_ConstructionError::Raise();
+  if ( UFirst > ULast) throw Standard_ConstructionError();
   
   load(C,UFirst,ULast);
 }
index 8790251..d51b0da 100644 (file)
@@ -133,10 +133,10 @@ const Standard_Boolean               SameOrientation
 
   Standard_Integer TheFirst = C->FirstUKnotIndex ();
   Standard_Integer TheLast  = C->LastUKnotIndex  ();
-  if (FromK1 == ToK2)  Standard_DomainError::Raise();
+  if (FromK1 == ToK2)  throw Standard_DomainError();
   Standard_Integer FirstK = Min (FromK1, ToK2);
   Standard_Integer LastK  = Max (FromK1, ToK2);
-  if (FirstK < TheFirst || LastK > TheLast) Standard_OutOfRange::Raise();
+  if (FirstK < TheFirst || LastK > TheLast) throw Standard_OutOfRange();
 
   Handle(Geom2d_BSplineCurve) NewCurve = Handle(Geom2d_BSplineCurve)::DownCast(C->Copy());
 
@@ -383,10 +383,10 @@ const Convert_ParameterisationType  Parameterisation)
                                          MaxSegments, MaxDegree);
       if (ApprCOffs.HasResult())
        TheCurve = ApprCOffs.Curve();
-      else  Standard_ConstructionError::Raise();
+      else  throw Standard_ConstructionError();
     }
 
-    else { Standard_DomainError::Raise("No such curve"); }
+    else { throw Standard_DomainError("No such curve"); }
     
   }
   
@@ -449,10 +449,10 @@ const Convert_ParameterisationType  Parameterisation)
                                          MaxSegments, MaxDegree);
       if (ApprCOffs.HasResult())
        TheCurve = ApprCOffs.Curve();
-      else  Standard_ConstructionError::Raise();
+      else  throw Standard_ConstructionError();
     }
 
-    else { Standard_DomainError::Raise(); }
+    else { throw Standard_DomainError(); }
   }
   
   return TheCurve;
@@ -875,7 +875,7 @@ static GeomAbs_Shape Continuity(const Handle(Geom2d_Curve)& C1,
     }
   }
   else
-    Standard_Failure::Raise("Courbes non jointives");
+    throw Standard_Failure("Courbes non jointives");
   return cont ;
 }
 
@@ -968,7 +968,7 @@ void  Geom2dConvert::ConcatG1(TColGeom2d_Array1OfBSplineCurve&           ArrayOf
                    PreLast,First,
                    Standard_True,
                    Standard_True)<GeomAbs_C0)
-       Standard_ConstructionError::Raise("Geom2dConvert curves not C0") ;                //renvoi d'une erreur
+       throw Standard_ConstructionError("Geom2dConvert curves not C0") ;                //renvoi d'une erreur
      else{
        if (Continuity(ArrayOfCurves(i-1),
                      ArrayOfCurves(i),
@@ -1117,7 +1117,7 @@ void  Geom2dConvert::ConcatG1(TColGeom2d_Array1OfBSplineCurve&           ArrayOf
      fusion=C.Add(Curve1,
                  local_tolerance(j-1));          //fusion de deux courbes adjacentes               
      if (fusion==Standard_False)
-       Standard_ConstructionError::Raise("Geom2dConvert Concatenation Error") ;
+       throw Standard_ConstructionError("Geom2dConvert Concatenation Error") ;
      Curve2=C.BSplineCurve();
    }
    Curve2->SetPeriodic();      //1 seule courbe C1
@@ -1143,7 +1143,7 @@ void  Geom2dConvert::ConcatG1(TColGeom2d_Array1OfBSplineCurve&           ArrayOf
         Geom2dConvert_CompCurveToBSplineCurve  C(ArrayOfConcatenated->Value(i));
         fusion=C.Add(Curve1,ArrayOfToler(j-1));          //fusion de deux courbes adjacentes               
         if (fusion==Standard_False)
-          Standard_ConstructionError::Raise("Geom2dConvert Concatenation Error") ;
+          throw Standard_ConstructionError("Geom2dConvert Concatenation Error") ;
         ArrayOfConcatenated->SetValue(i,C.BSplineCurve());
        }
      }
@@ -1213,7 +1213,7 @@ void  Geom2dConvert::ConcatC1(TColGeom2d_Array1OfBSplineCurve&           ArrayOf
                    Standard_True,
                    ArrayOfToler(i-1),
                    AngularTolerance)<GeomAbs_C0)
-       Standard_ConstructionError::Raise("Geom2dConvert curves not C0") ;                //renvoi d'une erreur
+       throw Standard_ConstructionError("Geom2dConvert curves not C0") ;                //renvoi d'une erreur
      else{
        if (Continuity(ArrayOfCurves(i-1),
                      ArrayOfCurves(i),
@@ -1358,7 +1358,7 @@ void  Geom2dConvert::ConcatC1(TColGeom2d_Array1OfBSplineCurve&           ArrayOf
        fusion=C.Add(Curve1,
                    local_tolerance(j-1));          //fusion de deux courbes adjacentes               
        if (fusion==Standard_False)
-        Standard_ConstructionError::Raise("Geom2dConvert Concatenation Error") ;
+        throw Standard_ConstructionError("Geom2dConvert Concatenation Error") ;
        Curve2=C.BSplineCurve();
      }
    }
@@ -1401,7 +1401,7 @@ void  Geom2dConvert::ConcatC1(TColGeom2d_Array1OfBSplineCurve&           ArrayOf
         Geom2dConvert_CompCurveToBSplineCurve C (ArrayOfConcatenated->Value(i));
         fusion=C.Add(Curve1,ArrayOfToler(j-1));          //fusion de deux courbes adjacentes               
         if (fusion==Standard_False)
-          Standard_ConstructionError::Raise("Geom2dConvert Concatenation Error") ;
+          throw Standard_ConstructionError("Geom2dConvert Concatenation Error") ;
         ArrayOfConcatenated->SetValue(i,C.BSplineCurve());
        }
      }
@@ -1482,7 +1482,7 @@ void Geom2dConvert::C0BSplineToC1BSplineCurve(Handle(Geom2d_BSplineCurve)& BS,
      for (i=1;i<ArrayOfConcatenated->Length();i++){
        fusion=C.Add(ArrayOfConcatenated->Value(i),tolerance, Standard_True);
        if (fusion==Standard_False)
-        Standard_ConstructionError::Raise("Geom2dConvert Concatenation Error") ;
+        throw Standard_ConstructionError("Geom2dConvert Concatenation Error") ;
      }
    }
    BS=C.BSplineCurve();
index 1d87142..45f390d 100644 (file)
@@ -33,7 +33,7 @@ const Standard_Integer      ContinuityRange
 ) {
 
 
-  if (ContinuityRange < 0)  Standard_RangeError::Raise();
+  if (ContinuityRange < 0)  throw Standard_RangeError();
 
   Standard_Integer FirstIndex = BasisCurve->FirstUKnotIndex();
   Standard_Integer LastIndex  = BasisCurve->LastUKnotIndex();
index 07b91b0..360582a 100644 (file)
@@ -56,7 +56,7 @@ Geom2dConvert_BSplineCurveToBezierCurve::Geom2dConvert_BSplineCurveToBezierCurve
  const Standard_Real ParametricTolerance)
 {
  if (U2 - U1 < ParametricTolerance)
-      Standard_DomainError::Raise("GeomConvert_BSplineCurveToBezierSurface");
+      throw Standard_DomainError("GeomConvert_BSplineCurveToBezierSurface");
 
   Standard_Real Uf = U1, Ul = U2; 
   Standard_Real PTol = ParametricTolerance/2 ;
@@ -92,7 +92,7 @@ Handle(Geom2d_BezierCurve) Geom2dConvert_BSplineCurveToBezierCurve::Arc
 (const Standard_Integer Index)
 {
   if ( Index < 1 || Index > myCurve->NbKnots()-1) {
-    Standard_OutOfRange::Raise("Geom2dConvert_BSplineCurveToBezierCurve");
+    throw Standard_OutOfRange("Geom2dConvert_BSplineCurveToBezierCurve");
   }
   Standard_Integer Deg = myCurve->Degree();
 
index 211f885..a899808 100644 (file)
@@ -188,8 +188,8 @@ void Geom2dEvaluator_OffsetCurve::CalculateD0(      gp_Pnt2d& theValue,
                                               const gp_Vec2d& theD1) const
 {
   if (theD1.SquareMagnitude() <= gp::Resolution())
-    Standard_NullValue::Raise("Geom2dEvaluator_OffsetCurve: Undefined normal vector "
-                              "because tangent vector has zero-magnitude!");
+    throw Standard_NullValue("Geom2dEvaluator_OffsetCurve: Undefined normal vector "
+                             "because tangent vector has zero-magnitude!");
 
   gp_Dir2d aNormal(theD1.Y(), -theD1.X());
   theValue.ChangeCoord().Add(aNormal.XY() * myOffset);
@@ -213,7 +213,7 @@ void Geom2dEvaluator_OffsetCurve::CalculateD1(      gp_Pnt2d& theValue,
   if (R3 <= gp::Resolution())
   {
     if (R2 <= gp::Resolution())
-      Standard_NullValue::Raise("Geom2dEvaluator_OffsetCurve: Null derivative");
+      throw Standard_NullValue("Geom2dEvaluator_OffsetCurve: Null derivative");
     //We try another computation but the stability is not very good.
     DNdir.Multiply(R);
     DNdir.Subtract(Ndir.Multiplied(Dr / R));
@@ -260,7 +260,7 @@ void Geom2dEvaluator_OffsetCurve::CalculateD2(      gp_Pnt2d& theValue,
   if (R5 <= gp::Resolution())
   {
     if (R4 <= gp::Resolution())
-      Standard_NullValue::Raise("Geom2dEvaluator_OffsetCurve: Null derivative");
+      throw Standard_NullValue("Geom2dEvaluator_OffsetCurve: Null derivative");
     //We try another computation but the stability is not very good dixit ISG.
     // V2 = P" (U) :
     D2Ndir.Subtract(DNdir.Multiplied(2.0 * Dr / R2));
@@ -334,7 +334,7 @@ void Geom2dEvaluator_OffsetCurve::CalculateD3(      gp_Pnt2d& theValue,
   if (R7 <= gp::Resolution())
   {
     if (R6 <= gp::Resolution())
-      Standard_NullValue::Raise("Geom2dEvaluator_OffsetCurve: Null derivative");
+      throw Standard_NullValue("Geom2dEvaluator_OffsetCurve: Null derivative");
     //We try another computation but the stability is not very good dixit ISG.
     // V3 = P"' (U) :
     D3Ndir.Subtract(D2Ndir.Multiplied(3.0 * myOffset * Dr / R2));
index 6d1370b..8a3cbf6 100644 (file)
@@ -680,8 +680,8 @@ Standard_Integer Geom2dGcc_Circ2d2TanOn::
 gp_Circ2d Geom2dGcc_Circ2d2TanOn::
   ThisSolution (const Standard_Integer Index) const 
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   return cirsol(Index);
 }
 
@@ -690,8 +690,8 @@ void Geom2dGcc_Circ2d2TanOn::
                        GccEnt_Position& Qualif1 ,
                        GccEnt_Position& Qualif2) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     if (Invert) {
       Qualif1 = qualifier2(Index);
@@ -710,8 +710,8 @@ void Geom2dGcc_Circ2d2TanOn::
                   Standard_Real&   ParArg,
                   gp_Pnt2d&        PntSol) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     if (Invert) {
       if (TheSame2(Index) == 0) {
@@ -719,7 +719,7 @@ void Geom2dGcc_Circ2d2TanOn::
        ParArg = pararg2(Index);
         PntSol = pnttg2sol(Index);
       }
-      else { StdFail_NotDone::Raise(); }
+      else { throw StdFail_NotDone(); }
     }
     else {
       if (TheSame1(Index) == 0) {
@@ -727,7 +727,7 @@ void Geom2dGcc_Circ2d2TanOn::
        ParArg = pararg1(Index);
         PntSol = pnttg1sol(Index);
       }
-      else { StdFail_NotDone::Raise(); }
+      else { throw StdFail_NotDone(); }
     }
   }
 }
@@ -738,8 +738,8 @@ void Geom2dGcc_Circ2d2TanOn::
               Standard_Real& ParArg,
               gp_Pnt2d& PntSol) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     if (!Invert) {
       if (TheSame2(Index) == 0) {
@@ -747,7 +747,7 @@ void Geom2dGcc_Circ2d2TanOn::
        ParArg = pararg2(Index);
         PntSol = pnttg2sol(Index);
       }
-      else { StdFail_NotDone::Raise(); }
+      else { throw StdFail_NotDone(); }
     }
     else {
       if (TheSame1(Index) == 0) {
@@ -755,7 +755,7 @@ void Geom2dGcc_Circ2d2TanOn::
        ParArg = pararg1(Index);
         PntSol = pnttg1sol(Index);
       }
-      else { StdFail_NotDone::Raise(); }
+      else { throw StdFail_NotDone(); }
     }
   }
 }
@@ -765,8 +765,8 @@ void Geom2dGcc_Circ2d2TanOn::
               Standard_Real& ParArg,
               gp_Pnt2d& PntSol) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     ParArg = parcen3(Index);
     PntSol = pntcen(Index);
@@ -776,8 +776,8 @@ void Geom2dGcc_Circ2d2TanOn::
 Standard_Boolean Geom2dGcc_Circ2d2TanOn::
    IsTheSame1 (const Standard_Integer Index) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   if (Invert) {
     if (TheSame2(Index) == 0) { return Standard_False; }
     else { return Standard_True; }
@@ -791,8 +791,8 @@ Standard_Boolean Geom2dGcc_Circ2d2TanOn::
 Standard_Boolean Geom2dGcc_Circ2d2TanOn::
    IsTheSame2 (const Standard_Integer Index) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   if (!Invert) {
     if (TheSame2(Index) == 0) { return Standard_False; }
     else { return Standard_True; }
index bf0a226..91b5047 100644 (file)
@@ -79,7 +79,7 @@ Geom2dGcc_Circ2d2TanOnGeo (const GccEnt_QualifiedCirc&     Qualified1 ,
     Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
     !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
     Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
       return;
   }
   gp_Circ2d C1 = Qualified1.Qualified();
@@ -140,7 +140,7 @@ Geom2dGcc_Circ2d2TanOnGeo (const GccEnt_QualifiedCirc&     Qualified1 ,
         break;
       default:
         {
-          Standard_ConstructionError::Raise();
+          throw Standard_ConstructionError();
         }
       }
       if (Intp.IsDone()) {
@@ -303,7 +303,7 @@ parcen3(1,8)
     Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
     !(Qualified2.IsEnclosed() ||
     Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
       return;
   }
   gp_Dir2d dirx(1.,0.);
@@ -348,7 +348,7 @@ parcen3(1,8)
         break;
       default:
         {
-          Standard_ConstructionError::Raise();
+          throw Standard_ConstructionError();
         }
       }
       if (Intp.IsDone()) {
@@ -479,7 +479,7 @@ parcen3(1,8)
     Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
     !(Qualified2.IsEnclosed() ||
     Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
       return;
   }
   Standard_Real Tol = Abs(Tolerance);
@@ -632,7 +632,7 @@ parcen3(1,8)
   NbrSol = 0;
   if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
     Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
       return;
   }
   Standard_Real Tol = Abs(Tolerance);
@@ -692,7 +692,7 @@ parcen3(1,8)
         break;
       default:
         {
-          Standard_ConstructionError::Raise();
+          throw Standard_ConstructionError();
         }
       }
       if (Intp.IsDone()) {
@@ -795,7 +795,7 @@ parcen3(1,8)
   NbrSol = 0;
   if (!(Qualified1.IsEnclosed() ||
     Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
       return;
   }
   gp_Dir2d dirx(1.,0.);
@@ -834,7 +834,7 @@ parcen3(1,8)
       break;
     default:
       {
-        Standard_ConstructionError::Raise();
+        throw Standard_ConstructionError();
       }
     }
     if (Intp.IsDone()) {
@@ -984,8 +984,8 @@ NbSolutions () const{ return NbrSol; }
 gp_Circ2d Geom2dGcc_Circ2d2TanOnGeo::
 ThisSolution (const Standard_Integer Index) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
 
   return cirsol(Index);
 }
@@ -995,8 +995,8 @@ WhichQualifier(const Standard_Integer Index   ,
                GccEnt_Position& Qualif1 ,
                GccEnt_Position& Qualif2 ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     Qualif1 = qualifier1(Index);
     Qualif2 = qualifier2(Index);
@@ -1008,15 +1008,15 @@ Tangency1 (const Standard_Integer    Index          ,
            Standard_Real&      ParSol         ,
            Standard_Real&      ParArg         ,
            gp_Pnt2d&           PntSol         ) const{
-             if (!WellDone) { StdFail_NotDone::Raise(); }
-             else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+             if (!WellDone) { throw StdFail_NotDone(); }
+             else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
              else {
                if (TheSame1(Index) == 0) {
                  ParSol = par1sol(Index);
                  ParArg = pararg1(Index);
                  PntSol = gp_Pnt2d(pnttg1sol(Index));
                }
-               else { StdFail_NotDone::Raise(); }
+               else { throw StdFail_NotDone(); }
              }
 }
 
@@ -1025,15 +1025,15 @@ Tangency2 (const Standard_Integer    Index          ,
            Standard_Real&      ParSol         ,
            Standard_Real&      ParArg         ,
            gp_Pnt2d&           PntSol         ) const{
-             if (!WellDone) { StdFail_NotDone::Raise(); }
-             else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+             if (!WellDone) { throw StdFail_NotDone(); }
+             else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
              else {
                if (TheSame2(Index) == 0) {
                  ParSol = par2sol(Index);
                  ParArg = pararg2(Index);
                  PntSol = gp_Pnt2d(pnttg2sol(Index));
                }
-               else { StdFail_NotDone::Raise(); }
+               else { throw StdFail_NotDone(); }
              }
 }
 
@@ -1041,8 +1041,8 @@ void Geom2dGcc_Circ2d2TanOnGeo::
 CenterOn3 (const Standard_Integer    Index          ,
            Standard_Real&      ParArg         ,
            gp_Pnt2d&           PntSol         ) const{
-             if (!WellDone) { StdFail_NotDone::Raise(); }
-             else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+             if (!WellDone) { throw StdFail_NotDone(); }
+             else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
              else {
                ParArg = parcen3(Index);
                PntSol = gp_Pnt2d(pntcen(Index));
@@ -1052,8 +1052,8 @@ CenterOn3 (const Standard_Integer    Index          ,
 Standard_Boolean Geom2dGcc_Circ2d2TanOnGeo::
 IsTheSame1 (const Standard_Integer Index) const
 {
-  if (!WellDone) StdFail_NotDone::Raise();
-  if (Index <= 0 ||Index > NbrSol) Standard_OutOfRange::Raise();
+  if (!WellDone) throw StdFail_NotDone();
+  if (Index <= 0 ||Index > NbrSol) throw Standard_OutOfRange();
 
   if (TheSame1(Index) == 0) 
     return Standard_False;
@@ -1065,8 +1065,8 @@ IsTheSame1 (const Standard_Integer Index) const
 Standard_Boolean Geom2dGcc_Circ2d2TanOnGeo::
 IsTheSame2 (const Standard_Integer Index) const
 {
-  if (!WellDone) StdFail_NotDone::Raise();
-  if (Index <= 0 ||Index > NbrSol) Standard_OutOfRange::Raise();
+  if (!WellDone) throw StdFail_NotDone();
+  if (Index <= 0 ||Index > NbrSol) throw Standard_OutOfRange();
 
   if (TheSame2(Index) == 0)
     return Standard_False;
index f544121..203a9e4 100644 (file)
@@ -66,7 +66,7 @@ Geom2dGcc_Circ2d2TanOnIter (const GccEnt_QualifiedLin&  Qualified1 ,
                                 Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
                                 !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
                                 Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-                                  GccEnt_BadQualifier::Raise();
+                                  throw GccEnt_BadQualifier();
                                   return;
                               }
                               gp_Dir2d dirx(1.,0.);
@@ -167,7 +167,7 @@ Geom2dGcc_Circ2d2TanOnIter (const Geom2dGcc_QCurve& Qualified1 ,
                                 Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
                                 !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
                                 Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-                                  GccEnt_BadQualifier::Raise();
+                                  throw GccEnt_BadQualifier();
                                   return;
                               }
                               Standard_Real Tol = Abs(Tolerance);
@@ -274,7 +274,7 @@ Geom2dGcc_Circ2d2TanOnIter (const Geom2dGcc_QCurve& Qualified1 ,
                               WellDone = Standard_False;
                               if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
                                 Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-                                  GccEnt_BadQualifier::Raise();
+                                  throw GccEnt_BadQualifier();
                                   return;
                               }
                               Standard_Real Tol = Abs(Tolerance);
@@ -361,7 +361,7 @@ Geom2dGcc_Circ2d2TanOnIter (const GccEnt_QualifiedCirc& Qualified1 ,
                                 Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
                                 !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
                                 Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-                                  GccEnt_BadQualifier::Raise();
+                                  throw GccEnt_BadQualifier();
                                   return;
                               }
                               Standard_Real Tol = Abs(Tolerance);
@@ -469,7 +469,7 @@ Geom2dGcc_Circ2d2TanOnIter (const GccEnt_QualifiedCirc& Qualified1 ,
                                 Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
                                 !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
                                 Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-                                  GccEnt_BadQualifier::Raise();
+                                  throw GccEnt_BadQualifier();
                                   return;
                               }
                               Standard_Real Tol = Abs(Tolerance);
@@ -575,7 +575,7 @@ Geom2dGcc_Circ2d2TanOnIter (const GccEnt_QualifiedLin&  Qualified1 ,
                                 Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
                                 !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
                                 Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-                                  GccEnt_BadQualifier::Raise();
+                                  throw GccEnt_BadQualifier();
                                   return;
                               }
                               Standard_Real Tol = Abs(Tolerance);
@@ -679,7 +679,7 @@ Geom2dGcc_Circ2d2TanOnIter (const Geom2dGcc_QCurve& Qualified1 ,
                                 Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
                                 !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
                                 Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-                                  GccEnt_BadQualifier::Raise();
+                                  throw GccEnt_BadQualifier();
                                   return;
                               }
                               Standard_Real Tol = Abs(Tolerance);
@@ -787,7 +787,7 @@ Geom2dGcc_Circ2d2TanOnIter (const Geom2dGcc_QCurve&  Qualified1 ,
                               WellDone = Standard_False;
                               if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
                                 Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-                                  GccEnt_BadQualifier::Raise();
+                                  throw GccEnt_BadQualifier();
                                   return;
                               }
                               Standard_Real Tol = Abs(Tolerance);
@@ -876,7 +876,7 @@ Geom2dGcc_Circ2d2TanOnIter (const Geom2dGcc_QCurve& Qualified1 ,
                                 Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
                                 !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
                                 Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-                                  GccEnt_BadQualifier::Raise();
+                                  throw GccEnt_BadQualifier();
                                   return;
                               }
                               gp_Dir2d dirx(1.,0.);
@@ -981,7 +981,7 @@ Geom2dGcc_Circ2d2TanOnIter (const GccEnt_QualifiedCirc& Qualified1 ,
                                 Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
                                 !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
                                 Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-                                  GccEnt_BadQualifier::Raise();
+                                  throw GccEnt_BadQualifier();
                                   return;
                               }
                               Standard_Real Tol = Abs(Tolerance);
@@ -1083,7 +1083,7 @@ Geom2dGcc_Circ2d2TanOnIter (const GccEnt_QualifiedLin&  Qualified1 ,
                                 Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
                                 !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
                                 Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-                                  GccEnt_BadQualifier::Raise();
+                                  throw GccEnt_BadQualifier();
                                   return;
                               }
                               Standard_Real Tol = Abs(Tolerance);
@@ -1181,7 +1181,7 @@ Geom2dGcc_Circ2d2TanOnIter (const Geom2dGcc_QCurve&    Qualified1 ,
   WellDone = Standard_False;
   if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
     Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
       return;
   }
   Standard_Real Tol = Abs(Tolerance);
@@ -1257,7 +1257,7 @@ void Geom2dGcc_Circ2d2TanOnIter::
 WhichQualifier (GccEnt_Position& Qualif1  ,
                 GccEnt_Position& Qualif2  ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
   else {
     Qualif1 = qualifier1;
     Qualif2 = qualifier2;
@@ -1269,14 +1269,14 @@ Tangency1 (Standard_Real&      ParSol         ,
            Standard_Real&      ParArg         ,
            gp_Pnt2d&  PntSol         ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
   else {
     if (TheSame1 == 0) {
       ParSol = 0;
       ParArg = 0;
       PntSol = pnttg1sol;
     }
-    else { StdFail_NotDone::Raise(); }
+    else { throw StdFail_NotDone(); }
   }
 }
 
@@ -1285,7 +1285,7 @@ Tangency2 (Standard_Real&      ParSol         ,
            Standard_Real&      ParArg         ,
            gp_Pnt2d&  PntSol         ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
   else {
     ParSol = 0;
     ParArg = 0;
@@ -1297,7 +1297,7 @@ void Geom2dGcc_Circ2d2TanOnIter::
 CenterOn3 (Standard_Real&      ParArg         ,
            gp_Pnt2d&  PntSol         ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
   else {
     ParArg = 0;
     PntSol = pntcen;
@@ -1307,7 +1307,7 @@ CenterOn3 (Standard_Real&      ParArg         ,
 Standard_Boolean Geom2dGcc_Circ2d2TanOnIter::
 IsTheSame1 () const
 {
-  if (!WellDone) StdFail_NotDone::Raise();
+  if (!WellDone) throw StdFail_NotDone();
 
   if (TheSame1 == 0) 
     return Standard_False;
@@ -1318,6 +1318,6 @@ IsTheSame1 () const
 Standard_Boolean Geom2dGcc_Circ2d2TanOnIter::
 IsTheSame2 () const
 {
-  if (!WellDone) StdFail_NotDone::Raise();
+  if (!WellDone) throw StdFail_NotDone();
   return Standard_False;
 }
index dd5d295..f0d174f 100644 (file)
@@ -67,7 +67,7 @@ Geom2dGcc_Circ2d2TanRad::
   pararg1(1,aNbSolMAX)  ,
   pararg2(1,aNbSolMAX)  
 {
-  if (Radius < 0.) { Standard_NegativeValue::Raise(); }
+  if (Radius < 0.) { throw Standard_NegativeValue(); }
   else {
     Geom2dAdaptor_Curve C1 = Qualified1.Qualified();
     Geom2dAdaptor_Curve C2 = Qualified2.Qualified();
@@ -118,7 +118,7 @@ Geom2dGcc_Circ2d2TanRad::
          }
          else { 
            WellDone = Standard_False;
-           GccEnt_BadQualifier::Raise(); 
+           throw GccEnt_BadQualifier();
          }
        }
       }
@@ -127,7 +127,7 @@ Geom2dGcc_Circ2d2TanRad::
        gp_Lin2d l1(LL1->Lin2d());
        if (Qualified1.IsEnclosing()) {
          WellDone = Standard_False;
-         GccEnt_BadQualifier::Raise();
+         throw GccEnt_BadQualifier();
        }
        else {
          GccEnt_QualifiedLin Ql1 = GccEnt_QualifiedLin(l1,
@@ -162,7 +162,7 @@ Geom2dGcc_Circ2d2TanRad::
            }
            else { 
              WellDone = Standard_False;
-             GccEnt_BadQualifier::Raise(); 
+             throw GccEnt_BadQualifier();
            }
          }
        }
@@ -177,7 +177,7 @@ Geom2dGcc_Circ2d2TanRad::
        gp_Lin2d l1(LL1->Lin2d());
        if (Qualified1.IsEnclosing()) {
          WellDone = Standard_False;
-         GccEnt_BadQualifier::Raise();
+         throw GccEnt_BadQualifier();
        }
        else {
          GccEnt_QualifiedLin Ql1 = GccEnt_QualifiedLin(l1,
@@ -212,7 +212,7 @@ Geom2dGcc_Circ2d2TanRad::
        gp_Lin2d l2(LL2->Lin2d());
        if (Qualified2.IsEnclosing()) {
          WellDone = Standard_False;
-         GccEnt_BadQualifier::Raise();
+         throw GccEnt_BadQualifier();
        }
        else {
          GccEnt_QualifiedLin Ql2 = GccEnt_QualifiedLin(l2,
@@ -274,7 +274,7 @@ Geom2dGcc_Circ2d2TanRad::
   pararg1(1,8)  ,
   pararg2(1,8)  
 {
-  if (Radius < 0.) { Standard_NegativeValue::Raise(); }
+  if (Radius < 0.) { throw Standard_NegativeValue(); }
   else {
     Geom2dAdaptor_Curve C1 = Qualified1.Qualified();
     Handle(Geom2d_Curve) CC1 = C1.Curve();
@@ -345,7 +345,7 @@ Geom2dGcc_Circ2d2TanRad::
   pararg1(1,2)  ,
   pararg2(1,2)  
 {
-  if (Radius < 0.) { Standard_NegativeValue::Raise(); }
+  if (Radius < 0.) { throw Standard_NegativeValue(); }
   else {
 
 //=============================================================================
@@ -403,8 +403,8 @@ Standard_Integer Geom2dGcc_Circ2d2TanRad::
 gp_Circ2d Geom2dGcc_Circ2d2TanRad::
   ThisSolution (const Standard_Integer Index) const 
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   return cirsol(Index);
 }
 
@@ -413,8 +413,8 @@ void Geom2dGcc_Circ2d2TanRad::
                        GccEnt_Position& Qualif1 ,
                        GccEnt_Position& Qualif2) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     if (Invert) {
       Qualif1 = qualifier2(Index);
@@ -433,8 +433,8 @@ void Geom2dGcc_Circ2d2TanRad::
                   Standard_Real&   ParArg,
                   gp_Pnt2d&        PntSol) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     if (Invert) {
       if (TheSame2(Index) == 0) {
@@ -442,7 +442,7 @@ void Geom2dGcc_Circ2d2TanRad::
        ParArg = pararg2(Index);
         PntSol = pnttg2sol(Index);
       }
-      else { StdFail_NotDone::Raise(); }
+      else { throw StdFail_NotDone(); }
     }
     else {
       if (TheSame1(Index) == 0) {
@@ -450,7 +450,7 @@ void Geom2dGcc_Circ2d2TanRad::
        ParArg = pararg1(Index);
         PntSol = pnttg1sol(Index);
       }
-      else { StdFail_NotDone::Raise(); }
+      else { throw StdFail_NotDone(); }
     }
   }
 }
@@ -461,8 +461,8 @@ void Geom2dGcc_Circ2d2TanRad::
               Standard_Real& ParArg,
               gp_Pnt2d& PntSol) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     if (!Invert) {
       if (TheSame2(Index) == 0) {
@@ -470,7 +470,7 @@ void Geom2dGcc_Circ2d2TanRad::
        ParArg = pararg2(Index);
         PntSol = pnttg2sol(Index);
       }
-      else { StdFail_NotDone::Raise(); }
+      else { throw StdFail_NotDone(); }
     }
     else {
       if (TheSame1(Index) == 0) {
@@ -478,7 +478,7 @@ void Geom2dGcc_Circ2d2TanRad::
        ParArg = pararg1(Index);
         PntSol = pnttg1sol(Index);
       }
-      else { StdFail_NotDone::Raise(); }
+      else { throw StdFail_NotDone(); }
     }
   }
 }
@@ -486,8 +486,8 @@ void Geom2dGcc_Circ2d2TanRad::
 Standard_Boolean Geom2dGcc_Circ2d2TanRad::
    IsTheSame1 (const Standard_Integer Index) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   if (Invert) {
     if (TheSame2(Index) == 0) { return Standard_False; }
     else { return Standard_True; }
@@ -501,8 +501,8 @@ Standard_Boolean Geom2dGcc_Circ2d2TanRad::
 Standard_Boolean Geom2dGcc_Circ2d2TanRad::
    IsTheSame2 (const Standard_Integer Index) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   if (!Invert) {
     if (TheSame2(Index) == 0) { return Standard_False; }
     else { return Standard_True; }
index 853f75c..2160dba 100644 (file)
@@ -94,7 +94,7 @@ pararg2(1,aNbSolMAX)
     !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
     Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
 
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
       return;
   }
   gp_Lin2d L1 = Qualified1.Qualified();
@@ -105,7 +105,7 @@ pararg2(1,aNbSolMAX)
   gp_Pnt2d origin1(lxloc,lyloc);
   gp_Dir2d normL1(-y1dir,x1dir);
   Geom2dAdaptor_Curve Cu2= Qualified2.Qualified();
-  if (Radius < 0.0) { Standard_NegativeValue::Raise(); }
+  if (Radius < 0.0) { throw Standard_NegativeValue(); }
   else {
     if (Qualified1.IsEnclosed() && Qualified2.IsEnclosed()) {
       //   =======================================================
@@ -281,13 +281,13 @@ pararg2(1,aNbSolMAX)
     Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
     !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
     Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
       return;
   }
   gp_Circ2d C1 = Qualified1.Qualified();
   gp_Pnt2d center1(C1.Location());
   Geom2dAdaptor_Curve Cu2 = Qualified2.Qualified();
-  if (Radius < 0.0) { Standard_NegativeValue::Raise(); }
+  if (Radius < 0.0) { throw Standard_NegativeValue(); }
   else {
     if (Qualified1.IsEnclosed() && Qualified2.IsEnclosed()) {
       //   =======================================================
@@ -470,11 +470,11 @@ pararg2(1,aNbSolMAX)
   NbrSol = 0;
   if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
     Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
       return;
   }
   Geom2dAdaptor_Curve Cu1 = Qualified1.Qualified();
-  if (Radius < 0.0) { Standard_NegativeValue::Raise(); }
+  if (Radius < 0.0) { throw Standard_NegativeValue(); }
   else {
     if (Qualified1.IsEnclosed()) {
       //    ===========================
@@ -753,12 +753,12 @@ pararg2(1,aNbSolMAX)
     Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
     !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
     Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
       return;
   }
   Geom2dAdaptor_Curve Cu1 = Qualified1.Qualified();
   Geom2dAdaptor_Curve Cu2 = Qualified2.Qualified();
-  if (Radius < 0.0) { Standard_NegativeValue::Raise(); }
+  if (Radius < 0.0) { throw Standard_NegativeValue(); }
   else {
     if (Qualified1.IsEnclosed() && Qualified2.IsEnclosed()) {
       //   =======================================================
@@ -918,8 +918,8 @@ NbSolutions () const { return NbrSol; }
 gp_Circ2d Geom2dGcc_Circ2d2TanRadGeo::
 ThisSolution (const Standard_Integer Index) const 
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   return cirsol(Index);
 }
 
@@ -928,8 +928,8 @@ WhichQualifier(const Standard_Integer Index   ,
                GccEnt_Position& Qualif1 ,
                GccEnt_Position& Qualif2 ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     Qualif1 = qualifier1(Index);
     Qualif2 = qualifier2(Index);
@@ -941,15 +941,15 @@ Tangency1 (const Standard_Integer Index,
            Standard_Real&   ParSol,
            Standard_Real&   ParArg,
            gp_Pnt2d&        PntSol) const{
-             if (!WellDone) { StdFail_NotDone::Raise(); }
-             else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+             if (!WellDone) { throw StdFail_NotDone(); }
+             else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
              else {
                if (TheSame1(Index) == 0) {
                  ParSol = par1sol(Index);
                  ParArg = pararg1(Index);
                  PntSol = gp_Pnt2d(pnttg1sol(Index));
                }
-               else { StdFail_NotDone::Raise(); }
+               else { throw StdFail_NotDone(); }
              }
 }
 
@@ -958,23 +958,23 @@ Tangency2 (const Standard_Integer Index,
            Standard_Real&   ParSol,
            Standard_Real&   ParArg,
            gp_Pnt2d&        PntSol) const{
-             if (!WellDone) { StdFail_NotDone::Raise(); }
-             else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+             if (!WellDone) { throw StdFail_NotDone(); }
+             else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
              else {
                if (TheSame2(Index) == 0) {
                  ParSol = par2sol(Index);
                  ParArg = pararg2(Index);
                  PntSol = gp_Pnt2d(pnttg2sol(Index));
                }
-               else { StdFail_NotDone::Raise(); }
+               else { throw StdFail_NotDone(); }
              }
 }
 
 Standard_Boolean Geom2dGcc_Circ2d2TanRadGeo::
 IsTheSame1 (const Standard_Integer Index) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
 
   if (TheSame1(Index) == 0) { return Standard_False; }
   return Standard_True;
@@ -983,8 +983,8 @@ IsTheSame1 (const Standard_Integer Index) const
 Standard_Boolean Geom2dGcc_Circ2d2TanRadGeo::
 IsTheSame2 (const Standard_Integer Index) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
 
   if (TheSame2(Index) == 0) { return Standard_False; }
   return Standard_True;
index 24e8732..792b332 100644 (file)
@@ -550,8 +550,8 @@ Standard_Integer Geom2dGcc_Circ2d3Tan::
 gp_Circ2d Geom2dGcc_Circ2d3Tan::
   ThisSolution (const Standard_Integer Index) const 
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   return cirsol(Index); 
 }
 
@@ -561,8 +561,8 @@ void Geom2dGcc_Circ2d3Tan::
                        GccEnt_Position& Qualif2 ,
                        GccEnt_Position& Qualif3) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     Qualif1 = qualifier1(Index);
     Qualif2 = qualifier2(Index);
@@ -576,15 +576,15 @@ void Geom2dGcc_Circ2d3Tan::
                   Standard_Real&   ParArg,
                   gp_Pnt2d&        PntSol) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     if (TheSame1(Index) == 0) {
       ParSol = par1sol(Index);
       ParArg = pararg1(Index);
       PntSol = pnttg1sol(Index);
     }
-    else { StdFail_NotDone::Raise(); }
+    else { throw StdFail_NotDone(); }
   }
 }
 
@@ -594,15 +594,15 @@ void Geom2dGcc_Circ2d3Tan::
               Standard_Real& ParArg,
               gp_Pnt2d& PntSol) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     if (TheSame2(Index) == 0) {
       ParSol = par2sol(Index);
       ParArg = pararg2(Index);
       PntSol = pnttg2sol(Index);
     }
-    else { StdFail_NotDone::Raise(); }
+    else { throw StdFail_NotDone(); }
   }
 }
 
@@ -612,22 +612,22 @@ void Geom2dGcc_Circ2d3Tan::
               Standard_Real& ParArg,
               gp_Pnt2d& PntSol) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     if (TheSame3(Index) == 0) {
       ParSol = par3sol(Index);
       ParArg = pararg3(Index);
       PntSol = pnttg3sol(Index);
     }
-    else { StdFail_NotDone::Raise(); }
+    else { throw StdFail_NotDone(); }
   }
 }
 
 Standard_Boolean Geom2dGcc_Circ2d3Tan::IsTheSame1 (const Standard_Integer Index) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   if (TheSame1(Index) == 0) { return Standard_False; }
   return Standard_True; 
 }
@@ -635,8 +635,8 @@ Standard_Boolean Geom2dGcc_Circ2d3Tan::IsTheSame1 (const Standard_Integer Index)
 Standard_Boolean Geom2dGcc_Circ2d3Tan::
    IsTheSame2 (const Standard_Integer Index) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   if (TheSame2(Index) == 0) { return Standard_False; }
   return Standard_True;
 }
@@ -644,8 +644,8 @@ Standard_Boolean Geom2dGcc_Circ2d3Tan::
 Standard_Boolean Geom2dGcc_Circ2d3Tan::
    IsTheSame3 (const Standard_Integer Index) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   if (TheSame3(Index) == 0) { return Standard_False; }
   return Standard_True; 
 }
index 1584398..a709ebd 100644 (file)
@@ -69,7 +69,7 @@ Geom2dGcc_Circ2d3TanIter (const Geom2dGcc_QCurve& Qualified1 ,
                               Qualified2.IsOutside() || Qualified2.IsUnqualified()) ||
                               !(Qualified3.IsEnclosed() || Qualified3.IsEnclosing() || 
                               Qualified3.IsOutside() || Qualified3.IsUnqualified())) {
-                                GccEnt_BadQualifier::Raise();
+                                throw GccEnt_BadQualifier();
                                 return;
                             }
                             Geom2dAdaptor_Curve Cu1 = Qualified1.Qualified();
@@ -193,7 +193,7 @@ Geom2dGcc_Circ2d3TanIter (const GccEnt_QualifiedCirc& Qualified1 ,
                               Qualified2.IsOutside() || Qualified2.IsUnqualified()) ||
                               !(Qualified3.IsEnclosed() || Qualified3.IsEnclosing() || 
                               Qualified3.IsOutside() || Qualified3.IsUnqualified())) {
-                                GccEnt_BadQualifier::Raise();
+                                throw GccEnt_BadQualifier();
                                 return;
                             }
                             gp_Circ2d C1 = Qualified1.Qualified();
@@ -322,7 +322,7 @@ Geom2dGcc_Circ2d3TanIter (const GccEnt_QualifiedCirc& Qualified1 ,
                               Qualified2.IsOutside() || Qualified2.IsUnqualified()) ||
                               !(Qualified3.IsEnclosed() || Qualified3.IsEnclosing() || 
                               Qualified3.IsOutside() || Qualified3.IsUnqualified())) {
-                                GccEnt_BadQualifier::Raise();
+                                throw GccEnt_BadQualifier();
                                 return;
                             }
                             gp_Circ2d C1 = Qualified1.Qualified();
@@ -454,7 +454,7 @@ Geom2dGcc_Circ2d3TanIter (const GccEnt_QualifiedLin& Qualified1 ,
                               Qualified2.IsOutside() || Qualified2.IsUnqualified()) ||
                               !(Qualified3.IsEnclosed() || Qualified3.IsEnclosing() || 
                               Qualified3.IsOutside() || Qualified3.IsUnqualified())) {
-                                GccEnt_BadQualifier::Raise();
+                                throw GccEnt_BadQualifier();
                                 return;
                             }
                             gp_Lin2d L1 = Qualified1.Qualified();
@@ -586,7 +586,7 @@ Geom2dGcc_Circ2d3TanIter (const GccEnt_QualifiedLin&  Qualified1 ,
                               Qualified2.IsOutside() || Qualified2.IsUnqualified()) ||
                               !(Qualified3.IsEnclosed() || Qualified3.IsEnclosing() || 
                               Qualified3.IsOutside() || Qualified3.IsUnqualified())) {
-                                GccEnt_BadQualifier::Raise();
+                                throw GccEnt_BadQualifier();
                                 return;
                             }
                             gp_Lin2d L1 = Qualified1.Qualified();
@@ -709,7 +709,7 @@ Geom2dGcc_Circ2d3TanIter (const Geom2dGcc_QCurve& Qualified1 ,
                               Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
                               !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
                               Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-                                GccEnt_BadQualifier::Raise();
+                                throw GccEnt_BadQualifier();
                                 return;
                             }
                             gp_Circ2d C1(gp_Ax2d(Point3,gp_Dir2d(1.,0.)),0.);
@@ -822,7 +822,7 @@ Geom2dGcc_Circ2d3TanIter (const Geom2dGcc_QCurve& Qualified1 ,
                             WellDone = Standard_False;
                             if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
                               Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-                                GccEnt_BadQualifier::Raise();
+                                throw GccEnt_BadQualifier();
                                 return;
                             }
                             gp_Dir2d dirx(1.,0.);
@@ -933,7 +933,7 @@ Geom2dGcc_Circ2d3TanIter (const GccEnt_QualifiedLin&  Qualified1 ,
                               Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
                               !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
                               Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-                                GccEnt_BadQualifier::Raise();
+                                throw GccEnt_BadQualifier();
                                 return;
                             }
                             gp_Dir2d dirx(1.,0.);
@@ -1054,7 +1054,7 @@ Geom2dGcc_Circ2d3TanIter (const GccEnt_QualifiedCirc& Qualified1 ,
                               Qualified2.IsOutside() || Qualified2.IsUnqualified()) ||
                               !(Qualified3.IsEnclosed() || Qualified3.IsEnclosing() || 
                               Qualified3.IsOutside() || Qualified3.IsUnqualified())) {
-                                GccEnt_BadQualifier::Raise();
+                                throw GccEnt_BadQualifier();
                                 return;
                             }
                             gp_Circ2d C1 = Qualified1.Qualified();
@@ -1181,7 +1181,7 @@ Geom2dGcc_Circ2d3TanIter (const GccEnt_QualifiedCirc& Qualified1 ,
                               Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
                               !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
                               Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-                                GccEnt_BadQualifier::Raise();
+                                throw GccEnt_BadQualifier();
                                 return;
                             }
                             gp_Circ2d C1 = Qualified1.Qualified();
@@ -1287,7 +1287,7 @@ WhichQualifier (GccEnt_Position& Qualif1  ,
                 GccEnt_Position& Qualif2  ,
                 GccEnt_Position& Qualif3  ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
   else {
     Qualif1 = qualifier1;
     Qualif2 = qualifier2;
@@ -1299,14 +1299,14 @@ void Geom2dGcc_Circ2d3TanIter::
 Tangency1 (Standard_Real&      ParSol ,
            Standard_Real&      ParArg ,
            gp_Pnt2d&           PntSol ) const{
-             if (!WellDone) { StdFail_NotDone::Raise(); }
+             if (!WellDone) { throw StdFail_NotDone(); }
              else {
                if (TheSame1 == 0) {
                  ParSol = par1sol;
                  ParArg = pararg1;
                  PntSol = pnttg1sol;
                }
-               else { StdFail_NotDone::Raise(); }
+               else { throw StdFail_NotDone(); }
              }
 }
 
@@ -1314,7 +1314,7 @@ void Geom2dGcc_Circ2d3TanIter::
 Tangency2 (Standard_Real&      ParSol         ,
            Standard_Real&      ParArg         ,
            gp_Pnt2d&  PntSol         ) const{
-             if (!WellDone) { StdFail_NotDone::Raise(); }
+             if (!WellDone) { throw StdFail_NotDone(); }
              else {
                ParSol = par2sol;
                ParArg = pararg2;
@@ -1326,7 +1326,7 @@ void Geom2dGcc_Circ2d3TanIter::
 Tangency3 (Standard_Real&      ParSol         ,
            Standard_Real&      ParArg         ,
            gp_Pnt2d&  PntSol         ) const{
-             if (!WellDone) { StdFail_NotDone::Raise(); }
+             if (!WellDone) { throw StdFail_NotDone(); }
              else {
                ParSol = par3sol;
                ParArg = pararg3;
@@ -1337,7 +1337,7 @@ Tangency3 (Standard_Real&      ParSol         ,
 Standard_Boolean Geom2dGcc_Circ2d3TanIter::
 IsTheSame1 () const
 {
-  if (!WellDone) StdFail_NotDone::Raise();
+  if (!WellDone) throw StdFail_NotDone();
 
   if (TheSame1 == 0) 
     return Standard_False;
@@ -1349,7 +1349,7 @@ IsTheSame1 () const
 Standard_Boolean Geom2dGcc_Circ2d3TanIter::
 IsTheSame2 () const
 {
-  if (!WellDone) StdFail_NotDone::Raise();
+  if (!WellDone) throw StdFail_NotDone();
 
   if (TheSame3 == 0) 
     return Standard_False;
@@ -1361,7 +1361,7 @@ IsTheSame2 () const
 Standard_Boolean Geom2dGcc_Circ2d3TanIter::
 IsTheSame3 () const
 {
-  if (!WellDone) StdFail_NotDone::Raise();
+  if (!WellDone) throw StdFail_NotDone();
 
   return Standard_True;
 }
index 83e63d1..df9c938 100644 (file)
@@ -115,8 +115,8 @@ Standard_Integer Geom2dGcc_Circ2dTanCen::
 gp_Circ2d Geom2dGcc_Circ2dTanCen::
   ThisSolution (const Standard_Integer Index) const 
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   return cirsol(Index); 
 }
 
@@ -124,8 +124,8 @@ void Geom2dGcc_Circ2dTanCen::
   WhichQualifier(const Standard_Integer Index,
                       GccEnt_Position& Qualif1) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else { Qualif1 = qualifier1(Index); }
 }
 
@@ -135,23 +135,23 @@ void Geom2dGcc_Circ2dTanCen::
                   Standard_Real&   ParArg,
                   gp_Pnt2d&        PntSol) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     if (TheSame1(Index) == 0) {
       ParSol = par1sol(Index);
       ParArg = pararg1(Index);
       PntSol = pnttg1sol(Index);
     }
-    else { StdFail_NotDone::Raise(); }
+    else { throw StdFail_NotDone(); }
   }
 }
 
 Standard_Boolean Geom2dGcc_Circ2dTanCen::
    IsTheSame1 (const Standard_Integer Index) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   if (TheSame1(Index) == 0) { return Standard_False; }
   return Standard_True; 
 }
index a7925e2..d7487d3 100644 (file)
@@ -62,9 +62,9 @@ Geom2dGcc_Circ2dTanCenGeo (const Geom2dGcc_QCurve&  Qualified1,
   Geom2dAdaptor_Curve curve = Qualified1.Qualified();
   Extrema_ExtPC2d distmin(Pcenter,curve,Geom2dGcc_CurveTool::NbSamples(curve),
     Geom2dGcc_CurveTool::EpsX(curve,Tol),Tol);
-  if (!distmin.IsDone() ) { Standard_Failure::Raise(); }
+  if (!distmin.IsDone() ) { throw Standard_Failure(); }
   Standard_Integer nbext = distmin.NbExt();
-  if(nbext==0) { Standard_Failure::Raise(); }
+  if(nbext==0) { throw Standard_Failure(); }
   while (i<=nbext) {
     thePar = distmin.Point(i).Parameter();
     if (distmin.SquareDistance(i)<theDist2(1) && 
@@ -130,7 +130,7 @@ NbSolutions () const { return NbrSol; }
 gp_Circ2d Geom2dGcc_Circ2dTanCenGeo::
 ThisSolution (const Standard_Integer Index) const 
 {
-  if (Index > NbrSol || Index <= 0) Standard_OutOfRange::Raise();
+  if (Index > NbrSol || Index <= 0) throw Standard_OutOfRange();
 
   return cirsol(Index);
 }
@@ -139,8 +139,8 @@ void Geom2dGcc_Circ2dTanCenGeo::
 WhichQualifier(const Standard_Integer Index   ,
                GccEnt_Position& Qualif1 ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     Qualif1 = qualifier1(Index);
   }
@@ -152,10 +152,10 @@ Tangency1 (const Standard_Integer Index,
            Standard_Real&   ParArg,
            gp_Pnt2d& PntSol) const{
              if (!WellDone) {
-               StdFail_NotDone::Raise();
+               throw StdFail_NotDone();
              }
              else if (Index <= 0 ||Index > NbrSol) {
-               Standard_OutOfRange::Raise();
+               throw Standard_OutOfRange();
              }
              else {
                PntSol = gp_Pnt2d(pnttg1sol(Index));
index 7360ebf..53f2844 100644 (file)
@@ -48,7 +48,7 @@ Geom2dGcc_Circ2dTanOnRad::
   parcen3(1,8)  
 {
   if (Radius < 0.) {
-    Standard_NegativeValue::Raise();
+    throw Standard_NegativeValue();
   }
   else {
     Geom2dAdaptor_Curve C1 = Qualified1.Qualified();
@@ -159,7 +159,7 @@ Geom2dGcc_Circ2dTanOnRad::
   parcen3(1,8)  
 {
   if (Radius < 0.) {
-    Standard_NegativeValue::Raise();
+    throw Standard_NegativeValue();
   }
   else {
     gp_Pnt2d point1(Point1->Pnt2d());
@@ -239,8 +239,8 @@ Standard_Integer Geom2dGcc_Circ2dTanOnRad::
 gp_Circ2d Geom2dGcc_Circ2dTanOnRad::
   ThisSolution (const Standard_Integer Index) const 
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   return cirsol(Index);
 }
 
@@ -248,8 +248,8 @@ void Geom2dGcc_Circ2dTanOnRad::
   WhichQualifier (const Standard_Integer Index,
                        GccEnt_Position& Qualif1) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else { Qualif1 = qualifier1(Index); }
 }
 
@@ -259,15 +259,15 @@ void Geom2dGcc_Circ2dTanOnRad::
                   Standard_Real&   ParArg,
                   gp_Pnt2d&        PntSol) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     if (TheSame1(Index) == 0) {
       ParSol = par1sol(Index);
       ParArg = pararg1(Index);
       PntSol = pnttg1sol(Index);
     }
-    else { StdFail_NotDone::Raise(); }
+    else { throw StdFail_NotDone(); }
   }
 }
 
@@ -276,8 +276,8 @@ void Geom2dGcc_Circ2dTanOnRad::
               Standard_Real& ParArg,
               gp_Pnt2d& PntSol) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     ParArg = parcen3(Index);
     PntSol = pntcen3(Index);
@@ -287,8 +287,8 @@ void Geom2dGcc_Circ2dTanOnRad::
 Standard_Boolean Geom2dGcc_Circ2dTanOnRad::
    IsTheSame1 (const Standard_Integer Index) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   if (TheSame1(Index) == 0) { return Standard_False; }
   return Standard_True; 
 }
index 44cb1b9..da9b436 100644 (file)
@@ -94,14 +94,14 @@ parcen3(1,8)
   NbrSol = 0;
   if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
     Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
       return;
   }
   Standard_Integer nbrcote1 = 0;
   TColStd_Array1OfReal Coef(1,2);
   Geom2dAdaptor_Curve Cu1 = Qualified1.Qualified();
 
-  if (Radius < 0.0) { Standard_NegativeValue::Raise(); }
+  if (Radius < 0.0) { throw Standard_NegativeValue(); }
   else {
     if (Qualified1.IsEnclosed()) {
       //    ===========================
@@ -204,14 +204,14 @@ parcen3(1,8)
   NbrSol = 0;
   if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
     Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
       return;
   }
   TColStd_Array1OfReal cote1(1,2);
   Geom2dAdaptor_Curve Cu1 = Qualified1.Qualified();
 
   if (Radius < 0.0) {
-    Standard_NegativeValue::Raise();
+    throw Standard_NegativeValue();
   }
   else {
     if (Qualified1.IsEnclosed()) {
@@ -317,7 +317,7 @@ parcen3(1,8)
   NbrSol = 0;
   if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
     Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
       return;
   }
   TColStd_Array1OfReal cote1(1,2);
@@ -326,7 +326,7 @@ parcen3(1,8)
   Standard_Real R1 = C1.Radius();
 
   if (Radius < 0.0) {
-    Standard_NegativeValue::Raise();
+    throw Standard_NegativeValue();
   }
   else {
     if (Qualified1.IsEnclosed()) {
@@ -440,7 +440,7 @@ parcen3(1,8)
   NbrSol = 0;
   if (!(Qualified1.IsEnclosed() ||
     Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
       return;
   }
   Standard_Integer nbrcote1=0;
@@ -451,7 +451,7 @@ parcen3(1,8)
   gp_Dir2d norm1(-dir1.Y(),dir1.X());
 
   if (Radius < 0.0) {
-    Standard_NegativeValue::Raise();
+    throw Standard_NegativeValue();
   }
   else {
     if (Qualified1.IsEnclosed()) {
@@ -562,14 +562,14 @@ parcen3(1,8)
   NbrSol = 0;
   if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
     Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
       return;
   }
   TColStd_Array1OfReal cote1(1,2);
   Geom2dAdaptor_Curve Cu1 = Qualified1.Qualified();
 
   if (Radius < 0.0) {
-    Standard_NegativeValue::Raise();
+    throw Standard_NegativeValue();
   }
   else {
     if (Qualified1.IsEnclosed()) {
@@ -677,7 +677,7 @@ parcen3(1,8)
   NbrSol = 0;
 
   if (Radius < 0.0) {
-    Standard_NegativeValue::Raise();
+    throw Standard_NegativeValue();
   }
   else {
     //     gp_Dir2d Dir(-y1dir,x1dir);
@@ -725,7 +725,7 @@ ThisSolution (const Standard_Integer Index) const
 {
 
   if (Index > NbrSol || Index <= 0)
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
 
   return cirsol(Index);
 }
@@ -734,8 +734,8 @@ void Geom2dGcc_Circ2dTanOnRadGeo::
 WhichQualifier(const Standard_Integer Index   ,
                GccEnt_Position& Qualif1 ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     Qualif1 = qualifier1(Index);
   }
@@ -747,10 +747,10 @@ Tangency1 (const Standard_Integer Index,
            Standard_Real&   ParArg,
            gp_Pnt2d& PntSol) const{
              if (!WellDone) {
-               StdFail_NotDone::Raise();
+               throw StdFail_NotDone();
              }
              else if (Index <= 0 ||Index > NbrSol) {
-               Standard_OutOfRange::Raise();
+               throw Standard_OutOfRange();
              }
              else {
                ParSol = par1sol(Index);
@@ -764,10 +764,10 @@ CenterOn3 (const Standard_Integer Index,
            Standard_Real&   ParArg, 
            gp_Pnt2d&        PntSol) const {
              if (!WellDone) {
-               StdFail_NotDone::Raise();
+               throw StdFail_NotDone();
              }
              else if (Index <= 0 ||Index > NbrSol) {
-               Standard_OutOfRange::Raise();
+               throw Standard_OutOfRange();
              }
              else {
                ParArg = parcen3(Index);
@@ -778,8 +778,8 @@ CenterOn3 (const Standard_Integer Index,
 Standard_Boolean Geom2dGcc_Circ2dTanOnRadGeo::
 IsTheSame1 (const Standard_Integer Index) const
 {
-  if (!WellDone) StdFail_NotDone::Raise();
-  if (Index <= 0 ||Index > NbrSol) Standard_OutOfRange::Raise();
+  if (!WellDone) throw StdFail_NotDone();
+  if (Index <= 0 ||Index > NbrSol) throw Standard_OutOfRange();
 
   if (TheSame1(Index) == 0) 
     return Standard_False;
index e17c061..d517da0 100644 (file)
@@ -87,7 +87,7 @@ InitDerivative(const math_Vector&  X,
     break;
   default:
     {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
                  }
 }
index c6219a9..ab40ca5 100644 (file)
@@ -137,7 +137,7 @@ void Geom2dGcc_FunctionTanCuCuOnCu::
     break;
   default:
     {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   }
 }
index 11166b6..10ade73 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Geom2dGcc_IsParallel, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Geom2dGcc_IsParallel
   #define Geom2dGcc_IsParallel_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Geom2dGcc_IsParallel::Raise(MESSAGE);
+  if (CONDITION) throw Geom2dGcc_IsParallel(MESSAGE);
 #else
   #define Geom2dGcc_IsParallel_Raise_if(CONDITION, MESSAGE)
 #endif
index c15f81f..3720101 100644 (file)
@@ -313,7 +313,7 @@ Standard_Integer Geom2dGcc_Lin2d2Tan::
 gp_Lin2d Geom2dGcc_Lin2d2Tan::
    ThisSolution (const Standard_Integer Index) const 
 {
-  if (Index > NbrSol || Index <= 0) { Standard_OutOfRange::Raise(); }
+  if (Index > NbrSol || Index <= 0) { throw Standard_OutOfRange(); }
   return linsol(Index);
 }
 
@@ -322,8 +322,8 @@ void Geom2dGcc_Lin2d2Tan::
                         GccEnt_Position& Qualif1,
                         GccEnt_Position& Qualif2) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else { 
     Qualif1 = qualifier1(Index);
     Qualif2 = qualifier2(Index);
@@ -336,8 +336,8 @@ void Geom2dGcc_Lin2d2Tan::
             Standard_Real& ParArg,
             gp_Pnt2d& PntSol) const 
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     ParSol = par1sol(Index);
     ParArg = pararg1(Index);
@@ -351,8 +351,8 @@ void Geom2dGcc_Lin2d2Tan::
                     Standard_Real&     ParArg ,
                     gp_Pnt2d& PntSol ) const 
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else {
     ParSol = par2sol(Index);
     ParArg = pararg2(Index);
index cff2772..144ce67 100644 (file)
@@ -50,7 +50,7 @@ Geom2dGcc_Lin2d2TanIter (const GccEnt_QualifiedCirc& Qualified1 ,
                            //Standard_Real Tol = Abs(Tolang);
 
                            WellDone = Standard_False;
-                           if (Qualified1.IsEnclosed()) { GccEnt_BadQualifier::Raise(); }
+                           if (Qualified1.IsEnclosed()) { throw GccEnt_BadQualifier(); }
                            gp_Circ2d C1 = Qualified1.Qualified();
                            Geom2dAdaptor_Curve Cu2 = Qualified2.Qualified();
                            Standard_Real U1 = Geom2dGcc_CurveTool::FirstParameter(Cu2);
@@ -127,7 +127,7 @@ Geom2dGcc_Lin2d2TanIter (const Geom2dGcc_QCurve& Qualified1 ,
                              Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
                              !(Qualified2.IsEnclosed() || Qualified2.IsEnclosing() || 
                              Qualified2.IsOutside() || Qualified2.IsUnqualified())) {
-                               GccEnt_BadQualifier::Raise();
+                               throw GccEnt_BadQualifier();
                                return;
                            }
                            Geom2dAdaptor_Curve Cu1 = Qualified1.Qualified();
@@ -199,7 +199,7 @@ Geom2dGcc_Lin2d2TanIter (const Geom2dGcc_QCurve& Qualified1 ,
                            WellDone = Standard_False;
                            if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
                              Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-                               GccEnt_BadQualifier::Raise();
+                               throw GccEnt_BadQualifier();
                                return;
                            }
                            Geom2dAdaptor_Curve Cu1 = Qualified1.Qualified();
@@ -247,7 +247,7 @@ IsDone () const { return WellDone; }
 gp_Lin2d Geom2dGcc_Lin2d2TanIter::
 ThisSolution () const 
 {
-  if (!WellDone) StdFail_NotDone::Raise();
+  if (!WellDone) throw StdFail_NotDone();
   return linsol;
 }
 
@@ -255,7 +255,7 @@ void Geom2dGcc_Lin2d2TanIter::
 WhichQualifier (GccEnt_Position& Qualif1  ,
                 GccEnt_Position& Qualif2  ) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
   else {
     Qualif1 = qualifier1;
     Qualif2 = qualifier2;
@@ -266,7 +266,7 @@ void Geom2dGcc_Lin2d2TanIter::
 Tangency1 (Standard_Real& ParSol ,
            Standard_Real& ParArg ,
            gp_Pnt2d& Pnt) const {
-             if (!WellDone) { StdFail_NotDone::Raise(); }
+             if (!WellDone) { throw StdFail_NotDone(); }
              else {
                ParSol = par1sol;
                ParArg = pararg1;
@@ -278,7 +278,7 @@ void Geom2dGcc_Lin2d2TanIter::
 Tangency2 (Standard_Real& ParSol ,
            Standard_Real& ParArg ,
            gp_Pnt2d& Pnt) const {
-             if (!WellDone) { StdFail_NotDone::Raise(); }
+             if (!WellDone) { throw StdFail_NotDone(); }
              else {
                ParSol = par2sol;
                ParArg = pararg2;
index 8bfa019..e75bfa9 100644 (file)
@@ -159,7 +159,7 @@ Standard_Integer Geom2dGcc_Lin2dTanObl::
 gp_Lin2d Geom2dGcc_Lin2dTanObl::
    ThisSolution (const Standard_Integer Index) const {
 
-   if (Index > NbrSol || Index <= 0) { Standard_OutOfRange::Raise(); }
+   if (Index > NbrSol || Index <= 0) { throw Standard_OutOfRange(); }
    return linsol(Index);
  }
 
@@ -167,8 +167,8 @@ void Geom2dGcc_Lin2dTanObl::
    WhichQualifier (const Standard_Integer Index,
                         GccEnt_Position& Qualif1) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
-  else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
+  else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
   else { Qualif1 = qualifier1(Index);   }
 }
 
@@ -177,8 +177,8 @@ void Geom2dGcc_Lin2dTanObl::
               Standard_Real& ParSol,
               Standard_Real& ParArg,
               gp_Pnt2d& PntSol) const {
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      ParSol = par1sol(Index);
      ParArg = pararg1(Index);
@@ -191,8 +191,8 @@ void Geom2dGcc_Lin2dTanObl::
                     Standard_Real&     ParSol ,
                     Standard_Real&     ParArg ,
                     gp_Pnt2d& PntSol ) const {
-   if (!WellDone) { StdFail_NotDone::Raise(); }
-   else if (Index <= 0 ||Index > NbrSol) { Standard_OutOfRange::Raise(); }
+   if (!WellDone) { throw StdFail_NotDone(); }
+   else if (Index <= 0 ||Index > NbrSol) { throw Standard_OutOfRange(); }
    else {
      ParSol = par2sol(Index);
      ParArg = pararg2(Index);
index 67c1473..c0aff19 100644 (file)
@@ -48,7 +48,7 @@ Geom2dGcc_Lin2dTanOblIter (const Geom2dGcc_QCurve&  Qualified1 ,
   WellDone = Standard_False;
   if (!(Qualified1.IsEnclosed() || Qualified1.IsEnclosing() || 
     Qualified1.IsOutside() || Qualified1.IsUnqualified())) {
-      GccEnt_BadQualifier::Raise();
+      throw GccEnt_BadQualifier();
       return;
   }
   Paral2 = Standard_False;
@@ -113,7 +113,7 @@ IsDone () const { return WellDone; }
 
 gp_Lin2d Geom2dGcc_Lin2dTanOblIter::ThisSolution () const 
 {      
-  if (!WellDone) StdFail_NotDone::Raise();
+  if (!WellDone) throw StdFail_NotDone();
 
   return linsol;
 }
@@ -121,7 +121,7 @@ gp_Lin2d Geom2dGcc_Lin2dTanOblIter::ThisSolution () const
 void Geom2dGcc_Lin2dTanOblIter:: 
 WhichQualifier (GccEnt_Position& Qualif1) const
 {
-  if (!WellDone) { StdFail_NotDone::Raise(); }
+  if (!WellDone) { throw StdFail_NotDone(); }
   else {
     Qualif1 = qualifier1;
   }
@@ -134,7 +134,7 @@ void Geom2dGcc_Lin2dTanOblIter::
 Tangency1 (Standard_Real& ParSol    ,
            Standard_Real& ParArg    ,
            gp_Pnt2d& PntSol) const {
-             if (!WellDone) { StdFail_NotDone::Raise(); }
+             if (!WellDone) { throw StdFail_NotDone(); }
              else {
                ParSol = par1sol;
                ParArg = pararg1;
@@ -146,8 +146,8 @@ void Geom2dGcc_Lin2dTanOblIter::
 Intersection2 (Standard_Real&     ParSol ,
                Standard_Real&     ParArg ,
                gp_Pnt2d& PntSol ) const {
-                 if (!WellDone) { StdFail_NotDone::Raise(); }
-                 else if (Paral2) { Geom2dGcc_IsParallel::Raise(); }
+                 if (!WellDone) { throw StdFail_NotDone(); }
+                 else if (Paral2) { throw Geom2dGcc_IsParallel(); }
                  else {
                    PntSol = pntint2sol;
                    ParSol = par2sol;
index 0758fe7..5ff2d37 100644 (file)
@@ -148,7 +148,7 @@ static void BuildPeriodicTangent(
   gp_Vec a_vector ;
   
   if (PointsArray.Length() < 3) {
-    Standard_ConstructionError::Raise(); 
+    throw Standard_ConstructionError();
     }   
  
   if (!TangentFlags.Value(1)) {
@@ -194,7 +194,7 @@ static void BuildTangents(const TColgp_Array1OfPnt&      PointsArray,
  degree = 3 ;
 
  if ( PointsArray.Length() < 3) {
-   Standard_ConstructionError::Raise(); 
+   throw Standard_ConstructionError();
    }   
  if (PointsArray.Length() == 3) {
    degree = 2 ;
@@ -332,7 +332,7 @@ myTangentRequest(Standard_False)
                                   myPoints->Upper()) ;
 
  if (!result) {
-   Standard_ConstructionError::Raise();
+   throw Standard_ConstructionError();
    }
  BuildParameters(PeriodicFlag,
                 PointsPtr->Array1(),
@@ -372,7 +372,7 @@ myTangentRequest(Standard_False)
 
  if (PeriodicFlag) {
    if ((PointsPtr->Length()) + 1 != ParametersPtr->Length()) {
-     Standard_ConstructionError::Raise();
+     throw Standard_ConstructionError();
    }
  }
  myTangents = 
@@ -383,13 +383,13 @@ myTangentRequest(Standard_False)
                                    myPoints->Upper()) ;
  
  if (!result) {
-   Standard_ConstructionError::Raise();
+   throw Standard_ConstructionError();
    }
                
  result =
  CheckParameters(ParametersPtr->Array1()) ;
  if (!result) {
-   Standard_ConstructionError::Raise();
+   throw Standard_ConstructionError();
    }
        
  for (ii = myPoints->Lower() ; ii <= myPoints->Upper() ; ii++) {
@@ -414,7 +414,7 @@ void GeomAPI_Interpolate::Load(
  myTangentFlags = TangentFlagsPtr ;
  if (Tangents.Length() != myPoints->Length() ||
      TangentFlagsPtr->Length() != myPoints->Length()) {
-   Standard_ConstructionError::Raise();
+   throw Standard_ConstructionError();
    }
  result  = 
    CheckTangents(Tangents,
@@ -435,7 +435,7 @@ void GeomAPI_Interpolate::Load(
     }
   }
  else {
-   Standard_ConstructionError::Raise();
+   throw Standard_ConstructionError();
    }
  
   
@@ -461,7 +461,7 @@ void GeomAPI_Interpolate::Load(const gp_Vec& InitialTangent,
                  myTangentFlags->Array1(),
                  myTolerance) ;
   if (!result) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
     }
 
   if(Scale) {
@@ -906,7 +906,7 @@ void GeomAPI_Interpolate::PerformNonPeriodic()
 const Handle(Geom_BSplineCurve)& GeomAPI_Interpolate::Curve() const 
 {
   if ( !myIsDone) 
-    StdFail_NotDone::Raise(" ");
+    throw StdFail_NotDone(" ");
   return myCurve;
 }
 
index ac686a3..fcec59f 100644 (file)
@@ -191,7 +191,7 @@ void GeomAPI_PointsToBSpline::Init
    const GeomAbs_Shape         Continuity,
    const Standard_Real         Tol3D)
 {
-  if (Params.Length() != Points.Length()) Standard_OutOfRange::Raise("");
+  if (Params.Length() != Points.Length()) throw Standard_OutOfRange("");
 
   Standard_Real Tol2D = 0.; // dummy argument for BSplineCompute.
   Standard_Integer Nbp = Params.Length();
@@ -346,7 +346,7 @@ void GeomAPI_PointsToBSpline::Init
 const Handle(Geom_BSplineCurve)& GeomAPI_PointsToBSpline::Curve() const 
 {
   if ( !myIsDone) 
-    StdFail_NotDone::Raise("GeomAPI_PointsToBSpline::Curve ");
+    throw StdFail_NotDone("GeomAPI_PointsToBSpline::Curve ");
   return myCurve;
 }
 
index 58b15d0..94df9a8 100644 (file)
@@ -81,7 +81,7 @@ Handle(Geom_Curve) GeomAdaptor::MakeCurve (const Adaptor3d_Curve& HC)
     break;
 
   default:
-    Standard_DomainError::Raise("GeomAdaptor::MakeCurve : OtherCurve");
+    throw Standard_DomainError("GeomAdaptor::MakeCurve : OtherCurve");
 
   }
 
@@ -152,7 +152,7 @@ Handle(Geom_Surface) GeomAdaptor::MakeSurface(const Adaptor3d_Surface& HS,
     break;
 
   case GeomAbs_OtherSurface:
-    Standard_DomainError::Raise("GeomAdaptor::MakeSurface : OtherSurface");
+    throw Standard_DomainError("GeomAdaptor::MakeSurface : OtherSurface");
     break;
   }
 
index 90f9214..2cb8276 100644 (file)
@@ -211,11 +211,11 @@ GeomAbs_Shape GeomAdaptor_Curve::Continuity() const
       case GeomAbs_G1: return GeomAbs_G1;
       case GeomAbs_G2: return GeomAbs_G2;
       default:
-        Standard_NoSuchObject::Raise("GeomAdaptor_Curve::Continuity");
+        throw Standard_NoSuchObject("GeomAdaptor_Curve::Continuity");
     }
   }
   else if (myTypeCurve == GeomAbs_OtherCurve) {
-    Standard_NoSuchObject::Raise("GeomAdaptor_Curve::Contunuity");
+    throw Standard_NoSuchObject("GeomAdaptor_Curve::Contunuity");
   }
 
   return GeomAbs_CN;
@@ -239,7 +239,7 @@ Standard_Integer GeomAdaptor_Curve::NbIntervals(const GeomAbs_Shape S) const
       switch ( S) {
       case GeomAbs_G1:
       case GeomAbs_G2:
-        Standard_DomainError::Raise("GeomAdaptor_Curve::NbIntervals");
+        throw Standard_DomainError("GeomAdaptor_Curve::NbIntervals");
         break;
       case GeomAbs_C0:
         myNbIntervals = 1;
@@ -310,7 +310,7 @@ Standard_Integer GeomAdaptor_Curve::NbIntervals(const GeomAbs_Shape S) const
     switch(S){
     case GeomAbs_G1:
     case GeomAbs_G2:
-      Standard_DomainError::Raise("GeomAdaptor_Curve::NbIntervals");
+      throw Standard_DomainError("GeomAdaptor_Curve::NbIntervals");
       break;
     case GeomAbs_C0: BaseS = GeomAbs_C1; break;
     case GeomAbs_C1: BaseS = GeomAbs_C2; break;
@@ -359,7 +359,7 @@ void GeomAdaptor_Curve::Intervals(TColStd_Array1OfReal& T,
        switch ( S) {
        case GeomAbs_G1:
        case GeomAbs_G2:
-         Standard_DomainError::Raise("Geom2dAdaptor_Curve::NbIntervals");
+         throw Standard_DomainError("Geom2dAdaptor_Curve::NbIntervals");
          break;
        case GeomAbs_C0:
          myNbIntervals = 1;
@@ -444,7 +444,7 @@ void GeomAdaptor_Curve::Intervals(TColStd_Array1OfReal& T,
     switch(S){
     case GeomAbs_G1:
     case GeomAbs_G2:
-      Standard_DomainError::Raise("GeomAdaptor_Curve::NbIntervals");
+      throw Standard_DomainError("GeomAdaptor_Curve::NbIntervals");
       break;
     case GeomAbs_C0: BaseS = GeomAbs_C1; break;
     case GeomAbs_C1: BaseS = GeomAbs_C2; break;
@@ -885,9 +885,7 @@ Standard_Integer GeomAdaptor_Curve::Degree() const
   else if (myTypeCurve == GeomAbs_BSplineCurve)
     return myBSplineCurve->Degree();
   else
-    Standard_NoSuchObject::Raise();
-  // portage WNT 
-  return 0;
+    throw Standard_NoSuchObject();
 }
 
 //=======================================================================
@@ -918,9 +916,7 @@ Standard_Integer GeomAdaptor_Curve::NbPoles() const
   else if (myTypeCurve == GeomAbs_BSplineCurve)
     return myBSplineCurve->NbPoles();
   else
-    Standard_NoSuchObject::Raise();
-  // portage WNT
-  return 0;
+    throw Standard_NoSuchObject();
 }
 
 //=======================================================================
@@ -931,7 +927,7 @@ Standard_Integer GeomAdaptor_Curve::NbPoles() const
 Standard_Integer GeomAdaptor_Curve::NbKnots() const
 {
   if ( myTypeCurve != GeomAbs_BSplineCurve)
-    Standard_NoSuchObject::Raise("GeomAdaptor_Curve::NbKnots");
+    throw Standard_NoSuchObject("GeomAdaptor_Curve::NbKnots");
   return myBSplineCurve->NbKnots();
 }
 
@@ -943,7 +939,7 @@ Standard_Integer GeomAdaptor_Curve::NbKnots() const
 Handle(Geom_BezierCurve) GeomAdaptor_Curve::Bezier() const 
 {
  if ( myTypeCurve != GeomAbs_BezierCurve)
-    Standard_NoSuchObject::Raise("GeomAdaptor_Curve::Bezier");
+    throw Standard_NoSuchObject("GeomAdaptor_Curve::Bezier");
   return Handle(Geom_BezierCurve)::DownCast (myCurve);
 }
 
@@ -955,7 +951,7 @@ Handle(Geom_BezierCurve) GeomAdaptor_Curve::Bezier() const
 Handle(Geom_BSplineCurve) GeomAdaptor_Curve::BSpline() const 
 {
  if ( myTypeCurve != GeomAbs_BSplineCurve)
-    Standard_NoSuchObject::Raise("GeomAdaptor_Curve::BSpline");
+    throw Standard_NoSuchObject("GeomAdaptor_Curve::BSpline");
 
   return myBSplineCurve;
 }
@@ -968,6 +964,6 @@ Handle(Geom_BSplineCurve) GeomAdaptor_Curve::BSpline() const
 Handle(Geom_OffsetCurve) GeomAdaptor_Curve::OffsetCurve() const
 {
   if ( myTypeCurve != GeomAbs_OffsetCurve)
-    Standard_NoSuchObject::Raise("GeomAdaptor_Curve::OffsetCurve");
+    throw Standard_NoSuchObject("GeomAdaptor_Curve::OffsetCurve");
   return Handle(Geom_OffsetCurve)::DownCast(myCurve);
 }
index 4b5a090..21bf1df 100644 (file)
@@ -61,7 +61,7 @@ inline GeomAdaptor_Curve::GeomAdaptor_Curve(const Handle(Geom_Curve)& C,
 
 inline void GeomAdaptor_Curve::Load(const Handle(Geom_Curve)& C)
 {
-  if ( C.IsNull()) Standard_NullObject::Raise();
+  if ( C.IsNull()) throw Standard_NullObject();
   
   load(C,C->FirstParameter(),C->LastParameter());
 }
@@ -75,9 +75,9 @@ inline void GeomAdaptor_Curve::Load(const Handle(Geom_Curve)& C,
                                     const Standard_Real UFirst,
                                     const Standard_Real ULast)
 {
-  if ( C.IsNull()) Standard_NullObject::Raise();
+  if ( C.IsNull()) throw Standard_NullObject();
   
-  if ( UFirst > ULast) Standard_ConstructionError::Raise();
+  if ( UFirst > ULast) throw Standard_ConstructionError();
   
   load(C,UFirst,ULast);
 }
index 39eca86..24e0542 100644 (file)
@@ -238,7 +238,7 @@ GeomAbs_Shape GeomAdaptor_Surface::UContinuity() const
       case GeomAbs_C1 :
       case GeomAbs_C0 : return GeomAbs_C0;
       }
-      Standard_NoSuchObject::Raise("GeomAdaptor_Surface::UContinuity");
+      throw Standard_NoSuchObject("GeomAdaptor_Surface::UContinuity");
       break;
     }
     case GeomAbs_SurfaceOfExtrusion:
@@ -249,7 +249,7 @@ GeomAbs_Shape GeomAdaptor_Surface::UContinuity() const
       return GC.Continuity();
     }
     case GeomAbs_OtherSurface: 
-      Standard_NoSuchObject::Raise("GeomAdaptor_Surface::UContinuity");
+      throw Standard_NoSuchObject("GeomAdaptor_Surface::UContinuity");
     case GeomAbs_Plane:
     case GeomAbs_Cylinder:
     case GeomAbs_Cone:
@@ -292,7 +292,7 @@ GeomAbs_Shape GeomAdaptor_Surface::VContinuity() const
       case GeomAbs_C1 :
       case GeomAbs_C0 : return GeomAbs_C0;
       }
-      Standard_NoSuchObject::Raise("GeomAdaptor_Surface::VContinuity");
+      throw Standard_NoSuchObject("GeomAdaptor_Surface::VContinuity");
       break;
     }
     case GeomAbs_SurfaceOfRevolution:
@@ -303,7 +303,7 @@ GeomAbs_Shape GeomAdaptor_Surface::VContinuity() const
       return GC.Continuity();
     }
     case GeomAbs_OtherSurface:
-      Standard_NoSuchObject::Raise("GeomAdaptor_Surface::VContinuity");
+      throw Standard_NoSuchObject("GeomAdaptor_Surface::VContinuity");
     case GeomAbs_Plane:
     case GeomAbs_Cylinder:
     case GeomAbs_Cone:
@@ -345,7 +345,7 @@ Standard_Integer GeomAdaptor_Surface::NbUIntervals(const GeomAbs_Shape S) const
       switch(S)
       {
         case GeomAbs_G1:
-        case GeomAbs_G2: Standard_DomainError::Raise("GeomAdaptor_Curve::NbUIntervals");
+        case GeomAbs_G2: throw Standard_DomainError("GeomAdaptor_Curve::NbUIntervals");
         case GeomAbs_C0: BaseS = GeomAbs_C1; break;
         case GeomAbs_C1: BaseS = GeomAbs_C2; break;
         case GeomAbs_C2: BaseS = GeomAbs_C3; break;
@@ -398,7 +398,7 @@ Standard_Integer GeomAdaptor_Surface::NbVIntervals(const GeomAbs_Shape S) const
       switch(S)
       {
         case GeomAbs_G1:
-        case GeomAbs_G2: Standard_DomainError::Raise("GeomAdaptor_Curve::NbVIntervals");
+        case GeomAbs_G2: throw Standard_DomainError("GeomAdaptor_Curve::NbVIntervals");
         case GeomAbs_C0: BaseS = GeomAbs_C1; break;
         case GeomAbs_C1: BaseS = GeomAbs_C2; break;
         case GeomAbs_C2: BaseS = GeomAbs_C3; break;
@@ -457,7 +457,7 @@ void GeomAdaptor_Surface::UIntervals(TColStd_Array1OfReal& T, const GeomAbs_Shap
       switch(S)
       {
         case GeomAbs_G1:
-        case GeomAbs_G2: Standard_DomainError::Raise("GeomAdaptor_Curve::UIntervals");
+        case GeomAbs_G2: throw Standard_DomainError("GeomAdaptor_Curve::UIntervals");
         case GeomAbs_C0: BaseS = GeomAbs_C1; break;
         case GeomAbs_C1: BaseS = GeomAbs_C2; break;
         case GeomAbs_C2: BaseS = GeomAbs_C3; break;
@@ -520,7 +520,7 @@ void GeomAdaptor_Surface::VIntervals(TColStd_Array1OfReal& T, const GeomAbs_Shap
       switch(S)
       {
         case GeomAbs_G1:
-        case GeomAbs_G2: Standard_DomainError::Raise("GeomAdaptor_Curve::VIntervals");
+        case GeomAbs_G2: throw Standard_DomainError("GeomAdaptor_Curve::VIntervals");
         case GeomAbs_C0: BaseS = GeomAbs_C1; break;
         case GeomAbs_C1: BaseS = GeomAbs_C2; break;
         case GeomAbs_C2: BaseS = GeomAbs_C3; break;
@@ -1092,7 +1092,7 @@ Standard_Real GeomAdaptor_Surface::VResolution(const Standard_Real R3d) const
 gp_Pln GeomAdaptor_Surface::Plane() const 
 {
   if (mySurfaceType != GeomAbs_Plane)
-    Standard_NoSuchObject::Raise("GeomAdaptor_Surface::Plane");
+    throw Standard_NoSuchObject("GeomAdaptor_Surface::Plane");
   return Handle(Geom_Plane)::DownCast (mySurface)->Pln();
 }
 
@@ -1104,7 +1104,7 @@ gp_Pln GeomAdaptor_Surface::Plane() const
 gp_Cylinder GeomAdaptor_Surface::Cylinder() const 
 {
   if (mySurfaceType != GeomAbs_Cylinder)
-    Standard_NoSuchObject::Raise("GeomAdaptor_Surface::Cylinder");
+    throw Standard_NoSuchObject("GeomAdaptor_Surface::Cylinder");
   return Handle(Geom_CylindricalSurface)::DownCast (mySurface)->Cylinder();
 }
 
@@ -1116,7 +1116,7 @@ gp_Cylinder GeomAdaptor_Surface::Cylinder() const
 gp_Cone GeomAdaptor_Surface::Cone() const 
 {
   if (mySurfaceType != GeomAbs_Cone)
-    Standard_NoSuchObject::Raise("GeomAdaptor_Surface::Cone");
+    throw Standard_NoSuchObject("GeomAdaptor_Surface::Cone");
   return Handle(Geom_ConicalSurface)::DownCast (mySurface)->Cone();
 }
 
@@ -1128,7 +1128,7 @@ gp_Cone GeomAdaptor_Surface::Cone() const
 gp_Sphere GeomAdaptor_Surface::Sphere() const 
 {
   if (mySurfaceType != GeomAbs_Sphere)
-    Standard_NoSuchObject::Raise("GeomAdaptor_Surface::Sphere");
+    throw Standard_NoSuchObject("GeomAdaptor_Surface::Sphere");
   return Handle(Geom_SphericalSurface)::DownCast (mySurface)->Sphere();
 }
 
@@ -1140,7 +1140,7 @@ gp_Sphere GeomAdaptor_Surface::Sphere() const
 gp_Torus GeomAdaptor_Surface::Torus() const 
 {
   if (mySurfaceType != GeomAbs_Torus)
-    Standard_NoSuchObject::Raise("GeomAdaptor_Surface::Torus");
+    throw Standard_NoSuchObject("GeomAdaptor_Surface::Torus");
   return Handle(Geom_ToroidalSurface)::DownCast (mySurface)->Torus(); 
 }
 
@@ -1161,8 +1161,7 @@ Standard_Integer GeomAdaptor_Surface::UDegree() const
       (Handle(Geom_SurfaceOfLinearExtrusion)::DownCast (mySurface)->BasisCurve(),myUFirst,myULast);
     return myBasisCurve.Degree();
   }
-  Standard_NoSuchObject::Raise("GeomAdaptor_Surface::UDegree");
-  return 0;
+  throw Standard_NoSuchObject("GeomAdaptor_Surface::UDegree");
 }
 
 //=======================================================================
@@ -1182,8 +1181,7 @@ Standard_Integer GeomAdaptor_Surface::NbUPoles() const
       (Handle(Geom_SurfaceOfLinearExtrusion)::DownCast (mySurface)->BasisCurve(),myUFirst,myULast);
     return myBasisCurve.NbPoles();
   }
-  Standard_NoSuchObject::Raise("GeomAdaptor_Surface::NbUPoles");
-  return 0;
+  throw Standard_NoSuchObject("GeomAdaptor_Surface::NbUPoles");
 }
 
 //=======================================================================
@@ -1203,8 +1201,7 @@ Standard_Integer GeomAdaptor_Surface::VDegree() const
       (Handle(Geom_SurfaceOfRevolution)::DownCast (mySurface)->BasisCurve(),myUFirst,myULast);
     return myBasisCurve.Degree();
   }
-  Standard_NoSuchObject::Raise("GeomAdaptor_Surface::VDegree");
-  return 0;
+  throw Standard_NoSuchObject("GeomAdaptor_Surface::VDegree");
 }
 
 //=======================================================================
@@ -1224,8 +1221,7 @@ Standard_Integer GeomAdaptor_Surface::NbVPoles() const
       (Handle(Geom_SurfaceOfRevolution)::DownCast (mySurface)->BasisCurve(),myUFirst,myULast);
     return myBasisCurve.NbPoles();
   }
-  Standard_NoSuchObject::Raise("GeomAdaptor_Surface::NbVPoles");
-  return 0;
+  throw Standard_NoSuchObject("GeomAdaptor_Surface::NbVPoles");
 }
 
 //=======================================================================
@@ -1243,8 +1239,7 @@ Standard_Integer GeomAdaptor_Surface::NbUKnots() const
       (Handle(Geom_SurfaceOfLinearExtrusion)::DownCast (mySurface)->BasisCurve(),myUFirst,myULast);
     return myBasisCurve.NbKnots();
   }
-  Standard_NoSuchObject::Raise("GeomAdaptor_Surface::NbUKnots");
-  return 0;
+  throw Standard_NoSuchObject("GeomAdaptor_Surface::NbUKnots");
 }
 
 //=======================================================================
@@ -1256,8 +1251,7 @@ Standard_Integer GeomAdaptor_Surface::NbVKnots() const
 {
   if (mySurfaceType == GeomAbs_BSplineSurface)
     return myBSplineSurface->NbVKnots();
-  Standard_NoSuchObject::Raise("GeomAdaptor_Surface::NbVKnots");
-  return 0;
+  throw Standard_NoSuchObject("GeomAdaptor_Surface::NbVKnots");
 }
 //=======================================================================
 //function : IsURational
@@ -1295,7 +1289,7 @@ Standard_Boolean GeomAdaptor_Surface::IsVRational() const
 Handle(Geom_BezierSurface) GeomAdaptor_Surface::Bezier() const 
 {
   if (mySurfaceType != GeomAbs_BezierSurface)
-    Standard_NoSuchObject::Raise("GeomAdaptor_Surface::Bezier");
+    throw Standard_NoSuchObject("GeomAdaptor_Surface::Bezier");
   return Handle(Geom_BezierSurface)::DownCast (mySurface);
 }
 
@@ -1307,7 +1301,7 @@ Handle(Geom_BezierSurface) GeomAdaptor_Surface::Bezier() const
 Handle(Geom_BSplineSurface) GeomAdaptor_Surface::BSpline() const 
 {
   if (mySurfaceType != GeomAbs_BSplineSurface)  
-    Standard_NoSuchObject::Raise("GeomAdaptor_Surface::BSpline");
+    throw Standard_NoSuchObject("GeomAdaptor_Surface::BSpline");
   return myBSplineSurface;
 }
 
@@ -1319,7 +1313,7 @@ Handle(Geom_BSplineSurface) GeomAdaptor_Surface::BSpline() const
 gp_Ax1 GeomAdaptor_Surface::AxeOfRevolution() const 
 {
   if (mySurfaceType != GeomAbs_SurfaceOfRevolution)
-    Standard_NoSuchObject::Raise("GeomAdaptor_Surface::AxeOfRevolution");
+    throw Standard_NoSuchObject("GeomAdaptor_Surface::AxeOfRevolution");
   return Handle(Geom_SurfaceOfRevolution)::DownCast (mySurface)->Axis();
 }
 
@@ -1331,7 +1325,7 @@ gp_Ax1 GeomAdaptor_Surface::AxeOfRevolution() const
 gp_Dir GeomAdaptor_Surface::Direction() const 
 {
   if (mySurfaceType != GeomAbs_SurfaceOfExtrusion)
-    Standard_NoSuchObject::Raise("GeomAdaptor_Surface::Direction");
+    throw Standard_NoSuchObject("GeomAdaptor_Surface::Direction");
   return Handle(Geom_SurfaceOfLinearExtrusion)::DownCast (mySurface)->Direction();
 }
 
@@ -1348,7 +1342,7 @@ Handle(Adaptor3d_HCurve) GeomAdaptor_Surface::BasisCurve() const
   else if (mySurfaceType == GeomAbs_SurfaceOfRevolution)
     C = Handle(Geom_SurfaceOfRevolution)::DownCast (mySurface)->BasisCurve();
   else
-    Standard_NoSuchObject::Raise("GeomAdaptor_Surface::BasisCurve");
+    throw Standard_NoSuchObject("GeomAdaptor_Surface::BasisCurve");
   return Handle(GeomAdaptor_HCurve)(new GeomAdaptor_HCurve(C));
 }
 
@@ -1360,7 +1354,7 @@ Handle(Adaptor3d_HCurve) GeomAdaptor_Surface::BasisCurve() const
 Handle(Adaptor3d_HSurface) GeomAdaptor_Surface::BasisSurface() const 
 {
   if (mySurfaceType != GeomAbs_OffsetSurface) 
-    Standard_NoSuchObject::Raise("GeomAdaptor_Surface::BasisSurface");
+    throw Standard_NoSuchObject("GeomAdaptor_Surface::BasisSurface");
   return new GeomAdaptor_HSurface
     (Handle(Geom_OffsetSurface)::DownCast (mySurface)->BasisSurface(),
      myUFirst,myULast,myVFirst,myVLast);
@@ -1374,7 +1368,7 @@ Handle(Adaptor3d_HSurface) GeomAdaptor_Surface::BasisSurface() const
 Standard_Real GeomAdaptor_Surface::OffsetValue() const 
 {
   if (mySurfaceType != GeomAbs_OffsetSurface) 
-    Standard_NoSuchObject::Raise("GeomAdaptor_Surface::BasisSurface");
+    throw Standard_NoSuchObject("GeomAdaptor_Surface::BasisSurface");
   return Handle(Geom_OffsetSurface)::DownCast (mySurface)->Offset();
 }
 
index 5b6f2eb..af7644e 100644 (file)
@@ -68,7 +68,7 @@ inline GeomAdaptor_Surface::GeomAdaptor_Surface(const Handle(Geom_Surface)& S,
 
 inline void GeomAdaptor_Surface::Load(const Handle(Geom_Surface)& S)
 {
-  if ( S.IsNull()) Standard_NullObject::Raise("GeomAdaptor_Surface::Load");
+  if ( S.IsNull()) throw Standard_NullObject("GeomAdaptor_Surface::Load");
 
   Standard_Real U1,U2,V1,V2;
   S->Bounds(U1,U2,V1,V2);
@@ -88,10 +88,10 @@ inline void GeomAdaptor_Surface::Load(const Handle(Geom_Surface)& S,
                                const Standard_Real TolU,
                                const Standard_Real TolV)
 {
-  if ( S.IsNull()) Standard_NullObject::Raise("GeomAdaptor_Surface::Load");
+  if ( S.IsNull()) throw Standard_NullObject("GeomAdaptor_Surface::Load");
 
   if(UFirst>ULast || VFirst>VLast)
-    Standard_ConstructionError::Raise("GeomAdaptor_Surface::Load");
+    throw Standard_ConstructionError("GeomAdaptor_Surface::Load");
 
   load(S,UFirst,ULast,VFirst,VLast,TolU,TolV);
 }
index 1333b6c..9c64c3c 100644 (file)
@@ -274,8 +274,7 @@ Standard_Boolean GeomAdaptor_SurfaceOfLinearExtrusion::IsVPeriodic() const
 
 Standard_Real GeomAdaptor_SurfaceOfLinearExtrusion::VPeriod() const 
 {
-  Standard_DomainError::Raise("GeomAdaptor_SurfaceOfLinearExtrusion::VPeriod");
-  return 0.0e0 ;
+  throw Standard_DomainError("GeomAdaptor_SurfaceOfLinearExtrusion::VPeriod");
 }
 
 //=======================================================================
@@ -424,8 +423,7 @@ gp_Cylinder GeomAdaptor_SurfaceOfLinearExtrusion::Cylinder() const
 
 gp_Cone GeomAdaptor_SurfaceOfLinearExtrusion::Cone() const 
 {
-  Standard_NoSuchObject::Raise("GeomAdaptor_SurfaceOfLinearExtrusion::Cone");
-  return gp_Cone();
+  throw Standard_NoSuchObject("GeomAdaptor_SurfaceOfLinearExtrusion::Cone");
 }
 
 //=======================================================================
@@ -435,8 +433,7 @@ gp_Cone GeomAdaptor_SurfaceOfLinearExtrusion::Cone() const
 
 gp_Sphere GeomAdaptor_SurfaceOfLinearExtrusion::Sphere() const 
 {
-  Standard_NoSuchObject::Raise("GeomAdaptor_SurfaceOfLinearExtrusion::Sphere");
-  return gp_Sphere();
+  throw Standard_NoSuchObject("GeomAdaptor_SurfaceOfLinearExtrusion::Sphere");
 }
 
 //=======================================================================
@@ -446,8 +443,7 @@ gp_Sphere GeomAdaptor_SurfaceOfLinearExtrusion::Sphere() const
 
 gp_Torus GeomAdaptor_SurfaceOfLinearExtrusion::Torus() const 
 {
-  Standard_NoSuchObject::Raise("GeomAdaptor_SurfaceOfLinearExtrusion::Torus");
-  return gp_Torus();
+  throw Standard_NoSuchObject("GeomAdaptor_SurfaceOfLinearExtrusion::Torus");
 }
 
 
@@ -458,8 +454,7 @@ gp_Torus GeomAdaptor_SurfaceOfLinearExtrusion::Torus() const
 
 gp_Ax1 GeomAdaptor_SurfaceOfLinearExtrusion::AxeOfRevolution() const 
 {
-  Standard_NoSuchObject::Raise("GeomAdaptor_SurfaceOfLinearExtrusion::Axes");
-  return gp_Ax1();
+  throw Standard_NoSuchObject("GeomAdaptor_SurfaceOfLinearExtrusion::Axes");
 }
 
 //=======================================================================
@@ -488,9 +483,7 @@ Standard_Integer GeomAdaptor_SurfaceOfLinearExtrusion::NbUPoles() const
 
 Standard_Boolean GeomAdaptor_SurfaceOfLinearExtrusion::IsURational() const 
 {
-  Standard_NoSuchObject::Raise
-    ("GeomAdaptor_SurfaceOfLinearExtrusion::IsURational");
-  return Standard_False;
+  throw Standard_NoSuchObject("GeomAdaptor_SurfaceOfLinearExtrusion::IsURational");
 }
 //=======================================================================
 //function : IsVRational
@@ -499,9 +492,7 @@ Standard_Boolean GeomAdaptor_SurfaceOfLinearExtrusion::IsURational() const
 
 Standard_Boolean GeomAdaptor_SurfaceOfLinearExtrusion::IsVRational() const 
 {
-  Standard_NoSuchObject::Raise
-    ("GeomAdaptor_SurfaceOfLinearExtrusion::IsVRational");
-  return Standard_False;
+  throw Standard_NoSuchObject("GeomAdaptor_SurfaceOfLinearExtrusion::IsVRational");
 }
 //=======================================================================
 //function : Bezier
@@ -511,8 +502,7 @@ Standard_Boolean GeomAdaptor_SurfaceOfLinearExtrusion::IsVRational() const
 
 Handle(Geom_BezierSurface)  GeomAdaptor_SurfaceOfLinearExtrusion::Bezier() const 
 {
-  Standard_NoSuchObject::Raise("GeomAdaptor_SurfaceOfLinearExtrusion::Bezier");
-  return Handle(Geom_BezierSurface)() ;
+  throw Standard_NoSuchObject("GeomAdaptor_SurfaceOfLinearExtrusion::Bezier");
 }
 
 //=======================================================================
@@ -522,8 +512,7 @@ Handle(Geom_BezierSurface)  GeomAdaptor_SurfaceOfLinearExtrusion::Bezier() const
 
 Handle(Geom_BSplineSurface)  GeomAdaptor_SurfaceOfLinearExtrusion::BSpline() const 
 {
-  Standard_NoSuchObject::Raise("GeomAdaptor_SurfaceOfLinearExtrusion::BSpline");
-  return Handle(Geom_BSplineSurface)() ;
+  throw Standard_NoSuchObject("GeomAdaptor_SurfaceOfLinearExtrusion::BSpline");
 }
 
 //=======================================================================
index c6dc7b6..d8fdd70 100644 (file)
@@ -132,7 +132,7 @@ void GeomAdaptor_SurfaceOfRevolution::Load(const gp_Ax1& V)
     while ( Dist < Precision::Confusion() && Ratio < 100);
 
     if ( Ratio >= 100 ) {
-      Standard_ConstructionError::Raise("Adaptor3d_SurfaceOfRevolution : Axe and meridian are confused");
+      throw Standard_ConstructionError("Adaptor3d_SurfaceOfRevolution : Axe and meridian are confused");
     }
     Ox = ( (Oz^gp_Vec(PP.XYZ()-O.XYZ()))^Oz); 
   }
@@ -621,8 +621,7 @@ Standard_Integer GeomAdaptor_SurfaceOfRevolution::NbVPoles() const
 
 Standard_Integer GeomAdaptor_SurfaceOfRevolution::NbVKnots() const 
 {
-  Standard_NoSuchObject::Raise("GeomAdaptor_SurfaceOfRevolution::NbVKnots");
-  return 0;
+  throw Standard_NoSuchObject("GeomAdaptor_SurfaceOfRevolution::NbVKnots");
 }
 
 
@@ -634,8 +633,7 @@ Standard_Integer GeomAdaptor_SurfaceOfRevolution::NbVKnots() const
 
 Standard_Boolean GeomAdaptor_SurfaceOfRevolution::IsURational() const 
 {
-  Standard_NoSuchObject::Raise("GeomAdaptor_SurfaceOfRevolution::IsURational");
-  return Standard_False;
+  throw Standard_NoSuchObject("GeomAdaptor_SurfaceOfRevolution::IsURational");
 }
 
 //=======================================================================
@@ -645,8 +643,7 @@ Standard_Boolean GeomAdaptor_SurfaceOfRevolution::IsURational() const
 
 Standard_Boolean GeomAdaptor_SurfaceOfRevolution::IsVRational() const 
 {
-  Standard_NoSuchObject::Raise("GeomAdaptor_SurfaceOfRevolution::IsVRational");
-  return Standard_False;
+  throw Standard_NoSuchObject("GeomAdaptor_SurfaceOfRevolution::IsVRational");
 }
 
 
@@ -657,8 +654,7 @@ Standard_Boolean GeomAdaptor_SurfaceOfRevolution::IsVRational() const
 
 Handle(Geom_BezierSurface) GeomAdaptor_SurfaceOfRevolution::Bezier() const 
 {
-  Standard_NoSuchObject::Raise("GeomAdaptor_SurfaceOfRevolution::Bezier");
-  return Handle(Geom_BezierSurface)();
+  throw Standard_NoSuchObject("GeomAdaptor_SurfaceOfRevolution::Bezier");
 }
 
 
@@ -669,8 +665,7 @@ Handle(Geom_BezierSurface) GeomAdaptor_SurfaceOfRevolution::Bezier() const
 
 Handle(Geom_BSplineSurface) GeomAdaptor_SurfaceOfRevolution::BSpline() const 
 {
-  Standard_NoSuchObject::Raise("GeomAdaptor_SurfaceOfRevolution::BSpline");
-  return Handle(Geom_BSplineSurface)();
+  throw Standard_NoSuchObject("GeomAdaptor_SurfaceOfRevolution::BSpline");
 }
 
 //=======================================================================
index 10d59c8..0bb25fc 100644 (file)
@@ -121,10 +121,10 @@ Handle(Geom_BSplineCurve) GeomConvert::SplitBSplineCurve
 {
   Standard_Integer TheFirst = C->FirstUKnotIndex ();
   Standard_Integer TheLast  = C->LastUKnotIndex ();
-  if (FromK1 == ToK2)  Standard_DomainError::Raise();
+  if (FromK1 == ToK2)  throw Standard_DomainError();
   Standard_Integer FirstK = Min (FromK1, ToK2);
   Standard_Integer LastK  = Max (FromK1, ToK2);
-  if (FirstK < TheFirst || LastK > TheLast) Standard_DomainError::Raise();
+  if (FirstK < TheFirst || LastK > TheLast) throw Standard_DomainError();
 
   Handle(Geom_BSplineCurve) C1
     = Handle(Geom_BSplineCurve)::DownCast(C->Copy ());
@@ -378,9 +378,9 @@ Handle(Geom_BSplineCurve)  GeomConvert::CurveToBSplineCurve
                                         MaxSegments, MaxDegree);
      if (ApprCOffs.HasResult())
        TheCurve = ApprCOffs.Curve();
-     else  Standard_ConstructionError::Raise();
+     else  throw Standard_ConstructionError();
     }
-    else { Standard_DomainError::Raise("No such curve"); }
+    else { throw Standard_DomainError("No such curve"); }
   }
 
   else { 
@@ -390,7 +390,7 @@ Handle(Geom_BSplineCurve)  GeomConvert::CurveToBSplineCurve
                      TheConic->MajorRadius(), TheConic->MinorRadius());
 /*      if (Parameterisation == Convert_TgtThetaOver2_1 ||
          Parameterisation == Convert_TgtThetaOver2_2) {
-       Standard_DomainError::Raise(); }
+       throw Standard_DomainError(); }
  
       else if ( Parameterisation == Convert_QuasiAngular) {
        Convert_EllipseToBSplineCurve Convert (E2d,
@@ -414,7 +414,7 @@ Handle(Geom_BSplineCurve)  GeomConvert::CurveToBSplineCurve
       gp_Circ2d C2d (gp::OX2d(), TheConic->Radius());
 /*      if (Parameterisation == Convert_TgtThetaOver2_1 ||
          Parameterisation == Convert_TgtThetaOver2_2) {
-       Standard_DomainError::Raise(); }
+       throw Standard_DomainError(); }
  
       else if ( Parameterisation == Convert_QuasiAngular) {
        Convert_CircleToBSplineCurve Convert (C2d,
@@ -467,9 +467,9 @@ Handle(Geom_BSplineCurve)  GeomConvert::CurveToBSplineCurve
                                         MaxSegments, MaxDegree);
      if (ApprCOffs.HasResult())
        TheCurve = ApprCOffs.Curve();
-     else  Standard_ConstructionError::Raise();
+     else  throw Standard_ConstructionError();
    }
-    else { Standard_DomainError::Raise("No such curve"); }
+    else { throw Standard_DomainError("No such curve"); }
   }
   
   return TheCurve;
@@ -816,7 +816,7 @@ private:
                                  PreLast,First,
                                  Standard_True,Standard_True);
      if (Cont<GeomAbs_C0)
-       Standard_ConstructionError::Raise("GeomConvert curves not C0") ;                
+       throw Standard_ConstructionError("GeomConvert curves not C0") ;                
      else{
        if (Cont>=GeomAbs_G1)
         tabG1(i-1)=Standard_True;                   //True=G1 continuity
@@ -941,7 +941,7 @@ private:
      fusion=C.Add(Curve1,
                  local_tolerance(j-1));                //merge of two consecutive curves               
      if (fusion==Standard_False)
-       Standard_ConstructionError::Raise("GeomConvert Concatenation Error") ;
+       throw Standard_ConstructionError("GeomConvert Concatenation Error") ;
      Curve2=C.BSplineCurve();
    }
    Curve2->SetPeriodic();      
@@ -967,7 +967,7 @@ private:
         GeomConvert_CompCurveToBSplineCurve C (ArrayOfConcatenated->Value(i));
         fusion=C.Add(Curve1,ArrayOfToler(j-1));            //merge of two consecutive curves               
         if (fusion==Standard_False)
-          Standard_ConstructionError::Raise("GeomConvert Concatenation Error") ;
+          throw Standard_ConstructionError("GeomConvert Concatenation Error") ;
         ArrayOfConcatenated->SetValue(i,C.BSplineCurve());
        }
      }
@@ -1040,7 +1040,7 @@ void  GeomConvert::ConcatC1(TColGeom_Array1OfBSplineCurve&           ArrayOfCurv
                               local_tolerance(i-1),
                               AngularTolerance);
      if (Cont<GeomAbs_C0)
-       Standard_ConstructionError::Raise("GeomConvert curves not C0");
+       throw Standard_ConstructionError("GeomConvert curves not C0");
      else{
        if (Cont>=GeomAbs_G1)
         tabG1(i-1)=Standard_True;                   //True=G1 continuity
@@ -1176,7 +1176,7 @@ void  GeomConvert::ConcatC1(TColGeom_Array1OfBSplineCurve&           ArrayOfCurv
        fusion=C.Add(Curve1,
                    local_tolerance(j-1));          //merge of two consecutive curves               
        if (fusion==Standard_False)
-        Standard_ConstructionError::Raise("GeomConvert Concatenation Error") ;
+        throw Standard_ConstructionError("GeomConvert Concatenation Error") ;
        Curve2=C.BSplineCurve();
      }
    }
@@ -1221,7 +1221,7 @@ void  GeomConvert::ConcatC1(TColGeom_Array1OfBSplineCurve&           ArrayOfCurv
          GeomConvert_CompCurveToBSplineCurve C (ArrayOfConcatenated->Value(i));
          fusion=C.Add(Curve1, local_tolerance(j-1), Standard_True);
          if (fusion==Standard_False)
-           Standard_ConstructionError::Raise("GeomConvert Concatenation Error");
+           throw Standard_ConstructionError("GeomConvert Concatenation Error");
          ArrayOfConcatenated->SetValue(i,C.BSplineCurve());
        }
      }
@@ -1252,7 +1252,7 @@ void GeomConvert::C0BSplineToC1BSplineCurve(Handle(Geom_BSplineCurve)& BS,
     for (i=1;i<ArrayOfConcatenated->Length();i++){
       fusion=C.Add(ArrayOfConcatenated->Value(i),tolerance);
       if (fusion==Standard_False)
-       Standard_ConstructionError::Raise("GeomConvert Concatenation Error") ;
+       throw Standard_ConstructionError("GeomConvert Concatenation Error") ;
     }
   }
   BS=C.BSplineCurve();
index c9be974..d21ff62 100644 (file)
@@ -132,13 +132,13 @@ Handle(Geom_BSplineSurface) GeomConvert::SplitBSplineSurface
   Standard_Integer FirstV = S->FirstVKnotIndex ();
   Standard_Integer LastU  = S->LastUKnotIndex  ();
   Standard_Integer LastV  = S->LastVKnotIndex  ();
-  if (FromUK1 == ToUK2 || FromVK1 == ToVK2)   Standard_DomainError::Raise();
+  if (FromUK1 == ToUK2 || FromVK1 == ToVK2)   throw Standard_DomainError();
   Standard_Integer FirstUK = Min (FromUK1, ToUK2);
   Standard_Integer LastUK  = Max (FromUK1, ToUK2);
   Standard_Integer FirstVK = Min (FromVK1, ToVK2);
   Standard_Integer LastVK  = Max (FromVK1, ToVK2);
   if (FirstUK < FirstU || LastUK > LastU || 
-    FirstVK < FirstV || LastVK > LastV) { Standard_DomainError::Raise(); }
+    FirstVK < FirstV || LastVK > LastV) { throw Standard_DomainError(); }
 
   Handle(Geom_BSplineSurface) S1= Handle(Geom_BSplineSurface)::DownCast(S->Copy());
 
@@ -173,7 +173,7 @@ Handle(Geom_BSplineSurface) GeomConvert::SplitBSplineSurface
   const Standard_Boolean USplit, 
   const Standard_Boolean SameOrientation )
 {
-  if (FromK1 == ToK2)   Standard_DomainError::Raise();
+  if (FromK1 == ToK2)   throw Standard_DomainError();
 
 
   Handle(Geom_BSplineSurface) S1 = Handle(Geom_BSplineSurface)::DownCast(S->Copy());
@@ -184,7 +184,7 @@ Handle(Geom_BSplineSurface) GeomConvert::SplitBSplineSurface
     Standard_Integer LastU  = S->LastUKnotIndex  ();
     Standard_Integer FirstUK = Min (FromK1, ToK2);
     Standard_Integer LastUK  = Max (FromK1, ToK2);
-    if (FirstUK < FirstU || LastUK > LastU)  Standard_DomainError::Raise();
+    if (FirstUK < FirstU || LastUK > LastU)  throw Standard_DomainError();
 
     S1->Segment( S1->UKnot(FirstUK), 
       S1->UKnot(LastUK),
@@ -205,7 +205,7 @@ Handle(Geom_BSplineSurface) GeomConvert::SplitBSplineSurface
     Standard_Integer LastV  = S->LastVKnotIndex  ();
     Standard_Integer FirstVK = Min (FromK1, ToK2);
     Standard_Integer LastVK  = Max (FromK1, ToK2);
-    if (FirstVK < FirstV || LastVK > LastV)  Standard_DomainError::Raise();
+    if (FirstVK < FirstV || LastVK > LastV)  throw Standard_DomainError();
 
     S1->Segment( S1->UKnot(S1->FirstUKnotIndex()), 
       S1->UKnot(S1->LastUKnotIndex()),
@@ -280,7 +280,7 @@ Handle(Geom_BSplineSurface) GeomConvert::SplitBSplineSurface
   const Standard_Boolean                 SameOrientation  )
 {
   if (Abs (FromParam1 - ToParam2) <= Abs(ParametricTolerance)) {
-    Standard_DomainError::Raise();
+    throw Standard_DomainError();
   }
   Handle(Geom_BSplineSurface) NewSurface
     = Handle(Geom_BSplineSurface)::DownCast(S->Copy());
@@ -341,7 +341,7 @@ Handle(Geom_BSplineSurface) GeomConvert::SurfaceToBSplineSurface
     Precision::IsPositiveInfinite(ULast)  || 
     Precision::IsNegativeInfinite(VFirst) || 
     Precision::IsPositiveInfinite(VLast) )   {
-      Standard_DomainError::Raise("");
+      throw Standard_DomainError("");
   }
 
   Handle(Geom_BSplineSurface) TheSurface;
index 83b3739..8b77635 100644 (file)
@@ -32,7 +32,7 @@ const Standard_Integer      ContinuityRange
 ) {
 
 
-  if (ContinuityRange < 0)  Standard_RangeError::Raise();
+  if (ContinuityRange < 0)  throw Standard_RangeError();
 
   Standard_Integer FirstIndex = BasisCurve->FirstUKnotIndex();
   Standard_Integer LastIndex  = BasisCurve->LastUKnotIndex();
index 1bda03a..0d13164 100644 (file)
@@ -53,7 +53,7 @@ GeomConvert_BSplineCurveToBezierCurve::GeomConvert_BSplineCurveToBezierCurve
  const Standard_Real ParametricTolerance)
 {
   if (U2 - U1 < ParametricTolerance)
-      Standard_DomainError::Raise("GeomConvert_BSplineCurveToBezierSurface");
+      throw Standard_DomainError("GeomConvert_BSplineCurveToBezierSurface");
 
   Standard_Real Uf = U1, Ul = U2; 
   Standard_Real PTol = ParametricTolerance/2 ;
@@ -87,7 +87,7 @@ Handle(Geom_BezierCurve) GeomConvert_BSplineCurveToBezierCurve::Arc
 (const Standard_Integer Index)
 {
   if ( Index < 1 || Index > myCurve->NbKnots()-1) {
-    Standard_OutOfRange::Raise("GeomConvert_BSplineCurveToBezierCurve");
+    throw Standard_OutOfRange("GeomConvert_BSplineCurveToBezierCurve");
   }
   Standard_Integer Deg = myCurve->Degree();
 
index 65a9811..b5118b4 100644 (file)
@@ -35,7 +35,7 @@ const Standard_Integer        VContinuityRange
 
 
   if (UContinuityRange < 0 || VContinuityRange < 0) { 
-    Standard_RangeError::Raise(); 
+    throw Standard_RangeError();
   }
 
   Standard_Integer FirstUIndex = BasisSurface->FirstUKnotIndex ();
index e97115c..56c6b52 100644 (file)
@@ -58,7 +58,7 @@ GeomConvert_BSplineSurfaceToBezierSurface::GeomConvert_BSplineSurfaceToBezierSur
 {
   if ( (U2 - U1 <  ParametricTolerance) ||
        (V2 - V1 <  ParametricTolerance) )
-      Standard_DomainError::Raise("GeomConvert_BSplineSurfaceToBezierSurface");
+      throw Standard_DomainError("GeomConvert_BSplineSurfaceToBezierSurface");
 
   Standard_Real Uf=U1, Ul=U2, Vf=V1, Vl=V2, PTol = ParametricTolerance/2;
   Standard_Integer I1, I2;
@@ -106,7 +106,7 @@ Handle(Geom_BezierSurface) GeomConvert_BSplineSurfaceToBezierSurface::Patch
 {
   if (UIndex < 1 || UIndex > mySurface->NbUKnots()-1 ||
       VIndex < 1 || VIndex > mySurface->NbVKnots()-1   ) {
-    Standard_OutOfRange::Raise("GeomConvert_BSplineSurfaceToBezierSurface");
+    throw Standard_OutOfRange("GeomConvert_BSplineSurfaceToBezierSurface");
   }
   Standard_Integer UDeg = mySurface->UDegree();
   Standard_Integer VDeg = mySurface->VDegree();
index 7fc0576..8fb8a84 100644 (file)
@@ -255,7 +255,7 @@ GeomConvert_CompBezierSurfacesToBSplineSurface(
     decu = 3;
     break;
   default:
-    Standard_ConstructionError::Raise( 
+    throw Standard_ConstructionError(
      "GeomConvert_CompBezierSurfacesToBSpl:: UContinuity error");
   }
   
@@ -273,7 +273,7 @@ GeomConvert_CompBezierSurfacesToBSplineSurface(
     decv = 3;
     break;
   default:
-    Standard_ConstructionError::Raise( 
+    throw Standard_ConstructionError(
      "GeomConvert_CompBezierSurfacesToBSpl:: VContinuity error");
   }
 
index f6dfa54..4809455 100644 (file)
@@ -194,7 +194,7 @@ void GeomEvaluator_OffsetCurve::CalculateD0(      gp_Pnt& theValue,
   gp_XYZ Ndir = (theD1.XYZ()).Crossed(myOffsetDir.XYZ());
   Standard_Real R = Ndir.Modulus();
   if (R <= gp::Resolution())
-    Standard_NullValue::Raise("GeomEvaluator_OffsetCurve: Undefined normal vector "
+    throw Standard_NullValue("GeomEvaluator_OffsetCurve: Undefined normal vector "
                               "because tangent vector has zero-magnitude!");
 
   Ndir.Multiply(myOffset / R);
@@ -218,7 +218,7 @@ void GeomEvaluator_OffsetCurve::CalculateD1(      gp_Pnt& theValue,
   Standard_Real Dr = Ndir.Dot(DNdir);
   if (R3 <= gp::Resolution()) {
     if (R2 <= gp::Resolution())
-      Standard_NullValue::Raise("GeomEvaluator_OffsetCurve: Null derivative");
+      throw Standard_NullValue("GeomEvaluator_OffsetCurve: Null derivative");
     //We try another computation but the stability is not very good.
     DNdir.Multiply(R);
     DNdir.Subtract(Ndir.Multiplied(Dr / R));
@@ -264,7 +264,7 @@ void GeomEvaluator_OffsetCurve::CalculateD2(      gp_Pnt& theValue,
 
   if (R5 <= gp::Resolution()) {
     if (R4 <= gp::Resolution())
-      Standard_NullValue::Raise("GeomEvaluator_OffsetCurve: Null derivative");
+      throw Standard_NullValue("GeomEvaluator_OffsetCurve: Null derivative");
     //We try another computation but the stability is not very good
     //dixit ISG.
     // V2 = P" (U) :
@@ -337,7 +337,7 @@ void GeomEvaluator_OffsetCurve::CalculateD3(      gp_Pnt& theValue,
   Standard_Real D3r = Ndir.Dot(D3Ndir) + 3.0 * DNdir.Dot(D2Ndir);
   if (R7 <= gp::Resolution()) {
     if (R6 <= gp::Resolution())
-      Standard_NullValue::Raise("CSLib_Offset: Null derivative");
+      throw Standard_NullValue("CSLib_Offset: Null derivative");
     // V3 = P"' (U) :
     D3Ndir.Subtract(D2Ndir.Multiplied(3.0 * Dr / R2));
     D3Ndir.Subtract(DNdir.Multiplied(3.0 * ((D2r / R2) + (Dr*Dr / R4))));
index 0484659..82fcf8c 100644 (file)
@@ -239,7 +239,7 @@ void GeomEvaluator_OffsetSurface::CalculateD0(
     }
 
     if (NStatus != CSLib_Defined)
-      Geom_UndefinedValue::Raise(
+      throw Geom_UndefinedValue(
           "GeomEvaluator_OffsetSurface::CalculateD0(): Unable to calculate normal");
 
     theValue.SetXYZ(theValue.XYZ() + myOffset * aSign * Normal.XYZ());
@@ -360,7 +360,7 @@ void GeomEvaluator_OffsetSurface::CalculateD1(
   }
 
   if (NStatus != CSLib_Defined)
-    Geom_UndefinedValue::Raise(
+    throw Geom_UndefinedValue(
         "GeomEvaluator_OffsetSurface::CalculateD1(): Unable to calculate normal");
 
   theValue.SetXYZ(theValue.XYZ() + myOffset * aSign * Normal.XYZ());
@@ -419,7 +419,7 @@ void GeomEvaluator_OffsetSurface::CalculateD2(
   CSLib::Normal(MaxOrder, DerNUV, MagTol, theU, theV, Umin, Umax, Vmin, Vmax,
                 NStatus, Normal, OrderU, OrderV);
   if (NStatus != CSLib_Defined)
-    Geom_UndefinedValue::Raise(
+    throw Geom_UndefinedValue(
         "GeomEvaluator_OffsetSurface::CalculateD2(): Unable to calculate normal");
 
   theValue.SetXYZ(theValue.XYZ() + myOffset * aSign * Normal.XYZ());
@@ -494,7 +494,7 @@ void GeomEvaluator_OffsetSurface::CalculateD3(
   CSLib::Normal(MaxOrder, DerNUV, MagTol, theU, theV, Umin, Umax, Vmin, Vmax,
                 NStatus, Normal, OrderU, OrderV);
   if (NStatus != CSLib_Defined)
-    Geom_UndefinedValue::Raise(
+    throw Geom_UndefinedValue(
         "GeomEvaluator_OffsetSurface::CalculateD3(): Unable to calculate normal");
 
   theValue.SetXYZ(theValue.XYZ() + myOffset * aSign * Normal.XYZ());
@@ -574,7 +574,7 @@ gp_Vec GeomEvaluator_OffsetSurface::CalculateDN(
   CSLib::Normal(MaxOrder, DerNUV, MagTol, theU, theV, Umin, Umax, Vmin, Vmax,
                 NStatus, Normal, OrderU, OrderV);
   if (NStatus != CSLib_Defined)
-    Geom_UndefinedValue::Raise(
+    throw Geom_UndefinedValue(
         "GeomEvaluator_OffsetSurface::CalculateDN(): Unable to calculate normal");
 
   gp_Vec D;
index 882da4e..57c9a01 100644 (file)
@@ -182,7 +182,7 @@ Standard_Integer SetSameDistribution(Handle(Geom_BSplineCurve)& C1,
     }
   }
   else {
-    Standard_ConstructionError::Raise(" ");
+    throw Standard_ConstructionError(" ");
   }
   
   return C1->NbPoles();
@@ -286,7 +286,7 @@ void  GeomFill_BSplineCurves::Init
 
   if(Type == GeomFill_CoonsStyle) {
     if(NbUPoles < 4 || NbVPoles < 4)
-      Standard_ConstructionError::Raise("GeomFill_BSplineCurves: invalid filling style");
+      throw Standard_ConstructionError("GeomFill_BSplineCurves: invalid filling style");
   }
 
   TColgp_Array1OfPnt P1(1,NbUPoles);
@@ -537,7 +537,7 @@ void  GeomFill_BSplineCurves::Init
     }
     
     if(!IsOK)
-      Standard_OutOfRange::Raise("GeomFill_BSplineCurves: Courbes non jointives");
+      throw Standard_OutOfRange("GeomFill_BSplineCurves: Courbes non jointives");
 
     Standard_Integer NbUPoles = CC1->NbPoles();
     Standard_Integer NbVPoles = CC2->NbPoles();
index 5f000f0..14ea8b9 100644 (file)
@@ -437,7 +437,7 @@ void  GeomFill_BezierCurves::Init(const Handle(Geom_BezierCurve)& C1,
     }
 
     if(!IsOK)
-      Standard_OutOfRange::Raise("GeomFill_BezierCurves: Courbes non jointives");
+      throw Standard_OutOfRange("GeomFill_BezierCurves: Courbes non jointives");
 
     CC1->Poles(P1);
     CC2->Poles(P2);
index 93bcf91..9de8c03 100644 (file)
@@ -92,7 +92,7 @@ gp_Vec GeomFill_BoundWithSurf::Norm(const Standard_Real U) const
 {
   // voir s il ne faudrait pas utiliser LProp ou autre.
   if (!HasNormals()) 
-    Standard_Failure::Raise("BoundWithSurf Norm : pas de contrainte");
+    throw Standard_Failure("BoundWithSurf Norm : pas de contrainte");
 
 //  Handle(Adaptor3d_HSurface)& S = myConS.GetSurface();
 //  Handle(Adaptor2d_HCurve2d)& C2d = myConS.GetCurve();
@@ -119,7 +119,7 @@ void GeomFill_BoundWithSurf::D1Norm(const Standard_Real U,
                                    gp_Vec&             DN) const 
 {
   if (!HasNormals()) 
-    Standard_Failure::Raise("BoundWithSurf Norm : pas de contrainte");
+    throw Standard_Failure("BoundWithSurf Norm : pas de contrainte");
 //  Handle(Adaptor3d_HSurface)& S = myConS.GetSurface();
 //  Handle(Adaptor2d_HCurve2d)& C2d = myConS.GetCurve();
   gp_Pnt2d P2d;
index 3e68305..32ffeca 100644 (file)
@@ -51,8 +51,7 @@ Standard_Boolean GeomFill_Boundary::HasNormals() const
 
 gp_Vec GeomFill_Boundary::Norm(const Standard_Real ) const 
 {
-  Standard_Failure::Raise("GeomFill_Boundary::Norm : Undefined normals");
-  return gp_Vec();
+  throw Standard_Failure("GeomFill_Boundary::Norm : Undefined normals");
 }
 
 
@@ -63,7 +62,7 @@ gp_Vec GeomFill_Boundary::Norm(const Standard_Real ) const
 
 void GeomFill_Boundary::D1Norm(const Standard_Real , gp_Vec& , gp_Vec& ) const 
 {
-  Standard_Failure::Raise("GeomFill_Boundary::Norm : Undefined normals");
+  throw Standard_Failure("GeomFill_Boundary::Norm : Undefined normals");
 }
 
 
index 51bfbde..7d974a7 100644 (file)
@@ -514,8 +514,7 @@ void GeomFill_ConstrainedFilling::SetDomain
 
 void GeomFill_ConstrainedFilling::ReBuild()
 {
-  if(!appdone) Standard_Failure::Raise
-    ("GeomFill_ConstrainedFilling::ReBuild Approx non faite");
+  if(!appdone) throw Standard_Failure("GeomFill_ConstrainedFilling::ReBuild Approx non faite");
   MatchKnots();
   PerformS0();
   PerformS1();
index 37772a2..9033194 100644 (file)
@@ -63,36 +63,6 @@ GeomFill_Curved::GeomFill_Curved(const TColgp_Array1OfPnt&   P1,
   Init(P1, P2, P3, P4, W1, W2, W3, W4);
 }
 
-
-//=======================================================================
-//function : GeomFill_Curved
-//purpose  : 
-//=======================================================================
-
-GeomFill_Curved::GeomFill_Curved(const TColgp_Array1OfPnt& P1, 
-                          const TColgp_Array1OfPnt& P2, 
-                          const TColgp_Array1OfPnt& P3)
-{
-  Init(P1, P2, P3);
-}
-
-
-//=======================================================================
-//function : GeomFill_Curved
-//purpose  : 
-//=======================================================================
-
-GeomFill_Curved::GeomFill_Curved(const TColgp_Array1OfPnt&   P1, 
-                          const TColgp_Array1OfPnt&   P2, 
-                          const TColgp_Array1OfPnt&   P3, 
-                          const TColStd_Array1OfReal& W1, 
-                          const TColStd_Array1OfReal& W2, 
-                          const TColStd_Array1OfReal& W3)
-{
-  Init(P1, P2, P3, W1, W2, W3);
-}
-
-
 //=======================================================================
 //function : GeomFill_Curved
 //purpose  : 
@@ -235,35 +205,6 @@ void  GeomFill_Curved::Init(const TColgp_Array1OfPnt&   P1,
 }
 
 
-//=======================================================================
-//function : Init
-//purpose  : 
-//=======================================================================
-
-void  GeomFill_Curved::Init(const TColgp_Array1OfPnt& ,  // P1, 
-                        const TColgp_Array1OfPnt& ,  // P2, 
-                        const TColgp_Array1OfPnt&  )// P3)
-{
-  Standard_NotImplemented::Raise(" ");
-}
-
-
-//=======================================================================
-//function : Init
-//purpose  : 
-//=======================================================================
-
-void  GeomFill_Curved::Init(const TColgp_Array1OfPnt&   ,  // P1, 
-                        const TColgp_Array1OfPnt&   ,  // P2, 
-                        const TColgp_Array1OfPnt&   ,  // P3, 
-                        const TColStd_Array1OfReal& ,  // W1, 
-                        const TColStd_Array1OfReal& ,  // W2,
-                        const TColStd_Array1OfReal&  ) // W3)
-{
-  Standard_NotImplemented::Raise(" ");
-}
-
-
 //=======================================================================
 //function : Init
 //purpose  : 
index b123a7b..5732ed7 100644 (file)
@@ -40,10 +40,6 @@ public:
   
   Standard_EXPORT GeomFill_Curved(const TColgp_Array1OfPnt& P1, const TColgp_Array1OfPnt& P2, const TColgp_Array1OfPnt& P3, const TColgp_Array1OfPnt& P4, const TColStd_Array1OfReal& W1, const TColStd_Array1OfReal& W2, const TColStd_Array1OfReal& W3, const TColStd_Array1OfReal& W4);
   
-  Standard_EXPORT GeomFill_Curved(const TColgp_Array1OfPnt& P1, const TColgp_Array1OfPnt& P2, const TColgp_Array1OfPnt& P3);
-  
-  Standard_EXPORT GeomFill_Curved(const TColgp_Array1OfPnt& P1, const TColgp_Array1OfPnt& P2, const TColgp_Array1OfPnt& P3, const TColStd_Array1OfReal& W1, const TColStd_Array1OfReal& W2, const TColStd_Array1OfReal& W3);
-  
   Standard_EXPORT GeomFill_Curved(const TColgp_Array1OfPnt& P1, const TColgp_Array1OfPnt& P2);
   
   Standard_EXPORT GeomFill_Curved(const TColgp_Array1OfPnt& P1, const TColgp_Array1OfPnt& P2, const TColStd_Array1OfReal& W1, const TColStd_Array1OfReal& W2);
@@ -52,10 +48,6 @@ public:
   
   Standard_EXPORT void Init (const TColgp_Array1OfPnt& P1, const TColgp_Array1OfPnt& P2, const TColgp_Array1OfPnt& P3, const TColgp_Array1OfPnt& P4, const TColStd_Array1OfReal& W1, const TColStd_Array1OfReal& W2, const TColStd_Array1OfReal& W3, const TColStd_Array1OfReal& W4);
   
-  Standard_EXPORT void Init (const TColgp_Array1OfPnt& P1, const TColgp_Array1OfPnt& P2, const TColgp_Array1OfPnt& P3);
-  
-  Standard_EXPORT void Init (const TColgp_Array1OfPnt& P1, const TColgp_Array1OfPnt& P2, const TColgp_Array1OfPnt& P3, const TColStd_Array1OfReal& W1, const TColStd_Array1OfReal& W2, const TColStd_Array1OfReal& W3);
-  
   Standard_EXPORT void Init (const TColgp_Array1OfPnt& P1, const TColgp_Array1OfPnt& P2);
   
   Standard_EXPORT void Init (const TColgp_Array1OfPnt& P1, const TColgp_Array1OfPnt& P2, const TColStd_Array1OfReal& W1, const TColStd_Array1OfReal& W2);
index d11c5f2..251a7d7 100644 (file)
@@ -73,7 +73,7 @@ static void NormalD0(const Standard_Real U, const Standard_Real V, const Handle(
     (Surf->Surface().UContinuity()) : (Surf->Surface().VContinuity());
   OrderU = OrderV = 0;
 #ifdef CHECK  
-  if (Cont == GeomAbs_C0) Geom_UndefinedValue::Raise();
+  if (Cont == GeomAbs_C0) throw Geom_UndefinedValue();
 #endif
   gp_Pnt P;
   Surf->D1(U, V, P, D1U, D1V);
@@ -84,7 +84,7 @@ static void NormalD0(const Standard_Real U, const Standard_Real V, const Handle(
   if (NStatus != CSLib_Defined) {
     if (Cont==GeomAbs_C0 || 
         Cont==GeomAbs_C1) {
-      Geom_UndefinedValue::Raise();
+      throw Geom_UndefinedValue();
       }
     Standard_Integer MaxOrder=3;
     TColgp_Array2OfVec DerNUV(0,MaxOrder,0,MaxOrder);
@@ -121,7 +121,7 @@ static void NormalD0(const Standard_Real U, const Standard_Real V, const Handle(
               << DerSurf(i,j).Y() <<"," << DerSurf(i,j).Z() << endl;
        }
 #endif
-      Geom_UndefinedValue::Raise();
+      throw Geom_UndefinedValue();
     }
   }
 }
@@ -139,7 +139,7 @@ void NormalD1 (const Standard_Real U, const Standard_Real V,
     (Surf->Surface().UContinuity()) : (Surf->Surface().VContinuity());
   if (Cont==GeomAbs_C0 || 
       Cont==GeomAbs_C1) { 
-    Geom_UndefinedDerivative::Raise();
+    throw Geom_UndefinedDerivative();
   }
 #endif
   gp_Vec d2u, d2v, d2uv;
@@ -182,7 +182,7 @@ void NormalD1 (const Standard_Real U, const Standard_Real V,
   
   CSLib::Normal(MaxOrder,DerNUV,MagTol,U,V,Umin,Umax,Vmin,Vmax,
                 NStatus,Normal,OrderU,OrderV);
-  if (NStatus != CSLib_Defined) Geom_UndefinedValue::Raise();
+  if (NStatus != CSLib_Defined) throw Geom_UndefinedValue();
 
   D1UNormal = CSLib::DNNormal(1,0,DerNUV,OrderU,OrderV);
   D1VNormal = CSLib::DNNormal(0,1,DerNUV,OrderU,OrderV);
@@ -201,7 +201,7 @@ void NormalD2 (const Standard_Real U, const Standard_Real V,
   GeomAbs_Shape Cont = (Surf->Surface().UContinuity() < Surf->Surface().VContinuity()) ? 
     (Surf->Surface().UContinuity()) : (Surf->Surface().VContinuity());
      if (Cont == GeomAbs_C0 || Continuity == GeomAbs_C1 ||
-         Cont == GeomAbs_C2) { Geom_UndefinedDerivative::Raise(); }
+         Cont == GeomAbs_C2) { throw Geom_UndefinedDerivative(); }
 #endif
   gp_Vec d3u, d3uuv, d3uvv, d3v;
   gp_Pnt P;
@@ -250,7 +250,7 @@ void NormalD2 (const Standard_Real U, const Standard_Real V,
   
   CSLib::Normal(MaxOrder,DerNUV,MagTol,U,V,Umin,Umax,Vmin,Vmax,
                 NStatus,Normal,OrderU,OrderV);
-  if (NStatus != CSLib_Defined) Geom_UndefinedValue::Raise();
+  if (NStatus != CSLib_Defined) throw Geom_UndefinedValue();
   
   D1UNormal = CSLib::DNNormal(1,0,DerNUV,OrderU,OrderV);
   D1VNormal = CSLib::DNNormal(0,1,DerNUV,OrderU,OrderV);
index ef9fe3d..47a085c 100755 (executable)
@@ -156,7 +156,7 @@ void GeomFill_DiscreteTrihedron::Init()
         {
           Standard_Real NewParam = (myKnots->Value(i-1) + myKnots->Value(i))/2.;
           if (NewParam - myKnots->Value(i-1) < gp::Resolution())
-            Standard_ConstructionError::Raise("GeomFill_DiscreteTrihedron : impassable singularities on path curve");
+            throw Standard_ConstructionError("GeomFill_DiscreteTrihedron : impassable singularities on path curve");
           myKnots->InsertBefore(i, NewParam);
           i--;
         }
index 14a1390..2f3b749 100644 (file)
@@ -260,7 +260,7 @@ Standard_Boolean GeomFill_DraftTrihedron::D2(const Standard_Real Param,
   case GeomAbs_C2:
   case GeomAbs_C3:
   case GeomAbs_CN: tmpS = GeomAbs_CN; break;
-  default: Standard_OutOfRange::Raise();
+  default: throw Standard_OutOfRange();
   }
   
   return myCurve->NbIntervals(tmpS);
@@ -280,7 +280,7 @@ Standard_Boolean GeomFill_DraftTrihedron::D2(const Standard_Real Param,
   case GeomAbs_C2:
   case GeomAbs_C3:
   case GeomAbs_CN: tmpS = GeomAbs_CN; break;
-  default: Standard_OutOfRange::Raise();
+  default: throw Standard_OutOfRange();
   }
   
   myCurve->Intervals(TT, tmpS);
index d8acab5..dfbde82 100644 (file)
@@ -352,7 +352,7 @@ void GeomFill_EvolvedSection::GetMinimalWeight(TColStd_Array1OfReal& Weights) co
  Handle(Geom_Curve) GeomFill_EvolvedSection::ConstantSection() const
 {
   Standard_Real Err, scale;
-  if (!IsConstant(Err)) StdFail_NotDone::Raise("The Law is not Constant!");
+  if (!IsConstant(Err)) throw StdFail_NotDone("The Law is not Constant!");
   gp_Trsf T;
   gp_Pnt P(0, 0, 0);
   scale = myLaw->Value(First) +  
index ac0ef59..25ee897 100644 (file)
@@ -29,7 +29,7 @@ GeomFill_Fixed::GeomFill_Fixed(const gp_Vec& Tangent,
                               const gp_Vec& Normal)
 {
   if (Tangent.IsParallel(Normal, 0.01) ) 
-    Standard_ConstructionError::Raise(
+    throw Standard_ConstructionError(
       "GeomFill_Fixed : Two parallel vectors !");
   T = Tangent;
   T.Normalize();
index 1e3f195..d1858ef 100644 (file)
@@ -679,7 +679,7 @@ Standard_Boolean
   case GeomAbs_C2:
   case GeomAbs_C3:
   case GeomAbs_CN: tmpS = GeomAbs_CN; break;
-  default: Standard_OutOfRange::Raise();
+  default: throw Standard_OutOfRange();
   }
   
   NbTrimmed = myCurve->NbIntervals(tmpS);
@@ -711,7 +711,7 @@ Standard_Boolean
   case GeomAbs_C2:
   case GeomAbs_C3:
   case GeomAbs_CN: tmpS = GeomAbs_CN; break;
-  default: Standard_OutOfRange::Raise();
+  default: throw Standard_OutOfRange();
   }
 
   if (!isSngl) {
index ef26645..d18a957 100644 (file)
@@ -218,7 +218,7 @@ static void InGoodPeriod(const Standard_Real Prec,
                                           Standard_Real& LastAngle)
 {
   if (myCurve.IsNull())
-    Standard_ConstructionError::Raise(
+    throw Standard_ConstructionError(
           "GeomFill_LocationGuide::The path is not setted !!");
 
     //repere fixe
@@ -811,7 +811,7 @@ static void InGoodPeriod(const Standard_Real Prec,
            cout << "DEDX = " << DEDX << endl;
            cout << "DEDT = " << DEDT << endl;
 #endif
-           Standard_ConstructionError::Raise(
+           throw Standard_ConstructionError(
             "LocationGuide::D1 : No Result dans la derivee");
          }
          
@@ -1364,7 +1364,7 @@ void GeomFill_LocationGuide::Resolution (const Standard_Integer ,
 // void GeomFill_LocationGuide::Rotation(gp_Pnt& Centre)  const
  void GeomFill_LocationGuide::Rotation(gp_Pnt& )  const
 {
-  Standard_NotImplemented::Raise("GeomFill_LocationGuide::Rotation");
+  throw Standard_NotImplemented("GeomFill_LocationGuide::Rotation");
 }
 
 //==================================================================
index ac270d8..ca1d655 100644 (file)
@@ -28,8 +28,7 @@ IMPLEMENT_STANDARD_RTTIEXT(GeomFill_LocationLaw,MMgt_TShared)
 
 Standard_Boolean GeomFill_LocationLaw::D1(const Standard_Real, gp_Mat&, gp_Vec&,gp_Mat&, gp_Vec&,TColgp_Array1OfPnt2d&,TColgp_Array1OfVec2d&) 
 {
-  Standard_NotImplemented::Raise("GeomFill_LocationLaw::D1");
-  return 0;
+  throw Standard_NotImplemented("GeomFill_LocationLaw::D1");
 }
 
  Standard_Boolean GeomFill_LocationLaw::D2(const Standard_Real,
@@ -38,8 +37,7 @@ Standard_Boolean GeomFill_LocationLaw::D1(const Standard_Real, gp_Mat&, gp_Vec&,
                                           gp_Mat&, gp_Vec&, 
                                           TColgp_Array1OfPnt2d&,TColgp_Array1OfVec2d&,TColgp_Array1OfVec2d&) 
 {
-  Standard_NotImplemented::Raise("GeomFill_LocationLaw::D2");
-  return 0;
+  throw Standard_NotImplemented("GeomFill_LocationLaw::D2");
 }
 
  Standard_Integer GeomFill_LocationLaw::Nb2dCurves() const
@@ -78,7 +76,7 @@ Standard_Boolean GeomFill_LocationLaw::D1(const Standard_Real, gp_Mat&, gp_Vec&,
 // void GeomFill_LocationLaw::Resolution(const Standard_Integer Index,const Standard_Real Tol,Standard_Real& TolU,Standard_Real& TolV) const
  void GeomFill_LocationLaw::Resolution(const Standard_Integer ,const Standard_Real ,Standard_Real& ,Standard_Real& ) const
 {
-  Standard_NotImplemented::Raise("GeomFill_LocationLaw::Resolution");
+  throw Standard_NotImplemented("GeomFill_LocationLaw::Resolution");
 }
 
  void GeomFill_LocationLaw::SetTolerance(const Standard_Real,
@@ -97,5 +95,5 @@ Standard_Boolean GeomFill_LocationLaw::D1(const Standard_Real, gp_Mat&, gp_Vec&,
 }
  void GeomFill_LocationLaw::Rotation(gp_Pnt&) const
 {
-  Standard_NotImplemented::Raise("GeomFill_SectionLaw::Rotation");
+  throw Standard_NotImplemented("GeomFill_SectionLaw::Rotation");
 }
index a7a2ad4..48d597f 100644 (file)
@@ -920,7 +920,7 @@ void GeomFill_NSections::GetMinimalWeight(TColStd_Array1OfReal& Weights) const
  Handle(Geom_Curve) GeomFill_NSections::ConstantSection() const
 {
 //  Standard_Real Err;
-//  if (!IsConstant(Err)) StdFail_NotDone::Raise("The Law is not Constant!");
+//  if (!IsConstant(Err)) throw StdFail_NotDone("The Law is not Constant!");
   Handle(Geom_Curve) C;
   C = Handle(Geom_Curve)::DownCast( mySections(1)->Copy());
   return C;
@@ -992,7 +992,7 @@ void GeomFill_NSections::GetMinimalWeight(TColStd_Array1OfReal& Weights) const
  Handle(Geom_Curve) GeomFill_NSections::CirclSection(const Standard_Real V) const
 {
   Standard_Real Err;
-  if (!IsConicalLaw(Err)) StdFail_NotDone::Raise("The Law is not Conical!");
+  if (!IsConicalLaw(Err)) throw StdFail_NotDone("The Law is not Conical!");
 
   GeomAdaptor_Curve AC1(mySections(1));
   GeomAdaptor_Curve AC2(mySections(mySections.Length()));
index 6c122e1..69044ca 100644 (file)
@@ -567,8 +567,7 @@ void GeomFill_Pipe::Init(const Handle(Geom_Curve)& Path,
 
   default :
     {
-      Standard_ConstructionError::Raise
-               ("GeomFill::Init : Unknown Option");
+      throw Standard_ConstructionError("GeomFill::Init : Unknown Option");
     }
   }
  
@@ -717,8 +716,7 @@ void GeomFill_Pipe::Init(const Handle(Geom_Curve)& Path,
     }
     for ( i = 1; i<NSections.Length(); i++) {
       if ( Abs(SeqP.Value(i+1)-SeqP.Value(i)) < Precision::PConfusion()) {
-       Standard_ConstructionError::Raise
-        ("GeomFill_Pipe::Init with NSections : invalid parameters");     
+       throw Standard_ConstructionError("GeomFill_Pipe::Init with NSections : invalid parameters");
       }
     }
     
@@ -890,7 +888,7 @@ void GeomFill_Pipe::Perform(const Standard_Real Tol,
        myIsDone = Standard_True;
      }
      //else {
-     //  Standard_ConstructionError::Raise ("GeomFill_Pipe::Perform : Cannot make a surface");
+     //  throw Standard_ConstructionError("GeomFill_Pipe::Perform : Cannot make a surface");
      //}
    }
  }
@@ -904,7 +902,7 @@ void GeomFill_Pipe::Perform(const Standard_Real Tol,
       myIsDone = Standard_True;
    }
    //else {
-   //  Standard_ConstructionError::Raise ("GeomFill_Pipe::Perform : Cannot make a surface");
+   //  throw Standard_ConstructionError("GeomFill_Pipe::Perform : Cannot make a surface");
    //}
    }
  else {
@@ -1057,7 +1055,7 @@ void GeomFill_Pipe::ApproxSurf(const Standard_Boolean WithParameters) {
   // generate a sequence of the section by <SweepSectionGenerator> 
   // and approximate this sequence. 
   
-  if (myType != 4) Standard_ConstructionError::Raise("GeomFill_Pipe");
+  if (myType != 4) throw Standard_ConstructionError("GeomFill_Pipe");
   GeomFill_SweepSectionGenerator Section(myAdpPath, myAdpFirstSect,
                                           myAdpLastSect,myRadius);
 
@@ -1123,7 +1121,7 @@ void GeomFill_Pipe::ApproxSurf(const Standard_Boolean WithParameters) {
 #endif
     }
 #endif
-    //StdFail_NotDone::Raise("Pipe : App not done");
+    //throw StdFail_NotDone("Pipe : App not done");
   }
   else {
     Standard_Integer UDegree, VDegree, NbUPoles, NbVPoles, NbUKnots, 
index 5488bc3..6313745 100644 (file)
@@ -256,7 +256,7 @@ void GeomFill_Profiler::Perform(const Standard_Real PTol)
 Standard_Integer GeomFill_Profiler::Degree() const 
 {
   if ( !myIsDone)
-    StdFail_NotDone::Raise("GeomFill_Profiler::Degree");
+    throw StdFail_NotDone("GeomFill_Profiler::Degree");
 
   Handle(Geom_BSplineCurve) C = 
     Handle(Geom_BSplineCurve)::DownCast(mySequence(1));
@@ -272,7 +272,7 @@ Standard_Integer GeomFill_Profiler::Degree() const
 Standard_Integer GeomFill_Profiler::NbPoles() const 
 {
   if ( !myIsDone)
-    StdFail_NotDone::Raise("GeomFill_Profiler::Degree");
+    throw StdFail_NotDone("GeomFill_Profiler::Degree");
 
   Handle(Geom_BSplineCurve) C = 
     Handle(Geom_BSplineCurve)::DownCast(mySequence(1));
@@ -289,7 +289,7 @@ void GeomFill_Profiler::Poles(const Standard_Integer Index,
                                    TColgp_Array1OfPnt& Poles) const 
 {
   if ( !myIsDone)
-    StdFail_NotDone::Raise("GeomFill_Profiler::Degree");
+    throw StdFail_NotDone("GeomFill_Profiler::Degree");
 
   Standard_DomainError_Raise_if( Poles.Length() != NbPoles(),
                                "GeomFill_Profiler::Poles");
@@ -312,7 +312,7 @@ void GeomFill_Profiler::Weights(const Standard_Integer      Index,
                                      TColStd_Array1OfReal& Weights) const 
 {
   if ( !myIsDone)
-    StdFail_NotDone::Raise("GeomFill_Profiler::Degree");
+    throw StdFail_NotDone("GeomFill_Profiler::Degree");
 
   Standard_DomainError_Raise_if( Weights.Length() != NbPoles(),
                                "GeomFill_Profiler::Weights");
@@ -334,7 +334,7 @@ void GeomFill_Profiler::Weights(const Standard_Integer      Index,
 Standard_Integer GeomFill_Profiler::NbKnots() const 
 {
   if ( !myIsDone)
-    StdFail_NotDone::Raise("GeomFill_Profiler::Degree");
+    throw StdFail_NotDone("GeomFill_Profiler::Degree");
 
   Handle(Geom_BSplineCurve) C = 
     Handle(Geom_BSplineCurve)::DownCast(mySequence(1));
@@ -352,7 +352,7 @@ void GeomFill_Profiler::KnotsAndMults(TColStd_Array1OfReal&    Knots,
                                      TColStd_Array1OfInteger& Mults ) const 
 {
   if ( !myIsDone)
-    StdFail_NotDone::Raise("GeomFill_Profiler::Degree");
+    throw StdFail_NotDone("GeomFill_Profiler::Degree");
 
 #ifndef No_Exception
   Standard_Integer n = NbKnots();
index 236720c..da6490b 100644 (file)
@@ -28,14 +28,12 @@ IMPLEMENT_STANDARD_RTTIEXT(GeomFill_SectionLaw,MMgt_TShared)
 
 Standard_Boolean GeomFill_SectionLaw::D1(const Standard_Real,TColgp_Array1OfPnt&,TColgp_Array1OfVec&,TColStd_Array1OfReal&,TColStd_Array1OfReal& ) 
 {
-  Standard_NotImplemented::Raise("GeomFill_SectionLaw::D1");
-  return 0;
+  throw Standard_NotImplemented("GeomFill_SectionLaw::D1");
 }
 
  Standard_Boolean GeomFill_SectionLaw::D2(const Standard_Real,TColgp_Array1OfPnt& ,TColgp_Array1OfVec&,TColgp_Array1OfVec&,TColStd_Array1OfReal&,TColStd_Array1OfReal&,TColStd_Array1OfReal&) 
 {
-  Standard_NotImplemented::Raise("GeomFill_SectionLaw::D2");
-  return 0;  
+  throw Standard_NotImplemented("GeomFill_SectionLaw::D2");
 }
 
  Handle(Geom_BSplineSurface) GeomFill_SectionLaw::BSplineSurface() const
@@ -53,13 +51,12 @@ Standard_Boolean GeomFill_SectionLaw::D1(const Standard_Real,TColgp_Array1OfPnt&
  gp_Pnt GeomFill_SectionLaw::BarycentreOfSurf() const
 {
 
-  Standard_NotImplemented::Raise("GeomFill_SectionLaw::BarycentreOfSurf");
-    return gp_Pnt(0.0, 0.0, 0.0);
+  throw Standard_NotImplemented("GeomFill_SectionLaw::BarycentreOfSurf");
 }
 
  void GeomFill_SectionLaw::GetMinimalWeight(TColStd_Array1OfReal&) const
 {
-  Standard_NotImplemented::Raise("GeomFill_SectionLaw::GetMinimalWeight");
+  throw Standard_NotImplemented("GeomFill_SectionLaw::GetMinimalWeight");
 }
 
  Standard_Boolean GeomFill_SectionLaw::IsConstant(Standard_Real& Error) const
@@ -71,8 +68,7 @@ Standard_Boolean GeomFill_SectionLaw::D1(const Standard_Real,TColgp_Array1OfPnt&
  Handle(Geom_Curve)  GeomFill_SectionLaw::ConstantSection() const
 {
  Handle(Geom_Curve) C;
- Standard_DomainError::Raise("GeomFill_SectionLaw::ConstantSection");
- return C;
+ throw Standard_DomainError("GeomFill_SectionLaw::ConstantSection");
 }
 
  Standard_Boolean GeomFill_SectionLaw::IsConicalLaw(Standard_Real& Error) const
@@ -85,6 +81,5 @@ Standard_Boolean GeomFill_SectionLaw::D1(const Standard_Real,TColgp_Array1OfPnt&
  CirclSection(const Standard_Real) const
 {
  Handle(Geom_Curve) C;
- Standard_DomainError::Raise("GeomFill_SectionLaw::CirclSection");
- return C;
+ throw Standard_DomainError("GeomFill_SectionLaw::CirclSection");
 }
index e149490..e4223d8 100644 (file)
@@ -804,7 +804,7 @@ void GeomFill_SectionPlacement::Perform(const Standard_Real Param,
     Standard_Real angle;
     
     if (!isplan)
-      Standard_Failure::Raise("Illegal usage: can't rotate non-planar profile");
+      throw Standard_Failure("Illegal usage: can't rotate non-planar profile");
     
     gp_Dir ProfileNormal = TheAxe.Direction();
     gp_Dir SpineStartDir = Paxe.Direction();
@@ -839,7 +839,7 @@ void GeomFill_SectionPlacement::Perform(const Standard_Real Param,
     //     gp_Trsf Rot;
     
     //     if (!isplan)
-    //       Standard_Failure::Raise("Illegal usage: can't rotate non-planar profile");
+    //       throw Standard_Failure("Illegal usage: can't rotate non-planar profile");
     
     //     gp_Dir ProfileNormal = TheAxe.Direction();
     //     gp_Dir SpineStartDir = Paxe.Direction();
index bfaeb2f..a81cee6 100644 (file)
@@ -51,7 +51,7 @@ void GeomFill_SnglrFunc::SetRatio(const Standard_Real Ratio)
   case GeomAbs_C0: HCS = GeomAbs_C2; break;
   case GeomAbs_C1: HCS = GeomAbs_C3; break;
   case GeomAbs_C2: HCS = GeomAbs_CN; break;
-  default: Standard_DomainError::Raise();
+  default: throw Standard_DomainError();
   }
   return myHCurve->NbIntervals(HCS);
 }
@@ -63,7 +63,7 @@ void GeomFill_SnglrFunc::SetRatio(const Standard_Real Ratio)
   case GeomAbs_C0: HCS = GeomAbs_C2; break;
   case GeomAbs_C1: HCS = GeomAbs_C3; break;
   case GeomAbs_C2: HCS = GeomAbs_CN; break;
-  default: Standard_DomainError::Raise();
+  default: throw Standard_DomainError();
   }
   myHCurve->Intervals(T, HCS);
 }
@@ -153,12 +153,9 @@ gp_Vec GeomFill_SnglrFunc::DN(const Standard_Real U,const Standard_Integer N) co
       D3(U,C,D1C,D2C,D3C);
       return D3C;
     default:
-      Standard_NotImplemented::Raise("Exception: Derivative order is greater than 3. "
+      throw Standard_NotImplemented("Exception: Derivative order is greater than 3. "
         "Cannot compute of derivative.");
     }
-   
-  return gp_Vec();
-
   }
 
  Standard_Real GeomFill_SnglrFunc::Resolution(const Standard_Real R3D) const
index f827697..01cf6d5 100644 (file)
@@ -1101,7 +1101,7 @@ static Standard_Boolean IsSweepParallelSpine (const Handle(GeomFill_LocationLaw)
 {
   Standard_Integer ind = IndexOfTrace+1;
   if (IndexOfTrace > myLoc->TraceNumber())
-    Standard_OutOfRange::Raise(" GeomFill_Sweep::ErrorOnTrace");
+    throw Standard_OutOfRange(" GeomFill_Sweep::ErrorOnTrace");
 
   UError =  CError->Value(1, ind);
   VError =  CError->Value(2, ind);
@@ -1146,6 +1146,6 @@ static Standard_Boolean IsSweepParallelSpine (const Handle(GeomFill_LocationLaw)
 {
   Standard_Integer ind = IndexOfTrace+1;
   if (IndexOfTrace > myLoc->TraceNumber())
-    Standard_OutOfRange::Raise(" GeomFill_Sweep::Trace");
+    throw Standard_OutOfRange(" GeomFill_Sweep::Trace");
   return  myCurve2d->Value(ind);  
 }
index ed600bb..76e1782 100644 (file)
@@ -674,8 +674,7 @@ const gp_Trsf& GeomFill_SweepSectionGenerator::Transformation
   (const Standard_Integer Index) const 
 {
   if (Index > myTrsfs.Length())
-    Standard_RangeError::Raise
-      ("GeomFill_SweepSectionGenerator::Transformation");
+    throw Standard_RangeError("GeomFill_SweepSectionGenerator::Transformation");
   
   return myTrsfs(Index);
 }
index 5334c3f..fa5e7b7 100644 (file)
@@ -43,8 +43,7 @@ void GeomFill_TrihedronLaw::SetCurve(const Handle(Adaptor3d_HCurve)& C)
                                            gp_Vec& ,gp_Vec&,gp_Vec&,
                                            gp_Vec&,gp_Vec&,gp_Vec& ) 
 {
-  Standard_NotImplemented::Raise(" GeomFill_TrihedronLaw::D2");
-  return Standard_False; 
+  throw Standard_NotImplemented(" GeomFill_TrihedronLaw::D2");
 }
 
  Standard_Boolean GeomFill_TrihedronLaw::D2(const Standard_Real,
@@ -52,8 +51,7 @@ void GeomFill_TrihedronLaw::SetCurve(const Handle(Adaptor3d_HCurve)& C)
                                            gp_Vec& ,gp_Vec&,gp_Vec&,
                                            gp_Vec&,gp_Vec& ,gp_Vec&) 
 {
-  Standard_NotImplemented::Raise(" GeomFill_TrihedronLaw::D2");
-  return Standard_False;
+  throw Standard_NotImplemented(" GeomFill_TrihedronLaw::D2");
 }
 
 void GeomFill_TrihedronLaw::SetInterval(const Standard_Real First,
index 8ba1c0c..5cac732 100644 (file)
     case GeomAbs_Cone:     quad1.SetValue(HS1->Surface().Cone()); break;
     case GeomAbs_Sphere:   quad1.SetValue(HS1->Surface().Sphere()); break;
     case GeomAbs_Torus:    quad1.SetValue(HS1->Surface().Torus()); break;
-    default: Standard_ConstructionError::Raise("GeomInt_IntSS::MakeCurve");
+    default: throw Standard_ConstructionError("GeomInt_IntSS::MakeCurve");
   }
 }
 
index 250dff8..60948f4 100644 (file)
@@ -679,7 +679,7 @@ void Parameters(const Handle(GeomAdaptor_HSurface)& myHS1,
       quad1.SetValue(myHS1->Surface().Torus()); 
       break;
     default: 
-      Standard_ConstructionError::Raise("GeomInt_LineConstructor::Parameters");
+      throw Standard_ConstructionError("GeomInt_LineConstructor::Parameters");
   }
   quad1.Parameters(Ptref,U1,V1);
 }
@@ -710,7 +710,7 @@ void GLinePoint(const IntPatch_IType typl,
     aP = ElCLib::Value(aT, GLine->Parabola()); 
     break;
   default:
-    Standard_ConstructionError::Raise("GeomInt_LineConstructor::Parameters");
+    throw Standard_ConstructionError("GeomInt_LineConstructor::Parameters");
   }
 }
 
index b00f11a..1eb3fe5 100644 (file)
@@ -62,7 +62,7 @@ inline Standard_Boolean GeomInt_LineConstructor::IsDone () const
 
 inline Standard_Integer GeomInt_LineConstructor::NbParts () const
 {
-  if (!done) { StdFail_NotDone::Raise(); }
+  if (!done) { throw StdFail_NotDone(); }
   return (seqp.Length() / 2);
 }
 
@@ -75,7 +75,7 @@ inline void GeomInt_LineConstructor::Part (const Standard_Integer I,
                                            Standard_Real& WFirst,
                                            Standard_Real& WLast) const
 {
-  if (!done) { StdFail_NotDone::Raise(); }
+  if (!done) { throw StdFail_NotDone(); }
   WFirst = seqp(2*I-1);
   WLast  = seqp(2*I);
 }
index bafa4a0..48afa78 100644 (file)
@@ -47,10 +47,6 @@ public:
 
   DEFINE_STANDARD_ALLOC
 
-  
-  //! Raises Construction Error
-  Standard_EXPORT GeomInt_TheFunctionOfTheInt2SOfThePrmPrmSvSurfacesOfWLApprox();
-  
   Standard_EXPORT GeomInt_TheFunctionOfTheInt2SOfThePrmPrmSvSurfacesOfWLApprox(const Handle(Adaptor3d_HSurface)& S1, const Handle(Adaptor3d_HSurface)& S2);
   
   Standard_EXPORT Standard_Integer NbVariables() const;
index 049152c..d1323e8 100644 (file)
@@ -49,10 +49,6 @@ public:
 
   DEFINE_STANDARD_ALLOC
 
-  
-  //! Raises Construction Error
-  Standard_EXPORT GeomInt_TheInt2SOfThePrmPrmSvSurfacesOfWLApprox();
-  
   //! compute the solution point with the close point
   Standard_EXPORT GeomInt_TheInt2SOfThePrmPrmSvSurfacesOfWLApprox(const TColStd_Array1OfReal& Param, const Handle(Adaptor3d_HSurface)& S1, const Handle(Adaptor3d_HSurface)& S2, const Standard_Real TolTangency);
   
index 83b7c83..c3fdccc 100644 (file)
@@ -137,7 +137,7 @@ GeomAbs_Shape GeomLProp::Continuity(const Handle(Geom_Curve)& C1,
   GeomLProp_CLProps clp1(C1,u1,n1,tl);
   GeomLProp_CLProps clp2(C2,u2,n2,tl);
   if(!(clp1.Value().IsEqual(clp2.Value(),tl))) {
-    Standard_Failure::Raise("Courbes non jointives");
+    throw Standard_Failure("Courbes non jointives");
   }
   Standard_Integer min = Min(n1,n2);
   if ( min >= 1 ) {
index c19096b..7f8867a 100644 (file)
@@ -703,7 +703,7 @@ Handle(Geom_Curve) GeomLib::To3d (const gp_Ax2&               Position,
     Curve3d = GeomH3d;
   }
   else {
-    Standard_NotImplemented::Raise();
+    throw Standard_NotImplemented();
   }
   
   return Curve3d;
@@ -886,7 +886,7 @@ void GeomLib::SameRange(const Standard_Real         Tolerance,
                        const Standard_Real         RequestedLast,
                              Handle(Geom2d_Curve)& NewCurvePtr) 
 {
-  if(CurvePtr.IsNull()) Standard_Failure::Raise();
+  if(CurvePtr.IsNull()) throw Standard_Failure();
   if (Abs(LastOnCurve - RequestedLast) <= Tolerance &&
     Abs(FirstOnCurve - RequestedFirst) <= Tolerance)
   { 
@@ -1222,7 +1222,7 @@ void GeomLib::AdjustExtremity(Handle(Geom_BoundedCurve)& Curve,
   // Interpolation des contraintes
   math_Matrix Mat(1, 4, 1, 4);
   if (!PLib::HermiteCoefficients(0., 1., 1, 1, Mat)) 
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
 
   for (jj=1; jj<=4; jj++) {
     gp_XYZ aux(0.,0.,0.);
@@ -1251,7 +1251,7 @@ void GeomLib::AdjustExtremity(Handle(Geom_BoundedCurve)& Curve,
   }
 
   if (aDef->NbPoles() != aIn->NbPoles()) 
-    Standard_ConstructionError::Raise("Inconsistent poles's number");
+    throw Standard_ConstructionError("Inconsistent poles's number");
 
   for (ii=1; ii<=aDef->NbPoles(); ii++) {
     P = aIn->Pole(ii);
@@ -1373,7 +1373,7 @@ void GeomLib::ExtendCurveToPoint(Handle(Geom_BoundedCurve)& Curve,
 
   // Concatenation
   Ok = Concat.Add(Bezier, Tol, After);
-  if (!Ok) Standard_ConstructionError::Raise("ExtendCurveToPoint");
+  if (!Ok) throw Standard_ConstructionError("ExtendCurveToPoint");
   
   Curve =  Concat.BSplineCurve();
 }
@@ -2232,7 +2232,7 @@ static void FunctionMultiply(Handle(Geom_BSplineSurface)&          BSurf,
                            NewDenominator,
                            status);
  if (status!=0)
-   Standard_ConstructionError::Raise("GeomLib Multiplication Error") ;
+   throw Standard_ConstructionError("GeomLib Multiplication Error") ;
  for (i = 1 ; i <= new_num_u_poles ; i++) {
       for (j = 1 ; j <= new_num_v_poles ; j++) {
        for (k = 1 ; k <= 3 ; k++) {
index ec5e68d..e6765e0 100644 (file)
@@ -331,6 +331,6 @@ GeomLib_IsPlanarSurface::GeomLib_IsPlanarSurface(const Handle(Geom_Surface)& S,
 
  const gp_Pln& GeomLib_IsPlanarSurface::Plan() const
 {
-  if (!IsPlan) StdFail_NotDone::Raise(" GeomLib_IsPlanarSurface");
+  if (!IsPlan) throw StdFail_NotDone(" GeomLib_IsPlanarSurface");
   return myPlan;
 }
index b97f660..747ea22 100644 (file)
@@ -37,7 +37,7 @@ Standard_Real GeomLib_LogSample::GetParameter(const Standard_Integer Index) cons
     Bounds(aA, aB);
     if (Index == 1) return aA;
     else if (Index == aN) return aB;
-    else Standard_OutOfRange::Raise("GeomLib_LogSample::GetParameter");
+    else throw Standard_OutOfRange("GeomLib_LogSample::GetParameter");
   }
 
   Standard_Real v = myF + Exp(myexp*Index);
index 0c1e5c8..ada816c 100644 (file)
@@ -134,21 +134,21 @@ myNbBounds(0)
   myLinCont = new GeomPlate_HSequenceOfCurveConstraint;
   myPntCont = new GeomPlate_HSequenceOfPointConstraint;
   if (myNbIter<1)
-    Standard_ConstructionError::Raise("GeomPlate :  Number of iteration must be >= 1");
+    throw Standard_ConstructionError("GeomPlate :  Number of iteration must be >= 1");
     
   if (NTCurve==0) 
-    Standard_ConstructionError::Raise("GeomPlate : the bounds Array is null");
+    throw Standard_ConstructionError("GeomPlate : the bounds Array is null");
   if (Tang->Length()==0) 
-    Standard_ConstructionError::Raise("GeomPlate : the constraints Array is null");
+    throw Standard_ConstructionError("GeomPlate : the constraints Array is null");
   Standard_Integer nbp = 0;
   Standard_Integer i ;
   for ( i=1;i<=NTCurve;i++) 
     { nbp+=NPoints->Value(i);
     }
   if (nbp==0) 
-    Standard_ConstructionError::Raise("GeomPlate : the resolution is impossible if the number of constraints points is 0");
+    throw Standard_ConstructionError("GeomPlate : the resolution is impossible if the number of constraints points is 0");
   if (myDegree<2) 
-    Standard_ConstructionError::Raise("GeomPlate ; the degree resolution must be upper of 2");  
+    throw Standard_ConstructionError("GeomPlate ; the degree resolution must be upper of 2");
   // Remplissage des champs  passage de l'ancien constructeur au nouveau
   for(i=1;i<=NTCurve;i++) 
     { Handle(GeomPlate_CurveConstraint) Cont = new GeomPlate_CurveConstraint 
@@ -187,9 +187,9 @@ myTol3d(Tol3d),
 myTolAng(TolAng),
 myNbBounds(0)
 {   if (myNbIter<1)
-    Standard_ConstructionError::Raise("GeomPlate :  Number of iteration must be >= 1");
+    throw Standard_ConstructionError("GeomPlate :  Number of iteration must be >= 1");
  if (myDegree<2) 
-     Standard_ConstructionError::Raise("GeomPlate : the degree resolution must be upper of 2");  
+     throw Standard_ConstructionError("GeomPlate : the degree resolution must be upper of 2");
    myLinCont = new GeomPlate_HSequenceOfCurveConstraint;
    myPntCont = new GeomPlate_HSequenceOfPointConstraint;
   mySurfInitIsGive=Standard_True;
@@ -221,9 +221,9 @@ myTol3d(Tol3d),
 myTolAng(TolAng),
 myNbBounds(0)
 {  if (myNbIter<1)
-    Standard_ConstructionError::Raise("GeomPlate :  Number of iteration must be >= 1");
+    throw Standard_ConstructionError("GeomPlate :  Number of iteration must be >= 1");
  if (myDegree<2) 
-    Standard_ConstructionError::Raise("GeomPlate : the degree resolution must be upper of 2");  
+    throw Standard_ConstructionError("GeomPlate : the degree resolution must be upper of 2");
   myLinCont = new GeomPlate_HSequenceOfCurveConstraint;
   myPntCont = new GeomPlate_HSequenceOfPointConstraint;
   mySurfInitIsGive=Standard_False;
@@ -497,7 +497,7 @@ void GeomPlate_BuildPlateSurface::Perform()
          for (Standard_Integer l=1;l<=NTLinCont;l++)
            myInitOrder->SetValue(l,l);
          if (!CourbeJointive(myTol3d)) 
-           {//    Standard_Failure::Raise("Curves are not joined"); 
+           {//    throw Standard_Failure("Curves are not joined");
 #ifdef OCCT_DEBUG
              cout<<"WARNING : Courbes non jointives a "<<myTol3d<<" pres"<<endl;
 #endif   
@@ -1527,7 +1527,7 @@ void GeomPlate_BuildPlateSurface::ComputeSurfInit()
       if ( NTPntCont != 0)
        nopt = 1;  //Calcul par la methode du plan d'inertie
       else if (!CourbeJoint || NTLinCont != myNbBounds)
-       {//    Standard_Failure::Raise("Curves are not joined"); 
+       {//    throw Standard_Failure("Curves are not joined");
 #ifdef OCCT_DEBUG          
          cout<<"WARNING : Courbes non jointives a "<<myTol3d<<" pres"<<endl;
 #endif   
index 6a66b70..e2f205d 100644 (file)
@@ -68,7 +68,7 @@ myTolCurv(TolCurv)
 {
   myOrder=Tang;
   if ((Tang<-1)||(Tang>2))
-    Standard_Failure::Raise("GeomPlate : The continuity is not G0 G1 or G2"); 
+    throw Standard_Failure("GeomPlate : The continuity is not G0 G1 or G2");
   myNbPoints=NPt;
   myConstG0=Standard_True;
   myConstG1=Standard_True;
@@ -94,7 +94,7 @@ myTolCurv(TolCurv)
       //      BS1=Handle(BRepAdaptor_HSurface)::DownCast(myFrontiere->
       //                                            ChangeCurve().GetSurface());
       //      Surf = BRep_Tool::Surface(BS1->ChangeSurface().Face());
-      Standard_Failure::Raise(
+      throw Standard_Failure(
                     "GeomPlate_CurveConstraint : Surface must be GeomAdaptor_Surface");
     }
 
@@ -178,7 +178,7 @@ void GeomPlate_CurveConstraint :: D1(const Standard_Real U,
                                  gp_Pnt& P,gp_Vec& V1,gp_Vec& V2) const
 { gp_Pnt2d P2d;
    if (!my3dCurve.IsNull())
-    Standard_Failure::Raise("GeomPlate_CurveConstraint.cxx : Curve must be on a Surface"); 
+    throw Standard_Failure("GeomPlate_CurveConstraint.cxx : Curve must be on a Surface");
 
   P2d = myFrontiere->ChangeCurve().GetCurve()->Value(U);
   myFrontiere->ChangeCurve().GetSurface()->D1(P2d.Coord(1),P2d.Coord(2),P,V1,V2);
@@ -193,7 +193,7 @@ void GeomPlate_CurveConstraint :: D2(const Standard_Real U,
                                gp_Vec& V3,gp_Vec& V4,gp_Vec& V5) const
 {  gp_Pnt2d P2d;
    if (!my3dCurve.IsNull())
-    Standard_Failure::Raise("GeomPlate_CurveConstraint.cxx : Curve must be on a Surface"); 
+    throw Standard_Failure("GeomPlate_CurveConstraint.cxx : Curve must be on a Surface");
 
   P2d = myFrontiere->ChangeCurve().GetCurve()->Value(U);
   myFrontiere->ChangeCurve().GetSurface()->D2(P2d.Coord(1),P2d.Coord(2),P,V1,V2,V3,V4,V5);
@@ -211,7 +211,7 @@ void GeomPlate_CurveConstraint :: SetG0Criterion(const Handle(Law_Function) &G0C
 //---------------------------------------------------------
 void GeomPlate_CurveConstraint :: SetG1Criterion(const Handle(Law_Function) &G1Crit)
 { if (!my3dCurve.IsNull())
-    Standard_Failure::Raise("GeomPlate_CurveConstraint.cxx : Curve must be on a Surface"); 
+    throw Standard_Failure("GeomPlate_CurveConstraint.cxx : Curve must be on a Surface");
   myG1Crit=G1Crit;
   myConstG1=Standard_False;
 }
@@ -220,7 +220,7 @@ void GeomPlate_CurveConstraint :: SetG1Criterion(const Handle(Law_Function) &G1C
 //---------------------------------------------------------
 void GeomPlate_CurveConstraint :: SetG2Criterion(const Handle(Law_Function) &G2Crit)
 { if (!my3dCurve.IsNull())
-    Standard_Failure::Raise("GeomPlate_CurveConstraint.cxx : Curve must be on a Surface"); 
+    throw Standard_Failure("GeomPlate_CurveConstraint.cxx : Curve must be on a Surface");
   myG2Crit=G2Crit;
   myConstG2=Standard_False;
 }
@@ -238,7 +238,7 @@ Standard_Real GeomPlate_CurveConstraint :: G0Criterion(const Standard_Real U) co
 //---------------------------------------------------------
 Standard_Real GeomPlate_CurveConstraint :: G1Criterion(const Standard_Real U) const
 { if (!my3dCurve.IsNull())
-    Standard_Failure::Raise("GeomPlate_CurveConstraint.cxx : Curve must be on a Surface"); 
+    throw Standard_Failure("GeomPlate_CurveConstraint.cxx : Curve must be on a Surface");
   if (myConstG1)
     return myTolAng;
   else 
@@ -249,7 +249,7 @@ Standard_Real GeomPlate_CurveConstraint :: G1Criterion(const Standard_Real U) co
 //---------------------------------------------------------
 Standard_Real GeomPlate_CurveConstraint :: G2Criterion(const Standard_Real U) const
 { if (!my3dCurve.IsNull())
-    Standard_Failure::Raise("GeomPlate_CurveConstraint.cxx : Curve must be on a Surface"); 
+    throw Standard_Failure("GeomPlate_CurveConstraint.cxx : Curve must be on a Surface");
   if (myConstG2)
     return myTolCurv;
   else 
@@ -338,7 +338,7 @@ myOrder = Order;
 //------------------------------------------------------------
 GeomLProp_SLProps &GeomPlate_CurveConstraint::LPropSurf(const Standard_Real U)
 {  if (myFrontiere.IsNull())
-    Standard_Failure::Raise("GeomPlate_CurveConstraint.cxx : Curve must be on a Surface"); 
+    throw Standard_Failure("GeomPlate_CurveConstraint.cxx : Curve must be on a Surface");
   gp_Pnt2d P2d= myFrontiere->ChangeCurve().GetCurve()->Value(U);
 myLProp.SetParameters(P2d.X(),P2d.Y());
 return myLProp;
index 126ff33..ea83cc2 100644 (file)
@@ -46,7 +46,7 @@ myPoint(Pt),
 myTolDist(TolDist),
 hasPnt2dOnSurf(Standard_False)
 { if ((myOrder>1)||(myOrder<-1))
-    Standard_Failure::Raise("GeomPlate_PointConstraint : the constraint must 0 or -1 with a point"); 
+    throw Standard_Failure("GeomPlate_PointConstraint : the constraint must 0 or -1 with a point");
 }
 
 //---------------------------------------------------------
@@ -150,14 +150,14 @@ Standard_Real GeomPlate_PointConstraint::G2Criterion() const
 // Fonction : Surface 
 //---------------------------------------------------------
 //Handle(Geom_Surface) GeomPlate_PointConstraint::Surface() const
-//{  Standard_Failure::Raise("GeomPlate_PointConstraint.cxx : The surface does not exist"); 
+//{  throw Standard_Failure("GeomPlate_PointConstraint.cxx : The surface does not exist");
 //}
 //------------------------------------------------------------
 //Fonction : LPropSurf
 //------------------------------------------------------------
 GeomLProp_SLProps &GeomPlate_PointConstraint::LPropSurf()
 { // if (myFrontiere.IsNull())
-  //  Standard_Failure::Raise("GeomPlate_CurveConstraint.cxx : Curve must be on a Surface"); 
+  //  throw Standard_Failure("GeomPlate_CurveConstraint.cxx : Curve must be on a Surface");
  // gp_Pnt2d P2d= myFrontiere->ChangeCurve().GetCurve()->Value(U);
 myLProp.SetParameters(myU,myV);
 return myLProp;
index f083969..89f8219 100644 (file)
@@ -55,7 +55,7 @@ GeomPlate_Surface::GeomPlate_Surface(const Handle(Geom_Surface)& Surfinit,const
 
 void GeomPlate_Surface::UReverse()
 {
- //Standard_Failure::Raise("UReverse"); 
+ //throw Standard_Failure("UReverse");
 }
 
 
@@ -65,7 +65,7 @@ void GeomPlate_Surface::UReverse()
 //=======================================================================
 
 Standard_Real GeomPlate_Surface::UReversedParameter(const Standard_Real U) const 
-{ //Standard_Failure::Raise("UReversedParameter"); 
+{ //throw Standard_Failure("UReversedParameter");
   return (-U);
 }
 
@@ -76,7 +76,7 @@ Standard_Real GeomPlate_Surface::UReversedParameter(const Standard_Real U) const
 //=======================================================================
 
 void GeomPlate_Surface::VReverse()
-{ //Standard_Failure::Raise("VReverse");
+{ //throw Standard_Failure("VReverse");
 }
 
 
@@ -86,7 +86,7 @@ void GeomPlate_Surface::VReverse()
 //=======================================================================
 
 Standard_Real GeomPlate_Surface::VReversedParameter(const Standard_Real V) const 
-{ //Standard_Failure::Raise("VReversedParameter");
+{ //throw Standard_Failure("VReversedParameter");
   return (-V);
 }
 
@@ -98,7 +98,7 @@ Standard_Real GeomPlate_Surface::VReversedParameter(const Standard_Real V) const
 
 //void GeomPlate_Surface::TransformParameters(Standard_Real& U, Standard_Real& V, const gp_Trsf& T) const 
 void GeomPlate_Surface::TransformParameters(Standard_Real& , Standard_Real& , const gp_Trsf& ) const 
-{//Standard_Failure::Raise("TransformParameters");
+{//throw Standard_Failure("TransformParameters");
 }
 
 
@@ -109,7 +109,7 @@ void GeomPlate_Surface::TransformParameters(Standard_Real& , Standard_Real& , co
 
 //gp_GTrsf2d GeomPlate_Surface::ParametricTransformation(const gp_Trsf& T) const 
 gp_GTrsf2d GeomPlate_Surface::ParametricTransformation(const gp_Trsf& ) const 
-{//Standard_Failure::Raise("ParametricTransformation");
+{//throw Standard_Failure("ParametricTransformation");
   return gp_GTrsf2d();
 }
 
@@ -134,7 +134,7 @@ void GeomPlate_Surface::Bounds(Standard_Real& U1, Standard_Real& U2, Standard_Re
 //=======================================================================
 
 Standard_Boolean GeomPlate_Surface::IsUClosed() const 
-{ //Standard_Failure::Raise("IsUClosed(");
+{ //throw Standard_Failure("IsUClosed(");
   //return 1;
   return 0;
 }
@@ -146,7 +146,7 @@ Standard_Boolean GeomPlate_Surface::IsUClosed() const
 //=======================================================================
 
 Standard_Boolean GeomPlate_Surface::IsVClosed() const 
-{ //Standard_Failure::Raise("IsVClosed(");
+{ //throw Standard_Failure("IsVClosed(");
   //return 1;
   return 0;
 }
@@ -203,7 +203,7 @@ Standard_Real GeomPlate_Surface::VPeriod() const
 
 //Handle(Geom_Curve) GeomPlate_Surface::UIso(const Standard_Real U) const 
 Handle(Geom_Curve) GeomPlate_Surface::UIso(const Standard_Real ) const 
-{ //Standard_Failure::Raise("UIso");
+{ //throw Standard_Failure("UIso");
   return Handle(Geom_Curve)();
 }
 
@@ -215,7 +215,7 @@ Handle(Geom_Curve) GeomPlate_Surface::UIso(const Standard_Real ) const
 
 //Handle(Geom_Curve) GeomPlate_Surface::VIso(const Standard_Real V) const 
 Handle(Geom_Curve) GeomPlate_Surface::VIso(const Standard_Real ) const 
-{ //Standard_Failure::Raise("VIso");
+{ //throw Standard_Failure("VIso");
   return Handle(Geom_Curve)();
 }
 
@@ -226,7 +226,7 @@ Handle(Geom_Curve) GeomPlate_Surface::VIso(const Standard_Real ) const
 //=======================================================================
 
 GeomAbs_Shape GeomPlate_Surface::Continuity() const 
-{ //Standard_Failure::Raise("Continuity()");
+{ //throw Standard_Failure("Continuity()");
   return GeomAbs_Shape();
 
 }
@@ -239,8 +239,8 @@ GeomAbs_Shape GeomPlate_Surface::Continuity() const
 
 //Standard_Boolean GeomPlate_Surface::IsCNu(const Standard_Integer N) const 
 Standard_Boolean GeomPlate_Surface::IsCNu(const Standard_Integer ) const 
-{ Standard_Failure::Raise("IsCNu");
-  return 1;
+{
+  throw Standard_Failure("IsCNu");
 }
 
 
@@ -251,8 +251,8 @@ Standard_Boolean GeomPlate_Surface::IsCNu(const Standard_Integer ) const
 
 //Standard_Boolean GeomPlate_Surface::IsCNv(const Standard_Integer N) const 
 Standard_Boolean GeomPlate_Surface::IsCNv(const Standard_Integer ) const 
-{ Standard_Failure::Raise("IsCNv");
return 1;
+{
 throw Standard_Failure("IsCNv");
 }
 
 
@@ -329,7 +329,7 @@ void GeomPlate_Surface::D2(const Standard_Real U, const Standard_Real V, gp_Pnt&
 
 //void GeomPlate_Surface::D3(const Standard_Real U, const Standard_Real V, gp_Pnt& P, gp_Vec& D1U, gp_Vec& D1V, gp_Vec& D2U, gp_Vec& D2V, gp_Vec& D2UV, gp_Vec& D3U, gp_Vec& D3V, gp_Vec& D3UUV, gp_Vec& D3UVV) const 
 void GeomPlate_Surface::D3(const Standard_Real , const Standard_Real , gp_Pnt& , gp_Vec& , gp_Vec& , gp_Vec& , gp_Vec& , gp_Vec& , gp_Vec& , gp_Vec& , gp_Vec& , gp_Vec& ) const 
-{ Standard_Failure::Raise("D3");
+{ throw Standard_Failure("D3");
 }
 
 
@@ -340,8 +340,8 @@ void GeomPlate_Surface::D3(const Standard_Real , const Standard_Real , gp_Pnt& ,
 
 //gp_Vec GeomPlate_Surface::DN(const Standard_Real U, const Standard_Real V, const Standard_Integer Nu, const Standard_Integer Nv) const 
 gp_Vec GeomPlate_Surface::DN(const Standard_Real , const Standard_Real , const Standard_Integer , const Standard_Integer ) const 
-{ Standard_Failure::Raise("DN");
-  return gp_Vec();
+{
+  throw Standard_Failure("DN");
 }
 
 
@@ -365,7 +365,7 @@ Handle(Geom_Geometry) GeomPlate_Surface::Copy() const
 
 //void GeomPlate_Surface::Transform(const gp_Trsf& T)
 void GeomPlate_Surface::Transform(const gp_Trsf& )
-{ //Standard_Failure::Raise("Transform");
+{ //throw Standard_Failure("Transform");
 }
 
 //=======================================================================
@@ -387,8 +387,8 @@ Handle(Geom_Surface) GeomPlate_Surface::CallSurfinit() const
 
 void GeomPlate_Surface::SetBounds(const Standard_Real Umin, const Standard_Real Umax, const Standard_Real Vmin, const Standard_Real Vmax)
 {
-  if ((Umin>Umax) || (Vmin>Vmax)) Standard_Failure::Raise("Bounds haven't the good sense");
-  if ((Umin==Umax) || (Vmin==Vmax)) Standard_Failure::Raise("Bounds are equal");
+  if ((Umin>Umax) || (Vmin>Vmax)) throw Standard_Failure("Bounds haven't the good sense");
+  if ((Umin==Umax) || (Vmin==Vmax)) throw Standard_Failure("Bounds are equal");
   myUmin=Umin;myUmax=Umax;myVmin=Vmin;myVmax=Vmax;
 }
 
index 2e1951e..8daeda8 100644 (file)
@@ -311,12 +311,13 @@ Handle(IGESData_IGESEntity) GeomToIGES_GeomCurve::TransferCurve
        mycurve = bspl;
       }
     }
-    catch ( Standard_Failure ) {
+    catch ( Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
       cout << "Warning: GeomToIGES_GeomCurve: can't trim bspline" << endl;
       cout << "Warning: Exception in Segment(): " ;
-      Standard_Failure::Caught()->Print(cout);
+      anException.Print(cout);
 #endif
+      (void)anException;
     }
   }
 
@@ -832,12 +833,13 @@ Handle(IGESData_IGESEntity) GeomToIGES_GeomCurve::TransferCurve
       res = TransferCurve(GeomConvert::CurveToBSplineCurve(start),U1,U2);
       return res;
     }
-    catch(Standard_Failure){
+    catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
       cout << "writing non-planar offset curve."<<endl;
       cout << "Warning: GeomConvert::CurveToBSplineCurve raised an exception: ";
-      Standard_Failure::Caught()->Print(cout);
+      anException.Print(cout);
 #endif
+      (void)anException;
     }
   }
 
index 34813ed..85cfc4b 100644 (file)
@@ -42,7 +42,7 @@ GeomToStep_MakeConicalSurface::GeomToStep_MakeConicalSurface
   aRadius = CS->RefRadius();
   aSemiAngle = CS->SemiAngle();
   if (aSemiAngle < 0. || aSemiAngle > M_PI/2.) {
-    Standard_DomainError::Raise("Conicalsurface not STEP conformant");
+    throw Standard_DomainError("Conicalsurface not STEP conformant");
   }
   
   Handle(TCollection_HAsciiString) name = new TCollection_HAsciiString("");
index d3db350..596f7c1 100644 (file)
@@ -825,12 +825,12 @@ Handle(Geom2d_Curve) GeomTools_Curve2dSet::ReadCurve2d(Standard_IStream& IS)
       break;
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
     cout <<"EXCEPTION in GeomTools_Curve2dSet::ReadCurve2d(..)!!!" << endl;
-    cout << anExc << endl;
+    cout << anException << endl;
 #endif
+    (void)anException;
   }
   return C;
 }
index 0f20d6a..903fd2b 100644 (file)
@@ -846,12 +846,12 @@ Handle(Geom_Curve) GeomTools_CurveSet::ReadCurve (Standard_IStream& IS)
       }
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
     cout <<"EXCEPTION in GeomTools_CurveSet::ReadCurve(..)!!!" << endl;
-    cout << anExc << endl;
+    cout << anException << endl;
 #endif
+    (void)anException;
   }
   return C;
 }
index 09e1d77..1b33ba8 100644 (file)
@@ -64,9 +64,9 @@ const char* GeomTools_Dump (void* theHandlePtr)
 
     return "Error: Not a geometric object";
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    return Standard_Failure::Caught()->GetMessageString();
+    return anException.GetMessageString();
   }
 }
 
index c09aafc..60dd9b3 100644 (file)
@@ -1037,12 +1037,12 @@ Handle(Geom_Surface) GeomTools_SurfaceSet::ReadSurface(Standard_IStream& IS)
       break;
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
-    Handle(Standard_Failure) anExc = Standard_Failure::Caught();
     cout <<"EXCEPTION in GeomTools_SurfaceSet::ReadSurface(..)!!!" << endl;
-    cout << anExc << endl;
+    cout << anException << endl;
 #endif
+    (void)anException;
   }
   return S;
 }
index 037c05f..f5cfe24 100644 (file)
@@ -263,7 +263,7 @@ Standard_Integer Graphic3d_ArrayOfPrimitives::AddBound (const Standard_Integer t
   Standard_Integer anIndex = myBounds->NbBounds;
   if (anIndex >= myMaxBounds)
   {
-    Standard_OutOfRange::Raise ("TOO many BOUNDS");
+    throw Standard_OutOfRange("TOO many BOUNDS");
   }
 
   myBounds->Bounds[anIndex] = theEdgeNumber;
@@ -289,7 +289,7 @@ Standard_Integer Graphic3d_ArrayOfPrimitives::AddBound (const Standard_Integer t
   Standard_Integer anIndex = myBounds->NbBounds;
   if (anIndex >= myMaxBounds)
   {
-    Standard_OutOfRange::Raise ("TOO many BOUND");
+    throw Standard_OutOfRange("TOO many BOUND");
   }
 
   myBounds->Bounds[anIndex] = theEdgeNumber;
@@ -308,14 +308,14 @@ Standard_Integer Graphic3d_ArrayOfPrimitives::AddEdge (const Standard_Integer th
   Standard_Integer anIndex = myIndices->NbElements;
   if (anIndex >= myMaxEdges)
   {
-    Standard_OutOfRange::Raise ("TOO many EDGE");
+    throw Standard_OutOfRange("TOO many EDGE");
   }
 
   Standard_Integer aVertIndex = theVertexIndex - 1;
   if (theVertexIndex <= 0
    || aVertIndex >= myMaxVertexs)
   {
-    Standard_OutOfRange::Raise ("BAD EDGE vertex index");
+    throw Standard_OutOfRange("BAD EDGE vertex index");
   }
 
   myIndices->SetIndex (anIndex, aVertIndex);
@@ -349,7 +349,7 @@ void Graphic3d_ArrayOfPrimitives::SetVertexColor (const Standard_Integer theInde
   if (theIndex < 1
    || theIndex > myMaxVertexs)
   {
-    Standard_OutOfRange::Raise ("BAD VERTEX index");
+    throw Standard_OutOfRange("BAD VERTEX index");
   }
 
   if (myVCol != 0)
index 4661b9b..6d6d1eb 100644 (file)
@@ -144,7 +144,7 @@ inline void Graphic3d_ArrayOfPrimitives::SetVertice (const Standard_Integer   th
   if (theIndex < 1
    || theIndex > myMaxVertexs)
   {
-    Standard_OutOfRange::Raise ("BAD VERTEX index");
+    throw Standard_OutOfRange("BAD VERTEX index");
   }
 
   Graphic3d_Vec3& aVec = myAttribs->ChangeValue<Graphic3d_Vec3> (theIndex - 1);
@@ -168,7 +168,7 @@ inline void Graphic3d_ArrayOfPrimitives::SetVertexColor (const Standard_Integer
   if (theIndex < 1
    || theIndex > myMaxVertexs)
   {
-    Standard_OutOfRange::Raise ("BAD VERTEX index");
+    throw Standard_OutOfRange("BAD VERTEX index");
   }
 
   if (myVCol != 0)
@@ -200,7 +200,7 @@ inline void Graphic3d_ArrayOfPrimitives::SetVertexNormal (const Standard_Integer
   if (theIndex < 1
    || theIndex > myMaxVertexs)
   {
-    Standard_OutOfRange::Raise ("BAD VERTEX index");
+    throw Standard_OutOfRange("BAD VERTEX index");
   }
 
   if (myVNor != 0)
@@ -225,7 +225,7 @@ inline void Graphic3d_ArrayOfPrimitives::SetVertexTexel (const Standard_Integer
   if (theIndex < 1
    || theIndex > myMaxVertexs)
   {
-    Standard_OutOfRange::Raise ("BAD VERTEX index");
+    throw Standard_OutOfRange("BAD VERTEX index");
   }
 
   if (myVTex != 0)
@@ -250,7 +250,7 @@ inline void Graphic3d_ArrayOfPrimitives::SetBoundColor (const Standard_Integer t
   if (theIndex < 1
    || theIndex > myMaxBounds)
   {
-    Standard_OutOfRange::Raise ("BAD BOUND index");
+    throw Standard_OutOfRange("BAD BOUND index");
   }
 
   Graphic3d_Vec4& aVec = myBounds->Colors[theIndex - 1];
@@ -275,7 +275,7 @@ inline void Graphic3d_ArrayOfPrimitives::Vertice (const Standard_Integer theInde
   if (theIndex < 1
    || theIndex > myAttribs->NbElements)
   {
-    Standard_OutOfRange::Raise ("BAD VERTEX index");
+    throw Standard_OutOfRange("BAD VERTEX index");
   }
 
   const Graphic3d_Vec3& aVec = myAttribs->Value<Graphic3d_Vec3> (theIndex - 1);
@@ -298,7 +298,7 @@ inline void Graphic3d_ArrayOfPrimitives::VertexColor (const Standard_Integer the
   if (theIndex < 1
    || theIndex > myAttribs->NbElements)
   {
-    Standard_OutOfRange::Raise ("BAD VERTEX index");
+    throw Standard_OutOfRange("BAD VERTEX index");
   }
   Standard_Integer aColorInt = 0;
   VertexColor (theIndex, aColorInt);
@@ -331,7 +331,7 @@ inline void Graphic3d_ArrayOfPrimitives::VertexNormal (const Standard_Integer th
   if (theIndex < 1
    || theIndex > myAttribs->NbElements)
   {
-    Standard_OutOfRange::Raise ("BAD VERTEX index");
+    throw Standard_OutOfRange("BAD VERTEX index");
   }
 
   if (myVNor != 0)
@@ -356,7 +356,7 @@ inline void Graphic3d_ArrayOfPrimitives::VertexTexel (const Standard_Integer the
   if (theIndex < 1
    || theIndex > myAttribs->NbElements)
   {
-    Standard_OutOfRange::Raise ("BAD VERTEX index");
+    throw Standard_OutOfRange("BAD VERTEX index");
   }
 
   if (myVTex != 0)
@@ -378,7 +378,7 @@ inline Standard_Integer Graphic3d_ArrayOfPrimitives::Edge (const Standard_Intege
    || theIndex <= 0
    || theIndex > myIndices->NbElements)
   {
-    Standard_OutOfRange::Raise ("BAD EDGE index");
+    throw Standard_OutOfRange("BAD EDGE index");
   }
   return Standard_Integer(myIndices->Index (theIndex - 1) + 1);
 }
@@ -399,7 +399,7 @@ inline Standard_Integer Graphic3d_ArrayOfPrimitives::Bound (const Standard_Integ
    || theIndex <= 0
    || theIndex > myBounds->NbBounds)
   {
-    Standard_OutOfRange::Raise ("BAD BOUND index");
+    throw Standard_OutOfRange("BAD BOUND index");
   }
   return myBounds->Bounds[theIndex - 1];
 }
@@ -414,7 +414,7 @@ inline void Graphic3d_ArrayOfPrimitives::BoundColor (const Standard_Integer theI
    || theIndex <= 0
    || theIndex > myBounds->NbBounds)
   {
-    Standard_OutOfRange::Raise(" BAD BOUND index");
+    throw Standard_OutOfRange(" BAD BOUND index");
   }
 
   const Graphic3d_Vec4& aVec = myBounds->Colors[theIndex - 1];
index a8273d9..d8c395c 100644 (file)
@@ -64,6 +64,6 @@ Graphic3d_AspectFillArea3d::Graphic3d_AspectFillArea3d (const Aspect_InteriorSty
 {
   if (theEdgeLineWidth <= 0.0)
   {
-    Aspect_AspectFillAreaDefinitionError::Raise ("Bad value for EdgeLineWidth");
+    throw Aspect_AspectFillAreaDefinitionError("Bad value for EdgeLineWidth");
   }
 }
index 01a5f1a..c365576 100644 (file)
@@ -245,7 +245,7 @@ public:
   {
     if (theWidth <= 0.0)
     {
-      Aspect_AspectFillAreaDefinitionError::Raise ("Bad value for EdgeLineWidth");
+      throw Aspect_AspectFillAreaDefinitionError("Bad value for EdgeLineWidth");
     }
     myEdgeWidth = (float )theWidth;
   }
index 38655d4..c482b83 100644 (file)
@@ -42,6 +42,6 @@ Graphic3d_AspectLine3d::Graphic3d_AspectLine3d (const Quantity_Color&   theColor
 {
   if (myWidth <= 0.0f)
   {
-    Aspect_AspectLineDefinitionError::Raise ("Graphic3d_AspectLine3d, Bad value for LineWidth");
+    throw Aspect_AspectLineDefinitionError("Graphic3d_AspectLine3d, Bad value for LineWidth");
   }
 }
index dfe513d..f21dfb9 100644 (file)
@@ -76,7 +76,7 @@ public:
   {
     if (theWidth <= 0.0f)
     {
-      Aspect_AspectLineDefinitionError::Raise ("Graphic3d_AspectLine3d, Bad value for LineWidth");
+      throw Aspect_AspectLineDefinitionError("Graphic3d_AspectLine3d, Bad value for LineWidth");
     }
     myWidth = theWidth;
   }
index 141f9b4..f9251e5 100644 (file)
@@ -42,7 +42,7 @@ Graphic3d_AspectMarker3d::Graphic3d_AspectMarker3d (const Aspect_TypeOfMarker th
 {
   if (theScale <= 0.0)
   {
-    Aspect_AspectMarkerDefinitionError::Raise ("Bad value for MarkerScale");
+    throw Aspect_AspectMarkerDefinitionError("Bad value for MarkerScale");
   }
 }
 
index 410f7d8..2d3f086 100644 (file)
@@ -73,7 +73,7 @@ public:
   {
     if (theScale <= 0.0f)
     {
-      Aspect_AspectMarkerDefinitionError::Raise ("Bad value for MarkerScale");
+      throw Aspect_AspectMarkerDefinitionError("Bad value for MarkerScale");
     }
     myScale = theScale;
   }
index 0cfe9a5..941084b 100644 (file)
@@ -64,6 +64,6 @@ Graphic3d_AspectText3d::Graphic3d_AspectText3d (const Quantity_Color&  theColor,
 
   if (theExpansionFactor <= 0.0)
   {
-    Graphic3d_AspectTextDefinitionError::Raise ("Bad value for TextScaleFactor");
+    throw Graphic3d_AspectTextDefinitionError("Bad value for TextScaleFactor");
   }
 }
index 2d480c5..e2f243b 100644 (file)
@@ -84,7 +84,7 @@ public:
   {
     if (theFactor <= 0.0)
     {
-      Graphic3d_AspectTextDefinitionError::Raise ("Bad value for TextScaleFactor");
+      throw Graphic3d_AspectTextDefinitionError("Bad value for TextScaleFactor");
     }
     myFactor = theFactor;
   }
index ef18c6d..6b6567a 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Graphic3d_AspectTextDefinitionError, Standard_OutOfRange)
 
 #if !defined No_Exception && !defined No_Graphic3d_AspectTextDefinitionError
   #define Graphic3d_AspectTextDefinitionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Graphic3d_AspectTextDefinitionError::Raise(MESSAGE);
+  if (CONDITION) throw Graphic3d_AspectTextDefinitionError(MESSAGE);
 #else
   #define Graphic3d_AspectTextDefinitionError_Raise_if(CONDITION, MESSAGE)
 #endif
index c874094..c4d98a7 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Graphic3d_GroupDefinitionError, Standard_OutOfRange)
 
 #if !defined No_Exception && !defined No_Graphic3d_GroupDefinitionError
   #define Graphic3d_GroupDefinitionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Graphic3d_GroupDefinitionError::Raise(MESSAGE);
+  if (CONDITION) throw Graphic3d_GroupDefinitionError(MESSAGE);
 #else
   #define Graphic3d_GroupDefinitionError_Raise_if(CONDITION, MESSAGE)
 #endif
index bff137b..2c4edbe 100644 (file)
@@ -559,7 +559,7 @@ void Graphic3d_MaterialAspect::SetAmbient (const Standard_ShortReal theValue)
   if (theValue < 0.0f
    || theValue > 1.0f)
   {
-    Graphic3d_MaterialDefinitionError::Raise ("Bad value for SetAmbient < 0. or > 1.0");
+    throw Graphic3d_MaterialDefinitionError("Bad value for SetAmbient < 0. or > 1.0");
   }
 
   myColorCoef[Graphic3d_TOR_AMBIENT] = theValue;
@@ -653,7 +653,7 @@ void Graphic3d_MaterialAspect::SetDiffuse (const Standard_ShortReal theValue)
   if (theValue < 0.0f
    || theValue > 1.0f)
   {
-    Graphic3d_MaterialDefinitionError::Raise ("Bad value for SetDiffuse < 0. or > 1.0");
+    throw Graphic3d_MaterialDefinitionError("Bad value for SetDiffuse < 0. or > 1.0");
   }
 
   myColorCoef[Graphic3d_TOR_DIFFUSE] = theValue;
@@ -673,7 +673,7 @@ void Graphic3d_MaterialAspect::SetEmissive (const Standard_ShortReal theValue)
   if (theValue < 0.0f
    || theValue > 1.0f)
   {
-    Graphic3d_MaterialDefinitionError::Raise ("Bad value for SetEmissive < 0. or > 1.0");
+    throw Graphic3d_MaterialDefinitionError("Bad value for SetEmissive < 0. or > 1.0");
   }
 
   myColorCoef[Graphic3d_TOR_EMISSION] = theValue;
@@ -707,7 +707,7 @@ void Graphic3d_MaterialAspect::SetSpecular (const Standard_ShortReal theValue)
   if (theValue < 0.0f
    || theValue > 1.0f)
   {
-    Graphic3d_MaterialDefinitionError::Raise ("Bad value for SetSpecular < 0. or > 1.0");
+    throw Graphic3d_MaterialDefinitionError("Bad value for SetSpecular < 0. or > 1.0");
   }
 
   myColorCoef[Graphic3d_TOR_SPECULAR] = theValue;
@@ -727,7 +727,7 @@ void Graphic3d_MaterialAspect::SetTransparency (const Standard_ShortReal theValu
   if (theValue < 0.0f
    || theValue > 1.0f)
   {
-    Graphic3d_MaterialDefinitionError::Raise ("Bad value for SetTransparency < 0. or > 1.0");
+    throw Graphic3d_MaterialDefinitionError("Bad value for SetTransparency < 0. or > 1.0");
   }
 
   myTransparencyCoef = theValue;
@@ -741,7 +741,7 @@ void Graphic3d_MaterialAspect::SetRefractionIndex (const Standard_ShortReal theV
 {
   if (theValue < 1.0f)
   {
-    Graphic3d_MaterialDefinitionError::Raise ("Bad value for refraction index < 1.0");
+    throw Graphic3d_MaterialDefinitionError("Bad value for refraction index < 1.0");
   }
 
   myRefractionIndex = theValue;
@@ -756,7 +756,7 @@ void Graphic3d_MaterialAspect::SetShininess (const Standard_ShortReal theValue)
   if (theValue < 0.0f
    || theValue > 1.0f)
   {
-    Graphic3d_MaterialDefinitionError::Raise ("Bad value for Shininess < 0. or > 1.0");
+    throw Graphic3d_MaterialDefinitionError("Bad value for Shininess < 0. or > 1.0");
   }
 
   myShininess = theValue;
@@ -771,7 +771,7 @@ Standard_CString Graphic3d_MaterialAspect::MaterialName (const Standard_Integer
 {
   if (theRank < 1 || theRank > NumberOfMaterials())
   {
-    Standard_OutOfRange::Raise ("BAD index of material");
+    throw Standard_OutOfRange("BAD index of material");
   }
   const RawMaterial& aMat = THE_MATERIALS[theRank - 1];
   return aMat.StringName;
@@ -832,7 +832,7 @@ Graphic3d_TypeOfMaterial Graphic3d_MaterialAspect::MaterialType (const Standard_
 {
   if (theRank < 1 || theRank > NumberOfMaterials())
   {
-    Standard_OutOfRange::Raise ("BAD index of material");
+    throw Standard_OutOfRange("BAD index of material");
   }
   const RawMaterial& aMat = THE_MATERIALS[theRank - 1];
   return aMat.MaterialType;
index b65e699..d4d9be3 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Graphic3d_MaterialDefinitionError, Standard_OutOfRange)
 
 #if !defined No_Exception && !defined No_Graphic3d_MaterialDefinitionError
   #define Graphic3d_MaterialDefinitionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Graphic3d_MaterialDefinitionError::Raise(MESSAGE);
+  if (CONDITION) throw Graphic3d_MaterialDefinitionError(MESSAGE);
 #else
   #define Graphic3d_MaterialDefinitionError_Raise_if(CONDITION, MESSAGE)
 #endif
index 6581e7e..601674d 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Graphic3d_PriorityDefinitionError, Standard_OutOfRange)
 
 #if !defined No_Exception && !defined No_Graphic3d_PriorityDefinitionError
   #define Graphic3d_PriorityDefinitionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Graphic3d_PriorityDefinitionError::Raise(MESSAGE);
+  if (CONDITION) throw Graphic3d_PriorityDefinitionError(MESSAGE);
 #else
   #define Graphic3d_PriorityDefinitionError_Raise_if(CONDITION, MESSAGE)
 #endif
index ea8c479..119d642 100755 (executable)
@@ -66,8 +66,7 @@ const TCollection_AsciiString& Graphic3d_ShaderProgram::ShadersFolder()
      || !aProgramFile.Exists())
     {
       std::cerr << "Standard GLSL programs are not found in: " << THE_SHADERS_FOLDER.ToCString() << std::endl;
-      Standard_Failure::Raise ("CSF_ShadersDirectory or CASROOT is set incorrectly");
-      return THE_SHADERS_FOLDER;
+      throw Standard_Failure("CSF_ShadersDirectory or CASROOT is set incorrectly");
     }
   }
   return THE_SHADERS_FOLDER;
index ffeb952..5e38b8f 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Graphic3d_StructureDefinitionError, Standard_OutOfRange)
 
 #if !defined No_Exception && !defined No_Graphic3d_StructureDefinitionError
   #define Graphic3d_StructureDefinitionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Graphic3d_StructureDefinitionError::Raise(MESSAGE);
+  if (CONDITION) throw Graphic3d_StructureDefinitionError(MESSAGE);
 #else
   #define Graphic3d_StructureDefinitionError_Raise_if(CONDITION, MESSAGE)
 #endif
index 66b20c9..7854882 100644 (file)
@@ -89,7 +89,7 @@ TCollection_AsciiString Graphic3d_Texture1D::TextureName (const Standard_Integer
 {
   if (theRank < 1 || theRank > NumberOfTextures())
   {
-    Standard_OutOfRange::Raise ("BAD index of texture");
+    throw Standard_OutOfRange("BAD index of texture");
   }
 
   TCollection_AsciiString aFileName (NameOfTexture_to_FileName[theRank - 1]);
index ca8ac55..362f547 100644 (file)
@@ -108,7 +108,7 @@ TCollection_AsciiString Graphic3d_Texture2D::TextureName (const Standard_Integer
 {
   if (theRank < 1 || theRank > NumberOfTextures())
   {
-    Standard_OutOfRange::Raise ("BAD index of texture");
+    throw Standard_OutOfRange("BAD index of texture");
   }
 
   TCollection_AsciiString aFileName (NameOfTexture_to_FileName[theRank - 1]);
index bbda332..4ee1377 100644 (file)
@@ -109,7 +109,7 @@ TCollection_AsciiString Graphic3d_TextureEnv::TextureName (const Standard_Intege
 {
   if(theRank < 1 || theRank > NumberOfTextures())
   {
-       Standard_OutOfRange::Raise ("BAD index of texture");
+       throw Standard_OutOfRange("BAD index of texture");
   }
 
   TCollection_AsciiString aFileName (NameOfTexture_to_FileName[theRank - 1]);
index 6e2dde7..5ea41b2 100644 (file)
@@ -61,8 +61,7 @@ TCollection_AsciiString Graphic3d_TextureRoot::TexturesFolder()
       std::cerr << "Both environment variables CSF_MDTVTexturesDirectory and CASROOT are undefined!\n"
                 << "At least one should be defined to use standard Textures.\n";
 #endif
-      Standard_Failure::Raise ("CSF_MDTVTexturesDirectory and CASROOT are undefined");
-      return VarName;
+      throw Standard_Failure("CSF_MDTVTexturesDirectory and CASROOT are undefined");
     }
 
     const OSD_Path aDirPath (VarName);
@@ -75,8 +74,7 @@ TCollection_AsciiString Graphic3d_TextureRoot::TexturesFolder()
       std::cerr << " CSF_MDTVTexturesDirectory or CASROOT not correctly setted\n";
       std::cerr << " not all files are found in : "<< VarName.ToCString() << std::endl;
 #endif
-      Standard_Failure::Raise ("CSF_MDTVTexturesDirectory or CASROOT not correctly setted");
-      return VarName;
+      throw Standard_Failure("CSF_MDTVTexturesDirectory or CASROOT not correctly setted");
     }
   }
   return VarName;
index 7a6233c..cb32af6 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Graphic3d_TransformError, Standard_OutOfRange)
 
 #if !defined No_Exception && !defined No_Graphic3d_TransformError
   #define Graphic3d_TransformError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Graphic3d_TransformError::Raise(MESSAGE);
+  if (CONDITION) throw Graphic3d_TransformError(MESSAGE);
 #else
   #define Graphic3d_TransformError_Raise_if(CONDITION, MESSAGE)
 #endif
index 4f3ba60..fa7f7a5 100644 (file)
@@ -68,7 +68,7 @@ public:
     }
     else
     {
-      Standard_ProgramError::Raise ("Graphic3d_TransformPers::SetPersistence(), wrong persistence mode.");
+      throw Standard_ProgramError("Graphic3d_TransformPers::SetPersistence(), wrong persistence mode.");
     }
   }
 
@@ -111,7 +111,7 @@ public:
   {
     if (!IsZoomOrRotate (theMode))
     {
-      Standard_ProgramError::Raise ("Graphic3d_TransformPers::SetPersistence(), wrong persistence mode.");
+      throw Standard_ProgramError("Graphic3d_TransformPers::SetPersistence(), wrong persistence mode.");
     }
 
     myMode = theMode;
@@ -128,7 +128,7 @@ public:
   {
     if (!IsTrihedronOr2d (theMode))
     {
-      Standard_ProgramError::Raise ("Graphic3d_TransformPers::SetPersistence(), wrong persistence mode.");
+      throw Standard_ProgramError("Graphic3d_TransformPers::SetPersistence(), wrong persistence mode.");
     }
 
     myMode = theMode;
@@ -144,7 +144,7 @@ public:
   {
     if (!IsZoomOrRotate())
     {
-      Standard_ProgramError::Raise ("Graphic3d_TransformPers::AnchorPoint(), wrong persistence mode.");
+      throw Standard_ProgramError("Graphic3d_TransformPers::AnchorPoint(), wrong persistence mode.");
     }
 
     return gp_Pnt (myParams.Params3d.PntX, myParams.Params3d.PntY, myParams.Params3d.PntZ);
@@ -155,7 +155,7 @@ public:
   {
     if (!IsZoomOrRotate())
     {
-      Standard_ProgramError::Raise ("Graphic3d_TransformPers::SetAnchorPoint(), wrong persistence mode.");
+      throw Standard_ProgramError("Graphic3d_TransformPers::SetAnchorPoint(), wrong persistence mode.");
     }
 
     myParams.Params3d.PntX = thePnt.X();
@@ -168,7 +168,7 @@ public:
   {
     if (!IsTrihedronOr2d())
     {
-      Standard_ProgramError::Raise ("Graphic3d_TransformPers::Corner2d(), wrong persistence mode.");
+      throw Standard_ProgramError("Graphic3d_TransformPers::Corner2d(), wrong persistence mode.");
     }
 
     return myParams.Params2d.Corner;
@@ -179,7 +179,7 @@ public:
   {
     if (!IsTrihedronOr2d())
     {
-      Standard_ProgramError::Raise ("Graphic3d_TransformPers::SetCorner2d(), wrong persistence mode.");
+      throw Standard_ProgramError("Graphic3d_TransformPers::SetCorner2d(), wrong persistence mode.");
     }
 
     myParams.Params2d.Corner = thePos;
@@ -190,7 +190,7 @@ public:
   {
     if (!IsTrihedronOr2d())
     {
-      Standard_ProgramError::Raise ("Graphic3d_TransformPers::Offset2d(), wrong persistence mode.");
+      throw Standard_ProgramError("Graphic3d_TransformPers::Offset2d(), wrong persistence mode.");
     }
 
     return Graphic3d_Vec2i (myParams.Params2d.OffsetX, myParams.Params2d.OffsetY);
@@ -201,7 +201,7 @@ public:
   {
     if (!IsTrihedronOr2d())
     {
-      Standard_ProgramError::Raise ("Graphic3d_TransformPers::SetOffset2d(), wrong persistence mode.");
+      throw Standard_ProgramError("Graphic3d_TransformPers::SetOffset2d(), wrong persistence mode.");
     }
 
     myParams.Params2d.OffsetX = theOffset.x();
index 3d76c33..bbbee63 100644 (file)
@@ -99,7 +99,7 @@ Standard_Real Graphic3d_Vector::Z () const {
 void Graphic3d_Vector::Normalize () {
 
        if (Abs (MyNorme) <= RealEpsilon ())
-               Graphic3d_VectorError::Raise ("The norm is null");
+               throw Graphic3d_VectorError("The norm is null");
 
        if (!IsNormalized()) // CQO CTS40181
            {   
index 6319951..8765904 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Graphic3d_VectorError, Standard_OutOfRange)
 
 #if !defined No_Exception && !defined No_Graphic3d_VectorError
   #define Graphic3d_VectorError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Graphic3d_VectorError::Raise(MESSAGE);
+  if (CONDITION) throw Graphic3d_VectorError(MESSAGE);
 #else
   #define Graphic3d_VectorError_Raise_if(CONDITION, MESSAGE)
 #endif
index 6071d76..47e9a53 100644 (file)
@@ -1312,7 +1312,7 @@ void HLRBRep_Data::LocalLEGeometry2D (const Standard_Real Param,
 {
   myLLProps.SetParameter(Param);
   if (!myLLProps.IsTangentDefined())
-    Standard_Failure::Raise("HLRBRep_Data::LocalGeometry2D");
+    throw Standard_Failure("HLRBRep_Data::LocalGeometry2D");
   myLLProps.Tangent(Tg);
   Cu = myLLProps.Curvature();
   if (Cu > Epsilon(1.) && !Precision::IsInfinite(Cu)) myLLProps.Normal(Nm);
@@ -1334,7 +1334,7 @@ void HLRBRep_Data::LocalFEGeometry2D (const Standard_Integer FE,
   myFLProps.SetCurve(aCurve);
   myFLProps.SetParameter(Param);
   if (!myFLProps.IsTangentDefined())
-    Standard_Failure::Raise("HLRBRep_Data::LocalGeometry2D");
+    throw Standard_Failure("HLRBRep_Data::LocalGeometry2D");
   myFLProps.Tangent(Tg);
   Cu = myFLProps.Curvature();
   if (Cu > Epsilon(1.) && !Precision::IsInfinite(Cu)) myFLProps.Normal(Nm);
index cc7d79a..b6be409 100644 (file)
@@ -385,7 +385,7 @@ void  HLRBRep_EdgeBuilder::NextVertex()
       current = 3;
   }
   else
-    Standard_NoSuchObject::Raise("EdgeBuilder::NextVertex : No current edge");
+    throw Standard_NoSuchObject("EdgeBuilder::NextVertex : No current edge");
 }
 
 //=======================================================================
@@ -400,8 +400,7 @@ const HLRAlgo_Intersection& HLRBRep_EdgeBuilder::Current() const
   else if (current == 2)
     return right->Vertex();
   else
-    Standard_NoSuchObject::Raise("EdgeBuilder::Current : No current vertex");
-  return left->Vertex(); // only for WNT.
+    throw Standard_NoSuchObject("EdgeBuilder::Current : No current vertex");
 }
 
 //=======================================================================
@@ -416,9 +415,7 @@ Standard_Boolean  HLRBRep_EdgeBuilder::IsBoundary() const
   else if (current == 2)
     return right->IsBoundary();
   else
-    Standard_NoSuchObject::Raise
-      ("EdgeBuilder::IsBoundary : No current vertex");
-  return left->IsBoundary(); // only for WNT.
+    throw Standard_NoSuchObject("EdgeBuilder::IsBoundary : No current vertex");
 }
 
 //=======================================================================
@@ -433,9 +430,7 @@ Standard_Boolean  HLRBRep_EdgeBuilder::IsInterference() const
   else if (current == 2)
     return right->IsInterference();
   else
-    Standard_NoSuchObject::Raise
-      ("EdgeBuilder::IsInterference : No current vertex");
-  return left->IsInterference(); // only for WNT.
+    throw Standard_NoSuchObject("EdgeBuilder::IsInterference : No current vertex");
 }
 
 //=======================================================================
index 6162996..3054ec1 100644 (file)
@@ -696,13 +696,13 @@ void HLRBRep_Hider::Hide(const Standard_Integer FI,
 
     }
 
-    catch(Standard_Failure) {
+    catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
       cout << "An exception was catched when hiding edge " << E;
       cout << " by the face " << FI << endl;
-      Handle(Standard_Failure) fail = Standard_Failure::Caught();
-      cout << fail << endl;
+      cout << anException << endl;
 #endif
+      (void)anException;
     }
   }
 }
index 8b5a5b7..c769e38 100644 (file)
@@ -111,13 +111,12 @@ void HLRBRep_InternalAlgo::Update ()
        de = DS[i-1]->NbEdges   ();
        df = DS[i-1]->NbFaces   ();
       }
-      catch(Standard_Failure) {
+      catch(Standard_Failure const& anException) {
         if (myDebug)
         {
           cout << "An exception was catched when preparing the Shape " << i;
           cout << " and computing its OutLines " << endl;
-          Handle(Standard_Failure) fail = Standard_Failure::Caught();
-          cout << fail << endl;
+          cout << anException << endl;
         }
        DS[i-1] = new HLRBRep_Data(0,0,0);
        dv = 0;
index 974b6d3..b970594 100644 (file)
@@ -100,8 +100,7 @@ const HLRAlgo_Intersection &  HLRBRep_VertexList::Current() const
   else if (fromInterf)
     return myIterator.Value().Intersection();
   else
-    Standard_NoSuchObject::Raise("HLRBRep_VertexList::Current");
-  return myTool.CurrentVertex(); // only for WNT.
+    throw Standard_NoSuchObject("HLRBRep_VertexList::Current");
 }
 
 //=======================================================================
@@ -134,8 +133,7 @@ TopAbs_Orientation  HLRBRep_VertexList::Orientation() const
   if (fromEdge)
     return myTool.CurrentOrientation();
   else
-    Standard_DomainError::Raise("HLRBRep_VertexList::Orientation");
-  return TopAbs_EXTERNAL; // only for WNT.
+    throw Standard_DomainError("HLRBRep_VertexList::Orientation");
 }
 
 //=======================================================================
@@ -148,8 +146,7 @@ TopAbs_Orientation  HLRBRep_VertexList::Transition() const
   if (fromInterf)
     return myIterator.Value().Transition();
   else
-    Standard_DomainError::Raise("HLRBRep_VertexList::Transition");
-  return TopAbs_EXTERNAL; // only for WNT.
+    throw Standard_DomainError("HLRBRep_VertexList::Transition");
 }
 
 //=======================================================================
@@ -162,6 +159,5 @@ TopAbs_Orientation  HLRBRep_VertexList::BoundaryTransition() const
   if (fromInterf)
     return myIterator.Value().BoundaryTransition();
   else
-    Standard_DomainError::Raise("HLRBRep_VertexList::BoundaryTransition");
-  return TopAbs_EXTERNAL; // only for WNT.
+    throw Standard_DomainError("HLRBRep_VertexList::BoundaryTransition");
 }
index 30e5f01..d07d2d8 100644 (file)
@@ -419,7 +419,7 @@ void  HLRTopoBRep_DSFiller::InsertFace (const Standard_Integer /*FI*/,
              
               case Contap_Restriction :
               {
-                Standard_ProgramError::Raise("HLRTopoBRep_DSFiller::InsertFace : Restriction");
+                throw Standard_ProgramError("HLRTopoBRep_DSFiller::InsertFace : Restriction");
               }
               break;
             }
index c9749b3..67d1d09 100644 (file)
@@ -227,8 +227,7 @@ Standard_Real Hatch_Hatcher::Coordinate(const Standard_Integer I) const
     return myLines(I).myLin.Location().Y();
 
   case Hatch_ANYLINE :
-    Standard_OutOfRange::Raise("Hatcher : not an X or Y line");
-    return 0.;
+    throw Standard_OutOfRange("Hatcher : not an X or Y line");
   }
 
   return 0.;
@@ -260,7 +259,7 @@ Standard_Real Hatch_Hatcher::Start(const Standard_Integer I,
                                   const Standard_Integer J) const
 {
   if (myLines(I).myInters.IsEmpty()) {
-    if (J != 1 || !myOrient) Standard_OutOfRange::Raise();
+    if (J != 1 || !myOrient) throw Standard_OutOfRange();
     return RealFirst();
   }
   else {
@@ -283,7 +282,7 @@ void Hatch_Hatcher::StartIndex
    Standard_Real& Par2) const
 {
   if (myLines(I).myInters.IsEmpty()) {
-    if (J != 1) Standard_OutOfRange::Raise();
+    if (J != 1) throw Standard_OutOfRange();
     Index = 0;
     Par2  = 0;
   }
@@ -310,7 +309,7 @@ Standard_Real Hatch_Hatcher::End(const Standard_Integer I,
                                 const Standard_Integer J) const
 {
   if (myLines(I).myInters.IsEmpty()) {
-    if (J != 1 || !myOrient) Standard_OutOfRange::Raise();
+    if (J != 1 || !myOrient) throw Standard_OutOfRange();
     return RealLast();
   }
   else {
@@ -333,7 +332,7 @@ void Hatch_Hatcher::EndIndex
    Standard_Real& Par2) const
 {
   if (myLines(I).myInters.IsEmpty()) {
-    if (J != 1) Standard_OutOfRange::Raise();
+    if (J != 1) throw Standard_OutOfRange();
     Index = 0;
     Par2  = 0;
   }
index 697d377..f589099 100644 (file)
@@ -228,7 +228,7 @@ static void PolyTest(const TColStd_Array1OfReal&         Herm,
     Standard_Real  Polemax=Polesinit(max).Y();
     if (((Polemax)>=((1/TolPoles)*Polemin))||((Polemin==0.0)&&(Polemax>=(1/TolPoles)))){
       if (Polesinit(0).Y()>=(1/TolPoles)*Polesinit(3).Y()||Polesinit(0).Y()<=TolPoles*Polesinit(3).Y())
-        Standard_DimensionError::Raise("Hermit Impossible Tolerance");       
+        throw Standard_DimensionError("Hermit Impossible Tolerance");
       if ((max==0)||(max==3))
       {
         for (i=0;i<=3;i++)
@@ -454,7 +454,7 @@ static void PolyTest(const TColStd_Array1OfReal&        Herm,
     if (((Polemax)>=((1/TolPoles)*Polemin))||((Polemin==0.0)&&(Polemax>=(1/TolPoles))))
     {
       if (Polesinit(0).Y()>=(1/TolPoles)*Polesinit(3).Y()||Polesinit(0).Y()<=TolPoles*Polesinit(3).Y())
-        Standard_DimensionError::Raise("Hermit Impossible Tolerance");       
+        throw Standard_DimensionError("Hermit Impossible Tolerance");
       if ((max==0)||(max==3))
       {
         for (i=0;i<=3;i++)
@@ -714,7 +714,7 @@ Handle(Geom2d_BSplineCurve) Hermit::Solution(const Handle(Geom_BSplineCurve)& BS
     InsertKnots(BS2,Utol1,Utol2);
   }
   if ((BS2->Knot(2)<TolKnots)||(BS2->Knot(BS2->NbKnots()-1)>(1-TolKnots))) //checking of the knots tolerance
-    Standard_DimensionError::Raise("Hermit Impossible Tolerance");
+    throw Standard_DimensionError("Hermit Impossible Tolerance");
   else{
     if ((Upos2==1.0)&&(Utol2==1.0)&&(Uint2==1.0))    //test on the final inserted knots
       InsertKnots(BS1,BS2->Knot(2),1.0);
@@ -804,7 +804,7 @@ Handle(Geom2d_BSplineCurve) Hermit::Solution(const Handle(Geom2d_BSplineCurve)&
     InsertKnots(BS2,Utol1,Utol2);
   }
   if ((BS2->Knot(2)<TolKnots)||(BS2->Knot(BS2->NbKnots()-1)>(1-TolKnots))) //checking of the knots tolerance
-    Standard_DimensionError::Raise("Hermit Impossible Tolerance");
+    throw Standard_DimensionError("Hermit Impossible Tolerance");
   else{
     if ((Upos2==1.0)&&(Utol2==1.0)&&(Uint2==1.0))    //test on the final inserted knots
       InsertKnots(BS1,BS2->Knot(2),1.0);
@@ -896,7 +896,7 @@ void Hermit::Solutionbis(const Handle(Geom_BSplineCurve)& BS,
     InsertKnots(BS2,Utol1,Utol2);
   }
   if ((BS2->Knot(2)<TolKnots)||(BS2->Knot(BS2->NbKnots()-1)>(1-TolKnots))) //checking of the knots tolerance
-    Standard_DimensionError::Raise("Hermit Impossible Tolerance");
+    throw Standard_DimensionError("Hermit Impossible Tolerance");
   else{
     if ((Upos2==1.0)&&(Utol2==1.0)&&(Uint2==1.0))    //test on the final inserted knots
       Knotmin=BS2->Knot(2);
index cf430b6..ad73079 100644 (file)
@@ -60,8 +60,7 @@ IFGraph_SubPartsIterator::IFGraph_SubPartsIterator
     void  IFGraph_SubPartsIterator::GetParts
   (IFGraph_SubPartsIterator& other)
 {
-  if (Model() != other.Model()) Interface_InterfaceError::Raise
-    ("SubPartsIterator : GetParts");
+  if (Model() != other.Model()) throw Interface_InterfaceError("SubPartsIterator : GetParts");
 //  On AJOUTE les Parts de other, sans perdre les siennes propres
 //  (meme principe que le constructeur ci-dessus)
   Standard_Integer nb = thegraph.Size();
@@ -102,8 +101,7 @@ IFGraph_SubPartsIterator::IFGraph_SubPartsIterator
 
     void  IFGraph_SubPartsIterator::SetPartNum (const Standard_Integer num)
 {
-  if (num <= 0 || num > theparts->Length()) Standard_OutOfRange::Raise
-    ("IFGraph_SubPartsIterator : SetPartNum");
+  if (num <= 0 || num > theparts->Length()) throw Standard_OutOfRange("IFGraph_SubPartsIterator : SetPartNum");
   thepart = num;
 }
 
@@ -220,26 +218,22 @@ IFGraph_SubPartsIterator::IFGraph_SubPartsIterator
 
     Standard_Boolean  IFGraph_SubPartsIterator::IsSingle () const
 {
-  if (thecurr < 1 || thecurr > theparts->Length()) Standard_NoSuchObject::Raise
-    ("IFGraph_SubPartsIterator : IsSingle");
+  if (thecurr < 1 || thecurr > theparts->Length()) throw Standard_NoSuchObject("IFGraph_SubPartsIterator : IsSingle");
   return (theparts->Value(thecurr) == 1);
 }
 
     Handle(Standard_Transient)  IFGraph_SubPartsIterator::FirstEntity
   () const 
 {
-  if (thecurr < 1 || thecurr > theparts->Length()) Standard_NoSuchObject::Raise
-    ("IFGraph_SubPartsIterator : FirstEntity");
+  if (thecurr < 1 || thecurr > theparts->Length()) throw Standard_NoSuchObject("IFGraph_SubPartsIterator : FirstEntity");
   Standard_Integer nument = thefirsts->Value(thecurr);
-  if (nument == 0) Standard_NoSuchObject::Raise
-    ("IFGraph_SubPartsIterator : FirstEntity (current part is empty)");
+  if (nument == 0) throw Standard_NoSuchObject("IFGraph_SubPartsIterator : FirstEntity (current part is empty)");
   return thegraph.Entity(nument);
 }
 
     Interface_EntityIterator  IFGraph_SubPartsIterator::Entities () const 
 {
-  if (thecurr < 1 || thecurr > theparts->Length()) Standard_NoSuchObject::Raise
-    ("IFGraph_SubPartsIterator : Entities");
+  if (thecurr < 1 || thecurr > theparts->Length()) throw Standard_NoSuchObject("IFGraph_SubPartsIterator : Entities");
   Interface_EntityIterator iter;
   Standard_Integer nb = thegraph.Size();
   Standard_Integer nument = thefirsts->Value(thecurr);
index 5d85edb..31fbfa7 100644 (file)
@@ -38,7 +38,7 @@ static TColStd_SequenceOfTransient theacts;
 #ifdef OCCT_DEBUG
   if (thedico.IsBound(command)) {
     cout << "****  XSTEP commands, name conflict on " << command << " first defined remains  ****" << endl;
-//    Standard_DomainError::Raise("IFSelect_Activator : Add");
+//    throw Standard_DomainError("IFSelect_Activator : Add");
   }
 #endif
 
index 508d43f..741a838 100644 (file)
@@ -317,7 +317,7 @@ void IFSelect_ContextModif::Next()
 
 Handle(Standard_Transient) IFSelect_ContextModif::ValueOriginal () const
 {
-  if (thecurr <= 0) Standard_NoSuchObject::Raise("IFSelect_ContextModif");
+  if (thecurr <= 0) throw Standard_NoSuchObject("IFSelect_ContextModif");
   return thegraf.Entity(thecurr);
 }
 
@@ -329,7 +329,7 @@ Handle(Standard_Transient) IFSelect_ContextModif::ValueOriginal () const
 
 Handle(Standard_Transient) IFSelect_ContextModif::ValueResult   () const
 {
-  if (thecurr <= 0) Standard_NoSuchObject::Raise("IFSelect_ContextModif");
+  if (thecurr <= 0) throw Standard_NoSuchObject("IFSelect_ContextModif");
   Handle(Standard_Transient) ent,newent;
   ent = thegraf.Entity(thecurr);
   if (themap.IsNull()) newent = ent;
index 8bd9f61..2269f53 100644 (file)
@@ -212,7 +212,7 @@ void IFSelect_ContextWrite::Next ()
 Handle(Standard_Transient) IFSelect_ContextWrite::Value() const
 {
   if (thecurr < 1 || thecurr > thenbent)
-    Standard_NoSuchObject::Raise("IFSelect_ContextWrite:Value");
+    throw Standard_NoSuchObject("IFSelect_ContextWrite:Value");
   Standard_Integer num = theapply->ItemNum (thecurr);
   return themodel->Value(num);
 }
index caab722..3fcdf60 100644 (file)
@@ -36,7 +36,7 @@ IFSelect_Editor::IFSelect_Editor (const Standard_Integer nbval)
 
     void  IFSelect_Editor::SetNbValues (const Standard_Integer nbval)
 {
-  if (nbval > thevalues.Upper()) Standard_OutOfRange::Raise("IFSelect_Editor:SetNbValues");
+  if (nbval > thevalues.Upper()) throw Standard_OutOfRange("IFSelect_Editor:SetNbValues");
   thenbval = nbval;
 }
 
index 84969ab..93b33da 100644 (file)
@@ -63,10 +63,8 @@ IFSelect_PacketList::IFSelect_PacketList
   (const Handle(Standard_Transient)& ent)
 {
   Standard_Integer num = themodel->Number(ent);
-  if (num == 0) Interface_InterfaceError::Raise
-    ("PacketList:Add, Entity not in Model");
-  if (thelast == 0) Interface_InterfaceError::Raise
-    ("PacketList:Add, no Packet yet added");
+  if (num == 0) throw Interface_InterfaceError("PacketList:Add, Entity not in Model");
+  if (thelast == 0) throw Interface_InterfaceError("PacketList:Add, no Packet yet added");
   if (theflags(num) != 0) return;
   theflags(num) = 1;
   thedupls(num) ++;
index cc3a042..a4c8c9f 100644 (file)
@@ -72,8 +72,7 @@ void  IFSelect_SelectAnyList::SetRange
 {
   Interface_EntityIterator input = InputResult(G);
   KeepInputEntity (input);    // selon type voulu
-  if (input.NbEntities() > 1) Interface_InterfaceError::Raise
-    ("SelectAnyList : more than ONE Entity in input");
+  if (input.NbEntities() > 1) throw Interface_InterfaceError("SelectAnyList : more than ONE Entity in input");
   if (input.NbEntities() == 0) return input;
 
   Handle(Standard_Transient) ent;
index aa1e6e2..75152a2 100644 (file)
@@ -221,10 +221,10 @@ IFSelect_ReturnStatus  IFSelect_WorkSession::ReadFile
     else if (stat < 0) status = IFSelect_RetError;
     else status = IFSelect_RetFail;
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     Handle(Message_Messenger) sout = Message::DefaultMessenger();
     sout<<"    ****    Interruption ReadFile par Exception :   ****\n";
-    sout << Standard_Failure::Caught()->GetMessageString();
+    sout << anException.GetMessageString();
     sout<<"\n    Abandon"<<endl;
     status = IFSelect_RetFail;
   }
@@ -479,8 +479,7 @@ Handle(Interface_HGraph) IFSelect_WorkSession::HGraph ()
 const Interface_Graph& IFSelect_WorkSession::Graph ()
 {
   ComputeGraph();
-  if (thegraph.IsNull()) Standard_DomainError::Raise
-    ("IFSelect WorkSession : Graph not available");
+  if (thegraph.IsNull()) throw Standard_DomainError("IFSelect WorkSession : Graph not available");
   return thegraph->Graph();
 }
 
@@ -1245,10 +1244,10 @@ Interface_EntityIterator IFSelect_WorkSession::EvalSelection
       OCC_CATCH_SIGNALS
       iter = EvalSelection(sel);    // appel normal (donc, code pas duplique)
     }
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
       Handle(Message_Messenger) sout = Message::DefaultMessenger();
       sout<<"    ****    Interruption EvalSelection par Exception :   ****\n";
-      sout<<Standard_Failure::Caught()->GetMessageString();
+      sout<<anException.GetMessageString();
       sout<<"\n    Abandon"<<endl;
     }
     errhand = theerrhand;
@@ -1288,10 +1287,10 @@ Handle(TColStd_HSequenceOfTransient) IFSelect_WorkSession::SelectionResult
       OCC_CATCH_SIGNALS
       res = SelectionResult(sel);    // appel normal (->code unique)
     }
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
       Handle(Message_Messenger) sout = Message::DefaultMessenger();
       sout<<"    ****    Interruption SelectionResult par Exception :   ****\n";
-      sout<<Standard_Failure::Caught()->GetMessageString();
+      sout<<anException.GetMessageString();
       sout<<"\n    Abandon"<<endl;
     }
     errhand = theerrhand;
@@ -2021,10 +2020,10 @@ void IFSelect_WorkSession::EvaluateFile ()
       OCC_CATCH_SIGNALS
       EvaluateFile();    // appel normal (donc, code pas duplique)
     }
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
       Handle(Message_Messenger) sout = Message::DefaultMessenger();
       sout<<"    ****    Interruption EvaluateFile par Exception :   ****\n";
-      sout<<Standard_Failure::Caught()->GetMessageString();
+      sout<<anException.GetMessageString();
       sout<<"\n    Abandon"<<endl;
       checks.CCheck(0)->AddFail ("Exception Raised -> Abandon");
     }
@@ -2125,10 +2124,10 @@ Standard_Boolean IFSelect_WorkSession::SendSplit ()
       OCC_CATCH_SIGNALS
       return SendSplit();   // appel normal (donc, code pas duplique)
     }
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
       Handle(Message_Messenger) sout = Message::DefaultMessenger();
       sout<<"    ****    Interruption SendSplit par Exception :   ****\n";
-      sout<<Standard_Failure::Caught()->GetMessageString();
+      sout<<anException.GetMessageString();
       sout<<"\n    Abandon"<<endl;
       checks.CCheck(0)->AddFail ("Exception Raised -> Abandon");
     }
@@ -2348,10 +2347,10 @@ IFSelect_ReturnStatus IFSelect_WorkSession::SendAll
       ComputeGraph(computegraph);
       checks = thecopier->SendAll(filename,thegraph->Graph(),thelibrary,theprotocol);
     }
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
       Handle(Message_Messenger) sout = Message::DefaultMessenger();
       sout<<"    ****    Interruption SendAll par Exception :   ****\n";
-      sout<<Standard_Failure::Caught()->GetMessageString();
+      sout<<anException.GetMessageString();
       sout<<"\n    Abandon"<<endl;
       errhand = theerrhand;
       checks.CCheck(0)->AddFail ("Exception Raised -> Abandon");
@@ -2398,10 +2397,10 @@ IFSelect_ReturnStatus IFSelect_WorkSession::SendSelected
       ComputeGraph(computegraph);
       return SendSelected (filename,sel);    // appel normal
     }
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
       Handle(Message_Messenger) sout = Message::DefaultMessenger();
       sout<<"    ****    Interruption SendSelected par Exception :   ****\n";
-      sout<<Standard_Failure::Caught()->GetMessageString();
+      sout<<anException.GetMessageString();
       sout<<"\n    Abandon"<<endl;
       checks.CCheck(0)->AddFail ("Exception Raised -> Abandon");
       errhand = theerrhand;
@@ -3333,10 +3332,10 @@ void IFSelect_WorkSession::DumpModel
       OCC_CATCH_SIGNALS
       C.Print(S,myModel, (level == 3));
     }
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
       Handle(Message_Messenger) sout = Message::DefaultMessenger();
       sout<<"    ****    Interruption DumpModel par Exception :   ****\n";
-      sout<<Standard_Failure::Caught()->GetMessageString();
+      sout<<anException.GetMessageString();
       sout<<"\n    Abandon"<<endl;
     }
 
@@ -3501,9 +3500,9 @@ void IFSelect_WorkSession::EvaluateSelection
       OCC_CATCH_SIGNALS
       EvaluateSelection(sel);    // appel normal (->code unique)
     }
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
       sout<<"    ****    Interruption EvaluateSelection par Exception    ****  Intitule\n";
-      sout<<Standard_Failure::Caught()->GetMessageString();
+      sout<<anException.GetMessageString();
       sout<<"\n    Abandon"<<endl;
     }
     errhand = theerrhand;
@@ -3539,9 +3538,9 @@ void IFSelect_WorkSession::EvaluateDispatch
       OCC_CATCH_SIGNALS
       EvaluateDispatch(disp,mode);    // appel normal (->code unique)
     }
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
       sout<<"    ****    Interruption EvaluateDispatch par Exception    ****  Intitule\n";
-      sout<<Standard_Failure::Caught()->GetMessageString();
+      sout<<anException.GetMessageString();
       sout<<"\n    Abandon"<<endl;
     }
     errhand = theerrhand;
@@ -3617,9 +3616,9 @@ void IFSelect_WorkSession::EvaluateComplete
       OCC_CATCH_SIGNALS
       EvaluateComplete(mode);    // appel normal (donc, code pas duplique)
     }
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
       sout<<"    ****    Interruption EvaluateComplete par Exception :   ****\n";
-      sout<<Standard_Failure::Caught()->GetMessageString();
+      sout<<anException.GetMessageString();
       sout<<"\n    Abandon"<<endl;
     }
     errhand = theerrhand;
@@ -3733,9 +3732,9 @@ void IFSelect_WorkSession::ListEntities
     if (mode == 0) sout<<endl;
     if (mode == 2) sout<<")"<<endl;
   }
-  catch (Standard_Failure) {
+  catch (Standard_Failure const& anException) {
     sout<<"    ****    Interruption ListEntities par Exception :   ****\n";
-    sout<<Standard_Failure::Caught()->GetMessageString();
+    sout<<anException.GetMessageString();
     sout<<"\n    Abandon"<<endl;
   }
 }
index d7a10d7..9dc304a 100644 (file)
@@ -54,16 +54,16 @@ IGESAppli_ElementResults::IGESAppli_ElementResults ()    {  }
       allnbResDataLocs->Lower()  != 1 || allnbResDataLocs->Upper()  != num ||
       allResDataLocs->Lower()    != 1 || allResDataLocs->Upper()    != num ||
       allResults->Lower()        != 1 || allResults->Upper()        != num )
-    Standard_DimensionMismatch::Raise("IGESAppli_ElementsResults : Init");
+    throw Standard_DimensionMismatch("IGESAppli_ElementsResults : Init");
   for (Standard_Integer i = 1; i <= num; i ++) {
     Standard_Integer nl  = nbLayers->Value(i);
     Standard_Integer nrl = allnbResDataLocs->Value(i);
     if (allResDataLocs->Value(i)->Lower() != 1 || 
        allResDataLocs->Value(i)->Upper() != nrl)
-      Standard_DimensionMismatch::Raise("IGESAppli_ElementsResults : DataLoc");
+      throw Standard_DimensionMismatch("IGESAppli_ElementsResults : DataLoc");
     if (allResults->Value(i)->Lower() != 1 ||
        allResults->Value(i)->Upper() != nl*nrl*nbResults)
-      Standard_DimensionMismatch::Raise("IGESAppli_ElementsResults : Results");
+      throw Standard_DimensionMismatch("IGESAppli_ElementsResults : Results");
   }
 
   theNote                 = aNote;
@@ -85,8 +85,7 @@ IGESAppli_ElementResults::IGESAppli_ElementResults ()    {  }
 
     void  IGESAppli_ElementResults::SetFormNumber (const Standard_Integer form)
 {
-  if (form < 0 || form > 34) Standard_OutOfRange::Raise
-    ("IGESAppli_ElementResults : SetFormNumber");
+  if (form < 0 || form > 34) throw Standard_OutOfRange("IGESAppli_ElementResults : SetFormNumber");
   InitTypeAndForm(148,form);
 }
 
index 9c943d7..0035a10 100644 (file)
@@ -35,7 +35,7 @@ IGESAppli_FiniteElement::IGESAppli_FiniteElement ()    {  }
    const Handle(TCollection_HAsciiString)& aName)
 {
   if (allNodes->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESAppli_FiniteElement : Init");
+    throw Standard_DimensionMismatch("IGESAppli_FiniteElement : Init");
   theTopology = aType;
   theNodes    = allNodes;
   theName     = aName;
index 27c747c..569acda 100644 (file)
@@ -30,7 +30,7 @@ IGESAppli_FlowLineSpec::IGESAppli_FlowLineSpec ()    {  }
   (const Handle(Interface_HArray1OfHAsciiString)& allProperties)
 {
   if (allProperties->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESAppli_FlowLineSpec : Init");
+    throw Standard_DimensionMismatch("IGESAppli_FlowLineSpec : Init");
   theNameAndModifiers = allProperties;
   InitTypeAndForm(406,14);
 }
index 8aa1e1c..78c5b48 100644 (file)
@@ -39,7 +39,7 @@ IGESAppli_LevelToPWBLayerMap::IGESAppli_LevelToPWBLayerMap ()    {  }
       (allNativeLevels->Lower() != 1 || allNativeLevels->Length() != num) ||
       (allPhysLevels->Lower()   != 1 || allPhysLevels->Length()   != num) ||
       (allExchIdents->Lower()   != 1 || allExchIdents->Length()   != num) )
-    Standard_DimensionMismatch::Raise("IGESAppli_LevelToPWBLayerMap: Init");
+    throw Standard_DimensionMismatch("IGESAppli_LevelToPWBLayerMap: Init");
   theNbPropertyValues        = nbPropVal;
   theExchangeFileLevelNumber = allExchLevels;
   theNativeLevel             = allNativeLevels;
index 7a97892..b436fe5 100644 (file)
@@ -34,7 +34,7 @@ IGESAppli_NodalConstraint::IGESAppli_NodalConstraint ()    {  }
    const Handle(IGESDefs_HArray1OfTabularData)& allTabData)
 {
   if (allTabData->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESAppli_NodalConstraint : Init");
+    throw Standard_DimensionMismatch("IGESAppli_NodalConstraint : Init");
   theType = aType;
   theNode = aNode;
   theTabularDataProps = allTabData;
index 046b396..b9b073d 100644 (file)
@@ -45,8 +45,7 @@ IGESAppli_NodalDisplAndRot::IGESAppli_NodalDisplAndRot ()    {  }
        allTransParams->Length()  != allNodes->Length()) ||
       (allRotParams->Lower()     != 1 ||
        allRotParams->Length()    != allNodes->Length()) )
-    Standard_DimensionMismatch::Raise
-  ("IGESAppli_NodalDisplAndRot : Init(Lengths of arrays inconsistent)");
+    throw Standard_DimensionMismatch("IGESAppli_NodalDisplAndRot : Init(Lengths of arrays inconsistent)");
 
   for (Standard_Integer i= 1; i <= allNodes->Length(); i++)
     {
@@ -54,8 +53,7 @@ IGESAppli_NodalDisplAndRot::IGESAppli_NodalDisplAndRot ()    {  }
       Handle(TColgp_HArray1OfXYZ) temp2 = allRotParams->Value(i);
       if ((temp1->Lower() != 1 || temp1->Length() != allNotes->Length()) ||
          (temp2->Lower() != 1 || temp2->Length() != allNotes->Length()) )
-       Standard_DimensionMismatch::Raise
-         ("IGESAppli_NodalDisplAndRot: Init(No. of Param per Node != Nbcases)");
+       throw Standard_DimensionMismatch("IGESAppli_NodalDisplAndRot: Init(No. of Param per Node != Nbcases)");
     }
 
   theNotes           = allNotes;
index 525222c..35328e2 100644 (file)
@@ -42,7 +42,7 @@ IGESAppli_NodalResults::IGESAppli_NodalResults ()    {  }
       allNodes->Length()  != allNodeIdentifiers->Length() ||
       allData->LowerCol() != 1 || allData->LowerRow() != 1 ||
       allNodes->Length()  != allData->UpperRow() )
-    Standard_DimensionMismatch::Raise("IGESAppli_NodalResults : Init");
+    throw Standard_DimensionMismatch("IGESAppli_NodalResults : Init");
   theNote            = aNote;
   theSubCaseNum      = aNumber;
   theTime            = aTime;
@@ -55,8 +55,7 @@ IGESAppli_NodalResults::IGESAppli_NodalResults ()    {  }
 
     void  IGESAppli_NodalResults::SetFormNumber (const Standard_Integer form)
 {
-  if (form < 0 || form > 34) Standard_OutOfRange::Raise
-    ("IGESAppli_NodalResults : SetFormNumber");
+  if (form < 0 || form > 34) throw Standard_OutOfRange("IGESAppli_NodalResults : SetFormNumber");
   InitTypeAndForm(146,form);
 }
 
index 3bcab5a..bbcee3b 100644 (file)
@@ -33,7 +33,7 @@ IGESAppli_PWBArtworkStackup::IGESAppli_PWBArtworkStackup ()    {  }
    const Handle(TColStd_HArray1OfInteger)& allLevelNums)
 {
   if (allLevelNums->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESAppli_PWBArtworkStackup : Init");
+    throw Standard_DimensionMismatch("IGESAppli_PWBArtworkStackup : Init");
   theNbPropertyValues    = nbPropVal;
   theArtworkStackupIdent = anArtIdent;
   theLevelNumbers        = allLevelNums;
index 0ce3be2..cda846b 100644 (file)
@@ -46,7 +46,7 @@ IGESAppli_PipingFlow::IGESAppli_PipingFlow ()    {  }
       allJoins->Lower()          != 1 || allJoins->Length()          != num ||
       allFlowNames->Lower()      != 1 || allFlowNames->Length()      != num ||
       allContFlowAssocs->Lower() != 1 || allContFlowAssocs->Length() != num )
-    Standard_DimensionMismatch::Raise("IGESAppli_PipingFlow : Init");
+    throw Standard_DimensionMismatch("IGESAppli_PipingFlow : Init");
   theNbContextFlags          = nbContextFlags;
   theTypeOfFlow              = aFlowType;
   theFlowAssociativities     = allFlowAssocs;
index a6f0499..5a19ea3 100644 (file)
@@ -33,7 +33,7 @@ IGESBasic_ExternalRefFileIndex::IGESBasic_ExternalRefFileIndex ()    {  }
 {
   if (aNameArray->Lower()  != 1 || allEntities->Lower() != 1 ||
       aNameArray->Length() != allEntities->Length())
-    Standard_DimensionMismatch::Raise("IGESBasic_ExternalRefFileIndex: Init");
+    throw Standard_DimensionMismatch("IGESBasic_ExternalRefFileIndex: Init");
 
   theNames = aNameArray;
   theEntities = allEntities;
index 1d5b2f8..6578414 100644 (file)
@@ -31,7 +31,7 @@ IGESBasic_ExternalReferenceFile::IGESBasic_ExternalReferenceFile ()    {  }
   (const Handle(Interface_HArray1OfHAsciiString)& aNameArray)
 {
   if (aNameArray->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESBasic_ExternalReferenceFile : Init");
+    throw Standard_DimensionMismatch("IGESBasic_ExternalReferenceFile : Init");
   theNames = aNameArray;
   InitTypeAndForm(406,12);
 }
index c269c71..5a25d35 100644 (file)
@@ -43,7 +43,7 @@ IGESBasic_Group::IGESBasic_Group ()    {  InitTypeAndForm(402,1);  }
   // ptv and rln September 14, 2000 BUC60743
   // Protection against empty groups
   if (!allEntities.IsNull() && (allEntities->Lower() != 1))
-    Standard_DimensionMismatch::Raise("IGESBasic_Group : Init");
+    throw Standard_DimensionMismatch("IGESBasic_Group : Init");
   theEntities   = allEntities;
   if (FormNumber() == 0) InitTypeAndForm(402,1);
 }
@@ -87,7 +87,7 @@ IGESBasic_Group::IGESBasic_Group ()    {  InitTypeAndForm(402,1);  }
     void  IGESBasic_Group::SetUser
   (const Standard_Integer type, const Standard_Integer form)
 {
-  if (type <= 5000) Standard_OutOfRange::Raise("IGESBasic_Group::SetUser");
+  if (type <= 5000) throw Standard_OutOfRange("IGESBasic_Group::SetUser");
   InitTypeAndForm (type,form);
 }
 
index 508b2f2..79d895a 100644 (file)
@@ -33,7 +33,7 @@ IGESBasic_SingleParent::IGESBasic_SingleParent ()    {  }
    const Handle(IGESData_HArray1OfIGESEntity)& allChildren)
 {
   if (!allChildren.IsNull() && allChildren->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESBasic_SingleParent : Init");
+    throw Standard_DimensionMismatch("IGESBasic_SingleParent : Init");
   theParentEntity     = aParentEntity;
   theChildren         = allChildren;
   theNbParentEntities = nbParentEntities;
index 303b0c7..fb0f442 100644 (file)
@@ -35,7 +35,7 @@ IGESBasic_SubfigureDef::IGESBasic_SubfigureDef ()    {  }
    const Handle(IGESData_HArray1OfIGESEntity)& allAssocEntities)
 {
   if (!allAssocEntities.IsNull() && allAssocEntities->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESBasic_SubfigureDef : Init");
+    throw Standard_DimensionMismatch("IGESBasic_SubfigureDef : Init");
   theDepth         = aDepth;
   theName          = aName;
   theAssocEntities = allAssocEntities;
index 0ff7a66..7cd2c62 100644 (file)
@@ -71,7 +71,7 @@ static Standard_Real epsa = 1.E-10;
 {
   Standard_Integer num, nb = theXYZ->Length();
   if (datatype < 1 || datatype > 3 || nb == 0 || (polyline && datatype == 3))
-    Standard_DomainError::Raise ("IGESConvGeom_GeomBuilder : MakeCopiousData");
+    throw Standard_DomainError("IGESConvGeom_GeomBuilder : MakeCopiousData");
 
   Standard_Integer nbd = datatype+1;  // 1->2  2->3   et   3->6
   if (datatype == 3) nbd = 6;
index 6614427..4c07c3a 100644 (file)
@@ -46,7 +46,7 @@ IGESData_IGESDumper::IGESData_IGESDumper
   if (!ent.IsNull()) {
     if (themodel.IsNull())                          S<<"    D???    ";
     else if ( (num = themodel->Number(ent)) == 0)   S<<"    0:D?????";
-// Interface_InterfaceError::Raise  ("IGESDumper : PrintDNum");
+// throw Interface_InterfaceError("IGESDumper : PrintDNum");
     else {
       S<<Interface_MSG::Blanks(num,9)<<num<<":D"<<2*num-1<<Interface_MSG::Blanks(2*num-1,9);
     }
index c60e0f5..25732a2 100644 (file)
@@ -337,13 +337,12 @@ Standard_Boolean IGESData_IGESEntity::CResValues (const Standard_CString res1,
     Handle(IGESData_IGESEntity) IGESData_IGESEntity::UniqueParent () const
 {
   if (NbTypedProperties(STANDARD_TYPE(IGESData_SingleParentEntity)) != 1)
-    Interface_InterfaceError::Raise ("IGESEntity : UniqueParent");
+    throw Interface_InterfaceError("IGESEntity : UniqueParent");
   else {
     DeclareAndCast(IGESData_SingleParentEntity,PP,
                   TypedProperty(STANDARD_TYPE(IGESData_SingleParentEntity)));
     return PP->SingleParent();
   }
-  return this;  // ne rime a rien (cf exception) mais calme le compilateur
 }
 
 
index 0150660..2b78a4b 100644 (file)
@@ -171,13 +171,13 @@ void IGESData_IGESWriter::SendStartLine (const Standard_CString startline)
 
     void IGESData_IGESWriter::SectionS ()
 {
-  if (thesect != 0) Interface_InterfaceError::Raise("IGESWriter : SectionS");
+  if (thesect != 0) throw Interface_InterfaceError("IGESWriter : SectionS");
   thesect = 1;
 }
 
     void IGESData_IGESWriter::SectionG (const IGESData_GlobalSection& header)
 {
-  if (thesect != 1) Interface_InterfaceError::Raise("IGESWriter : SectionG");
+  if (thesect != 1) throw Interface_InterfaceError("IGESWriter : SectionG");
   thesect = 2;
   thesep  = header.Separator();
   theendm = header.EndMark();
@@ -197,7 +197,7 @@ void IGESData_IGESWriter::SendStartLine (const Standard_CString startline)
 
     void IGESData_IGESWriter::SectionsDP ()
 {
-  if (thesect != 2) Interface_InterfaceError::Raise("IGESWriter : SectionsDP");
+  if (thesect != 2) throw Interface_InterfaceError("IGESWriter : SectionsDP");
   thesect = 3;
   thecurr.SetMax (MaxcarsP);
   thestep = IGESData_ReadEnd;
@@ -205,7 +205,7 @@ void IGESData_IGESWriter::SendStartLine (const Standard_CString startline)
 
     void IGESData_IGESWriter::SectionT ()
 {
-  if (thesect != 3) Interface_InterfaceError::Raise("IGESWriter : SectionT");
+  if (thesect != 3) throw Interface_InterfaceError("IGESWriter : SectionT");
   thesect = 4;
   thepnum.SetValue(thepnum.Length(),thepars->Length()+1);
 }
@@ -215,7 +215,7 @@ void IGESData_IGESWriter::SendStartLine (const Standard_CString startline)
       (const Handle(IGESData_IGESEntity)& anent)
 {
   if (thesect != 3 && thestep != IGESData_ReadEnd)
-    Interface_InterfaceError::Raise("IGESWriter : DirPart");
+    throw Interface_InterfaceError("IGESWriter : DirPart");
   Standard_Integer v[17]; Standard_Character res1[9],res2[9],label[9],snum[9];
   Standard_Integer nument = themodel->Number(anent);
   if (nument == 0) return;
@@ -289,7 +289,7 @@ void IGESData_IGESWriter::SendStartLine (const Standard_CString startline)
 {
   char text[20];
   if (thesect != 3 && thestep != IGESData_ReadDir)
-    Interface_InterfaceError::Raise("IGESWriter : OwnParams");
+    throw Interface_InterfaceError("IGESWriter : OwnParams");
   thepnum.SetValue(themodel->Number(anent),thepars->Length()+1);
   thecurr.Clear();
   sprintf(text,"%d",anent->TypeNumber());
@@ -301,7 +301,7 @@ void IGESData_IGESWriter::SendStartLine (const Standard_CString startline)
   (const Handle(IGESData_IGESEntity)& anent)
 {
   if (thesect != 3 && thestep != IGESData_ReadOwn)
-    Interface_InterfaceError::Raise("IGESWriter : Properties");
+    throw Interface_InterfaceError("IGESWriter : Properties");
   thestep = IGESData_ReadProps;
   if (!anent->ArePresentProperties()) return;
   Send(anent->NbProperties());
@@ -316,7 +316,7 @@ void IGESData_IGESWriter::SendStartLine (const Standard_CString startline)
   (const Handle(IGESData_IGESEntity)& anent)
 {
   if (thesect != 3 && thestep != IGESData_ReadOwn)
-    Interface_InterfaceError::Raise("IGESWriter : Associativities");
+    throw Interface_InterfaceError("IGESWriter : Associativities");
   thestep = IGESData_ReadAssocs;
   if (!anent->ArePresentAssociativities() && !anent->ArePresentProperties())
     return;  // Properties suivent : ne pas les omettre !
@@ -332,7 +332,7 @@ void IGESData_IGESWriter::SendStartLine (const Standard_CString startline)
     void IGESData_IGESWriter::EndEntity ()
 {
   if (thesect != 3 && thestep != IGESData_ReadOwn)
-    Interface_InterfaceError::Raise("IGESWriter : EndEntity");
+    throw Interface_InterfaceError("IGESWriter : EndEntity");
   AddChar(theendm);
   if (thecurr.Length() > 0) thepars->Append(thecurr.Moved());
   thestep = IGESData_ReadEnd;
@@ -496,8 +496,7 @@ Standard_Boolean IGESData_IGESWriter::Print (Standard_OStream& S) const
       blancs[i] = (char)(blancs[i] ^ (150 + (i & 3)));
   }
 
-  if (thesect != 4) Interface_InterfaceError::Raise
-    ("IGESWriter not ready for Print");
+  if (thesect != 4) throw Interface_InterfaceError("IGESWriter not ready for Print");
 //  Start Section (assez simple, somme toute). Attention si commentaires
   Handle(TCollection_HAsciiString) line;
   Standard_Integer nbs = 1;
index 9b67641..317aefb 100644 (file)
@@ -37,8 +37,7 @@ IGESData_ParamCursor::IGESData_ParamCursor (const Standard_Integer num)
   theoffst += thetsize;
   thetsize  = size;
   if (autoadv) theadv = (theoffst + thetsize == theisize);
-  if (theoffst + thetsize > theisize) Interface_InterfaceError::Raise
-    ("IGESDAta ParamCursor : required Term size overpass whole Item size");
+  if (theoffst + thetsize > theisize) throw Interface_InterfaceError("IGESDAta ParamCursor : required Term size overpass whole Item size");
 }
 
     void  IGESData_ParamCursor::SetOne (const Standard_Boolean autoadv)
index 95ccc16..27a8fac 100644 (file)
@@ -153,10 +153,8 @@ Standard_Boolean  IGESData_ToolLocation::HasParent
 {
   Standard_Integer num = themodel->Number(ent);
   if (num == 0) return Standard_False;
-  if (therefs(num) <  0 || theassocs(num) <  0) Standard_DomainError::Raise
-    ("IGESData_ToolLocation : HasParent");
-  if (therefs(num) != 0 && theassocs(num) != 0) Standard_DomainError::Raise
-    ("IGESData_ToolLocation : HasParent");
+  if (therefs(num) <  0 || theassocs(num) <  0) throw Standard_DomainError("IGESData_ToolLocation : HasParent");
+  if (therefs(num) != 0 && theassocs(num) != 0) throw Standard_DomainError("IGESData_ToolLocation : HasParent");
   if (therefs(num) != 0 || theassocs(num) != 0) return Standard_True;
   return Standard_False;
 }
@@ -167,10 +165,8 @@ Handle(IGESData_IGESEntity)  IGESData_ToolLocation::Parent
   Handle(IGESData_IGESEntity) parent;
   Standard_Integer num = themodel->Number(ent);
   if (num == 0) return parent;
-  if (therefs(num) <  0 || theassocs(num) <  0) Standard_DomainError::Raise
-    ("IGESData_ToolLocation : Parent");
-  if (therefs(num) != 0 && theassocs(num) != 0) Standard_DomainError::Raise
-    ("IGESData_ToolLocation : Parent");
+  if (therefs(num) <  0 || theassocs(num) <  0) throw Standard_DomainError("IGESData_ToolLocation : Parent");
+  if (therefs(num) != 0 && theassocs(num) != 0) throw Standard_DomainError("IGESData_ToolLocation : Parent");
   if (therefs(num)   != 0) parent = themodel->Entity (therefs   (num));
   if (theassocs(num) != 0) parent = themodel->Entity (theassocs (num));
   return parent;
@@ -181,10 +177,8 @@ Standard_Boolean  IGESData_ToolLocation::HasParentByAssociativity
 {
   Standard_Integer num = themodel->Number(ent);
   if (num == 0) return Standard_False;
-  if (therefs(num) <  0 || theassocs(num) <  0) Standard_DomainError::Raise
-    ("IGESData_ToolLocation : HasParentByAssociativity");
-  if (therefs(num) != 0 && theassocs(num) != 0) Standard_DomainError::Raise
-    ("IGESData_ToolLocation : HasParentByAssociativity");
+  if (therefs(num) <  0 || theassocs(num) <  0) throw Standard_DomainError("IGESData_ToolLocation : HasParentByAssociativity");
+  if (therefs(num) != 0 && theassocs(num) != 0) throw Standard_DomainError("IGESData_ToolLocation : HasParentByAssociativity");
   if (theassocs(num) != 0) return Standard_True;
   return Standard_False;
 }
index 6957058..b1c3e19 100644 (file)
@@ -38,7 +38,7 @@ IGESDefs_AssociativityDef::IGESDefs_AssociativityDef ()    {  }
       (orders->Lower()       != 1 || orders->Length()   != len) ||
       (numItems->Lower()     != 1 || numItems->Length() != len) ||
       (items->Lower()        != 1 || items->Length()    != len) )
-    Standard_DimensionMismatch::Raise("IGESDefs_AssociativityDef : Init");
+    throw Standard_DimensionMismatch("IGESDefs_AssociativityDef : Init");
 
   theBackPointerReqs = requirements;
   theClassOrders     = orders;
index 6780fd3..c7354b5 100644 (file)
@@ -54,15 +54,15 @@ IGESDefs_AttributeDef::IGESDefs_AttributeDef ()    {  }
   if (attrTypes->Lower() != 1 || attrValueDataTypes->Lower() != 1 ||
       attrValueDataTypes->Length() != nb ||
       attrValueCounts->Lower()     != 1  || attrValueCounts->Length() != nb)
-    Standard_DimensionMismatch::Raise("IGESDefs_AttributeDef : Init");
+    throw Standard_DimensionMismatch("IGESDefs_AttributeDef : Init");
 
   if (FormNumber() >= 1)
     if (attrValues->Lower() != 1 || attrValues->Length() != nb)
-      Standard_DimensionMismatch::Raise("IGESDefs_AttributeDef : Init");
+      throw Standard_DimensionMismatch("IGESDefs_AttributeDef : Init");
 
   if (FormNumber() == 2)
     if (attrValuePointers->Lower() != 1 || attrValuePointers->Length() != nb)
-      Standard_DimensionMismatch::Raise("IGESDefs_AttributeDef : Init");
+      throw Standard_DimensionMismatch("IGESDefs_AttributeDef : Init");
 // Form 1 : attrValues defined  Form = 2 : attrValuePointers defined
 
   theName               = aName;
index 31a3994..5080ef7 100644 (file)
@@ -43,7 +43,7 @@ IGESDefs_AttributeTable::IGESDefs_AttributeTable ()    {  }
   (const Handle(TColStd_HArray2OfTransient)& attributes)
 {
   if (attributes->LowerCol() != 1 || attributes->LowerRow() != 1)
-    Standard_DimensionMismatch::Raise("IGESDefs_AttributeTable : Init");
+    throw Standard_DimensionMismatch("IGESDefs_AttributeTable : Init");
   theAttributes = attributes;
 
   Standard_Integer fn = FormNumber();
index acd83e9..38545ba 100644 (file)
@@ -47,7 +47,7 @@ IGESDefs_GenericData::IGESDefs_GenericData ()    {  }
   if ( !allTypes.IsNull() && !allValues.IsNull() &&
       (allValues->Lower() != 1 || allTypes->Lower() != 1 ||
        allTypes->Length() != allValues->Length() ) )
-    Standard_DimensionMismatch::Raise("IGESDefs_GenericData: Init");
+    throw Standard_DimensionMismatch("IGESDefs_GenericData: Init");
   theNbPropertyValues = nbPropVal;
   theName   = aName;
   theTypes  = allTypes;
index 6047c5c..688147d 100644 (file)
@@ -33,7 +33,7 @@ IGESDefs_MacroDef::IGESDefs_MacroDef ()    {  }
    const Handle(TCollection_HAsciiString)& endMacro)
 {
   if (langStatements->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESDefs_MacroDef : Init");
+    throw Standard_DimensionMismatch("IGESDefs_MacroDef : Init");
   theMACRO          = macro;
   theEntityTypeID   = entityTypeID;
   theLangStatements = langStatements;
index 0cc27e5..af04ab6 100644 (file)
@@ -45,7 +45,7 @@ IGESDefs_TabularData::IGESDefs_TabularData ()    {  }
       nbValuesInd->Lower() != 1 || nbValuesInd->Length() != num ||
       valuesInd->Lower()   != 1 || valuesInd->Length()   != num ||
       valuesDep->Lower()   != 1 )
-    Standard_DimensionMismatch::Raise("IGESDefs_TabularData : Init");
+    throw Standard_DimensionMismatch("IGESDefs_TabularData : Init");
   theNbPropertyValues = nbProps;
   thePropertyType               = propType;
 /*     theNbDependents = nbDeps; */
index 0200222..b1f4c05 100644 (file)
@@ -36,7 +36,7 @@ IGESDefs_UnitsData::IGESDefs_UnitsData ()    {  }
   if ( unitTypes->Lower()  != 1  ||
       (unitValues->Lower() != 1 || unitValues->Length() != length) ||
       (unitScales->Lower() != 1 || unitScales->Length() != length) )
-    Standard_DimensionMismatch::Raise("IGESDefs_UnitsData : Init");
+    throw Standard_DimensionMismatch("IGESDefs_UnitsData : Init");
   theUnitTypes   = unitTypes;
   theUnitValues  = unitValues;
   theUnitScales  = unitScales;
index 05bed47..14e496d 100644 (file)
@@ -35,7 +35,7 @@ IGESDimen_CenterLine::IGESDimen_CenterLine ()    {  }
    const Handle(TColgp_HArray1OfXY)& dataPnts)
 {
   if (dataPnts->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESDimen_CenterLine : Init");
+    throw Standard_DimensionMismatch("IGESDimen_CenterLine : Init");
   theDatatype      = aDataType;
   theZDisplacement = aZdisp;
   theDataPoints    = dataPnts;
index e43d853..b3ecd8b 100644 (file)
@@ -44,7 +44,7 @@ IGESDimen_DimensionDisplayData::IGESDimen_DimensionDisplayData ()    {  }
     if (notes->Lower() != 1 ||
        (startInd->Lower() != 1 || notes->Length() != startInd->Length()) || 
        (endInd->Lower()   != 1 || notes->Length() != endInd->Length())   )
-      Standard_DimensionMismatch::Raise("IGESDimen_DimensionDisplayData : Init");
+      throw Standard_DimensionMismatch("IGESDimen_DimensionDisplayData : Init");
 
   theNbPropertyValues     = numProps;
   theDimensionType        = aDimType;
index 6d4fb86..deccd2f 100644 (file)
@@ -33,7 +33,7 @@ IGESDimen_DimensionedGeometry::IGESDimen_DimensionedGeometry ()    {  }
    const Handle(IGESData_HArray1OfIGESEntity)& entities)
 {
   if (entities->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESDimen_DimensionedGeometry : Init");
+    throw Standard_DimensionMismatch("IGESDimen_DimensionedGeometry : Init");
   theNbDimensions     = nbDims;
   theDimension        = aDimension;
   theGeometryEntities = entities;
index dd43bd1..ca892f7 100644 (file)
@@ -37,7 +37,7 @@ IGESDimen_FlagNote::IGESDimen_FlagNote ()    {  }
 {
   if (!someLeaders.IsNull())
     if (someLeaders->Lower() != 1)
-      Standard_DimensionMismatch::Raise("IGESDimen_FlagNote : Init");
+      throw Standard_DimensionMismatch("IGESDimen_FlagNote : Init");
   theLowerLeftcorner = leftCorner;
   theAngle           = anAngle;
   theNote            = aNote;
index bc1c2b2..a1bc1b7 100644 (file)
@@ -32,7 +32,7 @@ IGESDimen_GeneralLabel::IGESDimen_GeneralLabel ()    {  }
    const Handle(IGESDimen_HArray1OfLeaderArrow)& someLeaders)
 {
   if (someLeaders->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESDimen_GeneralLabel : Init");
+    throw Standard_DimensionMismatch("IGESDimen_GeneralLabel : Init");
   theNote    = aNote;
   theLeaders = someLeaders;
   InitTypeAndForm(210,0);
index 9ec9850..34d9fcc 100644 (file)
@@ -55,7 +55,7 @@ IGESDimen_GeneralNote::IGESDimen_GeneralNote ()    {  }
       (rotFlags->Lower()    != 1 || rotFlags->Length()    != num) ||
       (start->Lower()       != 1 || start->Length()       != num) ||
       (texts->Lower()       != 1 || texts->Length()       != num) )
-    Standard_DimensionMismatch::Raise("IGESDimen_GeneralNote : Init");
+    throw Standard_DimensionMismatch("IGESDimen_GeneralNote : Init");
 
   theNbChars        = nbChars; 
   theBoxWidths      = widths;
@@ -75,7 +75,7 @@ IGESDimen_GeneralNote::IGESDimen_GeneralNote ()    {  }
     void  IGESDimen_GeneralNote::SetFormNumber (const Standard_Integer form)
 {
   if ((form < 0 || form > 8) && (form < 100 || form > 102) && form != 105)
-    Standard_OutOfRange::Raise("IGESDimen_GeneralNote : SetFormNumber");
+    throw Standard_OutOfRange("IGESDimen_GeneralNote : SetFormNumber");
   InitTypeAndForm(212,form);
 }
 
index 943fb97..81293ba 100644 (file)
@@ -34,9 +34,9 @@ IGESDimen_GeneralSymbol::IGESDimen_GeneralSymbol ()    {  }
    const Handle(IGESDimen_HArray1OfLeaderArrow)& allLeaders)
 {
   if (!allGeoms.IsNull() &&  allGeoms->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESDimen_GeneralSymbol : Init");
+    throw Standard_DimensionMismatch("IGESDimen_GeneralSymbol : Init");
   if (!allLeaders.IsNull())
-    if (allLeaders->Lower() != 1) Standard_DimensionMismatch::Raise("$");
+    if (allLeaders->Lower() != 1) throw Standard_DimensionMismatch("$");
   theNote    = aNote;
   theGeoms   = allGeoms;
   theLeaders = allLeaders;
@@ -46,8 +46,7 @@ IGESDimen_GeneralSymbol::IGESDimen_GeneralSymbol ()    {  }
 
     void  IGESDimen_GeneralSymbol::SetFormNumber (const Standard_Integer form)
 {
-  if ((form < 0 || form > 3) && form < 5000) Standard_OutOfRange::Raise
-    ("IGESDimen_GeneralSymbol : SetFormNumber");
+  if ((form < 0 || form > 3) && form < 5000) throw Standard_OutOfRange("IGESDimen_GeneralSymbol : SetFormNumber");
   InitTypeAndForm(228,form);
 }
 
index 9ff74a9..a0fe750 100644 (file)
@@ -35,7 +35,7 @@ IGESDimen_LeaderArrow::IGESDimen_LeaderArrow ()    {  }
    const Handle(TColgp_HArray1OfXY)& segments)
 {
   if (segments->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESDimen_LeaderArrow : Init");
+    throw Standard_DimensionMismatch("IGESDimen_LeaderArrow : Init");
   theArrowHeadHeight = height;
   theArrowHeadWidth  = width;
   theZDepth          = depth ;
@@ -47,8 +47,7 @@ IGESDimen_LeaderArrow::IGESDimen_LeaderArrow ()    {  }
 
     void  IGESDimen_LeaderArrow::SetFormNumber (const Standard_Integer form)
 {
-  if (form < 1 || form > 12) Standard_OutOfRange::Raise
-    ("IGESDimen_LeaderArrow : SetFormNumber");
+  if (form < 1 || form > 12) throw Standard_OutOfRange("IGESDimen_LeaderArrow : SetFormNumber");
   InitTypeAndForm(214,form);
 }
 
index 6cbefe5..66dd56d 100644 (file)
@@ -47,8 +47,7 @@ IGESDimen_LinearDimension::IGESDimen_LinearDimension ()    {  }
 
     void  IGESDimen_LinearDimension::SetFormNumber (const Standard_Integer fm)
 {
-  if (fm < 0 || fm > 2) Standard_OutOfRange::Raise
-    ("IGESDimen_LinearDimension : SetFormNumber");
+  if (fm < 0 || fm > 2) throw Standard_OutOfRange("IGESDimen_LinearDimension : SetFormNumber");
   InitTypeAndForm(216,fm);
 }
 
index d3ef7ac..4705cc3 100644 (file)
@@ -42,8 +42,7 @@ IGESDimen_NewDimensionedGeometry::IGESDimen_NewDimensionedGeometry ()   { }
   if (allEntities->Lower()  != 1 ||
       allLocations->Lower() != 1 || allLocations->Length() != num ||
       allPoints->Lower()    != 1 || allPoints->Length()    != num )
-    Standard_DimensionMismatch::Raise
-      ("IGESDimen_NewDimensionedGeometry: Init");
+    throw Standard_DimensionMismatch("IGESDimen_NewDimensionedGeometry: Init");
   theNbDimensions             = nbDimens;
   theDimensionEntity          = aDimen;
   theDimensionOrientationFlag = anOrientation;
index 5e90312..da15024 100644 (file)
@@ -77,7 +77,7 @@ IGESDimen_NewGeneralNote::IGESDimen_NewGeneralNote ()    {  }
       (rotateFlags->Lower()     != 1 || rotateFlags->Length()     != num) ||
       (startPoints->Lower()     != 1 || startPoints->Length()     != num) ||
       (texts->Lower()           != 1 || texts->Length() != num))
-    Standard_DimensionMismatch::Raise("IGESDimen_GeneralNote : Init");
+    throw Standard_DimensionMismatch("IGESDimen_GeneralNote : Init");
 
   theWidth                = width;
   theHeight               = height;
index d0b6b05..e4a49e7 100644 (file)
@@ -34,7 +34,7 @@ IGESDimen_Section::IGESDimen_Section ()    {  }
    const Handle(TColgp_HArray1OfXY)& dataPoints)
 {
   if (dataPoints->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESDimen_Section : Init");
+    throw Standard_DimensionMismatch("IGESDimen_Section : Init");
   theDatatype      = dataType;
   theZDisplacement = aDisp;
   theDataPoints    = dataPoints;
@@ -45,8 +45,7 @@ IGESDimen_Section::IGESDimen_Section ()    {  }
 
     void  IGESDimen_Section::SetFormNumber (const Standard_Integer form)
 {
-  if (form < 31 || form > 38) Standard_OutOfRange::Raise
-    ("IGESDimen_Section : SetFormNumber");
+  if (form < 31 || form > 38) throw Standard_OutOfRange("IGESDimen_Section : SetFormNumber");
   InitTypeAndForm(106,form);
 }
 
index 0ba006b..f0dd3f8 100644 (file)
@@ -40,7 +40,7 @@ IGESDimen_SectionedArea::IGESDimen_SectionedArea ()    {  }
 {
   if (!someIslands.IsNull())
     if (someIslands->Lower() != 1)
-      Standard_DimensionMismatch::Raise("IGESDimen_SectionedArea : Init");
+      throw Standard_DimensionMismatch("IGESDimen_SectionedArea : Init");
   theExteriorCurve = aCurve;
   thePattern       = aPattern;
   thePassingPoint  = aPoint;
index 2662aff..23e9dc6 100644 (file)
@@ -34,7 +34,7 @@ IGESDimen_WitnessLine::IGESDimen_WitnessLine ()    {  }
    const Handle(TColgp_HArray1OfXY)& dataPoints)
 {
   if (dataPoints->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESDimen_WitnessLine : Init");
+    throw Standard_DimensionMismatch("IGESDimen_WitnessLine : Init");
   theDatatype      = dataType;
   theZDisplacement = aDisp;
   theDataPoints    = dataPoints;
index e57bcbc..4b4fd18 100644 (file)
@@ -42,7 +42,7 @@ IGESDraw_CircArraySubfigure::IGESDraw_CircArraySubfigure ()    {  }
 {
   if (!allNumPos.IsNull())
     if (allNumPos->Lower() != 1)
-      Standard_DimensionMismatch::Raise("IGESDraw_CircArraySubfigure : Init");
+      throw Standard_DimensionMismatch("IGESDraw_CircArraySubfigure : Init");
   theBaseEntity  = aBase;
   theNbLocations = aNumLocs;
   theCenter      = aCenter;
index dcf1cd6..fed0b05 100644 (file)
@@ -45,11 +45,10 @@ IGESDraw_Drawing::IGESDraw_Drawing ()    {  }
     Standard_Integer Len  = allViews->Length();
     Standard_Boolean Flag = ( allViewOrigins->Length() == Len );
     if (!Flag || allViews->Lower() != 1 || allViewOrigins->Lower() != 1)
-      Standard_DimensionMismatch::Raise("IGESDraw_Drawing : Init");
+      throw Standard_DimensionMismatch("IGESDraw_Drawing : Init");
   }
   if (!allAnnotations.IsNull())
-    if (allAnnotations->Lower() != 1) Standard_DimensionMismatch::Raise
-      ("IGESDraw_Drawing : Init");
+    if (allAnnotations->Lower() != 1) throw Standard_DimensionMismatch("IGESDraw_Drawing : Init");
 
   theViews         = allViews; 
   theViewOrigins   = allViewOrigins; 
index 217a9d1..9a20a49 100644 (file)
@@ -46,11 +46,9 @@ IGESDraw_DrawingWithRotation::IGESDraw_DrawingWithRotation ()    {  }
   if ( allViews->Lower() != 1 ||
       (allViewOrigins->Lower() != 1 || allViewOrigins->Length() != Len) ||
       (allOrientationAngles->Lower() != 1 || allOrientationAngles->Length() != Len) )
-    Standard_DimensionMismatch::Raise
-      ("IGESDraw_DrawingWithRotation : Init");
+    throw Standard_DimensionMismatch("IGESDraw_DrawingWithRotation : Init");
   if (!allAnnotations.IsNull())
-    if (allAnnotations->Lower() != 1) Standard_DimensionMismatch::Raise
-      ("IGESDraw_DrawingWithRotation : Init");
+    if (allAnnotations->Lower() != 1) throw Standard_DimensionMismatch("IGESDraw_DrawingWithRotation : Init");
 
   theViews             = allViews; 
   theViewOrigins       = allViewOrigins; 
index ce2dece..e20d74d 100644 (file)
@@ -45,7 +45,7 @@ IGESDraw_LabelDisplay::IGESDraw_LabelDisplay ()    {  }
       (allLeaderEntities->Lower() != 1 || allLeaderEntities->Length() != Ln) ||
       (allLabelLevels->Lower()    != 1 || allLabelLevels->Length()    != Ln) ||
       (allDisplayedEntities->Lower() != 1 || allDisplayedEntities->Length() != Ln))
-    Standard_DimensionMismatch::Raise("IGESDraw_LabelDisplay : Init");
+    throw Standard_DimensionMismatch("IGESDraw_LabelDisplay : Init");
 
   theViews             = allViews; 
   theTextLocations     = allTextLocations; 
index 1c12260..6ce9f23 100644 (file)
@@ -42,7 +42,7 @@ IGESDraw_NetworkSubfigure::IGESDraw_NetworkSubfigure ()    {  }
 {
   if (!allConnectPoints.IsNull())
     if (allConnectPoints->Lower() != 1)
-      Standard_DimensionMismatch::Raise("IGESDraw_NetworkSubfigure : Init");
+      throw Standard_DimensionMismatch("IGESDraw_NetworkSubfigure : Init");
   theSubfigureDefinition = aDefinition;
   theTranslation         = aTranslation;
   theScaleFactor         = aScaleFactor;
index 42a3199..7261959 100644 (file)
@@ -41,7 +41,7 @@ IGESDraw_NetworkSubfigureDef::IGESDraw_NetworkSubfigureDef ()    {  }
 {
   if (!allPointEntities.IsNull())
     if (allPointEntities->Lower() != 1 || allEntities->Lower() != 1)
-      Standard_DimensionMismatch::Raise("IGESDraw_NetworkSubfigureDef : Init");
+      throw Standard_DimensionMismatch("IGESDraw_NetworkSubfigureDef : Init");
   theDepth              = aDepth;
   theName               = aName;
   theEntities           = allEntities;
index 6b71a6a..b330131 100644 (file)
@@ -35,7 +35,7 @@ IGESDraw_Planar::IGESDraw_Planar ()    {  }
 {
   if (!allEntities.IsNull())
     if (allEntities->Lower() != 1)
-      Standard_DimensionMismatch::Raise("IGESDraw_Planar : Init");
+      throw Standard_DimensionMismatch("IGESDraw_Planar : Init");
   theNbMatrices           = nbMats;
   theTransformationMatrix = aTransformationMatrix;
   theEntities             = allEntities;
index 46b61aa..36f9da2 100644 (file)
@@ -44,7 +44,7 @@ IGESDraw_RectArraySubfigure::IGESDraw_RectArraySubfigure ()    {  }
 {
   if (!allNumPos.IsNull())
     if (allNumPos->Lower() != 1)
-      Standard_DimensionMismatch::Raise("IGESDraw_RectArraySubfigure : Init");
+      throw Standard_DimensionMismatch("IGESDraw_RectArraySubfigure : Init");
   theBaseEntity       = aBase;
   theScaleFactor      = aScale;
   theLowerLeftCorner  = aCorner;
index db1ec2e..75f1330 100644 (file)
@@ -48,7 +48,7 @@ IGESDraw_SegmentedViewsVisible::IGESDraw_SegmentedViewsVisible ()    {  }
       (allLineFontValues->Lower()   != 1 || allLineFontValues->Length()   != Len) ||
       (allLineFontDefinitions->Lower() != 1 || allLineFontDefinitions->Length()  != Len) ||
       (allLineWeights->Lower()  != 1 || allLineWeights->Length()  != Len) )
-    Standard_DimensionMismatch::Raise("IGESDraw_SegmentedViewsVisible : Init");
+    throw Standard_DimensionMismatch("IGESDraw_SegmentedViewsVisible : Init");
 
   theViews                = allViews;
   theBreakpointParameters = allBreakpointParameters;
index e4aa9be..43c47f6 100644 (file)
@@ -36,10 +36,10 @@ IGESDraw_ViewsVisible::IGESDraw_ViewsVisible ()    {  }
 {
   if (!allDisplayEntity.IsNull())
     if (allDisplayEntity->Lower() != 1)
-      Standard_DimensionMismatch::Raise("IGESDraw_ViewsVisible : Init");
+      throw Standard_DimensionMismatch("IGESDraw_ViewsVisible : Init");
   if (!allViewEntities.IsNull())
     if (allViewEntities->Lower() != 1)
-      Standard_DimensionMismatch::Raise("IGESDraw_ViewsVisible : Init");
+      throw Standard_DimensionMismatch("IGESDraw_ViewsVisible : Init");
   theViewEntities  = allViewEntities;
   theDisplayEntity = allDisplayEntity;
   InitTypeAndForm(402,3);
@@ -50,7 +50,7 @@ IGESDraw_ViewsVisible::IGESDraw_ViewsVisible ()    {  }
 {
   if (!allDisplayEntity.IsNull())
     if (allDisplayEntity->Lower() != 1)
-      Standard_DimensionMismatch::Raise("IGESDraw_ViewsVisible : InitImplied");
+      throw Standard_DimensionMismatch("IGESDraw_ViewsVisible : InitImplied");
   theDisplayEntity = allDisplayEntity;
 }
 
index a533264..c6d1fc1 100644 (file)
@@ -49,11 +49,10 @@ IGESDraw_ViewsVisibleWithAttr::IGESDraw_ViewsVisibleWithAttr ()    {  }
        (allLineWeights->Lower()  != 1 || allLineWeights->Length() != Exp) ||
        (allLineDefinitions->Lower() != 1 || allLineDefinitions->Length() != Exp) ||
        (allColorDefinitions->Lower() != 1 || allColorDefinitions->Length() != Exp))
-      Standard_DimensionMismatch::Raise("IGESDraw_ViewsVisibleWithAttr : Init");
+      throw Standard_DimensionMismatch("IGESDraw_ViewsVisibleWithAttr : Init");
   }
   if (!allDisplayEntities.IsNull())
-    if (allDisplayEntities->Lower() != 1) Standard_DimensionMismatch::Raise
-  ("IGESDraw_ViewsVisibleWithAttr : Init");
+    if (allDisplayEntities->Lower() != 1) throw Standard_DimensionMismatch("IGESDraw_ViewsVisibleWithAttr : Init");
 
   theViewEntities     = allViewEntities;
   theLineFonts        = allLineFonts;
@@ -70,7 +69,7 @@ IGESDraw_ViewsVisibleWithAttr::IGESDraw_ViewsVisibleWithAttr ()    {  }
 {
   if (!allDisplayEntity.IsNull())
     if (allDisplayEntity->Lower() != 1)
-      Standard_DimensionMismatch::Raise("IGESDraw_ViewsVisibleWithAttr : InitImplied");
+      throw Standard_DimensionMismatch("IGESDraw_ViewsVisibleWithAttr : InitImplied");
   theDisplayEntities = allDisplayEntity;
 }
 
index 7736d9d..2621a11 100644 (file)
@@ -42,11 +42,11 @@ IGESGeom_BSplineCurve::IGESGeom_BSplineCurve ()    {  }
 {
   if (!allPoles.IsNull()) {
     if (allPoles->Length() != allWeights->Length())
-      Standard_DimensionMismatch::Raise("IGESGeom_BSplineCurve : Init");
+      throw Standard_DimensionMismatch("IGESGeom_BSplineCurve : Init");
     if (allKnots->Lower()   != -aDegree || allKnots->Upper()   != anIndex+1 ||
        allWeights->Upper() !=  anIndex ||
        allWeights->Lower() != 0        || allPoles->Lower() != 0)
-      Standard_DimensionMismatch::Raise("IGESGeom_BSplineCurve : Init");
+      throw Standard_DimensionMismatch("IGESGeom_BSplineCurve : Init");
   }
 
   theIndex     = anIndex;
@@ -67,8 +67,7 @@ IGESGeom_BSplineCurve::IGESGeom_BSplineCurve ()    {  }
 
     void  IGESGeom_BSplineCurve::SetFormNumber (const Standard_Integer form)
 {
-  if (form < 0 || form > 5) Standard_OutOfRange::Raise
-    ("IGESGeom_BSplineCurve : SetFormNumber");
+  if (form < 0 || form > 5) throw Standard_OutOfRange("IGESGeom_BSplineCurve : SetFormNumber");
   InitTypeAndForm(126,form);
 }
 
index 035767b..514512e 100644 (file)
@@ -43,13 +43,13 @@ IGESGeom_BSplineSurface::IGESGeom_BSplineSurface ()    {  }
 {
   if (allWeights->RowLength() !=  allPoles->RowLength() || 
       allWeights->ColLength() !=  allPoles->ColLength())
-    Standard_DimensionMismatch::Raise("IGESGeom_BSplineSurface : Init");
+    throw Standard_DimensionMismatch("IGESGeom_BSplineSurface : Init");
   if (allKnotsU->Lower() != -aDegU       || allKnotsV->Lower() != -aDegV     ||
       allKnotsU->Upper() != anIndexU+1   || allKnotsV->Upper() != anIndexV+1 ||
       allWeights->LowerRow() != 0        || allWeights->LowerCol() != 0 ||
       allPoles->LowerRow()   != 0        || allPoles->LowerCol()   != 0 ||
       allPoles->UpperRow()   != anIndexU || allPoles->UpperCol()   != anIndexV)
-    Standard_DimensionMismatch::Raise("IGESGeom_BSplineSurface : Init");
+    throw Standard_DimensionMismatch("IGESGeom_BSplineSurface : Init");
 
   theIndexU    = anIndexU;
   theIndexV    = anIndexV;
@@ -74,8 +74,7 @@ IGESGeom_BSplineSurface::IGESGeom_BSplineSurface ()    {  }
 
     void  IGESGeom_BSplineSurface::SetFormNumber (const Standard_Integer form)
 {
-  if (form < 0 || form > 9) Standard_OutOfRange::Raise
-    ("IGESGeom_BSplineSurface : SetFormNumber");
+  if (form < 0 || form > 9) throw Standard_OutOfRange("IGESGeom_BSplineSurface : SetFormNumber");
   InitTypeAndForm(128,form);
 }
 
index f1a4f2e..9e2316e 100644 (file)
@@ -40,7 +40,7 @@ IGESGeom_Boundary::IGESGeom_Boundary ()    {  }
   if ( allSenses->Lower()          != 1 ||
       (allModelCurves->Lower()     != 1 || allModelCurves->Length() != num1) ||
       (allParameterCurves->Lower() != 1 || allParameterCurves->Length() != num1))
-    Standard_DimensionMismatch::Raise("IGESGeom_Boundary: Init");
+    throw Standard_DimensionMismatch("IGESGeom_Boundary: Init");
 
   theType            = aType;
   thePreference      = aPreference;
index c4910eb..2dab522 100644 (file)
@@ -34,7 +34,7 @@ IGESGeom_BoundedSurface::IGESGeom_BoundedSurface ()    {  }
    const Handle(IGESGeom_HArray1OfBoundary)& aBoundary)
 {
   if (aBoundary->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESGeom_BoundedSurface : Init");
+    throw Standard_DimensionMismatch("IGESGeom_BoundedSurface : Init");
   theType       = aType;
   theSurface    = aSurface;
   theBoundaries = aBoundary;
index 250c922..64af3db 100644 (file)
@@ -31,7 +31,7 @@ IGESGeom_CompositeCurve::IGESGeom_CompositeCurve ()    {  }
   (const Handle(IGESData_HArray1OfIGESEntity)& allEntities)
 {
   if (!allEntities.IsNull() && allEntities->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESGeom_CompositeCurve : Init");
+    throw Standard_DimensionMismatch("IGESGeom_CompositeCurve : Init");
   theEntities = allEntities;
   InitTypeAndForm(102,0);
 }
index 3a0bac2..b620720 100644 (file)
@@ -41,9 +41,9 @@ IGESGeom_CopiousData::IGESGeom_CopiousData ()
 {
   // PTV OCC386 crach application while reading So5771b.igs
   if (allData.IsNull())
-    Standard_NullObject::Raise("IGESGeom_CopiousData : Init with null data");
+    throw Standard_NullObject("IGESGeom_CopiousData : Init with null data");
   
-  if (allData->Lower() != 1) Standard_DimensionMismatch::Raise("IGESGeom_CopiousData : Init");
+  if (allData->Lower() != 1) throw Standard_DimensionMismatch("IGESGeom_CopiousData : Init");
   theDataType = aDataType;
   theZPlane   = aZPlane;
   theData     = allData;
index 50e1622..4bfe988 100644 (file)
@@ -48,8 +48,7 @@ IGESGeom_Flash::IGESGeom_Flash ()     {  }
 
     void  IGESGeom_Flash::SetFormNumber (const Standard_Integer form)
 {
-  if (form < 0 || form > 4) Standard_OutOfRange::Raise
-    ("IGESGeom_Flash : SetFormNumber");
+  if (form < 0 || form > 4) throw Standard_OutOfRange("IGESGeom_Flash : SetFormNumber");
   InitTypeAndForm(125,form);
 }
 
index b13e1c9..acbc1ed 100644 (file)
@@ -41,25 +41,21 @@ IGESGeom_SplineCurve::IGESGeom_SplineCurve ()    {  }
   Standard_Integer len = allXPolynomials->ColLength();
   if ((len != allYPolynomials->ColLength()) ||
       (len != allZPolynomials->ColLength()) )
-    Standard_DimensionMismatch::Raise
-  ("IGESGeom_SplineCurve : Column Length of HArray2s in Init");
+    throw Standard_DimensionMismatch("IGESGeom_SplineCurve : Column Length of HArray2s in Init");
   if (allBreakPoints->Lower() != 1 || allXvalues->Lower() != 1 ||
       allYvalues->Lower()     != 1 || allZvalues->Lower() != 1 ||
       allXPolynomials->LowerCol() != 1 || allXPolynomials->LowerRow() != 1 ||
       allYPolynomials->LowerCol() != 1 || allYPolynomials->LowerRow() != 1 ||
       allZPolynomials->LowerCol() != 1 || allZPolynomials->LowerRow() != 1)
-    Standard_DimensionMismatch::Raise
-  ("IGESGeom_SplineCurve : Lower Indices of HArrays in Init");
+    throw Standard_DimensionMismatch("IGESGeom_SplineCurve : Lower Indices of HArrays in Init");
   len = allXPolynomials->RowLength();
   if ((len != allYPolynomials->RowLength()) ||
       (len != allZPolynomials->RowLength()) )
-    Standard_DimensionMismatch::Raise
-  ("IGESGeom_SplineCurve : Row Length of HArray2s in Init");
+    throw Standard_DimensionMismatch("IGESGeom_SplineCurve : Row Length of HArray2s in Init");
 
   len = allXvalues->Length();
   if ((len != allYvalues->Length()) || (len != allZvalues->Length()) )
-    Standard_DimensionMismatch::Raise
-  ("IGESGeom_SplineCurve : Length of HArray1s in Init");
+    throw Standard_DimensionMismatch("IGESGeom_SplineCurve : Length of HArray1s in Init");
 
   theType   = aType;
   theDegree = aDegree;
index f25a990..c97c1cc 100644 (file)
@@ -37,26 +37,22 @@ IGESGeom_SplineSurface::IGESGeom_SplineSurface ()    {  }
 {
   Standard_Integer i,j;
   if (allUBreakPoints->Lower() != 1 || allVBreakPoints->Lower() != 1)
-    Standard_DimensionMismatch::Raise
-  ("IGESGeom_SplineSurface: Lower Indices of BreakPoints in Init");
+    throw Standard_DimensionMismatch("IGESGeom_SplineSurface: Lower Indices of BreakPoints in Init");
 
   Standard_Integer nbUSegs = allUBreakPoints->Length() - 1;
   Standard_Integer nbVSegs = allVBreakPoints->Length() - 1;
 
   Standard_Integer len = allXCoeffs->RowLength();
   if ((len != allYCoeffs->RowLength()) || (len != allZCoeffs->RowLength()))
-    Standard_DimensionMismatch::Raise
-  ("IGESGeom_SplineSurface: Row Length of HArray2s in Init");
+    throw Standard_DimensionMismatch("IGESGeom_SplineSurface: Row Length of HArray2s in Init");
   if (allXCoeffs->LowerCol() != 1 || allXCoeffs->LowerRow() != 1 ||
       allYCoeffs->LowerCol() != 1 || allYCoeffs->LowerRow() != 1 ||
       allZCoeffs->LowerCol() != 1 || allZCoeffs->LowerRow() != 1 )
-    Standard_DimensionMismatch::Raise
-  ("IGESGeom_SplineSurface: Lower Col-Row Indices of HArray2s in Init");
+    throw Standard_DimensionMismatch("IGESGeom_SplineSurface: Lower Col-Row Indices of HArray2s in Init");
 
   len = allXCoeffs->ColLength();
   if ((len != allYCoeffs->ColLength()) || (len != allZCoeffs->ColLength()))
-    Standard_DimensionMismatch::Raise
-  ("IGESGeom_SplineSurface: Column Length of HArray2s in Init");
+    throw Standard_DimensionMismatch("IGESGeom_SplineSurface: Column Length of HArray2s in Init");
 
   Handle(TColStd_HArray1OfReal) temp1;
   Handle(TColStd_HArray1OfReal) temp2;
@@ -70,8 +66,7 @@ IGESGeom_SplineSurface::IGESGeom_SplineSurface ()    {  }
         if ((temp1.IsNull() || temp1->Length() != 16) || 
             (temp2.IsNull() || temp2->Length() != 16) || 
             (temp3.IsNull() || temp3->Length() != 16))
-         Standard_DimensionMismatch::Raise
-           ("IGESGeom_SplineSurface: Lengths of elements of HArray2s in Init");
+         throw Standard_DimensionMismatch("IGESGeom_SplineSurface: Lengths of elements of HArray2s in Init");
       }
 
 
index da7e809..d4bb1a4 100644 (file)
@@ -39,8 +39,7 @@ IGESGeom_TransformationMatrix::IGESGeom_TransformationMatrix ()    {  }
     
   }
   if ((aMatrix->RowLength() != 4) || (aMatrix->ColLength() != 3))
-    Standard_DimensionMismatch::Raise
-  ("IGESGeom_TransformationMatrix : Init");
+    throw Standard_DimensionMismatch("IGESGeom_TransformationMatrix : Init");
 
   
   
@@ -55,8 +54,7 @@ IGESGeom_TransformationMatrix::IGESGeom_TransformationMatrix ()    {  }
 {
   if(theData.IsNull()) 
     cout<<"Inavalid Transformation Data"<<endl;
-  if ((fm < 0 || fm > 1) && (fm < 10 || fm > 12)) Standard_OutOfRange::Raise
-    ("IGESGeom_TransformationMatrix : SetFormNumber");
+  if ((fm < 0 || fm > 1) && (fm < 10 || fm > 12)) throw Standard_OutOfRange("IGESGeom_TransformationMatrix : SetFormNumber");
   InitTypeAndForm(124,fm);
 }
 
index 7c7810c..24cc2ba 100644 (file)
@@ -36,7 +36,7 @@ IGESGeom_TrimmedSurface::IGESGeom_TrimmedSurface ()    {  }
 {
   if (!anInner.IsNull())
     if (anInner->Lower() != 1)
-      Standard_DimensionMismatch::Raise("IGESGeom_TrimmedSurface : Init");
+      throw Standard_DimensionMismatch("IGESGeom_TrimmedSurface : Init");
 
   theSurface     = aSurface;
   theFlag        = aFlag;
index 4e63044..cb25768 100644 (file)
@@ -30,7 +30,7 @@ IGESGraph_DefinitionLevel::IGESGraph_DefinitionLevel ()    {  }
   (const Handle(TColStd_HArray1OfInteger)& allLevelNumbers)
 {
   if (allLevelNumbers->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESGraph_DefinitionLevel : Init");
+    throw Standard_DimensionMismatch("IGESGraph_DefinitionLevel : Init");
   theLevelNumbers = allLevelNumbers;
   InitTypeAndForm(406,1);
 }
index d763a35..7e45a1f 100644 (file)
@@ -34,7 +34,7 @@ IGESGraph_LineFontDefPattern::IGESGraph_LineFontDefPattern ()    {  }
    const Handle(TCollection_HAsciiString)&   aPattern)
 {
   if (allSegLength->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESGraph_LineFontDefPattern : Init");
+    throw Standard_DimensionMismatch("IGESGraph_LineFontDefPattern : Init");
   theSegmentLengths = allSegLength;
   theDisplayPattern = aPattern;
   InitTypeAndForm(304,2);
index 6621e90..e5bf6cf 100644 (file)
@@ -50,7 +50,7 @@ IGESGraph_TextFontDef::IGESGraph_TextFontDef ()    {  }
       (allPenFlags->Lower()   != 1 || allPenFlags->Length()   != Len) ||
       (allMovePenToX->Lower() != 1 || allMovePenToX->Length() != Len) ||
       (allMovePenToY->Lower() != 1 || allMovePenToY->Length() != Len) )
-    Standard_DimensionMismatch::Raise("IGESGraph_TextFontDef : Init");
+    throw Standard_DimensionMismatch("IGESGraph_TextFontDef : Init");
 
   theFontCode             = aFontCode;           
   theFontName             = aFontName; 
index 5315b1a..f72c4ea 100644 (file)
@@ -33,7 +33,7 @@ IGESSolid_BooleanTree::IGESSolid_BooleanTree ()    {  }
 {
   if (operands->Lower()  != 1 || operations->Lower() != 1 ||
       operands->Length() != operations->Length())
-    Standard_DimensionError::Raise("IGESSolid_BooleanTree : Init");
+    throw Standard_DimensionError("IGESSolid_BooleanTree : Init");
 
   theOperations = operations;
   theOperands   = operands;
index c3ae8ca..385b407 100644 (file)
@@ -42,7 +42,7 @@ IGESSolid_EdgeList::IGESSolid_EdgeList ()    {  }
       startVertexIndex->Lower() != 1 || startVertexIndex->Length() != nb ||
       endVertexList->Lower()    != 1 || endVertexList->Length()    != nb ||
       endVertexIndex->Lower()   != 1 || endVertexIndex->Length()   != nb  )
-    Standard_DimensionError::Raise("IGESSolid_EdgeList : Init");
+    throw Standard_DimensionError("IGESSolid_EdgeList : Init");
 
   theCurves = Curves;
   theStartVertexList  = startVertexList;
index 82c789f..52f7048 100644 (file)
@@ -34,7 +34,7 @@ IGESSolid_Face::IGESSolid_Face ()    {  }
    const Handle(IGESSolid_HArray1OfLoop)& Loops)
 {
   if (Loops->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESSolid_Face : Init");
+    throw Standard_DimensionMismatch("IGESSolid_Face : Init");
   theSurface   = aSurface;
   hasOuterLoop = OuterLoopFlag;
   theLoops     = Loops;
index e3ab009..1e9bfe2 100644 (file)
@@ -50,7 +50,7 @@ IGESSolid_Loop::IGESSolid_Loop ()    {  }
       nbParameterCurves->Lower() != 1 || nb != nbParameterCurves->Length() ||
       IsoparametricFlags->Lower() != 1 || nb != IsoparametricFlags->Length() ||
       Curves->Lower() != 1 || nb != Curves->Length() )
-    Standard_DimensionError::Raise("IGESSolid_Loop : Init");
+    throw Standard_DimensionError("IGESSolid_Loop : Init");
 
   theTypes  = Types;
   theEdges  = Edges;
index f6f3bf1..1325c84 100644 (file)
@@ -36,7 +36,7 @@ IGESSolid_ManifoldSolid::IGESSolid_ManifoldSolid ()    {  }
   if (!VoidShells.IsNull())
     if (VoidShells->Lower()  != 1 || VoidShellFlags->Lower() != 1 ||
        VoidShells->Length() != VoidShellFlags->Length())
-      Standard_DimensionError::Raise("IGESSolid_ManifoldSolid : Init");
+      throw Standard_DimensionError("IGESSolid_ManifoldSolid : Init");
 
   theShell           = aShell;
   theOrientationFlag = Shellflag;
index aaecb64..e35f47d 100644 (file)
@@ -33,7 +33,7 @@ IGESSolid_Shell::IGESSolid_Shell ()    {  }
 {
   if (Faces->Lower()  != 1 || Orient->Lower() != 1 ||
       Faces->Length() != Orient->Length())
-    Standard_DimensionError::Raise("IGESSolid_Shell : Init");
+    throw Standard_DimensionError("IGESSolid_Shell : Init");
 
   theFaces = Faces;
   theOrientation = Orient;
index 628576a..31e881a 100644 (file)
@@ -34,7 +34,7 @@ IGESSolid_SolidAssembly::IGESSolid_SolidAssembly ()    {  }
 {
   if (Items->Lower()  != 1 || Matrices->Lower() != 1 ||
       Items->Length() != Matrices->Length())
-    Standard_DimensionError::Raise("IGESSolid_SolidAssembly : Init");
+    throw Standard_DimensionError("IGESSolid_SolidAssembly : Init");
 
   theItems    = Items;
   theMatrices = Matrices;
index 2ba008d..27a1a39 100644 (file)
@@ -81,7 +81,7 @@ IGESSolid_TopoBuilder::IGESSolid_TopoBuilder ()    {  Clear();  }
 {
   if (curve.IsNull() || vstart <= 0 || vend <= 0 ||
       vstart > thepoint->Length() || vend > thepoint->Length())
-    Standard_DomainError::Raise ("IGESSolid_TopoBuilder : AddEdge");
+    throw Standard_DomainError("IGESSolid_TopoBuilder : AddEdge");
   thecur3d->Append (curve);
   thevstar->Append (vstart);
   thevend->Append  (vend);
@@ -150,7 +150,7 @@ IGESSolid_TopoBuilder::IGESSolid_TopoBuilder ()    {  Clear();  }
    const Standard_Integer orientation)
 {
   if (edge3d <= 0 || edge3d > thecur3d->Length())
-    Standard_DomainError::Raise ("IGESSolid_TopoBuilder : MakeEdge");
+    throw Standard_DomainError("IGESSolid_TopoBuilder : MakeEdge");
   theetype->Append (edgetype);
   thee3d->Append   (edge3d);
   theeflag->Append (orientation);
@@ -161,7 +161,7 @@ IGESSolid_TopoBuilder::IGESSolid_TopoBuilder ()    {  Clear();  }
   (const Handle(IGESData_IGESEntity)& curve, const Standard_Integer iso)
 {
   if (curve.IsNull() || thee3d->IsEmpty())
-    Standard_DomainError::Raise ("IGESSolid_TopoBuilder : AddCurveUV");
+    throw Standard_DomainError("IGESSolid_TopoBuilder : AddCurveUV");
   thecuruv->Append(curve);
   theisol->Append(iso);
 }
@@ -223,7 +223,7 @@ IGESSolid_TopoBuilder::IGESSolid_TopoBuilder ()    {  Clear();  }
   (const Handle(IGESData_IGESEntity)& surface)
 {
   if (surface.IsNull())
-    Standard_DomainError::Raise ("IGESSolid_TopoBuilder : MakeFace");
+    throw Standard_DomainError("IGESSolid_TopoBuilder : MakeFace");
   thesurf  = surface;
   theouter = Standard_False;
   theinner->Clear();
index fdc89cf..8aba4fc 100644 (file)
@@ -31,7 +31,7 @@ IGESSolid_VertexList::IGESSolid_VertexList ()    {  }
   (const Handle(TColgp_HArray1OfXYZ)& Vertices)
 {
   if (Vertices.IsNull() || Vertices->Lower() != 1)
-    Standard_DimensionMismatch::Raise("IGESSolid_VertexList : Init");
+    throw Standard_DimensionMismatch("IGESSolid_VertexList : Init");
   theVertices = Vertices;
   InitTypeAndForm(502,1);
 }
index f662924..732d63f 100644 (file)
@@ -303,11 +303,12 @@ Standard_Boolean IGESToBRep::IsBRepEntity(const Handle(IGESData_IGESEntity)& sta
          result = Standard_False;
        }
       }
-      catch(Standard_Failure) {
+      catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
        cout << "\n**IGESToBRep::TransferPCurve: Exception in SameRange : "; 
-       Standard_Failure::Caught()->Print(cout);
+       anException.Print(cout);
 #endif
+       (void)anException;
        result = Standard_False;
       }
     }
index 11b9269..877e901 100644 (file)
@@ -217,11 +217,12 @@ Handle(Geom_Curve) IGESToBRep_BasicCurve::TransferBasicCurve
     }
 
   } //:36
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout << "\n** Exception in IGESToBRep_BasicCurve::TransferBasicCurve : "; 
-    Standard_Failure::Caught()->Print(cout);
+    anException.Print(cout);
 #endif
+    (void)anException;
   }
   if (res.IsNull()) {
     // AddFail(start, "The IGESEntity cannot be transfered.");
@@ -280,11 +281,12 @@ Handle(Geom2d_Curve) IGESToBRep_BasicCurve::Transfer2dBasicCurve
       return res;
     }
   } //:h8
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout << "\n** Exception in IGESToBRep_BasicCurve::Transfer2dBasicCurve : "; 
-    Standard_Failure::Caught()->Print(cout);
+    anException.Print(cout);
 #endif
+    (void)anException;
   }
   return res;
 }
@@ -1088,11 +1090,12 @@ Handle(Geom_Curve) IGESToBRep_BasicCurve::TransferBSplineCurve
       else 
         BSplineRes = new Geom_BSplineCurve(Poles, Weight, Knot, Mult, Degree); 
     }
-    catch(Standard_Failure) {
+    catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
       cout << "\n** Exception in IGESToBRep_BasicCurve::TransferBSplineCurve during creation of Geom_BSplineCurve : "; 
-      Standard_Failure::Caught()->Print(cout);
+      anException.Print(cout);
 #endif
+      (void)anException;
     }
   }
   
index 88e9d69..d9aed32 100644 (file)
@@ -221,11 +221,12 @@ Handle(Geom_Surface) IGESToBRep_BasicSurface::TransferBasicSurface
     }
 
   } //:36
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout << "\n** Exception in IGESToBRep_BasicSurface::TransferBasicSurface : "; 
-    Standard_Failure::Caught()->Print(cout);
+    anException.Print(cout);
 #endif
+    (void)anException;
   }
 
   if (resurf.IsNull()) {
index b669668..b637c15 100644 (file)
@@ -781,13 +781,13 @@ TopoDS_Shape IGESToBRep_TopoSurface::TransferSurfaceOfRevolution
         }//if ( !aResultSurf.IsNull())
       }//if (extractCurve3d(generatrix, aBasisCurve))
     }
-    catch (Standard_Failure)
-    {
+    catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
       cout << "Warning: IgesToBRep_TopoSurface::"
                     "TransferSurfaceOfRevolution(): exception by Geom: ";
-      Standard_Failure::Caught()->Print ( cout ); cout << endl;
+      anException.Print ( cout ); cout << endl;
 #endif
+      (void)anException;
     }//catch (Standard_Failure)
   }
   
@@ -914,11 +914,12 @@ TopoDS_Shape IGESToBRep_TopoSurface::TransferTabulatedCylinder
       }
     }
   }
-  catch (Standard_Failure) {
+  catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout << "Warning: IgesToBRep_TopoSurface::TransferTabulatedCylinder(): exception by Geom: ";
-    Standard_Failure::Caught()->Print ( cout ); cout << endl;
+    anException.Print ( cout ); cout << endl;
 #endif
+    (void)anException;
   }
   }
   
index 67ca4fd..0d065c4 100644 (file)
@@ -85,7 +85,7 @@ void Image_PixMap::SetFormat (Image_PixMap::ImgFormat thePixelFormat)
   if (!IsEmpty()
     && SizePixelBytes (myImgFormat) != SizePixelBytes (thePixelFormat))
   {
-    Standard_ProgramError::Raise ("Image_PixMap::SetFormat() - incompatible pixel format");
+    throw Standard_ProgramError("Image_PixMap::SetFormat() - incompatible pixel format");
     return;
   }
 
index f644f73..1658010 100644 (file)
     }
   }
   else {
-    Standard_DomainError::Raise("IntAna_Curve::Domain");
+    throw Standard_DomainError("IntAna_Curve::Domain");
   }
 }
 //=======================================================================
      ((Theta>DomainSup*aRelTolp) && (!TwoCurves)) ||  
      (Theta>(DomainSup+DomainSup-DomainInf)*aRelTolp)) {
     SigneSqrtDis = 0.;
-    Standard_DomainError::Raise("IntAna_Curve::Domain");
+    throw Standard_DomainError("IntAna_Curve::Domain");
   }
   
   if(Theta>DomainSup) { 
                               const Standard_Real DSup) 
 {
   if(DInf>=DSup) {
-    Standard_DomainError::Raise("IntAna_Curve::Domain");
+    throw Standard_DomainError("IntAna_Curve::Domain");
   }
   //
   DomainInf=DInf;
index 72bd0a0..43aecf8 100644 (file)
@@ -23,14 +23,14 @@ inline Standard_Boolean IntAna_Int3Pln::IsDone () const {
 
 inline Standard_Boolean IntAna_Int3Pln::IsEmpty () const {
 
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return empt;
 }
 
 inline const gp_Pnt& IntAna_Int3Pln::Value () const {
 
-  if (!done) {StdFail_NotDone::Raise();}
-  if (empt) {Standard_DomainError::Raise();}
+  if (!done) {throw StdFail_NotDone();}
+  if (empt) {throw Standard_DomainError();}
   return pnt;
 }
 
index 01244ef..ecf588d 100644 (file)
@@ -22,20 +22,20 @@ inline Standard_Boolean IntAna_IntConicQuad::IsDone() const {
 
 
 inline Standard_Boolean IntAna_IntConicQuad::IsInQuadric() const {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return(inquadric);
 }
 
 
 inline Standard_Boolean IntAna_IntConicQuad::IsParallel() const {
-  if(!done) {StdFail_NotDone::Raise();}
+  if(!done) {throw StdFail_NotDone();}
   return(parallel);
 }
 
 
 inline Standard_Integer IntAna_IntConicQuad::NbPoints() const {
-  if(!done) {StdFail_NotDone::Raise();}
-  if (parallel || inquadric) {Standard_DomainError::Raise();}
+  if(!done) {throw StdFail_NotDone();}
+  if (parallel || inquadric) {throw Standard_DomainError();}
   return(nbpts);
 }
 
@@ -43,9 +43,9 @@ inline Standard_Integer IntAna_IntConicQuad::NbPoints() const {
 inline const gp_Pnt& IntAna_IntConicQuad::Point
   (const Standard_Integer i) const {
 
-  if(!done) {StdFail_NotDone::Raise();}
-  if (parallel || inquadric) {Standard_DomainError::Raise();}
-  if((i>nbpts)||(i<=0)) {Standard_OutOfRange::Raise();}
+  if(!done) {throw StdFail_NotDone();}
+  if (parallel || inquadric) {throw Standard_DomainError();}
+  if((i>nbpts)||(i<=0)) {throw Standard_OutOfRange();}
   return(pnts[i-1]);
 }
 
@@ -53,8 +53,8 @@ inline const gp_Pnt& IntAna_IntConicQuad::Point
 inline Standard_Real IntAna_IntConicQuad::ParamOnConic
   (const Standard_Integer i) const {  
 
-  if(!done) {StdFail_NotDone::Raise();}
-  if (parallel || inquadric) {Standard_DomainError::Raise();}
-  if((i>nbpts)||(i<=0)) {Standard_OutOfRange::Raise();}
+  if(!done) {throw StdFail_NotDone();}
+  if (parallel || inquadric) {throw Standard_DomainError();}
+  if((i>nbpts)||(i<=0)) {throw Standard_OutOfRange();}
   return(paramonc[i-1]);
 }
index 6854a0d..f8c5192 100644 (file)
@@ -20,23 +20,23 @@ inline Standard_Boolean IntAna_IntLinTorus::IsDone () const {
 }
 
 inline Standard_Integer IntAna_IntLinTorus::NbPoints () const {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return nbpt;
 }
 
 inline const gp_Pnt& IntAna_IntLinTorus::Value
   (const Standard_Integer Index) const {
 
-  if (!done) {StdFail_NotDone::Raise();}
-  if(Index<=0 || Index>nbpt) { Standard_OutOfRange::Raise();}
+  if (!done) {throw StdFail_NotDone();}
+  if(Index<=0 || Index>nbpt) { throw Standard_OutOfRange();}
   return thePoint[Index-1];
 }
 
 inline Standard_Real IntAna_IntLinTorus::ParamOnLine 
   (const Standard_Integer Index) const {
 
-  if (!done) {StdFail_NotDone::Raise();}
-  if(Index<=0 || Index>nbpt) { Standard_OutOfRange::Raise();}
+  if (!done) {throw StdFail_NotDone();}
+  if(Index<=0 || Index>nbpt) { throw Standard_OutOfRange();}
   return theParam[Index-1];
 }
 
@@ -44,8 +44,8 @@ inline void IntAna_IntLinTorus::ParamOnTorus
     (const Standard_Integer Index, 
      Standard_Real& FI, Standard_Real& THETA) const {
 
-  if (!done) {StdFail_NotDone::Raise();}
-  if(Index<=0 || Index>nbpt) { Standard_OutOfRange::Raise();}
+  if (!done) {throw StdFail_NotDone();}
+  if(Index<=0 || Index>nbpt) { throw Standard_OutOfRange();}
   FI=theFi[Index-1];
   THETA=theTheta[Index-1];
 }
index 361add7..b9c0ec9 100644 (file)
@@ -84,21 +84,21 @@ class TrigonometricRoots {
   //NbSolutions
   Standard_Integer NbSolutions() { 
     if(!done) {
-      StdFail_NotDone::Raise();
+      throw StdFail_NotDone();
     }
     return NbRoots; 
   }
   //InfiniteRoots
   Standard_Boolean InfiniteRoots() { 
     if(!done) {
-      StdFail_NotDone::Raise();
+      throw StdFail_NotDone();
     }    
     return infinite_roots; 
   }
   //Value
   Standard_Real Value(const Standard_Integer n) {
     if((!done)||(n>NbRoots)) {
-      StdFail_NotDone::Raise();
+      throw StdFail_NotDone();
     }    
     return Roots[n-1];
   }
@@ -1051,13 +1051,13 @@ void IntAna_IntQuadQuad::InternalSetNextAndPrevious()
 Standard_Boolean IntAna_IntQuadQuad::HasPreviousCurve(const Standard_Integer I) const
 {
   if(!done) {
-    StdFail_NotDone::Raise("IntQuadQuad Not done");
+    throw StdFail_NotDone("IntQuadQuad Not done");
   }  
   if (identical) {
-    Standard_DomainError::Raise("IntQuadQuad identical");
+    throw Standard_DomainError("IntQuadQuad identical");
   }
   if((I>NbCurves)||(I<=0)) {
-    Standard_OutOfRange::Raise("Incorrect Curve Number 'HasPrevious Curve'");
+    throw Standard_OutOfRange("Incorrect Curve Number 'HasPrevious Curve'");
   }
   if(previouscurve[I-1]) {
     return Standard_True;
@@ -1071,13 +1071,13 @@ Standard_Boolean IntAna_IntQuadQuad::HasPreviousCurve(const Standard_Integer I)
 Standard_Boolean IntAna_IntQuadQuad::HasNextCurve(const Standard_Integer I) const
 {
   if(!done) {
-    StdFail_NotDone::Raise("IntQuadQuad Not done");
+    throw StdFail_NotDone("IntQuadQuad Not done");
   }  
   if (identical) {
-    Standard_DomainError::Raise("IntQuadQuad identical");
+    throw Standard_DomainError("IntQuadQuad identical");
   }
   if((I>NbCurves)||(I<=0)) {
-    Standard_OutOfRange::Raise("Incorrect Curve Number 'HasNextCurve'");
+    throw Standard_OutOfRange("Incorrect Curve Number 'HasNextCurve'");
   }
   if(nextcurve[I-1]) {
     return Standard_True;
@@ -1102,7 +1102,7 @@ Standard_Integer IntAna_IntQuadQuad::PreviousCurve  (const Standard_Integer I,
     }
   }
   else {
-    Standard_DomainError::Raise("Incorrect Curve Number 'PreviousCurve'"); return(0);
+    throw Standard_DomainError("Incorrect Curve Number 'PreviousCurve'");
   }
 }
 //=======================================================================
@@ -1123,8 +1123,7 @@ Standard_Integer IntAna_IntQuadQuad::NextCurve (const Standard_Integer I,
     }
   }
   else {
-    Standard_DomainError::Raise("Incorrect Curve Number 'NextCurve'"); 
-    return(0);
+    throw Standard_DomainError("Incorrect Curve Number 'NextCurve'");
   }
 }
 //=======================================================================
@@ -1134,13 +1133,13 @@ Standard_Integer IntAna_IntQuadQuad::NextCurve (const Standard_Integer I,
 const IntAna_Curve& IntAna_IntQuadQuad::Curve(const Standard_Integer i) const
 {
   if(!done) {
-    StdFail_NotDone::Raise("IntQuadQuad Not done");
+    throw StdFail_NotDone("IntQuadQuad Not done");
   }
   if (identical) {
-    Standard_DomainError::Raise("IntQuadQuad identical");
+    throw Standard_DomainError("IntQuadQuad identical");
   }
   if((i <= 0) || (i>NbCurves)) {
-    Standard_OutOfRange::Raise("Incorrect Curve Number");
+    throw Standard_OutOfRange("Incorrect Curve Number");
   }
   return TheCurve[i-1];
 }
@@ -1151,13 +1150,13 @@ const IntAna_Curve& IntAna_IntQuadQuad::Curve(const Standard_Integer i) const
 const gp_Pnt& IntAna_IntQuadQuad::Point (const Standard_Integer i) const
 {
   if(!done) {
-    StdFail_NotDone::Raise("IntQuadQuad Not done");
+    throw StdFail_NotDone("IntQuadQuad Not done");
   }  
   if (identical) {
-    Standard_DomainError::Raise("IntQuadQuad identical");
+    throw Standard_DomainError("IntQuadQuad identical");
   }
   if((i <= 0) || (i>Nbpoints)) {
-    Standard_OutOfRange::Raise("Incorrect Point Number");
+    throw Standard_OutOfRange("Incorrect Point Number");
   }
   return Thepoints[i-1];
 }
index 9a23f55..837070a 100644 (file)
@@ -21,20 +21,20 @@ inline Standard_Boolean IntAna_IntQuadQuad::IsDone () const
 }
 
 inline Standard_Boolean IntAna_IntQuadQuad::IdenticalElements () const { 
-  if(!done) {StdFail_NotDone::Raise("IntQuadQuad Not done");}
+  if(!done) {throw StdFail_NotDone("IntQuadQuad Not done");}
   return(identical); 
 }
 
 inline Standard_Integer IntAna_IntQuadQuad::NbCurve () const { 
-  if(!done) {StdFail_NotDone::Raise("IntQuadQuad Not done");}
-  if (identical) {Standard_DomainError::Raise();}
+  if(!done) {throw StdFail_NotDone("IntQuadQuad Not done");}
+  if (identical) {throw Standard_DomainError();}
   return(NbCurves); 
 }
 
 inline Standard_Integer IntAna_IntQuadQuad::NbPnt () const
 {
-  if(!done) {StdFail_NotDone::Raise("IntQuadQuad Not done");}
-  if (identical) {Standard_DomainError::Raise();}
+  if(!done) {throw StdFail_NotDone("IntQuadQuad Not done");}
+  if (identical) {throw Standard_DomainError();}
   return(Nbpoints);
 }
 
index cd39195..f015b93 100644 (file)
@@ -2549,10 +2549,10 @@ void IntAna_QuadQuadGeo::Perform(const gp_Torus& Tor1,
 //=======================================================================
   gp_Pnt IntAna_QuadQuadGeo::Point(const Standard_Integer n) const 
 {
-  if(!done)          {    StdFail_NotDone::Raise();        }
-  if(n>nbint || n<1) {    Standard_DomainError::Raise();   }
+  if(!done)          {    throw StdFail_NotDone();        }
+  if(n>nbint || n<1) {    throw Standard_DomainError();   }
   if(typeres==IntAna_PointAndCircle) {
-    if(n!=1) { Standard_DomainError::Raise();  }
+    if(n!=1) { throw Standard_DomainError();  }
     if(param1==0.0) return(pt1);
     return(pt2);
   }
@@ -2570,9 +2570,9 @@ void IntAna_QuadQuadGeo::Perform(const gp_Torus& Tor1,
 //=======================================================================
   gp_Lin IntAna_QuadQuadGeo::Line(const Standard_Integer n) const 
 {
-  if(!done)        {   StdFail_NotDone::Raise();   }
+  if(!done)        {   throw StdFail_NotDone();   }
   if((n>nbint) || (n<1) || (typeres!=IntAna_Line)) {
-    Standard_DomainError::Raise();
+    throw Standard_DomainError();
     }
   if(n==1) {  return(gp_Lin(pt1,dir1));   }
   else {      return(gp_Lin(pt2,dir2));   }
@@ -2583,14 +2583,14 @@ void IntAna_QuadQuadGeo::Perform(const gp_Torus& Tor1,
 //=======================================================================
   gp_Circ IntAna_QuadQuadGeo::Circle(const Standard_Integer n) const 
 {
-  if(!done) {    StdFail_NotDone::Raise();     }
+  if(!done) {    throw StdFail_NotDone();     }
   if(typeres==IntAna_PointAndCircle) {
-    if(n!=1) { Standard_DomainError::Raise();  }
+    if(n!=1) { throw Standard_DomainError();  }
     if(param2==0.0) return(gp_Circ(DirToAx2(pt1,dir1),param1));
     return(gp_Circ(DirToAx2(pt2,dir2),param2));
   }
   else if((n>nbint) || (n<1) || (typeres!=IntAna_Circle)) {
-    Standard_DomainError::Raise();
+    throw Standard_DomainError();
     }
   if      (n==1) { return(gp_Circ(DirToAx2(pt1,dir1),param1));}
   else if (n==2) { return(gp_Circ(DirToAx2(pt2,dir2),param2));}
@@ -2604,9 +2604,9 @@ void IntAna_QuadQuadGeo::Perform(const gp_Torus& Tor1,
 //=======================================================================
   gp_Elips IntAna_QuadQuadGeo::Ellipse(const Standard_Integer n) const
 {
-  if(!done) {     StdFail_NotDone::Raise();     }
+  if(!done) {     throw StdFail_NotDone();     }
   if((n>nbint) || (n<1) || (typeres!=IntAna_Ellipse)) {
-    Standard_DomainError::Raise();
+    throw Standard_DomainError();
   }
 
   if(n==1) {
@@ -2635,13 +2635,13 @@ void IntAna_QuadQuadGeo::Perform(const gp_Torus& Tor1,
   gp_Parab IntAna_QuadQuadGeo::Parabola(const Standard_Integer n) const 
 {
   if(!done) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
     }
   if (typeres!=IntAna_Parabola) {
-    Standard_DomainError::Raise();
+    throw Standard_DomainError();
   }
   if((n>nbint) || (n!=1)) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return(gp_Parab(gp_Ax2( pt1
                          ,dir1
@@ -2655,10 +2655,10 @@ void IntAna_QuadQuadGeo::Perform(const gp_Torus& Tor1,
   gp_Hypr IntAna_QuadQuadGeo::Hyperbola(const Standard_Integer n) const 
 {
   if(!done) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
     }
   if((n>nbint) || (n<1) || (typeres!=IntAna_Hyperbola)) {
-    Standard_DomainError::Raise();
+    throw Standard_DomainError();
     }
   if(n==1) {
     return(gp_Hypr(gp_Ax2( pt1
index afa8c11..2667a55 100644 (file)
@@ -20,12 +20,12 @@ inline Standard_Boolean IntAna_QuadQuadGeo::IsDone() const {
 
 
 inline IntAna_ResultType IntAna_QuadQuadGeo::TypeInter()  const {
-  if(!done) {StdFail_NotDone::Raise();}
+  if(!done) {throw StdFail_NotDone();}
   return(typeres);
 }
 
 inline Standard_Integer IntAna_QuadQuadGeo::NbSolutions() const {
-  if(!done) {StdFail_NotDone::Raise();}
+  if(!done) {throw StdFail_NotDone();}
   return(nbint);
 }
 
index 41b9d18..5da53cf 100644 (file)
@@ -22,7 +22,7 @@ inline Standard_Boolean IntAna2d_AnaIntersection::IsDone () const {
 inline Standard_Boolean IntAna2d_AnaIntersection::IsEmpty () const {
   
   if (!done) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   return ((nbp==0)&&(!iden));
 }
@@ -30,7 +30,7 @@ inline Standard_Boolean IntAna2d_AnaIntersection::IsEmpty () const {
 inline Standard_Boolean IntAna2d_AnaIntersection::IdenticalElements () const {
   
   if (!done) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   return iden ;
 }
@@ -38,7 +38,7 @@ inline Standard_Boolean IntAna2d_AnaIntersection::IdenticalElements () const {
 inline Standard_Boolean IntAna2d_AnaIntersection::ParallelElements () const {
   
   if (!done) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   return para ;
 }
@@ -46,7 +46,7 @@ inline Standard_Boolean IntAna2d_AnaIntersection::ParallelElements () const {
 inline Standard_Integer IntAna2d_AnaIntersection::NbPoints () const {
   
   if (!done) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   return nbp ;
 }
@@ -54,13 +54,11 @@ inline Standard_Integer IntAna2d_AnaIntersection::NbPoints () const {
 inline const IntAna2d_IntPoint& IntAna2d_AnaIntersection::Point (const Standard_Integer N) const {
   
   if (!done) {
-    StdFail_NotDone::Raise();
-    return lpnt[0];
+    throw StdFail_NotDone();
   }
   else {
     if ((N<=0)||(N>nbp)) {
-      Standard_OutOfRange::Raise();
-      return lpnt[0];
+      throw Standard_OutOfRange();
     }
     else {
       return lpnt[N-1];
index 42adc3a..7fa0d44 100644 (file)
@@ -28,7 +28,7 @@ inline Standard_Real IntAna2d_IntPoint::ParamOnFirst () const {
 inline Standard_Real IntAna2d_IntPoint::ParamOnSecond () const {
 
   if (myimplicit) {
-    Standard_DomainError::Raise();
+    throw Standard_DomainError();
   }
   return myu2;
 }
index 15622b4..068fa2a 100644 (file)
@@ -1863,7 +1863,7 @@ void IntCurve_IntConicConic::Perform(const gp_Lin2d& Line
                                     ,const Standard_Real TolConf,const Standard_Real Tol) {
 
 //--  if(! CIRC_Domain.IsClosed()) {
-//--    Standard_ConstructionError::Raise("Domaine incorrect");
+//--    throw Standard_ConstructionError("Domaine incorrect");
 //--  }
 
   Standard_Boolean TheReversedParameters=ReversedParameters();
index 7da075f..74cef08 100644 (file)
@@ -30,7 +30,7 @@ IntCurve_IntConicCurveGen::IntCurve_IntConicCurveGen (const gp_Circ2d& C,
     IntRes2d_Domain D(D1);
     D.SetEquivalentParameters(D1.FirstParameter(),D1.FirstParameter()+M_PI+M_PI);
     Perform(IntCurve_IConicTool(C),D,PCurve,D2,TolConf,Tol);
-    //-- Standard_ConstructionError::Raise("Domaine incorrect");
+    //-- throw Standard_ConstructionError("Domaine incorrect");
   }
   else { 
     Perform(IntCurve_IConicTool(C),D1,PCurve,D2,TolConf,Tol);
@@ -47,7 +47,7 @@ IntCurve_IntConicCurveGen::IntCurve_IntConicCurveGen (const gp_Elips2d& E,
     IntRes2d_Domain D(D1);
     D.SetEquivalentParameters(D1.FirstParameter(),D1.FirstParameter()+M_PI+M_PI);
     Perform(IntCurve_IConicTool(E),D,PCurve,D2,TolConf,Tol);
-    //-- Standard_ConstructionError::Raise("Domaine incorrect");
+    //-- throw Standard_ConstructionError("Domaine incorrect");
   }
   else { 
     Perform(IntCurve_IConicTool(E),D1,PCurve,D2,TolConf,Tol);
index c1ecfc2..5e5885c 100644 (file)
@@ -63,7 +63,7 @@ inline void IntCurve_IntConicCurveGen::Perform (const gp_Circ2d& C,
     IntRes2d_Domain D(D1);
     D.SetEquivalentParameters(D1.FirstParameter(),D1.FirstParameter()+M_PI+M_PI);
     Perform(IntCurve_IConicTool(C),D,PCurve,D2,TolConf,Tol);
-    //-- Standard_ConstructionError::Raise("Domaine incorrect");
+    //-- throw Standard_ConstructionError("Domaine incorrect");
   }
   else { 
     Perform(IntCurve_IConicTool(C),D1,PCurve,D2,TolConf,Tol);
index 8f20b5a..b9b1117 100644 (file)
@@ -333,7 +333,7 @@ void IntCurve_Polygon2dGen::Segment(const Standard_Integer theIndex,
   theBegin = ThePnts(TheIndex(theIndex));
   if (theIndex >= NbPntIn) {
     if (!ClosedPolygon)
-      Standard_OutOfRange::Raise("IntCurve_Polygon2dGen::Segment!");
+      throw Standard_OutOfRange("IntCurve_Polygon2dGen::Segment!");
     ind = 0;
   }
   theEnd = ThePnts(TheIndex(ind+1));
index d9ca50c..a8da4f3 100644 (file)
@@ -31,22 +31,22 @@ IntCurveSurface_Intersection::IntCurveSurface_Intersection(): done(Standard_Fals
 Standard_Boolean IntCurveSurface_Intersection::IsDone() const { return(done); } 
 //================================================================================
 Standard_Integer IntCurveSurface_Intersection::NbPoints() const { 
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return lpnt.Length();
 }
 //================================================================================
 Standard_Integer IntCurveSurface_Intersection::NbSegments() const { 
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return lseg.Length();
 }
 //================================================================================
 const IntCurveSurface_IntersectionPoint& IntCurveSurface_Intersection::Point( const Standard_Integer N) const {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return lpnt.Value(N);
 }
 //================================================================================
 const IntCurveSurface_IntersectionSegment& IntCurveSurface_Intersection::Segment( const Standard_Integer N) const {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return lseg.Value(N);
 }
 //================================================================================
index 63ec244..bcfa81a 100644 (file)
 
 //Standard_IMPORT extern IntImp_ConstIsoparametric   *ChoixRef;
 
-
-IntImp_Int2S::IntImp_Int2S() { 
-  Standard_ConstructionError::Raise(" Empty Constructor : IntImp_Int2S");
-}
-
-
 IntImp_Int2S::IntImp_Int2S(const ThePSurface& surf1,
                            const ThePSurface& surf2,
                            const Standard_Real TolTangency ) :
index f7dfaf9..2c087ae 100644 (file)
@@ -21,48 +21,45 @@ inline Standard_Boolean IntImp_Int2S::IsDone()const { return done;}
 
 inline Standard_Boolean IntImp_Int2S::IsEmpty() const
 { 
-  if (!done) StdFail_NotDone::Raise(" IntImp_Int2S::IsEmpty() ");
+  if (!done) throw StdFail_NotDone(" IntImp_Int2S::IsEmpty() ");
   return empty;
 }
 
 inline const IntSurf_PntOn2S& IntImp_Int2S::Point() const
 { 
-  if (!done) StdFail_NotDone::Raise(" IntImp_Int2S::Point() ");
-  if (empty) Standard_DomainError::Raise(" IntImp_Int2S::Point() ");
+  if (!done) throw StdFail_NotDone(" IntImp_Int2S::Point() ");
+  if (empty) throw Standard_DomainError(" IntImp_Int2S::Point() ");
   return pint;
 }
 
 inline Standard_Boolean IntImp_Int2S::IsTangent () const {
 
-  if (!done) StdFail_NotDone::Raise(" IntImp_Int2S::IsTangent () ");
-  if (empty) Standard_DomainError::Raise(" IntImp_Int2S::IsTangent () ");
+  if (!done) throw StdFail_NotDone(" IntImp_Int2S::IsTangent () ");
+  if (empty) throw Standard_DomainError(" IntImp_Int2S::IsTangent () ");
   return tangent;
 }
 
 inline const gp_Dir& IntImp_Int2S::Direction () const {
 
-  if (!done) StdFail_NotDone::Raise(" IntImp_Int2S::Direction () ");
-  if (empty) Standard_DomainError::Raise(" IntImp_Int2S::Direction () ");
-  if (tangent) StdFail_UndefinedDerivative::Raise
-    (" IntImp_Int2S::Direction () ");
+  if (!done) throw StdFail_NotDone(" IntImp_Int2S::Direction () ");
+  if (empty) throw Standard_DomainError(" IntImp_Int2S::Direction () ");
+  if (tangent) throw StdFail_UndefinedDerivative(" IntImp_Int2S::Direction () ");
   return d3d;
 }
 
 inline const gp_Dir2d& IntImp_Int2S::DirectionOnS1 () const {
 
-  if (!done) StdFail_NotDone::Raise(" IntImp_Int2S::DirectionOnS1 () ");
-  if (empty) Standard_DomainError::Raise(" IntImp_Int2S::DirectionOnS1 () ");
-  if (tangent) StdFail_UndefinedDerivative::Raise
-    (" IntImp_Int2S::DirectionOnS1 () ");
+  if (!done) throw StdFail_NotDone(" IntImp_Int2S::DirectionOnS1 () ");
+  if (empty) throw Standard_DomainError(" IntImp_Int2S::DirectionOnS1 () ");
+  if (tangent) throw StdFail_UndefinedDerivative(" IntImp_Int2S::DirectionOnS1 () ");
   return d2d1;
 }
 
 inline const gp_Dir2d& IntImp_Int2S::DirectionOnS2 () const {
 
-  if (!done) StdFail_NotDone::Raise(" IntImp_Int2S::DirectionOnS2 () ");
-  if (empty) Standard_DomainError::Raise(" IntImp_Int2S::DirectionOnS2 () ");
-  if (tangent) StdFail_UndefinedDerivative::Raise
-    (" IntImp_Int2S::DirectionOnS2 () ");
+  if (!done) throw StdFail_NotDone(" IntImp_Int2S::DirectionOnS2 () ");
+  if (empty) throw Standard_DomainError(" IntImp_Int2S::DirectionOnS2 () ");
+  if (tangent) throw StdFail_UndefinedDerivative(" IntImp_Int2S::DirectionOnS2 () ");
   return d2d2;
 }
 
index 9dfb201..bc56346 100644 (file)
@@ -131,29 +131,29 @@ void IntImp_IntCS::Perform(const Standard_Real U,
 Standard_Boolean IntImp_IntCS::IsDone() const { return done;}
 
 Standard_Boolean IntImp_IntCS::IsEmpty()const { 
-  if (!done) StdFail_NotDone::Raise();
+  if (!done) throw StdFail_NotDone();
   return empty;
 }
 
 const gp_Pnt& IntImp_IntCS::Point() const
 { 
-  if (!done) StdFail_NotDone::Raise();
-  if (empty) Standard_DomainError::Raise();
+  if (!done) throw StdFail_NotDone();
+  if (empty) throw Standard_DomainError();
   return myFunction.Point();
 }
 
 void IntImp_IntCS::ParameterOnSurface(Standard_Real& U,
                                      Standard_Real& V) const
 { 
-  if (!done) StdFail_NotDone::Raise();
-  if (empty) Standard_DomainError::Raise();
+  if (!done) throw StdFail_NotDone();
+  if (empty) throw Standard_DomainError();
   U=u;
   V=v;
 }
 Standard_Real  IntImp_IntCS::ParameterOnCurve() const
 { 
-  if (!done) StdFail_NotDone::Raise();
-  if (empty) Standard_DomainError::Raise();
+  if (!done) throw StdFail_NotDone();
+  if (empty) throw Standard_DomainError();
   return w;
 }
 
index 5c5e0e7..353f8b4 100644 (file)
@@ -46,13 +46,13 @@ inline const gp_Pnt& IntImp_ZerImpFunc::Point() const
 
 inline const gp_Vec& IntImp_ZerImpFunc::Direction3d()
 {
-  if (IsTangent()) StdFail_UndefinedDerivative::Raise();       
+  if (IsTangent()) throw StdFail_UndefinedDerivative();
   return d3d;
 }
 
 inline const gp_Dir2d& IntImp_ZerImpFunc::Direction2d()
 {
-  if (IsTangent()) StdFail_UndefinedDerivative::Raise();       
+  if (IsTangent()) throw StdFail_UndefinedDerivative();
   return d2d;
 }
 
index b620835..5502295 100644 (file)
 #define SURF2 (*((ThePSurface *)(surf2)))
 
 
-IntImp_ZerParFunc::IntImp_ZerParFunc() { 
-  Standard_ConstructionError::Raise(" Empty Constructor : IntImp_ZerParFunc");
-}
-
 IntImp_ZerParFunc::IntImp_ZerParFunc(const ThePSurface& S1 ,
                                     const ThePSurface& S2) {
     surf1 = (Standard_Address)(&S1);
index 74fd09a..c7c2227 100644 (file)
@@ -29,17 +29,17 @@ inline gp_Pnt IntImp_ZerParFunc::Point() const {
 }
 
 inline gp_Dir IntImp_ZerParFunc::Direction() const {
-  if (tangent ) StdFail_UndefinedDerivative::Raise();
+  if (tangent ) throw StdFail_UndefinedDerivative();
   return gp_Dir(tgduv[0]*dpuv[0].XYZ() + tgduv[1]*dpuv[1].XYZ());
 }
 
 inline gp_Dir2d IntImp_ZerParFunc::DirectionOnS1() const {
-  if (tangent ) StdFail_UndefinedDerivative::Raise();       
+  if (tangent ) throw StdFail_UndefinedDerivative();
   return gp_Dir2d(tgduv[0],tgduv[1]);
 }
 
 inline gp_Dir2d IntImp_ZerParFunc::DirectionOnS2() const {
-  if (tangent ) StdFail_UndefinedDerivative::Raise();       
+  if (tangent ) throw StdFail_UndefinedDerivative();
   return gp_Dir2d(tgduv[2],tgduv[3]);
 }
 
index 756895c..cd02df9 100644 (file)
@@ -243,7 +243,7 @@ void IntImpParGen_Intersector::Perform(const ImpTool& TheImpTool,
 
   if (!(TheParCurveDomain.HasFirstPoint() &&
     TheParCurveDomain.HasLastPoint())) {
-    Standard_ConstructionError::Raise("Domaine sur courbe incorrect");
+    throw Standard_ConstructionError("Domaine sur courbe incorrect");
   }
 
   Standard_Integer nb_echantillons = ParTool::NbSamples(TheParCurve,
index 346edfd..629f0b1 100644 (file)
@@ -79,13 +79,13 @@ inline Standard_Boolean IntPatch_ALine::HasLastPoint () const
 
 inline const IntPatch_Point& IntPatch_ALine::FirstPoint () const
 {
-  if (!fipt) {Standard_DomainError::Raise();}
+  if (!fipt) {throw Standard_DomainError();}
   return svtx(indf);
 }
 
 inline const IntPatch_Point& IntPatch_ALine::LastPoint () const
 {
-  if (!lapt) {Standard_DomainError::Raise();}
+  if (!lapt) {throw Standard_DomainError();}
   return svtx(indl);
 }
 
index 5473849..bf630f8 100644 (file)
@@ -41,35 +41,35 @@ inline void IntPatch_GLine::SetLastPoint (const Standard_Integer IndLast)
 
 inline gp_Lin IntPatch_GLine::Line () const
 {
-  if (typ != IntPatch_Lin) {Standard_DomainError::Raise();}
+  if (typ != IntPatch_Lin) {throw Standard_DomainError();}
   return gp_Lin(pos.Axis());
 }
 
 
 inline gp_Circ IntPatch_GLine::Circle () const
 {
-  if (typ != IntPatch_Circle) {Standard_DomainError::Raise();}
+  if (typ != IntPatch_Circle) {throw Standard_DomainError();}
   return gp_Circ(pos,par1);
 }
 
 
 inline gp_Elips IntPatch_GLine::Ellipse () const
 {
-  if (typ != IntPatch_Ellipse) {Standard_DomainError::Raise();}
+  if (typ != IntPatch_Ellipse) {throw Standard_DomainError();}
   return gp_Elips(pos,par1,par2);
 }
 
 
 inline gp_Parab IntPatch_GLine::Parabola () const
 {
-  if (typ != IntPatch_Parabola) {Standard_DomainError::Raise();}
+  if (typ != IntPatch_Parabola) {throw Standard_DomainError();}
   return gp_Parab(pos,par1);
 }
 
 
 inline gp_Hypr IntPatch_GLine::Hyperbola () const
 {
-  if (typ != IntPatch_Hyperbola) {Standard_DomainError::Raise();}
+  if (typ != IntPatch_Hyperbola) {throw Standard_DomainError();}
   return gp_Hypr(pos,par1,par2);
 }
 
@@ -88,14 +88,14 @@ inline Standard_Boolean IntPatch_GLine::HasLastPoint () const
 
 inline const IntPatch_Point& IntPatch_GLine::FirstPoint () const
 {
-  if (!fipt) {Standard_DomainError::Raise();}
+  if (!fipt) {throw Standard_DomainError();}
   return svtx(indf);
 }
 
 
 inline const IntPatch_Point& IntPatch_GLine::LastPoint () const
 {
-  if (!lapt) {Standard_DomainError::Raise();}
+  if (!lapt) {throw Standard_DomainError();}
   return svtx(indl);
 }
 
index 1b2faa4..7ad540c 100644 (file)
@@ -289,7 +289,7 @@ void IntPatch_HInterTool::Value(const Handle(Adaptor2d_HCurve2d)&,
                                 Standard_Real&,
                                 Standard_Real&)
 {
-  Standard_OutOfRange::Raise();
+  throw Standard_OutOfRange();
 }
 
 Standard_Boolean IntPatch_HInterTool::IsVertex(const Handle(Adaptor2d_HCurve2d)&,
@@ -302,7 +302,7 @@ void IntPatch_HInterTool::Vertex(const Handle(Adaptor2d_HCurve2d)&,
                                  const Standard_Integer,
                                  Handle(Adaptor3d_HVertex)&)
 {
-  Standard_OutOfRange::Raise();
+  throw Standard_OutOfRange();
 }
 
 Standard_Integer IntPatch_HInterTool::NbSegments(const Handle(Adaptor2d_HCurve2d)&)
@@ -314,16 +314,14 @@ Standard_Boolean IntPatch_HInterTool::HasFirstPoint (const Handle(Adaptor2d_HCur
                                                      const Standard_Integer,
                                                      Standard_Integer&)
 {
-  Standard_OutOfRange::Raise();
-  return Standard_False;
+  throw Standard_OutOfRange();
 }
 
 Standard_Boolean IntPatch_HInterTool::HasLastPoint (const Handle(Adaptor2d_HCurve2d)&,
                                                     const Standard_Integer,
                                                     Standard_Integer&)
 {
-  Standard_OutOfRange::Raise();
-  return Standard_False;
+  throw Standard_OutOfRange();
 }
 
 Standard_Boolean IntPatch_HInterTool::IsAllSolution (const Handle(Adaptor2d_HCurve2d)&)
index 26cf77f..b43026b 100644 (file)
@@ -31,43 +31,43 @@ inline IntPatch_ImpImpIntersection::IntStatus
 
 inline Standard_Boolean IntPatch_ImpImpIntersection::IsEmpty () const
 {
-  if (!IsDone ()) { StdFail_NotDone::Raise(); }
+  if (!IsDone ()) { throw StdFail_NotDone(); }
   return empt;
 }
 
 inline Standard_Boolean IntPatch_ImpImpIntersection::TangentFaces () const
 {
-  if (!IsDone ()) { StdFail_NotDone::Raise(); }
+  if (!IsDone ()) { throw StdFail_NotDone(); }
   return tgte;
 }
 
 inline Standard_Boolean IntPatch_ImpImpIntersection::OppositeFaces () const
 {
-  if (!IsDone ()) { StdFail_NotDone::Raise(); }
-  if (!tgte) {Standard_DomainError::Raise();}
+  if (!IsDone ()) { throw StdFail_NotDone(); }
+  if (!tgte) {throw Standard_DomainError();}
   return oppo;
 }
 
 inline Standard_Integer IntPatch_ImpImpIntersection::NbPnts () const
 {
-  if (!IsDone ()) { StdFail_NotDone::Raise(); }
+  if (!IsDone ()) { throw StdFail_NotDone(); }
   return spnt.Length();
 }
 
 inline const IntPatch_Point& IntPatch_ImpImpIntersection::Point (const Standard_Integer Index) const
 {
-  if (!IsDone ()) { StdFail_NotDone::Raise(); }
+  if (!IsDone ()) { throw StdFail_NotDone(); }
   return spnt(Index);
 }
 
 inline Standard_Integer IntPatch_ImpImpIntersection::NbLines () const
 {
-  if (!IsDone ()) { StdFail_NotDone::Raise(); }
+  if (!IsDone ()) { throw StdFail_NotDone(); }
   return slin.Length();
 }
 
 inline const Handle(IntPatch_Line)& IntPatch_ImpImpIntersection::Line (const Standard_Integer Index) const
 {
-  if (!IsDone ()) { StdFail_NotDone::Raise(); }
+  if (!IsDone ()) { throw StdFail_NotDone(); }
   return slin(Index);
 }
index 27560c6..2567933 100644 (file)
@@ -90,7 +90,7 @@ void IntPatch_ImpImpIntersection::Perform(const Handle(Adaptor3d_HSurface)&  S1,
   const Standard_Integer iT2 = SetQuad(S2, typs2, quad2);
   //
   if (!iT1 || !iT2) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
     return;
   }
   //
@@ -298,7 +298,7 @@ void IntPatch_ImpImpIntersection::Perform(const Handle(Adaptor3d_HSurface)&  S1,
     }
     //
     default: {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
       break;
     }
   }
index daf260f..94bfab8 100644 (file)
@@ -222,7 +222,7 @@ ComputationMethods::stCoeffsValue::stCoeffsValue(const gp_Cylinder& theCyl1,
   // AxeOperator::AxeOperator(...) in IntAna_QuadQuadGeo.cxx file).
   if(Abs(aDetV1V2) < Precision::Angular())
   {
-    Standard_Failure::Raise("Error. Exception in divide by zerro (IntCyCyTrim)!!!!");
+    throw Standard_Failure("Error. Exception in divide by zerro (IntCyCyTrim)!!!!");
   }
 
   switch(aFoundCouple)
@@ -1276,7 +1276,7 @@ Standard_Boolean CyCyAnalyticalIntersect( const IntSurf_Quadric& Quad1,
 
   case IntAna_Parabola:
   case IntAna_Hyperbola:
-    Standard_Failure::Raise("IntCyCy(): Wrong intersection type!");
+    throw Standard_Failure("IntCyCy(): Wrong intersection type!");
 
   case IntAna_Circle:
     // Circle is useful when we will work with trimmed surfaces
@@ -1388,7 +1388,7 @@ Standard_Boolean ComputationMethods::CylCylMonotonicity(const Standard_Real theU
     isPlus = Standard_False;
     break;
   default:
-    //Standard_Failure::Raise("Error. Range Error!!!!");
+    //throw Standard_Failure("Error. Range Error!!!!");
     return Standard_False;
   }
 
index 8f773cd..ac89bbb 100644 (file)
@@ -549,7 +549,7 @@ void IntPatch_ImpPrmIntersection::Perform (const Handle(Adaptor3d_HSurface)& Sur
         break;
       default:
         {
-          Standard_ConstructionError::Raise();
+          throw Standard_ConstructionError();
           break;
         }
       } 
index 86ad430..5eac6dd 100644 (file)
@@ -24,30 +24,30 @@ inline Standard_Boolean IntPatch_ImpPrmIntersection::IsDone () const
 
 inline Standard_Boolean IntPatch_ImpPrmIntersection::IsEmpty () const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return empt;
 }
 
 inline Standard_Integer IntPatch_ImpPrmIntersection::NbPnts () const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return spnt.Length();
 }
 
 inline const IntPatch_Point& IntPatch_ImpPrmIntersection::Point (const Standard_Integer Index) const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return spnt(Index);
 }
 
 inline Standard_Integer IntPatch_ImpPrmIntersection::NbLines () const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return slin.Length();
 }
 
 inline const Handle(IntPatch_Line)& IntPatch_ImpPrmIntersection::Line (const Standard_Integer Index) const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return slin(Index);
 }
index 1af9838..22bb264 100644 (file)
@@ -24,43 +24,43 @@ inline Standard_Boolean IntPatch_Intersection::IsDone () const
 
 inline Standard_Boolean IntPatch_Intersection::IsEmpty () const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return empt;
 }
 
 inline Standard_Boolean IntPatch_Intersection::TangentFaces () const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return tgte;
 }
 
 inline Standard_Boolean IntPatch_Intersection::OppositeFaces () const
 {
-  if (!done) {StdFail_NotDone::Raise();}
-  if (!tgte) {Standard_DomainError::Raise();}
+  if (!done) {throw StdFail_NotDone();}
+  if (!tgte) {throw Standard_DomainError();}
   return oppo;
 }
 
 inline Standard_Integer IntPatch_Intersection::NbPnts () const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return spnt.Length();
 }
 
 inline const IntPatch_Point& IntPatch_Intersection::Point (const Standard_Integer Index) const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return spnt(Index);
 }
 
 inline Standard_Integer IntPatch_Intersection::NbLines () const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return slin.Length();
 }
 
 inline const Handle(IntPatch_Line)& IntPatch_Intersection::Line (const Standard_Integer Index) const
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return slin(Index);
 }
index 4ea6728..5a11fca 100644 (file)
@@ -50,14 +50,14 @@ inline IntSurf_TypeTrans IntPatch_Line::TransitionOnS2 () const {
 
 inline IntSurf_Situation IntPatch_Line::SituationS1 () const {
 
-  if (tS1 != IntSurf_Touch) {Standard_DomainError::Raise();}
+  if (tS1 != IntSurf_Touch) {throw Standard_DomainError();}
   return sit1;
 }
 
 
 inline IntSurf_Situation IntPatch_Line::SituationS2 () const {
 
-  if (tS2 != IntSurf_Touch) {Standard_DomainError::Raise();}
+  if (tS2 != IntSurf_Touch) {throw Standard_DomainError();}
   return sit2;
 }
 
index a5e034f..8581ae0 100644 (file)
@@ -163,7 +163,7 @@ static void Parameters(const Handle(Adaptor3d_HSurface)& myHS1,
     quad1.SetValue(myHS1->Surface().Torus());
     break;
   default:
-    Standard_ConstructionError::Raise("IntPatch_IntSS::MakeCurve");
+    throw Standard_ConstructionError("IntPatch_IntSS::MakeCurve");
   }
   
   typs = myHS2->Surface().GetType();
@@ -184,7 +184,7 @@ static void Parameters(const Handle(Adaptor3d_HSurface)& myHS1,
     quad2.SetValue(myHS2->Surface().Torus());
     break;
   default:
-    Standard_ConstructionError::Raise("IntPatch_IntSS::MakeCurve");
+    throw Standard_ConstructionError("IntPatch_IntSS::MakeCurve");
   }
   quad1.Parameters(Ptref,U1,V1);
   quad2.Parameters(Ptref,U2,V2);
@@ -728,7 +728,7 @@ static void AddLine(const Handle(IntPatch_Line)& L,
       break;
     }
     default: { 
-      Standard_ConstructionError::Raise("IntPatch_LineConstructor::AddLine");
+      throw Standard_ConstructionError("IntPatch_LineConstructor::AddLine");
     }
       break;
     }
index 7bd5fb4..48793d4 100644 (file)
@@ -119,35 +119,35 @@ inline Standard_Boolean IntPatch_Point::IsVertexOnS1 () const
 
 inline const Handle(Adaptor3d_HVertex)& IntPatch_Point::VertexOnS1 () const
 {
-  if (!vtxonS1) {Standard_DomainError::Raise();}
+  if (!vtxonS1) {throw Standard_DomainError();}
   return vS1;
 }
 
 
 inline const Handle(Adaptor2d_HCurve2d)& IntPatch_Point::ArcOnS1 () const
 {
-  if (!onS1) {Standard_DomainError::Raise();}
+  if (!onS1) {throw Standard_DomainError();}
   return arcS1;
 }
 
 
 inline const IntSurf_Transition& IntPatch_Point::TransitionLineArc1 () const
 {
-  if (!onS1) {Standard_DomainError::Raise();}
+  if (!onS1) {throw Standard_DomainError();}
   return traline1;
 }
 
 
 inline const IntSurf_Transition& IntPatch_Point::TransitionOnS1 () const
 {
-  if (!onS1) {Standard_DomainError::Raise();}
+  if (!onS1) {throw Standard_DomainError();}
   return tra1;
 }
 
 
 inline Standard_Real IntPatch_Point::ParameterOnArc1 () const
 {
-  if (!onS1) {Standard_DomainError::Raise();}
+  if (!onS1) {throw Standard_DomainError();}
   return prm1;
 }
 
@@ -166,35 +166,35 @@ inline Standard_Boolean IntPatch_Point::IsVertexOnS2 () const
 
 inline const Handle(Adaptor3d_HVertex)& IntPatch_Point::VertexOnS2 () const
 {
-  if (!vtxonS2) {Standard_DomainError::Raise();}
+  if (!vtxonS2) {throw Standard_DomainError();}
   return vS2;
 }
 
 
 inline const Handle(Adaptor2d_HCurve2d)& IntPatch_Point::ArcOnS2 () const
 {
-  if (!onS2) {Standard_DomainError::Raise();}
+  if (!onS2) {throw Standard_DomainError();}
   return arcS2;
 }
 
 
 inline const IntSurf_Transition& IntPatch_Point::TransitionLineArc2 () const
 {
-  if (!onS2) {Standard_DomainError::Raise();}
+  if (!onS2) {throw Standard_DomainError();}
   return traline2;
 }
 
 
 inline const IntSurf_Transition& IntPatch_Point::TransitionOnS2 () const
 {
-  if (!onS2) {Standard_DomainError::Raise();}
+  if (!onS2) {throw Standard_DomainError();}
   return tra2;
 }
 
 
 inline Standard_Real IntPatch_Point::ParameterOnArc2 () const
 {
-  if (!onS2) {Standard_DomainError::Raise();}
+  if (!onS2) {throw Standard_DomainError();}
   return prm2;
 }
 
index d31d087..ea12960 100644 (file)
@@ -47,7 +47,7 @@ IntPatch_PolyArc::IntPatch_PolyArc(const Handle(Adaptor2d_HCurve2d)& Line ,
   gp_Pnt2d p2d;
   
   if (Pdeb == RealFirst() || Pfin == RealLast() || NbSample <= 1) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   //----------------------------------------------------------------------
   //-- On veut eviter les cas ou  le present polygone est beaucoup plus 
index b33c661..571c700 100644 (file)
@@ -1218,7 +1218,7 @@ Handle(IntPatch_Line) IntPatch_PrmPrmIntersection::NewLine (const Handle(Adaptor
 { 
   Standard_Integer NbPnts = NbPntsToInsert + High - Low;
   if(NumLine>NbLines() || NumLine<1  || Low>=High ) 
-    Standard_OutOfRange::Raise(" IntPatch_PrmPrmIntersection NewLine "); 
+    throw Standard_OutOfRange(" IntPatch_PrmPrmIntersection NewLine ");
   //------------------------------------------------------------------
   //--  Indice     :   Low       Low+1     I    I+1         High    --
   //--                                                              --
index 4fd1425..276ac35 100644 (file)
@@ -26,7 +26,7 @@
 //======================================================================
 inline Standard_Integer IntPatch_PrmPrmIntersection::NbLines() const { 
   if(!done) 
-    StdFail_NotDone::Raise(" IntPatch_PrmPrmIntersection ");
+    throw StdFail_NotDone(" IntPatch_PrmPrmIntersection ");
   return(SLin.Length());
 }
 
@@ -34,14 +34,14 @@ inline Standard_Integer IntPatch_PrmPrmIntersection::NbLines() const {
 inline const Handle(IntPatch_Line)& IntPatch_PrmPrmIntersection::Line
   (const Standard_Integer n) const {
   if(!done) 
-    StdFail_NotDone::Raise(" IntPatch_PrmPrmIntersection ");
+    throw StdFail_NotDone(" IntPatch_PrmPrmIntersection ");
   return(SLin.Value(n));
 }
 
 //======================================================================
 inline Standard_Boolean IntPatch_PrmPrmIntersection::IsEmpty() const { 
   if(!done) 
-    StdFail_NotDone::Raise(" IntPatch_PrmPrmIntersection ");
+    throw StdFail_NotDone(" IntPatch_PrmPrmIntersection ");
   return(empt);
 }
 
index e4275ea..c79178b 100644 (file)
@@ -86,13 +86,13 @@ inline Standard_Boolean IntPatch_RLine::HasLastPoint () const
 
 inline const IntPatch_Point& IntPatch_RLine::FirstPoint () const
 {
-  if (!fipt) {Standard_DomainError::Raise();}
+  if (!fipt) {throw Standard_DomainError();}
   return svtx(indf);
 }
 
 inline const IntPatch_Point& IntPatch_RLine::LastPoint () const
 {
-  if (!lapt) {Standard_DomainError::Raise();}
+  if (!lapt) {throw Standard_DomainError();}
   return svtx(indl);
 }
 
@@ -114,7 +114,7 @@ inline IntPatch_Point& IntPatch_RLine::ChangeVertex (const Standard_Integer Inde
 inline void IntPatch_RLine::RemoveVertex(const Standard_Integer theIndex)
 {
   if((theIndex < 1) || (theIndex > NbVertex()))
-    Standard_OutOfRange::Raise("Cannot delete not existing vertex");
+    throw Standard_OutOfRange("Cannot delete not existing vertex");
   svtx.Remove(theIndex);
 }
 
@@ -125,13 +125,13 @@ inline Standard_Boolean IntPatch_RLine::HasPolygon () const
 
 inline Standard_Integer IntPatch_RLine::NbPnts () const
 {
-  if (curv.IsNull()) {Standard_DomainError::Raise();}
+  if (curv.IsNull()) {throw Standard_DomainError();}
   return curv->NbPoints();
 }
 
 inline const IntSurf_PntOn2S& IntPatch_RLine::Point (const Standard_Integer Index) const
 {
-  if (curv.IsNull()) {Standard_DomainError::Raise();}
+  if (curv.IsNull()) {throw Standard_DomainError();}
   return curv->Value(Index);
 }
 
index 87e7417..fe868ad 100644 (file)
@@ -382,7 +382,7 @@ static Standard_Boolean FindParameter(const Handle(IntPatch_Line)& L,
     if (found) return Standard_True;
   }
   else {
-    Standard_DomainError::Raise();
+    throw Standard_DomainError();
   }
   return Standard_False;
 }
@@ -499,7 +499,7 @@ void IntPatch_RstInt::PutVertexOnLine (const Handle(IntPatch_Line)& L,
     Nbptlin = rlin->NbPnts();
   }
   else {
-    Standard_DomainError::Raise();
+    throw Standard_DomainError();
   }
   if (!Domain->Has3d())
     // don't use computed deflection in the mode of pure geometric intersection
index 81d4130..b180d9a 100644 (file)
@@ -374,7 +374,7 @@ Standard_Boolean IntPatch_SpecialPoints::
   }
   else
   {
-    Standard_TypeMismatch::Raise( "IntPatch_SpecialPoints::AddSingularPole(),"
+    throw Standard_TypeMismatch( "IntPatch_SpecialPoints::AddSingularPole(),"
                                   "Unsupported quadric with Pole");
   }
 
index 9eab7c6..d96438f 100644 (file)
@@ -68,26 +68,26 @@ inline Standard_Boolean IntPatch_WLine::HasLastPoint () const
 
 inline const IntPatch_Point& IntPatch_WLine::FirstPoint () const
 {
-  if (!fipt) {Standard_DomainError::Raise();}
+  if (!fipt) {throw Standard_DomainError();}
   return svtx(indf);
 }
 
 inline const IntPatch_Point& IntPatch_WLine::LastPoint () const
 {
-  if (!lapt) {Standard_DomainError::Raise();}
+  if (!lapt) {throw Standard_DomainError();}
   return svtx(indl);
 }
 
 inline const IntPatch_Point& IntPatch_WLine::FirstPoint (Standard_Integer& Indfirst) const
 {
-  if (!fipt) {Standard_DomainError::Raise();}
+  if (!fipt) {throw Standard_DomainError();}
   Indfirst = indf;
   return svtx(indf);
 }
 
 inline const IntPatch_Point& IntPatch_WLine::LastPoint (Standard_Integer& Indlast) const
 {
-  if (!lapt) {Standard_DomainError::Raise();}
+  if (!lapt) {throw Standard_DomainError();}
   Indlast = indl;
   return svtx(indl);
 }
@@ -115,7 +115,7 @@ inline void IntPatch_WLine::ClearVertexes()
 inline void IntPatch_WLine::RemoveVertex(const Standard_Integer theIndex)
 {
   if((theIndex < 1) || (theIndex > NbVertex()))
-    Standard_OutOfRange::Raise("Cannot delete not existing vertex");
+    throw Standard_OutOfRange("Cannot delete not existing vertex");
   svtx.Remove(theIndex);
 }
 
index 03a9b39..85e36dc 100644 (file)
@@ -26,7 +26,7 @@
 inline void IntRes2d_Domain::SetEquivalentParameters
         (const Standard_Real p_first,
         const Standard_Real p_last)  {
-  if((status&3)!=3) { Standard_DomainError::Raise(); }
+  if((status&3)!=3) { throw Standard_DomainError(); }
   status|=4;
   periodfirst=p_first;
   periodlast=p_last;
@@ -37,17 +37,17 @@ inline Standard_Boolean IntRes2d_Domain::HasFirstPoint () const {
 }
 
 inline Standard_Real IntRes2d_Domain::FirstParameter () const {
-  if(!(status&1)) { Standard_DomainError::Raise(); }
+  if(!(status&1)) { throw Standard_DomainError(); }
   return(first_param);
 }
 
 inline const gp_Pnt2d& IntRes2d_Domain::FirstPoint () const {
-  if(!(status&1)) { Standard_DomainError::Raise(); }
+  if(!(status&1)) { throw Standard_DomainError(); }
   return(first_point);
 }
 
 inline Standard_Real IntRes2d_Domain::FirstTolerance () const {
-  if(!(status&1)) { Standard_DomainError::Raise(); }
+  if(!(status&1)) { throw Standard_DomainError(); }
   return(first_tol);
 }
 
@@ -58,17 +58,17 @@ inline Standard_Boolean IntRes2d_Domain::HasLastPoint () const {
 }
 
 inline Standard_Real IntRes2d_Domain::LastParameter () const {
-  if(!(status&2)) { Standard_DomainError::Raise(); }
+  if(!(status&2)) { throw Standard_DomainError(); }
   return(last_param);
 }
 
 inline const gp_Pnt2d& IntRes2d_Domain::LastPoint () const {
-  if(!(status&2)) { Standard_DomainError::Raise(); }
+  if(!(status&2)) { throw Standard_DomainError(); }
   return(last_point);
 }
 
 inline Standard_Real IntRes2d_Domain::LastTolerance () const {
-  if(!(status&2)) { Standard_DomainError::Raise(); }
+  if(!(status&2)) { throw Standard_DomainError(); }
   return(last_tol);
 }
 
index a5519cd..2f15506 100644 (file)
@@ -34,29 +34,29 @@ inline IntRes2d_Intersection::IntRes2d_Intersection(const IntRes2d_Intersection&
 }
 //----------------------------------------------------------------------
 inline Standard_Boolean IntRes2d_Intersection::IsEmpty() const {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return ((lpnt.Length() == 0) && (lseg.Length() == 0));
 }
 //----------------------------------------------------------------------
 inline Standard_Integer IntRes2d_Intersection::NbPoints() const {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return lpnt.Length();
 }
 //----------------------------------------------------------------------
 inline const IntRes2d_IntersectionPoint&
   IntRes2d_Intersection::Point( const Standard_Integer N) const {
-    if (!done) {StdFail_NotDone::Raise();}
+    if (!done) {throw StdFail_NotDone();}
     return lpnt(N);
   }
 //----------------------------------------------------------------------
 inline Standard_Integer IntRes2d_Intersection::NbSegments() const {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return lseg.Length();
 }
 //----------------------------------------------------------------------
 inline const IntRes2d_IntersectionSegment& 
   IntRes2d_Intersection::Segment(const Standard_Integer N) const {
-    if (!done) {StdFail_NotDone::Raise();}
+    if (!done) {throw StdFail_NotDone();}
     return lseg(N);
   }
 //----------------------------------------------------------------------
index 0df5234..a7aa4df 100644 (file)
@@ -86,7 +86,7 @@ inline Standard_Boolean IntRes2d_IntersectionSegment::HasLastPoint () const {
 inline const IntRes2d_IntersectionPoint& 
         IntRes2d_IntersectionSegment::FirstPoint () const {
 
-  if (!first) { Standard_DomainError::Raise(); }
+  if (!first) { throw Standard_DomainError(); }
   return ptfirst;
 }
 
@@ -94,7 +94,7 @@ inline const IntRes2d_IntersectionPoint&
 inline const IntRes2d_IntersectionPoint&
         IntRes2d_IntersectionSegment::LastPoint () const {
 
-  if (!last) { Standard_DomainError::Raise();}
+  if (!last) { throw Standard_DomainError();}
   return ptlast;
 }
 
index 802d07e..2028266 100644 (file)
@@ -88,7 +88,7 @@ inline IntRes2d_TypeTrans IntRes2d_Transition::TransitionType () const {
 inline Standard_Boolean IntRes2d_Transition::IsTangent () const {
 
   if (typetra==IntRes2d_Undecided) {
-    Standard_DomainError::Raise();
+    throw Standard_DomainError();
   }
   return tangent;
 }
@@ -96,7 +96,7 @@ inline Standard_Boolean IntRes2d_Transition::IsTangent () const {
 inline IntRes2d_Situation IntRes2d_Transition::Situation () const {
 
   if (typetra!=IntRes2d_Touch) {
-    Standard_DomainError::Raise();
+    throw Standard_DomainError();
   }
   return situat;
 }
@@ -104,7 +104,7 @@ inline IntRes2d_Situation IntRes2d_Transition::Situation () const {
 inline Standard_Boolean IntRes2d_Transition::IsOpposite () const {
 
   if (typetra!=IntRes2d_Touch) {
-    Standard_DomainError::Raise();
+    throw Standard_DomainError();
   }
   return oppos;
 }
index fa9ad86..07d5a87 100644 (file)
@@ -58,7 +58,7 @@ inline Standard_Boolean IntStart_PathPoint::IsNew () const {
 
 inline const TheVertex& IntStart_PathPoint::Vertex () const {
 
-  if (isnew) {Standard_DomainError::Raise ();}
+  if (isnew) {throw Standard_DomainError();}
   return vtx;
 }
 
index c4c9408..3728309 100644 (file)
@@ -23,7 +23,7 @@ inline Standard_Boolean IntStart_SearchInside::IsDone () const {
 
 inline Standard_Integer IntStart_SearchInside::NbPoints () const {
 
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return list.Length();
 }
 
@@ -32,7 +32,7 @@ inline const IntSurf_InteriorPoint& IntStart_SearchInside::Value
      (const Standard_Integer Index) const
 
 {
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return list.Value(Index);
 }
 
index 0efe2b2..2aa7330 100644 (file)
@@ -323,7 +323,7 @@ void BoundedArc (const TheArc& A,
 
     math_FunctionAllRoots Sol(Func,Echant,EpsX,maxdist,maxdist); //-- TolBoundary,nTolTangency);
 
-    if (!Sol.IsDone()) {Standard_Failure::Raise();}
+    if (!Sol.IsDone()) {throw Standard_Failure();}
 
     Nbp=Sol.NbPoints();
     //
@@ -335,7 +335,7 @@ void BoundedArc (const TheArc& A,
       Standard_Real theTol = 5.e-4;
       math_FunctionAllRoots SolAgain(Func,Echant,EpsX,theTol,theTol); //-- TolBoundary,nTolTangency);
 
-      if (!SolAgain.IsDone()) {Standard_Failure::Raise();}
+      if (!SolAgain.IsDone()) {throw Standard_Failure();}
 
       Standard_Integer Nbi_again = SolAgain.NbIntervals();
 
index 4cb8963..8b8927e 100644 (file)
@@ -23,14 +23,14 @@ inline Standard_Boolean IntStart_SearchOnBoundaries::IsDone () const {
 
 inline Standard_Boolean IntStart_SearchOnBoundaries::AllArcSolution () const {
 
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return all;
 }
 
 
 inline Standard_Integer IntStart_SearchOnBoundaries::NbPoints () const {
 
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return spnt.Length();
 }
 
@@ -38,13 +38,13 @@ inline Standard_Integer IntStart_SearchOnBoundaries::NbPoints () const {
 inline const IntStart_ThePathPoint& IntStart_SearchOnBoundaries::Point 
   (const Standard_Integer Index) const {
 
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return spnt.Value(Index);
 }
 
 inline Standard_Integer IntStart_SearchOnBoundaries::NbSegments () const {
 
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return sseg.Length();
 }
 
@@ -52,7 +52,7 @@ inline Standard_Integer IntStart_SearchOnBoundaries::NbSegments () const {
 inline const IntStart_TheSegment& IntStart_SearchOnBoundaries::Segment
   (const Standard_Integer Index) const {
 
-  if (!done) {StdFail_NotDone::Raise();}
+  if (!done) {throw StdFail_NotDone();}
   return sseg.Value(Index);
 }
 
index 699de50..b518a63 100644 (file)
@@ -37,7 +37,7 @@ inline Standard_Boolean IntStart_Segment::HasFirstPoint () const {
 
 inline const ThePathPoint& IntStart_Segment::FirstPoint () const {
 
-  if (!hasfp) { Standard_DomainError::Raise(); }
+  if (!hasfp) { throw Standard_DomainError(); }
   return thefp;
 }
 
@@ -50,7 +50,7 @@ inline Standard_Boolean IntStart_Segment::HasLastPoint () const {
 
 inline const ThePathPoint& IntStart_Segment::LastPoint () const {
 
-  if (!haslp) { Standard_DomainError::Raise(); }
+  if (!haslp) { throw Standard_DomainError(); }
   return thelp;
 }
 
index c238c7d..66b8e8a 100644 (file)
@@ -63,13 +63,13 @@ inline Standard_Boolean IntSurf_PathPoint::IsTangent () const {
 
 inline const gp_Vec& IntSurf_PathPoint::Direction3d () const {
 
-  if (istgt) {StdFail_UndefinedDerivative::Raise();}
+  if (istgt) {throw StdFail_UndefinedDerivative();}
   return vectg;
 }
 
 inline const gp_Dir2d& IntSurf_PathPoint::Direction2d () const {
 
-  if (istgt) {StdFail_UndefinedDerivative::Raise();}
+  if (istgt) {throw StdFail_UndefinedDerivative();}
   return dirtg;
 }
 
index 33e6a66..09df5f4 100644 (file)
@@ -47,21 +47,21 @@ inline IntSurf_TypeTrans IntSurf_Transition::TransitionType () const {
 
 inline Standard_Boolean IntSurf_Transition::IsTangent () const {
 
-  if (typetra == IntSurf_Undecided) {Standard_DomainError::Raise();}
+  if (typetra == IntSurf_Undecided) {throw Standard_DomainError();}
   return tangent;
 }
 
 
 inline IntSurf_Situation IntSurf_Transition::Situation () const {
 
-  if (typetra != IntSurf_Touch) {Standard_DomainError::Raise();}
+  if (typetra != IntSurf_Touch) {throw Standard_DomainError();}
   return situat;
 }
 
 
 inline Standard_Boolean IntSurf_Transition::IsOpposite () const {
 
-  if (typetra != IntSurf_Touch) {Standard_DomainError::Raise();}
+  if (typetra != IntSurf_Touch) {throw Standard_DomainError();}
   return oppos;
 }
 
index 41bc473..182075c 100644 (file)
@@ -97,7 +97,7 @@ IntTools_CArray1::IntTools_CArray1 (const Standard_Integer Length):
   if (theNewLength > 0) {
     // default creator called for each item of the array
     p =  new Array1Item[theNewLength];
-    if (!p) Standard_OutOfMemory::Raise("IntTools_CArray1 : Allocation failed.");
+    if (!p) throw Standard_OutOfMemory("IntTools_CArray1 : Allocation failed.");
     myIsAllocated = Standard_True;
   }
   
@@ -117,7 +117,7 @@ IntTools_CArray1::IntTools_CArray1 (const Standard_Integer Length):
   if (theNewLength > 0) {
     // default creator called for each item of the array
     p =  new Array1Item[theNewLength];
-    if (!p) Standard_OutOfMemory::Raise("IntTools_CArray1 : Allocation failed.");
+    if (!p) throw Standard_OutOfMemory("IntTools_CArray1 : Allocation failed.");
     
     if (myLength!=0) {
       Standard_Integer aBytesPerItem=sizeof(Array1Item);
@@ -139,7 +139,7 @@ IntTools_CArray1::IntTools_CArray1 (const Standard_Integer Length):
   const Array1Item& IntTools_CArray1::Value(const Standard_Integer Index) const
 {
   if (myLength <1 || Index < 0 || Index >= myLength)
-    Standard_OutOfRange::Raise("IntTools_CArray1::Value");
+    throw Standard_OutOfRange("IntTools_CArray1::Value");
   
   return ((Array1Item *)myStart)[Index];
 }
@@ -162,7 +162,7 @@ IntTools_CArray1::IntTools_CArray1 (const Standard_Integer Length):
   Array1Item& IntTools_CArray1::ChangeValue(const Standard_Integer Index)
 {
   if (myLength < 1 || Index < 0 || Index >= myLength)
-    Standard_OutOfRange::Raise("IntTools_CArray1::ChangeValue");
+    throw Standard_OutOfRange("IntTools_CArray1::ChangeValue");
 
   return ((Array1Item *)myStart)[Index];
 }
index 9e4ba48..ccd5196 100644 (file)
@@ -1955,7 +1955,7 @@ void IntTools_FaceFace::MakeCurve(const Standard_Integer Index,
     quad1.SetValue(HS1->Surface().Torus());
     break;
   default:
-    Standard_ConstructionError::Raise("GeomInt_IntSS::MakeCurve");
+    throw Standard_ConstructionError("GeomInt_IntSS::MakeCurve");
   }
   
   typs = HS2->Surface().GetType();
@@ -1976,7 +1976,7 @@ void IntTools_FaceFace::MakeCurve(const Standard_Integer Index,
     quad2.SetValue(HS2->Surface().Torus());
     break;
   default:
-    Standard_ConstructionError::Raise("GeomInt_IntSS::MakeCurve");
+    throw Standard_ConstructionError("GeomInt_IntSS::MakeCurve");
   }
 
   quad1.Parameters(Ptref,U1,V1);
index 37e896f..863e068 100644 (file)
@@ -65,7 +65,7 @@ IntTools_TopolTool::IntTools_TopolTool(const Handle(Adaptor3d_HSurface)& theSurf
 // =====================================================================================
 void IntTools_TopolTool::Initialize() 
 {
-  Standard_NotImplemented::Raise("IntTools_TopolTool::Initialize ()");
+  throw Standard_NotImplemented("IntTools_TopolTool::Initialize ()");
 }
 
 // =====================================================================================
index 3abae88..63f0485 100644 (file)
@@ -101,13 +101,13 @@ inline Standard_Boolean IntWalk_IWLine::HasFirstPoint() const
 
 inline Standard_Integer IntWalk_IWLine::FirstPointIndex() const
 {
-  if (!hasFirst) Standard_DomainError::Raise();
+  if (!hasFirst) throw Standard_DomainError();
   return firstIndex;
 }
 
 inline const TheStartPoint& IntWalk_IWLine::FirstPoint() const
 {
- if (!hasFirst) Standard_DomainError::Raise();
+ if (!hasFirst) throw Standard_DomainError();
  return theFirstPoint;
 }
 
@@ -118,13 +118,13 @@ inline Standard_Boolean IntWalk_IWLine::HasLastPoint() const
 
 inline const TheStartPoint& IntWalk_IWLine::LastPoint() const
 {
-  if (!hasLast) Standard_DomainError::Raise();
+  if (!hasLast) throw Standard_DomainError();
   return theLastPoint;
 }
 
 inline Standard_Integer IntWalk_IWLine::LastPointIndex() const
 {
-  if (!hasLast) Standard_DomainError::Raise();
+  if (!hasLast) throw Standard_DomainError();
   return lastIndex;
 }
 
index 3c1d612..2431bfb 100644 (file)
@@ -33,27 +33,27 @@ inline Standard_Boolean IntWalk_IWalking::IsDone() const
 
 inline Standard_Integer IntWalk_IWalking::NbLines() const
 { 
-  if(!done) StdFail_NotDone::Raise(); 
+  if(!done) throw StdFail_NotDone();
   return lines.Length();
 }
 
 inline const Handle(IntWalk_TheIWLine)& IntWalk_IWalking::Value
   (const Standard_Integer Index) const
 { 
-  if(!done) StdFail_NotDone::Raise();
+  if(!done) throw StdFail_NotDone();
   return lines.Value(Index);
 }
 
 inline Standard_Integer IntWalk_IWalking::NbSinglePnts() const 
 {
-    if(!done) StdFail_NotDone::Raise();
+    if(!done) throw StdFail_NotDone();
     return seqSingle.Length();
 }
 
 inline const ThePointOfPath& IntWalk_IWalking::SinglePnt
   (const Standard_Integer Index) const
 {
-  if(!done) StdFail_NotDone::Raise();
+  if(!done) throw StdFail_NotDone();
   return seqSingle.Value(Index);
 }
 
index d9eda77..e9cc440 100644 (file)
@@ -63,7 +63,7 @@ void IntWalk_IWalking::MakeWalkingPoint
     MakeWalkingPoint(Case - 10, U, V, sp, Psol); 
   }
   else {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
 
index e161417..de3bd59 100644 (file)
@@ -20,44 +20,44 @@ inline Standard_Boolean IntWalk_PWalking::IsDone() const {
 }
 
 inline Standard_Integer IntWalk_PWalking::NbPoints() const {
-  if(!done) StdFail_NotDone::Raise();
+  if(!done) throw StdFail_NotDone();
   return line->NbPoints();
 }
 
 inline const IntSurf_PntOn2S& IntWalk_PWalking::Value
   (const Standard_Integer Index) const
 {
-  if (!done) StdFail_NotDone::Raise();
+  if (!done) throw StdFail_NotDone();
   return line->Value(Index);
 }
 
 
 inline const Handle(IntSurf_LineOn2S)& IntWalk_PWalking::Line () const {
 
-  if (!done) StdFail_NotDone::Raise();
+  if (!done) throw StdFail_NotDone();
   return line;
 }
 
 
 inline Standard_Boolean IntWalk_PWalking::TangentAtFirst() const{ 
-  if(!done) StdFail_NotDone::Raise();
+  if(!done) throw StdFail_NotDone();
   return tgfirst;
 }
 
 inline Standard_Boolean IntWalk_PWalking::TangentAtLast() const{ 
-  if(!done) StdFail_NotDone::Raise();
+  if(!done) throw StdFail_NotDone();
   return tglast;
 }
 
 inline Standard_Boolean IntWalk_PWalking::IsClosed() const{ 
-  if(!done) StdFail_NotDone::Raise();
+  if(!done) throw StdFail_NotDone();
   return close;
 }
 
 inline const gp_Dir& IntWalk_PWalking::TangentAtLine
   (Standard_Integer& Index) const
 {
-  if(!done) StdFail_NotDone::Raise();
+  if(!done) throw StdFail_NotDone();
   Index = indextg;
   return tgdir;
 }
index b2b262d..ec8b285 100644 (file)
@@ -48,9 +48,6 @@ public:
   DEFINE_STANDARD_ALLOC
 
   
-  //! Raises Construction Error
-  Standard_EXPORT IntWalk_TheFunctionOfTheInt2S();
-  
   Standard_EXPORT IntWalk_TheFunctionOfTheInt2S(const Handle(Adaptor3d_HSurface)& S1, const Handle(Adaptor3d_HSurface)& S2);
   
   Standard_EXPORT Standard_Integer NbVariables() const;
index ca5af22..871b490 100644 (file)
@@ -48,10 +48,6 @@ class IntWalk_TheInt2S
 public:
 
   DEFINE_STANDARD_ALLOC
-
-  
-  //! Raises Construction Error
-  Standard_EXPORT IntWalk_TheInt2S();
   
   //! compute the solution point with the close point
   Standard_EXPORT IntWalk_TheInt2S(const TColStd_Array1OfReal& Param, const Handle(Adaptor3d_HSurface)& S1, const Handle(Adaptor3d_HSurface)& S2, const Standard_Real TolTangency);
index f823757..72633f8 100644 (file)
@@ -143,7 +143,7 @@ Standard_Integer Interface_Check::NbFails () const
 const Handle(TCollection_HAsciiString)& Interface_Check::Fail
        (const Standard_Integer num, const Standard_Boolean final) const
 {
-  if (thefails.IsNull()) Standard_OutOfRange::Raise();
+  if (thefails.IsNull()) throw Standard_OutOfRange();
   return (final ? thefails->Value(num) : thefailo->Value(num));
 }
 
@@ -271,7 +271,7 @@ Standard_Integer Interface_Check::NbWarnings () const
 const Handle(TCollection_HAsciiString)& Interface_Check::Warning
        (const Standard_Integer num, const Standard_Boolean final) const
 {
-  if (thewarns.IsNull()) Standard_OutOfRange::Raise();
+  if (thewarns.IsNull()) throw Standard_OutOfRange();
   return (final ? thewarns->Value(num) : thewarno->Value(num));
 }
 
@@ -341,7 +341,7 @@ Standard_Integer Interface_Check::NbInfoMsgs () const
 const Handle(TCollection_HAsciiString)& Interface_Check::InfoMsg
   (const Standard_Integer num, const Standard_Boolean final) const
 {
-  if (theinfos.IsNull()) Standard_OutOfRange::Raise();
+  if (theinfos.IsNull()) throw Standard_OutOfRange();
   return (final ? theinfos->Value(num) : theinfoo->Value(num));
 }
 
index fa4f71b..a5fd443 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Interface_CheckFailure, Interface_InterfaceError)
 
 #if !defined No_Exception && !defined No_Interface_CheckFailure
   #define Interface_CheckFailure_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Interface_CheckFailure::Raise(MESSAGE);
+  if (CONDITION) throw Interface_CheckFailure(MESSAGE);
 #else
   #define Interface_CheckFailure_Raise_if(CONDITION, MESSAGE)
 #endif
index 5f7be02..4a7e6b6 100644 (file)
@@ -436,8 +436,7 @@ void Interface_CheckIterator::Next () const
 
 const Handle(Interface_Check)& Interface_CheckIterator::Value () const 
 {
-  if (thecurr->Value() > thelist->Length()) Standard_NoSuchObject::Raise
-    ("Interface Check Iterator : Value");
+  if (thecurr->Value() > thelist->Length()) throw Standard_NoSuchObject("Interface Check Iterator : Value");
   return thelist->Value(thecurr->Value());
 }
 
@@ -449,8 +448,7 @@ const Handle(Interface_Check)& Interface_CheckIterator::Value () const
 
 Standard_Integer Interface_CheckIterator::Number () const 
 {
-  if (thecurr->Value() > thenums->Length()) Standard_NoSuchObject::Raise
-    ("Interface Check Iterator : Value");
+  if (thecurr->Value() > thenums->Length()) throw Standard_NoSuchObject("Interface Check Iterator : Value");
   return thenums->Value(thecurr->Value());
 }
 
index 47ad1d8..1a136df 100644 (file)
 static int errh = 1;
 
 
-static void raisecheck (Handle(Interface_Check)& ach)
+static void raisecheck (Standard_Failure& theException,Handle(Interface_Check)& ach)
 {
-  Handle(Standard_Failure) afail = Standard_Failure::Caught();
   char mess[100];
   sprintf (mess,"** Exception Raised during Check : %s **",
-          afail->DynamicType()->Name());
+          theException.DynamicType()->Name());
   ach->AddFail(mess);
 #ifdef _WIN32
-  if (afail->IsKind(STANDARD_TYPE(OSD_Exception)))
+  if (theException.IsKind(STANDARD_TYPE(OSD_Exception))) {
 #else
-  if (afail->IsKind(STANDARD_TYPE(OSD_Signal)))
+  if (theException.IsKind(STANDARD_TYPE(OSD_Signal))) {
 #endif
-    afail->Reraise("System Signal received, check interrupt");
+    theException.SetMessageString("System Signal received, check interrupt");
+    throw theException;
+  }
 }
 
 
@@ -134,8 +135,8 @@ void Interface_CheckTool::FillCheck(const Handle(Standard_Transient)& ent,
       OCC_CATCH_SIGNALS
       module->CheckCase(CN,ent,sh,ach);
     }
-    catch (Standard_Failure) {
-      raisecheck(ach);
+    catch (Standard_Failure& anException) {
+      raisecheck(anException,ach);
     }
   }
   else {
@@ -216,23 +217,20 @@ Handle(Interface_Check) Interface_CheckTool::Check(const Standard_Integer num)
 void Interface_CheckTool::CheckSuccess (const Standard_Boolean reset)
 {
   if (reset) thestat = 0;
-  if (thestat > 3) Interface_CheckFailure::Raise    // deja teste avec erreur
+  if (thestat > 3) throw Interface_CheckFailure    // deja teste avec erreur
     ("Interface Model : Global Check");
   Handle(Interface_InterfaceModel) model = theshare.Model();
-  if (model->GlobalCheck()->NbFails() > 0) Interface_CheckFailure::Raise
-    ("Interface Model : Global Check");
+  if (model->GlobalCheck()->NbFails() > 0) throw Interface_CheckFailure("Interface Model : Global Check");
   Handle(Interface_Check) modchk = new Interface_Check;
   model->VerifyCheck(modchk);
   if (!model->Protocol().IsNull()) model->Protocol()->GlobalCheck (theshare.Graph(),modchk);
-  if (modchk->HasFailed())  Interface_CheckFailure::Raise
-    ("Interface Model : Verify Check");
+  if (modchk->HasFailed())  throw Interface_CheckFailure("Interface Model : Verify Check");
   if (thestat == 3) return;                    // tout teste et ca passe
 
   errh = 0;  // Pas de try/catch, car justement on raise
   Standard_Integer nb = model->NbEntities();
   for (Standard_Integer i = 1; i <= nb; i ++) {
-    if (model->IsErrorEntity(i)) Interface_CheckFailure::Raise
-      ("Interface Model : an Entity is recorded as Erroneous");
+    if (model->IsErrorEntity(i)) throw Interface_CheckFailure("Interface Model : an Entity is recorded as Erroneous");
     Handle(Standard_Transient) ent = model->Value(i);
     if (thestat & 1) {
       if (!model->IsErrorEntity(i)) continue;    // deja verify, reste analyse
@@ -243,8 +241,7 @@ void Interface_CheckTool::CheckSuccess (const Standard_Boolean reset)
 
     Handle(Interface_Check) ach = new Interface_Check(ent);
     FillCheck(ent,theshare,ach);
-    if (ach->HasFailed()) Interface_CheckFailure::Raise
-      ("Interface Model : Check on an Entity has Failed");
+    if (ach->HasFailed()) throw Interface_CheckFailure("Interface Model : Check on an Entity has Failed");
   }
 }
 
@@ -293,9 +290,9 @@ Interface_CheckIterator Interface_CheckTool::CompleteCheckList ()
       }
       n0 = nb+1;
     }
-    catch(Standard_Failure) {
+    catch(Standard_Failure& anException) {
       n0 = i+1;
-      raisecheck(ach);
+      raisecheck(anException,ach);
       res.Add(ach,i);  thestat |= 12;
     }
   }
@@ -345,9 +342,9 @@ Interface_CheckIterator Interface_CheckTool::CheckList ()
       }
       n0 = nb+1;
     }
-    catch(Standard_Failure) {
+    catch(Standard_Failure& anException) {
       n0 = i+1;
-      raisecheck(ach);
+      raisecheck(anException,ach);
       res.Add(ach,i);  thestat |= 12;
     }
   }
@@ -385,9 +382,9 @@ Interface_CheckIterator Interface_CheckTool::AnalyseCheckList ()
       }
       n0 = nb+1;
     }
-    catch(Standard_Failure) {
+    catch(Standard_Failure& anException) {
       n0 = i+1;
-      raisecheck(ach);
+      raisecheck(anException,ach);
       res.Add(ach,i);  thestat |= 8;
     }
   }
@@ -429,9 +426,9 @@ Interface_CheckIterator Interface_CheckTool::VerifyCheckList ()
       }
       n0 = nb+1;
     }
-    catch(Standard_Failure) {
+    catch(Standard_Failure& anException) {
       n0 = i+1;
-      raisecheck(ach);
+      raisecheck(anException,ach);
       res.Add(ach,i);  thestat |= 4;
     }
   }
@@ -477,9 +474,9 @@ Interface_CheckIterator Interface_CheckTool::WarningCheckList ()
       }
       n0 = nb+1;
     }
-    catch(Standard_Failure) {
+    catch(Standard_Failure& anException) {
       n0 = i+1;
-      raisecheck(ach);
+      raisecheck(anException,ach);
       res.Add(ach,i);  thestat |= 12;
     }
   }
index 803a4ac..60db31f 100644 (file)
@@ -42,10 +42,8 @@ Interface_CopyMap::Interface_CopyMap
    const Handle(Standard_Transient)& res)
 {
   Standard_Integer num = themod->Number(ent);
-  if (num == 0 || num > theres.Upper()) Interface_InterfaceError::Raise
-    ("CopyMap : Bind, Starting Entity not issued from Starting Model");
-  if (!theres.Value(num).IsNull()) Interface_InterfaceError::Raise
-    ("CopyMap : Bind, Starting Entity already bound");
+  if (num == 0 || num > theres.Upper()) throw Interface_InterfaceError("CopyMap : Bind, Starting Entity not issued from Starting Model");
+  if (!theres.Value(num).IsNull()) throw Interface_InterfaceError("CopyMap : Bind, Starting Entity already bound");
   theres.SetValue(num,res);
 }
 
index f281f79..323308e 100644 (file)
@@ -65,8 +65,7 @@ Interface_CopyTool::Interface_CopyTool
   (const Handle(Interface_InterfaceModel)& amodel)
     : thelib (Interface_Protocol::Active()) , thelst (amodel->NbEntities())
 {
-  if (Interface_Protocol::Active().IsNull()) Interface_InterfaceError::Raise
-    ("Interface CopyTool : Create with Active Protocol undefined");
+  if (Interface_Protocol::Active().IsNull()) throw Interface_InterfaceError("Interface CopyTool : Create with Active Protocol undefined");
 
   thelst.Init(Standard_False);
   themod = amodel;
@@ -172,8 +171,7 @@ Interface_CopyTool::Interface_CopyTool
 
 //  <nument> == 0 -> Peut etre une sous-partie non partagee ...
 //  On accepte mais on se protege contre un bouclage
-  if (nument == 0 && thelev > 100) Interface_InterfaceError::Raise
-    ("CopyTool : Transferred, Entity is not contained in Starting Model");
+  if (nument == 0 && thelev > 100) throw Interface_InterfaceError("CopyTool : Transferred, Entity is not contained in Starting Model");
   if (!themap->Search(ent,res)) {       // deja transfere ? sinon, le faire
 
 //  On opere la Copie (enfin, on tente)
index b8c3055..58649d9 100644 (file)
@@ -49,7 +49,7 @@ Interface_EntityCluster::Interface_EntityCluster ()    {  }
     void  Interface_EntityCluster::Append
   (const Handle(Standard_Transient)& ent)
 {
-  if (ent.IsNull()) Standard_NullObject::Raise("Interface_EntityCluster Append");
+  if (ent.IsNull()) throw Standard_NullObject("Interface_EntityCluster Append");
   if      (theents[0].IsNull()) theents[0] = ent;
   else if (theents[1].IsNull()) theents[1] = ent;
   else if (theents[2].IsNull()) theents[2] = ent;
@@ -63,7 +63,7 @@ Interface_EntityCluster::Interface_EntityCluster ()    {  }
     Standard_Boolean  Interface_EntityCluster::Remove
   (const Handle(Standard_Transient)& ent)
 {
-  if (ent.IsNull()) Standard_NullObject::Raise("Interface_EntityCluster Remove");
+  if (ent.IsNull()) throw Standard_NullObject("Interface_EntityCluster Remove");
   Standard_Integer i;
 //  <ent> est-il ici ? si oui, on a son rang
   if      (ent == theents[0]) i = 1;
@@ -85,10 +85,10 @@ Interface_EntityCluster::Interface_EntityCluster ()    {  }
     Standard_Boolean  Interface_EntityCluster::Remove
   (const Standard_Integer num)
 {
-  if (num < 1) Standard_OutOfRange::Raise("EntityCluster : Remove");
+  if (num < 1) throw Standard_OutOfRange("EntityCluster : Remove");
   Standard_Integer n = NbLocal();
   if (num > n) {
-    if (thenext.IsNull()) Standard_OutOfRange::Raise("EntityCluster : Remove");
+    if (thenext.IsNull()) throw Standard_OutOfRange("EntityCluster : Remove");
     Standard_Boolean res = thenext->Remove (num-n);
     if (res) thenext = thenext->Next();
     return Standard_False;
@@ -111,10 +111,9 @@ Interface_EntityCluster::Interface_EntityCluster ()    {  }
   (const Standard_Integer num) const
 {
   Standard_Integer nb = NbLocal();
-  if (num <= 0) Standard_OutOfRange::Raise("Interface EntityCluster : Value");
+  if (num <= 0) throw Standard_OutOfRange("Interface EntityCluster : Value");
   if (num > nb) {
-    if (thenext.IsNull()) Standard_OutOfRange::Raise
-      ("Interface EntityCluster : Value");
+    if (thenext.IsNull()) throw Standard_OutOfRange("Interface EntityCluster : Value");
     return thenext->Value(num-nb);
   }
   return theents[num-1];  // numerotation a partir de 0
@@ -123,12 +122,11 @@ Interface_EntityCluster::Interface_EntityCluster ()    {  }
     void  Interface_EntityCluster::SetValue
   (const Standard_Integer num, const Handle(Standard_Transient)& ent)
 {
-  if (ent.IsNull()) Standard_NullObject::Raise("Interface_EntityCluster SetValue");
+  if (ent.IsNull()) throw Standard_NullObject("Interface_EntityCluster SetValue");
   Standard_Integer nb = NbLocal();
-  if (num <= 0) Standard_OutOfRange::Raise("Interface EntityCluster : SetValue");
+  if (num <= 0) throw Standard_OutOfRange("Interface EntityCluster : SetValue");
   if (num > nb) {
-    if (thenext.IsNull()) Standard_OutOfRange::Raise
-      ("Interface EntityCluster : SetValue");
+    if (thenext.IsNull()) throw Standard_OutOfRange("Interface EntityCluster : SetValue");
     thenext->SetValue(num-nb,ent);
   }
   else theents[num-1] = ent;  // numerotation a partir de 0
index 4bf98b4..7c7dd75 100644 (file)
@@ -137,9 +137,9 @@ Interface_EntityIterator::Interface_EntityIterator ()
     const Handle(Standard_Transient)& Interface_EntityIterator::Value () const
 {
 //  NbEntity pas const (on ne sait pas comment il est implemente apres tout)
-  if (thelist.IsNull()) Standard_NoSuchObject::Raise("Interface_EntityIterator");
+  if (thelist.IsNull()) throw Standard_NoSuchObject("Interface_EntityIterator");
   if (thecurr->Value() < 1 || thecurr->Value() > thelist->Length())
-    Standard_NoSuchObject::Raise("Interface_EntityIterator");
+    throw Standard_NoSuchObject("Interface_EntityIterator");
   return thelist->Value(thecurr->Value());
 }
 
index b462d40..68a6e46 100644 (file)
@@ -35,7 +35,7 @@ Interface_EntityList::Interface_EntityList ()    {  }
     void  Interface_EntityList::Append
   (const Handle(Standard_Transient)& ent)
 {
-  if (ent.IsNull()) Standard_NullObject::Raise("Interface_EntityList Append");
+  if (ent.IsNull()) throw Standard_NullObject("Interface_EntityList Append");
   if (theval.IsNull()) {  theval = ent;  return;  }
   Handle(Interface_EntityCluster) aValEC =
     Handle(Interface_EntityCluster)::DownCast(theval);
@@ -55,7 +55,7 @@ Interface_EntityList::Interface_EntityList ()    {  }
     void  Interface_EntityList::Add
   (const Handle(Standard_Transient)& ent)
 {
-  if (ent.IsNull()) Standard_NullObject::Raise("Interface_EntityList Add");
+  if (ent.IsNull()) throw Standard_NullObject("Interface_EntityList Add");
   if (theval.IsNull()) {  theval = ent;  return;  }
   Handle(Interface_EntityCluster) aValEC =
     Handle(Interface_EntityCluster)::DownCast(theval);
@@ -75,7 +75,7 @@ Interface_EntityList::Interface_EntityList ()    {  }
 
     void  Interface_EntityList::Remove (const Handle(Standard_Transient)& ent)
 {
-  if (ent.IsNull()) Standard_NullObject::Raise("Interface_EntityList Remove");
+  if (ent.IsNull()) throw Standard_NullObject("Interface_EntityList Remove");
   if (theval.IsNull()) return;
   if (theval == ent) {
     theval.Nullify();
@@ -92,11 +92,11 @@ Interface_EntityList::Interface_EntityList ()    {  }
 
     void  Interface_EntityList::Remove  (const Standard_Integer num)
 {
-  if (theval.IsNull()) Standard_OutOfRange::Raise("EntityList : Remove");
+  if (theval.IsNull()) throw Standard_OutOfRange("EntityList : Remove");
   Handle(Interface_EntityCluster) ec =
     Handle(Interface_EntityCluster)::DownCast(theval);
   if (ec.IsNull()) {
-    if (num != 1) Standard_OutOfRange::Raise("EntityList : Remove");
+    if (num != 1) throw Standard_OutOfRange("EntityList : Remove");
     theval.Nullify();
     return;
   }
@@ -122,23 +122,23 @@ Interface_EntityList::Interface_EntityList ()    {  }
     const Handle(Standard_Transient)&  Interface_EntityList::Value
   (const Standard_Integer num) const 
 {
-  if (theval.IsNull()) Standard_OutOfRange::Raise("Interface EntityList : Value");
+  if (theval.IsNull()) throw Standard_OutOfRange("Interface EntityList : Value");
   Handle(Interface_EntityCluster) ec =
     Handle(Interface_EntityCluster)::DownCast(theval);
   if (!ec.IsNull()) return ec->Value(num);  // EntityCluster
-  else if (num != 1) Standard_OutOfRange::Raise("Interface EntityList : Value");
+  else if (num != 1) throw Standard_OutOfRange("Interface EntityList : Value");
   return theval;
 }
 
     void  Interface_EntityList::SetValue
   (const Standard_Integer num, const Handle(Standard_Transient)& ent)
 {
-  if (ent.IsNull()) Standard_NullObject::Raise("Interface_EntityList SetValue");
-  if (theval.IsNull()) Standard_OutOfRange::Raise("Interface EntityList : SetValue");
+  if (ent.IsNull()) throw Standard_NullObject("Interface_EntityList SetValue");
+  if (theval.IsNull()) throw Standard_OutOfRange("Interface EntityList : SetValue");
   Handle(Interface_EntityCluster) ec =
     Handle(Interface_EntityCluster)::DownCast(theval);
   if (!ec.IsNull()) ec->SetValue(num,ent);   // EntityCluster
-  else if (num != 1) Standard_OutOfRange::Raise("Interface EntityList : SetValue");
+  else if (num != 1) throw Standard_OutOfRange("Interface EntityList : SetValue");
   else theval = ent;
 
 }
@@ -182,8 +182,7 @@ Interface_EntityList::Interface_EntityList ()    {  }
 {
   Standard_Integer res = 0;
   Handle(Standard_Transient) entres;
-  if (theval.IsNull()) Interface_InterfaceError::Raise
-    ("Interface EntityList : TypedEntity , none found");
+  if (theval.IsNull()) throw Interface_InterfaceError("Interface EntityList : TypedEntity , none found");
   Handle(Interface_EntityCluster) ec =
     Handle(Interface_EntityCluster)::DownCast(theval);
   if (!ec.IsNull()) {                // EntityCluster
@@ -191,8 +190,7 @@ Interface_EntityList::Interface_EntityList ()    {  }
       for (Standard_Integer i = ec->NbLocal(); i > 0; i --) {
        if (ec->Value(i)->IsKind(atype)) {
          res ++;
-         if (num == 0 && res > 1) Interface_InterfaceError::Raise
-           ("Interface EntityList : TypedEntity , several found");
+         if (num == 0 && res > 1) throw Interface_InterfaceError("Interface EntityList : TypedEntity , several found");
          entres = ec->Value(i);
          if (res == num) return entres;
        }
@@ -201,11 +199,9 @@ Interface_EntityList::Interface_EntityList ()    {  }
       ec = ec->Next();
     }
   } else if (num > 1) {
-    Interface_InterfaceError::Raise
-      ("Interface EntityList : TypedEntity ,out of range");
+    throw Interface_InterfaceError("Interface EntityList : TypedEntity ,out of range");
   } else {                          // InterfaceEntity
-    if (!theval->IsKind(atype)) Interface_InterfaceError::Raise
-      ("Interface EntityList : TypedEntity , none found");
+    if (!theval->IsKind(atype)) throw Interface_InterfaceError("Interface EntityList : TypedEntity , none found");
     entres = theval;
   }
   return entres;
index 1009559..6f7eb5b 100644 (file)
@@ -380,15 +380,14 @@ void Interface_FileReaderTool::LoadModel
 
     //   En cas d erreur NON PREVUE par l analyse, recuperation par defaut
     //   Attention : la recuperation peut elle-meme planter ... (cf ierr)
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
       //      Au passage suivant, on attaquera le record suivant
       num0 = thereader->FindNextRecord(num); //:g9 abv 28 May 98: tr8_as2_ug.stp - infinite cycle: (0);
 
-      Handle(Standard_Failure) afail = Standard_Failure::Caught();
 #ifdef _WIN32
-      if (afail.IsNull() || afail->IsKind(STANDARD_TYPE(OSD_Exception))) ierr = 2;
+      if (anException.IsKind(STANDARD_TYPE(OSD_Exception))) ierr = 2;
 #else
-      if (afail.IsNull() || afail->IsKind(STANDARD_TYPE(OSD_Signal))) ierr = 2;
+      if (anException.IsKind(STANDARD_TYPE(OSD_Signal))) ierr = 2;
 #endif
 //:abv 03Apr00: anent is actually a previous one:      if (anent.IsNull()) 
       anent = thereader->BoundEntity(num);
index 6506d29..5d66327 100644 (file)
@@ -363,8 +363,7 @@ void  Interface_Graph::GetFromIter
 
 void Interface_Graph::GetFromGraph (const Interface_Graph& agraph)
 {
-  if (Model() != agraph.Model()) Standard_DomainError::Raise
-    ("Graph from Interface : GetFromGraph");
+  if (Model() != agraph.Model()) throw Standard_DomainError("Graph from Interface : GetFromGraph");
   Standard_Integer nb = Size();
   for (Standard_Integer i = 1; i <= nb; i ++) {
     if (agraph.IsPresent(i))
@@ -375,8 +374,7 @@ void Interface_Graph::GetFromGraph (const Interface_Graph& agraph)
 void Interface_Graph::GetFromGraph
 (const Interface_Graph& agraph, const Standard_Integer stat)
 {
-  if (Model() != agraph.Model()) Standard_DomainError::Raise
-    ("Graph from Interface : GetFromGraph");
+  if (Model() != agraph.Model()) throw Standard_DomainError("Graph from Interface : GetFromGraph");
   Standard_Integer nb = Size();
   for (Standard_Integer i = 1; i <= nb; i ++) {
     if (agraph.IsPresent(i) && agraph.Status(i) == stat)
@@ -410,7 +408,7 @@ Interface_EntityIterator Interface_Graph::Shareds
   if (themodel->IsRedefinedContent(num)) 
      aCurEnt = themodel->ReportEntity(num)->Content();
 
-  //if (num == 0)  Standard_DomainError::Raise ("Interface : Shareds");
+  //if (num == 0)  throw Standard_DomainError("Interface : Shareds");
   Handle(Interface_GeneralModule) module;
   Standard_Integer CN;
   if (themodel->GTool()->Select(aCurEnt,module,CN))  
index ced99af..5461b98 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Interface_InterfaceError, Standard_Failure)
 
 #if !defined No_Exception && !defined No_Interface_InterfaceError
   #define Interface_InterfaceError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Interface_InterfaceError::Raise(MESSAGE);
+  if (CONDITION) throw Interface_InterfaceError(MESSAGE);
 #else
   #define Interface_InterfaceError_Raise_if(CONDITION, MESSAGE)
 #endif
index 9632f8b..5070529 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Interface_InterfaceMismatch, Interface_InterfaceError)
 
 #if !defined No_Exception && !defined No_Interface_InterfaceMismatch
   #define Interface_InterfaceMismatch_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Interface_InterfaceMismatch::Raise(MESSAGE);
+  if (CONDITION) throw Interface_InterfaceMismatch(MESSAGE);
 #else
   #define Interface_InterfaceMismatch_Raise_if(CONDITION, MESSAGE)
 #endif
index 9fd33dd..e896b4a 100644 (file)
@@ -431,18 +431,15 @@ Standard_Boolean Interface_InterfaceModel::SetReportEntity
   Handle(Standard_Transient) ent;
   if (num > 0) {
     ent = Value(nm);
-    if (! (ent == rep->Concerned()) ) Interface_InterfaceMismatch::Raise
-      ("InterfaceModel : SetReportEntity");
+    if (! (ent == rep->Concerned()) ) throw Interface_InterfaceMismatch("InterfaceModel : SetReportEntity");
   } else if (num < 0) {
     nm = -num;
     ent = Value(nm);
-    if (! (ent == rep->Concerned()) ) Interface_InterfaceMismatch::Raise
-      ("InterfaceModel : SetReportEntity");
+    if (! (ent == rep->Concerned()) ) throw Interface_InterfaceMismatch("InterfaceModel : SetReportEntity");
   } else {
     ent = rep->Concerned();
     nm = Number (ent);
-    if (nm == 0)  Interface_InterfaceMismatch::Raise
-      ("InterfaceModel : SetReportEntity");
+    if (nm == 0)  throw Interface_InterfaceMismatch("InterfaceModel : SetReportEntity");
   }
   if (!thereports.IsBound(nm)) {
     Standard_Integer maxrep = thereports.NbBuckets();
@@ -624,8 +621,7 @@ void Interface_InterfaceModel::AddWithRefs(const Handle(Standard_Transient)& ane
                                            const Standard_Boolean listall)
 {
   Handle(Interface_Protocol) proto = Protocol();
-  if (proto.IsNull()) Interface_InterfaceMismatch::Raise
-    ("InterfaceModel : AddWithRefs");
+  if (proto.IsNull()) throw Interface_InterfaceMismatch("InterfaceModel : AddWithRefs");
   AddWithRefs (anent,proto,level,listall);
 }
 
@@ -726,8 +722,7 @@ void Interface_InterfaceModel::ChangeOrder(const Standard_Integer oldnum,
   Standard_Integer minum  = (oldnum > newnum ? newnum : oldnum);
   Standard_Integer mxnum  = (oldnum < newnum ? newnum : oldnum);
   Standard_Integer kount  = (oldnum > newnum ? cnt  : -cnt);
-  if (cnt <= 0 || cnt > mxnum - minum) Interface_InterfaceMismatch::Raise
-    ("InterfaceModel : ChangeOrder, Overlap");
+  if (cnt <= 0 || cnt > mxnum - minum) throw Interface_InterfaceMismatch("InterfaceModel : ChangeOrder, Overlap");
   for (i = 1; i < minum; i ++)  ents.SetValue (i,theentities.FindKey(i));
   for (i = mxnum+cnt; i <= nb; i ++) ents.SetValue (i,theentities.FindKey(i));
   for (i = minum; i < mxnum; i ++)
index 2189f75..4925bfe 100644 (file)
@@ -28,8 +28,7 @@ Interface_LineBuffer::Interface_LineBuffer (const Standard_Integer size)
 
     void  Interface_LineBuffer::SetMax (const Standard_Integer max)
 {
-  if (max > theline.Length()) Standard_OutOfRange::Raise
-    ("Interface LineBuffer : SetMax");
+  if (max > theline.Length()) throw Standard_OutOfRange("Interface LineBuffer : SetMax");
   if (max <= 0) themax = theline.Length();
   else themax = max;
 }
@@ -38,8 +37,7 @@ Interface_LineBuffer::Interface_LineBuffer (const Standard_Integer size)
     void  Interface_LineBuffer::SetInitial (const Standard_Integer initial)
 {
   if (thefriz > 0) return;
-  if (initial >= themax) Standard_OutOfRange::Raise
-    ("Interface LineBuffer : SetInitial");
+  if (initial >= themax) throw Standard_OutOfRange("Interface LineBuffer : SetInitial");
   if (initial <= 0) theinit = 0;
   else theinit = initial;
 }
index 1216eb8..be84fd2 100644 (file)
@@ -192,7 +192,7 @@ Standard_CString  Interface_MSG::Translated (const Standard_CString key)
     } else
       thelist.Bind(key, 1);
   }
-  if (theraise) Standard_DomainError::Raise ("Interface_MSG : Translate");
+  if (theraise) throw Standard_DomainError("Interface_MSG : Translate");
   return key;
 }
 
@@ -216,7 +216,7 @@ void  Interface_MSG::Record
     dup = new TCollection_HAsciiString(item);
     thedup->Append(dup);
   }
-  if (theraise) Standard_DomainError::Raise ("Interface_MSG : Record");
+  if (theraise) throw Standard_DomainError("Interface_MSG : Record");
 }
 
 
index d1109cb..0a2a48d 100644 (file)
@@ -47,8 +47,7 @@ Interface_Recognizer::Interface_Recognizer ()
 {
   if (!theres.IsNull()) return theres;
   if (hasnext) return thenext->Result();
-  Standard_NoSuchObject::Raise ("Recognizer evaluation has failed");
-  return theres;  // pour calmer le compilateur
+  throw Standard_NoSuchObject("Recognizer evaluation has failed");
 }
 
     void Interface_Recognizer::Add (const Handle(Interface_Recognizer)& reco)
index 6245cd5..6850aee 100644 (file)
@@ -127,8 +127,7 @@ Interface_ShareFlags::Interface_ShareFlags
   (const Handle(Standard_Transient)& ent) const 
 {
   Standard_Integer num = themodel->Number(ent);
-  if (num == 0 || num > themodel->NbEntities()) Standard_DomainError::Raise
-    ("Interface ShareFlags : IsShared");
+  if (num == 0 || num > themodel->NbEntities()) throw Standard_DomainError("Interface ShareFlags : IsShared");
   return theflags.Value(num);
 }
 
index bf86bd0..984d09b 100644 (file)
@@ -149,12 +149,10 @@ Interface_ShareTool::Interface_ShareTool (const Handle(Interface_HGraph)& ahgrap
     if (entsh->IsKind(atype)) {
       entresult = entsh;
       result ++;
-      if (result > 1)  Interface_InterfaceError::Raise
-       ("Interface ShareTool : TypedSharing, more than one found");
+      if (result > 1)  throw Interface_InterfaceError("Interface ShareTool : TypedSharing, more than one found");
     }
   }
-  if (result == 0) Interface_InterfaceError::Raise
-    ("Interface ShareTool : TypedSharing, not found");
+  if (result == 0) throw Interface_InterfaceError("Interface ShareTool : TypedSharing, not found");
   return entresult;
 }
 
index ebba1c2..9909c58 100644 (file)
@@ -96,7 +96,7 @@ void  Interface_Static::Standards ()
     }
     if (!Message_MsgFile::HasMsg ("XSTEP_1"))
     {
-      Standard_ProgramError::Raise ("Critical Error - message resources for Interface_Static are invalid or undefined!");
+      throw Standard_ProgramError("Critical Error - message resources for Interface_Static are invalid or undefined!");
     }
   }
 }
index d4b3dbd..523f895 100644 (file)
@@ -62,8 +62,7 @@ Interface_UndefinedContent::Interface_UndefinedContent () // Unknown
    Handle(Standard_Transient)& ent,
    Handle(TCollection_HAsciiString)& val) const
 {
-  if (num < 1 || num > thenbparams) Standard_OutOfRange::Raise
-    ("Interface UndefinedContent : ParamData");
+  if (num < 1 || num > thenbparams) throw Standard_OutOfRange("Interface UndefinedContent : ParamData");
   Standard_Integer desc  = theparams->Value(num);
   Standard_Integer local = ((desc >> Content_LocalShift) & Content_LocalField);
   ptype = Interface_ParamType (desc & Content_TypeField);
@@ -89,8 +88,7 @@ Interface_UndefinedContent::Interface_UndefinedContent () // Unknown
 {
   Standard_Integer desc = theparams->Value(num);
   if (((desc >> Content_LocalShift) & Content_LocalField) != Content_LocalRef)
-    Interface_InterfaceError::Raise
-      ("UndefinedContent : Param is not Entity type");
+    throw Interface_InterfaceError("UndefinedContent : Param is not Entity type");
   return theentities.Value (desc >> Content_NumberShift);
 }
 
@@ -100,8 +98,7 @@ Interface_UndefinedContent::ParamValue
 {
   Standard_Integer desc = theparams->Value(num);
   if (((desc >> Content_LocalShift) & Content_LocalField) != 0)
-    Interface_InterfaceError::Raise
-      ("UndefinedContent : Param is not literal");
+    throw Interface_InterfaceError("UndefinedContent : Param is not literal");
   return thevalues->Value (desc >> Content_NumberShift);
 }
 
@@ -284,7 +281,7 @@ Interface_UndefinedContent::ParamValue
   Standard_Integer rang  = desc >> Content_NumberShift;
   Standard_Integer local = ((desc >> Content_LocalShift) & Content_LocalField);
   Standard_Boolean c1ent = (local == Content_LocalRef);
-  if (!c1ent) Interface_InterfaceError::Raise("UndefinedContent : SetEntity");
+  if (!c1ent) throw Interface_InterfaceError("UndefinedContent : SetEntity");
   theentities.SetValue(rang,ent);
 }
 
index 900c176..47220f5 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(LProp_BadContinuity, Standard_Failure)
 
 #if !defined No_Exception && !defined No_LProp_BadContinuity
   #define LProp_BadContinuity_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) LProp_BadContinuity::Raise(MESSAGE);
+  if (CONDITION) throw LProp_BadContinuity(MESSAGE);
 #else
   #define LProp_BadContinuity_Raise_if(CONDITION, MESSAGE)
 #endif
index d40bbf3..9d7a059 100644 (file)
@@ -167,7 +167,7 @@ Standard_Boolean LProp_CLProps::IsTangentDefined ()
 void  LProp_CLProps::Tangent (Dir& D)
 {
   if(!IsTangentDefined())
-    LProp_NotDefined::Raise();
+    throw LProp_NotDefined();
   
   if(mySignificantFirstDerivativeOrder == 1)
     D = Dir(myDerivArr[0]);
@@ -251,7 +251,7 @@ void  LProp_CLProps::Normal (Dir& D)
   Standard_Real c = Curvature();
   if(c==RealLast() || Abs(c) <= myLinTol)
   {
-    LProp_NotDefined::Raise("LProp_CLProps::Normal(...):"
+    throw LProp_NotDefined("LProp_CLProps::Normal(...):"
         "Curvature is null or infinity"); 
   }
 
@@ -267,7 +267,7 @@ void  LProp_CLProps::CentreOfCurvature (Pnt& P)
 {
   if(Abs(Curvature()) <= myLinTol)
   {
-    LProp_NotDefined::Raise(); 
+    throw LProp_NotDefined();
   }
 
   // we used here the following vector relation 
index f8aaf7a..811e6c3 100644 (file)
@@ -126,7 +126,7 @@ Standard_Integer LProp_CurAndInf::NbPoints() const
 
 Standard_Real LProp_CurAndInf::Parameter(const Standard_Integer N) const 
 {
-  if (N <1 || N > NbPoints ()) {Standard_OutOfRange::Raise();}
+  if (N <1 || N > NbPoints ()) {throw Standard_OutOfRange();}
   return theParams.Value(N);
 }
 
@@ -138,7 +138,7 @@ Standard_Real LProp_CurAndInf::Parameter(const Standard_Integer N) const
 
 LProp_CIType LProp_CurAndInf::Type(const Standard_Integer N) const 
 {  
-  if (N <1 || N > NbPoints()) {Standard_OutOfRange::Raise();}
+  if (N <1 || N > NbPoints()) {throw Standard_OutOfRange();}
   return theTypes.Value(N);
 }
 
index 2402002..c51ea18 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(LProp_NotDefined, Standard_Failure)
 
 #if !defined No_Exception && !defined No_LProp_NotDefined
   #define LProp_NotDefined_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) LProp_NotDefined::Raise(MESSAGE);
+  if (CONDITION) throw LProp_NotDefined(MESSAGE);
 #else
   #define LProp_NotDefined_Raise_if(CONDITION, MESSAGE)
 #endif
index ca05246..b5f5cbe 100644 (file)
@@ -216,7 +216,7 @@ Standard_Boolean LProp_SLProps::IsTangentUDefined ()
 void LProp_SLProps::TangentU (gp_Dir& D) 
 {
   if(!IsTangentUDefined())
-    LProp_NotDefined::Raise();
+    throw LProp_NotDefined();
 
   if(mySignificantFirstDerivativeOrderU == 1)
     D = gp_Dir(myD1u);
@@ -273,7 +273,7 @@ Standard_Boolean LProp_SLProps::IsTangentVDefined ()
 void LProp_SLProps::TangentV (gp_Dir& D)
 {
   if(!IsTangentVDefined())
-    LProp_NotDefined::Raise();
+    throw LProp_NotDefined();
   
   if(mySignificantFirstDerivativeOrderV == 1)
     D = gp_Dir(myD1v);
@@ -342,7 +342,7 @@ const gp_Dir& LProp_SLProps::Normal ()
 {
   if(!IsNormalDefined())
   {
-    LProp_NotDefined::Raise();
+    throw LProp_NotDefined();
   }
 
   return myNormal;
@@ -491,7 +491,7 @@ Standard_Boolean LProp_SLProps::IsCurvatureDefined ()
 Standard_Boolean LProp_SLProps::IsUmbilic ()
 {
   if(!IsCurvatureDefined())
-    LProp_NotDefined::Raise();
+    throw LProp_NotDefined();
   
   return Abs(myMaxCurv - myMinCurv) < Abs(Epsilon(myMaxCurv));
 }
@@ -499,7 +499,7 @@ Standard_Boolean LProp_SLProps::IsUmbilic ()
 Standard_Real LProp_SLProps::MaxCurvature ()
 {
   if(!IsCurvatureDefined())
-    LProp_NotDefined::Raise();
+    throw LProp_NotDefined();
 
   return myMaxCurv;
 }
@@ -507,7 +507,7 @@ Standard_Real LProp_SLProps::MaxCurvature ()
 Standard_Real LProp_SLProps::MinCurvature ()
 {
   if(!IsCurvatureDefined())
-    LProp_NotDefined::Raise();
+    throw LProp_NotDefined();
   
   return myMinCurv;
 }
@@ -515,7 +515,7 @@ Standard_Real LProp_SLProps::MinCurvature ()
 void LProp_SLProps::CurvatureDirections(gp_Dir& Max, gp_Dir& Min)
 {
   if(!IsCurvatureDefined())
-    LProp_NotDefined::Raise();
+    throw LProp_NotDefined();
 
   Max = myDirMaxCurv;
   Min = myDirMinCurv;
@@ -524,7 +524,7 @@ void LProp_SLProps::CurvatureDirections(gp_Dir& Max, gp_Dir& Min)
 Standard_Real LProp_SLProps::MeanCurvature ()
 {
   if(!IsCurvatureDefined())
-    LProp_NotDefined::Raise();
+    throw LProp_NotDefined();
 
   return myMeanCurv;
 }
@@ -532,7 +532,7 @@ Standard_Real LProp_SLProps::MeanCurvature ()
 Standard_Real LProp_SLProps::GaussianCurvature ()
 {
   if(!IsCurvatureDefined())
-    LProp_NotDefined::Raise();
+    throw LProp_NotDefined();
 
   return myGausCurv;
 }
index f3531f2..563457e 100644 (file)
@@ -222,8 +222,7 @@ Handle(Law_BSpline) Law::Reparametrize(const Adaptor3d_Curve&   Curve,
   }
   inter.Perform();
   if(!inter.IsDone()) 
-    Standard_Failure::Raise
-      ("Law::Reparametrize echec interpolation");
+    throw Standard_Failure("Law::Reparametrize echec interpolation");
   Handle(Law_BSpline) bs = inter.Curve();
   return bs;
 }
index 227762a..efe179c 100644 (file)
@@ -71,7 +71,7 @@ Standard_Integer Law_BSpFunc::NbIntervals(const GeomAbs_Shape S) const
     switch ( S) {
     case GeomAbs_G1:
     case GeomAbs_G2:
-      Standard_DomainError::Raise("Law_BSpFunc::NbIntervals");
+      throw Standard_DomainError("Law_BSpFunc::NbIntervals");
       break;
     case GeomAbs_C0:
       myNbIntervals = 1;
@@ -134,7 +134,7 @@ void Law_BSpFunc::Intervals(TColStd_Array1OfReal& T,
     switch ( S) {
     case GeomAbs_G1:
     case GeomAbs_G2:
-      Standard_DomainError::Raise("Law_BSpFunc_Curve::Intervals");
+      throw Standard_DomainError("Law_BSpFunc_Curve::Intervals");
       break;
     case GeomAbs_C0:
       myNbIntervals = 1;
index ffd1271..3a5f728 100644 (file)
@@ -94,20 +94,20 @@ static void CheckCurveData
  const Standard_Boolean            Periodic)
 {
   if (Degree < 1 || Degree > Law_BSpline::MaxDegree()) {
-    Standard_ConstructionError::Raise();  
+    throw Standard_ConstructionError();
   }
   
-  if (CPoles.Length() < 2)                Standard_ConstructionError::Raise();
-  if (CKnots.Length() != CMults.Length()) Standard_ConstructionError::Raise();
+  if (CPoles.Length() < 2)                throw Standard_ConstructionError();
+  if (CKnots.Length() != CMults.Length()) throw Standard_ConstructionError();
   
   for (Standard_Integer I = CKnots.Lower(); I < CKnots.Upper(); I++) {
     if (CKnots (I+1) - CKnots (I) <= Epsilon (Abs(CKnots (I)))) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   }
   
   if (CPoles.Length() != BSplCLib::NbPoles(Degree,Periodic,CMults))
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
 }
 
 
@@ -273,12 +273,12 @@ Law_BSpline::Law_BSpline
                  Periodic);
   
   if (Weights.Length() != Poles.Length())
-    Standard_ConstructionError::Raise("Law_BSpline");
+    throw Standard_ConstructionError("Law_BSpline");
   
   Standard_Integer i;
   for (i = Weights.Lower(); i <= Weights.Upper(); i++) {
     if (Weights(i) <= gp::Resolution())  
-      Standard_ConstructionError::Raise("Law_BSpline");
+      throw Standard_ConstructionError("Law_BSpline");
   }
   
   // check really rational
@@ -324,7 +324,7 @@ void Law_BSpline::IncreaseDegree  (const Standard_Integer Degree)
   if (Degree == deg) return;
   
   if (Degree < deg || Degree > Law_BSpline::MaxDegree()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   
   Standard_Integer FromK1 = FirstUKnotIndex ();
@@ -460,7 +460,7 @@ void  Law_BSpline::InsertKnots(const TColStd_Array1OfReal& Knots,
   if (!BSplCLib::PrepareInsertKnots(deg,periodic,
                                    knots->Array1(),mults->Array1(),
                                    Knots,&Mults,nbpoles,nbknots,Epsilon,Add))
-    Standard_ConstructionError::Raise("Law_BSpline::InsertKnots");
+    throw Standard_ConstructionError("Law_BSpline::InsertKnots");
   
   if (nbpoles == poles->Length()) return;
   
@@ -518,10 +518,10 @@ Standard_Boolean  Law_BSpline::RemoveKnot(const Standard_Integer Index,
   Standard_Integer I2  = LastUKnotIndex  ();
   
   if ( !periodic && (Index <= I1 || Index >= I2) ) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   else if ( periodic  && (Index < I1 || Index > I2)) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   
   const TColStd_Array1OfReal   & oldpoles   = poles->Array1();
@@ -601,9 +601,9 @@ void Law_BSpline::InsertPoleAfter
  const Standard_Real& P,
  const Standard_Real Weight)
 {
-  if (Index < 0 || Index > poles->Length())  Standard_OutOfRange::Raise();
+  if (Index < 0 || Index > poles->Length())  throw Standard_OutOfRange();
   
-  if (Weight <= gp::Resolution())     Standard_ConstructionError::Raise();
+  if (Weight <= gp::Resolution())     throw Standard_ConstructionError();
   
   
   // find the spans which are modified with the inserting pole
@@ -744,12 +744,12 @@ void Law_BSpline::InsertPoleBefore
 void Law_BSpline::RemovePole
 (const Standard_Integer Index)
 {
-  if (Index < 1 || Index > poles->Length())  Standard_OutOfRange::Raise();
+  if (Index < 1 || Index > poles->Length())  throw Standard_OutOfRange();
   
-  if (poles->Length() <= 2)           Standard_ConstructionError::Raise();
+  if (poles->Length() <= 2)           throw Standard_ConstructionError();
   
   if (knotSet == GeomAbs_NonUniform || knotSet == GeomAbs_PiecewiseBezier) 
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   
   Standard_Integer i;
   Handle(TColStd_HArray1OfReal) nknots =
@@ -957,20 +957,20 @@ void Law_BSpline::SetKnot
 (const Standard_Integer Index,
  const Standard_Real K)
 {
-  if (Index < 1 || Index > knots->Length())     Standard_OutOfRange::Raise();
+  if (Index < 1 || Index > knots->Length())     throw Standard_OutOfRange();
   Standard_Real DK = Abs(Epsilon (K));
   if (Index == 1) { 
-    if (K >= knots->Value(2) - DK) Standard_ConstructionError::Raise();
+    if (K >= knots->Value(2) - DK) throw Standard_ConstructionError();
   }
   else if (Index == knots->Length()) {
     if (K <= knots->Value (knots->Length()-1) + DK)  {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   }
   else {
     if (K <= knots->Value(Index-1) + DK ||
        K >= knots->Value(Index+1) - DK ) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   }
   if (K != knots->Value (Index)) {
@@ -1202,7 +1202,7 @@ void Law_BSpline::SetPole
 (const Standard_Integer Index,
  const Standard_Real P)
 {
-  if (Index < 1 || Index > poles->Length()) Standard_OutOfRange::Raise();
+  if (Index < 1 || Index > poles->Length()) throw Standard_OutOfRange();
   poles->SetValue (Index, P);
 }
 
@@ -1230,9 +1230,9 @@ void Law_BSpline::SetWeight
 (const Standard_Integer Index,
  const Standard_Real W)
 {
-  if (Index < 1 || Index > poles->Length())   Standard_OutOfRange::Raise();
+  if (Index < 1 || Index > poles->Length())   throw Standard_OutOfRange();
   
-  if (W <= gp::Resolution ())     Standard_ConstructionError::Raise();
+  if (W <= gp::Resolution ())     throw Standard_ConstructionError();
   
   
   Standard_Boolean rat = IsRational() || (Abs(W - 1.) > gp::Resolution());
index b98445b..192b94e 100644 (file)
@@ -28,7 +28,7 @@ Law_BSplineKnotSplitting::
 Law_BSplineKnotSplitting (const Handle(Law_BSpline)& BasisCurve, 
                           const Standard_Integer ContinuityRange)
 {
-  if (ContinuityRange < 0)  Standard_RangeError::Raise();
+  if (ContinuityRange < 0)  throw Standard_RangeError();
 
   Standard_Integer FirstIndex = BasisCurve->FirstUKnotIndex();
   Standard_Integer LastIndex  = BasisCurve->LastUKnotIndex();
index 8742bf1..81aa004 100644 (file)
@@ -60,8 +60,7 @@ Law_Composite::Law_Composite(const Standard_Real First,
 //=======================================================================
 GeomAbs_Shape Law_Composite::Continuity() const 
 {
-  Standard_NotImplemented::Raise("Law_Composite::Continuity()");
-  return GeomAbs_C0;
+  throw Standard_NotImplemented("Law_Composite::Continuity()");
 }
 
 //=======================================================================
index 795b7c1..1c1e222 100644 (file)
@@ -127,7 +127,7 @@ static void BuildTangents(const TColStd_Array1OfReal&  PointsArray,
   Standard_Real *point_array, *parameter_array, eval_result[2];
   
   if ( PointsArray.Length() < 3) {
-    Standard_ConstructionError::Raise(); 
+    throw Standard_ConstructionError();
   }   
   if (PointsArray.Length() == 3) {
     degree = 2;
@@ -210,7 +210,7 @@ Law_Interpolate::Law_Interpolate
 //Standard_Integer ii;
   if (PeriodicFlag) {
     if ((PointsPtr->Length()) + 1 != ParametersPtr->Length()) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
   }
   myTangents = new TColStd_HArray1OfReal(myPoints->Lower(),
@@ -219,7 +219,7 @@ Law_Interpolate::Law_Interpolate
                                                myPoints->Upper());
   Standard_Boolean result = CheckParameters(ParametersPtr->Array1());
   if (!result) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   myTangentFlags->Init(Standard_False);
 }
@@ -239,7 +239,7 @@ void Law_Interpolate::Load
   myTangentFlags = TangentFlagsPtr;
   if (Tangents.Length() != myPoints->Length() ||
       TangentFlagsPtr->Length() != myPoints->Length()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   myTangents = new TColStd_HArray1OfReal(Tangents.Lower(),Tangents.Upper());
   for (ii = Tangents.Lower() ; ii <= Tangents.Upper() ; ii++ ) {
@@ -634,7 +634,7 @@ void Law_Interpolate::PerformNonPeriodic()
 const Handle(Law_BSpline)& Law_Interpolate::Curve() const 
 {
   if ( !myIsDone) 
-    StdFail_NotDone::Raise(" ");
+    throw StdFail_NotDone(" ");
   return myCurve;
 }
 
index af88006..d7fcef9 100644 (file)
@@ -146,12 +146,12 @@ static Handle(LibCtl_Node) thelast;
 
     const Handle(TheModule)& LibCtl_Library::Module () const
 {
-  if (thecurr.IsNull()) Standard_NoSuchObject::Raise("Library from LibCtl");
+  if (thecurr.IsNull()) throw Standard_NoSuchObject("Library from LibCtl");
   return thecurr->Module();
 }
 
     const Handle(TheProtocol)& LibCtl_Library::Protocol () const
 {
-  if (thecurr.IsNull()) Standard_NoSuchObject::Raise("Library from LibCtl");
+  if (thecurr.IsNull()) throw Standard_NoSuchObject("Library from LibCtl");
   return thecurr->Protocol();
 }
index 4c42e99..ed785c0 100644 (file)
@@ -292,7 +292,7 @@ static void Add(const Standard_Integer ind,
 
 {
   if (!mapI.Add(ind)) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   TopTools_ListIteratorOfListOfShape itl(mapEF(ind));
@@ -306,7 +306,7 @@ static void Add(const Standard_Integer ind,
        const TopoDS_Shape& edg = exp.Current();
        Standard_Integer indedg = mapEF.FindIndex(edg);
        if (indedg == 0) {
-         Standard_ConstructionError::Raise();
+         throw Standard_ConstructionError();
        }
        if (!mapI.Contains(indedg)) {
          Add(indedg,mapI,mapF,mapEF);
index dd2264a..a4d8f26 100644 (file)
@@ -139,7 +139,7 @@ void LocOpe_BuildWires::Perform(const TopTools_ListOfShape& L,
       }
 
       if (!anIterl.More()) {
-       Standard_ConstructionError::Raise();
+       throw Standard_ConstructionError();
       }
       const TopoDS_Edge& theEdge = TopoDS::Edge(anIterl.Value());
       TopoDS_Vertex Vf,Vl;
@@ -232,7 +232,7 @@ Standard_Boolean LocOpe_BuildWires::IsDone() const
 const TopTools_ListOfShape& LocOpe_BuildWires::Result () const
 {
   if (!myDone) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   return myRes;
 }
index 0876f30..e649213 100644 (file)
@@ -79,7 +79,7 @@ void LocOpe_CSIntersector::Init(const TopoDS_Shape& S)
 void LocOpe_CSIntersector::Perform(const LocOpe_SequenceOfLin& Slin)
 {
   if (myShape.IsNull() || Slin.Length() <= 0) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   myDone = Standard_False;
 
@@ -115,7 +115,7 @@ void LocOpe_CSIntersector::Perform(const LocOpe_SequenceOfLin& Slin)
 void LocOpe_CSIntersector::Perform(const LocOpe_SequenceOfCirc& Scir)
 {
   if (myShape.IsNull() || Scir.Length() <= 0) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   myDone = Standard_False;
 
@@ -157,7 +157,7 @@ void LocOpe_CSIntersector::Perform(const LocOpe_SequenceOfCirc& Scir)
 void LocOpe_CSIntersector::Perform(const TColGeom_SequenceOfCurve& Scur)
 {
   if (myShape.IsNull() || Scur.Length() <= 0) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   myDone = Standard_False;
 
@@ -199,9 +199,9 @@ void LocOpe_CSIntersector::Perform(const TColGeom_SequenceOfCurve& Scur)
 Standard_Integer LocOpe_CSIntersector::NbPoints
    (const Standard_Integer I) const
 {
-  if (!myDone) {StdFail_NotDone::Raise();}
+  if (!myDone) {throw StdFail_NotDone();}
   if (I <= 0 || I > myNbelem) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return ((LocOpe_SequenceOfPntFace *)myPoints)[I-1].Length();
 }
@@ -215,9 +215,9 @@ const LocOpe_PntFace& LocOpe_CSIntersector::
    Point(const Standard_Integer I,
         const Standard_Integer Index) const
 {
-  if (!myDone) {StdFail_NotDone::Raise();}
+  if (!myDone) {throw StdFail_NotDone();}
   if (I <= 0 || I > myNbelem) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return ((LocOpe_SequenceOfPntFace *)myPoints)[I-1](Index);
 }
@@ -250,10 +250,10 @@ Standard_Boolean LocOpe_CSIntersector::LocalizeAfter
     Standard_Integer& IndTo) const
 {
   if (!myDone) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   if (I <= 0 || I > myNbelem) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return LocAfter((((LocOpe_SequenceOfPntFace*)myPoints)[I-1]),
                  From,Tol,Or,IndFrom,IndTo);
@@ -274,10 +274,10 @@ Standard_Boolean LocOpe_CSIntersector::LocalizeBefore
     Standard_Integer& IndTo) const
 {
   if (!myDone) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   if (I <= 0 || I > myNbelem) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return LocBefore(((LocOpe_SequenceOfPntFace*)myPoints)[I-1],
                   From,Tol,Or,IndFrom,IndTo);
@@ -297,10 +297,10 @@ Standard_Boolean LocOpe_CSIntersector::LocalizeAfter
     Standard_Integer& IndTo) const
 {
   if (!myDone) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   if (I <= 0 || I > myNbelem) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return LocAfter(((LocOpe_SequenceOfPntFace*)myPoints)[I-1],
                  FromInd,Tol,Or,IndFrom,IndTo);
@@ -321,10 +321,10 @@ Standard_Boolean LocOpe_CSIntersector::LocalizeBefore
     Standard_Integer& IndTo) const
 {
   if (!myDone) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   if (I <= 0 || I > myNbelem) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return LocBefore(((LocOpe_SequenceOfPntFace*)myPoints)[I-1],
                   FromInd,Tol,Or,IndFrom,IndTo);
index 8d8fc37..1f88d0e 100644 (file)
@@ -92,7 +92,7 @@ Standard_Boolean LocOpe_CurveShapeIntersector::LocalizeAfter
     Standard_Integer& IndTo) const
 {
   if (!myDone) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   Standard_Real Eps = Precision::Confusion();
   Standard_Real param,FMEPS = From - Eps;
@@ -149,7 +149,7 @@ Standard_Boolean LocOpe_CurveShapeIntersector::LocalizeBefore
     Standard_Integer& IndTo) const
 {
   if (!myDone) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   Standard_Real Eps = Precision::Confusion();
   Standard_Real param,FPEPS = From + Eps;
@@ -206,7 +206,7 @@ Standard_Boolean LocOpe_CurveShapeIntersector::LocalizeAfter
     Standard_Integer& IndTo) const
 {
   if (!myDone) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   Standard_Integer nbpoints = myPoints.Length();
   if (FromInd >= nbpoints) {
@@ -275,7 +275,7 @@ Standard_Boolean LocOpe_CurveShapeIntersector::LocalizeBefore
     Standard_Integer& IndTo) const
 {
   if (!myDone) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   Standard_Integer nbpoints = myPoints.Length();
   if (FromInd <= 1) {
index 7f3743f..d97a4c6 100644 (file)
@@ -70,7 +70,7 @@ inline Standard_Boolean LocOpe_CurveShapeIntersector::IsDone () const
 
 inline Standard_Integer LocOpe_CurveShapeIntersector::NbPoints() const
 {
-  if (!myDone) {StdFail_NotDone::Raise();}
+  if (!myDone) {throw StdFail_NotDone();}
   return myPoints.Length();
 }
 
@@ -82,7 +82,7 @@ inline Standard_Integer LocOpe_CurveShapeIntersector::NbPoints() const
 inline const LocOpe_PntFace& LocOpe_CurveShapeIntersector::
    Point(const Standard_Integer I) const
 {
-  if (!myDone) {StdFail_NotDone::Raise();}
+  if (!myDone) {throw StdFail_NotDone();}
   return myPoints(I);
 }
     
index fe41a4a..8da855d 100644 (file)
@@ -534,7 +534,7 @@ Standard_Boolean LocOpe_DPrism::IsDone() const
 const TopoDS_Shape& LocOpe_DPrism::Shape () const
 {
   if (!myDPrism.IsDone()) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   return myRes;
 }
@@ -591,7 +591,7 @@ const TopTools_ListOfShape&
  LocOpe_DPrism::Shapes (const TopoDS_Shape& S)const
 {
   if (!myDPrism.IsDone()) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   if (myMap.IsBound(S)) {
     return myMap(S);
@@ -625,7 +625,7 @@ void LocOpe_DPrism::Curves(TColGeom_SequenceOfCurve& Scurves) const
 
   Handle(Geom_Plane) PP = Handle(Geom_Plane)::DownCast(S);
   if (PP.IsNull()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   gp_Pln P = PP->Pln();
@@ -696,7 +696,7 @@ Handle(Geom_Curve) LocOpe_DPrism::BarycCurve() const
 
   Handle(Geom_Plane) PP = Handle(Geom_Plane)::DownCast(S);
   if (PP.IsNull()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   gp_Pln P = PP->Pln();
index 485618b..05b6746 100644 (file)
@@ -85,7 +85,7 @@ static Standard_Real NewParameter(const TopoDS_Edge&,
 void LocOpe_Generator::Perform(const Handle(LocOpe_GeneratedShape)& G)
 {
   if (myShape.IsNull()) {
-    Standard_NullObject::Raise();
+    throw Standard_NullObject();
   }
   myDone = Standard_False;
   myRes.Nullify();
@@ -1043,7 +1043,7 @@ void LocOpe_Generator::Perform(const Handle(LocOpe_GeneratedShape)& G)
 {
  // TopTools_ListOfShape list;
 
-  if (!myDone) {StdFail_NotDone::Raise();}
+  if (!myDone) {throw StdFail_NotDone();}
   return myModShapes(F);
 }
 
index 7cdfb0f..8b8d167 100644 (file)
@@ -77,7 +77,7 @@ inline const TopoDS_Shape& LocOpe_Generator::Shape() const
 
 inline const TopoDS_Shape& LocOpe_Generator::ResultingShape() const
 {
-  if (!myDone) {StdFail_NotDone::Raise();}
+  if (!myDone) {throw StdFail_NotDone();}
   return myRes;
 }
 
index bdf6895..8c4b9ac 100644 (file)
@@ -80,7 +80,7 @@ void LocOpe_GluedShape::GlueOnFace(const TopoDS_Face& F)
     }
   }
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   myMap.Add(exp.Current()); // bonne orientation
 }
@@ -117,7 +117,7 @@ void LocOpe_GluedShape::MapEdgeAndVertices()
       }
       // Est-ce un edge de connexite entre les faces collees
       if (theMapEF.FindFromKey(edg).Extent() != 2) {
-       Standard_ConstructionError::Raise();
+       throw Standard_ConstructionError();
       }
       for (itl.Initialize(theMapEF.FindFromKey(edg)); itl.More(); itl.Next()) {
        if (!myMap.Contains(itl.Value())) {
index ab711e8..c53b67f 100644 (file)
@@ -90,7 +90,7 @@ void LocOpe_Gluer::Bind(const TopoDS_Face& Fnew,
     }
   }
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   TopoDS_Shape aLocalFace =  Fnew.Oriented(exp.Current().Orientation());
@@ -103,7 +103,7 @@ void LocOpe_Gluer::Bind(const TopoDS_Face& Fnew,
     }
   }
   if (!exp.More()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   aLocalFace = Fbase.Oriented(exp.Current().Orientation());
@@ -153,7 +153,7 @@ void LocOpe_Gluer::Bind(const TopoDS_Edge& Enew,
                        const TopoDS_Edge& Ebase)
 {
   if (myMapEE.IsBound(Enew) && !myMapEE(Enew).IsSame(Ebase)) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   myMapEE.Bind(Enew,Ebase);
 }
@@ -172,7 +172,7 @@ void LocOpe_Gluer::Perform()
   }
   if (mySb.IsNull() || mySn.IsNull() || 
       myMapEF.IsEmpty() || myOpe ==LocOpe_INVALID) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   Handle(LocOpe_WiresOnShape) theWOnS = new LocOpe_WiresOnShape(mySb);
@@ -330,7 +330,7 @@ void LocOpe_Gluer::Perform()
 const TopTools_ListOfShape& LocOpe_Gluer::DescendantFaces
    (const TopoDS_Face& F) const
 {
-  if (!myDone) {StdFail_NotDone::Raise();}
+  if (!myDone) {throw StdFail_NotDone();}
   if (myDescF.IsBound(F))
     return myDescF(F);
   static TopTools_ListOfShape nullList;
index eaa6d06..fa6ba03 100644 (file)
@@ -57,7 +57,7 @@ inline Standard_Boolean LocOpe_Gluer::IsDone() const
 inline const TopoDS_Shape& LocOpe_Gluer::ResultingShape () const
 {
   if (!myDone) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   return myRes;
 }
index 0593997..e9b9570 100644 (file)
@@ -218,7 +218,7 @@ void LocOpe_LinearForm::IntPerf()
 const TopoDS_Shape& LocOpe_LinearForm::Shape () const
 {
   if (!myDone) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   return myRes;
 }
index 345b308..9b377f6 100644 (file)
@@ -269,7 +269,7 @@ const TopTools_ListOfShape& LocOpe_Pipe::Shapes (const TopoDS_Shape& S)
 {
   TopAbs_ShapeEnum typS = S.ShapeType();
   if (typS != TopAbs_EDGE && typS != TopAbs_VERTEX) {
-    Standard_DomainError::Raise();
+    throw Standard_DomainError();
   }
 //  for (TopExp_Explorer exp(myPipe.Profile(),typS); exp.More(); exp.Next()) {
   TopExp_Explorer exp(myPipe.Profile(),typS) ;
@@ -279,7 +279,7 @@ const TopTools_ListOfShape& LocOpe_Pipe::Shapes (const TopoDS_Shape& S)
     }
   }
   if (!exp.More()) {
-    Standard_NoSuchObject::Raise();
+    throw Standard_NoSuchObject();
   }
 
   myGShap.Clear();
@@ -412,8 +412,7 @@ static TopAbs_Orientation Orientation(const TopoDS_Shape& Sub,
       return exp.Current().Orientation();
     }
   }
-  Standard_NoSuchObject::Raise();
-  return TopAbs_INTERNAL;
+  throw Standard_NoSuchObject();
 }
 
 
index f1fbec6..7b6ca49 100644 (file)
@@ -228,7 +228,7 @@ void LocOpe_Prism::IntPerf()
 const TopoDS_Shape& LocOpe_Prism::Shape () const
 {
   if (!myDone) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   return myRes;
 }
index a163115..2e5f1ad 100644 (file)
@@ -212,7 +212,7 @@ void LocOpe_Revol::IntPerf()
 const TopoDS_Shape& LocOpe_Revol::Shape () const
 {
   if (!myDone) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   return myRes;
 }
index 30b465c..ce08089 100644 (file)
@@ -183,7 +183,7 @@ void LocOpe_RevolutionForm::IntPerf()
 const TopoDS_Shape& LocOpe_RevolutionForm::Shape () const
 {
   if (!myDone) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   return myRes;
 }
index e6418e8..553623f 100644 (file)
@@ -138,11 +138,11 @@ void LocOpe_SplitDrafts::Perform(const TopoDS_Face& F,
   myResult.Nullify();
   myMap.Clear();
   if (myShape.IsNull() || F.IsNull() || W.IsNull()) {
-    Standard_NullObject::Raise();
+    throw Standard_NullObject();
   }    
 
   if (!ModLeft && !ModRight) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   TopAbs_Orientation OriF = TopAbs_FORWARD;
@@ -160,8 +160,8 @@ void LocOpe_SplitDrafts::Perform(const TopoDS_Face& F,
   }
 
   if (!FinS) {
-    cout << "LocOpe_SplitDrafts:!Fins Standard_ConstructionError::Raise()" << endl;
-    Standard_ConstructionError::Raise();
+    cout << "LocOpe_SplitDrafts:!Fins throw Standard_ConstructionError()" << endl;
+    throw Standard_ConstructionError();
   }    
 
   gp_Pln NewPlg,NewPld;
@@ -204,7 +204,7 @@ void LocOpe_SplitDrafts::Perform(const TopoDS_Face& F,
     thePipe.Init(theLinePipe,i2s.Line(1));
     thePipe.Perform(Standard_True);
     if (!thePipe.IsDone())
-      Standard_ConstructionError::Raise ("GeomFill_Pipe : Cannot make a surface");
+      throw Standard_ConstructionError("GeomFill_Pipe : Cannot make a surface");
 
     Handle(Geom_Surface) Spl = thePipe.Surface();
     AS.Load(Spl);
@@ -418,7 +418,7 @@ void LocOpe_SplitDrafts::Perform(const TopoDS_Face& F,
        thePipe.Init(theLinePipe,C);
        thePipe.Perform(Standard_True);
         if (!thePipe.IsDone())
-          Standard_ConstructionError::Raise ("GeomFill_Pipe : Cannot make a surface");
+          throw Standard_ConstructionError("GeomFill_Pipe : Cannot make a surface");
 
        Handle(Geom_Surface) thePS = thePipe.Surface();
        if (thePS->DynamicType() == STANDARD_TYPE(Geom_RectangularTrimmedSurface)) {
@@ -1294,7 +1294,7 @@ void LocOpe_SplitDrafts::Perform(const TopoDS_Face& F,
 const TopoDS_Shape& LocOpe_SplitDrafts::Shape () const
 {
   if (myResult.IsNull()) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   return myResult;
 }
@@ -1308,7 +1308,7 @@ const TopTools_ListOfShape& LocOpe_SplitDrafts::ShapesFromShape
    (const TopoDS_Shape& S) const
 {
   if (myResult.IsNull()) {
-    StdFail_NotDone::Raise();
+    throw StdFail_NotDone();
   }
   return myMap(S);
 }
index 14a6c4f..04e1c52 100644 (file)
@@ -1165,7 +1165,7 @@ const TopTools_ListOfShape& LocOpe_SplitShape::LeftOf(const TopoDS_Wire& W,
                                                       const TopoDS_Face& F)
 {
   if (myShape.IsNull()) {
-    Standard_NoSuchObject::Raise();
+    throw Standard_NoSuchObject();
   }
 
   TopExp_Explorer exp,expw,expf;
@@ -1176,7 +1176,7 @@ const TopTools_ListOfShape& LocOpe_SplitShape::LeftOf(const TopoDS_Wire& W,
     }
   }
   if (!exp.More()) {
-    Standard_NoSuchObject::Raise();
+    throw Standard_NoSuchObject();
   }
   myLeft.Clear();
 
index f342c85..547998a 100644 (file)
@@ -72,7 +72,7 @@ static void Select(const TopoDS_Edge&,
 void LocOpe_Spliter::Perform(const Handle(LocOpe_WiresOnShape)& PW)
 {
   if (myShape.IsNull()) {
-    Standard_NullObject::Raise();
+    throw Standard_NullObject();
   }
   myDone = Standard_False;
   myMap.Clear();
@@ -126,7 +126,7 @@ void LocOpe_Spliter::Perform(const Handle(LocOpe_WiresOnShape)& PW)
        const TopTools_ListOfShape& lsub = theSubs.Copy(itdesc.Key());
 #ifdef OCCT_DEBUG
        if (lsub.Extent() != 1) {
-         Standard_ConstructionError::Raise();
+         throw Standard_ConstructionError();
        }
 #endif
        myMap(itdesc.Key()).Clear(); 
@@ -307,7 +307,7 @@ void LocOpe_Spliter::Perform(const Handle(LocOpe_WiresOnShape)& PW)
        const TopTools_ListOfShape& lsub = theSubs.Copy(itl.Value());
 #ifdef OCCT_DEBUG
        if (lsub.Extent() != 1) {
-         Standard_ConstructionError::Raise();
+         throw Standard_ConstructionError();
        }
 #endif
        newdesc.Append(lsub.First());
@@ -502,7 +502,7 @@ void LocOpe_Spliter::Perform(const Handle(LocOpe_WiresOnShape)& PW)
 const TopTools_ListOfShape& LocOpe_Spliter::
    DescendantShapes(const TopoDS_Shape& F)
 {
-  if (!myDone) {StdFail_NotDone::Raise();}
+  if (!myDone) {throw StdFail_NotDone();}
   if (myMap.IsBound(F))
     return myMap(F);
   else {
@@ -519,7 +519,7 @@ const TopTools_ListOfShape& LocOpe_Spliter::
 
 const TopTools_ListOfShape& LocOpe_Spliter::DirectLeft() const
 {
-  if (!myDone) {StdFail_NotDone::Raise();}
+  if (!myDone) {throw StdFail_NotDone();}
   return myDLeft;
 
 }
@@ -532,7 +532,7 @@ const TopTools_ListOfShape& LocOpe_Spliter::DirectLeft() const
 
 const TopTools_ListOfShape& LocOpe_Spliter::Left() const
 {
-  if (!myDone) {StdFail_NotDone::Raise();}
+  if (!myDone) {throw StdFail_NotDone();}
   return myLeft;
 
 }
@@ -551,7 +551,7 @@ static void RebuildWires(TopTools_ListOfShape& ledge,
   LocOpe_BuildWires theBuild(ledge, PW);
 //  Modified by skv - Mon May 31 12:31:40 2004 OCC5865 End
   if (!theBuild.IsDone()) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
   ledge = theBuild.Result();
 
index e3100fa..dc47c53 100644 (file)
@@ -77,7 +77,7 @@ inline const TopoDS_Shape& LocOpe_Spliter::Shape() const
 
 inline const TopoDS_Shape& LocOpe_Spliter::ResultingShape() const
 {
-  if (!myDone) {StdFail_NotDone::Raise();}
+  if (!myDone) {throw StdFail_NotDone();}
   return myRes;
 }
 
index be1bfd2..2861396 100644 (file)
@@ -176,7 +176,7 @@ void LocOpe_WiresOnShape::Bind(const TopoDS_Edge& E,
     }
   }
   else {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 }
 
@@ -930,7 +930,7 @@ void PutPCurves(const TopoDS_Edge& Efrom,
   }
 
   if (Lfaces.Extent() != 1 && Lfaces.Extent() !=2) {
-    Standard_ConstructionError::Raise();
+    throw Standard_ConstructionError();
   }
 
   // soit bord libre, soit connexite entre 2 faces, eventuellement edge closed
@@ -1077,7 +1077,7 @@ void PutPCurves(const TopoDS_Edge& Efrom,
   else {
     const TopoDS_Face& Fac = TopoDS::Face(Lfaces.First());
     if (!BRep_Tool::IsClosed(Eto,Fac)) {
-      Standard_ConstructionError::Raise();
+      throw Standard_ConstructionError();
     }
 
     TopoDS_Shape aLocalE = Efrom.Oriented(TopAbs_FORWARD);
index de2364c..ca70109 100644 (file)
@@ -201,7 +201,7 @@ LocalAnalysis_CurveContinuity::LocalAnalysis_CurveContinuity(const Handle(Geom_C
 
 Standard_Boolean LocalAnalysis_CurveContinuity::IsC0() const 
 { 
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   if (myContC0 <= myepsC0 )
      return Standard_True;
      else return Standard_False;
@@ -211,7 +211,7 @@ Standard_Boolean LocalAnalysis_CurveContinuity::IsC0() const
 
 Standard_Boolean LocalAnalysis_CurveContinuity::IsC1() const  
 {
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   if ( IsC0() && ( (myContC1 <= myepsC1)||(Abs(myContC1-M_PI)<=myepsC1)))
      return Standard_True;
      else return Standard_False;       
@@ -222,7 +222,7 @@ Standard_Boolean LocalAnalysis_CurveContinuity::IsC1() const
 Standard_Boolean LocalAnalysis_CurveContinuity::IsC2() const  
 { Standard_Real epsil1, epsil2;
 
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   if ( IsC1())
     { if ((myContC2 <= myepsC2)||(Abs(myContC2-M_PI)<=myepsC2))
       { epsil1 = 0.5*myepsC1*myepsC1*myLambda1;
@@ -240,7 +240,7 @@ Standard_Boolean LocalAnalysis_CurveContinuity::IsC2() const
 
 Standard_Boolean LocalAnalysis_CurveContinuity::IsG1() const  
 {
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
  if ( IsC0() && (( myContG1 <= myepsG1||(Abs(myContG1-M_PI)<=myepsG1))))
      return Standard_True;
      else return Standard_False;       
@@ -255,7 +255,7 @@ Standard_Boolean LocalAnalysis_CurveContinuity::IsG2()const
        //                         -> 1 Crbure finie
        //                         -> 2 Crbure infinie
 
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   if ( IsG1 ())
      { CRBINF = 1/myepsC0;
        CRBNUL = 8*myepsC0/(myMaxLon*myMaxLon);
@@ -286,7 +286,7 @@ Standard_Boolean LocalAnalysis_CurveContinuity::IsG2()const
 
 Standard_Real LocalAnalysis_CurveContinuity::C0Value() const 
 { 
-  if (!myIsDone) {StdFail_NotDone::Raise();}
+  if (!myIsDone) {throw StdFail_NotDone();}
   return ( myContC0 );
 }
 
@@ -294,7 +294,7 @@ Standard_Real LocalAnalysis_CurveContinuity::C0Value() const
 
 Standard_Real LocalAnalysis_CurveContinuity::C1Angle() const 
 {
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   return ( myContC1 );
 }
 
@@ -302,7 +302,7 @@ Standard_Real LocalAnalysis_CurveContinuity::C1Angle() const
 
 Standard_Real LocalAnalysis_CurveContinuity::C2Angle() const 
 {
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   return ( myContC2 );
 }
 
@@ -310,14 +310,14 @@ Standard_Real LocalAnalysis_CurveContinuity::C2Angle() const
 
 Standard_Real LocalAnalysis_CurveContinuity::G1Angle() const 
 {
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   return ( myContG1    );
 }
 /*********************************************************************************/
 
 Standard_Real LocalAnalysis_CurveContinuity::G2Angle() const 
 {
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   return ( myContG2    );
 }
 
@@ -327,7 +327,7 @@ Standard_Real LocalAnalysis_CurveContinuity::G2Angle() const
 
 Standard_Real LocalAnalysis_CurveContinuity::C1Ratio() const 
 {
-  if (!myIsDone) {StdFail_NotDone::Raise();}
+  if (!myIsDone) {throw StdFail_NotDone();}
   return ( myLambda1    );
 }
 
@@ -335,14 +335,14 @@ Standard_Real LocalAnalysis_CurveContinuity::C1Ratio() const
 
 Standard_Real LocalAnalysis_CurveContinuity::C2Ratio() const 
 {
-  if (!myIsDone) {StdFail_NotDone::Raise();}
+  if (!myIsDone) {throw StdFail_NotDone();}
   return ( myLambda2    );
 }
 
 /********************************************************************************/
 Standard_Real LocalAnalysis_CurveContinuity::G2CurvatureVariation() const 
 {
-  if (!myIsDone) {StdFail_NotDone::Raise();}
+  if (!myIsDone) {throw StdFail_NotDone();}
   return ( myG2Variation);
 }
 
@@ -362,7 +362,7 @@ return  myErrorStatus;
 /*************************************************************************/
 GeomAbs_Shape  LocalAnalysis_CurveContinuity::ContinuityStatus() const 
 {
- if (!myIsDone) { StdFail_NotDone::Raise();}
+ if (!myIsDone) { throw StdFail_NotDone();}
  return (myTypeCont);
 }
 /*********************************************************************************/
index 1c78d75..177fda6 100644 (file)
@@ -373,7 +373,7 @@ LocalAnalysis_SurfaceContinuity::LocalAnalysis_SurfaceContinuity(const Handle(Ge
 /*********************************************************************************/
 
 Standard_Boolean LocalAnalysis_SurfaceContinuity::IsC0() const 
-{ if (!myIsDone) { StdFail_NotDone::Raise();}
+{ if (!myIsDone) { throw StdFail_NotDone();}
   if ( myContC0 <= myepsC0 ) 
      return Standard_True;
      else return Standard_False;
@@ -382,7 +382,7 @@ Standard_Boolean LocalAnalysis_SurfaceContinuity::IsC0() const
 /*********************************************************************************/
 
 Standard_Boolean LocalAnalysis_SurfaceContinuity::IsC1() const 
-{ if (!myIsDone) { StdFail_NotDone::Raise();}
+{ if (!myIsDone) { throw StdFail_NotDone();}
   if ( IsC0 () && (myContC1U <= myepsC1) && (myContC1V <= myepsC1))
    return Standard_True;
   else return Standard_False;
@@ -393,7 +393,7 @@ Standard_Boolean LocalAnalysis_SurfaceContinuity::IsC1() const
 Standard_Boolean LocalAnalysis_SurfaceContinuity::IsC2() const 
 { Standard_Real eps1u, eps1v, eps2u, eps2v;
 
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   if ( IsC1())
      { eps1u = 0.5*myepsC1*myepsC1*myLambda1U;
        eps1v = 0.5*myepsC1*myepsC1*myLambda1V;
@@ -416,7 +416,7 @@ Standard_Boolean LocalAnalysis_SurfaceContinuity::IsC2() const
 
 Standard_Boolean LocalAnalysis_SurfaceContinuity::IsG1() const 
 {
-  if (!myIsDone) { StdFail_NotDone::Raise();} 
+  if (!myIsDone) { throw StdFail_NotDone();} 
   if ( IsC0 () &&( myContG1 <= myepsG1))
        return Standard_True;
       else return Standard_False;
@@ -428,7 +428,7 @@ Standard_Boolean LocalAnalysis_SurfaceContinuity::IsG2()const
 { Standard_Real EPSNL;
   Standard_Integer itype;
  
-  if (!myIsDone) { StdFail_NotDone::Raise();} 
+  if (!myIsDone) { throw StdFail_NotDone();} 
   itype =0;
   EPSNL= 8*myepsC0/(mymaxlen*mymaxlen);
   if ( IsG1())
@@ -465,7 +465,7 @@ Standard_Boolean LocalAnalysis_SurfaceContinuity::IsG2()const
 
 GeomAbs_Shape  LocalAnalysis_SurfaceContinuity::ContinuityStatus() const 
 {
- if (!myIsDone) { StdFail_NotDone::Raise();}
+ if (!myIsDone) { throw StdFail_NotDone();}
  return (myTypeCont);
 }
 
@@ -473,7 +473,7 @@ GeomAbs_Shape  LocalAnalysis_SurfaceContinuity::ContinuityStatus() const
 
 Standard_Real LocalAnalysis_SurfaceContinuity::C0Value() const 
 { 
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   return ( myContC0    );
 }
 
@@ -481,7 +481,7 @@ Standard_Real LocalAnalysis_SurfaceContinuity::C0Value() const
 
 Standard_Real LocalAnalysis_SurfaceContinuity::C1UAngle() const 
 {
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   return ( myContC1U    );
 }
 
@@ -489,7 +489,7 @@ Standard_Real LocalAnalysis_SurfaceContinuity::C1UAngle() const
 
 Standard_Real LocalAnalysis_SurfaceContinuity::C1VAngle() const 
 {
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   return ( myContC1V    );
 }
 
@@ -497,7 +497,7 @@ Standard_Real LocalAnalysis_SurfaceContinuity::C1VAngle() const
 
 Standard_Real LocalAnalysis_SurfaceContinuity::C2UAngle() const 
 {
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   return ( myContC2U    );
 }
 
@@ -505,7 +505,7 @@ Standard_Real LocalAnalysis_SurfaceContinuity::C2UAngle() const
 
 Standard_Real LocalAnalysis_SurfaceContinuity::C2VAngle() const 
 {
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   return ( myContC2V    );
 }
 
@@ -513,7 +513,7 @@ Standard_Real LocalAnalysis_SurfaceContinuity::C2VAngle() const
 
 Standard_Real LocalAnalysis_SurfaceContinuity::G1Angle() const 
 {
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   return ( myContG1    );
 }
 
@@ -521,7 +521,7 @@ Standard_Real LocalAnalysis_SurfaceContinuity::G1Angle() const
 
 Standard_Real LocalAnalysis_SurfaceContinuity::C1URatio() const 
 {
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   return ( myLambda1U    );
 }
 
@@ -529,7 +529,7 @@ Standard_Real LocalAnalysis_SurfaceContinuity::C1URatio() const
 
 Standard_Real LocalAnalysis_SurfaceContinuity::C2URatio() const 
 {
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   return ( myLambda2U    );
 }
 
@@ -537,7 +537,7 @@ Standard_Real LocalAnalysis_SurfaceContinuity::C2URatio() const
 
 Standard_Real LocalAnalysis_SurfaceContinuity::C1VRatio() const 
 {
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   return ( myLambda1V    );
 }
 
@@ -545,7 +545,7 @@ Standard_Real LocalAnalysis_SurfaceContinuity::C1VRatio() const
 
 Standard_Real LocalAnalysis_SurfaceContinuity::C2VRatio() const 
 { 
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
  return ( myLambda2V    );
 }
 
@@ -553,7 +553,7 @@ Standard_Real LocalAnalysis_SurfaceContinuity::C2VRatio() const
 
 Standard_Real LocalAnalysis_SurfaceContinuity::G2CurvatureGap() const 
 {
-  if (!myIsDone) { StdFail_NotDone::Raise();}
+  if (!myIsDone) { throw StdFail_NotDone();}
   return ( myGap    );
 }
 
index ff9b28c..a70e3e5 100644 (file)
@@ -107,8 +107,7 @@ Handle(MAT_Node) MAT_Arc::TheOtherNode(const Handle(MAT_Node)& aNode)const
   else if (SecondNode() == aNode)
     return FirstNode();
   else {
-    Standard_DomainError::Raise("MAT_Arc::TheOtherNode");
-    return aNode;
+    throw Standard_DomainError("MAT_Arc::TheOtherNode");
   }
 }
 
@@ -131,8 +130,7 @@ Standard_Boolean MAT_Arc::HasNeighbour(const Handle(MAT_Node)& aNode,
 //    if (aNode == SecondNode()) return (!secondArcRight == NULL);
     if (aNode == SecondNode()) return (secondArcRight != 0);
   }
-  Standard_DomainError::Raise("MAT_Arc::HasNeighbour");
-  return Standard_False;
+  throw Standard_DomainError("MAT_Arc::HasNeighbour");
 }
 
 //========================================================================
@@ -152,8 +150,7 @@ const
     if (aNode == FirstNode())  return (MAT_Arc*)firstArcRight;
     if (aNode == SecondNode()) return (MAT_Arc*)secondArcRight;
   }
-  Standard_DomainError::Raise("MAT_Arc::Neighbour");
-  return (MAT_Arc*)firstArcLeft;
+  throw Standard_DomainError("MAT_Arc::Neighbour");
 }
 
 //========================================================================
@@ -250,7 +247,7 @@ void  MAT_Arc::SetNeighbour(const MAT_Side aSide,
     else if (aNode == SecondNode())
       secondArcLeft = anArc.operator->();
     else
-     Standard_DomainError::Raise("MAT_Arc::SetNeighbour"); 
+     throw Standard_DomainError("MAT_Arc::SetNeighbour");
   }
   else {
     if (aNode == FirstNode())  
@@ -258,7 +255,7 @@ void  MAT_Arc::SetNeighbour(const MAT_Side aSide,
     else if (aNode == SecondNode())
       secondArcRight = anArc.operator->();
     else
-      Standard_DomainError::Raise("MAT_Arc::SetNeighbour");
+      throw Standard_DomainError("MAT_Arc::SetNeighbour");
   }
 }
 
index 0415f63..2838d2f 100644 (file)
@@ -109,7 +109,7 @@ Standard_Boolean MAT2d_CutCurve::UnModified() const
 
 Standard_Integer MAT2d_CutCurve::NbCurves() const 
 {
-  if (UnModified()) {Standard_OutOfRange::Raise();}
+  if (UnModified()) {throw Standard_OutOfRange();}
   return theCurves.Length();
 }
 
@@ -123,9 +123,9 @@ Handle(Geom2d_TrimmedCurve) MAT2d_CutCurve::Value (
    const Standard_Integer Index) 
 const 
 {
-  if (UnModified()) {Standard_OutOfRange::Raise();}
+  if (UnModified()) {throw Standard_OutOfRange();}
   if ( Index < 1 || Index > theCurves.Length()) {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   return Handle(Geom2d_TrimmedCurve)::DownCast(theCurves.Value(Index));
 }
index 8b4324d..eb5b683 100644 (file)
@@ -1070,7 +1070,7 @@ Standard_Real MAT2d_Tool2d::Distance(const Handle(MAT_Bisector)& Bis,
 void MAT2d_Tool2d::Dump(const Standard_Integer ,
   const Standard_Integer ) const
 {
-  Standard_NotImplemented::Raise();
+  throw Standard_NotImplemented();
 #else
 void MAT2d_Tool2d::Dump(const Standard_Integer bisector,
   const Standard_Integer) const
index d801433..43a3594 100644 (file)
@@ -58,9 +58,9 @@ Standard_EXPORT const char* MeshTest_DrawLinks(const char* theNameStr, void* the
     }
     return theNameStr;
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    return Standard_Failure::Caught()->GetMessageString();
+    return anException.GetMessageString();
   }
 }
 
@@ -102,8 +102,8 @@ Standard_EXPORT const char* MeshTest_DrawTriangles(const char* theNameStr, void*
     }
     return theNameStr;
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    return Standard_Failure::Caught()->GetMessageString();
+    return anException.GetMessageString();
   }
 }
index 3ffcd0b..124b38b 100644 (file)
@@ -115,8 +115,8 @@ static OSD_Timer& chrono() {
   thesubst = 0;
 }
 
-    void  MoniTool_CaseData::AddRaised (const Standard_CString name)
-      {  AddData ( Standard_Failure::Caught(),1,name);  }
+    void  MoniTool_CaseData::AddRaised (const Handle(Standard_Failure)& theException, const Standard_CString name)
+      {  AddData ( theException,1,name);  }
 
     void  MoniTool_CaseData::AddShape
   (const TopoDS_Shape& sh, const Standard_CString name)
index 2fc2826..7dd85a0 100644 (file)
@@ -128,7 +128,7 @@ public:
   Standard_EXPORT void AddData (const Handle(Standard_Transient)& val, const Standard_Integer kind, const Standard_CString name = "");
   
   //! Adds the currently caught exception
-  Standard_EXPORT void AddRaised (const Standard_CString name = "");
+  Standard_EXPORT void AddRaised (const Handle(Standard_Failure)& theException, const Standard_CString name = "");
   
   //! Adds a Shape (recorded as a HShape)
   Standard_EXPORT void AddShape (const TopoDS_Shape& sh, const Standard_CString name = "");
index af10310..a61a16e 100644 (file)
@@ -80,7 +80,7 @@ static Standard_Boolean StaticPath(const Handle(TCollection_HAsciiString)& val)
   if (type != MoniTool_ValueInteger && type != MoniTool_ValueReal &&
       type != MoniTool_ValueEnum    && type != MoniTool_ValueText &&
       type != MoniTool_ValueIdent)
-    Standard_ConstructionError::Raise("MoniTool_TypedValue : Type not supported");
+    throw Standard_ConstructionError("MoniTool_TypedValue : Type not supported");
   if (init[0] != '\0')
     if (Satisfies(new TCollection_HAsciiString(init))) SetCStringValue (init);
 
@@ -315,8 +315,7 @@ static Standard_Boolean StaticPath(const Handle(TCollection_HAsciiString)& val)
     void  MoniTool_TypedValue::SetIntegerLimit
   (const Standard_Boolean max, const Standard_Integer val)
 {
-  if (thetype != MoniTool_ValueInteger) Standard_ConstructionError::Raise
-      ("MoniTool_TypedValue : SetIntegerLimit, not an Integer");
+  if (thetype != MoniTool_ValueInteger) throw Standard_ConstructionError("MoniTool_TypedValue : SetIntegerLimit, not an Integer");
 
   if (max)  {  thelims |= 2;  theintup  = val; }
   else      {  thelims |= 1;  theintlow = val; }
@@ -335,8 +334,7 @@ static Standard_Boolean StaticPath(const Handle(TCollection_HAsciiString)& val)
     void  MoniTool_TypedValue::SetRealLimit
   (const Standard_Boolean max, const Standard_Real val)
 {
-  if (thetype != MoniTool_ValueReal) Standard_ConstructionError::Raise
-      ("MoniTool_TypedValue : SetRealLimit, not a Real");
+  if (thetype != MoniTool_ValueReal) throw Standard_ConstructionError("MoniTool_TypedValue : SetRealLimit, not a Real");
 
   if (max)  {  thelims |= 2;  therealup = val; }
   else      {  thelims |= 1;  therealow = val; }
@@ -362,8 +360,7 @@ static Standard_Boolean StaticPath(const Handle(TCollection_HAsciiString)& val)
     void  MoniTool_TypedValue::StartEnum
   (const Standard_Integer start, const Standard_Boolean match)
 {
-  if (thetype != MoniTool_ValueEnum) Standard_ConstructionError::Raise
-    ("MoniTool_TypedValue : StartEnum, Not an Enum");
+  if (thetype != MoniTool_ValueEnum) throw Standard_ConstructionError("MoniTool_TypedValue : StartEnum, Not an Enum");
 
   thelims |= 4;  if (!match) thelims -= 4;
   theintlow = start;  theintup = start -1;
@@ -376,8 +373,7 @@ static Standard_Boolean StaticPath(const Handle(TCollection_HAsciiString)& val)
    const Standard_CString v7, const Standard_CString v8,
    const Standard_CString v9, const Standard_CString v10)
 {
-  if (thetype != MoniTool_ValueEnum) Standard_ConstructionError::Raise
-    ("MoniTool_TypedValue : AddEnum, Not an Enum");
+  if (thetype != MoniTool_ValueEnum) throw Standard_ConstructionError("MoniTool_TypedValue : AddEnum, Not an Enum");
   if (theenums.IsNull()) theenums =
     new TColStd_HArray1OfAsciiString(theintlow,theintlow+10);
   else if (theenums->Upper() < theintup + 10) {
@@ -433,10 +429,8 @@ static Standard_Boolean StaticPath(const Handle(TCollection_HAsciiString)& val)
     void  MoniTool_TypedValue::AddEnumValue
   (const Standard_CString val, const Standard_Integer num)
 {
-  if (thetype != MoniTool_ValueEnum) Standard_ConstructionError::Raise
-    ("MoniTool_TypedValue : AddEnum, Not an Enum");
-  if (num < theintlow) Standard_ConstructionError::Raise
-    ("MoniTool_TypedValue : AddEnum, out of range");
+  if (thetype != MoniTool_ValueEnum) throw Standard_ConstructionError("MoniTool_TypedValue : AddEnum, Not an Enum");
+  if (num < theintlow) throw Standard_ConstructionError("MoniTool_TypedValue : AddEnum, out of range");
   if (val[0] == '\0') return;
   if (theenums.IsNull()) theenums =
     new TColStd_HArray1OfAsciiString(theintlow,num+1);
@@ -498,8 +492,7 @@ static Standard_Boolean StaticPath(const Handle(TCollection_HAsciiString)& val)
     void  MoniTool_TypedValue::SetObjectType
   (const Handle(Standard_Type)& typ)
 {
-  if (thetype != MoniTool_ValueIdent) Standard_ConstructionError::Raise
-    ("MoniTool_TypedValue : AddEnum, Not an Entity/Object");
+  if (thetype != MoniTool_ValueIdent) throw Standard_ConstructionError("MoniTool_TypedValue : AddEnum, Not an Entity/Object");
   theotyp = typ;
 }
 
index ab0b0b0..24a11a1 100644 (file)
@@ -98,8 +98,8 @@ void NCollection_AccAllocator::Free(void* theAddress)
 #if !defined No_Exception && !defined No_Standard_ProgramError
   if (aBlock == 0L || aBlock->IsEmpty())
   {
-    Standard_ProgramError::Raise("NCollection_AccAllocator::Free: \
-                                 Trying to free an invalid address");
+    throw Standard_ProgramError("NCollection_AccAllocator::Free: \
+                                Trying to free an invalid address");
   }
 #endif
 
index ed4fb9f..4cf81fe 100644 (file)
@@ -216,7 +216,7 @@ void NCollection_BaseSequence::PInsertAfter (const Standard_Integer theIndex,
                                              NCollection_BaseSequence& Other)
 {
   if (theIndex < 0 || theIndex > mySize)
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   if (Other.mySize != 0) {
     if (theIndex == 0) 
       PPrepend (Other);
index a656df9..598f718 100644 (file)
@@ -246,7 +246,7 @@ protected:
     ListNode()
     {
       // Empty constructor is forbidden.
-      Standard_NoSuchObject::Raise("NCollection_CellFilter::ListNode()");
+      throw Standard_NoSuchObject("NCollection_CellFilter::ListNode()");
     }
 
     Target Object;
index 0d0ceab..13d72d8 100644 (file)
@@ -301,7 +301,7 @@ class NCollection_DataMap : public NCollection_BaseMap
   {
     DataMapNode* p = 0;
     if (!lookup(theKey, p))
-      Standard_NoSuchObject::Raise("NCollection_DataMap::Find");
+      throw Standard_NoSuchObject("NCollection_DataMap::Find");
     return p->Value();
   }
 
@@ -337,7 +337,7 @@ class NCollection_DataMap : public NCollection_BaseMap
   {
     DataMapNode* p = 0;
     if (!lookup(theKey, p))
-      Standard_NoSuchObject::Raise("NCollection_DataMap::Find");
+      throw Standard_NoSuchObject("NCollection_DataMap::Find");
     return p->ChangeValue();
   }
 
index 564146e..369e8dd 100644 (file)
@@ -112,12 +112,6 @@ class NCollection_DoubleMap : public NCollection_BaseMap
       Standard_NoSuchObject_Raise_if (!More(), "NCollection_DoubleMap::Iterator::Value");
       return ((DoubleMapNode *) myNode)->Value();
     }
-    //! Value change access - denied
-    TheKey2Type& ChangeValue(void) const
-    {  
-      Standard_ImmutableObject::Raise("NCollection_DoubleMap::Iterator::ChangeValue");
-      return * (TheKey2Type *) NULL; // For compiler
-    }
   };
 
  public:
@@ -219,14 +213,14 @@ class NCollection_DoubleMap : public NCollection_BaseMap
     while (pNode) 
     {
       if (Hasher1::IsEqual (pNode->Key1(), theKey1))
-        Standard_MultiplyDefined::Raise("NCollection_DoubleMap:Bind");
+        throw Standard_MultiplyDefined("NCollection_DoubleMap:Bind");
       pNode = (DoubleMapNode *) pNode->Next();
     }
     pNode = (DoubleMapNode *) myData2[iK2];
     while (pNode) 
     {
       if (Hasher2::IsEqual (pNode->Key2(), theKey2))
-        Standard_MultiplyDefined::Raise("NCollection_DoubleMap:Bind");
+        throw Standard_MultiplyDefined("NCollection_DoubleMap:Bind");
       pNode = (DoubleMapNode *) pNode->Next();
     }
     pNode = new (this->myAllocator) DoubleMapNode (theKey1, theKey2, 
@@ -403,8 +397,7 @@ class NCollection_DoubleMap : public NCollection_BaseMap
         return pNode1->Key2();
       pNode1 = (DoubleMapNode*) pNode1->Next();
     }
-    Standard_NoSuchObject::Raise("NCollection_DoubleMap::Find1");
-    return pNode1->Key2(); // This for compiler
+    throw Standard_NoSuchObject("NCollection_DoubleMap::Find1");
   }
 
   //! Find2
@@ -419,8 +412,7 @@ class NCollection_DoubleMap : public NCollection_BaseMap
         return pNode2->Key1();
       pNode2 = (DoubleMapNode*) pNode2->Next2();
     }
-    Standard_NoSuchObject::Raise("NCollection_DoubleMap::Find2");
-    return pNode2->Key1(); // This for compiler
+    throw Standard_NoSuchObject("NCollection_DoubleMap::Find2");
   }
 
   //! Clear data. If doReleaseMemory is false then the table of
index cc34724..dac826c 100644 (file)
@@ -34,7 +34,7 @@ void * NCollection_HeapAllocator::Allocate (const Standard_Size theSize)
   {
     char aBuffer[96];
     Sprintf (aBuffer, "Failed to allocate %" PRIuPTR " bytes in global dynamic heap", theSize);
-    Standard_OutOfMemory::Raise (aBuffer);
+    throw Standard_OutOfMemory(aBuffer);
   }
   return aResult;
 }
index c4e29f4..a867afa 100644 (file)
@@ -194,7 +194,7 @@ NCollection_IncAllocator::NCollection_IncAllocator (const size_t theBlockSize)
   mySize = aSize - IMEM_SIZE(sizeof(IBlock));
   myMemSize = aSize * sizeof(aligned_t);
   if (aBlock == NULL)
-    Standard_OutOfMemory::Raise("NCollection_IncAllocator: out of memory");
+    throw Standard_OutOfMemory("NCollection_IncAllocator: out of memory");
   aBlock -> p_free_space = (aligned_t *) IMEM_ALIGN (&aBlock[1]);
   aBlock -> p_end_block  = ((aligned_t *) aBlock) + aSize;
   aBlock -> p_next       = NULL;
@@ -233,7 +233,7 @@ void * NCollection_IncAllocator::Allocate (const size_t aSize)
     if (aResult)
       myFirstBlock -> p_free_space = myFirstBlock -> p_end_block;
     else
-      Standard_OutOfMemory::Raise("NCollection_IncAllocator: out of memory");
+      throw Standard_OutOfMemory("NCollection_IncAllocator: out of memory");
   } else
     if (cSize <= IMEM_FREE(myFirstBlock)) {
       /* If the requested size fits into the free space in the 1st block  */
@@ -259,14 +259,14 @@ void * NCollection_IncAllocator::Allocate (const size_t aSize)
         {
           const size_t aDefault = IMEM_SIZE(DefaultBlockSize);
           if (cSize > aDefault)
-              Standard_OutOfMemory::Raise("NCollection_IncAllocator: out of memory");
+              throw Standard_OutOfMemory("NCollection_IncAllocator: out of memory");
           else
           {            
             aResult = (aligned_t *) allocateNewBlock (aDefault);
             if (aResult)
               myFirstBlock -> p_free_space = aResult + cSize;
             else
-              Standard_OutOfMemory::Raise("NCollection_IncAllocator: out of memory");
+              throw Standard_OutOfMemory("NCollection_IncAllocator: out of memory");
           }
         }
       }
@@ -327,7 +327,7 @@ void * NCollection_IncAllocator::Reallocate (void         * theAddress,
   }
   else
   {
-    Standard_OutOfMemory::Raise("NCollection_IncAllocator: out of memory");
+    throw Standard_OutOfMemory("NCollection_IncAllocator: out of memory");
   }
   return aResult;
 }
index 09b60ad..0171fb6 100644 (file)
@@ -306,8 +306,8 @@ class NCollection_IndexedDataMap : public NCollection_BaseMap
       {
         if (p->Key2() != theIndex)
         {
-          Standard_DomainError::Raise ("NCollection_IndexedDataMap::Substitute : "
-                                       "Attempt to substitute existing key");
+          throw Standard_DomainError ("NCollection_IndexedDataMap::Substitute : "
+                                      "Attempt to substitute existing key");
         }
         p->Key1() = theKey1;
         p->ChangeValue() = theItem;
@@ -443,7 +443,7 @@ class NCollection_IndexedDataMap : public NCollection_BaseMap
     IndexedDataMapNode* aNode = nodeFromIndex (theKey2);
     if (aNode == NULL)
     {
-      Standard_NoSuchObject::Raise ("NCollection_IndexedDataMap::FindKey");
+      throw Standard_NoSuchObject("NCollection_IndexedDataMap::FindKey");
     }
     return aNode->Key1();
   }
@@ -456,7 +456,7 @@ class NCollection_IndexedDataMap : public NCollection_BaseMap
     IndexedDataMapNode* aNode = nodeFromIndex (theKey2);
     if (aNode == NULL)
     {
-      Standard_NoSuchObject::Raise ("NCollection_IndexedDataMap::FindFromIndex");
+      throw Standard_NoSuchObject("NCollection_IndexedDataMap::FindFromIndex");
     }
     return aNode->Value();
   }
@@ -473,7 +473,7 @@ class NCollection_IndexedDataMap : public NCollection_BaseMap
     IndexedDataMapNode* aNode = nodeFromIndex (theKey2);
     if (aNode == NULL)
     {
-      Standard_NoSuchObject::Raise ("NCollection_IndexedDataMap::ChangeFromIndex");
+      throw Standard_NoSuchObject("NCollection_IndexedDataMap::ChangeFromIndex");
     }
     return aNode->ChangeValue();
   }
@@ -510,8 +510,7 @@ class NCollection_IndexedDataMap : public NCollection_BaseMap
         return pNode1->Value();
       pNode1 = (IndexedDataMapNode*) pNode1->Next();
     }
-    Standard_NoSuchObject::Raise("NCollection_IndexedDataMap::FindFromKey");
-    return pNode1->Value();
+    throw Standard_NoSuchObject("NCollection_IndexedDataMap::FindFromKey");
   }
 
   //! ChangeFromKey
@@ -527,8 +526,7 @@ class NCollection_IndexedDataMap : public NCollection_BaseMap
         return pNode1->ChangeValue();
       pNode1 = (IndexedDataMapNode*) pNode1->Next();
     }
-    Standard_NoSuchObject::Raise("NCollection_IndexedDataMap::ChangeFromKey");
-    return pNode1->ChangeValue();
+    throw Standard_NoSuchObject("NCollection_IndexedDataMap::ChangeFromKey");
   }
 
   //! Seek returns pointer to Item by Key. Returns
index f7ac9ee..3553fd0 100644 (file)
@@ -20,7 +20,6 @@
 #include <NCollection_TListNode.hxx>
 #include <NCollection_StlIterator.hxx>
 #include <Standard_NoSuchObject.hxx>
-#include <Standard_ImmutableObject.hxx>
 
 #include <NCollection_DefaultHasher.hxx>
 
@@ -104,12 +103,7 @@ class NCollection_IndexedMap : public NCollection_BaseMap
       Standard_NoSuchObject_Raise_if(!More(), "NCollection_IndexedMap::Iterator::Value");
       return myMap->FindKey(myIndex);
     }
-    //! Value change access denied - use Substitute
-    TheKeyType& ChangeValue(void) const
-    {  
-      Standard_ImmutableObject::Raise ("impossible to ChangeValue");
-      return * (TheKeyType *) NULL; // This for compiler
-    }
+
     //! Performs comparison of two iterators.
     Standard_Boolean IsEqual (const Iterator& theOther) const
     {
@@ -277,8 +271,8 @@ class NCollection_IndexedMap : public NCollection_BaseMap
       {
         if (p->Key2() != theIndex)
         {
-          Standard_DomainError::Raise ("NCollection_IndexedMap::Substitute : "
-                                       "Attempt to substitute existing key");
+          throw Standard_DomainError ("NCollection_IndexedMap::Substitute : "
+                                      "Attempt to substitute existing key");
         }
         p->Key1() = theKey1;
         return;
@@ -417,8 +411,7 @@ class NCollection_IndexedMap : public NCollection_BaseMap
         return pNode2->Key1();
       pNode2 = (IndexedMapNode*) pNode2->Next2();
     }
-    Standard_NoSuchObject::Raise("NCollection_IndexedMap::FindKey");
-    return pNode2->Key1(); // This for compiler
+    throw Standard_NoSuchObject("NCollection_IndexedMap::FindKey");
   }
 
   //! operator ()
index 866d0cb..c30654a 100644 (file)
@@ -22,7 +22,6 @@
 #include <NCollection_StlIterator.hxx>
 #include <NCollection_DefaultHasher.hxx>
 
-#include <Standard_ImmutableObject.hxx>
 #include <Standard_NoSuchObject.hxx>
 
 /**
@@ -96,12 +95,7 @@ class NCollection_Map : public NCollection_BaseMap
       Standard_NoSuchObject_Raise_if (!More(), "NCollection_Map::Iterator::Value");  
       return ((MapNode *) myNode)->Value();
     }
-    //! Value change access - denied
-    TheKeyType& ChangeValue(void) const
-    {  
-      Standard_ImmutableObject::Raise("NCollection_Map::Iterator::ChangeValue");
-      return * (TheKeyType *) NULL; // For compiler
-    }
+
     //! Key
     const TheKeyType& Key (void) const
     { 
index c833e8c..0e286bb 100644 (file)
@@ -74,7 +74,7 @@ void* NCollection_WinHeapAllocator::Allocate (const Standard_Size theSize)
   {
     char aBuf[128];
     Sprintf (aBuf, "Failed to allocate %" PRIuPTR " bytes in local dynamic heap", theSize);
-    Standard_OutOfMemory::Raise (aBuf);
+    throw Standard_OutOfMemory(aBuf);
   }
   return aResult;
 }
index 8f9ec34..4418a11 100644 (file)
@@ -99,8 +99,8 @@ public:
   //! across threads.
   //!
   //! Keep in mind that whether the C++ exception will really be thrown (i.e.
-  //! ::throw() will be called) is regulated by the NO_CXX_EXCEPTIONS and
-  //! OCC_CONVERT_SIGNALS macros used during compilation of Open CASCADE and
+  //! ::throw() will be called) is regulated by the
+  //! OCC_CONVERT_SIGNALS macro used during compilation of Open CASCADE and
   //! user's code. Refer to Foundation Classes User's Guide for further details.
   //!
   Standard_EXPORT static void SetSignal (const Standard_Boolean theFloatingSignal = Standard_True);
index 7db3ac2..de8467b 100644 (file)
@@ -127,7 +127,7 @@ void OSD_Directory :: Build (const OSD_Protection& Protect) {
 
  if (  dirName.IsEmpty ()  )
 
-  Standard_ProgramError :: Raise ( "OSD_Directory :: Build (): incorrect call - no directory name");
+  throw Standard_ProgramError ( "OSD_Directory :: Build (): incorrect call - no directory name");
 
   Standard_Boolean isOK = Exists();
   if (! isOK)
index 2298658..2adf192 100644 (file)
@@ -403,7 +403,7 @@ static void __fastcall _osd_wnt_set_disk_name ( TCollection_AsciiString& result,
   
   } else {
 badPath:  
-   Standard_ProgramError :: Raise ( "OSD_Disk: bad disk name" );
+   throw Standard_ProgramError ( "OSD_Disk: bad disk name" );
 
   }  // end else
  
index dfa7ecf..2a81d2f 100644 (file)
@@ -54,7 +54,7 @@ OSD_Environment::OSD_Environment(const TCollection_AsciiString& Name)
 {
 
  if (!Name.IsAscii() || Name.Search("$") != -1 ) 
-   Standard_ConstructionError::Raise("OSD_Environment::OSD_Environment: bad argument");
+   throw Standard_ConstructionError("OSD_Environment::OSD_Environment: bad argument");
 
  myName = Name; 
 }
@@ -71,7 +71,7 @@ OSD_Environment::OSD_Environment(const TCollection_AsciiString& Name,
  if (!Name.IsAscii() || !Value.IsAscii() || 
 // JPT : Dec-7-1992     Name.Search("$") != -1 || Value.Search("$") != -1) 
      Name.Search("$") != -1 ) 
-   Standard_ConstructionError::Raise("OSD_Environment::OSD_Environment: bad argument");
+   throw Standard_ConstructionError("OSD_Environment::OSD_Environment: bad argument");
 
  myName = Name; 
  myValue = Value;
@@ -95,7 +95,7 @@ void OSD_Environment::SetName (const TCollection_AsciiString& Name)
 {
  myError.Reset();
  if (!Name.IsAscii() || Name.Search("$") != -1 ) 
-   Standard_ConstructionError::Raise("OSD_Environment::SetName: bad argument");
+   throw Standard_ConstructionError("OSD_Environment::SetName: bad argument");
 
  myName = Name;
 }
@@ -107,7 +107,7 @@ void OSD_Environment::SetName (const TCollection_AsciiString& Name)
 void OSD_Environment::SetValue (const TCollection_AsciiString& Value)
 {
  if (!Value.IsAscii() || Value.Search("$") != -1) 
-   Standard_ConstructionError::Raise("OSD_Environment::Change: bad argument");
+   throw Standard_ConstructionError("OSD_Environment::Change: bad argument");
 
  myValue = Value;
 }
index 130fdf6..031826a 100755 (executable)
@@ -434,7 +434,7 @@ void OSD_Error::Perror() {
    }
  }
  buffer += ".\n\n";
OSD_OSDError::Raise (buffer.ToCString());
throw OSD_OSDError(buffer.ToCString());
 }
 
 #else
index 069d8c0..19db890 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception, Standard_Failure)
 
 #if !defined No_Exception && !defined No_OSD_Exception
   #define OSD_Exception_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception(MESSAGE);
 #else
   #define OSD_Exception_Raise_if(CONDITION, MESSAGE)
 #endif
index 3d9b3c0..382b994 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_ACCESS_VIOLATION, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_ACCESS_VIOLATION
   #define OSD_Exception_ACCESS_VIOLATION_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_ACCESS_VIOLATION::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_ACCESS_VIOLATION(MESSAGE);
 #else
   #define OSD_Exception_ACCESS_VIOLATION_Raise_if(CONDITION, MESSAGE)
 #endif
index 1c67a31..91e5b54 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_ARRAY_BOUNDS_EXCEEDED, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_ARRAY_BOUNDS_EXCEEDED
   #define OSD_Exception_ARRAY_BOUNDS_EXCEEDED_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_ARRAY_BOUNDS_EXCEEDED::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_ARRAY_BOUNDS_EXCEEDED(MESSAGE);
 #else
   #define OSD_Exception_ARRAY_BOUNDS_EXCEEDED_Raise_if(CONDITION, MESSAGE)
 #endif
index b74d860..f696f28 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_CTRL_BREAK, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_CTRL_BREAK
   #define OSD_Exception_CTRL_BREAK_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_CTRL_BREAK::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_CTRL_BREAK(MESSAGE);
 #else
   #define OSD_Exception_CTRL_BREAK_Raise_if(CONDITION, MESSAGE)
 #endif
index 64e89aa..a1fadb8 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_FLT_DENORMAL_OPERAND, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_FLT_DENORMAL_OPERAND
   #define OSD_Exception_FLT_DENORMAL_OPERAND_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_FLT_DENORMAL_OPERAND::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_FLT_DENORMAL_OPERAND(MESSAGE);
 #else
   #define OSD_Exception_FLT_DENORMAL_OPERAND_Raise_if(CONDITION, MESSAGE)
 #endif
index b2248bb..78de87c 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_FLT_DIVIDE_BY_ZERO, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_FLT_DIVIDE_BY_ZERO
   #define OSD_Exception_FLT_DIVIDE_BY_ZERO_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_FLT_DIVIDE_BY_ZERO::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_FLT_DIVIDE_BY_ZERO(MESSAGE);
 #else
   #define OSD_Exception_FLT_DIVIDE_BY_ZERO_Raise_if(CONDITION, MESSAGE)
 #endif
index 01c33d0..b6906bc 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_FLT_INEXACT_RESULT, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_FLT_INEXACT_RESULT
   #define OSD_Exception_FLT_INEXACT_RESULT_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_FLT_INEXACT_RESULT::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_FLT_INEXACT_RESULT(MESSAGE);
 #else
   #define OSD_Exception_FLT_INEXACT_RESULT_Raise_if(CONDITION, MESSAGE)
 #endif
index 262cb97..35f75ff 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_FLT_INVALID_OPERATION, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_FLT_INVALID_OPERATION
   #define OSD_Exception_FLT_INVALID_OPERATION_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_FLT_INVALID_OPERATION::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_FLT_INVALID_OPERATION(MESSAGE);
 #else
   #define OSD_Exception_FLT_INVALID_OPERATION_Raise_if(CONDITION, MESSAGE)
 #endif
index 824457a..5821938 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_FLT_OVERFLOW, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_FLT_OVERFLOW
   #define OSD_Exception_FLT_OVERFLOW_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_FLT_OVERFLOW::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_FLT_OVERFLOW(MESSAGE);
 #else
   #define OSD_Exception_FLT_OVERFLOW_Raise_if(CONDITION, MESSAGE)
 #endif
index 24f41c3..e311c02 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_FLT_STACK_CHECK, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_FLT_STACK_CHECK
   #define OSD_Exception_FLT_STACK_CHECK_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_FLT_STACK_CHECK::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_FLT_STACK_CHECK(MESSAGE);
 #else
   #define OSD_Exception_FLT_STACK_CHECK_Raise_if(CONDITION, MESSAGE)
 #endif
index 2780ca1..a5081c9 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_FLT_UNDERFLOW, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_FLT_UNDERFLOW
   #define OSD_Exception_FLT_UNDERFLOW_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_FLT_UNDERFLOW::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_FLT_UNDERFLOW(MESSAGE);
 #else
   #define OSD_Exception_FLT_UNDERFLOW_Raise_if(CONDITION, MESSAGE)
 #endif
index b9a6501..f529003 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_ILLEGAL_INSTRUCTION, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_ILLEGAL_INSTRUCTION
   #define OSD_Exception_ILLEGAL_INSTRUCTION_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_ILLEGAL_INSTRUCTION::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_ILLEGAL_INSTRUCTION(MESSAGE);
 #else
   #define OSD_Exception_ILLEGAL_INSTRUCTION_Raise_if(CONDITION, MESSAGE)
 #endif
index 6248181..a07148b 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_INT_DIVIDE_BY_ZERO, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_INT_DIVIDE_BY_ZERO
   #define OSD_Exception_INT_DIVIDE_BY_ZERO_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_INT_DIVIDE_BY_ZERO::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_INT_DIVIDE_BY_ZERO(MESSAGE);
 #else
   #define OSD_Exception_INT_DIVIDE_BY_ZERO_Raise_if(CONDITION, MESSAGE)
 #endif
index 5fa2aee..dbed49d 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_INT_OVERFLOW, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_INT_OVERFLOW
   #define OSD_Exception_INT_OVERFLOW_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_INT_OVERFLOW::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_INT_OVERFLOW(MESSAGE);
 #else
   #define OSD_Exception_INT_OVERFLOW_Raise_if(CONDITION, MESSAGE)
 #endif
index d1639ae..1512d02 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_INVALID_DISPOSITION, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_INVALID_DISPOSITION
   #define OSD_Exception_INVALID_DISPOSITION_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_INVALID_DISPOSITION::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_INVALID_DISPOSITION(MESSAGE);
 #else
   #define OSD_Exception_INVALID_DISPOSITION_Raise_if(CONDITION, MESSAGE)
 #endif
index cd19191..36b431c 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_IN_PAGE_ERROR, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_IN_PAGE_ERROR
   #define OSD_Exception_IN_PAGE_ERROR_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_IN_PAGE_ERROR::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_IN_PAGE_ERROR(MESSAGE);
 #else
   #define OSD_Exception_IN_PAGE_ERROR_Raise_if(CONDITION, MESSAGE)
 #endif
index d5920ac..1f1a643 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_NONCONTINUABLE_EXCEPTION, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_NONCONTINUABLE_EXCEPTION
   #define OSD_Exception_NONCONTINUABLE_EXCEPTION_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_NONCONTINUABLE_EXCEPTION::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_NONCONTINUABLE_EXCEPTION(MESSAGE);
 #else
   #define OSD_Exception_NONCONTINUABLE_EXCEPTION_Raise_if(CONDITION, MESSAGE)
 #endif
index 5f0a531..b8cb71c 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_PRIV_INSTRUCTION, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_PRIV_INSTRUCTION
   #define OSD_Exception_PRIV_INSTRUCTION_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_PRIV_INSTRUCTION::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_PRIV_INSTRUCTION(MESSAGE);
 #else
   #define OSD_Exception_PRIV_INSTRUCTION_Raise_if(CONDITION, MESSAGE)
 #endif
index a1189c3..6eed03b 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_STACK_OVERFLOW, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_STACK_OVERFLOW
   #define OSD_Exception_STACK_OVERFLOW_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_STACK_OVERFLOW::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_STACK_OVERFLOW(MESSAGE);
 #else
   #define OSD_Exception_STACK_OVERFLOW_Raise_if(CONDITION, MESSAGE)
 #endif
index 1cc02fe..25cd922 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Exception_STATUS_NO_MEMORY, OSD_Exception)
 
 #if !defined No_Exception && !defined No_OSD_Exception_STATUS_NO_MEMORY
   #define OSD_Exception_STATUS_NO_MEMORY_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Exception_STATUS_NO_MEMORY::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Exception_STATUS_NO_MEMORY(MESSAGE);
 #else
   #define OSD_Exception_STATUS_NO_MEMORY_Raise_if(CONDITION, MESSAGE)
 #endif
index 4bb93a7..76623f9 100644 (file)
@@ -91,10 +91,10 @@ void OSD_File::Build(const OSD_OpenMode Mode,
  TCollection_AsciiString aBuffer;
 
  if (myPath.Name().Length()==0)
-  Standard_ProgramError::Raise("OSD_File::Build : no name was given");
+  throw Standard_ProgramError("OSD_File::Build : no name was given");
 
  if (myFileChannel != -1)
-  Standard_ProgramError::Raise("OSD_File::Build : file is already open");
+  throw Standard_ProgramError("OSD_File::Build : file is already open");
 
 
  myMode = Mode;
@@ -144,14 +144,14 @@ void  OSD_File::Append(const OSD_OpenMode Mode,
  TCollection_AsciiString aBuffer;
 
  if ( OSD_File::KindOfFile ( ) == OSD_DIRECTORY ) {
-    Standard_ProgramError::Raise("OSD_File::Append : it is a directory");
+    throw Standard_ProgramError("OSD_File::Append : it is a directory");
  } 
  
  if (myPath.Name().Length()==0)
-  Standard_ProgramError::Raise("OSD_File::Append : no name was given");
+  throw Standard_ProgramError("OSD_File::Append : no name was given");
 
  if (myFileChannel != -1)
-  Standard_ProgramError::Raise("OSD_File::Append : file is already open");
+  throw Standard_ProgramError("OSD_File::Append : file is already open");
 
  internal_prot = Protect.Internal();
  myMode = Mode;
@@ -202,10 +202,10 @@ void  OSD_File::Open(const OSD_OpenMode Mode,
   }
 
  if (myPath.Name().Length()==0)
-  Standard_ProgramError::Raise("OSD_File::Open : no name was given");
+  throw Standard_ProgramError("OSD_File::Open : no name was given");
 
  if (myFileChannel != -1)
-  Standard_ProgramError::Raise("OSD_File::Open : file is already open");
+  throw Standard_ProgramError("OSD_File::Open : file is already open");
 
  internal_prot = Protect.Internal();
  myMode = Mode;
@@ -283,19 +283,19 @@ void  OSD_File::Read(TCollection_AsciiString& Buffer,
  int status;
 
   if ( OSD_File::KindOfFile ( ) == OSD_DIRECTORY ) { 
-    Standard_ProgramError::Raise("OSD_File::Read : it is a directory");
+    throw Standard_ProgramError("OSD_File::Read : it is a directory");
   }
 
  if (myFileChannel == -1)
-  Standard_ProgramError::Raise("OSD_File::Read : file is not open");
+  throw Standard_ProgramError("OSD_File::Read : file is not open");
 
  if (Failed()) Perror();
 
  if (myMode == OSD_WriteOnly)
-  Standard_ProgramError::Raise("OSD_File::Read : file is Write only");
+  throw Standard_ProgramError("OSD_File::Read : file is Write only");
 
  if (Nbyte <= 0)
-  Standard_ProgramError::Raise("OSD_File::Read : Nbyte is null");
+  throw Standard_ProgramError("OSD_File::Read : Nbyte is null");
 
  TCollection_AsciiString transfert(Nbyte,' ');
  readbuf = (Standard_PCharacter)transfert.ToCString();  
@@ -321,19 +321,19 @@ void OSD_File::ReadLine(TCollection_AsciiString& Buffer,
   Standard_PCharacter readbuf, abuffer;
   //
   if (OSD_File::KindOfFile() == OSD_DIRECTORY ) { 
-    Standard_ProgramError::Raise("OSD_File::Read : it is a directory");
+    throw Standard_ProgramError("OSD_File::Read : it is a directory");
   }
   if (myFileChannel == -1){
-    Standard_ProgramError::Raise("OSD_File::ReadLine : file is not open");
+    throw Standard_ProgramError("OSD_File::ReadLine : file is not open");
   }
   if (Failed()) {
     Perror();
   }
   if (myMode == OSD_WriteOnly) {
-    Standard_ProgramError::Raise("OSD_File::ReadLine : file is Write only");
+    throw Standard_ProgramError("OSD_File::ReadLine : file is Write only");
   }
   if (Nbyte <= 0){
-    Standard_ProgramError::Raise("OSD_File::ReadLine : Nbyte is null");
+    throw Standard_ProgramError("OSD_File::ReadLine : Nbyte is null");
   }
   //
   TCollection_AsciiString transfert(Nbyte,' ');
@@ -391,22 +391,22 @@ void  OSD_File::Read(const Standard_Address   Buffer,
   
   Readbyte = 0;
   if ( OSD_File::KindOfFile ( ) == OSD_DIRECTORY ) { 
-    Standard_ProgramError::Raise("OSD_File::Read : it is a directory");
+    throw Standard_ProgramError("OSD_File::Read : it is a directory");
   }
  
   if (myFileChannel == -1)
-    Standard_ProgramError::Raise("OSD_File::Read : file is not open");
+    throw Standard_ProgramError("OSD_File::Read : file is not open");
   
   if (Failed()) Perror();
   
   if (myMode == OSD_WriteOnly)
-    Standard_ProgramError::Raise("OSD_File::Read : file is Write only");
+    throw Standard_ProgramError("OSD_File::Read : file is Write only");
   
   if (Nbyte <= 0)
-    Standard_ProgramError::Raise("OSD_File::Read : Nbyte is null");
+    throw Standard_ProgramError("OSD_File::Read : Nbyte is null");
 
   if (Buffer == NULL)
-    Standard_ProgramError::Raise("OSD_File::Read : Buffer is null");
+    throw Standard_ProgramError("OSD_File::Read : Buffer is null");
   
   status = read (myFileChannel, (char*) Buffer, Nbyte);
   
@@ -426,19 +426,19 @@ void  OSD_File::Write(const TCollection_AsciiString &Buffer,
  int status;
 
  if ( OSD_File::KindOfFile ( ) == OSD_DIRECTORY ) { 
-   Standard_ProgramError::Raise("OSD_File::Write : it is a directory");
+   throw Standard_ProgramError("OSD_File::Write : it is a directory");
  }
  
  if (myFileChannel == -1)
-  Standard_ProgramError::Raise("OSD_File::Write : file is not open");
+  throw Standard_ProgramError("OSD_File::Write : file is not open");
 
  if (Failed()) Perror();
 
  if (myMode == OSD_ReadOnly)
-  Standard_ProgramError::Raise("OSD_File::Write : file is Read only");
+  throw Standard_ProgramError("OSD_File::Write : file is Read only");
 
  if (Nbyte <= 0)
-  Standard_ProgramError::Raise("OSD_File::Write : Nbyte is null");
+  throw Standard_ProgramError("OSD_File::Write : Nbyte is null");
 
  writebuf = Buffer.ToCString();
 
@@ -457,15 +457,15 @@ void  OSD_File::Write(const Standard_Address   Buffer,
   int status;
   
   if (myFileChannel == -1)
-    Standard_ProgramError::Raise("OSD_File::Write : file is not open");
+    throw Standard_ProgramError("OSD_File::Write : file is not open");
   
   if (Failed()) Perror();
   
   if (myMode == OSD_ReadOnly)
-    Standard_ProgramError::Raise("OSD_File::Write : file is Read only");
+    throw Standard_ProgramError("OSD_File::Write : file is Read only");
   
   if (Nbyte <= 0)
-    Standard_ProgramError::Raise("OSD_File::Write : Nbyte is null");
+    throw Standard_ProgramError("OSD_File::Write : Nbyte is null");
   
   status = write (myFileChannel, (const char *)Buffer, Nbyte);
   
@@ -485,7 +485,7 @@ void  OSD_File::Seek(const Standard_Integer Offset,
  int iwhere=0;
 
  if (myFileChannel == -1)
-  Standard_ProgramError::Raise("OSD_File::Seek : file is not open");
+  throw Standard_ProgramError("OSD_File::Seek : file is not open");
 
  if (Failed()) Perror();
 
@@ -518,7 +518,7 @@ void  OSD_File::Close(){
  int status;
 
  if (myFileChannel == -1)
-  Standard_ProgramError::Raise("OSD_File::Close : file is not open");
+  throw Standard_ProgramError("OSD_File::Close : file is not open");
 
  if (Failed()) Perror();
 
@@ -543,7 +543,7 @@ void  OSD_File::Close(){
 
 Standard_Boolean OSD_File::IsAtEnd(){
  if (myFileChannel == -1)
-  Standard_ProgramError::Raise("OSD_File::IsAtEnd : file is not open");
+  throw Standard_ProgramError("OSD_File::IsAtEnd : file is not open");
 
  if (myIO == EOF) return (Standard_True);
  return (Standard_False);
@@ -553,7 +553,7 @@ Standard_Boolean OSD_File::IsAtEnd(){
 
 /*void  OSD_File::Link(const TCollection_AsciiString& ToFile){
  if (myFileChannel == -1)
-  Standard_ProgramError::Raise("OSD_File::Link : file is not open");
+  throw Standard_ProgramError("OSD_File::Link : file is not open");
 
  TCollection_AsciiString aBuffer;
  myPath.SystemName ( aBuffer );
@@ -567,7 +567,7 @@ void  OSD_File::SetLock(const OSD_LockType Lock){
 int status;
 
  if (myFileChannel == -1)
-  Standard_ProgramError::Raise("OSD_File::SetLock : file is not open");
+  throw Standard_ProgramError("OSD_File::SetLock : file is not open");
 
 
 #ifdef POSIX
@@ -652,7 +652,7 @@ void  OSD_File::UnLock(){
 int status;
 
  if (myFileChannel == -1)
-  Standard_ProgramError::Raise("OSD_File::UnLock : file is not open");
+  throw Standard_ProgramError("OSD_File::UnLock : file is not open");
 
 #ifdef POSIX
  struct stat buf;
@@ -711,7 +711,7 @@ Standard_Size  OSD_File::Size(){
  int status;
 
  if (myPath.Name().Length()==0)
-  Standard_ProgramError::Raise("OSD_File::Size : empty file name");
+  throw Standard_ProgramError("OSD_File::Size : empty file name");
 
  TCollection_AsciiString aBuffer;
  myPath.SystemName ( aBuffer );
@@ -814,7 +814,7 @@ void OSD_File::Rewind() {
 
 #define ACE_HEADER_SIZE (  sizeof ( ACCESS_ALLOWED_ACE ) - sizeof ( DWORD )  )
 
-#define RAISE( arg ) Standard_ProgramError :: Raise (  ( arg )  )
+#define RAISE( arg ) throw Standard_ProgramError (  ( arg )  )
 #define TEST_RAISE( arg ) _test_raise (  myFileHandle, ( arg )  )
 
 #define OPEN_NEW    0
@@ -923,7 +923,7 @@ void OSD_File :: Build ( const OSD_OpenMode Mode, const OSD_Protection& Protect)
  TCollection_AsciiString fName;
 
  if ( OSD_File::KindOfFile ( ) == OSD_DIRECTORY ) { 
-   Standard_ProgramError::Raise("OSD_File::Read : it is a directory");
+   throw Standard_ProgramError("OSD_File::Read : it is a directory");
  }
                                         
  if (myFileHandle != INVALID_HANDLE_VALUE)
@@ -1050,7 +1050,7 @@ void OSD_File :: Read (
    cout << " OSD_File::Read : it is a directory " << endl;
 #endif
    return ;
-//   Standard_ProgramError::Raise("OSD_File::Read : it is a directory");
+//   throw Standard_ProgramError("OSD_File::Read : it is a directory");
  }
                                         
  Standard_Integer NbyteRead;
@@ -1096,7 +1096,7 @@ void OSD_File :: ReadLine (
  LONG               aSeekPos;
 
  if ( OSD_File::KindOfFile ( ) == OSD_DIRECTORY ) { 
-   Standard_ProgramError::Raise("OSD_File::Read : it is a directory");
+   throw Standard_ProgramError("OSD_File::Read : it is a directory");
  }
                                         
  TEST_RAISE(  "ReadLine"  );              
@@ -1237,7 +1237,7 @@ void OSD_File :: Read (
  DWORD dwBytesRead;
 
  if ( OSD_File::KindOfFile ( ) == OSD_DIRECTORY ) { 
-   Standard_ProgramError::Raise("OSD_File::Read : it is a directory");
+   throw Standard_ProgramError("OSD_File::Read : it is a directory");
  }
                                         
  TEST_RAISE(  "Read"  );
@@ -1926,7 +1926,7 @@ static void __fastcall _test_raise ( HANDLE hFile, Standard_CString str ) {
     buff += str;
     buff += " (): wrong access";
 
-    Standard_ProgramError::Raise(buff.ToCString());
+    throw Standard_ProgramError(buff.ToCString());
   }  // end if
 
 }  // end _test_raise
index 8354eee..99e75a2 100644 (file)
@@ -78,7 +78,7 @@ int status;
 
 
 // if (myPath.Name().Length()==0)  A directory can have a null name field (ex: root)
-//  OSD_OSDError::Raise("OSD_FileNode::Exists : no name was given"); (LD)
+//  throw OSD_OSDError("OSD_FileNode::Exists : no name was given"); (LD)
 
 // if (Failed()) Perror();
 
@@ -98,7 +98,7 @@ int status;
 void  OSD_FileNode::Remove(){
 
 // if (myPath.Name().Length()==0) A directory can have a null name field (ex: root)
-//  OSD_OSDError::Raise("OSD_FileNode::Remove : no name was given"); (LD)
+//  throw OSD_OSDError("OSD_FileNode::Remove : no name was given"); (LD)
 
 // if (Failed()) Perror();
 
@@ -151,7 +151,7 @@ int status;
 TCollection_AsciiString thisPath;
 
 // if (myPath.Name().Length()==0)
-//  OSD_OSDError::Raise("OSD_FileNode::Move : no name was given");
+//  throw OSD_OSDError("OSD_FileNode::Move : no name was given");
 
 // if (Failed()) Perror();
 
@@ -206,7 +206,7 @@ int status;
 TCollection_AsciiString second_name;
 
 // if (myPath.Name().Length()==0)   Copy .login would raise !!
-//  OSD_OSDError::Raise("OSD_FileNode::Copy : no name was given");
+//  throw OSD_OSDError("OSD_FileNode::Copy : no name was given");
 // if (Failed()) Perror();
 
  ToPath.SystemName (second_name);
@@ -233,7 +233,7 @@ int status;
 int s,u,g,w;
 
 // if (myPath.Name().Length()==0)
-//  OSD_OSDError::Raise("OSD_FileNode::Protection : no name was given");
+//  throw OSD_OSDError("OSD_FileNode::Protection : no name was given");
 
 // if (Failed()) Perror();
 
@@ -272,7 +272,7 @@ void  OSD_FileNode::SetProtection(const OSD_Protection& Prot){
 int status;
 
 //  if (myPath.Name().Length()==0)
-//  OSD_OSDError::Raise("OSD_FileNode::SetProtection : no name was given");
+//  throw OSD_OSDError("OSD_FileNode::SetProtection : no name was given");
 
 // if (Failed()) Perror();
 
@@ -291,7 +291,7 @@ Quantity_Date  OSD_FileNode::CreationMoment(){
  struct stat buffer;
 
 // if (myPath.Name().Length()==0)
-//  OSD_OSDError::Raise("OSD_FileNode::CreationMoment : no name was given");
+//  throw OSD_OSDError("OSD_FileNode::CreationMoment : no name was given");
 
 // if (Failed()) Perror();
 
@@ -319,7 +319,7 @@ Quantity_Date  OSD_FileNode::AccessMoment(){
  struct stat buffer;
 
 // if (myPath.Name().Length()==0)
-//  OSD_OSDError::Raise("OSD_FileNode::AccessMoment : no name was given");
+//  throw OSD_OSDError("OSD_FileNode::AccessMoment : no name was given");
 
 // if (Failed()) Perror();
 
@@ -383,7 +383,7 @@ Standard_Integer OSD_FileNode::Error()const{
 #include <Strsafe.h>
 
 #define TEST_RAISE( arg ) _test_raise (  fName, ( arg )  )
-#define RAISE( arg ) Standard_ProgramError :: Raise (  ( arg )  )
+#define RAISE( arg ) throw Standard_ProgramError (  ( arg )  )
 
 #ifndef OCCT_UWP
 // None of the existing security APIs are supported in a UWP applications
@@ -925,7 +925,7 @@ static void __fastcall _test_raise ( TCollection_AsciiString fName, Standard_CSt
    buff += str;
    buff += " (): wrong access";
 
-   Standard_ProgramError::Raise(buff.ToCString());
+   throw Standard_ProgramError(buff.ToCString());
  }  // end if
 
 }  // end _test_raise
index baec11b..97b7c25 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_OSDError, Standard_Failure)
 
 #if !defined No_Exception && !defined No_OSD_OSDError
   #define OSD_OSDError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_OSDError::Raise(MESSAGE);
+  if (CONDITION) throw OSD_OSDError(MESSAGE);
 #else
   #define OSD_OSDError_Raise_if(CONDITION, MESSAGE)
 #endif
index 7ac171a..592452a 100644 (file)
@@ -222,7 +222,7 @@ void OSD_Parallel::ForEach( InputIterator          theBegin,
     }
     catch ( tbb::captured_exception& anException )
     {
-      Standard_NotImplemented::Raise(anException.what());
+      throw Standard_NotImplemented(anException.what());
     }
   }
   #else
@@ -271,7 +271,7 @@ void OSD_Parallel::For( const Standard_Integer theBegin,
     }
     catch ( tbb::captured_exception& anException )
     {
-      Standard_NotImplemented::Raise(anException.what());
+      throw Standard_NotImplemented(anException.what());
     }
   }
   #else
index ba1082e..397fadb 100644 (file)
@@ -456,7 +456,7 @@ void OSD_Path::RemoveATrek(const Standard_Integer thewhere){
  Standard_Integer length=TrekLength();
 
  if (length <= 0 || thewhere > length)
-  Standard_NumericError::Raise("OSD_Path::RemoveATrek : where has an invalid value");
+  throw Standard_NumericError("OSD_Path::RemoveATrek : where has an invalid value");
 
  Standard_Integer posit,aHowmany;
  TCollection_AsciiString tok;
@@ -494,7 +494,7 @@ TCollection_AsciiString OSD_Path::TrekValue(const Standard_Integer thewhere)cons
  TCollection_AsciiString result=myTrek.Token("|",thewhere);
 
  if (result == "")
-  Standard_NumericError::Raise("OSD_Path::TrekValue : where is invalid");
+  throw Standard_NumericError("OSD_Path::TrekValue : where is invalid");
 
  return(result);
 }
@@ -504,7 +504,7 @@ void OSD_Path::InsertATrek(const TCollection_AsciiString& aName,
  Standard_Integer length=TrekLength();
 
  if (thewhere <= 0 || thewhere > length)
-  Standard_NumericError::Raise("OSD_Path::InsertATrek : where has an invalid value");
+  throw Standard_NumericError("OSD_Path::InsertATrek : where has an invalid value");
 
  TCollection_AsciiString tok=myTrek.Token("|",thewhere);
  Standard_Integer wwhere = myTrek.Search(tok);
@@ -1362,7 +1362,7 @@ static void __fastcall _test_raise ( OSD_SysType type, Standard_CString str ) {
   strcat (  buff, str );
   strcat (  buff, " (): unknown system type"  );
 
-  Standard_ProgramError :: Raise ( buff );
+  throw Standard_ProgramError ( buff );
  
  }  // end if
 
index 0813b84..0f034ee 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_SIGBUS, OSD_Signal)
 
 #if !defined No_Exception && !defined No_OSD_SIGBUS
   #define OSD_SIGBUS_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_SIGBUS::Raise(MESSAGE);
+  if (CONDITION) throw OSD_SIGBUS(MESSAGE);
 #else
   #define OSD_SIGBUS_Raise_if(CONDITION, MESSAGE)
 #endif
index 6700a4f..f09bc6c 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_SIGHUP, OSD_Signal)
 
 #if !defined No_Exception && !defined No_OSD_SIGHUP
   #define OSD_SIGHUP_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_SIGHUP::Raise(MESSAGE);
+  if (CONDITION) throw OSD_SIGHUP(MESSAGE);
 #else
   #define OSD_SIGHUP_Raise_if(CONDITION, MESSAGE)
 #endif
index 34c5fcb..e170358 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_SIGILL, OSD_Signal)
 
 #if !defined No_Exception && !defined No_OSD_SIGILL
   #define OSD_SIGILL_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_SIGILL::Raise(MESSAGE);
+  if (CONDITION) throw OSD_SIGILL(MESSAGE);
 #else
   #define OSD_SIGILL_Raise_if(CONDITION, MESSAGE)
 #endif
index 87d2532..0f7c9a1 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_SIGINT, OSD_Signal)
 
 #if !defined No_Exception && !defined No_OSD_SIGINT
   #define OSD_SIGINT_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_SIGINT::Raise(MESSAGE);
+  if (CONDITION) throw OSD_SIGINT(MESSAGE);
 #else
   #define OSD_SIGINT_Raise_if(CONDITION, MESSAGE)
 #endif
index a52afe2..5b633de 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_SIGKILL, OSD_Signal)
 
 #if !defined No_Exception && !defined No_OSD_SIGKILL
   #define OSD_SIGKILL_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_SIGKILL::Raise(MESSAGE);
+  if (CONDITION) throw OSD_SIGKILL(MESSAGE);
 #else
   #define OSD_SIGKILL_Raise_if(CONDITION, MESSAGE)
 #endif
index 8611b11..ee7b071 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_SIGQUIT, OSD_Signal)
 
 #if !defined No_Exception && !defined No_OSD_SIGQUIT
   #define OSD_SIGQUIT_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_SIGQUIT::Raise(MESSAGE);
+  if (CONDITION) throw OSD_SIGQUIT(MESSAGE);
 #else
   #define OSD_SIGQUIT_Raise_if(CONDITION, MESSAGE)
 #endif
index 4b0d860..9c32bf4 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_SIGSEGV, OSD_Signal)
 
 #if !defined No_Exception && !defined No_OSD_SIGSEGV
   #define OSD_SIGSEGV_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_SIGSEGV::Raise(MESSAGE);
+  if (CONDITION) throw OSD_SIGSEGV(MESSAGE);
 #else
   #define OSD_SIGSEGV_Raise_if(CONDITION, MESSAGE)
 #endif
index 4781d5d..baf1027 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_SIGSYS, OSD_Signal)
 
 #if !defined No_Exception && !defined No_OSD_SIGSYS
   #define OSD_SIGSYS_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_SIGSYS::Raise(MESSAGE);
+  if (CONDITION) throw OSD_SIGSYS(MESSAGE);
 #else
   #define OSD_SIGSYS_Raise_if(CONDITION, MESSAGE)
 #endif
index eadc28f..18119e3 100644 (file)
@@ -25,7 +25,7 @@ DEFINE_STANDARD_HANDLE(OSD_Signal, Standard_Failure)
 
 #if !defined No_Exception && !defined No_OSD_Signal
   #define OSD_Signal_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) OSD_Signal::Raise(MESSAGE);
+  if (CONDITION) throw OSD_Signal(MESSAGE);
 #else
   #define OSD_Signal_Raise_if(CONDITION, MESSAGE)
 #endif
index 365831a..4e2f1c1 100644 (file)
@@ -149,8 +149,7 @@ static LONG CallHandler (DWORD dwExceptionCode,
       break ;
     case STATUS_NO_MEMORY:
 //      cout << "CallHandler : STATUS_NO_MEMORY:" << endl ;
-      OSD_Exception_STATUS_NO_MEMORY ::
-      Raise (  "MEMORY ALLOCATION ERROR ( no room in the process heap )"  );
+      throw OSD_Exception_STATUS_NO_MEMORY (  "MEMORY ALLOCATION ERROR ( no room in the process heap )"  );
     case EXCEPTION_ACCESS_VIOLATION:
 //      cout << "CallHandler : EXCEPTION_ACCESS_VIOLATION:" << endl ;
       StringCchPrintfW (buffer, _countof(buffer), L"%s%s%s0x%.8p%s%s%s", L"ACCESS VIOLATION",
@@ -288,8 +287,8 @@ static void SIGWntHandler (int signum, int sub_code)
           CallHandler( EXCEPTION_FLT_INEXACT_RESULT ,0,0) ;
           break ;
         default:
-          cout << "SIGWntHandler(default) -> Standard_NumericError::Raise(\"Floating Point Error\");" << endl;
-          Standard_NumericError::Raise("Floating Point Error");
+          cout << "SIGWntHandler(default) -> throw Standard_NumericError(\"Floating Point Error\");" << endl;
+          throw Standard_NumericError("Floating Point Error");
           break ;
       }
       break ;
@@ -421,7 +420,7 @@ void OSD::SetSignal (const Standard_Boolean theFloatingSignal)
 void OSD::ControlBreak () {
   if ( fCtrlBrk ) {
     fCtrlBrk = Standard_False;
-    OSD_Exception_CTRL_BREAK :: Raise ( "*** INTERRUPT ***" );
+    throw OSD_Exception_CTRL_BREAK ( "*** INTERRUPT ***" );
   }
 }  // end OSD :: ControlBreak
 #if !defined(__MINGW32__) && !defined(__CYGWIN32__)
@@ -449,54 +448,54 @@ static LONG __fastcall _osd_raise ( DWORD dwCode, LPSTR msg )
   switch (dwCode)
   {
     case EXCEPTION_ACCESS_VIOLATION:
-      OSD_Exception_ACCESS_VIOLATION::Raise (msg);
+      throw OSD_Exception_ACCESS_VIOLATION(msg);
       break;
     case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
-      OSD_Exception_ARRAY_BOUNDS_EXCEEDED::Raise (msg);
+      throw OSD_Exception_ARRAY_BOUNDS_EXCEEDED(msg);
       break;
     case EXCEPTION_DATATYPE_MISALIGNMENT:
-      Standard_ProgramError::Raise (msg);
+      throw Standard_ProgramError(msg);
       break;
     case EXCEPTION_ILLEGAL_INSTRUCTION:
-      OSD_Exception_ILLEGAL_INSTRUCTION::Raise (msg);
+      throw OSD_Exception_ILLEGAL_INSTRUCTION(msg);
       break;
     case EXCEPTION_IN_PAGE_ERROR:
-      OSD_Exception_IN_PAGE_ERROR::Raise (msg);
+      throw OSD_Exception_IN_PAGE_ERROR(msg);
       break;
     case EXCEPTION_INT_DIVIDE_BY_ZERO:
-      Standard_DivideByZero::Raise (msg);
+      throw Standard_DivideByZero(msg);
       break;
     case EXCEPTION_INT_OVERFLOW:
-      OSD_Exception_INT_OVERFLOW::Raise (msg);
+      throw OSD_Exception_INT_OVERFLOW(msg);
       break;
     case EXCEPTION_INVALID_DISPOSITION:
-      OSD_Exception_INVALID_DISPOSITION::Raise (msg);
+      throw OSD_Exception_INVALID_DISPOSITION(msg);
       break;
     case EXCEPTION_NONCONTINUABLE_EXCEPTION:
-      OSD_Exception_NONCONTINUABLE_EXCEPTION::Raise (msg);
+      throw OSD_Exception_NONCONTINUABLE_EXCEPTION(msg);
       break;
     case EXCEPTION_PRIV_INSTRUCTION:
-      OSD_Exception_PRIV_INSTRUCTION::Raise (msg);
+      throw OSD_Exception_PRIV_INSTRUCTION(msg);
       break;
     case EXCEPTION_STACK_OVERFLOW:
-      OSD_Exception_STACK_OVERFLOW::Raise (msg);
+      throw OSD_Exception_STACK_OVERFLOW(msg);
       break;
     case EXCEPTION_FLT_DIVIDE_BY_ZERO:
-      Standard_DivideByZero::Raise (msg);
+      throw Standard_DivideByZero(msg);
       break;
     case EXCEPTION_FLT_STACK_CHECK:
     case EXCEPTION_FLT_OVERFLOW:
-      Standard_Overflow::Raise (msg);
+      throw Standard_Overflow(msg);
       break;
     case EXCEPTION_FLT_UNDERFLOW:
-      Standard_Underflow::Raise (msg);
+      throw Standard_Underflow(msg);
       break;
     case EXCEPTION_FLT_INVALID_OPERATION:
     case EXCEPTION_FLT_DENORMAL_OPERAND:
     case EXCEPTION_FLT_INEXACT_RESULT:
     case STATUS_FLOAT_MULTIPLE_TRAPS:
     case STATUS_FLOAT_MULTIPLE_FAULTS:
-      Standard_NumericError::Raise (msg);
+      throw Standard_NumericError(msg);
       break;
     default:
       break;
@@ -650,27 +649,6 @@ typedef void (* SIG_PFV) (int);
   #include <sys/signal.h>
 #endif
 
-#if defined(HAVE_PTHREAD_H) && defined(NO_CXX_EXCEPTION)
-//============================================================================
-//====  GetOldSigAction
-//====     get previous 
-//============================================================================
-
-static struct sigaction *GetOldSigAction() 
-{
-  static struct sigaction oldSignals[NSIG];
-  return oldSignals;
-}
-
-#ifdef SOLARIS
-static sigfpe_handler_type *GetOldFPE()
-{
-  static sigfpe_handler_type aIEEEHandler[5] = { NULL, NULL, NULL, NULL, NULL } ;
-  return aIEEEHandler;
-}
-#endif
-#endif
-
 //============================================================================
 //==== Handler
 //====     Catche the differents signals:
@@ -691,11 +669,7 @@ static sigfpe_handler_type *GetOldFPE()
 //==== SIGSEGV is handled by "SegvHandler()"
 //============================================================================
 #ifdef SA_SIGINFO
-  #if defined(HAVE_PTHREAD_H) && defined(NO_CXX_EXCEPTION)
-static void Handler (const int theSignal, siginfo_t *theSigInfo, const Standard_Address theContext)
-  #else
 static void Handler (const int theSignal, siginfo_t */*theSigInfo*/, const Standard_Address /*theContext*/)
-  #endif
 #else
 static void Handler (const int theSignal)
 #endif
@@ -710,91 +684,6 @@ static void Handler (const int theSignal)
     perror ("sigaction");
   }
 
-#if defined(HAVE_PTHREAD_H) && defined(NO_CXX_EXCEPTION)
-  if (pthread_self() != getOCCThread()  || !Standard_ErrorHandler::IsInTryBlock()) {
-    // use the previous signal handler
-    // cout << "OSD::Handler: signal " << (int) theSignal << " occured outside a try block " <<  endl ;
-    struct sigaction *oldSignals = GetOldSigAction();
-    struct sigaction  asigacthandler =  oldSignals[theSignal >= 0 && theSignal < NSIG ? theSignal : 0];
-
-    if (asigacthandler.sa_flags & SA_SIGINFO) {
-      void (*aCurInfoHandle)(int, siginfo_t *, void *) = asigacthandler.sa_sigaction;
-
-      siginfo_t * aSigInfo = NULL;
-#ifdef SA_SIGINFO
-      aSigInfo = theSigInfo;
-#endif
-
-      if (aSigInfo) {
-        switch (aSigInfo->si_signo) {
-          case SIGFPE:
-          {
-#ifdef SOLARIS
-            sigfpe_handler_type *aIEEEHandlerTab = GetOldFPE();
-            sigfpe_handler_type  aIEEEHandler = NULL;
-            switch (aSigInfo->si_code) {
-              case FPE_INTDIV_TRAP :
-              case FPE_FLTDIV_TRAP :
-               aIEEEHandler = aIEEEHandlerTab[1];
-                break;
-              case FPE_INTOVF_TRAP :
-              case FPE_FLTOVF_TRAP :
-                aIEEEHandler = aIEEEHandlerTab[2];
-                break;
-              case FPE_FLTUND_TRAP :
-                aIEEEHandler = aIEEEHandlerTab[4];
-                break;
-              case FPE_FLTRES_TRAP :
-                aIEEEHandler = aIEEEHandlerTab[3];
-                break;
-              case FPE_FLTINV_TRAP :
-                aIEEEHandler = aIEEEHandlerTab[0];
-                break;
-              case FPE_FLTSUB_TRAP :
-              default:
-                break;
-            }
-            if (aIEEEHandler) {
-              // cout << "OSD::Handler: calling previous IEEE signal handler with info" <<  endl ;
-              (*aIEEEHandler) (theSignal, aSigInfo, theContext);
-              return;
-            }
-#endif
-            break;
-          }
-          default:
-            break;
-        }
-      }
-      if (aCurInfoHandle) {
-        // cout << "OSD::Handler: calling previous signal handler with info " << aCurInfoHandle <<  endl ;
-        (*aCurInfoHandle) (theSignal, aSigInfo, theContext);
-#ifdef OCCT_DEBUG
-        cerr << " previous signal handler return" <<  endl ;
-#endif
-        return;
-      }
-      else {
-       // cout << "OSD::Handler: no handler with info for the signal" << endl;
-      }
-    }
-    else {
-      // no siginfo needed for the signal
-      void (*aCurHandler) (int) = asigacthandler.sa_handler;
-      if(aCurHandler) {
-        // cout << "OSD::Handler: calling previous signal handler" <<  endl ;
-        (*aCurHandler) (theSignal);
-#ifdef OCCT_DEBUG
-        cerr << " previous signal handler return" <<  endl ;
-#endif
-        return;
-      }
-    }
-    // cout << " Signal occured outside a try block, but no handler for it" <<endl;
-    return;
-  }
-#endif
-
   // cout << "OSD::Handler: signal " << (int) theSignal << " occured inside a try block " <<  endl ;
   if ( ADR_ACT_SIGIO_HANDLER != NULL )
     (*ADR_ACT_SIGIO_HANDLER)() ;
@@ -913,15 +802,9 @@ static void SegvHandler(const int theSignal,
                         siginfo_t *ip,
                         const Standard_Address theContext)
 {
-#ifdef NO_CXX_EXCEPTION
-  if (!Standard_ErrorHandler::IsInTryBlock()) {
-    Handler(theSignal, ip, theContext);
-    return;
-  }
-#else
   (void)theSignal; // silence GCC warnings
   (void)theContext;
-#endif
+
 #ifdef __linux__
   if (fFltExceptions)
     feenableexcept (FE_INVALID | FE_DIVBYZERO | FE_OVERFLOW);
@@ -1149,7 +1032,7 @@ void OSD :: ControlBreak ()
 {
   if ( fCtrlBrk ) {
     fCtrlBrk = Standard_False;
-    OSD_Exception_CTRL_BREAK::Raise ("*** INTERRUPT ***");
+    throw OSD_Exception_CTRL_BREAK("*** INTERRUPT ***");
   }
 }
 
index f0c5171..a305748 100644 (file)
@@ -76,7 +76,7 @@ OpenGl_GraphicDriver::OpenGl_GraphicDriver (const Handle(Aspect_DisplayConnectio
 #if !defined(_WIN32) && !defined(__ANDROID__) && !defined(__QNX__) && (!defined(__APPLE__) || defined(MACOSX_USE_GLX))
   if (myDisplayConnection.IsNull())
   {
-    //Aspect_GraphicDeviceDefinitionError::Raise ("OpenGl_GraphicDriver: cannot connect to X server!");
+    //throw Aspect_GraphicDeviceDefinitionError("OpenGl_GraphicDriver: cannot connect to X server!");
     return;
   }
 
@@ -97,7 +97,7 @@ OpenGl_GraphicDriver::OpenGl_GraphicDriver (const Handle(Aspect_DisplayConnectio
   if (theToInitialize
   && !InitContext())
   {
-    Aspect_GraphicDeviceDefinitionError::Raise ("OpenGl_GraphicDriver: default context can not be initialized!");
+    throw Aspect_GraphicDeviceDefinitionError("OpenGl_GraphicDriver: default context can not be initialized!");
   }
 
   // default layers are always presented in display layer sequence it can not be removed
@@ -186,7 +186,7 @@ void OpenGl_GraphicDriver::ReleaseContext()
   for (NCollection_Map<Handle(OpenGl_View)>::Iterator aViewIter (myMapOfView);
        aViewIter.More(); aViewIter.Next())
   {
-    const Handle(OpenGl_View)& aView = aViewIter.ChangeValue();
+    const Handle(OpenGl_View)& aView = aViewIter.Value();
     const Handle(OpenGl_Window)& aWindow = aView->GlWindow();
     if (aWindow.IsNull())
     {
@@ -208,7 +208,7 @@ void OpenGl_GraphicDriver::ReleaseContext()
   for (NCollection_Map<Handle(OpenGl_View)>::Iterator aViewIter (myMapOfView);
        aViewIter.More(); aViewIter.Next())
   {
-    const Handle(OpenGl_View)& aView = aViewIter.ChangeValue();
+    const Handle(OpenGl_View)& aView = aViewIter.Value();
     aView->ReleaseGlResources (aCtxShared);
   }
 
@@ -223,7 +223,7 @@ void OpenGl_GraphicDriver::ReleaseContext()
   for (NCollection_Map<Handle(OpenGl_View)>::Iterator aViewIter (myMapOfView);
        aViewIter.More(); aViewIter.Next())
   {
-    const Handle(OpenGl_View)& aView = aViewIter.ChangeValue();
+    const Handle(OpenGl_View)& aView = aViewIter.Value();
     const Handle(OpenGl_Window)& aWindow = aView->GlWindow();
     if (aWindow.IsNull())
     {
index babde6c..4c53148 100644 (file)
@@ -47,7 +47,7 @@ OpenGl_Group::OpenGl_Group (const Handle(Graphic3d_Structure)& theStruct)
   Handle(OpenGl_Structure) aStruct = Handle(OpenGl_Structure)::DownCast (myStructure->CStructure());
   if (aStruct.IsNull())
   {
-    Graphic3d_GroupDefinitionError::Raise ("OpenGl_Group should be created by OpenGl_Structure!");
+    throw Graphic3d_GroupDefinitionError("OpenGl_Group should be created by OpenGl_Structure!");
   }
 }
 
index b89d0cc..6467201 100644 (file)
@@ -49,7 +49,7 @@ OpenGl_StructureShadow::OpenGl_StructureShadow (const Handle(Graphic3d_Structure
 // =======================================================================
 void OpenGl_StructureShadow::Connect (Graphic3d_CStructure& )
 {
-  Standard_ProgramError::Raise ("Error! OpenGl_StructureShadow::Connect() should not be called!");
+  throw Standard_ProgramError("Error! OpenGl_StructureShadow::Connect() should not be called!");
 }
 
 // =======================================================================
@@ -58,5 +58,5 @@ void OpenGl_StructureShadow::Connect (Graphic3d_CStructure& )
 // =======================================================================
 void OpenGl_StructureShadow::Disconnect (Graphic3d_CStructure& )
 {
-  Standard_ProgramError::Raise ("Error! OpenGl_StructureShadow::Disconnect() should not be called!");
+  throw Standard_ProgramError("Error! OpenGl_StructureShadow::Disconnect() should not be called!");
 }
index 2a0d430..4a83643 100644 (file)
@@ -181,7 +181,7 @@ OpenGl_Window::OpenGl_Window (const Handle(OpenGl_GraphicDriver)& theDriver,
    || anEglContext == EGL_NO_CONTEXT
    || anEglConfig == NULL)
   {
-    Aspect_GraphicDeviceDefinitionError::Raise ("OpenGl_Window, EGL does not provide compatible configurations!");
+    throw Aspect_GraphicDeviceDefinitionError("OpenGl_Window, EGL does not provide compatible configurations!");
     return;
   }
 
@@ -195,13 +195,13 @@ OpenGl_Window::OpenGl_Window (const Handle(OpenGl_GraphicDriver)& theDriver,
                                         NULL);
     if (anEglSurf == EGL_NO_SURFACE)
     {
-      Aspect_GraphicDeviceDefinitionError::Raise ("OpenGl_Window, EGL is unable to create surface for window!");
+      throw Aspect_GraphicDeviceDefinitionError("OpenGl_Window, EGL is unable to create surface for window!");
       return;
     }
   }
   else if (theGContext != anEglContext)
   {
-    Aspect_GraphicDeviceDefinitionError::Raise ("OpenGl_Window, EGL is used in unsupported combination!");
+    throw Aspect_GraphicDeviceDefinitionError("OpenGl_Window, EGL is used in unsupported combination!");
     return;
   }
   else
@@ -209,7 +209,7 @@ OpenGl_Window::OpenGl_Window (const Handle(OpenGl_GraphicDriver)& theDriver,
     anEglSurf = eglGetCurrentSurface(EGL_DRAW);
     if (anEglSurf == EGL_NO_SURFACE)
     {
-      Aspect_GraphicDeviceDefinitionError::Raise ("OpenGl_Window, EGL is unable to retrieve current surface!");
+      throw Aspect_GraphicDeviceDefinitionError("OpenGl_Window, EGL is unable to retrieve current surface!");
       return;
     }
   }
@@ -259,7 +259,7 @@ OpenGl_Window::OpenGl_Window (const Handle(OpenGl_GraphicDriver)& theDriver,
 
     TCollection_AsciiString aMsg ("OpenGl_Window::CreateWindow: ChoosePixelFormat failed. Error code: ");
     aMsg += (int )GetLastError();
-    Aspect_GraphicDeviceDefinitionError::Raise (aMsg.ToCString());
+    throw Aspect_GraphicDeviceDefinitionError(aMsg.ToCString());
     return;
   }
 
@@ -359,7 +359,7 @@ OpenGl_Window::OpenGl_Window (const Handle(OpenGl_GraphicDriver)& theDriver,
 
       TCollection_AsciiString aMsg("OpenGl_Window::CreateWindow: SetPixelFormat failed. Error code: ");
       aMsg += (int )GetLastError();
-      Aspect_GraphicDeviceDefinitionError::Raise (aMsg.ToCString());
+      throw Aspect_GraphicDeviceDefinitionError(aMsg.ToCString());
       return;
     }
 
@@ -450,7 +450,7 @@ OpenGl_Window::OpenGl_Window (const Handle(OpenGl_GraphicDriver)& theDriver,
 
       TCollection_AsciiString aMsg ("OpenGl_Window::CreateWindow: wglCreateContext failed. Error code: ");
       aMsg += (int )GetLastError();
-      Aspect_GraphicDeviceDefinitionError::Raise (aMsg.ToCString());
+      throw Aspect_GraphicDeviceDefinitionError(aMsg.ToCString());
       return;
     }
   }
@@ -460,7 +460,7 @@ OpenGl_Window::OpenGl_Window (const Handle(OpenGl_GraphicDriver)& theDriver,
   {
     TCollection_AsciiString aMsg ("OpenGl_Window::CreateWindow: wglShareLists failed. Error code: ");
     aMsg += (int )GetLastError();
-    Aspect_GraphicDeviceDefinitionError::Raise (aMsg.ToCString());
+    throw Aspect_GraphicDeviceDefinitionError(aMsg.ToCString());
     return;
   }
 
@@ -481,12 +481,12 @@ OpenGl_Window::OpenGl_Window (const Handle(OpenGl_GraphicDriver)& theDriver,
   int isGl = 0;
   if (aVis == NULL)
   {
-    Aspect_GraphicDeviceDefinitionError::Raise ("OpenGl_Window::CreateWindow: XGetVisualInfo is unable to choose needed configuration in existing OpenGL context. ");
+    throw Aspect_GraphicDeviceDefinitionError("OpenGl_Window::CreateWindow: XGetVisualInfo is unable to choose needed configuration in existing OpenGL context. ");
     return;
   }
   else if (glXGetConfig (aDisp, aVis, GLX_USE_GL, &isGl) != 0 || !isGl)
   {
-    Aspect_GraphicDeviceDefinitionError::Raise ("OpenGl_Window::CreateWindow: window Visual does not support GL rendering!");
+    throw Aspect_GraphicDeviceDefinitionError("OpenGl_Window::CreateWindow: window Visual does not support GL rendering!");
     return;
   }
 
@@ -559,7 +559,7 @@ OpenGl_Window::OpenGl_Window (const Handle(OpenGl_GraphicDriver)& theDriver,
     aGContext = glXCreateContext (aDisp, aVis, aSlaveCtx, GL_TRUE);
     if (aGContext == NULL)
     {
-      Aspect_GraphicDeviceDefinitionError::Raise ("OpenGl_Window::CreateWindow: glXCreateContext failed.");
+      throw Aspect_GraphicDeviceDefinitionError("OpenGl_Window::CreateWindow: glXCreateContext failed.");
       return;
     }
   }
index bddf2df..85f9ad4 100644 (file)
@@ -91,7 +91,7 @@ OpenGl_Window::OpenGl_Window (const Handle(OpenGl_GraphicDriver)& theDriver,
     || ![EAGLContext setCurrentContext: aGLContext])
     {
       TCollection_AsciiString aMsg ("OpenGl_Window::CreateWindow: EAGLContext creation failed");
-      Aspect_GraphicDeviceDefinitionError::Raise (aMsg.ToCString());
+      throw Aspect_GraphicDeviceDefinitionError(aMsg.ToCString());
       return;
     }
 
@@ -102,7 +102,7 @@ OpenGl_Window::OpenGl_Window (const Handle(OpenGl_GraphicDriver)& theDriver,
     if (![EAGLContext setCurrentContext: aGLContext])
     {
       TCollection_AsciiString aMsg ("OpenGl_Window::CreateWindow: EAGLContext can not be assigned");
-      Aspect_GraphicDeviceDefinitionError::Raise (aMsg.ToCString());
+      throw Aspect_GraphicDeviceDefinitionError(aMsg.ToCString());
       return;
     }
 
@@ -183,7 +183,7 @@ OpenGl_Window::OpenGl_Window (const Handle(OpenGl_GraphicDriver)& theDriver,
     if (aGLContext == NULL)
     {
       TCollection_AsciiString aMsg ("OpenGl_Window::CreateWindow: NSOpenGLContext creation failed");
-      Aspect_GraphicDeviceDefinitionError::Raise (aMsg.ToCString());
+      throw Aspect_GraphicDeviceDefinitionError(aMsg.ToCString());
       return;
     }
 
@@ -317,7 +317,7 @@ void OpenGl_Window::Init()
     if (!aDefFbo->InitWithRB (myGlContext, myWidth, myHeight, GL_RGBA8, GL_DEPTH24_STENCIL8, aWinRBColor))
     {
       TCollection_AsciiString aMsg ("OpenGl_Window::CreateWindow: default FBO creation failed");
-      Aspect_GraphicDeviceDefinitionError::Raise (aMsg.ToCString());
+      throw Aspect_GraphicDeviceDefinitionError(aMsg.ToCString());
       return;
     }
   }
@@ -326,7 +326,7 @@ void OpenGl_Window::Init()
     if (!aDefFbo->InitWrapper (myGlContext))
     {
       TCollection_AsciiString aMsg ("OpenGl_Window::CreateWindow: default FBO wrapper creation failed");
-      Aspect_GraphicDeviceDefinitionError::Raise (aMsg.ToCString());
+      throw Aspect_GraphicDeviceDefinitionError(aMsg.ToCString());
       return;
     }
 
index 935ca22..65ca6a2 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(PCDM_DriverError, Standard_Failure)
 
 #if !defined No_Exception && !defined No_PCDM_DriverError
   #define PCDM_DriverError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) PCDM_DriverError::Raise(MESSAGE);
+  if (CONDITION) throw PCDM_DriverError(MESSAGE);
 #else
   #define PCDM_DriverError_Raise_if(CONDITION, MESSAGE)
 #endif
index 8ce4da3..3557478 100644 (file)
@@ -61,7 +61,7 @@ void PCDM_ReadWriter::Open (Storage_BaseDriver&                 aDriver,
       break;
     }
     aMsg << (char)0;
-    Standard_Failure::Raise(aMsg);
+    throw Standard_Failure(aMsg.str().c_str());
   }
 }
 
index 8208664..5deb83e 100644 (file)
@@ -54,17 +54,17 @@ void PCDM_StorageDriver::Write(const Handle(CDM_Document)& aDocument, const TCol
   PCDM_SequenceOfDocument thePersistentDocuments;
   {
     try { OCC_CATCH_SIGNALS Make(aDocument,thePersistentDocuments);}
-    catch (Standard_Failure) {
-      aMsg << Standard_Failure::Caught()<<(char)0;
+    catch (Standard_Failure const& anException) {
+      aMsg << anException<<(char)0;
       Failure=Standard_True;
     }
   }
 
-  if(Failure) PCDM_DriverError::Raise(aMsg);
+  if(Failure) throw PCDM_DriverError(aMsg.str().c_str());
 
   if(thePersistentDocuments.IsEmpty()) {
     aMsg << "the storage driver: " << DynamicType()->Name() << "returned no documents to store" << (char) 0;
-    PCDM_DriverError::Raise(aMsg);
+    throw PCDM_DriverError(aMsg.str().c_str());
   }
 
   Standard_Integer i=1;
@@ -97,7 +97,7 @@ void PCDM_StorageDriver::Write(const Handle(CDM_Document)& aDocument, const TCol
   theFile.Close();
 
   if ( theData->ErrorStatus() != Storage_VSOk )
-    PCDM_DriverError::Raise(theData->ErrorStatusExtension().ToCString());
+    throw PCDM_DriverError(theData->ErrorStatusExtension().ToCString());
 }
 
 
@@ -115,8 +115,7 @@ Handle(PCDM_Document) PCDM_StorageDriver::Make(const Handle(CDM_Document)& ) {
   Handle(PCDM_Document) voidDocument;
   Standard_SStream aMsg;
   aMsg << "No Make method were implemented in this Driver" << DynamicType()->Name() << (char) 0;
-  Standard_NotImplemented::Raise(aMsg);
-  return voidDocument;
+  throw Standard_NotImplemented(aMsg.str().c_str());
 }
 
 void PCDM_StorageDriver::Make(const Handle(CDM_Document)& aDocument, PCDM_SequenceOfDocument& Documents) {
index 665c719..d67c4f8 100644 (file)
@@ -1512,7 +1512,7 @@ void PLib::Trimming(const Standard_Real U1,
 
   if (rat) {
     if(len != WCoefs->Length())
-      Standard_Failure::Raise("PLib::Trimming : nbcoefs/dim != nbweights !!!");
+      throw Standard_Failure("PLib::Trimming : nbcoefs/dim != nbweights !!!");
     upw = WCoefs->Upper();
   }
   len --;
@@ -1861,10 +1861,10 @@ void PLib::JacobiParameters(const GeomAbs_Shape ConstraintOrder,
   case GeomAbs_C1: NivConstr = 1; break;
   case GeomAbs_C2: NivConstr = 2; break;
   default: 
-    Standard_ConstructionError::Raise("Invalid ConstraintOrder");
+    throw Standard_ConstructionError("Invalid ConstraintOrder");
   }
   if (MaxDegree < 2*NivConstr+1)
-    Standard_ConstructionError::Raise("Invalid MaxDegree");
+    throw Standard_ConstructionError("Invalid MaxDegree");
   
   if (Code >= 1)
     WorkDegree = MaxDegree + 9;
@@ -1892,7 +1892,7 @@ void PLib::JacobiParameters(const GeomAbs_Shape ConstraintOrder,
   else if (WorkDegree < NDEG61) 
     IPMIN=NDEG61;
   else
-    Standard_ConstructionError::Raise("Invalid MaxDegree");
+    throw Standard_ConstructionError("Invalid MaxDegree");
   // ---> Nbre de points voulus.
   Standard_Integer IWANT=0;
   switch (Code) {
@@ -1906,7 +1906,7 @@ void PLib::JacobiParameters(const GeomAbs_Shape ConstraintOrder,
   case  3: IWANT=NDEG50; break;
   case  4: IWANT=NDEG61; break;
   default: 
-    Standard_ConstructionError::Raise("Invalid Code");
+    throw Standard_ConstructionError("Invalid Code");
   }      
   //-->  NbGaussPoints est le nombre de points de discretisation de la fonction,
   //     il ne peut prendre que les valeurs 8,10,15,20,25,30,40,50 ou 61.
@@ -1928,7 +1928,7 @@ void PLib::JacobiParameters(const GeomAbs_Shape ConstraintOrder,
     case GeomAbs_C1: NivConstr = 1; break;
     case GeomAbs_C2: NivConstr = 2; break;
     default: 
-      Standard_ConstructionError::Raise("Invalid ConstraintOrder");
+      throw Standard_ConstructionError("Invalid ConstraintOrder");
   }
   return NivConstr;
 }
@@ -1946,7 +1946,7 @@ void PLib::JacobiParameters(const GeomAbs_Shape ConstraintOrder,
     case 1: ConstraintOrder = GeomAbs_C1; break;
     case 2: ConstraintOrder = GeomAbs_C2; break;
     default: 
-      Standard_ConstructionError::Raise("Invalid NivConstr");
+      throw Standard_ConstructionError("Invalid NivConstr");
   }
   return ConstraintOrder;
 }
index e8a418f..2d16238 100644 (file)
@@ -45,11 +45,11 @@ const Standard_Integer UNDEFINED=-999;
     case GeomAbs_C1: myNivConstr = 1; break;
     case GeomAbs_C2: myNivConstr = 2; break;
     default: 
-      Standard_ConstructionError::Raise("Invalid ConstraintOrder");
+      throw Standard_ConstructionError("Invalid ConstraintOrder");
   }
   myDegree = myWorkDegree - 2*(myNivConstr+1);
   if (myDegree > 30)
-    Standard_ConstructionError::Raise("Invalid Degree");
+    throw Standard_ConstructionError("Invalid Degree");
 }
 
 //=======================================================================
@@ -66,7 +66,7 @@ void PLib_JacobiPolynomial::Points(const Standard_Integer NbGaussPoints,
       NbGaussPoints != NDEG40 && NbGaussPoints != NDEG50 && 
       NbGaussPoints != NDEG61) || 
       NbGaussPoints <= myDegree)
-    Standard_ConstructionError::Raise("Invalid NbGaussPoints");
+    throw Standard_ConstructionError("Invalid NbGaussPoints");
 
   math_Vector DecreasingPoints(1,NbGaussPoints);
 
index 17354e8..cf4ca7c 100644 (file)
@@ -36,7 +36,7 @@ Plate_LinearScalarConstraint::Plate_LinearScalarConstraint
 
 Plate_LinearScalarConstraint::Plate_LinearScalarConstraint(const Plate_Array1OfPinpointConstraint& thePPC,const TColgp_Array1OfXYZ& theCoeff)
 {
-  if(theCoeff.Length()!= thePPC.Length()) Standard_DimensionMismatch::Raise();
+  if(theCoeff.Length()!= thePPC.Length()) throw Standard_DimensionMismatch();
   myPPC = new Plate_HArray1OfPinpointConstraint(1, thePPC.Length());
   myCoef = new TColgp_HArray2OfXYZ(1,1,1, theCoeff.Length());
 
@@ -49,7 +49,7 @@ Plate_LinearScalarConstraint::Plate_LinearScalarConstraint(const Plate_Array1OfP
 Plate_LinearScalarConstraint::Plate_LinearScalarConstraint
    (const Plate_Array1OfPinpointConstraint& thePPC,const TColgp_Array2OfXYZ& theCoeff)
 {
-  if(theCoeff.RowLength()!= thePPC.Length()) Standard_DimensionMismatch::Raise();
+  if(theCoeff.RowLength()!= thePPC.Length()) throw Standard_DimensionMismatch();
   myPPC = new Plate_HArray1OfPinpointConstraint(1, thePPC.Length());
   myCoef = new TColgp_HArray2OfXYZ(1, theCoeff.ColLength(),1, theCoeff.RowLength());
   
index b3cda68..cbbe761 100644 (file)
@@ -24,7 +24,7 @@ Plate_LinearXYZConstraint::Plate_LinearXYZConstraint() {}
 
 Plate_LinearXYZConstraint::Plate_LinearXYZConstraint(const Plate_Array1OfPinpointConstraint& thePPC,const TColStd_Array1OfReal& theCoeff)
 {
-  if(theCoeff.Length()!= thePPC.Length()) Standard_DimensionMismatch::Raise();
+  if(theCoeff.Length()!= thePPC.Length()) throw Standard_DimensionMismatch();
   myPPC = new Plate_HArray1OfPinpointConstraint(1, thePPC.Length());
   myCoef = new TColStd_HArray2OfReal(1,1,1, theCoeff.Length());
   
@@ -35,7 +35,7 @@ Plate_LinearXYZConstraint::Plate_LinearXYZConstraint(const Plate_Array1OfPinpoin
 
 Plate_LinearXYZConstraint::Plate_LinearXYZConstraint(const Plate_Array1OfPinpointConstraint& thePPC,const TColStd_Array2OfReal& theCoeff)
 {
-  if(theCoeff.RowLength()!= thePPC.Length()) Standard_DimensionMismatch::Raise();
+  if(theCoeff.RowLength()!= thePPC.Length()) throw Standard_DimensionMismatch();
   myPPC = new Plate_HArray1OfPinpointConstraint(1, thePPC.Length());
   myCoef = new TColStd_HArray2OfReal(1, theCoeff.ColLength(),1, theCoeff.RowLength());
   
index 02de880..ce35e90 100644 (file)
@@ -36,7 +36,7 @@ Plate_SampledCurveConstraint::Plate_SampledCurveConstraint(const Plate_SequenceO
 {
   Standard_Integer m = SOPPC.Length();
 
-  if (n > m)  Standard_DimensionMismatch::Raise();
+  if (n > m)  throw Standard_DimensionMismatch();
   for(Standard_Integer index =1; index <= m;index++)
     myLXYZC.SetPPC(index,SOPPC(index));
 
index 182e69d..04b7f59 100644 (file)
@@ -52,7 +52,7 @@ Handle(Standard_Transient) Plugin::Load (const Standard_GUID& aGUID,
       aMsg << theResource.ToCString() << endl;
       if (theVerbose)
         cout << "could not find the resource:" << theResource.ToCString() << endl;
-      Plugin_Failure::Raise(aMsg);
+      throw Plugin_Failure(aMsg.str().c_str());
     }
     
     TCollection_AsciiString thePluginLibrary("");
@@ -78,7 +78,7 @@ Handle(Standard_Transient) Plugin::Load (const Standard_GUID& aGUID,
       aMsg << error.ToCString();
       if (theVerbose)
         cout << "could not open: "  << PluginResource->Value(theResource.ToCString())<< " ; reason: "<< error.ToCString() << endl;
-      Plugin_Failure::Raise(aMsg);
+      throw Plugin_Failure(aMsg.str().c_str());
     }
     f = theSharedLibrary.DlSymb("PLUGINFACTORY");
     if( f == NULL ) {
@@ -86,7 +86,7 @@ Handle(Standard_Transient) Plugin::Load (const Standard_GUID& aGUID,
       Standard_SStream aMsg; aMsg << "could not find the factory in:";
       aMsg << PluginResource->Value(theResource.ToCString());
       aMsg << error.ToCString();
-      Plugin_Failure::Raise(aMsg);
+      throw Plugin_Failure(aMsg.str().c_str());
     }
     theMapOfFunctions.Bind(pid,f);
   }
index 976a41a..5ee7a1a 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Plugin_Failure, Standard_Failure)
 
 #if !defined No_Exception && !defined No_Plugin_Failure
   #define Plugin_Failure_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Plugin_Failure::Raise(MESSAGE);
+  if (CONDITION) throw Plugin_Failure(MESSAGE);
 #else
   #define Plugin_Failure_Raise_if(CONDITION, MESSAGE)
 #endif
index 7f3316a..6de2f89 100644 (file)
@@ -242,8 +242,8 @@ void Poly_CoherentTriangle::RemoveConnection(const Standard_Integer iConn)
       else if (pConnectedTri->mypConnected[2] == this)
         iConn1 = 2;
       else
-        Standard_ProgramError::Raise("Poly_CoherentTriangle::RemoveConnection: "
-                                     "wrong connection between triangles");
+        throw Standard_ProgramError("Poly_CoherentTriangle::RemoveConnection: "
+                                    "wrong connection between triangles");
     }
     pConnectedTri->mypConnected[iConn1] = 0L;
     pConnectedTri->myNodesOnConnected[iConn1] = -1;
index 0c2f761..772ee81 100644 (file)
@@ -585,8 +585,8 @@ void Poly_CoherentTriangulation::RemoveLink (Poly_CoherentLink& theLink)
         else if (iNode == pTri[i]->Node(2))
           const_cast<Poly_CoherentTriangle *>(pTri[i])->mypLink[2] = 0L;
         else
-          Standard_ProgramError::Raise("Poly_CoherentTriangulation::RemoveLink: "
-                                       " wrong connectivity between triangles");
+          throw Standard_ProgramError("Poly_CoherentTriangulation::RemoveLink: "
+                                      " wrong connectivity between triangles");
       }
     }
   } 
@@ -619,8 +619,8 @@ Poly_CoherentLink * Poly_CoherentTriangulation::AddLink
       else if (pTriOpp->Node(2) == theTri.GetConnectedNode(theConn))
         const_cast<Poly_CoherentTriangle *>(pTriOpp)->mypLink[2] = pLink;
       else
-        Standard_ProgramError::Raise("Poly_CoherentTriangulation::AddLink: "
-                                     "Bad connectivity of triangles");
+        throw Standard_ProgramError("Poly_CoherentTriangulation::AddLink: "
+                                    "Bad connectivity of triangles");
     }
   }
   return pLink;
@@ -660,8 +660,8 @@ Standard_Boolean Poly_CoherentTriangulation::FindTriangle
         else if (aTri.Node(1) == theLink.Node(1))
           pTri[1] = &aTri;
       } else
-        Standard_ProgramError::Raise("Poly_CoherentTriangulation::FindTriangle : "
-                                     " Data incoherence detected");
+        throw Standard_ProgramError("Poly_CoherentTriangulation::FindTriangle : "
+                                    " Data incoherence detected");
       if (pTri[0] && pTri[1])
         break;
     }
index b9c7419..1e0466a 100644 (file)
@@ -175,7 +175,7 @@ const gp_Pnt& Poly_Triangulation::Node (const Standard_Integer theIndex) const
 {
   if (theIndex < 1 || theIndex > myNodes.Size())
   {
-    Standard_OutOfRange::Raise ("Poly_Triangulation::Node : index out of range");
+    throw Standard_OutOfRange ("Poly_Triangulation::Node : index out of range");
   }
   return myNodes.Value (theIndex);
 }
@@ -189,7 +189,7 @@ gp_Pnt& Poly_Triangulation::ChangeNode (const Standard_Integer theIndex)
 {
   if (theIndex < 1 || theIndex > myNodes.Size())
   {
-    Standard_OutOfRange::Raise ("Poly_Triangulation::ChangeNode : index out of range");
+    throw Standard_OutOfRange ("Poly_Triangulation::ChangeNode : index out of range");
   }
   return myNodes.ChangeValue (theIndex);
 }
@@ -223,7 +223,7 @@ const gp_Pnt2d& Poly_Triangulation::UVNode (const Standard_Integer theIndex) con
 {
   if (myUVNodes.IsNull() || theIndex < 1 || theIndex > myUVNodes->Size())
   {
-    Standard_OutOfRange::Raise ("Poly_Triangulation::UVNode : index out of range");
+    throw Standard_OutOfRange ("Poly_Triangulation::UVNode : index out of range");
   }
   return myUVNodes->Value (theIndex);
 }
@@ -237,7 +237,7 @@ gp_Pnt2d& Poly_Triangulation::ChangeUVNode (const Standard_Integer theIndex)
 {
   if (myUVNodes.IsNull() || theIndex < 1 || theIndex > myUVNodes->Size())
   {
-    Standard_OutOfRange::Raise ("Poly_Triangulation::ChangeUVNode : index out of range");
+    throw Standard_OutOfRange ("Poly_Triangulation::ChangeUVNode : index out of range");
   }
   return myUVNodes->ChangeValue (theIndex);
 }
@@ -271,7 +271,7 @@ const Poly_Triangle& Poly_Triangulation::Triangle (const Standard_Integer theInd
 {
   if (theIndex < 1 || theIndex > myTriangles.Size())
   {
-    Standard_OutOfRange::Raise ("Poly_Triangulation::Triangle : index out of range");
+    throw Standard_OutOfRange ("Poly_Triangulation::Triangle : index out of range");
   }
   return myTriangles.Value (theIndex);
 }
@@ -285,7 +285,7 @@ Poly_Triangle& Poly_Triangulation::ChangeTriangle (const Standard_Integer theInd
 {
   if (theIndex < 1 || theIndex > myTriangles.Size())
   {
-    Standard_OutOfRange::Raise ("Poly_Triangulation::ChangeTriangle : index out of range");
+    throw Standard_OutOfRange ("Poly_Triangulation::ChangeTriangle : index out of range");
   }
   return myTriangles.ChangeValue (theIndex);
 }
@@ -299,7 +299,7 @@ void Poly_Triangulation::SetNormals (const Handle(TShort_HArray1OfShortReal)& th
 {
 
   if(theNormals.IsNull() || theNormals->Length() != 3*myNbNodes) {
-    Standard_DomainError::Raise("Poly_Triangulation::SetNormals : wrong length");
+    throw Standard_DomainError("Poly_Triangulation::SetNormals : wrong length");
   }
 
   myNormals = theNormals;
@@ -314,8 +314,8 @@ const TShort_Array1OfShortReal& Poly_Triangulation::Normals() const
 {
 
   if(myNormals.IsNull() || myNormals->Length() != 3*myNbNodes) {
-    Standard_NullObject::Raise("Poly_Triangulation::Normals : "
-                               "wrong length or null array");
+    throw Standard_NullObject("Poly_Triangulation::Normals : "
+                              "wrong length or null array");
   }
 
   return myNormals->Array1();
@@ -330,8 +330,8 @@ TShort_Array1OfShortReal& Poly_Triangulation::ChangeNormals()
 {
 
   if(myNormals.IsNull() || myNormals->Length() != 3*myNbNodes) {
-    Standard_NullObject::Raise("Poly_Triangulation::ChangeNormals : "
-                               "wrong length or null array");
+    throw Standard_NullObject("Poly_Triangulation::ChangeNormals : "
+                              "wrong length or null array");
   }
 
   return myNormals->ChangeArray1();
@@ -359,7 +359,7 @@ void Poly_Triangulation::SetNormal (const Standard_Integer theIndex, const gp_Di
 {
   if (myNormals.IsNull() || theIndex < 1 || theIndex > myNodes.Size())
   {
-    Standard_NullObject::Raise("Poly_Triangulation::SetNormal : empty array or index out of range");
+    throw Standard_NullObject ("Poly_Triangulation::SetNormal : empty array or index out of range");
   }
 
   myNormals->ChangeValue (theIndex * 3 - 2) = (Standard_ShortReal) theNormal.X();
@@ -376,7 +376,7 @@ const gp_Dir Poly_Triangulation::Normal (const Standard_Integer theIndex) const
 {
   if (myNormals.IsNull() || theIndex < 1 || theIndex > myNodes.Size())
   {
-    Standard_NullObject::Raise("Poly_Triangulation::Normal : empty array or index out of range");
+    throw Standard_NullObject ("Poly_Triangulation::Normal : empty array or index out of range");
   }
 
   gp_Dir N;
index f9583f2..f657d00 100644 (file)
@@ -150,7 +150,7 @@ static void d1(const Standard_Real t,
     DS1_v*DS1_v + Ort*DS2_v);
 
   Standard_Real det = dE_du.X()*dE_dv.Y() - dE_du.Y()*dE_dv.X();
-  if (fabs(det) < gp::Resolution()) Standard_ConstructionError::Raise();
+  if (fabs(det) < gp::Resolution()) throw Standard_ConstructionError();
 
   gp_Mat2d M(gp_XY(dE_dv.Y()/det, -dE_du.Y()/det), 
     gp_XY(-dE_dv.X()/det, dE_du.X()/det));
@@ -186,7 +186,7 @@ static void d2(const Standard_Real t,
     DS1_v*DS1_v + Ort*DS2_v);
 
   Standard_Real det = dE_du.X()*dE_dv.Y() - dE_du.Y()*dE_dv.X();
-  if (fabs(det) < gp::Resolution()) Standard_ConstructionError::Raise();
+  if (fabs(det) < gp::Resolution()) throw Standard_ConstructionError();
 
   gp_Mat2d M(gp_XY(dE_dv.Y()/det, -dE_du.Y()/det), 
     gp_XY(-dE_dv.X()/det, dE_du.X()/det));
@@ -259,7 +259,7 @@ static void d1CurvOnSurf(const Standard_Real t,
     DS1_v*DS1_v + Ort*DS2_v);
 
   Standard_Real det = dE_du.X()*dE_dv.Y() - dE_du.Y()*dE_dv.X();
-  if (fabs(det) < gp::Resolution()) Standard_ConstructionError::Raise();
+  if (fabs(det) < gp::Resolution()) throw Standard_ConstructionError();
 
   gp_Mat2d M(gp_XY(dE_dv.Y()/det, -dE_du.Y()/det), 
     gp_XY(-dE_dv.X()/det, dE_du.X()/det));
@@ -300,7 +300,7 @@ static void d2CurvOnSurf(const Standard_Real t,
     DS1_v*DS1_v + Ort*DS2_v);
 
   Standard_Real det = dE_du.X()*dE_dv.Y() - dE_du.Y()*dE_dv.X();
-  if (fabs(det) < gp::Resolution()) Standard_ConstructionError::Raise();
+  if (fabs(det) < gp::Resolution()) throw Standard_ConstructionError();
 
   gp_Mat2d M(gp_XY(dE_dv.Y()/det, -dE_du.Y()/det), 
     gp_XY(-dE_dv.X()/det, dE_du.X()/det));
@@ -1185,7 +1185,7 @@ void ProjLib_CompProjectedCurve::Bounds(const Standard_Integer Index,
   Standard_Real& Udeb,
   Standard_Real& Ufin) const
 {
-  if(Index < 1 || Index > myNbCurves) Standard_NoSuchObject::Raise();
+  if(Index < 1 || Index > myNbCurves) throw Standard_NoSuchObject();
   Udeb = mySequence->Value(Index)->Value(1).X();
   Ufin = mySequence->Value(Index)->Value(mySequence->Value(Index)->Length()).X();
 }
@@ -1196,7 +1196,7 @@ void ProjLib_CompProjectedCurve::Bounds(const Standard_Integer Index,
 
 Standard_Boolean ProjLib_CompProjectedCurve::IsSinglePnt(const Standard_Integer Index, gp_Pnt2d& P) const
 {
-  if(Index < 1 || Index > myNbCurves) Standard_NoSuchObject::Raise();
+  if(Index < 1 || Index > myNbCurves) throw Standard_NoSuchObject();
   P = gp_Pnt2d(mySequence->Value(Index)->Value(1).Y(), mySequence->Value(Index)->Value(1).Z());
   return mySnglPnts->Value(Index);
 }
@@ -1208,7 +1208,7 @@ Standard_Boolean ProjLib_CompProjectedCurve::IsSinglePnt(const Standard_Integer
 
 Standard_Boolean ProjLib_CompProjectedCurve::IsUIso(const Standard_Integer Index, Standard_Real& U) const
 {
-  if(Index < 1 || Index > myNbCurves) Standard_NoSuchObject::Raise();
+  if(Index < 1 || Index > myNbCurves) throw Standard_NoSuchObject();
   U = mySequence->Value(Index)->Value(1).Y();
   return myUIso->Value(Index);
 }
@@ -1219,7 +1219,7 @@ Standard_Boolean ProjLib_CompProjectedCurve::IsUIso(const Standard_Integer Index
 
 Standard_Boolean ProjLib_CompProjectedCurve::IsVIso(const Standard_Integer Index, Standard_Real& V) const
 {
-  if(Index < 1 || Index > myNbCurves) Standard_NoSuchObject::Raise();
+  if(Index < 1 || Index > myNbCurves) throw Standard_NoSuchObject();
   V = mySequence->Value(Index)->Value(1).Z();
   return myVIso->Value(Index);
 }
@@ -1254,7 +1254,7 @@ void ProjLib_CompProjectedCurve::D0(const Standard_Real U,gp_Pnt2d& P) const
       break;
     }
   }
-  if (!found) Standard_DomainError::Raise("ProjLib_CompProjectedCurve::D0");
+  if (!found) throw Standard_DomainError("ProjLib_CompProjectedCurve::D0");
 
   Standard_Real U0, V0;
 
@@ -1389,7 +1389,7 @@ void ProjLib_CompProjectedCurve::D2(const Standard_Real t,
 gp_Vec2d ProjLib_CompProjectedCurve::DN(const Standard_Real t, 
   const Standard_Integer N) const 
 {
-  if (N < 1 ) Standard_OutOfRange::Raise("ProjLib_CompProjectedCurve : N must be greater than 0");
+  if (N < 1 ) throw Standard_OutOfRange("ProjLib_CompProjectedCurve : N must be greater than 0");
   else if (N ==1) 
   {
     gp_Pnt2d P;
@@ -1405,7 +1405,7 @@ gp_Vec2d ProjLib_CompProjectedCurve::DN(const Standard_Real t,
     return V2;
   }
   else if (N > 2 ) 
-    Standard_NotImplemented::Raise("ProjLib_CompProjectedCurve::DN");
+    throw Standard_NotImplemented("ProjLib_CompProjectedCurve::DN");
   return gp_Vec2d();
 }
 
@@ -1445,7 +1445,7 @@ Standard_Real ProjLib_CompProjectedCurve::LastParameter() const
 
 Standard_Real ProjLib_CompProjectedCurve::MaxDistance(const Standard_Integer Index) const
 {
-  if(Index < 1 || Index > myNbCurves) Standard_NoSuchObject::Raise();
+  if(Index < 1 || Index > myNbCurves) throw Standard_NoSuchObject();
   return myMaxDistance->Value(Index);
 }
 
@@ -1497,7 +1497,7 @@ void ProjLib_CompProjectedCurve::BuildIntervals(const GeomAbs_Shape S) const
     SforS = GeomAbs_CN; 
     break;
   default: 
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
   Standard_Integer i, j, k;
   Standard_Integer NbIntCur = myCurve->NbIntervals(S);
index 1e0a64c..9fc50d3 100644 (file)
@@ -116,7 +116,7 @@ static gp_Pnt2d Function_Value(const Standard_Real U,
       break;
     }
   default:
-    Standard_NoSuchObject::Raise("ProjLib_ComputeApprox::Value");
+    throw Standard_NoSuchObject("ProjLib_ComputeApprox::Value");
   }
 
   if ( UCouture) {
@@ -1213,7 +1213,7 @@ ProjLib_ComputeApprox::ProjLib_ComputeApprox
         break;
       }
     default:
-      Standard_NoSuchObject::Raise("ProjLib_ComputeApprox::Value");
+      throw Standard_NoSuchObject("ProjLib_ComputeApprox::Value");
     }
     Standard_Boolean ToMirror = Standard_False;
     Standard_Real du = 0., dv = 0.;
index 4b410a5..6f4ae79 100644 (file)
@@ -284,7 +284,7 @@ static gp_Pnt2d Function_Value(const Standard_Real theU,
         break;
       }
     default:
-      Standard_NoSuchObject::Raise("ProjLib_ComputeApproxOnPolarSurface::Value");
+      throw Standard_NoSuchObject("ProjLib_ComputeApproxOnPolarSurface::Value");
     }
     return gp_Pnt2d(S, T);
   }
@@ -363,7 +363,7 @@ static gp_Pnt2d Function_Value(const Standard_Real theU,
   }
   else
   {
-    Standard_NoSuchObject::Raise("");
+    throw Standard_NoSuchObject("");
   }
 
   // Try to run simple search with initial point (U0, V0).
@@ -1031,7 +1031,7 @@ Handle(Adaptor2d_HCurve2d)
        break;
       }
     default:
-      Standard_NoSuchObject::Raise("ProjLib_ComputeApproxOnPolarSurface::BuildInitialCurve2d");
+      throw Standard_NoSuchObject("ProjLib_ComputeApproxOnPolarSurface::BuildInitialCurve2d");
     }
   }
   else {
index 1fc118b..68fc43e 100644 (file)
@@ -32,7 +32,7 @@ ProjLib_PrjFunc::ProjLib_PrjFunc(const Adaptor3d_CurvePtr & C,const Standard_Rea
   case 1: myt = FixVal; break;
   case 2: myU = FixVal; break;
   case 3: myV = FixVal; break;
-  default: Standard_ConstructionError::Raise();
+  default: throw Standard_ConstructionError();
   }
 }
 
index 7c32659..892fbf9 100644 (file)
@@ -28,7 +28,7 @@
 
 ProjLib_PrjResolve::ProjLib_PrjResolve(const Adaptor3d_Curve& C,const Adaptor3d_Surface& S,const Standard_Integer Fix) : myFix(Fix)
 {
-  if (myFix > 3 || myFix < 1) Standard_ConstructionError::Raise();
+  if (myFix > 3 || myFix < 1) throw Standard_ConstructionError();
   mySolution = gp_Pnt2d(0.,0.);
   myCurve    = (Adaptor3d_CurvePtr)&C;
   mySurface  = (Adaptor3d_SurfacePtr)&S; 
@@ -130,6 +130,6 @@ ProjLib_PrjResolve::ProjLib_PrjResolve(const Adaptor3d_Curve& C,const Adaptor3d_
 
  gp_Pnt2d ProjLib_PrjResolve::Solution() const
 {
-  if (!IsDone())  StdFail_NotDone::Raise(); 
+  if (!IsDone())  throw StdFail_NotDone();
   return mySolution;
 }
index d5fd04e..b8b9a03 100644 (file)
@@ -433,7 +433,7 @@ myType      (GeomAbs_OtherCurve),
 myIsApprox  (Standard_False)
 {
 //  if ( Abs(D * Pl.Direction()) < Precision::Confusion()) {
-//    Standard_ConstructionError::Raise
+//    throw Standard_ConstructionError
 //      ("ProjLib_ProjectOnPlane:  The Direction and the Plane are parallel");
 //  }
 }
@@ -974,12 +974,8 @@ ProjLib_ProjectOnPlane::Trim(const Standard_Real First,
     return myResult->Trim(First,Last,Tolerance) ;
   }
   else {
-    Standard_NotImplemented::Raise("");
+    throw Standard_NotImplemented("");
   }
-
-  // portage WNT
-  Handle(Adaptor3d_HCurve) dummy;
-  return dummy;
 }
 
   
@@ -1016,7 +1012,7 @@ Standard_Boolean ProjLib_ProjectOnPlane::IsPeriodic() const
 Standard_Real ProjLib_ProjectOnPlane::Period() const
 {
   if ( !IsPeriodic()) {
-    Standard_NoSuchObject::Raise("ProjLib_ProjectOnPlane::Period");
+    throw Standard_NoSuchObject("ProjLib_ProjectOnPlane::Period");
   }
                                
   if ( myIsApprox)
@@ -1198,7 +1194,7 @@ GeomAbs_CurveType ProjLib_ProjectOnPlane::GetType() const
 gp_Lin ProjLib_ProjectOnPlane::Line() const
 {
   if (myType != GeomAbs_Line)
-    Standard_NoSuchObject::Raise("ProjLib_ProjectOnPlane:Line");
+    throw Standard_NoSuchObject("ProjLib_ProjectOnPlane:Line");
 
   return myResult->Line();
 }
@@ -1212,7 +1208,7 @@ gp_Lin ProjLib_ProjectOnPlane::Line() const
 gp_Circ ProjLib_ProjectOnPlane::Circle() const
 {
   if (myType != GeomAbs_Circle)
-    Standard_NoSuchObject::Raise("ProjLib_ProjectOnPlane:Circle");
+    throw Standard_NoSuchObject("ProjLib_ProjectOnPlane:Circle");
 
   return myResult->Circle();
 }
@@ -1226,7 +1222,7 @@ gp_Circ ProjLib_ProjectOnPlane::Circle() const
 gp_Elips ProjLib_ProjectOnPlane::Ellipse() const
 {
   if (myType != GeomAbs_Ellipse)
-    Standard_NoSuchObject::Raise("ProjLib_ProjectOnPlane:Ellipse");
+    throw Standard_NoSuchObject("ProjLib_ProjectOnPlane:Ellipse");
 
   return myResult->Ellipse();
 }
@@ -1240,7 +1236,7 @@ gp_Elips ProjLib_ProjectOnPlane::Ellipse() const
 gp_Hypr ProjLib_ProjectOnPlane::Hyperbola() const
 {
   if (myType != GeomAbs_Hyperbola)
-    Standard_NoSuchObject::Raise("ProjLib_ProjectOnPlane:Hyperbola");
+    throw Standard_NoSuchObject("ProjLib_ProjectOnPlane:Hyperbola");
 
   return myResult->Hyperbola() ;
 }
@@ -1254,7 +1250,7 @@ gp_Hypr ProjLib_ProjectOnPlane::Hyperbola() const
 gp_Parab ProjLib_ProjectOnPlane::Parabola() const
 {
   if (myType != GeomAbs_Parabola)
-    Standard_NoSuchObject::Raise("ProjLib_ProjectOnPlane:Parabola");
+    throw Standard_NoSuchObject("ProjLib_ProjectOnPlane:Parabola");
   
   return myResult->Parabola() ;
 }
@@ -1268,7 +1264,7 @@ Standard_Integer ProjLib_ProjectOnPlane::Degree() const
 {
   if ((GetType() != GeomAbs_BSplineCurve) &&
       (GetType() != GeomAbs_BezierCurve))
-    Standard_NoSuchObject::Raise("ProjLib_ProjectOnPlane:Degree");
+    throw Standard_NoSuchObject("ProjLib_ProjectOnPlane:Degree");
 
   if ( myIsApprox)
     return myResult->Degree();
@@ -1285,7 +1281,7 @@ Standard_Boolean ProjLib_ProjectOnPlane::IsRational() const
 {
   if ((GetType() != GeomAbs_BSplineCurve) &&
       (GetType() != GeomAbs_BezierCurve))
-    Standard_NoSuchObject::Raise("ProjLib_ProjectOnPlane:IsRational");
+    throw Standard_NoSuchObject("ProjLib_ProjectOnPlane:IsRational");
   
   if ( myIsApprox) 
     return myResult->IsRational();
@@ -1302,7 +1298,7 @@ Standard_Integer ProjLib_ProjectOnPlane::NbPoles() const
 {
   if ((GetType() != GeomAbs_BSplineCurve) &&
       (GetType() != GeomAbs_BezierCurve))
-    Standard_NoSuchObject::Raise("ProjLib_ProjectOnPlane:NbPoles");
+    throw Standard_NoSuchObject("ProjLib_ProjectOnPlane:NbPoles");
   
   if ( myIsApprox)
     return myResult->NbPoles();
@@ -1318,7 +1314,7 @@ Standard_Integer ProjLib_ProjectOnPlane::NbPoles() const
 Standard_Integer ProjLib_ProjectOnPlane::NbKnots() const 
 {
   if ( GetType() != GeomAbs_BSplineCurve) 
-    Standard_NoSuchObject::Raise("ProjLib_ProjectOnPlane:NbKnots");
+    throw Standard_NoSuchObject("ProjLib_ProjectOnPlane:NbKnots");
   
   if ( myIsApprox) 
     return myResult->NbKnots();
@@ -1335,7 +1331,7 @@ Standard_Integer ProjLib_ProjectOnPlane::NbKnots() const
 Handle(Geom_BezierCurve)  ProjLib_ProjectOnPlane::Bezier() const
 {
   if (myType != GeomAbs_BezierCurve)
-    Standard_NoSuchObject::Raise("ProjLib_ProjectOnPlane:Bezier");
+    throw Standard_NoSuchObject("ProjLib_ProjectOnPlane:Bezier");
 
   return myResult->Bezier() ;
 }
@@ -1348,7 +1344,7 @@ Handle(Geom_BezierCurve)  ProjLib_ProjectOnPlane::Bezier() const
 Handle(Geom_BSplineCurve)  ProjLib_ProjectOnPlane::BSpline() const
 {
   if (myType != GeomAbs_BSplineCurve)
-    Standard_NoSuchObject::Raise("ProjLib_ProjectOnPlane:BSpline");
+    throw Standard_NoSuchObject("ProjLib_ProjectOnPlane:BSpline");
 
   return myResult->BSpline() ;
 }
index 8dd1817..9f30fd2 100644 (file)
@@ -250,7 +250,7 @@ static void Project(ProjLib_Projector& P, Handle(Adaptor3d_HCurve)& C)
     case GeomAbs_OtherCurve:    // try the approximation
       break;
     default:
-      Standard_NoSuchObject::Raise(" ");
+      throw Standard_NoSuchObject(" ");
   }
 }
 
@@ -786,8 +786,7 @@ Standard_Real ProjLib_ProjectedCurve::LastParameter() const
 
 GeomAbs_Shape ProjLib_ProjectedCurve::Continuity() const
 {
-  Standard_NotImplemented::Raise("");
-  return GeomAbs_C0;
+  throw Standard_NotImplemented("");
 }
 
 
@@ -798,8 +797,7 @@ GeomAbs_Shape ProjLib_ProjectedCurve::Continuity() const
 
 Standard_Integer ProjLib_ProjectedCurve::NbIntervals(const GeomAbs_Shape ) const 
 {
-  Standard_NotImplemented::Raise("");
-  return 0;
+  throw Standard_NotImplemented("");
 }
 
 
@@ -812,7 +810,7 @@ Standard_Integer ProjLib_ProjectedCurve::NbIntervals(const GeomAbs_Shape ) const
 void ProjLib_ProjectedCurve::Intervals(TColStd_Array1OfReal&  ,
                                       const GeomAbs_Shape ) const 
 {
-  Standard_NotImplemented::Raise("");
+  throw Standard_NotImplemented("");
 }
 
 
@@ -823,8 +821,7 @@ void ProjLib_ProjectedCurve::Intervals(TColStd_Array1OfReal&  ,
 
 Standard_Boolean ProjLib_ProjectedCurve::IsClosed() const
 {
-  Standard_NotImplemented::Raise("");
-  return Standard_True;
+  throw Standard_NotImplemented("");
 }
 
 
@@ -846,8 +843,7 @@ Standard_Boolean ProjLib_ProjectedCurve::IsPeriodic() const
 
 Standard_Real ProjLib_ProjectedCurve::Period() const
 {
-  Standard_NotImplemented::Raise("");
-  return 0.;
+  throw Standard_NotImplemented("");
 }
 
 
@@ -858,8 +854,7 @@ Standard_Real ProjLib_ProjectedCurve::Period() const
 
 gp_Pnt2d ProjLib_ProjectedCurve::Value(const Standard_Real ) const 
 {
-  Standard_NotImplemented::Raise("");
-  return gp_Pnt2d(0.,0.);
+  throw Standard_NotImplemented("");
 }
 
 
@@ -870,7 +865,7 @@ gp_Pnt2d ProjLib_ProjectedCurve::Value(const Standard_Real ) const
 
 void ProjLib_ProjectedCurve::D0(const Standard_Real , gp_Pnt2d& ) const
 {
-  Standard_NotImplemented::Raise("");
+  throw Standard_NotImplemented("");
 }
 
 
@@ -883,7 +878,7 @@ void ProjLib_ProjectedCurve::D1(const Standard_Real ,
                                      gp_Pnt2d&     , 
                                       gp_Vec2d&     ) const 
 {
-  Standard_NotImplemented::Raise("");
+  throw Standard_NotImplemented("");
 }
 
 
@@ -897,7 +892,7 @@ void ProjLib_ProjectedCurve::D2(const Standard_Real ,
                                       gp_Vec2d&     , 
                                       gp_Vec2d&     ) const 
 {
-  Standard_NotImplemented::Raise("");
+  throw Standard_NotImplemented("");
 }
 
 
@@ -912,7 +907,7 @@ void ProjLib_ProjectedCurve::D3(const Standard_Real,
                                      gp_Vec2d&, 
                                      gp_Vec2d&) const 
 {
-  Standard_NotImplemented::Raise("");
+  throw Standard_NotImplemented("");
 }
 
 
@@ -924,8 +919,7 @@ void ProjLib_ProjectedCurve::D3(const Standard_Real,
 gp_Vec2d ProjLib_ProjectedCurve::DN(const Standard_Real, 
                                    const Standard_Integer) const 
 {
-  Standard_NotImplemented::Raise("");
-  return gp_Vec2d(0.,0.);
+  throw Standard_NotImplemented("");
 }
 
 
@@ -936,8 +930,7 @@ gp_Vec2d ProjLib_ProjectedCurve::DN(const Standard_Real,
 
 Standard_Real ProjLib_ProjectedCurve::Resolution(const Standard_Real) const 
 {
-  Standard_NotImplemented::Raise("");
-  return 0.;
+  throw Standard_NotImplemented("");
 }
     
 
@@ -1117,7 +1110,6 @@ Handle(Adaptor2d_HCurve2d) ProjLib_ProjectedCurve::Trim
  const Standard_Real ,
  const Standard_Real ) const 
 {
-  Standard_NotImplemented::Raise("");
-  return NULL ;
+  throw Standard_NotImplemented("");
 }
 
index 48a8cad..9bd9afc 100644 (file)
@@ -128,7 +128,7 @@ void ProjLib_Projector::SetPeriodic()
 const gp_Lin2d&  ProjLib_Projector::Line()const 
 {
   if (myType != GeomAbs_Line)
-    Standard_NoSuchObject::Raise("ProjLib_Projector::Line");
+    throw Standard_NoSuchObject("ProjLib_Projector::Line");
   return myLin;
 }
 
@@ -141,7 +141,7 @@ const gp_Lin2d&  ProjLib_Projector::Line()const
 const gp_Circ2d&  ProjLib_Projector::Circle()const 
 {
   if (myType != GeomAbs_Circle)
-    Standard_NoSuchObject::Raise("ProjLib_Projector::Circle");
+    throw Standard_NoSuchObject("ProjLib_Projector::Circle");
   return myCirc;
 }
 
@@ -154,7 +154,7 @@ const gp_Circ2d&  ProjLib_Projector::Circle()const
 const gp_Elips2d&  ProjLib_Projector::Ellipse()const 
 {
   if (myType != GeomAbs_Ellipse)
-    Standard_NoSuchObject::Raise("ProjLib_Projector::Ellipse");
+    throw Standard_NoSuchObject("ProjLib_Projector::Ellipse");
   return myElips;
 }
 
@@ -167,7 +167,7 @@ const gp_Elips2d&  ProjLib_Projector::Ellipse()const
 const gp_Hypr2d&  ProjLib_Projector::Hyperbola()const 
 {
   if (myType != GeomAbs_Hyperbola)
-    Standard_NoSuchObject::Raise("ProjLib_Projector::Hyperbola");
+    throw Standard_NoSuchObject("ProjLib_Projector::Hyperbola");
   return myHypr;
 }
 
@@ -180,7 +180,7 @@ const gp_Hypr2d&  ProjLib_Projector::Hyperbola()const
 const gp_Parab2d&  ProjLib_Projector::Parabola()const 
 {
   if (myType != GeomAbs_Parabola)
-    Standard_NoSuchObject::Raise("ProjLib_Projector::Parabola");
+    throw Standard_NoSuchObject("ProjLib_Projector::Parabola");
   return myParab;
 }
 
index d419a6d..18a08dc 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Prs3d_InvalidAngle, Standard_RangeError)
 
 #if !defined No_Exception && !defined No_Prs3d_InvalidAngle
   #define Prs3d_InvalidAngle_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Prs3d_InvalidAngle::Raise(MESSAGE);
+  if (CONDITION) throw Prs3d_InvalidAngle(MESSAGE);
 #else
   #define Prs3d_InvalidAngle_Raise_if(CONDITION, MESSAGE)
 #endif
index 3886f0a..46e0bb9 100644 (file)
@@ -90,7 +90,7 @@ void PrsMgr_PresentableObject::Compute (const Handle(PrsMgr_PresentationManager)
                                         const Handle(Prs3d_Presentation)& /*aPresentation*/,
                                         const Standard_Integer /*aMode*/)
 {
-  Standard_NotImplemented::Raise("cannot compute in a 3d visualizer");
+  throw Standard_NotImplemented("cannot compute in a 3d visualizer");
 }
 
 //=======================================================================
@@ -100,7 +100,7 @@ void PrsMgr_PresentableObject::Compute (const Handle(PrsMgr_PresentationManager)
 void PrsMgr_PresentableObject::Compute(const Handle(Prs3d_Projector)& /*aProjector*/,
                                        const Handle(Prs3d_Presentation)& /*aPresentation*/)
 {
-  Standard_NotImplemented::Raise("cannot compute under a specific projector");
+  throw Standard_NotImplemented("cannot compute under a specific projector");
 }
 
 //=======================================================================
@@ -111,7 +111,7 @@ void PrsMgr_PresentableObject::Compute(const Handle(Prs3d_Projector)& /* aProjec
                                        const Handle(Geom_Transformation)& /*aTrsf*/,
                                                               const Handle(Prs3d_Presentation)& /*aPresentation*/)
 {
-  Standard_NotImplemented::Raise("cannot compute under a specific projector");
+  throw Standard_NotImplemented("cannot compute under a specific projector");
 }
 
 //=======================================================================
index f7a97ce..5896d3b 100644 (file)
@@ -1710,12 +1710,11 @@ static Standard_Integer OCC670 (Draw_Interpretor& di, Standard_Integer argc, con
 
   // check that exception initialized without message string can be safely handled and printed
   try {
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   }
-  catch (Standard_Failure) {
+  catch (Standard_Failure const& anException) {
     std::cout << "Caught successfully: ";
-    Standard_Failure::Caught()->Print (std::cout);
-    std::cout << endl;
+    std::cout << anException << endl;
   }
   return 0;
 }
@@ -2422,19 +2421,17 @@ static Standard_Integer OCC6143 (Draw_Interpretor& di, Standard_Integer argc, co
     {
       di << "Caught, OK\n";
     }
-    catch(Standard_Failure) {
+    catch(Standard_Failure const& anException) {
       di << " Caught (";
-      di << Standard_Failure::Caught()->GetMessageString();
+      di << anException.GetMessageString();
       di << ")... KO\n";
       Succes = Standard_False;
     }
-#ifndef NO_CXX_EXCEPTION
     // this case tests if (...) supersedes (Standard_*),
     // the normal behaviour is not
     catch(...) {
       di<<" unknown exception... (But) Ok\n";
     }
-#endif
   }
 
   {//==== Test Divide ByZero (Real) ===========================================
@@ -2457,10 +2454,10 @@ static Standard_Integer OCC6143 (Draw_Interpretor& di, Standard_Integer argc, co
     {
       di << "Caught, OK\n";
     }
-    catch(Standard_Failure) {
+    catch(Standard_Failure const& anException) {
       //cout << " Caught (" << Standard_Failure::Caught() << ")... KO" << endl;
       di << " Caught (";
-      di << Standard_Failure::Caught()->GetMessageString();
+      di << anException.GetMessageString();
       di << ")... KO\n";
       Succes = Standard_False;
     }
@@ -2482,10 +2479,10 @@ static Standard_Integer OCC6143 (Draw_Interpretor& di, Standard_Integer argc, co
     catch(Standard_Overflow) {
       di << "Caught, OK\n";
     }
-    catch(Standard_Failure) {
+    catch(Standard_Failure const& anException) {
       //cout << " Caught (" << Standard_Failure::Caught() << ")... KO" << endl;
       di << " Caught (";
-      di << Standard_Failure::Caught()->GetMessageString();
+      di << anException.GetMessageString();
       di << ")... KO\n";
       Succes = Standard_False;
     }
@@ -2514,10 +2511,10 @@ static Standard_Integer OCC6143 (Draw_Interpretor& di, Standard_Integer argc, co
     {
       di << "Caught, OK\n";
     }
-    catch(Standard_Failure) {
+    catch(Standard_Failure const& anException) {
       //cout << " Caught (" << Standard_Failure::Caught() << ")... KO" << endl;
       di << " Caught (";
-      di << Standard_Failure::Caught()->GetMessageString();
+      di << anException.GetMessageString();
       di << ")... KO\n";
       Succes = Standard_False;
     }
@@ -2547,10 +2544,10 @@ static Standard_Integer OCC6143 (Draw_Interpretor& di, Standard_Integer argc, co
       di << "Exception caught, KO\n";
       Succes = Standard_False;
     }
-    catch(Standard_Failure) {
+    catch(Standard_Failure const& anException) {
       //cout << " Caught (" << Standard_Failure::Caught() << ")... KO" << endl;
       di << " Caught (";
-      di << Standard_Failure::Caught()->GetMessageString();
+      di << anException.GetMessageString();
       di << ")... KO\n";
       Succes = Standard_False;
     }
@@ -2571,10 +2568,10 @@ static Standard_Integer OCC6143 (Draw_Interpretor& di, Standard_Integer argc, co
     catch(Standard_NumericError) {
       di << "Caught, OK\n";
     }
-    catch(Standard_Failure) {
+    catch(Standard_Failure const& anException) {
       //cout << " Caught (" << Standard_Failure::Caught() << ")... KO" << endl;
       di << " Caught (";
-      di << Standard_Failure::Caught()->GetMessageString();
+      di << anException.GetMessageString();
       di << ")... KO\n";
       Succes = Standard_False;
     }
@@ -2599,10 +2596,10 @@ static Standard_Integer OCC6143 (Draw_Interpretor& di, Standard_Integer argc, co
 #endif
     {
       di << "Caught, OK\n";
-    } catch(Standard_Failure) {
+    } catch(Standard_Failure const& anException) {
       //cout << " Caught (" << Standard_Failure::Caught() << ")... KO" << endl;
       di << " Caught (";
-      di << Standard_Failure::Caught()->GetMessageString();
+      di << anException.GetMessageString();
       di << ")... KO\n";
       Succes = Standard_False;
     }
@@ -2697,10 +2694,10 @@ static Standard_Integer OCC7141 (Draw_Interpretor& di, Standard_Integer argc, co
   catch(OSD_Exception_STACK_OVERFLOW) {
     di << "Failed : STACK OVERFLOW\n\n";
   }
-  catch (Standard_Failure) {
+  catch (Standard_Failure const& anException) {
     di << "Failed :\n\n";
     //cout << Standard_Failure::Caught() << endl;
-    di << Standard_Failure::Caught()->GetMessageString();
+    di << anException.GetMessageString();
   }
   di << argv[0] << " : Finish\n";
   
@@ -4938,9 +4935,8 @@ Standard_Integer CR23403 (Draw_Interpretor& di, Standard_Integer argc, const cha
     OCC_CATCH_SIGNALS
     myExpr->Process( aString );
   }
-  catch(Standard_Failure) {
-    Handle(Standard_Failure) aFail = Standard_Failure::Caught();
-    di << "Exception : " << aFail->GetMessageString() << "\n";
+  catch(Standard_Failure const& anException) {
+    di << "Exception : " << anException.GetMessageString() << "\n";
   }
 
   return 0;
index 0fc575a..5be3819 100644 (file)
@@ -2140,47 +2140,6 @@ static Standard_Integer OCC27875(Draw_Interpretor& theDI,
   return 0;
 }
 
-#include <OSD_Parallel.hxx>
-
-namespace {
-  struct ExceptionRaiser
-  {
-    void operator () (int i) const
-    {
-      try 
-      {
-        f (i);
-      }
-      catch (Standard_ProgramError)
-      {
-        strlen (Standard_Failure::Caught()->GetMessageString());
-      }
-    }
-
-    void f(int i) const;
-  };
-
-  void ExceptionRaiser::f (int i) const
-  {
-    const char str[] = "0123456789";
-    Standard_ProgramError::Raise (str + i % 10);
-  }
-};
-
-static Standard_Integer OCC28217(Draw_Interpretor& theDI,
-                                 Standard_Integer /*theNArg*/,
-                                 const char ** /*theArgVal*/)
-{
-  NCollection_Array1<int> aVec (1, 10000);
-  for (int i=1; i < aVec.Length(); i++) 
-    aVec(i) = i;
-
-  ExceptionRaiser aProc;
-  OSD_Parallel::For (1, aVec.Length(), aProc);
-
-  theDI << "OCC28217: OK";
-  return 0;
-}
 
 #include <TDF_Tool.hxx>
 #include <XCAFDoc_View.hxx>
@@ -2313,7 +2272,6 @@ void QABugs::Commands_20(Draw_Interpretor& theCommands) {
   theCommands.Add("OCC26270", "OCC26270 shape result", __FILE__, OCC26270, group);
   theCommands.Add ("OCC27552", "OCC27552", __FILE__, OCC27552, group); 
   theCommands.Add("OCC27875", "OCC27875 curve", __FILE__, OCC27875, group);
-  theCommands.Add("OCC28217", "OCC28217", __FILE__, OCC28217, group);
   theCommands.Add("OCC28389", "OCC28389", __FILE__, OCC28389, group);
 
   return;
index 9cbe790..ed4480d 100644 (file)
@@ -49,7 +49,7 @@ QANewBRepNaming_BooleanOperation::QANewBRepNaming_BooleanOperation(const TDF_Lab
 void QANewBRepNaming_BooleanOperation::Init(const TDF_Label& Label)
 {
   if(Label.IsNull())
-    Standard_NullObject::Raise("QANewBRepNaming_BooleanOperation::Init The Result label is Null ..."); 
+    throw Standard_NullObject("QANewBRepNaming_BooleanOperation::Init The Result label is Null ...");
   myResultLabel = Label;
 }
 
index 88569e3..35553b0 100644 (file)
@@ -95,7 +95,7 @@ QANewBRepNaming_BooleanOperationFeat::QANewBRepNaming_BooleanOperationFeat(const
 
 void QANewBRepNaming_BooleanOperationFeat::Init(const TDF_Label& ResultLabel) {  
   if(ResultLabel.IsNull()) 
-    Standard_NullObject::Raise("QANewBRepNaming_BooleanOperationFeat::Init The Result label is Null ..."); 
+    throw Standard_NullObject("QANewBRepNaming_BooleanOperationFeat::Init The Result label is Null ...");
   myResultLabel = ResultLabel; 
 }
 
index 3b9ed13..cf3676c 100644 (file)
@@ -44,7 +44,7 @@ QANewBRepNaming_Box::QANewBRepNaming_Box(const TDF_Label& Label)
 
 void QANewBRepNaming_Box::Init(const TDF_Label& Label) {
   if(Label.IsNull())
-    Standard_NullObject::Raise("QANewBRepNaming_Box::Init The Result label is Null ..."); 
+    throw Standard_NullObject("QANewBRepNaming_Box::Init The Result label is Null ...");
   myResultLabel = Label;
 }  
 
index 9279d47..206d3f3 100644 (file)
@@ -47,7 +47,7 @@ QANewBRepNaming_Chamfer::QANewBRepNaming_Chamfer(const TDF_Label& ResultLabel):
 void QANewBRepNaming_Chamfer::Init(const TDF_Label& ResultLabel)
 {
   if(ResultLabel.IsNull())
-    Standard_NullObject::Raise("QANewBRepNaming_Chamfer::Init The Result label is Null ..."); 
+    throw Standard_NullObject("QANewBRepNaming_Chamfer::Init The Result label is Null ...");
   myResultLabel = ResultLabel;
 }   
 
index ea0180a..bc7aa65 100644 (file)
@@ -47,7 +47,7 @@ QANewBRepNaming_Cylinder::QANewBRepNaming_Cylinder(const TDF_Label& ResultLabel)
 
 void QANewBRepNaming_Cylinder::Init(const TDF_Label& ResultLabel) {
   if(ResultLabel.IsNull())
-    Standard_NullObject::Raise("QANewBRepNaming_Cylinder::Init The Result label is Null ..."); 
+    throw Standard_NullObject("QANewBRepNaming_Cylinder::Init The Result label is Null ...");
   myResultLabel = ResultLabel;
 }    
 
index 091d8ec..2f81ffb 100644 (file)
@@ -57,7 +57,7 @@ QANewBRepNaming_Fillet::QANewBRepNaming_Fillet(const TDF_Label& theLabel):
 void QANewBRepNaming_Fillet::Init(const TDF_Label& theLabel)
 {
   if(theLabel.IsNull())
-    Standard_NullObject::Raise("QANewBRepNaming_Fillet::Init: The Result label is Null ...");
+    throw Standard_NullObject("QANewBRepNaming_Fillet::Init: The Result label is Null ...");
   myResultLabel = theLabel;
 }
 
index 05d2ebf..cbb9a2c 100644 (file)
@@ -74,7 +74,7 @@ QANewBRepNaming_Gluing::QANewBRepNaming_Gluing(const TDF_Label& ResultLabel):QAN
 
 void QANewBRepNaming_Gluing::Init(const TDF_Label& ResultLabel) {  
   if(ResultLabel.IsNull()) 
-    Standard_NullObject::Raise("QANewBRepNaming_Gluing::Init The Result label is Null ..."); 
+    throw Standard_NullObject("QANewBRepNaming_Gluing::Init The Result label is Null ...");
   myResultLabel = ResultLabel; 
 }
 
index ff286a6..7037f59 100644 (file)
@@ -62,7 +62,7 @@ QANewBRepNaming_ImportShape::QANewBRepNaming_ImportShape(const TDF_Label& L):QAN
 
 void QANewBRepNaming_ImportShape::Init(const TDF_Label& Label) {
   if(Label.IsNull()) 
-    Standard_NullObject::Raise("QANewBRepNaming_ImportShape::Init The Result label is Null ..."); 
+    throw Standard_NullObject("QANewBRepNaming_ImportShape::Init The Result label is Null ...");
   myResultLabel = Label;
 }  
 
index fd38dfa..294384c 100644 (file)
@@ -59,7 +59,7 @@ QANewBRepNaming_Prism::QANewBRepNaming_Prism(const TDF_Label& Label):QANewBRepNa
 
 void QANewBRepNaming_Prism::Init(const TDF_Label& Label) {
   if(Label.IsNull())
-    Standard_NullObject::Raise("QANewBRepNaming_Prism::Init The Result label is Null ..."); 
+    throw Standard_NullObject("QANewBRepNaming_Prism::Init The Result label is Null ...");
   myResultLabel = Label;
 }
 
index 299cd4d..855a4e8 100644 (file)
@@ -55,7 +55,7 @@ QANewBRepNaming_Revol::QANewBRepNaming_Revol(const TDF_Label& Label)
 void QANewBRepNaming_Revol::Init(const TDF_Label& Label)
 {
   if(Label.IsNull())
-    Standard_NullObject::Raise("QANewBRepNaming_Revol::Init The Result label is Null ..."); 
+    throw Standard_NullObject("QANewBRepNaming_Revol::Init The Result label is Null ...");
   myResultLabel = Label;
 }
 
index 47d7458..dea2ed1 100644 (file)
@@ -58,7 +58,7 @@ QANewBRepNaming_Sphere::QANewBRepNaming_Sphere(const TDF_Label& ResultLabel):QAN
 
 void QANewBRepNaming_Sphere::Init(const TDF_Label& ResultLabel) {
   if(ResultLabel.IsNull())
-    Standard_NullObject::Raise("QANewBRepNaming_Sphere::Init The Result label is Null ..."); 
+    throw Standard_NullObject("QANewBRepNaming_Sphere::Init The Result label is Null ...");
   myResultLabel = ResultLabel;
 }   
 
index 230e2ae..db99974 100644 (file)
@@ -34,7 +34,7 @@ QANewBRepNaming_TopNaming::QANewBRepNaming_TopNaming()
 QANewBRepNaming_TopNaming::QANewBRepNaming_TopNaming(const TDF_Label& Label)
 {
   if(Label.IsNull())
-    Standard_NullObject::Raise("QANewBRepNaming_TopNaming:: The Result label is Null ..."); 
+    throw Standard_NullObject("QANewBRepNaming_TopNaming:: The Result label is Null ...");
   myResultLabel = Label;
 }
 
index 8b5e24f..87023de 100644 (file)
@@ -133,7 +133,7 @@ void QANewModTopOpe_Limitation::Cut()
     
   }
   else {
-    Standard_ConstructionError::Raise("QANewModTopOpe_Limitation : wrong mode");
+    throw Standard_ConstructionError("QANewModTopOpe_Limitation : wrong mode");
   }
 
 
index 408c9a4..53334a4 100644 (file)
@@ -86,7 +86,7 @@ Quantity_Color::Quantity_Color (const Quantity_Parameter R1, const Quantity_Para
                        if ( R1 < 0. || R1 > 1. ||
                             R2 < 0. || R2 > 1. ||
                             R3 < 0. || R3 > 1. )
-                               Standard_OutOfRange::Raise ("Color out");
+                               throw Standard_OutOfRange("Color out");
                        MyRed   = Standard_ShortReal (R1);
                        MyGreen = Standard_ShortReal (R2);
                        MyBlue  = Standard_ShortReal (R3);
@@ -97,7 +97,7 @@ Quantity_Color::Quantity_Color (const Quantity_Parameter R1, const Quantity_Para
                          || (R1 > 360.) ||
                             R2 < 0. || R2 > 1. ||
                             R3 < 0. || R3 > 1. )
-                               Standard_OutOfRange::Raise ("Color out");
+                               throw Standard_OutOfRange("Color out");
                        Quantity_Color::hlsrgb
                                (Standard_ShortReal (R1),
                                 Standard_ShortReal (R2),
@@ -117,7 +117,7 @@ Quantity_Color::Quantity_Color (const NCollection_Vec3<float>& theRgb)
    || theRgb.g() < 0.0f || theRgb.g() > 1.0f
    || theRgb.b() < 0.0f || theRgb.b() > 1.0f)
   {
-    Standard_OutOfRange::Raise ("Color out");
+    throw Standard_OutOfRange("Color out");
   }
 }
 
@@ -167,7 +167,7 @@ void Quantity_Color::SetValues (const Quantity_Parameter R1, const Quantity_Para
                        if ( R1 < 0. || R1 > 1. ||
                             R2 < 0. || R2 > 1. ||
                             R3 < 0. || R3 > 1. )
-                               Standard_OutOfRange::Raise ("Color out");
+                               throw Standard_OutOfRange("Color out");
                        else {
                                MyRed   = Standard_ShortReal (R1);
                                MyGreen = Standard_ShortReal (R2);
@@ -179,7 +179,7 @@ void Quantity_Color::SetValues (const Quantity_Parameter R1, const Quantity_Para
                        if ( R1 < 0. || R1 > 360. ||
                             R2 < 0. || R2 > 1. ||
                             R3 < 0. || R3 > 1. )
-                               Standard_OutOfRange::Raise ("Color out");
+                               throw Standard_OutOfRange("Color out");
                        else {
                                Quantity_Color::hlsrgb
                                        (Standard_ShortReal (R1),
@@ -309,7 +309,7 @@ Quantity_NameOfColor Quantity_Color::Name (const Quantity_Parameter R, const Qua
        if ( R < 0. || R > 1. ||
             G < 0. || G > 1. ||
             B < 0. || B > 1. )
-               Standard_OutOfRange::Raise ("Color out");
+               throw Standard_OutOfRange("Color out");
 
 Quantity_Color AColor (R, G, B, Quantity_TOC_RGB);     // Couleur definie en RGB.
 
@@ -2031,7 +2031,7 @@ switch (AName) {
                RR = R1 = (float ) 0.603922; RG = R2 = (float ) 0.803922; RB = R3 = (float ) 0.196078;
        break;
        default :
-               Standard_OutOfRange::Raise ("Bad name");
+               throw Standard_OutOfRange("Bad name");
        break;
 }
        if (AType == Quantity_TOC_HLS)
@@ -3598,7 +3598,7 @@ switch (AName) {
        break;
        default :
                TheName = "UNDEFINED";
-               Standard_OutOfRange::Raise ("Bad name");
+               throw Standard_OutOfRange("Bad name");
        break;
 }
 return (TheName);
@@ -3618,9 +3618,8 @@ void TestOfColor ();
                TestOfColor ();
        }
 
-       catch (Standard_Failure) {
-               Handle(Standard_Failure) E = Standard_Failure::Caught();
-               cout << E << endl;
+       catch (Standard_Failure const& anException) {
+               cout << anException << endl;
        }
 
 }
index 2f7d0f0..fa530d1 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Quantity_ColorDefinitionError, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Quantity_ColorDefinitionError
   #define Quantity_ColorDefinitionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Quantity_ColorDefinitionError::Raise(MESSAGE);
+  if (CONDITION) throw Quantity_ColorDefinitionError(MESSAGE);
 #else
   #define Quantity_ColorDefinitionError_Raise_if(CONDITION, MESSAGE)
 #endif
index b11d4c3..ab1f5ad 100644 (file)
@@ -127,9 +127,7 @@ void Quantity_Date::SetValues(const Standard_Integer mm,
 Standard_Integer i;
 
 if ( ! Quantity_Date::IsValid (mm,dd,yy,hh,mn,ss,mis,mics))
-   Quantity_DateDefinitionError::Raise(
-             "Quantity_Date::Quantity_Date invalid parameters");
-
+   throw Quantity_DateDefinitionError("Quantity_Date::Quantity_Date invalid parameters");
 
 if ( Quantity_Date::IsLeap (yy) ) month_table[1] = 29;
 else month_table[1] = 28;
@@ -288,7 +286,7 @@ if ( result.mySec >= 0 && result.myUSec < 0 ) {
 
 
 if ( result.mySec <0   )
-   Quantity_DateDefinitionError::Raise(
+   throw Quantity_DateDefinitionError(
    "Quantity_Date::Subtract : The result date is anterior to Jan,1 1979");
 
 return (result); 
index 02a65ee..2eaf6d4 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Quantity_DateDefinitionError, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Quantity_DateDefinitionError
   #define Quantity_DateDefinitionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Quantity_DateDefinitionError::Raise(MESSAGE);
+  if (CONDITION) throw Quantity_DateDefinitionError(MESSAGE);
 #else
   #define Quantity_DateDefinitionError_Raise_if(CONDITION, MESSAGE)
 #endif
index 5259a3d..cb8b1b0 100644 (file)
@@ -142,8 +142,7 @@ void Quantity_Period::SetValues(
                          const Standard_Integer mics) {
 
 if ( ! Quantity_Period::IsValid(ss,mics) )
-   Quantity_PeriodDefinitionError::Raise(
-             "Quantity_Period::SetValues invalid parameters");
+   throw Quantity_PeriodDefinitionError("Quantity_Period::SetValues invalid parameters");
 
 mySec  = ss;
 myUSec = mics;
index f35d0b6..3e71e23 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Quantity_PeriodDefinitionError, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Quantity_PeriodDefinitionError
   #define Quantity_PeriodDefinitionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Quantity_PeriodDefinitionError::Raise(MESSAGE);
+  if (CONDITION) throw Quantity_PeriodDefinitionError(MESSAGE);
 #else
   #define Quantity_PeriodDefinitionError_Raise_if(CONDITION, MESSAGE)
 #endif
index d574f34..61773d1 100644 (file)
@@ -378,7 +378,7 @@ Handle(StlMesh_Mesh) RWStl::ReadBinary (const OSD_Path& thePath,
   Standard_Integer NBFACET = (Standard_Integer)((filesize - HEADER_SIZE) / SIZEOF_STL_FACET);
   if (NBFACET < 1)
   {
-    Standard_NoMoreObject::Raise("RWStl::ReadBinary (wrong file size)");
+    throw Standard_NoMoreObject("RWStl::ReadBinary (wrong file size)");
   }
 
   theFile.Seek (80, OSD_FromBeginning);
index 38089d6..be8f839 100644 (file)
@@ -352,7 +352,7 @@ Standard_Integer Resource_Manager::Integer(const Standard_CString aResourceName)
     TCollection_AsciiString n("Value of resource `");
     n+= aResourceName;
     n+= "` is not an integer";
-    Standard_TypeMismatch::Raise(n.ToCString());
+    throw Standard_TypeMismatch(n.ToCString());
   }
   return Result.IntegerValue();
 }
@@ -369,7 +369,7 @@ Standard_Real Resource_Manager::Real(const Standard_CString  aResourceName) cons
     TCollection_AsciiString n("Value of resource `");
     n+= aResourceName;
     n+= "` is not a real";
-    Standard_TypeMismatch::Raise(n.ToCString());
+    throw Standard_TypeMismatch(n.ToCString());
   }
   return Result.RealValue();
 }
@@ -386,8 +386,7 @@ Standard_CString Resource_Manager::Value(const Standard_CString aResource) const
     return myUserMap(Resource).ToCString();
   if (myRefMap.IsBound(Resource))
     return myRefMap(Resource).ToCString();
-  Resource_NoSuchResource::Raise(aResource);
-  return ("");
+  throw Resource_NoSuchResource(aResource);
 }
 
 //=======================================================================
index 4ff1d04..7cc872f 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Resource_NoSuchResource, Standard_NoSuchObject)
 
 #if !defined No_Exception && !defined No_Resource_NoSuchResource
   #define Resource_NoSuchResource_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Resource_NoSuchResource::Raise(MESSAGE);
+  if (CONDITION) throw Resource_NoSuchResource(MESSAGE);
 #else
   #define Resource_NoSuchResource_Raise_if(CONDITION, MESSAGE)
 #endif
index ab80ef7..07d9e20 100644 (file)
@@ -27,7 +27,7 @@ public:
   : mynbpoints(theNbPoints)
   {
     if (theNbPoints <= 0)
-      Standard_ConstructionError::Raise("Select3D_PointData");
+      throw Standard_ConstructionError("Select3D_PointData");
 
     mypolyg3d = new Select3D_Pnt[mynbpoints];
   }
@@ -44,7 +44,7 @@ public:
                const Select3D_Pnt& theValue)
   {
     if (theIndex < 0 || theIndex >= mynbpoints)
-      Standard_OutOfRange::Raise("Select3D_PointData::SetPnt");
+      throw Standard_OutOfRange("Select3D_PointData::SetPnt");
     mypolyg3d[theIndex] = theValue;
   }
 
@@ -54,7 +54,7 @@ public:
                const gp_Pnt& theValue)
   {
     if (theIndex < 0 || theIndex >= mynbpoints)
-      Standard_OutOfRange::Raise("Select3D_PointData::SetPnt");
+      throw Standard_OutOfRange("Select3D_PointData::SetPnt");
     mypolyg3d[theIndex] = theValue;
   }
 
@@ -63,7 +63,7 @@ public:
   Select3D_Pnt Pnt (const Standard_Integer theIndex) const
   {
     if (theIndex < 0 || theIndex >= mynbpoints)
-      Standard_OutOfRange::Raise("Select3D_PointData::Pnt");
+      throw Standard_OutOfRange("Select3D_PointData::Pnt");
     return mypolyg3d[theIndex];
   }
 
@@ -72,7 +72,7 @@ public:
   gp_Pnt Pnt3d (const Standard_Integer theIndex) const
   {
     if (theIndex < 0 || theIndex >= mynbpoints)
-      Standard_OutOfRange::Raise("Select3D_PointData::Pnt");
+      throw Standard_OutOfRange("Select3D_PointData::Pnt");
     return mypolyg3d[theIndex];
   }
 
index 43a9118..4173124 100644 (file)
@@ -296,7 +296,7 @@ void SelectMgr_SelectableObject::HilightSelected
   ( const Handle(PrsMgr_PresentationManager3d)&,
     const SelectMgr_SequenceOfOwner&)
 {
-  Standard_NotImplemented::Raise ("SelectMgr_SelectableObject::HilightSelected");
+  throw Standard_NotImplemented("SelectMgr_SelectableObject::HilightSelected");
 }
 
 //=======================================================================
@@ -326,7 +326,7 @@ void SelectMgr_SelectableObject::HilightOwnerWithColor (const Handle(PrsMgr_Pres
                                                         const Handle(Prs3d_Drawer)&,
                                                         const Handle(SelectMgr_EntityOwner)&)
 {
-  Standard_NotImplemented::Raise ("SelectMgr_SelectableObject::HilightOwnerWithColor");
+  throw Standard_NotImplemented("SelectMgr_SelectableObject::HilightOwnerWithColor");
 }
 
 //=======================================================================
index e87ccb9..6c5348c 100644 (file)
@@ -382,7 +382,7 @@ gp_Pnt SelectMgr_SelectingVolumeManager::DetectedPoint (const Standard_Real theD
 {
   if (myActiveSelectionType != Point)
   {
-    Standard_ProgramError::Raise ("SelectMgr_SelectingVolumeManager::DetectedPoint() should be called only for Point selection type");
+    throw Standard_ProgramError("SelectMgr_SelectingVolumeManager::DetectedPoint() should be called only for Point selection type");
   }
 
   return mySelectingVolumes[Frustum]->DetectedPoint (theDepth);
index 45fd4b3..3066144 100644 (file)
@@ -49,8 +49,7 @@ Standard_Boolean ShapeAnalysis_BoxBndTreeSelector::
   Accept (const Standard_Integer& theObj)
 {
   if (theObj < 1 || theObj > mySeq->Length())
-    Standard_NoSuchObject::Raise
-      ("ShapeAnalysis_BoxBndTreeSelector::Accept : no such object for current index");
+    throw Standard_NoSuchObject("ShapeAnalysis_BoxBndTreeSelector::Accept : no such object for current index");
   Standard_Boolean IsAccept = Standard_False;
   if (myList.Contains(theObj))
     return Standard_False;
index 21de5a9..82d372c 100644 (file)
@@ -256,12 +256,14 @@ Standard_Real ShapeAnalysis_Curve::ProjectAct(const Adaptor3d_Curve& C3D,
       }
     }
   }
-  catch(Standard_Failure) {
-    OK = Standard_False;
-#ifdef OCCT_DEBUG //:s5
+  catch(Standard_Failure const& anException) {
+#ifdef OCCT_DEBUG
+ //:s5
     cout << "\nWarning: ShapeAnalysis_Curve::ProjectAct(): Exception in Extrema_ExtPC: "; 
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
+    OK = Standard_False;
   }
   
   //szv#4:S4163:12Mar99 moved
index 22dc6a3..8b46dde 100644 (file)
@@ -474,12 +474,14 @@ static Handle(Geom_Curve) ComputeIso
     if (utype) iso = surf->UIso (par);
     else       iso = surf->VIso (par);
   }
-  catch(Standard_Failure) {
-    iso.Nullify();
-#ifdef OCCT_DEBUG //:s5
+  catch(Standard_Failure const& anException) {
+#ifdef OCCT_DEBUG
+//:s5
     cout << "\nWarning: ShapeAnalysis_Surface, ComputeIso(): Exception in UVIso(): "; 
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
+    iso.Nullify();
   }
   return iso;
 }
@@ -1155,22 +1157,24 @@ gp_Pnt2d ShapeAnalysis_Surface::ValueOfUV(const gp_Pnt& P3D,const Standard_Real
 
   }  // end Try ValueOfUV (CKY 30-DEC-1997)
 
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
+#ifdef OCCT_DEBUG
 //   Pas de raison mais qui sait. Mieux vaut retourner un truc faux que stopper
 //   L ideal serait d avoir un status ... mais qui va l interroger ?
 //   Avec ce status, on saurait que ce point est a sauter et voila tout
 //   En attendant, on met une valeur "pas idiote" mais surement fausse ...
-    //szv#4:S4163:12Mar99 optimized
-    S = (Precision::IsInfinite(uf))? 0 : (uf+ul) / 2.;
-    T = (Precision::IsInfinite(vf))? 0 : (vf+vl) / 2.;
-#ifdef OCCT_DEBUG //:s5
+//szv#4:S4163:12Mar99 optimized
+//:s5
     cout << "\nWarning: ShapeAnalysis_Surface::ValueOfUV(): Exception: "; 
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
+    S = (Precision::IsInfinite(uf))? 0 : (uf+ul) / 2.;
+    T = (Precision::IsInfinite(vf))? 0 : (vf+vl) / 2.;
   }
   } //:c9
   //szv#4:S4163:12Mar99 waste raise
-  //if (!computed) Standard_NoSuchObject::Raise("PCurveLib_ProjectPointOnSurf::ValueOfUV untreated surface type");
+  //if (!computed) throw Standard_NoSuchObject("PCurveLib_ProjectPointOnSurf::ValueOfUV untreated surface type");
   if (computed) { if (myGap <= 0) myGap = P3D.Distance (SurfAdapt.Value (S,T)); }
   else { myGap = -1.; S = 0.; T = 0.; }
   return gp_Pnt2d( S, T);
@@ -1359,12 +1363,14 @@ Standard_Real ShapeAnalysis_Surface::UVFromIso(const gp_Pnt& P3d,const Standard_
     U = UU;  V = VV;
 
   }  // fin try RAJOUT
-  catch(Standard_Failure) {
-    theMin = RealLast();    // theMin de depart
-#ifdef OCCT_DEBUG //:s5
+  catch(Standard_Failure const& anException) {
+#ifdef OCCT_DEBUG
+//:s5
     cout << "\nWarning: ShapeAnalysis_Curve::UVFromIso(): Exception: "; 
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
+    theMin = RealLast();    // theMin de depart
   }
   return theMin;
 }
index ef31ec1..184057f 100644 (file)
@@ -96,7 +96,7 @@ void ShapeAnalysis_WireOrder::Add(const gp_XYZ& start3d,const gp_XYZ& end3d)
 {
   //szv#4:S4163:12Mar99 waste raise
   //if (!myMode)
-    //Standard_TypeMismatch::Raise("ShapeAnalysis_WireOrder : AddXYZ");
+    //throw Standard_TypeMismatch("ShapeAnalysis_WireOrder : AddXYZ");
   if (myMode) {
     myXYZ->Append (start3d);  myXYZ->Append (end3d);
   }
@@ -111,7 +111,7 @@ void ShapeAnalysis_WireOrder::Add(const gp_XY& start2d,const gp_XY& end2d)
 {
   //szv#4:S4163:12Mar99 waste raise
   //if ( myMode)
-    //Standard_TypeMismatch::Raise("ShapeAnalysis_WireOrder : AddXY");
+    //throw Standard_TypeMismatch("ShapeAnalysis_WireOrder : AddXY");
   if (!myMode) {
     gp_XYZ val;
     val.SetCoord (start2d.X(),start2d.Y(),0.);
index 64aba8a..c17a4e4 100644 (file)
@@ -637,11 +637,12 @@ Standard_Boolean ShapeBuild_Edge::BuildCurve3d (const TopoDS_Edge& edge) const
         return Standard_True;
       }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout << "\nWarning: ShapeBuild_Edge: Exception in BuildCurve3d: "; 
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
   }
   return Standard_False;
 }
index 9e4f3a4..b8b6b1f 100644 (file)
@@ -88,11 +88,12 @@ Handle(Geom_BSplineCurve) ShapeConstruct::ConvertCurveToBSpline(const Handle(Geo
       else
        aBSpline = GeomConvert::CurveToBSplineCurve(C3D,Convert_QuasiAngular);
     }
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
            cout << "Warning: GeomConvert_ApproxSurface Exception:  ";
-           Standard_Failure::Caught()->Print(cout); cout << endl;
+           anException.Print(cout); cout << endl;
 #endif 
+           (void)anException;
            aBSpline = GeomConvert::CurveToBSplineCurve(C3D,Convert_QuasiAngular);    
          }
   }
@@ -256,11 +257,12 @@ Handle(Geom_BSplineSurface) ShapeConstruct::ConvertSurfaceToBSpline(const Handle
       }
     }
        
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
       cout << "Warning: GeomConvert_ApproxSurface Exception: try to decrease continuity ";
-      Standard_Failure::Caught()->Print(cout); cout << endl;
+      anException.Print(cout); cout << endl;
 #endif
+      (void)anException;
       if(cnt > 0) cnt--;
       continue;
     }
@@ -360,11 +362,12 @@ Standard_Boolean ShapeConstruct::JoinPCurves(const Handle(TopTools_HSequenceOfSh
     B.SameParameter(theEdge,Standard_False);
     return (i <= edges->Length());
   }
-  catch ( Standard_Failure ) {
+  catch ( Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout<<"Error: ShapeConstruct::JoinPCurves Exception in GeomConvert_CompCurveToBSplineCurve: ";
-    Standard_Failure::Caught()->Print(cout); cout<<endl;
+    anException.Print(cout); cout<<endl;
 #endif
+    (void)anException;
   }
   return Standard_False;
 }
index 42e2abd..13a199e 100644 (file)
@@ -153,11 +153,12 @@ Handle(Geom_BSplineCurve) ShapeConstruct_Curve::ConvertToBSpline (const Handle(G
       OCC_CATCH_SIGNALS
       bspl = GeomConvert::CurveToBSplineCurve(tc);
     }
-    catch ( Standard_Failure ) {
+    catch ( Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
       cout << "Warning: ShapeConstruct_Curve::ConvertToBSpline(): Exception in GeomConvert: ";
-      Standard_Failure::Caught()->Print(cout); cout << endl;
+      anException.Print(cout); cout << endl;
 #endif
+      (void)anException;
     }
   }
 
@@ -174,11 +175,12 @@ Handle(Geom_BSplineCurve) ShapeConstruct_Curve::ConvertToBSpline (const Handle(G
       bspl->Segment ( fbsp, lbsp );
       return bspl;
     }
-    catch ( Standard_Failure ) {
+    catch ( Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
       cout << "Warning: ShapeConstruct_Curve::ConvertToBSpline(): Exception in Segment: ";
-      Standard_Failure::Caught()->Print(cout); cout << endl;
+      anException.Print(cout); cout << endl;
 #endif
+      (void)anException;
     }
   }
 
@@ -192,11 +194,12 @@ Handle(Geom_BSplineCurve) ShapeConstruct_Curve::ConvertToBSpline (const Handle(G
     if ( Conv.IsDone() || Conv.HasResult() ) 
       bspl = Conv.Curve();
   }
-  catch ( Standard_Failure ) {
+  catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout << "Warning: ShapeConstruct_Curve::ConvertToBSpline(): Exception in Approx_Curve3d: ";
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
   }
   return bspl;
 }
@@ -223,11 +226,12 @@ Handle(Geom2d_BSplineCurve) ShapeConstruct_Curve::ConvertToBSpline (const Handle
       OCC_CATCH_SIGNALS
       bspl = Geom2dConvert::CurveToBSplineCurve(tc);
     }
-    catch ( Standard_Failure ) {
+    catch ( Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
       cout << "Warning: ShapeConstruct_Curve::ConvertToBSpline(): Exception in Geom2dConvert: ";
-      Standard_Failure::Caught()->Print(cout); cout << endl;
+      anException.Print(cout); cout << endl;
 #endif
+      (void)anException;
     }
   }
 
@@ -244,11 +248,12 @@ Handle(Geom2d_BSplineCurve) ShapeConstruct_Curve::ConvertToBSpline (const Handle
       bspl->Segment ( fbsp, lbsp );
       return bspl;
     }
-    catch ( Standard_Failure ) {
+    catch ( Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
       cout << "Warning: ShapeConstruct_Curve::ConvertToBSpline(): Exception in Segment: ";
-      Standard_Failure::Caught()->Print(cout); cout << endl;
+      anException.Print(cout); cout << endl;
 #endif
+      (void)anException;
     }
   }
 
@@ -263,11 +268,12 @@ Handle(Geom2d_BSplineCurve) ShapeConstruct_Curve::ConvertToBSpline (const Handle
     if ( Conv.IsDone() || Conv.HasResult() ) 
       bspl = Conv.Curve();
   }
-  catch ( Standard_Failure ) {
+  catch ( Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout << "Warning: ShapeConstruct_Curve::ConvertToBSpline(): Exception in Approx_Curve3d: ";
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
   }
   return bspl;
 }
index 1fc1cb1..332f4eb 100644 (file)
@@ -471,12 +471,12 @@ Standard_Boolean ShapeConstruct_ProjectCurveOnSurface::PerformByProjLib(Handle(G
     }
     
   }
-  catch(Standard_Failure)
-  {
+  catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout << "Warning: ShapeConstruct_ProjectCurveOnSurface::PerformByProjLib(): Exception: ";
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
     myStatus = ShapeExtend::EncodeStatus (ShapeExtend_FAIL3);
     c2d.Nullify();
   }
@@ -1480,13 +1480,14 @@ Handle(Geom2d_Curve) ShapeConstruct_ProjectCurveOnSurface::ApproximatePCurve(con
     C2d = new Geom2d_BSplineCurve  ( poles2d, weights, knots, multiplicities, crv3d->Degree(), crv3d->IsPeriodic());
     return C2d;
   }
-  catch(Standard_Failure) {
-#ifdef OCCT_DEBUG //:s5
+  catch(Standard_Failure const& anException) {
+#ifdef OCCT_DEBUG
+ //:s5
     //    debug ...
     Standard_Integer nbp = params->Length();
     Standard_Integer nb2 = points2d->Length();
     cout << "Warning: ShapeConstruct_ProjectCurveOnSurface::ApproximatePCurve(): Exception: ";
-    Standard_Failure::Caught()->Print(cout); 
+    anException.Print(cout); 
     cout<<"Pb Geom2dAPI_Approximate, tol2d="<<theTolerance2d<<" NbParams="<<nbp<<" NbPnts="<<nb2<<endl;
 //     if (nb2 > nbp) nb2 = nbp;
 //     Standard_Real rbp,rb2; rbp = nbp; rb2 = nb2;
@@ -1497,6 +1498,7 @@ Handle(Geom2d_Curve) ShapeConstruct_ProjectCurveOnSurface::ApproximatePCurve(con
 //       dbl.AddXYZ (quoi);
 //     }
 #endif
+     (void)anException;
      C2d.Nullify();
   }
   return C2d;
@@ -1524,13 +1526,14 @@ Handle(Geom2d_Curve) ShapeConstruct_ProjectCurveOnSurface::ApproximatePCurve(con
     myInterPol2d.Perform();
     if (myInterPol2d.IsDone()) C2d = myInterPol2d.Curve();
   }
-  catch(Standard_Failure) {
-#ifdef OCCT_DEBUG //:s5
+  catch(Standard_Failure const& anException) {
+#ifdef OCCT_DEBUG
+//:s5
 // //    debug ...
     Standard_Integer nbp = params->Length();
     Standard_Integer nb2 = points2d->Length();
     cout << "Warning: ShapeConstruct_ProjectCurveOnSurface::InterpolatePCurve(): Exception: ";
-    Standard_Failure::Caught()->Print(cout); 
+    anException.Print(cout); 
     cout<<"Pb Geom2dAPI_Interpolate, tol2d="<<theTolerance2d<<" NbParams="<<nbp<<" NbPnts="<<nb2<<endl;
 //     if (nb2 > nbp) nb2 = nbp;
 //     Standard_Real rbp,rb2; rbp = nbp; rb2 = nb2;
@@ -1541,6 +1544,7 @@ Handle(Geom2d_Curve) ShapeConstruct_ProjectCurveOnSurface::ApproximatePCurve(con
 //       dbl.AddXYZ (quoi);
 //     }
 #endif
+    (void)anException;
     C2d.Nullify();
   }
   return C2d;
@@ -1565,12 +1569,14 @@ Handle(Geom_Curve) ShapeConstruct_ProjectCurveOnSurface::InterpolateCurve3d(cons
     myInterPol.Perform();
     if (myInterPol.IsDone()) C3d = myInterPol.Curve();
   }
-  catch(Standard_Failure) {
-    C3d.Nullify();
-#ifdef OCCT_DEBUG //:s5
+  catch(Standard_Failure const& anException) {
+#ifdef OCCT_DEBUG
+ //:s5
     cout << "Warning: ShapeConstruct_ProjectCurveOnSurface::InterpolateCurve3d(): Exception: ";
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
+    C3d.Nullify();
   }
   return C3d;
 }
@@ -1965,18 +1971,17 @@ Handle(Geom_Curve) ShapeConstruct_ProjectCurveOnSurface::InterpolateCurve3d(cons
   }  */
   return isoParam;
   }  // RAJOUT
-  catch(Standard_Failure) {
-//  pb : on affiche ce qu on peut
+  catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
+//  pb : on affiche ce qu on peut
     for (Standard_Integer numpnt = 1; numpnt <= nbrPnt; numpnt ++) {
       cout<<"["<<numpnt<<"]param="<<params(numpnt)<<" point=("<<
        points(numpnt).X()<<"  "<<points(numpnt).Y()<<"  "<<points(numpnt).Z()<<")"<<endl;
     }
-#endif
-#ifdef OCCT_DEBUG //:s5
     cout << "Warning: ShapeConstruct_ProjectCurveOnSurface::IsAnIsoparametric(): Exception: ";
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
     return Standard_False;
   }
 }
index e2cb165..9a5e73b 100644 (file)
@@ -727,11 +727,12 @@ Standard_Boolean ShapeCustom_BSplineRestriction::ConvertSurface(const Handle(Geo
 
         }
 
-        catch (Standard_Failure) {
+        catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
           cout << "Warning: GeomConvert_ApproxSurface Exception: try to decrease continuity ";
-          Standard_Failure::Caught()->Print(cout); cout << endl;
+          anException.Print(cout); cout << endl;
 #endif
+          (void)anException;
           //szv: protection against loop
           if(aCU == 0 && aCV == 0) break;
           if(aCU > 0) aCU--;
@@ -1063,11 +1064,12 @@ Standard_Boolean ShapeCustom_BSplineRestriction::ConvertCurve(const Handle(Geom_
               return Standard_True;
             }
         }
-        catch (Standard_Failure) {
+        catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
           cout << "Warning: GeomConvert_ApproxCurve Exception: Wrong Coefficient : Decrease continuity    ";
-          Standard_Failure::Caught()->Print(cout); cout << endl;
+          anException.Print(cout); cout << endl;
 #endif
+          (void)anException;
           continue;
         } 
       }
@@ -1371,11 +1373,12 @@ Standard_Boolean ShapeCustom_BSplineRestriction::ConvertCurve2d(const Handle(Geo
             return Standard_True;
           }
         }
-        catch (Standard_Failure) {
+        catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
           cout << "Warning: Geom2dConvert_ApproxCurve Exception: Wrong Cofficient :Decrease Continuity    ";
-          Standard_Failure::Caught()->Print(cout); cout << endl;
+          anException.Print(cout); cout << endl;
 #endif
+          (void)anException;
           continue;
         }
       }
index 60cafd6..cd7fd80 100644 (file)
@@ -42,7 +42,7 @@ void ShapeExtend::Init()
     }
     if (!Message_MsgFile::HasMsg ("ShapeFix.FixSmallSolid.MSG0"))
     {
-      Standard_ProgramError::Raise ("Critical Error - message resources for ShapeExtend are invalid or undefined!");
+      throw Standard_ProgramError("Critical Error - message resources for ShapeExtend are invalid or undefined!");
     }
   }
 }
index d1222ab..830865f 100644 (file)
@@ -547,12 +547,14 @@ Standard_Boolean ShapeFix_Edge::FixAddPCurve (const TopoDS_Edge& edge,
       B.Range(edge, G3dCFirst, G3dCLast, Standard_True);
     }
   }   // end try
-  catch(Standard_Failure) {
-    myStatus |= ShapeExtend::EncodeStatus (ShapeExtend_FAIL2);
-#ifdef OCCT_DEBUG //:s5
+  catch(Standard_Failure const& anException) {
+#ifdef OCCT_DEBUG
+//:s5
     cout << "Warning: ShapeFix_Edge::FixAddPCurve(): Exception: ";
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
+    myStatus |= ShapeExtend::EncodeStatus (ShapeExtend_FAIL2);
   }
   myStatus |= ShapeExtend::EncodeStatus (ShapeExtend_DONE1);
   return Standard_True;
@@ -775,12 +777,12 @@ Standard_Boolean ShapeFix_Edge::FixSameParameter(const TopoDS_Edge& edge,
         if ( ! SP ) myStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_FAIL2 );
       }
     }
-    catch(Standard_Failure)
-    {
+    catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
       cout << "\nWarning: ShapeFix_Edge: Exception in SameParameter: "; 
-      Standard_Failure::Caught()->Print(cout); cout << endl;
+      anException.Print(cout); cout << endl;
 #endif
+      (void)anException;
       myStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_FAIL2 );
     }
   }
index e19cd9b..8488355 100644 (file)
@@ -209,11 +209,13 @@ static Standard_Boolean FindParameterWithExt (const gp_Pnt& Pt1,
     }
     else return Standard_False;
   }  // end try
-  catch(Standard_Failure) {
-#ifdef OCCT_DEBUG //:s5
+  catch(Standard_Failure const& anException) {
+#ifdef OCCT_DEBUG
+//:s5
     cout << "Warning: ShapeFix_EdgeProjAux, FindParameterWithExt(): Exception: ";
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
     return Standard_False;
   }
 }
index dbeacee..eb901c5 100644 (file)
@@ -219,11 +219,12 @@ static void CollectSolids(const TopTools_SequenceOfShape& aSeqShells ,
         }
       }
     }
-    catch(Standard_Failure) {
+    catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
       cout << "Warning: ShapeFix_Solid::SolidFromShell: Exception: ";
-      Standard_Failure::Caught()->Print(cout); cout << endl;
+      anException.Print(cout); cout << endl;
 #endif
+      (void)anException;
       continue;
     }
   }
@@ -296,11 +297,12 @@ static Standard_Boolean CreateSolids(const TopoDS_Shape theShape,TopTools_Indexe
       bsc3d.PerformInfinitePoint(Precision::Confusion());
       infinstatus = bsc3d.State();
       }
-    catch(Standard_Failure) {
+    catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
       cout << "Warning: ShapeFix_Solid::SolidFromShell: Exception: ";
-      Standard_Failure::Caught()->Print(cout); cout << endl;
+      anException.Print(cout); cout << endl;
 #endif
+      (void)anException;
       ShellSolid.Add(aShell,aSolid);
       continue;
     } 
@@ -572,11 +574,12 @@ TopoDS_Solid ShapeFix_Solid::SolidFromShell (const TopoDS_Shell& shell)
       myStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_DONE2 );
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout << "Warning: ShapeFix_Solid::SolidFromShell: Exception: ";
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
     return solid;
   }
   return solid;
index a6dfcd7..5c00a23 100644 (file)
@@ -365,12 +365,12 @@ static Standard_Real AdjustOnPeriodic3d (const Handle(Geom_Curve)& c,
          else tc = new Geom_TrimmedCurve(c,first,last);
          bsp = GeomConvert::CurveToBSplineCurve(tc);
        }
-       catch (Standard_Failure) 
-        {
+       catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
          cout << "Warning: ShapeFix_Wire_1::FixGap3d: Exception in TrimmedCurve" <<first<<" " <<last<<endl;
-         Standard_Failure::Caught()->Print(cout); cout << endl; 
+         anException.Print(cout); cout << endl; 
 #endif  
+         (void)anException;
        }
       }
 
@@ -640,12 +640,12 @@ static Standard_Real AdjustOnPeriodic3d (const Handle(Geom_Curve)& c,
          }
        }
       }
-      catch (Standard_Failure) 
-      {
+      catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
        cout << "Warning: ShapeFix_Wire_1::FixGap3d: Exception in TrimmedCurve      :"<<endl;
-       Standard_Failure::Caught()->Print(cout); cout << endl;
+       anException.Print(cout); cout << endl;
 #endif
+       (void)anException;
       }  
     }
   }
@@ -948,12 +948,12 @@ static Standard_Real AdjustOnPeriodic2d (const Handle(Geom2d_Curve)& pc,
            c = new Geom2d_TrimmedCurve(pc,first,last);
          bsp = Geom2dConvert::CurveToBSplineCurve(c);
        }
-       catch (Standard_Failure) 
-        {
+       catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
          cout << "Warning: ShapeFix_Wire_1::FixGap2d: Exception in TrimmedCurve2d" <<first<<" " <<last<<endl;
-         Standard_Failure::Caught()->Print(cout); cout << endl; 
+         anException.Print(cout); cout << endl; 
 #endif  
+         (void)anException;
        }
       }
       
@@ -1527,13 +1527,12 @@ static Standard_Real AdjustOnPeriodic2d (const Handle(Geom2d_Curve)& pc,
          }
        }
       }
-      catch (Standard_Failure) 
-      {
-       
+      catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
        cout << "Warning: ShapeFix_Wire_1::FixGap2d: Exception in TrimmedCurve2d  :"<<endl;
-       Standard_Failure::Caught()->Print(cout); cout << endl;
+       anException.Print(cout); cout << endl;
 #endif 
+       (void)anException;
       }  
     }
   }
index d699ec3..9d979c5 100644 (file)
@@ -390,12 +390,12 @@ ShapeFix_Wireframe::ShapeFix_Wireframe(const TopoDS_Shape& shape)
     E3 = newedge;
     return ReplaceFirst;
   }
-  catch ( Standard_Failure ) 
-  {
+  catch ( Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout<<"Error: ShapeFix_Wireframe::FixSmallEdges: JoinEdges: Exception in GeomConvert_CompCurveToBSplineCurve: ";
-    Standard_Failure::Caught()->Print(cout); cout<<endl;
+    anException.Print(cout); cout<<endl;
 #endif
+    (void)anException;
     return ReplaceFirst;
   }
 }
index 968aaa3..6e88066 100644 (file)
@@ -131,9 +131,9 @@ Standard_Boolean ShapeProcess::Perform (const Handle(ShapeProcess_Context)& cont
       if ( op->Perform(context) )
         isDone = Standard_True;
     }
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
       Message_Msg SMSG2 ("SP.Sequence.Error.Except"); //Operator %s failed with exception %s
-      SMSG2 << oper << Standard_Failure::Caught()->GetMessageString();
+      SMSG2 << oper << anException.GetMessageString();
       context->Messenger()->Send (SMSG2, Message_Alarm);
     }
     context->UnSetScope();
index c14b453..ed740b5 100644 (file)
@@ -311,11 +311,12 @@ Standard_Boolean ShapeProcess_Context::GetBoolean (const Standard_CString param,
     val = myRC->Integer (MakeName (myScope, param)->ToCString()) != 0;
     return Standard_True;
   }
-  catch (Standard_Failure) {
+  catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout << "Warning: ShapeProcess_Context::GetInteger(): " << param << ": ";
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
   }
   return Standard_False;
 }
@@ -369,11 +370,12 @@ Standard_CString ShapeProcess_Context::StringVal (const Standard_CString param,
     OCC_CATCH_SIGNALS
     return myRC->Value ( MakeName ( myScope, param )->ToCString() );
   }
-  catch (Standard_Failure) {
+  catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     cout << "Warning: ShapeProcess_Context::GetInteger(): " << param << ": ";
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
   }
   return def;
 }
index 1ee2355..0f0bb44 100644 (file)
@@ -80,11 +80,12 @@ Standard_Boolean ShapeUpgrade_FixSmallBezierCurves::Approx(Handle(Geom_Curve)& C
        }
       }
     }
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
       cout << "Warning: ShapeUpgrade_FixSmallBezierCurve::Approx(): Exception in Segment      :";
-      Standard_Failure::Caught()->Print(cout); cout << endl;
+      anException.Print(cout); cout << endl;
 #endif
+      (void)anException;
       return Standard_False;
     }
   }
@@ -116,11 +117,12 @@ Standard_Boolean ShapeUpgrade_FixSmallBezierCurves::Approx(Handle(Geom_Curve)& C
        Curve2d = theSegments2d->Value(1);
       }
     }
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
       cout << "Warning: ShapeUpgrade_FixSmallBezierCurve::Approx(): Exception in Segment      :";
-      Standard_Failure::Caught()->Print(cout); cout << endl;
+      anException.Print(cout); cout << endl;
 #endif
+      (void)anException;
       return Standard_False;
     }
   }
@@ -153,11 +155,12 @@ Standard_Boolean ShapeUpgrade_FixSmallBezierCurves::Approx(Handle(Geom_Curve)& C
          Curve2dR = theSegments2d->Value(1);
        }
       }
-      catch (Standard_Failure) {
+      catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
          cout << "Warning: ShapeUpgrade_FixSmallBezierCurve::Approx(): Exception in Segment      :";
-         Standard_Failure::Caught()->Print(cout); cout << endl;
+         anException.Print(cout); cout << endl;
 #endif
+         (void)anException;
          return Standard_False;
        }
     }
index 31e5e2a..659a4aa 100644 (file)
@@ -220,12 +220,13 @@ Standard_Boolean ShapeUpgrade_ShapeDivide::Perform(const Standard_Boolean newCon
            }
          }
        }
-       catch (Standard_Failure) {
-         myStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_FAIL2 );
+       catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
          cout << "\nError: Exception in ShapeUpgrade_FaceDivide::Perform(): ";
-         Standard_Failure::Caught()->Print(cout); cout << endl;
+         anException.Print(cout); cout << endl;
 #endif
+         (void)anException;
+         myStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_FAIL2 );
        }
       }
     }
index 07d5e78..c533c51 100644 (file)
@@ -174,11 +174,12 @@ ShapeUpgrade_SplitCurve2d::ShapeUpgrade_SplitCurve2d()
          else if (myCurve->IsKind (STANDARD_TYPE (Geom2d_BezierCurve)))
            Handle(Geom2d_BezierCurve)::DownCast(theNewCurve)->Segment (First, Last);
        }
-       catch (Standard_Failure) {
+       catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
          cout << "Warning: ShapeUpgrade_Split2dCurve::Build(): Exception in Segment      :";
-         Standard_Failure::Caught()->Print(cout); cout << endl;
+         anException.Print(cout); cout << endl;
 #endif
+         (void)anException;
          theNewCurve = new Geom2d_TrimmedCurve(Handle(Geom2d_Curve)::DownCast(myCurve->Copy()),First,Last);
        }
        myResultingCurves->SetValue (1, theNewCurve);
@@ -227,11 +228,12 @@ ShapeUpgrade_SplitCurve2d::ShapeUpgrade_SplitCurve2d()
            Handle(Geom2d_BezierCurve)::DownCast(theNewCurve)->Segment (Firstt, Lastt);
          myStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_DONE3 );
        }
-       catch (Standard_Failure) {
+       catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
          cout << "Warning: ShapeUpgrade_Split2dCurve::Build(): Exception in Segment      :";
-         Standard_Failure::Caught()->Print(cout); cout << endl;
+         anException.Print(cout); cout << endl;
 #endif
+         (void)anException;
          theNewCurve = new Geom2d_TrimmedCurve(Handle(Geom2d_Curve)::DownCast(myCurve->Copy()),Firstt,Lastt);
        }
       }
index 5a63916..f3cf452 100644 (file)
@@ -250,11 +250,12 @@ ShapeUpgrade_SplitCurve3d::ShapeUpgrade_SplitCurve3d()
            Handle(Geom_BezierCurve)::DownCast(theNewCurve)->Segment (Firstt, Lastt);
          myStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_DONE3 );
        }
-       catch (Standard_Failure) {
+       catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
          cout << "Warning: ShapeUpgrade_Split3dCurve::Build(): Exception in Segment      :";
-         Standard_Failure::Caught()->Print(cout); cout << endl;
+         anException.Print(cout); cout << endl;
 #endif
+         (void)anException;
          theNewCurve = new Geom_TrimmedCurve(Handle(Geom_Curve)::DownCast(myCurve->Copy()),Firstt,Lastt);  
        }
       }
index 9f1586f..a4c72ba 100644 (file)
@@ -437,11 +437,12 @@ void ShapeUpgrade_SplitSurface::Build(const Standard_Boolean Segment)
          }
          myStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_DONE3 );
        }
-       catch (Standard_Failure) {
+       catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
          cout << "Warning: ShapeUpgrade_SplitSurface::Build(): Exception in Segment      :";
-         Standard_Failure::Caught()->Print(cout); cout << endl;
+         anException.Print(cout); cout << endl;
 #endif
+         (void)anException;
          Handle(Geom_Surface) theNewSurf = theNew;
          theNew = new Geom_RectangularTrimmedSurface(theNewSurf,U1,U2,V1,V2);
        }
index 32339da..ea405b3 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_AbortiveTransaction, Standard_Failure)
 
 #if !defined No_Exception && !defined No_Standard_AbortiveTransaction
   #define Standard_AbortiveTransaction_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_AbortiveTransaction::Raise(MESSAGE);
+  if (CONDITION) throw Standard_AbortiveTransaction(MESSAGE);
 #else
   #define Standard_AbortiveTransaction_Raise_if(CONDITION, MESSAGE)
 #endif
index aa4df3c..283570e 100644 (file)
@@ -146,7 +146,7 @@ inline void Standard_ASSERT_DO_NOTHING() {}
 
 //! Raise exception (Standard_ProgramError) with the provided message
 #define Standard_ASSERT_RAISE(theExpr, theDesc)                                  \
-  Standard_ASSERT(theExpr, theDesc, Standard_ProgramError::Raise(                \
+  Standard_ASSERT(theExpr, theDesc, throw Standard_ProgramError(                \
       "*** ERROR: ASSERT in file '" __FILE__ "': \n" theDesc " (" #theExpr ")" ) )
 
 //! Return from the current function with specified value (empty
index cdb52ec..581efb5 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_ConstructionError, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Standard_ConstructionError
   #define Standard_ConstructionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_ConstructionError::Raise(MESSAGE);
+  if (CONDITION) throw Standard_ConstructionError(MESSAGE);
 #else
   #define Standard_ConstructionError_Raise_if(CONDITION, MESSAGE)
 #endif
index af3fb60..89f4559 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_DimensionError, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Standard_DimensionError
   #define Standard_DimensionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_DimensionError::Raise(MESSAGE);
+  if (CONDITION) throw Standard_DimensionError(MESSAGE);
 #else
   #define Standard_DimensionError_Raise_if(CONDITION, MESSAGE)
 #endif
index 4a6f3f1..da4a816 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_DimensionMismatch, Standard_DimensionError)
 
 #if !defined No_Exception && !defined No_Standard_DimensionMismatch
   #define Standard_DimensionMismatch_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_DimensionMismatch::Raise(MESSAGE);
+  if (CONDITION) throw Standard_DimensionMismatch(MESSAGE);
 #else
   #define Standard_DimensionMismatch_Raise_if(CONDITION, MESSAGE)
 #endif
index 4786335..4103f21 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_DivideByZero, Standard_NumericError)
 
 #if !defined No_Exception && !defined No_Standard_DivideByZero
   #define Standard_DivideByZero_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_DivideByZero::Raise(MESSAGE);
+  if (CONDITION) throw Standard_DivideByZero(MESSAGE);
 #else
   #define Standard_DivideByZero_Raise_if(CONDITION, MESSAGE)
 #endif
index 35c86f4..0bd6765 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_DomainError, Standard_Failure)
 
 #if !defined No_Exception && !defined No_Standard_DomainError
   #define Standard_DomainError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_DomainError::Raise(MESSAGE);
+  if (CONDITION) throw Standard_DomainError(MESSAGE);
 #else
   #define Standard_DomainError_Raise_if(CONDITION, MESSAGE)
 #endif
index 04cbc1b..c95b516 100644 (file)
@@ -267,7 +267,7 @@ Standard_ErrorHandler* Standard_ErrorHandler::FindHandler(const Standard_Handler
   return anActive;
 }
 
-#if defined(NO_CXX_EXCEPTION) || defined(OCC_CONVERT_SIGNALS)
+#if defined(OCC_CONVERT_SIGNALS)
 
 Standard_ErrorHandler::Callback::Callback ()
   : myHandler(0), myPrev(0), myNext(0)
index 333d68c..5071021 100644 (file)
 //!
 //! The implementation is based on C long jumps.
 //!
-//! If macro NO_CXX_EXCEPTION is defined, "try" and "catch" are defined as
-//! macros that use jumps to implement exception handling. 
-//! See Standard_Failure::Reraise() for exception throwing code.
-//! Note that this option is obsolete and useless for modern platforms.
-//! 
 //! If macro OCC_CONVERT_SIGNALS is defined, this enables macro OCC_CATCH_SIGNALS
 //! that can be used in the code (often inside try {} blocks) to convert C-style 
 //! signals to standard C++ exceptions. This works only when OSD::SetSignal()
 //! signal handler, this OCC_CONVERT_SIGNALS is not needed. Note however that
 //! this requires that compiler option /EHa is used.
 
-#ifdef NO_CXX_EXCEPTION
-
-  // No CXX Exceeptions, only jumps in all the cases.
-  //
-  // Note: In the current version setjmp is used. The alternative solution is to
-  // use sigsetjmp that stores the signal mask (to be checked)
-  // In the original implementation sigsetjmp is tried to use for SUN and IRIX
-  // in the following way:
-  //    #ifdef SOLARIS
-  //      #define DoesNotAbort(aHandler) !sigsetjmp(aHandler.Label(),1)
-  //    #endif
-
-  #define try               Standard_ErrorHandler _Function; \
-                            if(!setjmp(_Function.Label()))
-  #define catch(Error)        else if(_Function.Catches(STANDARD_TYPE(Error)))
-  #define OCC_CATCH_SIGNALS 
-
-  // Suppress GCC warning "variable ...  might be clobbered by 'longjmp' or 'vfork'"
-  #if defined(__GNUC__) && ! defined(__INTEL_COMPILER) && ! defined(__clang__)
-  #pragma GCC diagnostic ignored "-Wclobbered"
-  #endif
-
-#elif defined(OCC_CONVERT_SIGNALS)
+#if defined(OCC_CONVERT_SIGNALS)
 
   // Exceptions are raied as usual, signal cause jumps in the nearest 
   // OCC_CATCH_SIGNALS and then thrown as exceptions.
@@ -164,7 +137,7 @@ public:
   //! so as to be correctly destroyed when error handler is activated.
   //!
   //! Note that this is needed only when Open CASCADE is compiled with
-  //! NO_CXX_EXCEPTION or OCC_CONVERT_SIGNALS options (i.e. on UNIX/Linux).
+  //! OCC_CONVERT_SIGNALS options (i.e. on UNIX/Linux).
   //! In that case, raising OCC exception and/or signal will not cause
   //! C++ stack unwinding and destruction of objects created in the stack.
   //!
@@ -220,9 +193,9 @@ private:
   friend class Standard_Failure;
 };
 
-// If neither NO_CXX_EXCEPTION nor OCC_CONVERT_SIGNALS is defined,
+// If OCC_CONVERT_SIGNALS is not defined,
 // provide empty inline implementation
-#if ! defined(NO_CXX_EXCEPTION) && ! defined(OCC_CONVERT_SIGNALS)
+#if ! defined(OCC_CONVERT_SIGNALS)
 inline Standard_ErrorHandler::Callback::Callback ()
        : myHandler(0), myPrev(0), myNext(0)
 {
index 2f13deb..83e52e9 100644 (file)
@@ -72,9 +72,8 @@ static void deallocate_message(Standard_CString aMessage)
 // ******************************************************************
 //                           Standard_Failure                       *
 // ******************************************************************
-#ifndef NO_CXX_EXCEPTION
 static Standard_THREADLOCAL Handle(Standard_Failure) RaisedError;
-#endif
+
 // ------------------------------------------------------------------
 //
 // ------------------------------------------------------------------
@@ -115,11 +114,7 @@ void Standard_Failure::SetMessageString(const Standard_CString AString)
 // ------------------------------------------------------------------
 Handle(Standard_Failure) Standard_Failure::Caught() 
 {
-#ifdef NO_CXX_EXCEPTION
-  return Standard_ErrorHandler::LastCaughtError();
-#else
   return RaisedError ;
-#endif
 }
 
 // ------------------------------------------------------------------
@@ -157,18 +152,13 @@ void Standard_Failure::Reraise (const Standard_SStream& AReason)
 
 void Standard_Failure::Reraise () 
 {
-#ifdef NO_CXX_EXCEPTION
-  Standard_ErrorHandler::Error (this);
-  Standard_ErrorHandler::Abort (this);
-#else
   RaisedError = this;
   Throw();
-#endif
 }
 
 void Standard_Failure::Jump()
 {
-#if defined (NO_CXX_EXCEPTION) || defined (OCC_CONVERT_SIGNALS)
+#if defined (OCC_CONVERT_SIGNALS)
   Standard_ErrorHandler::Error (this);
   Standard_ErrorHandler::Abort (this);
 #else
@@ -183,9 +173,7 @@ void Standard_Failure::Jump()
 // ------------------------------------------------------------------
 void Standard_Failure::Throw() const
 {
-#ifndef NO_CXX_EXCEPTION
   throw *this;
-#endif
 }
 
 // ------------------------------------------------------------------
index e3a9bb4..13f62d2 100644 (file)
@@ -103,6 +103,7 @@ public:
   //! Returns the last caught exception.
   //! Needed when exceptions are emulated by C longjumps,
   //! in other cases is also provided for compatibility.
+  Standard_DEPRECATED("This method is deprecated (not thread-safe), use standard C++ mechanism instead")
   Standard_EXPORT static Handle(Standard_Failure) Caught();
 
 
@@ -135,4 +136,11 @@ inline Standard_OStream& operator << (Standard_OStream& AStream,
   return AStream;
 }
 
+inline Standard_OStream& operator << (Standard_OStream& AStream,
+                                      const Standard_Failure& AFailure)
+{
+  AFailure.Print(AStream);
+  return AStream;
+}
+
 #endif // _Standard_Failure_HeaderFile
index aa00065..459a60d 100644 (file)
@@ -177,16 +177,16 @@ Standard_GUID::Standard_GUID(const Standard_CString aGuid)
 {
   char* tmpBuffer =(char*) aGuid;
 
-  if(!CheckGUIDFormat(tmpBuffer)) Standard_RangeError::Raise("Invalid format of GUID");
+  if(!CheckGUIDFormat(tmpBuffer)) throw Standard_RangeError("Invalid format of GUID");
 
   if((tmpBuffer = Standard_GUID_GetValue32(tmpBuffer,my32b)) == NULL) 
-    Standard_RangeError::Raise("Invalid format of GUID");
+    throw Standard_RangeError("Invalid format of GUID");
   if((tmpBuffer = Standard_GUID_GetValue16(tmpBuffer,my16b1)) == NULL) 
-    Standard_RangeError::Raise("Invalid format of GUID");
+    throw Standard_RangeError("Invalid format of GUID");
   if((tmpBuffer = Standard_GUID_GetValue16(tmpBuffer,my16b2)) == NULL) 
-    Standard_RangeError::Raise("Invalid format of GUID");
+    throw Standard_RangeError("Invalid format of GUID");
   if((tmpBuffer = Standard_GUID_GetValue16(tmpBuffer,my16b3)) == NULL) 
-    Standard_RangeError::Raise("Invalid format of GUID");
+    throw Standard_RangeError("Invalid format of GUID");
   tmpBuffer = Standard_GUID_GetValue8(tmpBuffer,my8b1);
   tmpBuffer = Standard_GUID_GetValue8(tmpBuffer,my8b2);
   tmpBuffer = Standard_GUID_GetValue8(tmpBuffer,my8b3);
@@ -217,16 +217,16 @@ Standard_GUID::Standard_GUID(const Standard_ExtString aGuid)
 
   tmpBuffer[i] = '\0';
 
-  if(!CheckGUIDFormat(tmpBuffer)) Standard_RangeError::Raise("Invalid format of GUID");
+  if(!CheckGUIDFormat(tmpBuffer)) throw Standard_RangeError("Invalid format of GUID");
 
   if((tmpBuffer = Standard_GUID_GetValue32(tmpBuffer,my32b)) == NULL) 
-    Standard_RangeError::Raise("Invalid format of GUID");
+    throw Standard_RangeError("Invalid format of GUID");
   if((tmpBuffer = Standard_GUID_GetValue16(tmpBuffer,my16b1)) == NULL) 
-    Standard_RangeError::Raise("Invalid format of GUID");
+    throw Standard_RangeError("Invalid format of GUID");
   if((tmpBuffer = Standard_GUID_GetValue16(tmpBuffer,my16b2)) == NULL) 
-    Standard_RangeError::Raise("Invalid format of GUID");
+    throw Standard_RangeError("Invalid format of GUID");
   if((tmpBuffer = Standard_GUID_GetValue16(tmpBuffer,my16b3)) == NULL) 
-    Standard_RangeError::Raise("Invalid format of GUID");
+    throw Standard_RangeError("Invalid format of GUID");
   tmpBuffer = Standard_GUID_GetValue8(tmpBuffer,my8b1);
   tmpBuffer = Standard_GUID_GetValue8(tmpBuffer,my8b2);
   tmpBuffer = Standard_GUID_GetValue8(tmpBuffer,my8b3);
@@ -390,8 +390,7 @@ Standard_Integer Standard_GUID::HashCode(const Standard_GUID& aGuid,const Standa
 Standard_Integer Standard_GUID::Hash(const Standard_Integer Upper) const
 {
   if (Upper < 1){
-    Standard_RangeError::
-      Raise("Standard_GUID::Hash: Try to apply HashCode method with negative or null argument.");
+    throw Standard_RangeError("Standard_GUID::Hash: Try to apply HashCode method with negative or null argument.");
   }
 
   char sguid[Standard_GUID_SIZE_ALLOC];
index db90aeb..2ab6ded 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_ImmutableObject, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Standard_ImmutableObject
   #define Standard_ImmutableObject_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_ImmutableObject::Raise(MESSAGE);
+  if (CONDITION) throw Standard_ImmutableObject(MESSAGE);
 #else
   #define Standard_ImmutableObject_Raise_if(CONDITION, MESSAGE)
 #endif
index 256702d..7ad9fd3 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_LicenseError, Standard_Failure)
 
 #if !defined No_Exception && !defined No_Standard_LicenseError
   #define Standard_LicenseError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_LicenseError::Raise(MESSAGE);
+  if (CONDITION) throw Standard_LicenseError(MESSAGE);
 #else
   #define Standard_LicenseError_Raise_if(CONDITION, MESSAGE)
 #endif
index 38e90bf..e8a5599 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_LicenseNotFound, Standard_LicenseError)
 
 #if !defined No_Exception && !defined No_Standard_LicenseNotFound
   #define Standard_LicenseNotFound_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_LicenseNotFound::Raise(MESSAGE);
+  if (CONDITION) throw Standard_LicenseNotFound(MESSAGE);
 #else
   #define Standard_LicenseNotFound_Raise_if(CONDITION, MESSAGE)
 #endif
index 387dae6..b75854a 100644 (file)
@@ -401,7 +401,7 @@ Standard_Address Standard_MMgrOpt::Allocate(const Standard_Size aSize)
           aBlock = (Standard_Size*)calloc(RoundSizeN+BLOCK_SHIFT, sizeof(Standard_Size));
         // if still not succeeded, raise exception
         if ( ! aBlock )
-          Standard_OutOfMemory::Raise ("Standard_MMgrOpt::Allocate(): malloc failed");
+          throw Standard_OutOfMemory("Standard_MMgrOpt::Allocate(): malloc failed");
       }
 
       // initialize new block header by its size
@@ -726,7 +726,7 @@ retry:
       if ( Purge(Standard_False) )
         goto retry;
       // if nothing helps, raise exception
-      Standard_OutOfMemory::Raise (strerror(errcode));
+      throw Standard_OutOfMemory(strerror(errcode));
     }
 
     // save actually allocated size into argument
@@ -766,7 +766,7 @@ retry:
 
       char messageA[BUFSIZE];
       WideCharToMultiByte(CP_UTF8, 0, message, -1, messageA, sizeof(messageA), NULL, NULL);
-      Standard_OutOfMemory::Raise(messageA);
+      throw Standard_OutOfMemory(messageA);
     }
 
     // record map handle in the beginning
@@ -789,7 +789,7 @@ retry:
       if ( Purge(Standard_False) )
         goto retry;
       // if nothing helps, raise exception
-      Standard_OutOfMemory::Raise ("Standard_MMgrOpt::Allocate(): malloc failed");
+      throw Standard_OutOfMemory("Standard_MMgrOpt::Allocate(): malloc failed");
     }
   }
   // clear whole block if clearing option is set
index b6e9f6d..302053d 100644 (file)
@@ -41,7 +41,7 @@ Standard_Address Standard_MMgrRaw::Allocate(const Standard_Size aSize)
   Standard_Address aPtr = ( myClear ? calloc(aRoundSize, sizeof(char)) :
                                       malloc(aRoundSize) );
   if ( ! aPtr )
-    Standard_OutOfMemory::Raise("Standard_MMgrRaw::Allocate(): malloc failed");
+    throw Standard_OutOfMemory("Standard_MMgrRaw::Allocate(): malloc failed");
   return aPtr;
 }
 
@@ -68,7 +68,7 @@ Standard_Address Standard_MMgrRaw::Reallocate(Standard_Address theStorage,
   const Standard_Size aRoundSize = (theSize + 3) & ~0x3;
   Standard_Address newStorage = (Standard_Address)realloc(theStorage, aRoundSize);
   if ( ! newStorage )
-    Standard_OutOfMemory::Raise("Standard_MMgrRaw::Reallocate(): realloc failed");
+    throw Standard_OutOfMemory("Standard_MMgrRaw::Reallocate(): realloc failed");
   // Note that it is not possible to ensure that additional memory
   // allocated by realloc will be cleared (so as to satisfy myClear mode);
   // in order to do that we would need using memset...
index de1d4b0..8499e1a 100644 (file)
@@ -51,7 +51,7 @@ Standard_Address Standard_MMgrTBBalloc::Allocate(const Standard_Size aSize)
   Standard_Address aPtr = ( myClear ? scalable_calloc(aRoundSize, sizeof(char)) :
                                       scalable_malloc(aRoundSize) );
   if ( ! aPtr )
-    Standard_OutOfMemory::Raise("Standard_MMgrTBBalloc::Allocate(): malloc failed");
+    throw Standard_OutOfMemory("Standard_MMgrTBBalloc::Allocate(): malloc failed");
   return aPtr;
 }
 
@@ -78,7 +78,7 @@ Standard_Address Standard_MMgrTBBalloc::Reallocate (Standard_Address theStorage,
   const Standard_Size aRoundSize = (theSize + 3) & ~0x3;
   Standard_Address newStorage = (Standard_Address)scalable_realloc(theStorage, aRoundSize);
   if ( ! newStorage )
-    Standard_OutOfMemory::Raise("Standard_MMgrTBBalloc::Reallocate(): realloc failed");
+    throw Standard_OutOfMemory("Standard_MMgrTBBalloc::Reallocate(): realloc failed");
   // Note that it is not possible to ensure that additional memory
   // allocated by realloc will be cleared (so as to satisfy myClear mode);
   // in order to do that we would need using memset...
index 91ecd05..01c1f51 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_MultiplyDefined, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Standard_MultiplyDefined
   #define Standard_MultiplyDefined_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_MultiplyDefined::Raise(MESSAGE);
+  if (CONDITION) throw Standard_MultiplyDefined(MESSAGE);
 #else
   #define Standard_MultiplyDefined_Raise_if(CONDITION, MESSAGE)
 #endif
index 9bfdb0e..b1545f2 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_NegativeValue, Standard_RangeError)
 
 #if !defined No_Exception && !defined No_Standard_NegativeValue
   #define Standard_NegativeValue_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_NegativeValue::Raise(MESSAGE);
+  if (CONDITION) throw Standard_NegativeValue(MESSAGE);
 #else
   #define Standard_NegativeValue_Raise_if(CONDITION, MESSAGE)
 #endif
index e472033..67f97b8 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_NoMoreObject, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Standard_NoMoreObject
   #define Standard_NoMoreObject_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_NoMoreObject::Raise(MESSAGE);
+  if (CONDITION) throw Standard_NoMoreObject(MESSAGE);
 #else
   #define Standard_NoMoreObject_Raise_if(CONDITION, MESSAGE)
 #endif
index 2860a56..6c3a269 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_NoSuchObject, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Standard_NoSuchObject
   #define Standard_NoSuchObject_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_NoSuchObject::Raise(MESSAGE);
+  if (CONDITION) throw Standard_NoSuchObject(MESSAGE);
 #else
   #define Standard_NoSuchObject_Raise_if(CONDITION, MESSAGE)
 #endif
index e689d98..433fc9a 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_NotImplemented, Standard_ProgramError)
 
 #if !defined No_Exception && !defined No_Standard_NotImplemented
   #define Standard_NotImplemented_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_NotImplemented::Raise(MESSAGE);
+  if (CONDITION) throw Standard_NotImplemented(MESSAGE);
 #else
   #define Standard_NotImplemented_Raise_if(CONDITION, MESSAGE)
 #endif
index fad6f74..6d0ca0f 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_NullObject, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Standard_NullObject
   #define Standard_NullObject_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_NullObject::Raise(MESSAGE);
+  if (CONDITION) throw Standard_NullObject(MESSAGE);
 #else
   #define Standard_NullObject_Raise_if(CONDITION, MESSAGE)
 #endif
index 5f915d9..3edf240 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_NullValue, Standard_RangeError)
 
 #if !defined No_Exception && !defined No_Standard_NullValue
   #define Standard_NullValue_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_NullValue::Raise(MESSAGE);
+  if (CONDITION) throw Standard_NullValue(MESSAGE);
 #else
   #define Standard_NullValue_Raise_if(CONDITION, MESSAGE)
 #endif
index 25e1336..71a4639 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_NumericError, Standard_Failure)
 
 #if !defined No_Exception && !defined No_Standard_NumericError
   #define Standard_NumericError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_NumericError::Raise(MESSAGE);
+  if (CONDITION) throw Standard_NumericError(MESSAGE);
 #else
   #define Standard_NumericError_Raise_if(CONDITION, MESSAGE)
 #endif
index 81ed7b3..c75acbe 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_OutOfMemory, Standard_ProgramError)
 
 #if !defined No_Exception && !defined No_Standard_OutOfMemory
   #define Standard_OutOfMemory_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_OutOfMemory::Raise(MESSAGE);
+  if (CONDITION) throw Standard_OutOfMemory(MESSAGE);
 #else
   #define Standard_OutOfMemory_Raise_if(CONDITION, MESSAGE)
 #endif
@@ -48,7 +48,7 @@ DEFINE_STANDARD_HANDLE(Standard_OutOfMemory, Standard_ProgramError)
 
 class Standard_OutOfMemory : public Standard_ProgramError
 {
-  void Throw () const Standard_OVERRIDE;
+  Standard_EXPORT void Throw () const Standard_OVERRIDE;
 
 public:
 
index 7475c31..28b1123 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_OutOfRange, Standard_RangeError)
 
 #if !defined No_Exception && !defined No_Standard_OutOfRange
   #define Standard_OutOfRange_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_OutOfRange::Raise(MESSAGE);
+  if (CONDITION) throw Standard_OutOfRange(MESSAGE);
 #else
   #define Standard_OutOfRange_Raise_if(CONDITION, MESSAGE)
 #endif
index ac0f675..7e67d36 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_Overflow, Standard_NumericError)
 
 #if !defined No_Exception && !defined No_Standard_Overflow
   #define Standard_Overflow_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_Overflow::Raise(MESSAGE);
+  if (CONDITION) throw Standard_Overflow(MESSAGE);
 #else
   #define Standard_Overflow_Raise_if(CONDITION, MESSAGE)
 #endif
index 06bf783..2e9b3bc 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_ProgramError, Standard_Failure)
 
 #if !defined No_Exception && !defined No_Standard_ProgramError
   #define Standard_ProgramError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_ProgramError::Raise(MESSAGE);
+  if (CONDITION) throw Standard_ProgramError(MESSAGE);
 #else
   #define Standard_ProgramError_Raise_if(CONDITION, MESSAGE)
 #endif
index e884228..2cdffec 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_RangeError, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Standard_RangeError
   #define Standard_RangeError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_RangeError::Raise(MESSAGE);
+  if (CONDITION) throw Standard_RangeError(MESSAGE);
 #else
   #define Standard_RangeError_Raise_if(CONDITION, MESSAGE)
 #endif
index b587af4..fdc4220 100644 (file)
@@ -26,8 +26,7 @@
 Standard_Integer HashCode(const Standard_Real me, const Standard_Integer Upper)
 {
   if (Upper < 1){
-     Standard_RangeError::
-      Raise("Try to apply HashCode method with negative or null argument.");
+     throw Standard_RangeError("Try to apply HashCode method with negative or null argument.");
   }
   union 
     {
@@ -45,7 +44,7 @@ Standard_Integer HashCode(const Standard_Real me, const Standard_Integer Upper)
 Standard_Real ACos (const Standard_Real Value) 
 { 
   if ( (Value < -1.) || (Value > 1.) ){
-    Standard_RangeError::Raise();
+    throw Standard_RangeError();
   } 
   return acos(Value); 
 }
@@ -95,7 +94,7 @@ Standard_Real ACosApprox (const Standard_Real Value)
 Standard_Real ASin (const Standard_Real Value) 
 { 
   if ( Value < -1 || Value > 1 ){
-    Standard_RangeError::Raise();
+    throw Standard_RangeError();
   }
   return asin(Value); 
 }
@@ -106,7 +105,7 @@ Standard_Real ASin (const Standard_Real Value)
 Standard_Real ATan2 (const Standard_Real Value, const Standard_Real Other) 
 { 
   if ( Value == 0. && Other == 0. ){
-    Standard_NullValue::Raise();
+    throw Standard_NullValue();
   }
   return atan2(Value,Other); 
 }
@@ -233,10 +232,10 @@ double NextAfter(const double x, const double y)
 Standard_Real     ATanh(const Standard_Real Value) 
 { 
   if ( (Value <= -1.) || (Value >= 1.) ){
-    Standard_NumericError::Raise("Illegal agument in ATanh");
 #ifdef OCCT_DEBUG
     cout << "Illegal agument in ATanh" << endl ;
 #endif
+    throw Standard_NumericError("Illegal agument in ATanh");
   }
 #if __QNX__
   return std::atanh(Value);
@@ -251,10 +250,10 @@ Standard_Real     ATanh(const Standard_Real Value)
 Standard_Real     ACosh (const Standard_Real Value) 
 { 
   if ( Value < 1. ){
-    Standard_NumericError::Raise("Illegal agument in ACosh");
 #ifdef OCCT_DEBUG
     cout << "Illegal agument in ACosh" << endl ;
 #endif
+    throw Standard_NumericError("Illegal agument in ACosh");
   }
 #if __QNX__
   return std::acosh(Value);
@@ -269,10 +268,10 @@ Standard_Real     ACosh (const Standard_Real Value)
 Standard_Real     Cosh (const Standard_Real Value) 
 { 
   if ( Abs(Value) > 0.71047586007394394e+03 ){
-    Standard_NumericError::Raise("Result of Cosh exceeds the maximum value Standard_Real");
 #ifdef OCCT_DEBUG
     cout << "Result of Cosh exceeds the maximum value Standard_Real" << endl ;
 #endif
+    throw Standard_NumericError("Result of Cosh exceeds the maximum value Standard_Real");
   } 
   return cosh(Value); 
 }
@@ -283,10 +282,10 @@ Standard_Real     Cosh (const Standard_Real Value)
 Standard_Real     Sinh (const Standard_Real Value) 
 { 
   if ( Abs(Value) > 0.71047586007394394e+03 ){
-    Standard_NumericError::Raise("Result of Sinh exceeds the maximum value Standard_Real");
 #ifdef OCCT_DEBUG
     cout << "Result of Sinh exceeds the maximum value Standard_Real" << endl ;
 #endif
+    throw Standard_NumericError("Result of Sinh exceeds the maximum value Standard_Real");
   } 
   return sinh(Value); 
 }
@@ -296,10 +295,10 @@ Standard_Real     Sinh (const Standard_Real Value)
 //-------------------------------------------------------------------
 Standard_Real     Log (const Standard_Real Value) 
 {   if ( Value <= 0. ){
-    Standard_NumericError::Raise("Illegal agument in Log");
 #ifdef OCCT_DEBUG
     cout << "Illegal agument in Log" << endl ;
 #endif
+    throw Standard_NumericError("Illegal agument in Log");
   } 
  return log(Value); 
 }
@@ -309,10 +308,10 @@ Standard_Real     Log (const Standard_Real Value)
 Standard_Real     Sqrt (const Standard_Real Value) 
 { 
   if (  Value < 0. ){
-    Standard_NumericError::Raise("Illegal agument in Sqrt");
 #ifdef OCCT_DEBUG
     cout << "Illegal agument in Sqrt" << endl ;
 #endif
+    throw Standard_NumericError("Illegal agument in Sqrt");
   } 
  return sqrt(Value); 
 }
index cc2d241..63d765d 100644 (file)
@@ -24,8 +24,7 @@
 Standard_Integer HashCode(const Standard_ShortReal me, const Standard_Integer Upper)
 {
   if (Upper < 1){
-     Standard_RangeError::
-      Raise("Try to apply HashCode method with negative or null argument.");
+     throw Standard_RangeError("Try to apply HashCode method with negative or null argument.");
   }
   union 
     {
index 92a6cea..087cfb3 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_TooManyUsers, Standard_LicenseError)
 
 #if !defined No_Exception && !defined No_Standard_TooManyUsers
   #define Standard_TooManyUsers_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_TooManyUsers::Raise(MESSAGE);
+  if (CONDITION) throw Standard_TooManyUsers(MESSAGE);
 #else
   #define Standard_TooManyUsers_Raise_if(CONDITION, MESSAGE)
 #endif
index a57af06..3510970 100644 (file)
@@ -68,7 +68,7 @@ Standard_Boolean Standard_Transient::IsKind (const Standard_CString theTypeName)
 Standard_Transient* Standard_Transient::This() const
 {
   if (GetRefCount() == 0)
-    Standard_ProgramError::Raise ("Attempt to create handle to object created in stack, not yet constructed, or destroyed");
+    throw Standard_ProgramError("Attempt to create handle to object created in stack, not yet constructed, or destroyed");
   return const_cast<Standard_Transient*> (this);
 }
 
index a593fa0..4c29d4a 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_TypeMismatch, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_Standard_TypeMismatch
   #define Standard_TypeMismatch_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_TypeMismatch::Raise(MESSAGE);
+  if (CONDITION) throw Standard_TypeMismatch(MESSAGE);
 #else
   #define Standard_TypeMismatch_Raise_if(CONDITION, MESSAGE)
 #endif
index 481691d..07ff760 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Standard_Underflow, Standard_NumericError)
 
 #if !defined No_Exception && !defined No_Standard_Underflow
   #define Standard_Underflow_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Standard_Underflow::Raise(MESSAGE);
+  if (CONDITION) throw Standard_Underflow(MESSAGE);
 #else
   #define Standard_Underflow_Raise_if(CONDITION, MESSAGE)
 #endif
index 2aed18c..76d5d6e 100644 (file)
@@ -46,8 +46,7 @@ Handle(Standard_Transient) StdDrivers::Factory (const Standard_GUID& aGUID)
     return model_rd;
   }
  
-  Standard_Failure::Raise ("StdDrivers : unknown GUID");
-  return NULL;
+  throw Standard_Failure("StdDrivers : unknown GUID");
 }
 
 //=======================================================================
index 334c813..79821b4 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(StdFail_InfiniteSolutions, Standard_Failure)
 
 #if !defined No_Exception && !defined No_StdFail_InfiniteSolutions
   #define StdFail_InfiniteSolutions_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) StdFail_InfiniteSolutions::Raise(MESSAGE);
+  if (CONDITION) throw StdFail_InfiniteSolutions(MESSAGE);
 #else
   #define StdFail_InfiniteSolutions_Raise_if(CONDITION, MESSAGE)
 #endif
index 9eb6f92..0671da9 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(StdFail_NotDone, Standard_Failure)
 
 #if !defined No_Exception && !defined No_StdFail_NotDone
   #define StdFail_NotDone_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) StdFail_NotDone::Raise(MESSAGE);
+  if (CONDITION) throw StdFail_NotDone(MESSAGE);
 #else
   #define StdFail_NotDone_Raise_if(CONDITION, MESSAGE)
 #endif
index 62072b9..86c4d42 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(StdFail_Undefined, Standard_Failure)
 
 #if !defined No_Exception && !defined No_StdFail_Undefined
   #define StdFail_Undefined_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) StdFail_Undefined::Raise(MESSAGE);
+  if (CONDITION) throw StdFail_Undefined(MESSAGE);
 #else
   #define StdFail_Undefined_Raise_if(CONDITION, MESSAGE)
 #endif
index fb2684d..309c14f 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(StdFail_UndefinedDerivative, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_StdFail_UndefinedDerivative
   #define StdFail_UndefinedDerivative_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) StdFail_UndefinedDerivative::Raise(MESSAGE);
+  if (CONDITION) throw StdFail_UndefinedDerivative(MESSAGE);
 #else
   #define StdFail_UndefinedDerivative_Raise_if(CONDITION, MESSAGE)
 #endif
index 578a512..885e3ca 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(StdFail_UndefinedValue, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_StdFail_UndefinedValue
   #define StdFail_UndefinedValue_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) StdFail_UndefinedValue::Raise(MESSAGE);
+  if (CONDITION) throw StdFail_UndefinedValue(MESSAGE);
 #else
   #define StdFail_UndefinedValue_Raise_if(CONDITION, MESSAGE)
 #endif
index 547b9bd..b655e27 100644 (file)
@@ -43,8 +43,7 @@ Handle(Standard_Transient) StdLDrivers::Factory (const Standard_GUID& aGUID)
     return model_rd;
   }
  
-  Standard_Failure::Raise ("StdLDrivers : unknown GUID");
-  return NULL;
+  throw Standard_Failure("StdLDrivers : unknown GUID");
 }
 
 //=======================================================================
index 5c2ebad..9adb12e 100644 (file)
@@ -95,13 +95,13 @@ Handle(StdObjMgt_Persistent) StdLDrivers_DocumentRetrievalDriver::read (
     PCDM_ReadWriter::Open (*aFileDriver, theFileName, Storage_VSRead);
     myReaderStatus = PCDM_RS_OK;
   } 
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
     myReaderStatus = PCDM_RS_OpenError;
 
     Standard_SStream aMsg;
-    aMsg << Standard_Failure::Caught() << endl;
-    Standard_Failure::Raise (aMsg);
+    aMsg << anException << endl;
+    throw Standard_Failure(aMsg.str().c_str());
   }
   
   // Read header section
@@ -124,7 +124,7 @@ Handle(StdObjMgt_Persistent) StdLDrivers_DocumentRetrievalDriver::read (
 
     Standard_SStream aMsg;
     aMsg << "could not find any document in this file" << endl;
-    Standard_Failure::Raise (aMsg);
+    throw Standard_Failure(aMsg.str().c_str());
   }
 
   // Select instantiators for the used types
@@ -164,7 +164,7 @@ Handle(StdObjMgt_Persistent) StdLDrivers_DocumentRetrievalDriver::read (
         else                             aMsg << endl;
       }
 
-      Standard_Failure::Raise (aMsg);
+      throw Standard_Failure(aMsg.str().c_str());
     }
   }
 
@@ -231,7 +231,7 @@ void StdLDrivers_DocumentRetrievalDriver::Read (Standard_IStream&
                                                 const Handle(CDM_Document)&     /*theDoc*/,
                                                 const Handle(CDM_Application)&  /*theApplication*/)
 {
-  Standard_NotImplemented::Raise ("Reading from stream is not supported by StdLDrivers_DocumentRetrievalDriver");
+  throw Standard_NotImplemented("Reading from stream is not supported by StdLDrivers_DocumentRetrievalDriver");
 }
 
 //=======================================================================
@@ -253,37 +253,37 @@ void StdLDrivers_DocumentRetrievalDriver::raiseOnStorageError (Storage_Error the
   case Storage_VSAlreadyOpen:
     myReaderStatus = PCDM_RS_OpenError;
     aMsg << "Stream Open Error" << endl;
-    Standard_Failure::Raise (aMsg);
+    throw Standard_Failure(aMsg.str().c_str());
 
   case Storage_VSModeError:
     myReaderStatus = PCDM_RS_WrongStreamMode;
     aMsg << "Stream is opened with a wrong mode for operation" << endl;
-    Standard_Failure::Raise (aMsg);
+    throw Standard_Failure(aMsg.str().c_str());
 
   case Storage_VSSectionNotFound:
     myReaderStatus = PCDM_RS_FormatFailure;
     aMsg << "Section is not found" << endl;
-    Standard_Failure::Raise (aMsg);
+    throw Standard_Failure(aMsg.str().c_str());
 
   case Storage_VSFormatError:
     myReaderStatus = PCDM_RS_FormatFailure;
     aMsg << "Wrong format error" << endl;
-    Standard_Failure::Raise (aMsg);
+    throw Standard_Failure(aMsg.str().c_str());
 
   case Storage_VSUnknownType:
     myReaderStatus = PCDM_RS_TypeFailure;
     aMsg << "Try to read an unknown type" << endl;
-    Standard_Failure::Raise (aMsg);
+    throw Standard_Failure(aMsg.str().c_str());
 
   case Storage_VSTypeMismatch:
     myReaderStatus = PCDM_RS_TypeFailure;
     aMsg << "Try to read a wrong primitive type" << endl;
-    Standard_Failure::Raise (aMsg);
+    throw Standard_Failure(aMsg.str().c_str());
 
   default:
     myReaderStatus = PCDM_RS_DriverFailure;
     aMsg << "Retrieval Driver Failure" << endl;
-    Standard_Failure::Raise (aMsg);
+    throw Standard_Failure(aMsg.str().c_str());
   }
 }
 
index c3803ba..d161705 100644 (file)
@@ -1050,8 +1050,7 @@ Standard_Boolean StdSelect_ViewerSelector3d::ToPixMap (Image_PixMap&
 {
   if (theImage.IsEmpty())
   {
-    Standard_ProgramError::Raise ("StdSelect_ViewerSelector3d::ToPixMap() has been called with empty image");
-    return Standard_False;
+    throw Standard_ProgramError("StdSelect_ViewerSelector3d::ToPixMap() has been called with empty image");
   }
 
   Handle(BaseFiller) aFiller;
index ec78dd6..679c18c 100644 (file)
@@ -30,14 +30,12 @@ Standard_Integer  StepData_FieldList::NbFields () const
 
 const StepData_Field&  StepData_FieldList::Field (const Standard_Integer) const
 {
-  Standard_OutOfRange::Raise("StepData_FieldList : Field");
-  return nulfild;
+  throw Standard_OutOfRange("StepData_FieldList : Field");
 }
 
 StepData_Field&  StepData_FieldList::CField (const Standard_Integer)
 {
-  Standard_OutOfRange::Raise("StepData_FieldList : CField");
-  return nulfild;
+  throw Standard_OutOfRange("StepData_FieldList : CField");
 }
 
 
index e3a8b3d..2442c31 100644 (file)
@@ -23,12 +23,12 @@ Standard_Integer  StepData_FieldList1::NbFields () const
 
 const StepData_Field&  StepData_FieldList1::Field (const Standard_Integer num) const
 {
-  if (num != 1) Standard_OutOfRange::Raise("StepData_FieldList1 : Field");
+  if (num != 1) throw Standard_OutOfRange("StepData_FieldList1 : Field");
   return thefield;
 }
 
 StepData_Field&  StepData_FieldList1::CField (const Standard_Integer num)
 {
-  if (num != 1) Standard_OutOfRange::Raise("StepData_FieldList1 : CField");
+  if (num != 1) throw Standard_OutOfRange("StepData_FieldList1 : CField");
   return thefield;
 }
index 30efabd..d96a76d 100644 (file)
@@ -30,12 +30,12 @@ Standard_Integer  StepData_FieldListD::NbFields () const
 
 const StepData_Field&  StepData_FieldListD::Field (const Standard_Integer num) const
 {
-  if (thefields.IsNull()) Standard_OutOfRange::Raise("StepData_FieldListD::Field");
+  if (thefields.IsNull()) throw Standard_OutOfRange("StepData_FieldListD::Field");
   return thefields->Value(num);
 }
 
 StepData_Field&  StepData_FieldListD::CField (const Standard_Integer num)
 {
-  if (thefields.IsNull()) Standard_OutOfRange::Raise("StepData_FieldListD::Field");
+  if (thefields.IsNull()) throw Standard_OutOfRange("StepData_FieldListD::Field");
   return thefields->ChangeValue(num);
 }
index cf9d85c..66131f6 100644 (file)
@@ -77,8 +77,7 @@ static StepData_Field bid;
     ent = Member(i);
     if (ent->HasField (name)) return ent->Field (name);
   }
-  Interface_InterfaceMismatch::Raise("StepData_Plex : Field");
-  return bid;  // pour faire plaisir au compilo
+  throw Interface_InterfaceMismatch("StepData_Plex : Field");
 }
 
 
@@ -90,8 +89,7 @@ static StepData_Field bid;
     ent = Member(i);
     if (ent->HasField (name)) return ent->CField (name);
   }
-  Interface_InterfaceMismatch::Raise("StepData_Plex : Field");
-  return bid;  // pour faire plaisir au compilo
+  throw Interface_InterfaceMismatch("StepData_Plex : Field");
 }
 
 
index db55e4b..36a31e8 100644 (file)
@@ -36,7 +36,7 @@ Standard_Boolean  StepData_SelectType::Matches
 {
   if (ent.IsNull())  thevalue.Nullify();
   else if (!Matches(ent))
-    Standard_TypeMismatch::Raise ("StepData : SelectType, SetValue");
+    throw Standard_TypeMismatch("StepData : SelectType, SetValue");
   else thevalue = ent;
 }
 
@@ -97,7 +97,7 @@ Standard_Boolean  StepData_SelectType::Matches
     void  StepData_SelectType::SetInt (const Standard_Integer val)
 {
   DeclareAndCast(StepData_SelectMember,sm,thevalue);
-  if (sm.IsNull()) Standard_TypeMismatch::Raise ("StepData : SelectType, SetInt");
+  if (sm.IsNull()) throw Standard_TypeMismatch("StepData : SelectType, SetInt");
   sm->SetInt (val);
 }
 
@@ -110,7 +110,7 @@ static Handle(StepData_SelectMember) SelectVal
   DeclareAndCast(StepData_SelectMember,sm,thevalue);
   if (!sm.IsNull()) {
     if (name && name[0] != '\0')
-      if (!sm->SetName(name)) Standard_TypeMismatch::Raise ("StepData : SelectType, SetInteger");
+      if (!sm->SetName(name)) throw Standard_TypeMismatch("StepData : SelectType, SetInteger");
   }
   else if (name && name[0] != '\0') {
     Handle(StepData_SelectNamed) sn = new StepData_SelectNamed;
@@ -136,7 +136,7 @@ static Handle(StepData_SelectMember) SelectVal
 {
   Handle(StepData_SelectMember) sm = SelectVal (thevalue,name,0);
   sm->SetInteger (val);
-  if (CaseMem (sm) == 0) Standard_TypeMismatch::Raise ("StepData : SelectType, SetInteger");
+  if (CaseMem (sm) == 0) throw Standard_TypeMismatch("StepData : SelectType, SetInteger");
   thevalue = sm;
 }
 
@@ -152,7 +152,7 @@ static Handle(StepData_SelectMember) SelectVal
 {
   Handle(StepData_SelectMember) sm = SelectVal (thevalue,name,0);
   sm->SetBoolean (val);
-  if (CaseMem (sm) == 0) Standard_TypeMismatch::Raise ("StepData : SelectType, SetBoolean");
+  if (CaseMem (sm) == 0) throw Standard_TypeMismatch("StepData : SelectType, SetBoolean");
   thevalue = sm;
 }
 
@@ -168,7 +168,7 @@ static Handle(StepData_SelectMember) SelectVal
 {
   Handle(StepData_SelectMember) sm = SelectVal (thevalue,name,0);
   sm->SetLogical (val);
-  if (CaseMem (sm) == 0) Standard_TypeMismatch::Raise ("StepData : SelectType, SetLogical");
+  if (CaseMem (sm) == 0) throw Standard_TypeMismatch("StepData : SelectType, SetLogical");
   thevalue = sm;
 }
 
@@ -184,7 +184,7 @@ Standard_Real  StepData_SelectType::Real () const
 {
   Handle(StepData_SelectMember) sm = SelectVal (thevalue,name,1);
   sm->SetReal (val);
-  if (CaseMem (sm) == 0) Standard_TypeMismatch::Raise ("StepData : SelectType, SetReal");
+  if (CaseMem (sm) == 0) throw Standard_TypeMismatch("StepData : SelectType, SetReal");
   thevalue = sm;
 }
 
index 6f29a06..81fa474 100644 (file)
@@ -56,14 +56,14 @@ StepData_Simple::StepData_Simple (const Handle(StepData_ESDescr)& descr)
     const StepData_Field&  StepData_Simple::Field (const Standard_CString name) const
 {
   Standard_Integer num = ESDescr()->Rank (name);
-  if (num == 0) Interface_InterfaceMismatch::Raise("StepData_Simple : Field");
+  if (num == 0) throw Interface_InterfaceMismatch("StepData_Simple : Field");
   return FieldNum (num);
 }
 
     StepData_Field&  StepData_Simple::CField (const Standard_CString name)
 {
   Standard_Integer num = ESDescr()->Rank (name);
-  if (num == 0) Interface_InterfaceMismatch::Raise("StepData_Simple : Field");
+  if (num == 0) throw Interface_InterfaceMismatch("StepData_Simple : Field");
   return CFieldNum (num);
 }
 
index 074352a..134fdf7 100644 (file)
@@ -97,10 +97,10 @@ void StepData_StepReaderTool::Prepare (const Standard_Boolean optim)
       stepdat->SetEntityNumbers(optim);
       SetEntities();
     }
-    catch(Standard_Failure) {
+    catch(Standard_Failure const& anException) {
       Handle(Message_Messenger) sout = Message::DefaultMessenger();
       sout << " Exception Raised during Preparation :\n";
-      sout << Standard_Failure::Caught()->GetMessageString();
+      sout << anException.GetMessageString();
       sout << "\n Now, trying to continue, but with presomption of failure\n";
     }
   }
index 512b962..8186299 100644 (file)
@@ -119,7 +119,7 @@ void StepData_StepWriter::SetScope (const Standard_Integer numscope,
 {
   Standard_Integer nb = themodel->NbEntities();
   if (numscope <= 0 || numscope > nb || numin <= 0 || numin > nb)
-    Interface_InterfaceMismatch::Raise("StepWriter : SetScope, out of range");
+    throw Interface_InterfaceMismatch("StepWriter : SetScope, out of range");
   if (thescopenext.IsNull()) {
     thescopebeg  = new TColStd_HArray1OfInteger (1,nb); thescopebeg->Init(0);
     thescopeend  = new TColStd_HArray1OfInteger (1,nb); thescopeend->Init(0);
@@ -130,7 +130,7 @@ void StepData_StepWriter::SetScope (const Standard_Integer numscope,
     cout << "StepWriter : SetScope (scope : " << numscope << " entity : "
       << numin << "), Entity already in a Scope"<<endl;
 #endif
-    Interface_InterfaceMismatch::Raise("StepWriter : SetScope, already set");
+    throw Interface_InterfaceMismatch("StepWriter : SetScope, already set");
   }
   thescopenext->SetValue(numin,-1);  // nouvelle fin de scope
   if (thescopebeg->Value(numscope) == 0) thescopebeg->SetValue(numscope,numin);
@@ -258,7 +258,7 @@ void StepData_StepWriter::SendHeader ()
 
 void StepData_StepWriter::SendData ()
 {
-  if (thesect) Interface_InterfaceMismatch::Raise("StepWriter : Data section");
+  if (thesect) throw Interface_InterfaceMismatch("StepWriter : Data section");
   NewLine(Standard_False);
   thefile->Append (new TCollection_HAsciiString("DATA;"));
   thesect = Standard_True;
@@ -284,7 +284,7 @@ void StepData_StepWriter::EndSec ()
 
 void StepData_StepWriter::EndFile ()
 {
-  if (thesect) Interface_InterfaceMismatch::Raise("StepWriter : EndFile");
+  if (thesect) throw Interface_InterfaceMismatch("StepWriter : EndFile");
   NewLine(Standard_False);
   thefile->Append (new TCollection_HAsciiString("END-ISO-10303-21;"));
   thesect = Standard_False;
@@ -489,7 +489,7 @@ void StepData_StepWriter::Comment (const Standard_Boolean mode)
 
 void StepData_StepWriter::SendComment(const Handle(TCollection_HAsciiString)& text)
 {
-  if (!thecomm) Interface_InterfaceMismatch::Raise("StepWriter : Comment");
+  if (!thecomm) throw Interface_InterfaceMismatch("StepWriter : Comment");
   AddString(text->ToCString(),text->Length());
 }
 
@@ -501,7 +501,7 @@ void StepData_StepWriter::SendComment(const Handle(TCollection_HAsciiString)& te
 
 void StepData_StepWriter::SendComment (const Standard_CString text)
 {
-  if (!thecomm) Interface_InterfaceMismatch::Raise("StepWriter : Comment");
+  if (!thecomm) throw Interface_InterfaceMismatch("StepWriter : Comment");
   AddString(text,(Standard_Integer) strlen(text));
 }
 
@@ -515,8 +515,7 @@ void StepData_StepWriter::StartEntity(const TCollection_AsciiString& atype)
 {
   if (atype.Length() == 0) return;
   if (themult) {
-    if (thelevel != 1) Interface_InterfaceMismatch::Raise
-      ("StepWriter : StartEntity");   // decompte de parentheses mauvais ...
+    if (thelevel != 1) throw Interface_InterfaceMismatch("StepWriter : StartEntity");   // decompte de parentheses mauvais ...
     AddString(textendlist);
     AddString(" ",1); //skl 29.01.2003
   }
@@ -876,7 +875,7 @@ void StepData_StepWriter::Send (const Handle(Standard_Transient)& val)
   char lident[20];
 //  Undefined ?
   if (val.IsNull()) {
-//   Interface_InterfaceMismatch::Raise("StepWriter : Sending Null Reference");
+//   throw Interface_InterfaceMismatch("StepWriter : Sending Null Reference");
     thechecks.CCheck(thenum)->AddFail("Null Reference");
     SendUndef();
     Comment(Standard_True);
@@ -906,7 +905,7 @@ void StepData_StepWriter::Send (const Handle(Standard_Transient)& val)
       Comment(Standard_True);
       SendComment(" UNKNOWN REF ");
       Comment(Standard_False);
-//      Interface_InterfaceMismatch::Raise("StepWriter : Sending Unknown Reference");
+//      throw Interface_InterfaceMismatch("StepWriter : Sending Unknown Reference");
     }
   }
 //  Cas normal : une bonne Entite, on envoie son Ident.
@@ -1062,8 +1061,7 @@ void StepData_StepWriter::SendDerived ()
 
 void StepData_StepWriter::EndEntity ()
 {
-  if (thelevel != 1) Interface_InterfaceMismatch::Raise
-    ("StepWriter : EndEntity");   // decompte de parentheses mauvais ...
+  if (thelevel != 1) throw Interface_InterfaceMismatch("StepWriter : EndEntity");   // decompte de parentheses mauvais ...
   AddString(textendent);
   thelevel  = 0;        // on garde theindval : sera traite au prochain NewLine
   Standard_Boolean indent = theindent; theindent = Standard_False;
index 9203e99..aaff6f8 100644 (file)
@@ -18,5 +18,5 @@
 
 void StepFile_CallFailure(char * const message)
 {
-  Standard_Failure::Raise(message);
+  throw Standard_Failure(message);
 }
index 2e024c9..9ce4327 100644 (file)
@@ -136,12 +136,13 @@ Standard_Integer StepFile_Read
     OCC_CATCH_SIGNALS
     if (stepread () != 0) {  lir_file_fin(3);  stepread_endinput (newin,ficnom);  return 1;  }
   }
-  catch (Standard_Failure) {
+  catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
     sout << " ...  Exception Raised while reading Step File : " << ficnom << ":\n" << endl;
-    sout << Standard_Failure::Caught()->GetMessageString();  
+    sout << anException.GetMessageString();  
     sout << "    ..." << endl;
 #endif
+    (void)anException;
     lir_file_fin(3);  
     stepread_endinput (newin,ficnom);  
     return 1;
index 8363e53..fd82fee 100644 (file)
@@ -36,7 +36,7 @@ static TCollection_AsciiString lastvalue;
   (const Handle(Interface_Protocol)& proto)
 {
   DeclareAndCast(StepData_Protocol,newproto,proto);
-  if (newproto.IsNull()) Interface_InterfaceError::Raise("StepSelect_StepType");
+  if (newproto.IsNull()) throw Interface_InterfaceError("StepSelect_StepType");
   theproto = newproto;
   thelib.Clear();
   thelib.AddProtocol (theproto);
index 3096b4c..5edea1a 100644 (file)
@@ -1540,12 +1540,14 @@ Handle(Geom_Surface) StepToGeom::MakeSurface (const Handle(StepGeom_Surface)& SS
       }
     }
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
+#ifdef OCCT_DEBUG
 //   ShapeTool_DB ?
-#ifdef OCCT_DEBUG //:s5
+//:s5
     cout<<"Warning: MakeSurface: Exception:";
-    Standard_Failure::Caught()->Print(cout); cout << endl;
+    anException.Print(cout); cout << endl;
 #endif
+    (void)anException;
   }
   return 0;
 }
index 3ee3429..cb79d04 100644 (file)
@@ -800,10 +800,10 @@ void StepToTopoDS_Builder::Init
          OCC_CATCH_SIGNALS
           aGeomCrv = StepToGeom::MakeCurve (aCrv);
        }
-       catch(Standard_Failure) {
+       catch(Standard_Failure const& anException) {
          Handle(Message_Messenger) sout = TP->Messenger();
          sout<<"StepToTopoDS, GeometricSet, elem "<<i<<" of "<<nbElem<<": exception ";
-         sout<<Standard_Failure::Caught()->GetMessageString() << endl;
+         sout<<anException.GetMessageString() << endl;
        }
        if ( ! aGeomCrv.IsNull() ) {
          BRepBuilderAPI_MakeEdge anEdge(aGeomCrv, aGeomCrv->FirstParameter(), aGeomCrv->LastParameter());
index 75c394b..448c092 100644 (file)
@@ -191,11 +191,12 @@ Standard_Boolean StepToTopoDS_TranslateCompositeCurve::Init (const Handle(StepGe
           }
         }
       }
-      catch(Standard_Failure) {
+      catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
        cout << "Warning: StepToTopoDS_TranslateCompositeCurve: Exception: ";
-       Standard_Failure::Caught()->Print(cout); cout << endl;
+       anException.Print(cout); cout << endl;
 #endif
+       (void)anException;
       }
     }
     
@@ -228,11 +229,12 @@ Standard_Boolean StepToTopoDS_TranslateCompositeCurve::Init (const Handle(StepGe
          }
        }
       }
-      catch(Standard_Failure) {
+      catch(Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
        cout << "Warning: StepToTopoDS_TranslateCompositeCurve: Exception: ";
-       Standard_Failure::Caught()->Print(cout); cout << endl;
+       anException.Print(cout); cout << endl;
 #endif
+       (void)anException;
       }
     }
     
index b4a94dc..8b2d1aa 100644 (file)
@@ -326,13 +326,13 @@ void StepToTopoDS_TranslateEdgeLoop::Init(const Handle(StepShape_FaceBound)& Fac
             TP->AddWarning(C,"Could not convert a curve. Curve definition is incorrect");
         }
       }
-      catch (Standard_Failure)
-      {
-        TP->AddFail(C,"Exeption was raised. Curve geometry definition is incorrect");
+      catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
-  cout << "Warning: StepToTopoDS_TranslateEdgeLoop: Exception: ";
-  Standard_Failure::Caught()->Print(cout); cout << endl;
+        cout << "Warning: StepToTopoDS_TranslateEdgeLoop: Exception: ";
+        anException.Print(cout); cout << endl;
 #endif
+        (void)anException;
+        TP->AddFail(C,"Exeption was raised. Curve geometry definition is incorrect");
       }
     }
 
index a4b103b..c069dbf 100644 (file)
@@ -131,7 +131,7 @@ void Storage_RootData::UpdateRoot(const TCollection_AsciiString& aName,const Han
     myObjects.ChangeFind(aName)->SetObject(aPers);
   }
   else {
-    Standard_NoSuchObject::Raise();
+    throw Standard_NoSuchObject();
   }
 }
 
index 1be563f..ac046fc 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Storage_StreamExtCharParityError, Storage_StreamReadError
 
 #if !defined No_Exception && !defined No_Storage_StreamExtCharParityError
   #define Storage_StreamExtCharParityError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Storage_StreamExtCharParityError::Raise(MESSAGE);
+  if (CONDITION) throw Storage_StreamExtCharParityError(MESSAGE);
 #else
   #define Storage_StreamExtCharParityError_Raise_if(CONDITION, MESSAGE)
 #endif
index e31068b..e3c44b3 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Storage_StreamFormatError, Standard_Failure)
 
 #if !defined No_Exception && !defined No_Storage_StreamFormatError
   #define Storage_StreamFormatError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Storage_StreamFormatError::Raise(MESSAGE);
+  if (CONDITION) throw Storage_StreamFormatError(MESSAGE);
 #else
   #define Storage_StreamFormatError_Raise_if(CONDITION, MESSAGE)
 #endif
index 86f9d06..e6da24a 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Storage_StreamModeError, Standard_Failure)
 
 #if !defined No_Exception && !defined No_Storage_StreamModeError
   #define Storage_StreamModeError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Storage_StreamModeError::Raise(MESSAGE);
+  if (CONDITION) throw Storage_StreamModeError(MESSAGE);
 #else
   #define Storage_StreamModeError_Raise_if(CONDITION, MESSAGE)
 #endif
index 029cceb..0ca265e 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Storage_StreamReadError, Standard_Failure)
 
 #if !defined No_Exception && !defined No_Storage_StreamReadError
   #define Storage_StreamReadError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Storage_StreamReadError::Raise(MESSAGE);
+  if (CONDITION) throw Storage_StreamReadError(MESSAGE);
 #else
   #define Storage_StreamReadError_Raise_if(CONDITION, MESSAGE)
 #endif
index dbbc1c3..d1d9561 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Storage_StreamTypeMismatchError, Storage_StreamReadError)
 
 #if !defined No_Exception && !defined No_Storage_StreamTypeMismatchError
   #define Storage_StreamTypeMismatchError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Storage_StreamTypeMismatchError::Raise(MESSAGE);
+  if (CONDITION) throw Storage_StreamTypeMismatchError(MESSAGE);
 #else
   #define Storage_StreamTypeMismatchError_Raise_if(CONDITION, MESSAGE)
 #endif
index 576aaae..daa18fa 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Storage_StreamUnknownTypeError, Storage_StreamReadError)
 
 #if !defined No_Exception && !defined No_Storage_StreamUnknownTypeError
   #define Storage_StreamUnknownTypeError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Storage_StreamUnknownTypeError::Raise(MESSAGE);
+  if (CONDITION) throw Storage_StreamUnknownTypeError(MESSAGE);
 #else
   #define Storage_StreamUnknownTypeError_Raise_if(CONDITION, MESSAGE)
 #endif
index 44de4a2..cfab9a2 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Storage_StreamWriteError, Standard_Failure)
 
 #if !defined No_Exception && !defined No_Storage_StreamWriteError
   #define Storage_StreamWriteError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Storage_StreamWriteError::Raise(MESSAGE);
+  if (CONDITION) throw Storage_StreamWriteError(MESSAGE);
 #else
   #define Storage_StreamWriteError_Raise_if(CONDITION, MESSAGE)
 #endif
index 8a6e8e1..a07cf86 100644 (file)
@@ -111,7 +111,7 @@ TCollection_AsciiString Storage_TypeData::Type(const Standard_Integer aTypeNum)
     r = myPt.FindKey(aTypeNum);
   }
   else {
-    Standard_NoSuchObject::Raise("Storage_TypeData::Type - aTypeNum not in range");
+    throw Standard_NoSuchObject("Storage_TypeData::Type - aTypeNum not in range");
   }
 
   return r;
@@ -125,7 +125,7 @@ Standard_Integer Storage_TypeData::Type(const TCollection_AsciiString& aTypeName
     r = myPt.FindFromKey(aTypeName);
   }
   else {
-    Standard_NoSuchObject::Raise("Storage_TypeData::Type - aTypeName not found");
+    throw Standard_NoSuchObject("Storage_TypeData::Type - aTypeName not found");
   }
 
   return r;
index b361878..249635d 100644 (file)
@@ -147,7 +147,7 @@ Sweep_NumShape Sweep_NumShapeTool::FirstVertex()const
                            myNumShape.Closed(),Standard_False,
                            Standard_False);
     }
-    else Standard_ConstructionError::Raise("inifinite Shape");
+    else throw Standard_ConstructionError("inifinite Shape");
   }
   return myNumShape;
 }
@@ -166,7 +166,7 @@ Sweep_NumShape Sweep_NumShapeTool::LastVertex()const
                            myNumShape.Closed(),Standard_False,
                            Standard_False);
     }
-    else Standard_ConstructionError::Raise("inifinite Shape");
+    else throw Standard_ConstructionError("inifinite Shape");
   }
   return myNumShape;
 }
index c6929c2..dd74161 100644 (file)
@@ -40,7 +40,7 @@ void TCollection_Array2::Allocate ()
 //  Modified by Sergey KHROMOV - Mon Feb 10 11:46:15 2003 End
     myData = new Array2Item [Size];
 
-    if (!myData) Standard_OutOfMemory::Raise("Array2 : Allocation failed");
+    if (!myData) throw Standard_OutOfMemory("Array2 : Allocation failed");
   }
   
   // allocation of the indirection table (pointers on rows)
index 09156ab..027b975 100644 (file)
@@ -67,7 +67,7 @@ TCollection_AsciiString::TCollection_AsciiString(const Standard_CString astring)
     mystring[mylength] = '\0';
   }
   else {
-    Standard_NullObject::Raise("TCollection_AsciiString : parameter 'astring'");
+    throw Standard_NullObject("TCollection_AsciiString : parameter 'astring'");
   }
 }
 
@@ -84,7 +84,7 @@ TCollection_AsciiString::TCollection_AsciiString(const Standard_CString astring,
     mystring [ mylength ] = '\0' ;
   }
   else {
-    Standard_NullObject::Raise("TCollection_AsciiString : parameter 'astring'");
+    throw Standard_NullObject("TCollection_AsciiString : parameter 'astring'");
   }
 }
 
@@ -308,7 +308,7 @@ void TCollection_AsciiString::AssignCat(const Standard_CString other)
     }
   }
   else {
-    Standard_NullObject::Raise("TCollection_AsciiString::Operator += parameter other");
+    throw Standard_NullObject("TCollection_AsciiString::Operator += parameter other");
   }
 }
 
@@ -348,7 +348,7 @@ void TCollection_AsciiString::Center(const Standard_Integer Width ,
     RightJustify(Width,Filler);
   }
   else if (Width < 0) {
-    Standard_NegativeValue::Raise();
+    throw Standard_NegativeValue();
   }
 }
 
@@ -441,8 +441,7 @@ Standard_Integer TCollection_AsciiString::FirstLocationInSet
         if (mystring[i] == Set.mystring[j]) return i+1;
     return 0;
   }
-  Standard_OutOfRange::Raise();
-  return 0;
+  throw Standard_OutOfRange();
 }
 
 // ----------------------------------------------------------------------------
@@ -464,8 +463,7 @@ Standard_Integer TCollection_AsciiString::FirstLocationNotInSet
     }
     return 0;
   }
-  Standard_OutOfRange::Raise();
-  return 0;
+  throw Standard_OutOfRange();
 }
 
 //----------------------------------------------------------------------------
@@ -474,10 +472,8 @@ Standard_Integer TCollection_AsciiString::FirstLocationNotInSet
 void TCollection_AsciiString::Insert(const Standard_Integer where,
                                      const Standard_Character what)
 {
-  if (where > mylength + 1 ) Standard_OutOfRange::Raise
-        ("TCollection_AsciiString::Insert : Parameter where is too big");
-  if (where < 1)             Standard_OutOfRange::Raise
-        ("TCollection_AsciiString::Insert : Parameter where is too small");
+  if (where > mylength + 1 ) throw Standard_OutOfRange("TCollection_AsciiString::Insert : Parameter where is too big");
+  if (where < 1)             throw Standard_OutOfRange("TCollection_AsciiString::Insert : Parameter where is too small");
   
   mystring = Reallocate (mystring, mylength + 2);
   if (where != mylength +1) {
@@ -513,8 +509,8 @@ void TCollection_AsciiString::Insert(const Standard_Integer where,
     }
   }
   else {
-    Standard_OutOfRange::Raise("TCollection_AsciiString::Insert : "
-                               "Parameter where is invalid");
+    throw Standard_OutOfRange("TCollection_AsciiString::Insert : "
+                              "Parameter where is invalid");
   }
 }
 
@@ -544,8 +540,8 @@ void TCollection_AsciiString::Insert(const Standard_Integer where,
     }
   }
   else {
-    Standard_OutOfRange::Raise("TCollection_AsciiString::Insert : "
-                               "Parameter where is too big");
+    throw Standard_OutOfRange("TCollection_AsciiString::Insert : "
+                              "Parameter where is too big");
   }
 }
 
@@ -555,7 +551,7 @@ void TCollection_AsciiString::Insert(const Standard_Integer where,
 void TCollection_AsciiString::InsertAfter(const Standard_Integer Index,
                                           const TCollection_AsciiString& what)
 {
-   if (Index < 0 || Index > mylength) Standard_OutOfRange::Raise();
+   if (Index < 0 || Index > mylength) throw Standard_OutOfRange();
    Insert(Index+1,what);
 }
 
@@ -565,7 +561,7 @@ void TCollection_AsciiString::InsertAfter(const Standard_Integer Index,
 void TCollection_AsciiString::InsertBefore(const Standard_Integer Index,
                                            const TCollection_AsciiString& what)
 {
-   if (Index < 1 || Index > mylength) Standard_OutOfRange::Raise();
+   if (Index < 1 || Index > mylength) throw Standard_OutOfRange();
    Insert(Index,what);
 }
 
@@ -578,9 +574,8 @@ Standard_Boolean TCollection_AsciiString::IsEqual
   if (other) {
     return ( strncmp( other, mystring, mylength+1 ) == 0 );
   }
-  Standard_NullObject::Raise("TCollection_AsciiString::Operator == "
+  throw Standard_NullObject("TCollection_AsciiString::Operator == "
                              "Parameter 'other'");
-  return Standard_False;
 }
 
 // ----------------------------------------------------------------------------
@@ -630,9 +625,8 @@ Standard_Boolean TCollection_AsciiString::IsDifferent
   if (other) {
     return ( strncmp( other, mystring, mylength+1 ) != 0 );
   }
-  Standard_NullObject::Raise("TCollection_AsciiString::Operator != "
+  throw Standard_NullObject("TCollection_AsciiString::Operator != "
                             "Parameter 'other'");
-  return Standard_False;
 }
 
 // ----------------------------------------------------------------------------
@@ -655,9 +649,8 @@ Standard_Boolean TCollection_AsciiString::IsLess
   if (other) {
     return ( strncmp( mystring, other, mylength+1 ) < 0 );
   }
-  Standard_NullObject::Raise("TCollection_AsciiString::Operator < "
-                             "Parameter 'other'");
-  return Standard_False;
+  throw Standard_NullObject("TCollection_AsciiString::Operator < "
+                            "Parameter 'other'");
 }
 
 // ----------------------------------------------------------------------------
@@ -678,9 +671,8 @@ Standard_Boolean TCollection_AsciiString::IsGreater
   if (other) {
     return ( strncmp( mystring, other, mylength+1 ) > 0 );
   }
-  Standard_NullObject::Raise("TCollection_AsciiString::Operator > "
-                             "Parameter 'other'");
-  return Standard_False;
+  throw Standard_NullObject("TCollection_AsciiString::Operator > "
+                            "Parameter 'other'");
 }
 
 // ----------------------------------------------------------------------------
@@ -729,8 +721,7 @@ Standard_Integer TCollection_AsciiString::IntegerValue()const
   Standard_Integer value = (Standard_Integer)strtol(mystring,&ptr,10); 
   if (ptr != mystring) return value;
 
-  Standard_NumericError::Raise("TCollection_AsciiString::IntegerValue");
-  return 0;
+  throw Standard_NumericError("TCollection_AsciiString::IntegerValue");
 }
 
 // ----------------------------------------------------------------------------
@@ -795,7 +786,7 @@ void TCollection_AsciiString::LeftJustify(const Standard_Integer Width,
      mystring[mylength] = '\0';
    }
    else if (Width < 0) {
-     Standard_NegativeValue::Raise();
+     throw Standard_NegativeValue();
    }
 }
 
@@ -817,8 +808,7 @@ Standard_Integer TCollection_AsciiString::Location
      }
      return 0 ;
    }
-   Standard_OutOfRange::Raise();
-   return 0 ;
+   throw Standard_OutOfRange();
 }
 
 //------------------------------------------------------------------------
@@ -850,8 +840,7 @@ Standard_Integer TCollection_AsciiString::Location
     if (Find) return l+2;
     else      return 0;
   }
-  Standard_OutOfRange::Raise();
-  return 0;
+  throw Standard_OutOfRange();
 }
 
 // ----------------------------------------------------------------------------
@@ -880,8 +869,7 @@ Standard_Real TCollection_AsciiString::RealValue()const
   Standard_Real value = Strtod(mystring,&ptr);
   if (ptr != mystring) return value;
 
-  Standard_NumericError::Raise("TCollection_AsciiString::RealValue");
-  return value;
+  throw Standard_NumericError("TCollection_AsciiString::RealValue");
 }
 
 // ----------------------------------------------------------------------------
@@ -979,9 +967,9 @@ void TCollection_AsciiString::Remove (const Standard_Integer where,
    mystring[mylength] = '\0';
  }
  else {
-  Standard_OutOfRange::Raise("TCollection_AsciiString::Remove: "
-                             "Too many characters to erase or invalid "
-                             "starting value.");
+  throw Standard_OutOfRange("TCollection_AsciiString::Remove: "
+                            "Too many characters to erase or invalid "
+                            "starting value.");
  }
 }
 
@@ -1016,7 +1004,7 @@ void TCollection_AsciiString::RightJustify(const Standard_Integer Width,
     mystring[mylength] = '\0';
   }
   else if (Width < 0) {
-    Standard_NegativeValue::Raise();
+    throw Standard_NegativeValue();
   }
 }
 
@@ -1115,8 +1103,8 @@ void TCollection_AsciiString::SetValue(const Standard_Integer where,
     mystring[where-1] = what;
   }
   else {
-    Standard_OutOfRange::Raise("TCollection_AsciiString::SetValue : "
-                               "parameter where");
+    throw Standard_OutOfRange("TCollection_AsciiString::SetValue : "
+                              "parameter where");
   }
 }
 
@@ -1138,8 +1126,8 @@ void TCollection_AsciiString::SetValue(const Standard_Integer where,
    mystring[mylength] = '\0';
  }
  else {
-   Standard_OutOfRange::Raise("TCollection_AsciiString::SetValue : "
-                              "parameter where");
+   throw Standard_OutOfRange("TCollection_AsciiString::SetValue : "
+                             "parameter where");
  }
 }
 
@@ -1162,8 +1150,8 @@ void TCollection_AsciiString::SetValue(const Standard_Integer where,
    mystring[mylength] = '\0';
  }
  else {
-   Standard_OutOfRange::Raise("TCollection_AsciiString::SetValue : "
-                              "parameter where");
+   throw Standard_OutOfRange("TCollection_AsciiString::SetValue : "
+                             "parameter where");
  }
 }
 
@@ -1179,7 +1167,7 @@ void TCollection_AsciiString::Split(const Standard_Integer where,
     Trunc(where);
     return ;
   }
-  Standard_OutOfRange::Raise("TCollection_AsciiString::Split index");
+  throw Standard_OutOfRange("TCollection_AsciiString::Split index");
   return ;
 }
 
@@ -1194,9 +1182,7 @@ TCollection_AsciiString TCollection_AsciiString::Split
     Trunc(where);
     return res;
   }
-  Standard_OutOfRange::Raise("TCollection_AsciiString::Split index");
-  TCollection_AsciiString res;
-  return res;
+  throw Standard_OutOfRange("TCollection_AsciiString::Split index");
 }
 
 // ----------------------------------------------------------------------------
@@ -1209,7 +1195,7 @@ void TCollection_AsciiString::SubString(const Standard_Integer FromIndex,
 {
 
   if (ToIndex > mylength || FromIndex <= 0 || FromIndex > ToIndex )
-    Standard_OutOfRange::Raise();
+    throw Standard_OutOfRange();
   Standard_Integer newlength = ToIndex-FromIndex+1;
   res.mystring =Reallocate (res.mystring, newlength + 1);
   strncpy( res.mystring, mystring + FromIndex - 1, newlength );
@@ -1237,8 +1223,8 @@ TCollection_AsciiString TCollection_AsciiString::Token
                                          const Standard_Integer whichone) const
 {
   if (!separators)
-    Standard_NullObject::Raise("TCollection_AsciiString::Token : "
-                               "parameter 'separators'");
+    throw Standard_NullObject("TCollection_AsciiString::Token : "
+                              "parameter 'separators'");
 
   Standard_Integer theOne ;
   Standard_Integer StringIndex = 0 ;
@@ -1291,8 +1277,8 @@ TCollection_AsciiString TCollection_AsciiString::Token
 void TCollection_AsciiString::Trunc(const Standard_Integer ahowmany)
 {
   if (ahowmany < 0 || ahowmany > mylength)
-    Standard_OutOfRange::Raise("TCollection_AsciiString::Trunc : "
-                               "parameter 'ahowmany'");
+    throw Standard_OutOfRange("TCollection_AsciiString::Trunc : "
+                              "parameter 'ahowmany'");
   mylength = ahowmany;
   mystring[mylength] = '\0';
 }
@@ -1326,6 +1312,5 @@ Standard_Character TCollection_AsciiString::Value
  if (where > 0 && where <= mylength) {
    return mystring[where-1];
  }
- Standard_OutOfRange::Raise("TCollection_AsciiString::Value : parameter where");
- return '\0';
+ throw Standard_OutOfRange("TCollection_AsciiString::Value : parameter where");
 }
index 92e429a..0464a37 100644 (file)
@@ -113,7 +113,7 @@ inline TCollection_AsciiString TCollection_AsciiString::SubString(const Standard
                                                           const Standard_Integer ToIndex) const
 {
 
-  if (ToIndex > mylength || FromIndex <= 0 || FromIndex > ToIndex ) Standard_OutOfRange::Raise();
+  if (ToIndex > mylength || FromIndex <= 0 || FromIndex > ToIndex ) throw Standard_OutOfRange();
 
   return TCollection_AsciiString( &mystring [ FromIndex - 1 ] ,
                                   ToIndex - FromIndex + 1 ) ;
index e661124..2c00ec7 100644 (file)
@@ -168,7 +168,7 @@ void TCollection_BaseSequence::PInsertAfter(const Standard_Integer Index, const
 
 void TCollection_BaseSequence::PInsertAfter(const Standard_Integer Index, TCollection_BaseSequence& Other)
 {
-  if (Index < 0 || Index > Size) Standard_OutOfRange::Raise();
+  if (Index < 0 || Index > Size) throw Standard_OutOfRange();
   if (Other.Size == 0) return;
   if (Index == 0) 
     PPrepend( Other );
index 0b268c7..2830720 100644 (file)
@@ -36,7 +36,7 @@ TCollection_DataMap::TCollection_DataMap(const TCollection_DataMap& Other) :
        TCollection_BasicMap(Other.NbBuckets(),Standard_True)
 {
   if (!Other.IsEmpty())
-    Standard_DomainError::Raise("TCollection:Copy of DataMap");
+    throw Standard_DomainError("TCollection:Copy of DataMap");
 }
 
 //=======================================================================
@@ -201,8 +201,7 @@ const TheItem& TCollection_DataMap::Find(const TheKey& K) const
       }
     p = (TCollection_DataMapNode*) p->Next();
   }
-  Standard_NoSuchObject::Raise("TCollection_DataMap::Find");
-  return p->Value();
+  throw Standard_NoSuchObject("TCollection_DataMap::Find");
 }
 //=======================================================================
 //function : ChangeFind
@@ -219,8 +218,7 @@ TheItem& TCollection_DataMap::ChangeFind(const TheKey& K)
       }
     p = (TCollection_DataMapNode*)  p->Next();
   }
-  Standard_NoSuchObject::Raise("TCollection_DataMap::ChangeFind");
-  return p->Value();
+  throw Standard_NoSuchObject("TCollection_DataMap::ChangeFind");
 }
 //modified by NIZNHY-PKV Tue Jul 05 09:54:14 2011f
 //=======================================================================
index c6ea551..5ed4164 100644 (file)
@@ -39,7 +39,7 @@ TCollection_DoubleMap::TCollection_DoubleMap
        TCollection_BasicMap(Other.NbBuckets(),Standard_False)
 {
   if (Other.Extent() != 0)
-    Standard_DomainError::Raise("TCollection:Copy of DoubleMap");
+    throw Standard_DomainError("TCollection:Copy of DoubleMap");
 }
 
 //=======================================================================
@@ -139,13 +139,13 @@ void TCollection_DoubleMap::Bind(const TheKey1& K1, const TheKey2& K2)
   p = data1[k1];
   while (p) {
     if (Hasher1::IsEqual(p->Key1(),K1)) 
-      Standard_MultiplyDefined::Raise("DoubleMap:Bind");
+      throw Standard_MultiplyDefined("DoubleMap:Bind");
     p = (TCollection_DoubleMapNode*) p->Next();
   }
   p = data2[k2];
   while (p) {
     if (Hasher2::IsEqual(p->Key2(),K2)) 
-      Standard_MultiplyDefined::Raise("DoubleMap:Bind");
+      throw Standard_MultiplyDefined("DoubleMap:Bind");
     p = (TCollection_DoubleMapNode*)p->Next2();
   }
   p = new TCollection_DoubleMapNode(K1,K2,data1[k1],data2[k2]);
@@ -238,7 +238,7 @@ const TheKey2& TCollection_DoubleMap::Find1(const TheKey1& K1) const
     if (Hasher1::IsEqual(p1->Key1(),K1)) return p1->Key2();
     p1 = (TCollection_DoubleMapNode*) p1->Next();
   }
-  Standard_NoSuchObject::Raise("TCollection_DoubleMap::Find1");
+  throw Standard_NoSuchObject("TCollection_DoubleMap::Find1");
   return p1->Key2();
 }
 
@@ -258,7 +258,7 @@ const TheKey1& TCollection_DoubleMap::Find2(const TheKey2& K2) const
     if (Hasher2::IsEqual(p2->Key2(),K2)) return p2->Key1();
     p2 = (TCollection_DoubleMapNode*)p2->Next2();
   }
-  Standard_NoSuchObject::Raise("TCollection_DoubleMap::Find2");
+  throw Standard_NoSuchObject("TCollection_DoubleMap::Find2");
   return p2->Key1();
 }
 
index d3965c6..c46da4d 100644 (file)
@@ -108,7 +108,7 @@ TCollection_ExtendedString::TCollection_ExtendedString
 {
   if (theString == NULL)
   {
-    Standard_NullObject::Raise ("TCollection_ExtendedString : null parameter ");
+    throw Standard_NullObject("TCollection_ExtendedString : null parameter ");
   }
 
   if (isMultiByte)
@@ -140,7 +140,7 @@ TCollection_ExtendedString::TCollection_ExtendedString (const Standard_ExtString
 {
   if (theString == NULL)
   {
-    Standard_NullObject::Raise("TCollection_ExtendedString : null parameter ");
+    throw Standard_NullObject("TCollection_ExtendedString : null parameter ");
   }
 
   for (mylength = 0; theString[mylength] != '\0'; ++mylength) {}
@@ -159,7 +159,7 @@ TCollection_ExtendedString::TCollection_ExtendedString (const Standard_WideChar*
 {
   if (theStringUtf == NULL)
   {
-    Standard_NullObject::Raise ("TCollection_ExtendedString : null parameter ");
+    throw Standard_NullObject("TCollection_ExtendedString : null parameter ");
   }
 
   mystring = fromWideString<sizeof(Standard_WideChar)> (theStringUtf, mylength);
@@ -389,11 +389,11 @@ void TCollection_ExtendedString::Insert(const Standard_Integer where,
                                         const Standard_ExtCharacter what)
 {
   if (where > mylength + 1 )
-    Standard_OutOfRange::Raise("TCollection_ExtendedString::Insert : "
-                               "Parameter where is too big");
+    throw Standard_OutOfRange("TCollection_ExtendedString::Insert : "
+                              "Parameter where is too big");
   if (where < 0)
-    Standard_OutOfRange::Raise("TCollection_ExtendedString::Insert : "
-                               "Parameter where is negative");
+    throw Standard_OutOfRange("TCollection_ExtendedString::Insert : "
+                              "Parameter where is negative");
 
   if (mystring != NULL)
   {
@@ -441,8 +441,8 @@ void TCollection_ExtendedString::Insert(const Standard_Integer            where,
     }
   }
   else {
-    Standard_OutOfRange::Raise("TCollection_ExtendedString::Insert : "
-                               "Parameter where is too big");
+    throw Standard_OutOfRange("TCollection_ExtendedString::Insert : "
+                              "Parameter where is too big");
   }
 }
 
@@ -617,9 +617,9 @@ void TCollection_ExtendedString::Remove (const Standard_Integer where,
     mystring[mylength] =  '\0';
   }
   else
-    Standard_OutOfRange::Raise("TCollection_ExtendedString::Remove: "
-                               "Too many characters to erase or "
-                               "invalid starting value.");
+    throw Standard_OutOfRange("TCollection_ExtendedString::Remove: "
+                              "Too many characters to erase or "
+                              "invalid starting value.");
 }
 
 // ----------------------------------------------------------------------------
@@ -678,7 +678,7 @@ void TCollection_ExtendedString::SetValue(const Standard_Integer      where,
     mystring[where-1] = what;
   }
   else {
-    Standard_OutOfRange::Raise("TCollection_ExtendedString::SetValue : parameter where");
+    throw Standard_OutOfRange("TCollection_ExtendedString::SetValue : parameter where");
   }
 }
 
@@ -707,8 +707,8 @@ void TCollection_ExtendedString::SetValue
     mystring[mylength] =  '\0';
   }
   else
-    Standard_OutOfRange::Raise("TCollection_ExtendedString::SetValue : "
-                               "parameter where");
+    throw Standard_OutOfRange("TCollection_ExtendedString::SetValue : "
+                              "parameter where");
 }
 
 // ----------------------------------------------------------------------------
@@ -722,9 +722,7 @@ TCollection_ExtendedString TCollection_ExtendedString::Split
     Trunc(where);
     return res;
   }
-  Standard_OutOfRange::Raise("TCollection_ExtendedString::Split index");
-  TCollection_ExtendedString res;
-  return res;
+  throw Standard_OutOfRange("TCollection_ExtendedString::Split index");
 }
 
 // ----------------------------------------------------------------------------
@@ -736,8 +734,8 @@ TCollection_ExtendedString TCollection_ExtendedString::Token
 {
   TCollection_ExtendedString res;
   if (!separators)
-    Standard_NullObject::Raise("TCollection_ExtendedString::Token : "
-                               "parameter 'separators'");
+    throw Standard_NullObject("TCollection_ExtendedString::Token : "
+                              "parameter 'separators'");
   
   int                   i,j,k,l;
   Standard_PExtCharacter  buftmp = allocateExtChars (mylength);
@@ -819,8 +817,8 @@ Standard_ExtString TCollection_ExtendedString::ToExtString() const
 void TCollection_ExtendedString::Trunc(const Standard_Integer ahowmany)
 {
   if (ahowmany < 0 || ahowmany > mylength)
-    Standard_OutOfRange::Raise("TCollection_ExtendedString::Trunc : "
-                               "parameter 'ahowmany'");
+    throw Standard_OutOfRange("TCollection_ExtendedString::Trunc : "
+                              "parameter 'ahowmany'");
   mylength = ahowmany;
   mystring[mylength] =  '\0';
 }
@@ -835,9 +833,8 @@ Standard_ExtCharacter TCollection_ExtendedString::Value
    if(mystring) return mystring[where-1];
    else         return 0;
  }
- Standard_OutOfRange::Raise("TCollection_ExtendedString::Value : "
-                            "parameter where");
- return 0;
+ throw Standard_OutOfRange("TCollection_ExtendedString::Value : "
+                           "parameter where");
 }
 
 
index 90e203f..9f7843b 100644 (file)
@@ -125,7 +125,7 @@ void TCollection_HAsciiString::Center
                       (const Standard_Integer Width ,
                        const Standard_Character Filler) 
 {
-   if (Width < 0) Standard_NegativeValue::Raise();
+   if (Width < 0) throw Standard_NegativeValue();
    myString.Center(Width,Filler);
 }
 
@@ -158,7 +158,7 @@ Standard_Integer TCollection_HAsciiString::FirstLocationInSet
 {
    if (Length() == 0 || Set->Length() == 0) return 0;
    if (ToIndex > Length() || FromIndex <= 0 || FromIndex > ToIndex ) 
-                     Standard_OutOfRange::Raise();
+                     throw Standard_OutOfRange();
    return (myString.FirstLocationInSet(Set->String(),FromIndex,ToIndex));
 }
 
@@ -172,7 +172,7 @@ Standard_Integer TCollection_HAsciiString::FirstLocationNotInSet
 {
    if (Length() == 0 || Set->Length() == 0) return 0;
    if (ToIndex > Length() || FromIndex <= 0 || FromIndex > ToIndex ) 
-                     Standard_OutOfRange::Raise();
+                     throw Standard_OutOfRange();
    return (myString.FirstLocationNotInSet(Set->String(),FromIndex,ToIndex));
 }
 
@@ -211,7 +211,7 @@ void TCollection_HAsciiString::InsertAfter
 {
    Standard_Integer size1 = Length();
 #ifndef NOBOUNDCHECK
-   if (Index < 0 || Index > size1) Standard_OutOfRange::Raise();
+   if (Index < 0 || Index > size1) throw Standard_OutOfRange();
 #endif
    myString.InsertAfter(Index,S->String());
 }
@@ -224,7 +224,7 @@ void TCollection_HAsciiString::InsertBefore
 {
    Standard_Integer size1 = Length();
 #ifndef NOBOUNDCHECK
-   if (Index < 1 || Index > size1) Standard_OutOfRange::Raise();
+   if (Index < 1 || Index > size1) throw Standard_OutOfRange();
 #endif
    myString.InsertBefore(Index,S->String());
 }
@@ -294,7 +294,7 @@ Standard_Boolean TCollection_HAsciiString::IsAscii() const
 Standard_Boolean TCollection_HAsciiString::IsDifferent
        (const Handle(TCollection_HAsciiString)& S) const 
 {
-  if(S.IsNull()) Standard_NullObject::Raise("TCollection_HAsciiString::IsDifferent");
+  if(S.IsNull()) throw Standard_NullObject("TCollection_HAsciiString::IsDifferent");
   if(S->Length() != myString.Length() ) return Standard_True;
   return ( strncmp( myString.ToCString(), S->ToCString(), myString.Length() ) != 0 );
 }
@@ -305,7 +305,7 @@ Standard_Boolean TCollection_HAsciiString::IsDifferent
 Standard_Boolean TCollection_HAsciiString::IsSameString
        (const Handle(TCollection_HAsciiString)& S) const 
 {
-  if(S.IsNull()) Standard_NullObject::Raise("TCollection_HAsciiString::IsSameString");
+  if(S.IsNull()) throw Standard_NullObject("TCollection_HAsciiString::IsSameString");
   if ( myString.Length() == S->Length() )
     return ( strncmp( myString.ToCString(), S->ToCString(), myString.Length() ) == 0 );
   else
@@ -319,7 +319,7 @@ Standard_Boolean TCollection_HAsciiString::IsSameString
                     (const Handle(TCollection_HAsciiString)& S ,
                      const Standard_Boolean CaseSensitive) const 
 {
-  if(S.IsNull()) Standard_NullObject::Raise("TCollection_HAsciiString::IsSameString");
+  if(S.IsNull()) throw Standard_NullObject("TCollection_HAsciiString::IsSameString");
   return TCollection_AsciiString::IsSameString (myString, S->myString, CaseSensitive);
 }
 
@@ -337,7 +337,7 @@ void TCollection_HAsciiString::LeftAdjust ()
 void TCollection_HAsciiString::LeftJustify 
      (const Standard_Integer Width, const Standard_Character Filler)
 {
-   if (Width < 0) Standard_NegativeValue::Raise();
+   if (Width < 0) throw Standard_NegativeValue();
    myString.LeftJustify(Width,Filler);
 }
 
@@ -349,7 +349,7 @@ Standard_Integer TCollection_HAsciiString::Location
     const Standard_Integer FromIndex, const Standard_Integer ToIndex) const
 {
    if (ToIndex > Length() || FromIndex <= 0 || FromIndex > ToIndex ) 
-                      Standard_OutOfRange::Raise();
+                      throw Standard_OutOfRange();
    return myString.Location(N,C,FromIndex,ToIndex);
 }
 
@@ -362,7 +362,7 @@ Standard_Integer TCollection_HAsciiString::Location
 {
    if (Length() == 0 || S->Length() == 0) return 0;
    if (ToIndex > Length() || FromIndex <= 0 || FromIndex > ToIndex ) 
-                      Standard_OutOfRange::Raise();
+                      throw Standard_OutOfRange();
    return myString.Location(S->String(),FromIndex,ToIndex);
 }
 
@@ -440,7 +440,7 @@ void TCollection_HAsciiString::RightAdjust ()
 void TCollection_HAsciiString::RightJustify 
            (const Standard_Integer Width, const Standard_Character Filler)
 {
-   if (Width < 0) Standard_NegativeValue::Raise();
+   if (Width < 0) throw Standard_NegativeValue();
    myString.RightJustify(Width,Filler);
 }
 
index 83b4b51..3e15166 100644 (file)
@@ -41,7 +41,7 @@ TCollection_IndexedDataMap::TCollection_IndexedDataMap
   TCollection_BasicMap(Other.NbBuckets(),Standard_False)
 {
   if (Other.Extent() != 0)
-    Standard_DomainError::Raise("TCollection:Copy of non empty IndexedDataMap");
+    throw Standard_DomainError("TCollection:Copy of non empty IndexedDataMap");
 }
 
 //=======================================================================
@@ -177,8 +177,8 @@ void TCollection_IndexedDataMap::Substitute(const Standard_Integer I,
   while (p) {
     if (Hasher::IsEqual(p->Key1(),K1)) {
       if (p->Key2() != I)
-        Standard_DomainError::Raise("IndexedDataMap::Substitute : "
-                                    "Attempt to substitute existing key");
+        throw Standard_DomainError("IndexedDataMap::Substitute : "
+                                   "Attempt to substitute existing key");
       p->Key1() = K1;
       p->Value() = T;
       return;
@@ -271,7 +271,7 @@ const TheKey& TCollection_IndexedDataMap::FindKey(const Standard_Integer K2) con
     if (p2->Key2() == K2) return p2->Key1();
     p2 = (TCollection_IndexedDataMapNode*)p2->Next2();
   }
-  Standard_OutOfRange::Raise("IndexedDataMap : missing index !!!");
+  throw Standard_OutOfRange("IndexedDataMap : missing index !!!");
   return p2->Key1();
 }
 
@@ -292,7 +292,7 @@ const TheItem& TCollection_IndexedDataMap::FindFromIndex
     if (p2->Key2() == K2) return p2->Value();
     p2 = (TCollection_IndexedDataMapNode*)p2->Next2();
   }
-  Standard_OutOfRange::Raise("IndexedDataMap : missing index !!!");
+  throw Standard_OutOfRange("IndexedDataMap : missing index !!!");
   return p2->Value();
 }
 
@@ -312,7 +312,7 @@ TheItem& TCollection_IndexedDataMap::ChangeFromIndex(const Standard_Integer K2)
     if (p2->Key2() == K2) return p2->Value();
     p2 = (TCollection_IndexedDataMapNode*)p2->Next2();
   }
-  Standard_OutOfRange::Raise("IndexedDataMap : missing index !!!");
+  throw Standard_OutOfRange("IndexedDataMap : missing index !!!");
   return p2->Value();
 }
 
@@ -366,7 +366,7 @@ const TheItem& TCollection_IndexedDataMap::FindFromKey(const TheKey& K1) const
     if (Hasher::IsEqual(p1->Key1(),K1)) return p1->Value();
     p1 = (TCollection_IndexedDataMapNode*) p1->Next();
   }
-  Standard_OutOfRange::Raise("TCollection_IndexedDataMap::FindFromKey");
+  throw Standard_OutOfRange("TCollection_IndexedDataMap::FindFromKey");
   return p1->Value();
 }
 //=======================================================================
@@ -384,7 +384,7 @@ TheItem& TCollection_IndexedDataMap::ChangeFromKey(const TheKey& K1)
     if (Hasher::IsEqual(p1->Key1(),K1)) return p1->Value();
     p1 = (TCollection_IndexedDataMapNode*)p1->Next();
   }
-  Standard_OutOfRange::Raise("TCollection_IndexedDataMap::ChangeFromKey");
+  throw Standard_OutOfRange("TCollection_IndexedDataMap::ChangeFromKey");
   return p1->Value();
 }
 //modified by NIZNHY-PKV Tue Jul 05 08:37:03 2011f
index 0b25f3f..4740011 100644 (file)
@@ -179,8 +179,8 @@ void TCollection_IndexedMap::Substitute(const Standard_Integer I,
   while (p) {
     if (Hasher::IsEqual(p->Key1(),K1)) {
       if (p->Key2() != I)
-        Standard_DomainError::Raise("IndexedMap::Substitute : "
-                                    "Attempt to substitute existing key");
+        throw Standard_DomainError("IndexedMap::Substitute : "
+                                   "Attempt to substitute existing key");
       p->Key1() = K1;
       return;
     }
@@ -289,7 +289,7 @@ const TheKey& TCollection_IndexedMap::FindKey(const Standard_Integer K2) const
     if (p2->Key2() == K2) return p2->Key1();
     p2 = (TCollection_IndexedMapNode*)p2->Next2();
   }
-  Standard_OutOfRange::Raise("IndexedMap : missing index !!!");
+  throw Standard_OutOfRange("IndexedMap : missing index !!!");
   return p2->Key1();
 }
 
index 570619b..5174b39 100644 (file)
@@ -158,8 +158,7 @@ Standard_Integer TDF_Attribute::UntilTransaction() const
   if      (IsForgotten())   return myTransaction;
   else if (IsBackuped())  return myNext->myTransaction - 1;
   else if (IsValid())     return myLabelNode->Data()->Transaction();
-  Standard_DomainError::Raise("The attribute structure is wrong.");
-  return 0;
+  throw Standard_DomainError("The attribute structure is wrong.");
 }
 
 
@@ -253,7 +252,7 @@ void TDF_Attribute::Backup()
       aMess = "Attribute \"";
       aMess += DynamicType()->Name();
       aMess += "\" is changed outside transaction";
-      Standard_ImmutableObject::Raise(aMess.ToCString());
+      throw Standard_ImmutableObject(aMess.ToCString());
     }
 
     const Standard_Integer currentTransaction =
@@ -297,7 +296,7 @@ void TDF_Attribute::RemoveBackup()
 {
 #ifdef OCCT_DEBUG
   if (myBackup.IsNull())
-    Standard_DomainError::Raise("Impossible to remove a nonexistent backup.");
+    throw Standard_DomainError("Impossible to remove a nonexistent backup.");
 #endif
   myBackup->BeforeRemoval();
   myBackup->myLabelNode = NULL; // Absolutly necessary!
index 295fcc6..18a662c 100644 (file)
@@ -194,8 +194,7 @@ void TDF_CopyTool::CopyAttributes
        if (tAtt->IsInstance(sAtt->DynamicType()))
          aAttMap.Bind(sAtt,tAtt);
        else
-         Standard_TypeMismatch::Raise
-           ("TDF_CopyTool: Cannot paste to a different type attribute.");
+         throw Standard_TypeMismatch("TDF_CopyTool: Cannot paste to a different type attribute.");
       }
     }
   }
index 9ec23b4..f0fd8ff 100644 (file)
@@ -118,9 +118,9 @@ void TDF_Delta::BeforeOrAfterApply(const Standard_Boolean before) const
       cout<<"AttributeDelta type = "<<itr.Value()->DynamicType()->Name();
       cout<<"  Attribute type = "<<itr.Value()->Attribute()->DynamicType()->Name()<<endl;;
     if (before)
-      Standard_ConstructionError::Raise("BeforeUndo(): dead lock.");
+      cout<<"BeforeUndo(): dead lock."<<endl;
     else
-      Standard_ConstructionError::Raise("AfterUndo(): dead lock.");
+      cout<<"AfterUndo(): dead lock."<<endl;
     }
 #endif
     for (itr.Initialize(ADlist); itr.More(); itr.Next()) {
index f90da8a..13093a7 100644 (file)
@@ -38,7 +38,7 @@
 //=======================================================================
 void TDF_Label::Imported(const Standard_Boolean aStatus) const
 {
-  if (IsNull()) Standard_NullObject::Raise("A null Label has no status.");
+  if (IsNull()) throw Standard_NullObject("A null Label has no status.");
   if (myLabelNode->IsImported() != aStatus) {
     myLabelNode->Imported(aStatus);
     for (TDF_ChildIterator itr(*this, Standard_True);
@@ -57,7 +57,7 @@ Standard_Boolean TDF_Label::FindAttribute
 (const Standard_GUID& anID,
  Handle(TDF_Attribute)& anAttribute) const
 {
-  if (IsNull()) Standard_NullObject::Raise("A null Label has no attribute.");
+  if (IsNull()) throw Standard_NullObject("A null Label has no attribute.");
   TDF_AttributeIterator itr (myLabelNode); // Without removed attributes.
   for ( ; itr.More(); itr.Next()) {
     if (itr.Value()->ID() == anID) {
@@ -101,7 +101,7 @@ Standard_Boolean TDF_Label::FindAttribute
 
 Standard_Integer TDF_Label::Depth() const
 {
-  if (IsNull()) Standard_NullObject::Raise("A null Label has no depth.");
+  if (IsNull()) throw Standard_NullObject("A null Label has no depth.");
   return myLabelNode->Depth();
 }
 
@@ -120,7 +120,7 @@ Standard_Boolean TDF_Label::IsDescendant(const TDF_Label& aLabel) const
   TDF_LabelNode*   lp2 = myLabelNode;
 #ifdef OCCT_DEBUG
   if ((lp1 == NULL) || (lp2 == NULL))
-    Standard_NullObject::Raise("A null label has no ancestor nor descendant.");
+    throw Standard_NullObject("A null label has no ancestor nor descendant.");
 #endif
   if ((lp1 != NULL) && (lp2 != NULL)) {
     const Standard_Integer d1 = lp1->Depth();
@@ -143,7 +143,7 @@ Standard_Boolean TDF_Label::IsDescendant(const TDF_Label& aLabel) const
 
 const TDF_Label TDF_Label::Root() const
 {
-  if (IsNull()) Standard_NullObject::Raise("A null Label has no root.");
+  if (IsNull()) throw Standard_NullObject("A null Label has no root.");
   return myLabelNode->RootNode();
 }
 
@@ -155,7 +155,7 @@ const TDF_Label TDF_Label::Root() const
 
 Standard_Integer TDF_Label::NbChildren() const
 {
-  if (IsNull()) Standard_NullObject::Raise("A null Label has no children.");
+  if (IsNull()) throw Standard_NullObject("A null Label has no children.");
   Standard_Integer n = 0;
   if (myLabelNode->FirstChild() != NULL)
     for (TDF_ChildIterator itr(*this); itr.More(); itr.Next()) ++n;
@@ -173,9 +173,9 @@ TDF_Label TDF_Label::FindChild
  const Standard_Boolean create) const
 {
   if (IsNull())
-    Standard_NullObject::Raise("A null Label has no child.");
+    throw Standard_NullObject("A null Label has no child.");
   if (create && ((Depth()+1) & TDF_LabelNodeFlagsMsk))
-      Standard_OutOfRange::Raise("Depth value out of range");
+      throw Standard_OutOfRange("Depth value out of range");
 
   return FindOrAddChild(aTag,create);
 }
@@ -212,7 +212,7 @@ Standard_Boolean TDF_Label::IsAttribute(const Standard_GUID& anID) const
 
 Standard_Boolean TDF_Label::HasAttribute() const
 {
-  if (IsNull()) Standard_NullObject::Raise("A null Label has no attribute.");
+  if (IsNull()) throw Standard_NullObject("A null Label has no attribute.");
 
   if (!myLabelNode->FirstAttribute().IsNull()) {
     TDF_AttributeIterator itr (myLabelNode); // Without removed attributes.
@@ -229,7 +229,7 @@ Standard_Boolean TDF_Label::HasAttribute() const
 
 Standard_Integer TDF_Label::NbAttributes() const
 {
-  if (IsNull()) Standard_NullObject::Raise("A null Label has no attribute.");
+  if (IsNull()) throw Standard_NullObject("A null Label has no attribute.");
   Standard_Integer n = 0;
   if (!myLabelNode->FirstAttribute().IsNull())
     for (TDF_AttributeIterator itr (myLabelNode); itr.More(); itr.Next()) ++n;
@@ -247,7 +247,7 @@ Standard_Integer TDF_Label::NbAttributes() const
 
 Standard_Integer TDF_Label::Transaction() const
 {
-  if (IsNull()) Standard_NullObject::Raise("A null Label has no transaction.");
+  if (IsNull()) throw Standard_NullObject("A null Label has no transaction.");
   return myLabelNode->Data()->Transaction();
 }
 
@@ -540,15 +540,15 @@ void TDF_Label::AddToNode (const TDF_LabelNodePtr& toNode,
     aMess = "Attribute \"";
     aMess += anAttribute->DynamicType()->Name();
     aMess += "\" is added to label outside transaction";
-    Standard_ImmutableObject::Raise(aMess.ToCString());
+    throw Standard_ImmutableObject(aMess.ToCString());
   }
     
   if (!anAttribute->Label().IsNull())
-    Standard_DomainError::Raise("Attribute to add is already attached to a label.");
+    throw Standard_DomainError("Attribute to add is already attached to a label.");
   Handle(TDF_Attribute) dummyAtt;
   //if (Find(anAttribute->ID(),dummyAtt))  
   if (FindAttribute(anAttribute->ID(),dummyAtt))
-    Standard_DomainError::Raise("This label has already such an attribute.");
+    throw Standard_DomainError("This label has already such an attribute.");
 
   anAttribute->myTransaction = toNode->Data()->Transaction();  /// myData->Transaction();
   anAttribute->mySavedTransaction = 0;
@@ -579,12 +579,11 @@ void TDF_Label::ForgetFromNode (const TDF_LabelNodePtr& fromNode,
     aMess = "Attribute \"";
     aMess += anAttribute->DynamicType()->Name();
     aMess += "\" is removed from label outside transaction";
-    Standard_ImmutableObject::Raise(aMess.ToCString());
+    throw Standard_ImmutableObject(aMess.ToCString());
   }
     
   if (fromNode != anAttribute->Label().myLabelNode)
-    Standard_DomainError::Raise
-      ("Attribute to forget not attached to my label.");
+    throw Standard_DomainError("Attribute to forget not attached to my label.");
 
   Standard_Integer curTrans = fromNode->Data()->Transaction();
   if (!anAttribute->IsForgotten()) {
@@ -633,13 +632,11 @@ void TDF_Label::ResumeToNode (const TDF_LabelNodePtr& toNode,
                               const Handle(TDF_Attribute)& anAttribute) const
 {
   if (anAttribute.IsNull())
-    Standard_NullObject::Raise("The attribute is a null handle.");
+    throw Standard_NullObject("The attribute is a null handle.");
   if (!anAttribute->Label().IsNull())
-    Standard_NullObject::Raise
-      ("Cannot resume an attribute already attached to a label.");
+    throw Standard_NullObject("Cannot resume an attribute already attached to a label.");
   if (!anAttribute->IsForgotten()) 
-    Standard_DomainError::Raise
-      ("Cannot resume an unforgotten attribute.");
+    throw Standard_DomainError("Cannot resume an unforgotten attribute.");
 
   AddToNode(toNode, anAttribute); // vro
   anAttribute->Resume();
index 606f6f7..ef67054 100644 (file)
@@ -94,9 +94,9 @@ Standard_Integer TDF_Transaction::Open()
   cout<<"Transaction "<<myName<<" opens #"<<myDF->Transaction()+1<<endl;
 #endif
   if (IsOpen())
-    Standard_DomainError::Raise("This transaction is already open.");
+    throw Standard_DomainError("This transaction is already open.");
   if (myDF.IsNull())
-    Standard_NullObject::Raise("Null TDF_Data.");
+    throw Standard_NullObject("Null TDF_Data.");
   return myUntilTransaction = myDF->OpenTransaction();
 }
 
index 46f1df2..1f991c1 100644 (file)
@@ -62,7 +62,7 @@ TDF_Label TDataStd_Current::Get (const TDF_Label& access)
 //  TDF_Label current;
   Handle(TDataStd_Current) A;
   if (!access.Data()->Root().FindAttribute (TDataStd_Current::GetID(), A)) {
-    Standard_DomainError::Raise("TDataStd_Current::Get : not setted");
+    throw Standard_DomainError("TDataStd_Current::Get : not setted");
   }  
   return A->GetLabel();
 }
index 2ddfc1d..1acc960 100644 (file)
@@ -73,7 +73,7 @@ const Standard_GUID& TDataStd_Directory::GetID()
 Handle(TDataStd_Directory) TDataStd_Directory::New (const TDF_Label& L)
 {  
   if (L.HasAttribute()) {
-    Standard_DomainError::Raise("TDataStd_Directory::New : not an empty label");
+    throw Standard_DomainError("TDataStd_Directory::New : not an empty label");
   }
   Handle(TDataStd_Directory) A = new TDataStd_Directory ();
   L.AddAttribute(A);                        
index 36b846b..005e023 100644 (file)
@@ -61,7 +61,7 @@ Standard_Boolean TDataStd_NoteBook::Find (const TDF_Label& current,
 Handle(TDataStd_NoteBook) TDataStd_NoteBook::New (const TDF_Label& label)
 {  
   if (label.HasAttribute()) {
-    Standard_DomainError::Raise("TDataStd_NoteBook::New : not an empty label");
+    throw Standard_DomainError("TDataStd_NoteBook::New : not an empty label");
   }
   Handle(TDataStd_NoteBook) NB = new TDataStd_NoteBook ();  
   label.AddAttribute(NB);
index e8fbd71..1316ff4 100644 (file)
@@ -108,7 +108,7 @@ TDataStd_TreeNode::TDataStd_TreeNode () :
 Standard_Boolean TDataStd_TreeNode::Append (const Handle(TDataStd_TreeNode)& TN)
 {  
   if (!(TN->ID() == myTreeID) )
-    Standard_DomainError::Raise("TDataStd_TreeNode::Append : uncompatible GUID");
+    throw Standard_DomainError("TDataStd_TreeNode::Append : uncompatible GUID");
 
   Handle(TDataStd_TreeNode) bid;
   TN->SetNext(bid); // Deconnects from next.
@@ -138,7 +138,7 @@ Standard_Boolean TDataStd_TreeNode::Append (const Handle(TDataStd_TreeNode)& TN)
 Standard_Boolean TDataStd_TreeNode::Prepend (const Handle(TDataStd_TreeNode)& TN)
 {  
   if (!(TN->ID() == myTreeID) ) 
-    Standard_DomainError::Raise("TDataStd_TreeNode::Prepend : uncompatible GUID");
+    throw Standard_DomainError("TDataStd_TreeNode::Prepend : uncompatible GUID");
 
   Handle(TDataStd_TreeNode) bid;
   TN->SetPrevious(bid);
@@ -163,7 +163,7 @@ Standard_Boolean TDataStd_TreeNode::Prepend (const Handle(TDataStd_TreeNode)& TN
 Standard_Boolean TDataStd_TreeNode::InsertBefore (const Handle(TDataStd_TreeNode)& TN)
 {
   if (!(TN->ID() == myTreeID) ) 
-    Standard_DomainError::Raise("TDataStd_TreeNode::InsertBefore : uncompatible GUID");
+    throw Standard_DomainError("TDataStd_TreeNode::InsertBefore : uncompatible GUID");
 
   TN->SetFather(Father());
   TN->SetPrevious(Previous());
@@ -186,7 +186,7 @@ Standard_Boolean TDataStd_TreeNode::InsertBefore (const Handle(TDataStd_TreeNode
 Standard_Boolean TDataStd_TreeNode::InsertAfter (const Handle(TDataStd_TreeNode)& TN)
 {
   if (!(TN->ID() == myTreeID) ) 
-    Standard_DomainError::Raise("TDataStd_TreeNode::InsertAfter : uncompatible GUID");
+    throw Standard_DomainError("TDataStd_TreeNode::InsertAfter : uncompatible GUID");
   
   if (HasFather() && !HasNext())
     Father()->SetLast(TN);
index 7941155..37a9e73 100644 (file)
@@ -85,7 +85,7 @@ const TCollection_ExtendedString& TDataStd_Variable::Name () const
 {
   Handle(TDataStd_Name) N;
   if (!Label().FindAttribute(TDataStd_Name::GetID(),N)) {
-    Standard_DomainError::Raise("TDataStd_Variable::Name : invalid model");
+    throw Standard_DomainError("TDataStd_Variable::Name : invalid model");
   }
   return N->Get();
 }
@@ -109,7 +109,7 @@ Handle(TDataStd_Real) TDataStd_Variable::Real() const
 {
   Handle(TDataStd_Real) R;
   if (!Label().FindAttribute(TDataStd_Real::GetID(),R)) {
-    Standard_DomainError::Raise("TDataStd_Variable::Real : invalid model");
+    throw Standard_DomainError("TDataStd_Variable::Real : invalid model");
   }
   return R;
 }
@@ -140,7 +140,7 @@ Standard_Real TDataStd_Variable::Get () const
 {  
   Handle(TDataStd_Real) R;
   if (!Label().FindAttribute(TDataStd_Real::GetID(),R)) {
-    Standard_DomainError::Raise("TDataStd_Variable::Get : invalid model");
+    throw Standard_DomainError("TDataStd_Variable::Get : invalid model");
   }
   return R->Get();
 }
@@ -177,7 +177,7 @@ void TDataStd_Variable::Desassign () const
 {  
   Handle(TDataStd_Expression) E;
   if (!Label().FindAttribute(TDataStd_Expression::GetID(),E)) {
-    Standard_DomainError::Raise("TDataStd_Variable::Deassign");
+    throw Standard_DomainError("TDataStd_Variable::Deassign");
   }   
   Label().ForgetAttribute(E);
 }
@@ -191,7 +191,7 @@ Handle(TDataStd_Expression) TDataStd_Variable::Expression () const
 {
   Handle(TDataStd_Expression) E;
   if (!Label().FindAttribute(TDataStd_Expression::GetID(),E)) {
-    Standard_DomainError::Raise("TDataStd_Variable::GetExpression");
+    throw Standard_DomainError("TDataStd_Variable::GetExpression");
   }
   return E;
 }
index bf476b4..2f31cf4 100644 (file)
@@ -399,7 +399,7 @@ TDataXtd_GeometryEnum  TDataXtd_Geometry::Type (const Handle(TNaming_NamedShape)
       }
 #ifdef OCCT_DEBUG
       else {
-       Standard_Failure::Raise("curve Null dans TDataXtd_Geometry");
+       throw Standard_Failure("curve Null dans TDataXtd_Geometry");
       }
 #endif
     }
@@ -420,7 +420,7 @@ TDataXtd_GeometryEnum  TDataXtd_Geometry::Type (const Handle(TNaming_NamedShape)
       } 
 #ifdef OCCT_DEBUG
       else {
-       Standard_Failure::Raise("surface Null dans TDataXtd_Geometry");
+       throw Standard_Failure("surface Null dans TDataXtd_Geometry");
       }
 #endif
       break;
index 76ba7cb..aafd1ae 100644 (file)
@@ -66,7 +66,7 @@ Standard_Boolean TDataXtd_Shape::Find (const TDF_Label& current,
 Handle(TDataXtd_Shape) TDataXtd_Shape::New (const TDF_Label& label)
 {  
   if (label.HasAttribute()) {
-    Standard_DomainError::Raise("TDataXtd_Shape::New : not an empty label");
+    throw Standard_DomainError("TDataXtd_Shape::New : not an empty label");
   }
   Handle(TDataXtd_Shape) A = new TDataXtd_Shape ();  
   label.AddAttribute(A);                     
index 681abe2..017f99b 100644 (file)
@@ -179,7 +179,7 @@ void TDocStd_Application::WritingFormats(TColStd_SequenceOfAsciiString &theForma
 Standard_Integer TDocStd_Application::NbDocuments() const
 {
   if (!CDF_Session::Exists())
-    Standard_DomainError::Raise("TDocStd_Application::NbDocuments");
+    throw Standard_DomainError("TDocStd_Application::NbDocuments");
   Handle(CDF_Session) S = CDF_Session::CurrentSession();
   return S->Directory()->Length();
 }
@@ -192,7 +192,7 @@ Standard_Integer TDocStd_Application::NbDocuments() const
 void TDocStd_Application::GetDocument(const Standard_Integer index,Handle(TDocStd_Document)& aDoc) const
 {
   if (!CDF_Session::Exists())
-    Standard_DomainError::Raise("TDocStd_Application::NbDocuments");
+    throw Standard_DomainError("TDocStd_Application::NbDocuments");
   Handle(CDF_Session) S = CDF_Session::CurrentSession();
   CDF_DirectoryIterator it (S->Directory());
   Standard_Integer current = 0;
@@ -300,14 +300,13 @@ PCDM_ReaderStatus TDocStd_Application::Open(const TCollection_ExtendedString& pa
     CDF_Application::Open(D);
     aDoc = D;
   }
-  catch (Standard_Failure) {
+  catch (Standard_Failure const& anException) {
 //    status = GetRetrieveStatus();
-    Handle(Standard_Failure) F = Standard_Failure::Caught();
-    if (!F.IsNull() && !MessageDriver().IsNull()) {
+    if (!MessageDriver().IsNull()) {
 //      Standard_SStream aMsg;
 //      aMsg << Standard_Failure::Caught() << endl;
 //      cout << "TDocStd_Application::Open(): " << aMsg.rdbuf()->str() << endl;
-      TCollection_ExtendedString aString (F->GetMessageString());
+      TCollection_ExtendedString aString (anException.GetMessageString());
       MessageDriver()->Write(aString.ToExtString());
     }
   }
@@ -335,12 +334,11 @@ PCDM_ReaderStatus TDocStd_Application::Open (Standard_IStream& theIStream, Handl
       theDoc = D;
     }
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    Handle(Standard_Failure) aFailure = Standard_Failure::Caught();
-    if (!aFailure.IsNull() && !MessageDriver().IsNull())
+    if (!MessageDriver().IsNull())
     {
-      TCollection_ExtendedString aFailureMessage (aFailure->GetMessageString());
+      TCollection_ExtendedString aFailureMessage (anException.GetMessageString());
       MessageDriver()->Write (aFailureMessage.ToExtString());
     }
   }
@@ -375,10 +373,9 @@ PCDM_StoreStatus TDocStd_Application::SaveAs(const Handle(TDocStd_Document)& D,c
     OCC_CATCH_SIGNALS
     storer.Realize();
   }
-  catch (Standard_Failure) {
-    Handle(Standard_Failure) F = Standard_Failure::Caught();
-    if (!F.IsNull() && !MessageDriver().IsNull()) {
-      TCollection_ExtendedString aString (F->GetMessageString());
+  catch (Standard_Failure const& anException) {
+    if (!MessageDriver().IsNull()) {
+      TCollection_ExtendedString aString (anException.GetMessageString());
       MessageDriver()->Write(aString.ToExtString());
     }
   }
@@ -415,12 +412,11 @@ PCDM_StoreStatus TDocStd_Application::SaveAs (const Handle(TDocStd_Document)& th
 
     return aDocStorageDriver->GetStoreStatus();
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    Handle(Standard_Failure) aFailure = Standard_Failure::Caught();
-    if (!aFailure.IsNull() && !MessageDriver().IsNull())
+    if (!MessageDriver().IsNull())
     {
-      TCollection_ExtendedString aString(aFailure->GetMessageString());
+      TCollection_ExtendedString aString(anException.GetMessageString());
       MessageDriver()->Write(aString.ToExtString());
     }
   }
@@ -440,10 +436,9 @@ PCDM_StoreStatus TDocStd_Application::Save (const Handle(TDocStd_Document)& D) {
       OCC_CATCH_SIGNALS
       storer.Realize();
     }
-    catch (Standard_Failure) {
-      Handle(Standard_Failure) F = Standard_Failure::Caught();
-      if (!F.IsNull() && !MessageDriver().IsNull()) {
-        TCollection_ExtendedString aString (F->GetMessageString());
+    catch (Standard_Failure const& anException) {
+      if (!MessageDriver().IsNull()) {
+        TCollection_ExtendedString aString (anException.GetMessageString());
         MessageDriver()->Write(aString.ToExtString());
       }
     }
@@ -486,10 +481,9 @@ PCDM_StoreStatus TDocStd_Application::SaveAs(const Handle(TDocStd_Document)& D,
       OCC_CATCH_SIGNALS
       storer.Realize();
     }
-    catch (Standard_Failure) {
-      Handle(Standard_Failure) F = Standard_Failure::Caught();
-      if (!F.IsNull() && !MessageDriver().IsNull()) {
-        TCollection_ExtendedString aString (F->GetMessageString());
+    catch (Standard_Failure const& anException) {
+      if (!MessageDriver().IsNull()) {
+        TCollection_ExtendedString aString (anException.GetMessageString());
         MessageDriver()->Write(aString.ToExtString());
       }
     }
@@ -534,12 +528,11 @@ PCDM_StoreStatus TDocStd_Application::SaveAs (const Handle(TDocStd_Document)& th
 
     return aDocStorageDriver->GetStoreStatus();
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    Handle(Standard_Failure) aFailure = Standard_Failure::Caught();
-    if (!aFailure.IsNull() && !MessageDriver().IsNull())
+    if (!MessageDriver().IsNull())
     {
-      TCollection_ExtendedString aString(aFailure->GetMessageString());
+      TCollection_ExtendedString aString(anException.GetMessageString());
       MessageDriver()->Write(aString.ToExtString());
     }
   }
@@ -561,10 +554,9 @@ PCDM_StoreStatus TDocStd_Application::Save (const Handle(TDocStd_Document)& D,
       OCC_CATCH_SIGNALS
       storer.Realize(); 
     }
-    catch (Standard_Failure) {
-      Handle(Standard_Failure) F = Standard_Failure::Caught();
-      if (!F.IsNull() && !MessageDriver().IsNull()) {
-        TCollection_ExtendedString aString (F->GetMessageString());
+    catch (Standard_Failure const& anException) {
+      if (!MessageDriver().IsNull()) {
+        TCollection_ExtendedString aString (anException.GetMessageString());
         MessageDriver()->Write(aString.ToExtString());
       }
     }
index d9eb141..1e0f7f3 100644 (file)
@@ -241,7 +241,7 @@ void TDocStd_Document::NewCommand()
 {
 #ifdef OCCT_DEBUG_TRANS
   if (myUndoTransaction.IsOpen() && myData->Transaction() > 1) {
-    Standard_DomainError::Raise ("NewCommand : many open transactions");
+    throw Standard_DomainError("NewCommand : many open transactions");
   }
 #endif
 
@@ -271,7 +271,7 @@ Standard_Boolean TDocStd_Document::HasOpenCommand() const
 void TDocStd_Document::OpenCommand ()
 {
   if (!myIsNestedTransactionMode && myUndoTransaction.IsOpen()) {
-    Standard_DomainError::Raise("TDocStd_Document::OpenCommand : already open");
+    throw Standard_DomainError("TDocStd_Document::OpenCommand : already open");
   }
   OpenTransaction();
 //  if (myUndoLimit != 0) myUndoTransaction.Open();
index 88ecca5..b8e1daa 100644 (file)
@@ -91,7 +91,7 @@ const TDF_LabelMap& TDocStd_Modified::Get (const TDF_Label& access)
 {  
   Handle(TDocStd_Modified) MDF;
   if (!access.Root().FindAttribute (TDocStd_Modified::GetID(), MDF)) {
-    Standard_DomainError::Raise("TDocStd_Modified::Get : IsEmpty");
+    throw Standard_DomainError("TDocStd_Modified::Get : IsEmpty");
   }
   return MDF->Get();
 }
index 1b12f71..e6f82b2 100644 (file)
@@ -108,7 +108,7 @@ void TDocStd_MultiTransactionManager::OpenCommand() {
             "Can't start new application transaction while a "
             "previous one is not commited or aborted" << endl;
 #endif
-    Standard_Failure::Raise("Can't start new application transaction"
+    throw Standard_Failure("Can't start new application transaction"
                             "while a previous one is not commited or aborted");
   }
   myOpenTransaction = Standard_True;
index c47bcf1..bfa14f0 100644 (file)
@@ -51,7 +51,7 @@ void TDocStd_Owner::SetDocument (const Handle(TDF_Data)& indata,
     indata->Root().AddAttribute(A);
   }
   else {  
-    Standard_DomainError::Raise("TDocStd_Owner::SetDocument : already called");
+    throw Standard_DomainError("TDocStd_Owner::SetDocument : already called");
   }
 }
 
@@ -64,7 +64,7 @@ Handle(TDocStd_Document) TDocStd_Owner::GetDocument (const Handle(TDF_Data)& ofd
 {
   Handle(TDocStd_Owner) A;
   if (!ofdata->Root().FindAttribute (TDocStd_Owner::GetID(), A)) {
-    Standard_DomainError::Raise("TDocStd_Owner::GetDocument : document not found");
+    throw Standard_DomainError("TDocStd_Owner::GetDocument : document not found");
   }
   return A->GetDocument();
 }
index ee5c46f..b080339 100644 (file)
@@ -61,7 +61,7 @@ void TDocStd_XLinkIterator::Initialize(const Handle(TDocStd_Document)& DOC)
 
 void TDocStd_XLinkIterator::Next() 
 {
-  if (myValue == NULL) Standard_NoMoreObject::Raise("");
+  if (myValue == NULL) throw Standard_NoMoreObject("");
   else                 myValue = myValue->Next();
 }
 
index 6c82e2f..da951e4 100644 (file)
@@ -61,7 +61,7 @@ void TDocStd_XLinkTool::Copy (const TDF_Label& target,
   SOURCE = TDocStd_Document::Get(source);
   if (TARGET != SOURCE) {
     if (!TDF_Tool::IsSelfContained(source)) {
-      Standard_DomainError::Raise("TDocStd_XLinkTool::Copy : not self-contained");
+      throw Standard_DomainError("TDocStd_XLinkTool::Copy : not self-contained");
     }
   }
 
@@ -128,7 +128,7 @@ void TDocStd_XLinkTool::CopyWithLink (const TDF_Label& target,
 {  
   Handle(TDF_Reference) REF;
   if (target.FindAttribute(TDF_Reference::GetID(),REF)) {
-    Standard_DomainError::Raise(" TDocStd_CopyWithLink : already a ref");
+    throw Standard_DomainError(" TDocStd_CopyWithLink : already a ref");
   }
   Copy(target,source);
   if (isDone) {
@@ -159,7 +159,7 @@ void TDocStd_XLinkTool::UpdateLink (const TDF_Label& label)
 {
   Handle(TDF_Reference) REF;
   if (!label.FindAttribute(TDF_Reference::GetID(),REF)) {
-    Standard_DomainError::Raise(" TDocStd_XLinkTool::UpdateLink : not ref registred");
+    throw Standard_DomainError(" TDocStd_XLinkTool::UpdateLink : not ref registred");
   }
   TDocStd_XLinkTool XLinkTool;
   Copy (label,REF->Get());
index b2eb0ec..8a2938e 100644 (file)
@@ -421,9 +421,9 @@ Handle(TFunction_Driver) TFunction_IFunction::GetDriver(const Standard_Integer t
   Handle(TFunction_Driver) driver;
   Handle(TFunction_Function) func;
   if (!myLabel.FindAttribute(TFunction_Function::GetID(), func))
-    Standard_NoSuchObject::Raise("TFunction_IFunction::GetDriver(): A Function is not found attached to this label");
+    throw Standard_NoSuchObject("TFunction_IFunction::GetDriver(): A Function is not found attached to this label");
   if (!TFunction_DriverTable::Get()->FindDriver(func->GetDriverGUID(), driver, thread))
-    Standard_NoSuchObject::Raise("TFunction_IFunction::GetDriver(): A driver is not found for this ID");
+    throw Standard_NoSuchObject("TFunction_IFunction::GetDriver(): A driver is not found for this ID");
   driver->Init(myLabel);
   return driver;
 }
@@ -437,6 +437,6 @@ Handle(TFunction_GraphNode) TFunction_IFunction::GetGraphNode() const
 {
   Handle(TFunction_GraphNode) graphNode;
   if (!myLabel.FindAttribute(TFunction_GraphNode::GetID(), graphNode))
-    Standard_NoSuchObject::Raise("TFunction_IFunction::GetStatus(): A graph node is not found attached to this label");
+    throw Standard_NoSuchObject("TFunction_IFunction::GetStatus(): A graph node is not found attached to this label");
   return graphNode;
 }
index 697a8f0..89fccc1 100644 (file)
@@ -1096,7 +1096,7 @@ static Standard_Boolean  Generated (const TDF_Label&                L,
                                    const TNaming_ListOfNamedShape& Args)
 {
   if (Args.Extent() < 2) {
-    Standard_ConstructionError::Raise("TNaming_Name::Solve: => Generated");
+    throw Standard_ConstructionError("TNaming_Name::Solve: => Generated");
   }
   // First argument : label of generation
   // Next arguments : generators.
@@ -1303,7 +1303,7 @@ static Standard_Boolean Identity (const TDF_Label&                L,
                                   const TopAbs_ShapeEnum          ShapeType)
 {
   if (Args.Extent() > 2) {
-    Standard_ConstructionError::Raise("TNaming_Name::Solve");
+    throw Standard_ConstructionError("TNaming_Name::Solve");
     }
   if(!ValidArgs(Args)) return Standard_False;
   const Handle(TNaming_NamedShape)& A = Args.First();
@@ -1724,7 +1724,7 @@ static Standard_Boolean WireIN(const TDF_Label&                L,
   TopTools_IndexedMapOfShape aMapOfSh;
   TDF_LabelMap        aForbiden;
   if (Args.Extent() < 1 ) 
-    Standard_ConstructionError::Raise("TNaming_Name::Solve"); 
+    throw Standard_ConstructionError("TNaming_Name::Solve");
   const Handle(TNaming_NamedShape)& A = Args.First();
   TNaming_NamingTool::CurrentShape (Valid,aForbiden,A, aMapOfSh);
   if (aMapOfSh.Extent() != 1) return aResult;
@@ -1860,7 +1860,7 @@ static Standard_Boolean ShellIN(const TDF_Label&                L,
   TopTools_IndexedMapOfShape aMapOfSh; 
   TDF_LabelMap        aForbiden;
   if (Args.Extent() < 1 ) 
-    Standard_ConstructionError::Raise("TNaming_Name::Solve"); 
+    throw Standard_ConstructionError("TNaming_Name::Solve");
   const Handle(TNaming_NamedShape)& A = Args.First();
   TNaming_NamingTool::CurrentShape (Valid,aForbiden,A, aMapOfSh);
   if (aMapOfSh.Extent() != 1) return aResult;
@@ -2007,9 +2007,8 @@ static  Standard_CString NameTypeToString (const TNaming_NameType Type)
     case  TNaming_ORIENTATION         : return "ORIENTATION";
     case  TNaming_WIREIN              : return "WIREIN";
       default :
-        Standard_DomainError::Raise("TNaming_NameType; enum term unknown ");
+        throw Standard_DomainError("TNaming_NameType; enum term unknown ");
     }
-  return "";
 }
 #endif
 //=======================================================================
@@ -2058,7 +2057,7 @@ Standard_Boolean TNaming_Name::Solve(const TDF_Label&    aLab,
     }
   case TNaming_SUBSTRACTION: 
     {
-      Standard_NotImplemented::Raise();
+      throw Standard_NotImplemented();
 //      Done = Substraction (aLab,Valid,myArgs);
       break;
     }
index d09714f..c58441e 100644 (file)
@@ -472,7 +472,7 @@ const
 { 
   TDF_Label        Lab = into->Label();
   if (Lab.IsNull()) {
-    Standard_NullObject::Raise("TNaming_NamedShape::Paste");
+    throw Standard_NullObject("TNaming_NamedShape::Paste");
   }
   TNaming_Builder B(Lab);
 
@@ -638,7 +638,7 @@ static void UpdateFirstUseOrNextSameShape(TNaming_RefShape*& prs,
       ldn = cdn;
       cdn = cdn->NextSameShape(prs);
       if (ldn == cdn) {
-       Standard_ConstructionError::Raise("UpdateFirstUseOrNextSameShape");
+       throw Standard_ConstructionError("UpdateFirstUseOrNextSameShape");
        break;
       }
     }
@@ -660,7 +660,7 @@ void TNaming_Builder::Generated(const TopoDS_Shape& newShape)
   if (myAtt->myNode == 0L) myAtt->myEvolution = TNaming_PRIMITIVE;
   else {
     if (myAtt->myEvolution != TNaming_PRIMITIVE)
-      Standard_ConstructionError::Raise("TNaming_Builder : not same evolution");
+      throw Standard_ConstructionError("TNaming_Builder : not same evolution");
   }
 
   TNaming_RefShape* pos = 0L;
@@ -672,7 +672,7 @@ void TNaming_Builder::Generated(const TopoDS_Shape& newShape)
 #endif
     pns = myShapes->myMap.ChangeFind(newShape);
     if (pns->FirstUse()->myAtt  == myAtt.operator->()) {
-      Standard_ConstructionError::Raise("TNaming_Builder::Generate");
+      throw Standard_ConstructionError("TNaming_Builder::Generate");
     }
     TNaming_Node* pdn = new TNaming_Node(pos,pns);
     myAtt->Add(pdn);
@@ -699,7 +699,7 @@ void TNaming_Builder::Delete(const TopoDS_Shape& oldShape)
   if (myAtt->myNode == 0L) myAtt->myEvolution = TNaming_DELETE;
   else {
     if (myAtt->myEvolution != TNaming_DELETE)
-      Standard_ConstructionError::Raise("TNaming_Builder : not same evolution");
+      throw Standard_ConstructionError("TNaming_Builder : not same evolution");
   }
 
   TNaming_RefShape* pns = 0L;
@@ -730,7 +730,7 @@ void TNaming_Builder::Generated(const TopoDS_Shape& oldShape,
   if (myAtt->myNode == 0L) myAtt->myEvolution = TNaming_GENERATED;
   else {
     if (myAtt->myEvolution != TNaming_GENERATED)
-      Standard_ConstructionError::Raise("TNaming_Builder : not same evolution");
+      throw Standard_ConstructionError("TNaming_Builder : not same evolution");
   }
 
   if (oldShape.IsSame(newShape)) {
@@ -773,7 +773,7 @@ void TNaming_Builder::Modify(const TopoDS_Shape& oldShape,
   if (myAtt->myNode == 0L) myAtt->myEvolution = TNaming_MODIFY;
   else {
     if (myAtt->myEvolution != TNaming_MODIFY)
-      Standard_ConstructionError::Raise("TNaming_Builder : not same evolution");
+      throw Standard_ConstructionError("TNaming_Builder : not same evolution");
   }
 
   if (oldShape.IsSame(newShape)) {
@@ -815,7 +815,7 @@ void TNaming_Builder::Select (const TopoDS_Shape& S,
   if (myAtt->myNode == 0L) myAtt->myEvolution = TNaming_SELECTED;
   else {
     if (myAtt->myEvolution != TNaming_SELECTED)
-      Standard_ConstructionError::Raise("TNaming_Builder : not same evolution");
+      throw Standard_ConstructionError("TNaming_Builder : not same evolution");
   }
 
   TNaming_RefShape* pos;  
@@ -1340,7 +1340,7 @@ void TNaming_OldShapeIterator::Next()
 
 TDF_Label TNaming_OldShapeIterator::Label() const
 {  
-  if (myNode == 0L) Standard_NoSuchObject::Raise("TNaming_OldShapeIterator::Label");
+  if (myNode == 0L) throw Standard_NoSuchObject("TNaming_OldShapeIterator::Label");
   return myNode->Label();
   
 }
@@ -1352,7 +1352,7 @@ TDF_Label TNaming_OldShapeIterator::Label() const
 
 Handle(TNaming_NamedShape) TNaming_OldShapeIterator::NamedShape() const
 {  
-  if (myNode == 0L) Standard_NoSuchObject::Raise("TNaming_OldShapeIterator::Label");
+  if (myNode == 0L) throw Standard_NoSuchObject("TNaming_OldShapeIterator::Label");
   return myNode->myAtt;
 }
 //=======================================================================
@@ -1362,7 +1362,7 @@ Handle(TNaming_NamedShape) TNaming_OldShapeIterator::NamedShape() const
 
 const TopoDS_Shape& TNaming_OldShapeIterator::Shape() const
 {   
-  if(myNode == 0L) Standard_NoSuchObject::Raise("TNaming_OldShapeIterator::Shape"); 
+  if(myNode == 0L) throw Standard_NoSuchObject("TNaming_OldShapeIterator::Shape");
   return myNode->myOld->Shape();
 }
 
index 514aaf4..5fc0855 100644 (file)
@@ -56,7 +56,7 @@ TObj_Application::TObj_Application () : myIsError(Standard_False)
     Message_MsgFile::LoadFromString (TObj_TObj_msg, sizeof(TObj_TObj_msg) - 1);
     if (!Message_MsgFile::HasMsg ("TObj_Appl_SUnknownFailure"))
     {
-      Standard_ProgramError::Raise ("Critical Error - message resources for TObj_Application are invalid or undefined!");
+      throw Standard_ProgramError("Critical Error - message resources for TObj_Application are invalid or undefined!");
     }
   }
 
@@ -135,12 +135,12 @@ Standard_Boolean TObj_Application::LoadDocument
     {
       aStatus = Open (theSourceFile, theTargetDoc);
     }
-    catch (Standard_Failure)
-    {
+    catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
       ErrorMessage (Message_Msg("TObj_Appl_Exception") << 
-                    Standard_Failure::Caught()->GetMessageString());
+                    anException.GetMessageString());
 #endif
+      (void)anException;
     }
   }
   myIsError = aStatus != PCDM_RS_OK;
index e7466fc..2effe2c 100644 (file)
@@ -189,14 +189,13 @@ Standard_Boolean TObj_Model::Load (const TCollection_ExtendedString& theFile)
       {
         isInitOk = initNewModel(isFileEmpty);
       }
-      catch (Standard_Failure)
-      {
+      catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
-        Handle(Standard_Failure) anExc = Standard_Failure::Caught();
-        TCollection_ExtendedString aString(anExc->DynamicType()->Name());
-        aString = aString + ": " + anExc->GetMessageString();
+        TCollection_ExtendedString aString(anException.DynamicType()->Name());
+        aString = aString + ": " + anException.GetMessageString();
         Messenger()->Send(Message_Msg("TObj_Appl_Exception") << aString);
 #endif
+        (void)anException;
         Messenger()->Send(Message_Msg("TObj_M_WrongFile") << theFile,
                                 Message_Alarm);
       }
index 79b0183..b9a5d2e 100644 (file)
@@ -83,11 +83,10 @@ void TObj_TIntSparseArray::SetValue (const Standard_Size theId,
 {
   // check that modification is allowed
   if ( !Label().Data()->IsModificationAllowed() )
-    Standard_ImmutableObject::Raise
-      ("Attribute TObj_TIntSparseArray is changed outside transaction");
+    throw Standard_ImmutableObject("Attribute TObj_TIntSparseArray is changed outside transaction");
 
   if (theId < 1 || theValue < 1)
-    Standard_OutOfRange::Raise ("TObj_TIntSparseArray::SetValue");
+    throw Standard_OutOfRange("TObj_TIntSparseArray::SetValue");
 
   Standard_Integer anOld = AbsentValue;
   Standard_Boolean isOld = myVector.HasValue(theId);
@@ -128,11 +127,10 @@ void TObj_TIntSparseArray::UnsetValue (const Standard_Size theId)
 {
   // check that modification is allowed
   if ( !Label().Data()->IsModificationAllowed() )
-    Standard_ImmutableObject::Raise
-      ("Attribute TObj_TIntSparseArray is changed outside transaction");
+    throw Standard_ImmutableObject("Attribute TObj_TIntSparseArray is changed outside transaction");
 
   if (theId < 1)
-    Standard_OutOfRange::Raise ("TObj_TIntSparseArray::UnsetValue");
+    throw Standard_OutOfRange("TObj_TIntSparseArray::UnsetValue");
 
   Standard_Integer anOld = AbsentValue;
   Standard_Boolean isOld = myVector.HasValue(theId);
index e9274d6..5745080 100644 (file)
@@ -61,7 +61,7 @@ Handle(TPrsStd_AISPresentation) TPrsStd_AISPresentation::Set
   // create associated data (unless already there)
   Handle(TDataXtd_Presentation) aData = TDataXtd_Presentation::Set (theLabel, theDriver);
   if(aData.IsNull())
-    Standard_NoMoreObject::Raise (NO_MORE_OBJECT);
+    throw Standard_NoMoreObject(NO_MORE_OBJECT);
   if ( !theLabel.FindAttribute(TPrsStd_AISPresentation::GetID(), aPresentation) )
   {
     aPresentation = new TPrsStd_AISPresentation();
@@ -102,7 +102,7 @@ Handle(TDataXtd_Presentation) TPrsStd_AISPresentation::getData () const
 {
   Handle(TDataXtd_Presentation) aData;
   if (!Label().FindAttribute(TDataXtd_Presentation::GetID(), aData))
-      Standard_NoMoreObject::Raise (NO_MORE_OBJECT);
+      throw Standard_NoMoreObject(NO_MORE_OBJECT);
   return aData;
 }
 
index 437a485..45db314 100644 (file)
@@ -48,7 +48,7 @@ Handle(TPrsStd_AISViewer) TPrsStd_AISViewer::New (const TDF_Label& acces,
 {   
   Handle(TPrsStd_AISViewer) V;
   if (acces.Root().FindAttribute(TPrsStd_AISViewer::GetID(),V)) { 
-    Standard_DomainError::Raise("already done");
+    throw Standard_DomainError("already done");
   }
   V = new TPrsStd_AISViewer();
   V->SetInteractiveContext (new AIS_InteractiveContext(viewer));
@@ -76,7 +76,7 @@ Handle(TPrsStd_AISViewer) TPrsStd_AISViewer::New (const TDF_Label& acces,
 {   
   Handle(TPrsStd_AISViewer) V;
   if (acces.Root().FindAttribute(TPrsStd_AISViewer::GetID(),V)) { 
-    Standard_DomainError::Raise("already done");
+    throw Standard_DomainError("already done");
   }
   V = new TPrsStd_AISViewer();
   V->SetInteractiveContext (IC);
index 9ea0e33..b5f4e59 100644 (file)
@@ -1088,7 +1088,7 @@ void TPrsStd_ConstraintTools::ComputeConcentric(const Handle(TDataXtd_Constraint
 {
   Standard_Integer nbgeom = aConst->NbGeometries();
   if (nbgeom < 2) {
-    Standard_ProgramError::Raise ("TPrsStd_ConstraintTools::ComputeConcentric: at least 2 constraintes are needed");
+    throw Standard_ProgramError("TPrsStd_ConstraintTools::ComputeConcentric: at least 2 constraintes are needed");
   }
   if (!aConst->IsPlanar()) {
 #ifdef OCCT_DEBUG
@@ -1939,8 +1939,7 @@ void TPrsStd_ConstraintTools::ComputePlacement
 {
   Standard_Integer nbgeom = aConst->NbGeometries();
   if (nbgeom < 2) 
-    Standard_ProgramError::Raise
-      ("TPrsStd_ConstraintTools::ComputePlacement: at leat two constraints are needed");
+    throw Standard_ProgramError("TPrsStd_ConstraintTools::ComputePlacement: at leat two constraints are needed");
   
   TopoDS_Shape shape1,shape2 ;
   GetTwoShapes(aConst,shape1,shape2);
index 4ee4483..fc166fb 100644 (file)
@@ -185,7 +185,7 @@ public:
 
 gp_Pnt tsee_entity0::Pnt() const
 {
-  if (!Is0()) Standard_Failure::Raise("not 0d");
+  if (!Is0()) throw Standard_Failure("not 0d");
   gp_Pnt P; 
   if      (IsP()) P = myEPDS->Point(myEindex).Point();
   else if (IsV()) P = BRep_Tool::Pnt(TopoDS::Vertex(myEPDS->Shape(myEindex)));
index 5bbcbda..8bbe4dc 100644 (file)
@@ -22,10 +22,10 @@ TopOpeBRep_Bipoint::TopOpeBRep_Bipoint():myI1(0),myI2(0){}
 TopOpeBRep_Bipoint::TopOpeBRep_Bipoint
 (const Standard_Integer I1,const Standard_Integer I2):myI1(I1),myI2(I2){}
 Standard_Integer TopOpeBRep_Bipoint::I1() const {
-if(myI1<=0)Standard_ProgramError::Raise("TopOpeBRep_Bipoint I1=0");
+if(myI1<=0)throw Standard_ProgramError("TopOpeBRep_Bipoint I1=0");
 return myI1;
 }
 Standard_Integer TopOpeBRep_Bipoint::I2() const {
-if(myI2<=0)Standard_ProgramError::Raise("TopOpeBRep_Bipoint I2=0");
+if(myI2<=0)throw Standard_ProgramError("TopOpeBRep_Bipoint I2=0");
 return myI2;
 }
index c4752fb..90904af 100644 (file)
@@ -357,7 +357,7 @@ void TopOpeBRep_EdgesFiller::Face(const Standard_Integer ISI,const TopoDS_Shape&
 {
   if      (ISI == 1) myF1 = TopoDS::Face(F);
   else if (ISI == 2) myF2 = TopoDS::Face(F);
-  else Standard_Failure::Raise("Face(i,f) : ISI incorrect");
+  else throw Standard_Failure("Face(i,f) : ISI incorrect");
 }
 
 //=======================================================================
@@ -368,8 +368,7 @@ const TopoDS_Shape& TopOpeBRep_EdgesFiller::Face(const Standard_Integer ISI) con
 {
   if      (ISI == 1) return myF1;
   else if (ISI == 2) return myF2;
-  else Standard_Failure::Raise("Face(i) : ISI incorrect");
-  return myF1;
+  else throw Standard_Failure("Face(i) : ISI incorrect");
 }
 
 //=======================================================================
index 26c9018..ea29b29 100644 (file)
@@ -317,7 +317,7 @@ Standard_Boolean EdgesIntersector_checkT1D(const TopoDS_Edge& E1,const TopoDS_Ed
   //modified by NIZNHY-PKV Thu Nov  4 15:44:13 1999 to
 
   if (PC1.IsNull()) 
-    Standard_Failure::Raise("EdgesIntersector::Perform : no 2d curve");
+    throw Standard_Failure("EdgesIntersector::Perform : no 2d curve");
   
   myCurve1.Load(PC1);
   BRep_Tool::UVPoints(myEdge1,myFace1,pfirst,plast);
@@ -844,9 +844,7 @@ const TopoDS_Shape& TopOpeBRep_EdgesIntersector::Edge(const Standard_Integer Ind
 {
   if      ( Index == 1 ) return myEdge1;
   else if ( Index == 2 ) return myEdge2;
-  else Standard_Failure::Raise("TopOpeBRep_EdgesIntersector::Edge");
-  
-  return myEdge1;
+  else throw Standard_Failure("TopOpeBRep_EdgesIntersector::Edge");
 }
 
 //=======================================================================
@@ -857,9 +855,7 @@ const Geom2dAdaptor_Curve& TopOpeBRep_EdgesIntersector::Curve(const Standard_Int
 {
   if      ( Index == 1 ) return myCurve1;
   else if ( Index == 2 ) return myCurve2;
-  else Standard_Failure::Raise("TopOpeBRep_EdgesIntersector::Curve");
-  
-  return myCurve1;
+  else throw Standard_Failure("TopOpeBRep_EdgesIntersector::Curve");
 }
 
 //=======================================================================
@@ -870,9 +866,7 @@ const TopoDS_Shape& TopOpeBRep_EdgesIntersector::Face(const Standard_Integer Ind
 {
   if      ( Index == 1 ) return myFace1;
   else if ( Index == 2 ) return myFace2;
-  else Standard_Failure::Raise("TopOpeBRep_EdgesIntersector::Face");
-  
-  return myFace1;
+  else throw Standard_Failure("TopOpeBRep_EdgesIntersector::Face");
 }
 
 //=======================================================================
@@ -883,9 +877,7 @@ const BRepAdaptor_Surface& TopOpeBRep_EdgesIntersector::Surface(const Standard_I
 {
   if      ( Index == 1 ) return mySurface1->ChangeSurface();
   else if ( Index == 2 ) return mySurface2->ChangeSurface();
-  else Standard_Failure::Raise("TopOpeBRep_EdgesIntersector::Surface");
-  
-  return mySurface1->ChangeSurface();
+  else throw Standard_Failure("TopOpeBRep_EdgesIntersector::Surface");
 }
 
 //=======================================================================
@@ -979,7 +971,7 @@ const TopOpeBRep_Point2d& TopOpeBRep_EdgesIntersector::Point() const
 //=======================================================================
 const TopOpeBRep_Point2d& TopOpeBRep_EdgesIntersector::Point(const Standard_Integer I) const
 {
-  if (I<1 || I>mysp2d.Length()) Standard_Failure::Raise("TopOpeBRep_EdgesIntersector::Point(I)");
+  if (I<1 || I>mysp2d.Length()) throw Standard_Failure("TopOpeBRep_EdgesIntersector::Point(I)");
   return mysp2d(I);
 }
 
index df8cafe..279dff1 100644 (file)
@@ -44,7 +44,7 @@
 const IntRes2d_IntersectionSegment& TopOpeBRep_EdgesIntersector::Segment1() const
 {
   if ( ! IsPointOfSegment1() ) 
-    Standard_Failure::Raise("TopOpeBRep_EdgesIntersector : Not a segment point");
+    throw Standard_Failure("TopOpeBRep_EdgesIntersector : Not a segment point");
   Standard_Integer iseg = 1 + (myPointIndex - myNbPoints - 1) / 2;
   return mylseg.Value(iseg);
 }
@@ -234,7 +234,7 @@ TopOpeBRepDS_Transition TopOpeBRep_EdgesIntersector::Transition1(const Standard_
            staA = staINON;
          }
          else // Middle/Middle is impossible
-           Standard_Failure::Raise("TopOpeBRep_EdgesIntersector : Situation Unknown MM");
+           throw Standard_Failure("TopOpeBRep_EdgesIntersector : Situation Unknown MM");
        }
        else { // posother = Head or End
          Standard_Boolean opposite = IsOpposite1();
@@ -277,7 +277,7 @@ TopOpeBRepDS_Transition TopOpeBRep_EdgesIntersector::Transition1(const Standard_
          staA = staINON;
        }
        else {  // Middle is impossible
-         Standard_Failure::Raise("TopOpeBRep_EdgesIntersector : Situation Unknown M");
+         throw Standard_Failure("TopOpeBRep_EdgesIntersector : Situation Unknown M");
        }
       } // point is not a segment point
       
@@ -288,7 +288,7 @@ TopOpeBRepDS_Transition TopOpeBRep_EdgesIntersector::Transition1(const Standard_
     break;
     
   case IntRes2d_Undecided : 
-    Standard_Failure::Raise("TopOpeBRep_EdgesIntersector : TransitionType Undecided");
+    throw Standard_Failure("TopOpeBRep_EdgesIntersector : TransitionType Undecided");
     break;
     
   } // switch TransitionType()
@@ -407,7 +407,7 @@ Standard_Boolean TopOpeBRep_EdgesIntersector::IsVertex1(const Standard_Integer I
 const TopoDS_Shape& TopOpeBRep_EdgesIntersector::Vertex1(const Standard_Integer Index)
 {
   if ( ! IsVertex1(Index) )
-    Standard_Failure::Raise("TopOpeBRep_EdgesIntersector : Vertex1");
+    throw Standard_Failure("TopOpeBRep_EdgesIntersector : Vertex1");
   return myIsVertexVertex;
 }
 
index 905e140..41f465d 100644 (file)
@@ -153,9 +153,7 @@ const TopoDS_Shape& TopOpeBRep_FaceEdgeIntersector::Shape
 {
   if      ( Index == 1 ) return myFace;
   else if ( Index == 2 ) return myEdge;
-  else Standard_ProgramError::Raise("TopOpeBRep_FaceEdgeIntersector::Shape");
-
-  return myNullShape;
+  else throw Standard_ProgramError("TopOpeBRep_FaceEdgeIntersector::Shape");
 }
 
 //=======================================================================
@@ -330,11 +328,7 @@ TopOpeBRepDS_Transition TopOpeBRep_FaceEdgeIntersector::Transition
     return TR;
   }
 
-  else Standard_ProgramError::Raise("FEINT Transition Index");
-
-//  return(TopOpeBRepDS_Transition());
-  TopOpeBRepDS_Transition aValRet ;
-  return (aValRet);
+  else throw Standard_ProgramError("FEINT Transition Index");
 }
 
 //=======================================================================
index cbf111a..863c3c8 100644 (file)
@@ -466,7 +466,7 @@ void TopOpeBRep_FacesFiller::VP_PositionOnR(TopOpeBRep_LineInter& L)
        VP.EdgeON(E,paramC,Esi);
       }
       else {
-//     Standard_ProgramError::Raise("VP_Position projection failed on E");
+//     throw Standard_ProgramError("VP_Position projection failed on E");
        VP.ChangeKeep(Standard_False); // xpu051198
       }
     }
@@ -479,7 +479,7 @@ void TopOpeBRep_FacesFiller::VP_PositionOnR(TopOpeBRep_LineInter& L)
        VP.EdgeON(OOE,paramC,OOEsi);
       }
       else {
-//     Standard_ProgramError::Raise("VP_Position projection failed on OOE");
+//     throw Standard_ProgramError("VP_Position projection failed on OOE");
        VP.ChangeKeep(Standard_False); // xpu051198
       }
     }
@@ -593,8 +593,7 @@ const TopoDS_Face& TopOpeBRep_FacesFiller::Face(const Standard_Integer I) const
 {
   if      (I == 1) return myF1;
   else if (I == 2) return myF2;
-  Standard_ProgramError::Raise("FacesFiller::Face");
-  return myF1;
+  throw Standard_ProgramError("FacesFiller::Face");
 }
 
 //=======================================================================
index 6c72812..01ed90a 100644 (file)
@@ -303,7 +303,7 @@ Standard_Boolean TopOpeBRep_FacesIntersector::IsDone () const
 Standard_Boolean TopOpeBRep_FacesIntersector::SameDomain () const 
 {
   if (!myIntersectionDone) 
-    Standard_ProgramError::Raise("FacesIntersector : bad SameDomain");
+    throw Standard_ProgramError("FacesIntersector : bad SameDomain");
 
   Standard_Boolean sd = myIntersector.TangentFaces();
 
@@ -324,9 +324,7 @@ const TopoDS_Shape& TopOpeBRep_FacesIntersector::Face
 {
   if      ( Index == 1 ) return myFace1;
   else if ( Index == 2 ) return myFace2;
-  else Standard_ProgramError::Raise("TopOpeBRep_FacesIntersector::Face");
-
-  return myNullShape;
+  else throw Standard_ProgramError("TopOpeBRep_FacesIntersector::Face");
 }
 
 
@@ -340,8 +338,7 @@ Standard_Boolean TopOpeBRep_FacesIntersector::SurfacesSameOriented () const
   if ( SameDomain() ) {
     return mySurfacesSameOriented;
   }
-  Standard_ProgramError::Raise("FacesIntersector : bad SurfacesSameOriented");
-  return Standard_False;
+  throw Standard_ProgramError("FacesIntersector : bad SurfacesSameOriented");
 }
 
 //=======================================================================
index 099290a..78db513 100644 (file)
@@ -81,7 +81,7 @@ void  TopOpeBRep_GeomTool::MakeCurves
   case TopOpeBRep_RESTRICTION : 
   case TopOpeBRep_OTHERTYPE :
     default : 
-      Standard_ProgramError::Raise("TopOpeBRep_GeomTool::MakePrivateCurves");
+      throw Standard_ProgramError("TopOpeBRep_GeomTool::MakePrivateCurves");
     break;
   }
 
@@ -132,7 +132,7 @@ void  TopOpeBRep_GeomTool::MakeCurve
   case TopOpeBRep_RESTRICTION : 
   case TopOpeBRep_OTHERTYPE :
   default : 
-    Standard_ProgramError::Raise("TopOpeBRep_GeomTool::MakePrivateCurves");
+    throw Standard_ProgramError("TopOpeBRep_GeomTool::MakePrivateCurves");
     break;
   }
 }
index 965c81d..06d9d29 100644 (file)
@@ -72,7 +72,7 @@ void TopOpeBRep_Hctxee2d::SetEdges(const TopoDS_Edge& E1,const TopoDS_Edge& E2,
 
   Handle(Geom2d_Curve) PC1;
   PC1 = FC2D_CurveOnSurface(myEdge1,F1,first,last,tolpc);
-  if (PC1.IsNull()) Standard_Failure::Raise("TopOpeBRep_Hctxee2d::SetEdges : no 2d curve");
+  if (PC1.IsNull()) throw Standard_Failure("TopOpeBRep_Hctxee2d::SetEdges : no 2d curve");
   myCurve1.Load(PC1);
   BRep_Tool::UVPoints(myEdge1,F1,pfirst,plast);
   tole = BRep_Tool::Tolerance(myEdge1);
@@ -174,9 +174,7 @@ const TopoDS_Shape& TopOpeBRep_Hctxee2d::Edge(const Standard_Integer Index) cons
 {
   if      ( Index == 1 ) return myEdge1;
   else if ( Index == 2 ) return myEdge2;
-  else Standard_Failure::Raise("TopOpeBRep_Hctxee2d::Edge");
-  
-  return myEdge1;
+  else throw Standard_Failure("TopOpeBRep_Hctxee2d::Edge");
 }
 
 //=======================================================================
@@ -187,9 +185,7 @@ const Geom2dAdaptor_Curve& TopOpeBRep_Hctxee2d::Curve(const Standard_Integer Ind
 {
   if      ( Index == 1 ) return myCurve1;
   else if ( Index == 2 ) return myCurve2;
-  else Standard_Failure::Raise("TopOpeBRep_Hctxee2d::Curve");
-  
-  return myCurve1;
+  else throw Standard_Failure("TopOpeBRep_Hctxee2d::Curve");
 }
 
 //=======================================================================
@@ -200,7 +196,5 @@ const IntRes2d_Domain& TopOpeBRep_Hctxee2d::Domain(const Standard_Integer Index)
 {
   if      ( Index == 1 ) return myDomain1;
   else if ( Index == 2 ) return myDomain2;
-  else Standard_Failure::Raise("TopOpeBRep_Hctxee2d::Domain");
-  
-  return myDomain1;
+  else throw Standard_Failure("TopOpeBRep_Hctxee2d::Domain");
 }
index ea4adf6..6605a10 100644 (file)
@@ -163,9 +163,7 @@ const TopoDS_Face& TopOpeBRep_Hctxff2d::Face(const Standard_Integer Index) const
 {
   if      ( Index == 1 ) return myFace1;
   else if ( Index == 2 ) return myFace2;
-  else Standard_Failure::Raise("TopOpeBRep_Hctxff2d::Face");
-  
-  return myFace1;
+  else throw Standard_Failure("TopOpeBRep_Hctxff2d::Face");
 }
 
 //=======================================================================
@@ -176,9 +174,7 @@ Handle(BRepAdaptor_HSurface) TopOpeBRep_Hctxff2d::HSurface(const Standard_Intege
 {
   if      ( Index == 1 ) return mySurface1;
   else if ( Index == 2 ) return mySurface2;
-  else Standard_Failure::Raise("TopOpeBRep_Hctxff2d::HSurface");
-  
-  return mySurface1;
+  else throw Standard_Failure("TopOpeBRep_Hctxff2d::HSurface");
 }
 
 //=======================================================================
@@ -207,7 +203,5 @@ Standard_Boolean TopOpeBRep_Hctxff2d::FaceSameOrientedWithRef (const Standard_In
 {
   if      ( Index == 1 ) return myf1surf1F_sameoriented;
   else if ( Index == 2 ) return myf2surf1F_sameoriented;
-  else Standard_Failure::Raise("TopOpeBRep_Hctxff2d::FSO");
-
-  return Standard_True;
+  else throw Standard_Failure("TopOpeBRep_Hctxff2d::FSO");
 }
index 892229a..2dd9082 100644 (file)
@@ -520,7 +520,7 @@ Standard_Boolean TopOpeBRep_LineInter::ArcIsEdge(const Standard_Integer Index) c
 Standard_Boolean TopOpeBRep_LineInter::HasFirstPoint() const
 {
   if (myILG.IsNull())
-    Standard_ProgramError::Raise("TopOpeBRep_LineInter::HasFirstPoint sur line != GLine");
+    throw Standard_ProgramError("TopOpeBRep_LineInter::HasFirstPoint sur line != GLine");
   return myILG->HasFirstPoint();
 }
 
@@ -532,7 +532,7 @@ Standard_Boolean TopOpeBRep_LineInter::HasFirstPoint() const
 Standard_Boolean TopOpeBRep_LineInter::HasLastPoint() const
 {
   if (myILG.IsNull())
-    Standard_ProgramError::Raise("TopOpeBRep_LineInter::HasLastPoint sur line != GLine");
+    throw Standard_ProgramError("TopOpeBRep_LineInter::HasLastPoint sur line != GLine");
   return myILG->HasLastPoint();
 }
 
@@ -558,8 +558,7 @@ const TopOpeBRepDS_Transition& TopOpeBRep_LineInter::FaceFaceTransition
 {
   if (I == 1) return myLineTonF1;
   if (I == 2) return myLineTonF2;
-  Standard_ProgramError::Raise("TopOpeBRep_LineInter::FaceFaceTransition");
-  return myLineTonF1;
+  throw Standard_ProgramError("TopOpeBRep_LineInter::FaceFaceTransition");
 }
 
 //=======================================================================
index ceb2860..6287c0b 100644 (file)
@@ -58,11 +58,10 @@ mytolerance(0.)
 //=======================================================================
 const TopoDS_Vertex& TopOpeBRep_Point2d::Vertex(const Standard_Integer Index) const
 {
-  if (!IsVertex(Index)) Standard_Failure::Raise("TopOpeBRep_Point2d::Vertex");
+  if (!IsVertex(Index)) throw Standard_Failure("TopOpeBRep_Point2d::Vertex");
   if      (Index == 1) return myvertex1;
   else if (Index == 2) return myvertex2;
-  else Standard_Failure::Raise("TopOpeBRep_Point2d::Vertex");
-  return myvertex1;
+  else throw Standard_Failure("TopOpeBRep_Point2d::Vertex");
 }
 
 //=======================================================================
@@ -73,8 +72,7 @@ const TopOpeBRepDS_Transition& TopOpeBRep_Point2d::Transition(const Standard_Int
 {
   if      (Index == 1) return mytransition1;
   else if (Index == 2) return mytransition2;
-  else Standard_Failure::Raise("TopOpeBRep_Point2d::Transition");
-  return mytransition1;
+  else throw Standard_Failure("TopOpeBRep_Point2d::Transition");
 }
 
 //=======================================================================
@@ -85,8 +83,7 @@ TopOpeBRepDS_Transition& TopOpeBRep_Point2d::ChangeTransition(const Standard_Int
 {
   if      (Index == 1) return mytransition1;
   else if (Index == 2) return mytransition2;
-  else Standard_Failure::Raise("TopOpeBRep_Point2d::ChangeTransition");
-  return mytransition1;
+  else throw Standard_Failure("TopOpeBRep_Point2d::ChangeTransition");
 }
 
 //=======================================================================
index 8502f72..dbe09f2 100644 (file)
@@ -41,7 +41,7 @@ inline Standard_Boolean TopOpeBRep_Point2d::HasPint() const
 //=======================================================================
 inline const IntRes2d_IntersectionPoint& TopOpeBRep_Point2d::Pint() const
 {
-  if (!HasPint()) Standard_Failure::Raise("TopOpeBRep_Point2d::Pint");
+  if (!HasPint()) throw Standard_Failure("TopOpeBRep_Point2d::Pint");
   return mypint;
 }
 
@@ -53,7 +53,7 @@ inline void TopOpeBRep_Point2d::SetIsVertex(const Standard_Integer Index,const S
 {
   if      (Index == 1) myisvertex1 = B;
   else if (Index == 2) myisvertex2 = B;
-  else Standard_Failure::Raise("TopOpeBRep_Point2d::SetIsVertex");
+  else throw Standard_Failure("TopOpeBRep_Point2d::SetIsVertex");
 }
 
 //=======================================================================
@@ -64,8 +64,7 @@ inline Standard_Boolean TopOpeBRep_Point2d::IsVertex(const Standard_Integer Inde
 {
   if      (Index == 1) return myisvertex1;
   else if (Index == 2) return myisvertex2;
-  else Standard_Failure::Raise("TopOpeBRep_Point2d::IsVertex");
-  return myisvertex1;
+  else throw Standard_Failure("TopOpeBRep_Point2d::IsVertex");
 }
 
 //=======================================================================
@@ -76,7 +75,7 @@ inline void TopOpeBRep_Point2d::SetVertex(const Standard_Integer Index,const Top
 {
   if      (Index == 1) {myvertex1 = V; myisvertex1 = Standard_True;}
   else if (Index == 2) {myvertex2 = V; myisvertex2 = Standard_True;}
-  else Standard_Failure::Raise("TopOpeBRep_Point2d::SetVertex");
+  else throw Standard_Failure("TopOpeBRep_Point2d::SetVertex");
 }
 
 //=======================================================================
@@ -87,7 +86,7 @@ inline void TopOpeBRep_Point2d::SetTransition(const Standard_Integer Index,const
 {
   if      (Index == 1) mytransition1 = T;
   else if (Index == 2) mytransition2 = T;
-  else Standard_Failure::Raise("TopOpeBRep_Point2d::SetTransition");
+  else throw Standard_Failure("TopOpeBRep_Point2d::SetTransition");
 }
 
 //=======================================================================
@@ -98,7 +97,7 @@ inline void TopOpeBRep_Point2d::SetParameter(const Standard_Integer Index,const
 {
   if      (Index == 1) myparameter1 = P;
   else if (Index == 2) myparameter2 = P;
-  else Standard_Failure::Raise("TopOpeBRep_Point2d::SetParameter");
+  else throw Standard_Failure("TopOpeBRep_Point2d::SetParameter");
 }
 
 //=======================================================================
@@ -109,8 +108,7 @@ inline Standard_Real TopOpeBRep_Point2d::Parameter(const Standard_Integer Index)
 {
   if      (Index == 1) return myparameter1;
   else if (Index == 2) return myparameter2;
-  else Standard_Failure::Raise("TopOpeBRep_Point2d::Parameter");
-  return myparameter1;
+  else throw Standard_Failure("TopOpeBRep_Point2d::Parameter");
 }
 
 //=======================================================================
index 42b00bf..cfc3450 100644 (file)
@@ -130,9 +130,10 @@ TopAbs_State TopOpeBRep_FacesFiller::StBipVPonF
     if (Lrest.ArcIsEdge(2)) IArc = 2; 
     if (IArc == 0) {
 #ifdef OCCT_DEBUG
-      Standard_Failure::Raise("StBipVPonF");
-#endif
+      throw Standard_Failure("StBipVPonF");
+#else
       return TopAbs_UNKNOWN;
+#endif
     }
     Standard_Integer ISI = (IArc == 1) ? 2 : 1; 
     Standard_Integer sif = vpf.ShapeIndex();
@@ -355,7 +356,7 @@ Standard_Real TopOpeBRep_FacesFiller::VPParamOnER(const TopOpeBRep_VPointInter&
   tolee = tolee * 1.e2; //xpu290998 : PRO15369
   Standard_Real param, dist; Standard_Boolean projok = FUN_tool_projPonE(vp.Value(),tolee,E,param,dist);
   if (!projok) {
-    Standard_ProgramError::Raise("TopOpeBRep_FacesFiller::VPParamOnER");
+    throw Standard_ProgramError("TopOpeBRep_FacesFiller::VPParamOnER");
   }
   return param;
 }
index 305c023..12f799f 100644 (file)
@@ -159,9 +159,7 @@ const TopoDS_Shape& TopOpeBRep_ShapeIntersector::CurrentGeomShape
     }
   }
 
-  Standard_Failure::Raise("CurrentGeomShape : no intersection");
-  TopoDS_Shape* bid = new TopoDS_Shape();
-  return *bid;
+  throw Standard_Failure("CurrentGeomShape : no intersection");
 }
 //modified by NIZNHY-PKV Fri Sep 24 11:02:59 1999 from
 //=======================================================================
@@ -1017,9 +1015,7 @@ const TopoDS_Shape& TopOpeBRep_ShapeIntersector::Shape
   if      ( Index == 1 ) return myShape1;
   else if ( Index == 2 ) return myShape2;
 
-  Standard_Failure::Raise("ShapeIntersector : no shape");
-  TopoDS_Shape* bid = new TopoDS_Shape();
-  return *bid;
+  throw Standard_Failure("ShapeIntersector : no shape");
 }
 
 
index cfab427..26fb9b4 100644 (file)
@@ -104,9 +104,7 @@ const TopoDS_Shape& TopOpeBRep_ShapeIntersector2d::CurrentGeomShape
     }
   }
   
-  Standard_ProgramError::Raise("CurrentGeomShape : no intersection 2d");
-  TopoDS_Shape* bid = new TopoDS_Shape();
-  return *bid;
+  throw Standard_ProgramError("CurrentGeomShape : no intersection 2d");
 }
 
 
@@ -431,9 +429,7 @@ const TopoDS_Shape& TopOpeBRep_ShapeIntersector2d::Shape
   if      ( Index == 1 ) return myShape1;
   else if ( Index == 2 ) return myShape2;
   
-  Standard_ProgramError::Raise("ShapeIntersector : no shape");
-  TopoDS_Shape* bid = new TopoDS_Shape();
-  return *bid;
+  throw Standard_ProgramError("ShapeIntersector : no shape");
 }
 
 //=======================================================================
index ec7f720..c322cf9 100644 (file)
@@ -85,7 +85,7 @@ const TopoDS_Shape&  TopOpeBRep_VPointInter::ArcOnS2() const
 const TopoDS_Shape& TopOpeBRep_VPointInter::VertexOnS1() const
 {
   if ( !myPPOI->IsVertexOnS1() )
-    Standard_DomainError::Raise("TopOpeBRep_VPointInter::VertexOnS1");
+    throw Standard_DomainError("TopOpeBRep_VPointInter::VertexOnS1");
 
   const Handle(BRepTopAdaptor_HVertex)* HBRTAHV = (Handle(BRepTopAdaptor_HVertex)*)&(myPPOI->VertexOnS1());
   return (*HBRTAHV)->Vertex();
@@ -98,7 +98,7 @@ const TopoDS_Shape& TopOpeBRep_VPointInter::VertexOnS1() const
 const TopoDS_Shape& TopOpeBRep_VPointInter::VertexOnS2() const 
 {
   if ( !myPPOI->IsVertexOnS2() )
-    Standard_DomainError::Raise("TopOpeBRep_VPointInter::VertexOnS2");
+    throw Standard_DomainError("TopOpeBRep_VPointInter::VertexOnS2");
 
   const Handle(BRepTopAdaptor_HVertex)* HBRTAHV = (Handle(BRepTopAdaptor_HVertex)*)&(myPPOI->VertexOnS2());
   return (*HBRTAHV)->Vertex();
@@ -112,7 +112,7 @@ void TopOpeBRep_VPointInter::State(const TopAbs_State S,const Standard_Integer I
 {
   if      (I == 1) myState1 = S;
   else if (I == 2) myState2 = S;
-  else Standard_DomainError::Raise("TopOpeBRep_VPointInter::State");
+  else throw Standard_DomainError("TopOpeBRep_VPointInter::State");
   UpdateKeep();
 }
 
@@ -124,7 +124,7 @@ TopAbs_State TopOpeBRep_VPointInter::State(const Standard_Integer I) const
 {
   if      (I == 1) return myState1;
   else if (I == 2) return myState2;
-  else { Standard_DomainError::Raise("TopOpeBRep_VPointInter::State"); return TopAbs_UNKNOWN; }
+  else { throw Standard_DomainError("TopOpeBRep_VPointInter::State");}
 }
 
 //=======================================================================
@@ -151,8 +151,7 @@ const TopoDS_Shape& TopOpeBRep_VPointInter::EdgeON(const Standard_Integer I) con
 {
   if      (I == 1) return myEdgeON1;
   else if (I == 2) return myEdgeON2;
-  else Standard_DomainError::Raise("TopOpeBRep_VPointInter::EdgeON");
-  return myNullShape;
+  else throw Standard_DomainError("TopOpeBRep_VPointInter::EdgeON");
 }
 
 //=======================================================================
@@ -163,8 +162,7 @@ Standard_Real TopOpeBRep_VPointInter::EdgeONParameter(const Standard_Integer I)
 {
   if      (I == 1) return myEdgeONPar1;
   else if (I == 2) return myEdgeONPar2;
-  else Standard_DomainError::Raise("TopOpeBRep_VPointInter::EdgeONParameter");
-  return 0.;
+  else throw Standard_DomainError("TopOpeBRep_VPointInter::EdgeONParameter");
 }
 
 //=======================================================================
index 86d78d6..4b6d414 100644 (file)
@@ -91,7 +91,7 @@ TopAbs_State TopOpeBRep_VPointInterClassifier::VPointPosition
     }
     break;
   }
-  default : Standard_ProgramError::Raise("VPointClassifier : wrong Index");
+  default : throw Standard_ProgramError("VPointClassifier : wrong Index");
   }
 
   if (myState == TopAbs_ON) {
index 36417f0..3e5c5dc 100644 (file)
@@ -106,7 +106,7 @@ void  TopOpeBRep_VPointInterIterator::Next()
 const TopOpeBRep_VPointInter& TopOpeBRep_VPointInterIterator::CurrentVP()
 {
   if (!More())
-    Standard_ProgramError::Raise("TopOpeBRep_VPointInterIterator::CurrentVP");
+    throw Standard_ProgramError("TopOpeBRep_VPointInterIterator::CurrentVP");
   const TopOpeBRep_VPointInter& VP = myLineInter->VPoint(myVPointIndex);
   return VP;
 }
@@ -119,7 +119,7 @@ const TopOpeBRep_VPointInter& TopOpeBRep_VPointInterIterator::CurrentVP()
 TopOpeBRep_VPointInter& TopOpeBRep_VPointInterIterator::ChangeCurrentVP()
 {
   if (!More()) 
-    Standard_ProgramError::Raise("TopOpeBRep_VPointInterIterator::ChangeCurrentVP");
+    throw Standard_ProgramError("TopOpeBRep_VPointInterIterator::ChangeCurrentVP");
   TopOpeBRep_VPointInter& VP = myLineInter->ChangeVPoint(myVPointIndex);
   return VP;
 }
@@ -132,7 +132,7 @@ TopOpeBRep_VPointInter& TopOpeBRep_VPointInterIterator::ChangeCurrentVP()
 Standard_Integer TopOpeBRep_VPointInterIterator::CurrentVPIndex()const
 {
   if (!More()) 
-    Standard_ProgramError::Raise("TopOpeBRep_VPointInterIterator::CurrentVPIndex");
+    throw Standard_ProgramError("TopOpeBRep_VPointInterIterator::CurrentVPIndex");
   return myVPointIndex;
 }
 
index 1f3e62a..5cb52ed 100644 (file)
@@ -93,7 +93,7 @@ void TopOpeBRep_WPointInterIterator::Next()
 const TopOpeBRep_WPointInter& TopOpeBRep_WPointInterIterator::CurrentWP()
 {
   if (!More()) 
-    Standard_ProgramError::Raise("TopOpeBRep_WPointInterIterator::Current");
+    throw Standard_ProgramError("TopOpeBRep_WPointInterIterator::Current");
   const TopOpeBRep_WPointInter& WP = myLineInter->WPoint(myWPointIndex);
   return WP;
 }
index 4bb6cce..5d21732 100644 (file)
@@ -84,7 +84,7 @@ static void FUNBREP_Periodize
        parline = f;
       }
       else {
-       Standard_ProgramError::Raise("FUNBREP_Periodize");
+       throw Standard_ProgramError("FUNBREP_Periodize");
       }
     } // onfl
     else {
@@ -143,8 +143,7 @@ Standard_Boolean FUNBREP_topowalki_new
 //----------------------------------------------------------------------
 {
   if (L.TypeLineCurve() != TopOpeBRep_WALKING) {
-    Standard_ProgramError::Raise("FUNBREP_topowalki_new : line is not a walking");
-    return Standard_False;
+    throw Standard_ProgramError("FUNBREP_topowalki_new : line is not a walking");
   }
 
   Standard_Boolean CPIfound = !Ifound.IsNull();
@@ -247,8 +246,7 @@ Standard_Boolean FUNBREP_topowalki
 //----------------------------------------------------------------------
 {
   if (L.TypeLineCurve() != TopOpeBRep_WALKING) {
-    Standard_ProgramError::Raise("FUNBREP_topowalki : line is not a walking");
-    return Standard_False;
+    throw Standard_ProgramError("FUNBREP_topowalki : line is not a walking");
   }
 
 #ifdef OCCT_DEBUG
@@ -400,8 +398,7 @@ Standard_Boolean FUNBREP_topogline_new
 //----------------------------------------------------------------------
 {
   if (L.TypeLineCurve() == TopOpeBRep_WALKING) {
-    Standard_ProgramError::Raise("FUNBREP_topogline_new : line is not a GLine");
-    return Standard_False;
+    throw Standard_ProgramError("FUNBREP_topogline_new : line is not a GLine");
   }
 
   Standard_Integer iVP = VP.Index();
@@ -517,8 +514,7 @@ static Standard_Boolean FUNBREP_topogline
 //----------------------------------------------------------------------
 {
   if (L.TypeLineCurve() == TopOpeBRep_WALKING) {
-    Standard_ProgramError::Raise("FUNBREP_topogline : line is not a GLine");
-    return Standard_False;
+    throw Standard_ProgramError("FUNBREP_topogline : line is not a GLine");
   }
   
 #ifdef OCCT_DEBUG
index 0866e75..ef99be7 100644 (file)
@@ -95,7 +95,7 @@ TopOpeBRepDS_Transition TopOpeBRep_FacesFiller::GetEdgeTrans(const TopOpeBRep_VP
   Standard_Integer vpsind = VP.ShapeIndex();
   Standard_Boolean on2edges = (vpsind == 3);
   Standard_Boolean isvalid = on2edges || (vpsind == ShapeIndex);
-  if (!isvalid) Standard_Failure::Raise("TopOpeBRep_FacesFiller::GetEdgeTrans");
+  if (!isvalid) throw Standard_Failure("TopOpeBRep_FacesFiller::GetEdgeTrans");
   
   const TopoDS_Edge& edge = TopoDS::Edge(VP.Edge(ShapeIndex));
   Standard_Real paredge = VP.EdgeParameter(ShapeIndex);
index d8416f9..faa9b97 100644 (file)
@@ -212,7 +212,7 @@ const TopoDS_Shape& TopOpeBRepBuild_BlockBuilder::Element
 (const TopOpeBRepBuild_BlockIterator& BI) const
 {
   Standard_Boolean isbound = BI.More();
-  if (!isbound) Standard_Failure::Raise("OutOfRange");
+  if (!isbound) throw Standard_Failure("OutOfRange");
 
   Standard_Integer index = BI.Value();
   const TopoDS_Shape& E = myOrientedShapeMap(index);
@@ -223,7 +223,7 @@ const TopoDS_Shape& TopOpeBRepBuild_BlockBuilder::Element
 (const Standard_Integer index) const
 {
   Standard_Boolean isbound = myOrientedShapeMapIsValid.IsBound(index);
-  if (!isbound) Standard_Failure::Raise("OutOfRange");
+  if (!isbound) throw Standard_Failure("OutOfRange");
 
   const TopoDS_Shape& E = myOrientedShapeMap(index);
   return E;
@@ -233,7 +233,7 @@ Standard_Integer TopOpeBRepBuild_BlockBuilder::Element
 (const TopoDS_Shape& E) const
 {
   Standard_Boolean isbound = myOrientedShapeMap.Contains(E);
-  if (!isbound) Standard_Failure::Raise("OutOfRange");
+  if (!isbound) throw Standard_Failure("OutOfRange");
 
   Standard_Integer I = myOrientedShapeMap.FindIndex(E);
   return I;
index 4476134..c740f2d 100644 (file)
@@ -62,7 +62,7 @@ Standard_EXPORT Standard_Boolean DEBTEFOR(const TopOpeBRepBuild_Builder& B,const
 
 #ifdef OCCT_DEBUG
 Standard_EXPORT void FUN_RaiseON()
-{Standard_Failure::Raise("BuilderON");}
+{throw Standard_Failure("BuilderON");}
 static void FUN_cout(const TopoDS_Shape& eON)
 {
   TopAbs_Orientation oE = eON.Orientation();
index 8f6aa3f..dc15d35 100644 (file)
@@ -229,7 +229,7 @@ void TopOpeBRepBuild_Builder::End()
           Handle(Geom2d_Curve) C2D;
           if (!pcf) {
             C2D = FC2D_CurveOnSurface(E,F,f,l,tolpc);
-            if (C2D.IsNull()) Standard_ProgramError::Raise("TopOpeBRepBuild_Builder::End 1");
+            if (C2D.IsNull()) throw Standard_ProgramError("TopOpeBRepBuild_Builder::End 1");
             Standard_Real tolE = BRep_Tool::Tolerance(E);
             Standard_Real tol = Max(tolE,tolpc);
             B.UpdateEdge(E,C2D,F,tol);
index 02d0bac..da506ce 100644 (file)
@@ -556,7 +556,7 @@ Standard_Integer TopOpeBRepBuild_FaceBuilder::InitEdge()
 {
   const Handle(TopOpeBRepBuild_Loop)& L = myFaceAreaBuilder.Loop();
   if ( L->IsShape() )
-    Standard_DomainError::Raise("TopOpeBRepBuild_FaceBuilder:InitEdge");
+    throw Standard_DomainError("TopOpeBRepBuild_FaceBuilder:InitEdge");
   else {
     myBlockIterator = L->BlockIterator();
     myBlockIterator.Initialize();
@@ -592,11 +592,11 @@ void TopOpeBRepBuild_FaceBuilder::NextEdge()
 //=======================================================================
 const TopoDS_Shape& TopOpeBRepBuild_FaceBuilder::Edge() const
 {
-  if (!myBlockIterator.More()) Standard_Failure::Raise("OutOfRange");
+  if (!myBlockIterator.More()) throw Standard_Failure("OutOfRange");
 
   const Standard_Integer i = myBlockIterator.Value();
   Standard_Boolean isvalid = myBlockBuilder.ElementIsValid(i);
-  if (!isvalid) Standard_Failure::Raise("Edge not Valid");
+  if (!isvalid) throw Standard_Failure("Edge not Valid");
 
   const TopoDS_Shape& E = myBlockBuilder.Element(i);
   return E;
@@ -609,9 +609,10 @@ const TopoDS_Shape& TopOpeBRepBuild_FaceBuilder::Edge() const
 Standard_Integer TopOpeBRepBuild_FaceBuilder::EdgeConnexity(const TopoDS_Shape& /*E*/) const
 {
 #ifdef OCCT_DEBUG
-  Standard_ProgramError::Raise("FaceBuilder::EdgeConnexity management disactivated");
-#endif
+  throw Standard_ProgramError("FaceBuilder::EdgeConnexity management disactivated");
+#else
   return 0;
+#endif
 //  Standard_Boolean inmosi = myMOSI.IsBound(E);
 //  Standard_Integer nmosi = (inmosi) ? myMOSI.Find(E) : 0;
 //  return nmosi;
index 734f799..957133b 100644 (file)
@@ -213,8 +213,7 @@ Standard_Integer TopOpeBRepBuild_GTopo::GIndex(const TopAbs_State s) const
   if      (s == TopAbs_IN ) return 0;
   else if (s == TopAbs_ON ) return 1;
   else if (s == TopAbs_OUT) return 2;
-  else Standard_ProgramError::Raise("GIndex : bad input");
-  return 0;
+  else throw Standard_ProgramError("GIndex : bad input");
 }
 
 //=======================================================================
@@ -227,8 +226,7 @@ TopAbs_State TopOpeBRepBuild_GTopo::GState(const Standard_Integer i) const
   if      (i == 0) return TopAbs_IN;
   else if (i == 1) return TopAbs_ON; 
   else if (i == 2) return TopAbs_OUT;
-  else Standard_ProgramError::Raise("GState : bad input");
-  return TopAbs_UNKNOWN;
+  else throw Standard_ProgramError("GState : bad input");
 }
 
 //=======================================================================
@@ -341,7 +339,7 @@ void TopOpeBRepBuild_GTopo::StatesON(TopAbs_State& s1,
   else if ( Value(TopAbs_OUT,TopAbs_ON)) s2 = TopAbs_OUT;
 
   if ( s1 == TopAbs_UNKNOWN || s2 == TopAbs_UNKNOWN ) {
-    Standard_ProgramError::Raise("Gtopo : StatesON incorrect");
+    throw Standard_ProgramError("Gtopo : StatesON incorrect");
   }
 }
 
@@ -362,7 +360,7 @@ Standard_Boolean TopOpeBRepBuild_GTopo::IsToReverse1() const
     else IsToRev = (s1 == TopAbs_IN);
     return IsToRev;
   }
-//  Standard_ProgramError::Raise("GTopo::IsToReverse1");
+//  throw Standard_ProgramError("GTopo::IsToReverse1");
 //  return Standard_False; // dummy
 }
 
@@ -406,8 +404,7 @@ void TopOpeBRepBuild_GTopo::SetReverse(const Standard_Boolean rev)
 Standard_Boolean TopOpeBRepBuild_GTopo::Reverse() const 
 {
   if (myReverseForce) return myReverseValue;
-  Standard_ProgramError::Raise("GTopo::ReverseValue undefined");
-  return Standard_False; // dummy
+  throw Standard_ProgramError("GTopo::ReverseValue undefined");
 }
 
 //=======================================================================
index 98a9b7c..0a2bda8 100644 (file)
@@ -799,7 +799,7 @@ Standard_Boolean TopOpeBRepBuild_Builder::GParamOnReference(const TopoDS_Vertex&
   Standard_Real u,v; ElSLib::Parameters(pln,p3,u,v); gp_Pnt2d p2(u,v);
   Standard_Real f,l,tolpc; Handle(Geom2d_Curve) C2D;
   C2D = FC2D_CurveOnSurface(myEdgeReference,myFaceReference,f,l,tolpc);
-  if (C2D.IsNull()) Standard_ProgramError::Raise("TopOpeBRepBuild_Builder::GParamOnReference");
+  if (C2D.IsNull()) throw Standard_ProgramError("TopOpeBRepBuild_Builder::GParamOnReference");
   
 //  Standard_Real U;
   Geom2dAdaptor_Curve AC(C2D);
index ab790e8..09aff15 100644 (file)
@@ -983,7 +983,7 @@ static Standard_Boolean FUN_SplitEvisoONperiodicF(const Handle(TopOpeBRepDS_HDat
     Handle(Geom2d_Curve) PC = FC2D_CurveOnSurface(EG,FS,pf,pl,tol);
     if (PC.IsNull()) {
       TopoDS_Edge EEG = EG; Standard_Boolean ok = FUN_tool_pcurveonF(FS,EEG);
-      if (!ok) Standard_ProgramError::Raise("_Builder::SplitONVisolineonCyl");
+      if (!ok) throw Standard_ProgramError("_Builder::SplitONVisolineonCyl");
       Standard_Real f,l; PC = FC2D_CurveOnSurface(EEG,FS,f,l,tol);
     }
     
@@ -1045,7 +1045,7 @@ void TopOpeBRepBuild_Builder::SplitEvisoONperiodicF()
     TopoDS_Shape FF = FOR; FF.Orientation(TopAbs_FORWARD);
     
     Standard_Boolean ok = FUN_SplitEvisoONperiodicF(myDataStructure,FF);
-    if (!ok) Standard_ProgramError::Raise("_Builder::SplitONVisolineonCyl");
+    if (!ok) throw Standard_ProgramError("_Builder::SplitONVisolineonCyl");
   } // i
 }
 
index d4a2a5a..8f1ea4d 100644 (file)
@@ -314,8 +314,8 @@ void TopOpeBRepBuild_HBuilder::NextSection()
 
 const TopoDS_Shape& TopOpeBRepBuild_HBuilder::CurrentSection() const
 {
-  if (PITLE == NULL) Standard_ProgramError::Raise("no more CurrentSection");
-  if (!PITLE->More()) Standard_ProgramError::Raise("no more CurrentSection");
+  if (PITLE == NULL) throw Standard_ProgramError("no more CurrentSection");
+  if (!PITLE->More()) throw Standard_ProgramError("no more CurrentSection");
   return PITLE->Value();
 }
 
index c1349e1..63474e4 100644 (file)
@@ -69,7 +69,7 @@ extern Standard_Boolean TopOpeBRepBuild_GettraceKPB();
 static void FUN_Raise() {
 #ifdef OCCT_DEBUG
   cout<<"******************************ERROR"<<endl;
-  Standard_ProgramError::Raise("KPart.cxx");
+  throw Standard_ProgramError("KPart.cxx");
 #endif
 }
 
index af5ce58..a64c565 100644 (file)
@@ -196,8 +196,7 @@ static Standard_Boolean FUN_EstaEE(const TopoDS_Edge& E, const TopAbs_State sta,
   EinEE = FUN_PinE(P,EE);
   if      (sta == TopAbs_IN)  return EinEE;
   else if (sta == TopAbs_OUT) return !EinEE;
-  else Standard_ProgramError::Raise("TopOpeBRepBuild FUN_EstaEE on invalid state");
-  return EinEE;
+  else throw Standard_ProgramError("TopOpeBRepBuild FUN_EstaEE on invalid state");
 }
 
 //=======================================================================
@@ -538,7 +537,7 @@ void TopOpeBRepBuild_Builder::SplitSectionEdges()
 //     Standard_Real tolpc; MGhc2 PC = FC2D_CurveOnSurface(eon,F,esdF,f,l,tolpc);
        Standard_Real tolpc; MGhc2 PC = FC2D_CurveOnSurface(eon,F,esdF,f,l,tolpc,Standard_True);//xpu051198 :PRO15049
        hasPC = (!PC.IsNull());
-       if (!hasPC) Standard_ProgramError::Raise("TopOpeBRepBuild_Builder::SSE null PC on F");
+       if (!hasPC) throw Standard_ProgramError("TopOpeBRepBuild_Builder::SSE null PC on F");
        Standard_Real tol = Max(tolE,tolpc);
        BB.UpdateEdge(eon,PC,F,tol);
       }
@@ -581,10 +580,10 @@ void TopOpeBRepBuild_Builder::SplitSectionEdges()
 #endif
       Standard_Boolean haspc = FC2D_HasCurveOnSurface(EG,FS); if (haspc) continue;
       Standard_Boolean hasc3d = FC2D_HasC3D(EG);
-      if (!hasc3d) Standard_ProgramError::Raise("TopOpeBRepBuild_Builder::SSE EG without C3D");
+      if (!hasc3d) throw Standard_ProgramError("TopOpeBRepBuild_Builder::SSE EG without C3D");
       Standard_Real pf,pl,tolpc; Handle(Geom2d_Curve) PC;
       Standard_Boolean trim3d = Standard_True; PC = FC2D_CurveOnSurface(EG,FS,pf,pl,tolpc,trim3d);
-      if (PC.IsNull()) Standard_ProgramError::Raise("TopOpeBRepBuild_Builder::SSE EG without PC on FS");
+      if (PC.IsNull()) throw Standard_ProgramError("TopOpeBRepBuild_Builder::SSE EG without PC on FS");
     } 
   } //5
   
@@ -633,7 +632,7 @@ void TopOpeBRepBuild_Builder::SplitSectionEdges()
          Standard_Boolean isouon,isovon; gp_Pnt2d o2don; gp_Dir2d d2don; 
          Standard_Boolean ISOon = TopOpeBRepTool_TOOL::UVISO(PCon,isouon,isovon,d2don,o2don);
          Standard_Boolean PCko = !ISOon || ((isoU && !isouon) || (isoV && !isovon));
-         if (PCko) Standard_ProgramError::Raise("TopOpeBRepBuild_Builder::splitON");
+         if (PCko) throw Standard_ProgramError("TopOpeBRepBuild_Builder::splitON");
 
          Standard_Boolean test = (FFuper && isoU) || (FFvper && isoV);
          if (!test) { newlON.Append(eon); continue;}
index 4d75721..fc08c34 100644 (file)
@@ -50,7 +50,7 @@ TopOpeBRepBuild_ShapeSet::TopOpeBRepBuild_ShapeSet(const TopAbs_ShapeEnum SubSha
 {
   if      (SubShapeType == TopAbs_EDGE)   myShapeType = TopAbs_FACE;
   else if (SubShapeType == TopAbs_VERTEX) myShapeType = TopAbs_EDGE;
-  else Standard_ProgramError::Raise("ShapeSet : bad ShapeType");
+  else throw Standard_ProgramError("ShapeSet : bad ShapeType");
   myDEBNumber = 0;
 
   myCheckShape = Standard_False; // temporary NYI
index b05a59f..7eab8c4 100644 (file)
@@ -155,7 +155,7 @@ Standard_Integer TopOpeBRepBuild_SolidBuilder::InitFace()
 {
   const Handle(TopOpeBRepBuild_Loop)& L = mySolidAreaBuilder.Loop();
   if ( L->IsShape() )
-    Standard_DomainError::Raise("TopOpeBRepBuild_SolidBuilder:InitFace");
+    throw Standard_DomainError("TopOpeBRepBuild_SolidBuilder:InitFace");
   else {
     myBlockIterator = L->BlockIterator();
     myBlockIterator.Initialize();
index 9ea5e7f..2ab6824 100644 (file)
@@ -139,7 +139,7 @@ void TopOpeBRepBuild_Builder::SplitShapes(TopOpeBRepTool_ShapeExplorer& Ex,
              add = (state == ToBuild1);
            }
            else {
-             Standard_ProgramError::Raise("SplitShapes no 3D curve on edge");
+             throw Standard_ProgramError("SplitShapes no 3D curve on edge");
              // NYI pas de courbe 3d : prendre un point sur (courbe 2d,face)
            }
          }
index 62deb9f..5857aab 100644 (file)
@@ -393,7 +393,7 @@ void  TopOpeBRepBuild_WireEdgeClassifier::ResetElement(const TopoDS_Shape& EE)
   } //jyl980406+
   
   C2D = FC2D_CurveOnSurface(E,F,f2,l2,tolpc);
-  if (C2D.IsNull()) Standard_ProgramError::Raise("WEC : ResetElement");
+  if (C2D.IsNull()) throw Standard_ProgramError("WEC : ResetElement");
 
   Standard_Real t = 0.397891143689; Standard_Real par = ((1-t)*f2 + t*l2);
   myPoint2d = C2D->Value(par);
index 49d779e..b69bb4a 100644 (file)
@@ -522,7 +522,7 @@ void TopOpeBRepBuild_WireEdgeSet::IsUVISO(const TopoDS_Edge& E,const TopoDS_Face
   Standard_Real fE,lE,tolpc;Handle(Geom2d_Curve) PC;
   Standard_Boolean trim3d = Standard_True;
   PC = FC2D_CurveOnSurface(E,F,fE,lE,tolpc,trim3d);
-  if (PC.IsNull()) Standard_ProgramError::Raise("TopOpeBRepBuild_WireEdgeSet::IsUVISO");
+  if (PC.IsNull()) throw Standard_ProgramError("TopOpeBRepBuild_WireEdgeSet::IsUVISO");
 
   Handle(Standard_Type) TheType = PC->DynamicType();
   if (TheType == STANDARD_TYPE(Geom2d_Line)) {
index a77e86a..4cd66bf 100644 (file)
@@ -202,7 +202,7 @@ void TopOpeBRepBuild_Builder::GFillCurveTopologyWES(const TopOpeBRepDS_CurveIter
 //      Standard_Real tolE = BRep_Tool::Tolerance(E);
       Standard_Real f2,l2,tolpc; Handle(Geom2d_Curve) C2D;
       C2D = FC2D_CurveOnSurface(E,WESF,f2,l2,tolpc);
-      if (C2D.IsNull()) Standard_ProgramError::Raise("GFillCurveTopologyWES");
+      if (C2D.IsNull()) throw Standard_ProgramError("GFillCurveTopologyWES");
 #ifdef OCCT_DEBUG
 //      Standard_Real tol = Max(tolE,tolpc);
 #endif
index 04058ce..86bd024 100644 (file)
@@ -624,11 +624,11 @@ Standard_EXPORT void FUNKP_KPmakefaces(const TopOpeBRepBuild_Builder& BU,
     BU.GFindSamDomSODO(Fac1,LFSO,LFDO);
   }
   else {
-    Standard_ProgramError::Raise("KPmakeface Stfac1 != OUT");
+    throw Standard_ProgramError("KPmakeface Stfac1 != OUT");
   }
   
   if (rankIN == 0) {
-    Standard_ProgramError::Raise("KPmakeface rankIN = 0");
+    throw Standard_ProgramError("KPmakeface rankIN = 0");
   }
   
   TopTools_ListOfShape LFIN;
@@ -712,13 +712,11 @@ TopoDS_Shape TopOpeBRepBuild_Builder::KPmakeface(const TopoDS_Shape& Fac1,
     GFindSamDomSODO(Fac1,LFSO,LFDO);
   }
   else {
-    Standard_ProgramError::Raise("KPmakeface Stfac1 != OUT");
-    return myFaceReference; //Dummy
+    throw Standard_ProgramError("KPmakeface Stfac1 != OUT");
   }
   
   if (rankIN == 0) {
-    Standard_ProgramError::Raise("KPmakeface rankIN = 0");
-    return myFaceReference; //Dummy
+    throw Standard_ProgramError("KPmakeface rankIN = 0");
   }
   
   TopTools_ListOfShape LFIN;
index fb7fc38..16181a6 100644 (file)
@@ -207,7 +207,7 @@ void TopOpeBRepBuild_Builder::GWESMakeFaces
     
     const TopoDS_Face& FA = TopoDS::Face(FF);
     Standard_Boolean puok = TopOpeBRepTool::PurgeClosingEdges(FA,LOF,MWisOld,MshNOK);
-    if (!puok) Standard_Failure::Raise("TopOpeBRepBuild::GWESMakeFaces");
+    if (!puok) throw Standard_Failure("TopOpeBRepBuild::GWESMakeFaces");
     topurge = !MshNOK.IsEmpty();
 
 #ifdef OCCT_DEBUG
@@ -218,7 +218,7 @@ void TopOpeBRepBuild_Builder::GWESMakeFaces
   if (topurge) {
     TopTools_ListOfShape LOFF;
     Standard_Boolean puok = TopOpeBRepTool::MakeFaces(TopoDS::Face(FF),LOF,MshNOK,LOFF);
-    if (!puok) Standard_Failure::Raise("TopOpeBRepBuild::GWESMakeFaces");
+    if (!puok) throw Standard_Failure("TopOpeBRepBuild::GWESMakeFaces");
     LOF.Clear(); LOF.Assign(LOFF);
   }
 
@@ -422,7 +422,7 @@ void TopOpeBRepBuild_Builder::GFABUMakeFaces(const TopoDS_Shape& FF,TopOpeBRepBu
                      Standard_Real f2,l2,tolpc; Handle(Geom2d_Curve) C2D;                                              // jyl980402+
                      //C2D = FC2D_CurveOnSurface(newEdge,newFace,f2,l2,tolpc);                                         // jyl980402+
                      C2D = FC2D_CurveOnSurface(newEdge,newFace,f2,l2,tolpc, Standard_True);                            // xpu051198 (CTS21701)
-                     if(C2D.IsNull()) Standard_ProgramError::Raise("TopOpeBRepBuild_Builder::GFABUMakeFaces null PC"); // jyl980402+
+                     if(C2D.IsNull()) throw Standard_ProgramError("TopOpeBRepBuild_Builder::GFABUMakeFaces null PC"); // jyl980402+
                      Standard_Real tol = Max(tolE,tolpc);                                                              // jyl980402+
                      BRep_Builder BB_PC; BB_PC.UpdateEdge(newEdge,C2D,newFace,tol);                                    // jyl980402+
                    }                                                                                                   // jyl980402+
index 1893943..5557d67 100644 (file)
@@ -170,7 +170,7 @@ TopOpeBRepDS_Kind TopOpeBRepDS::ShapeToKind(const TopAbs_ShapeEnum S)
   case TopAbs_SOLID  : res = TopOpeBRepDS_SOLID; break;
   case TopAbs_COMPSOLID : res = TopOpeBRepDS_COMPSOLID; break;
   case TopAbs_COMPOUND : res = TopOpeBRepDS_COMPOUND; break;
-  default : Standard_ProgramError::Raise("TopOpeBRepDS::ShapeToKind");
+  default : throw Standard_ProgramError("TopOpeBRepDS::ShapeToKind");
   }
   return res;
 }
@@ -194,7 +194,7 @@ TopAbs_ShapeEnum TopOpeBRepDS::KindToShape(const TopOpeBRepDS_Kind K)
   case TopOpeBRepDS_SOLID  : res = TopAbs_SOLID; break;
   case TopOpeBRepDS_COMPSOLID  : res = TopAbs_COMPSOLID; break;
   case TopOpeBRepDS_COMPOUND : res = TopAbs_COMPOUND; break;
-  default : Standard_ProgramError::Raise("TopOpeBRepDS::KindToShape");
+  default : throw Standard_ProgramError("TopOpeBRepDS::KindToShape");
   }
   return res;
 }
index 4da8245..6ed5f5b 100644 (file)
@@ -800,19 +800,14 @@ void  TopOpeBRepDS_BuildTool::RecomputeCurves
   const Standard_Boolean approx = Approximation();
   
   const Handle(Geom_Curve)& C3D = C.Curve();
-  if (comppc1 && C.Shape1().IsNull()) Standard_ProgramError::Raise
-    ("TopOpeBRepDS_BuildTool::RecomputeCurve 2");
-  if (comppc2 && C.Shape2().IsNull()) Standard_ProgramError::Raise
-    ("TopOpeBRepDS_BuildTool::RecomputeCurve 3");
+  if (comppc1 && C.Shape1().IsNull()) throw Standard_ProgramError("TopOpeBRepDS_BuildTool::RecomputeCurve 2");
+  if (comppc2 && C.Shape2().IsNull()) throw Standard_ProgramError("TopOpeBRepDS_BuildTool::RecomputeCurve 3");
   TopoDS_Vertex Vmin,Vmax; TopExp::Vertices(E,Vmin,Vmax);
-  if ( Vmin.IsNull() ) Standard_ProgramError::Raise
-    ("TopOpeBRepDS_BuildTool::RecomputeCurve 4");
-  if ( Vmax.IsNull() ) Standard_ProgramError::Raise
-    ("TopOpeBRepDS_BuildTool::RecomputeCurve 5");
+  if ( Vmin.IsNull() ) throw Standard_ProgramError("TopOpeBRepDS_BuildTool::RecomputeCurve 4");
+  if ( Vmax.IsNull() ) throw Standard_ProgramError("TopOpeBRepDS_BuildTool::RecomputeCurve 5");
   
   if (iswalk && approx) {
-    if (compc3d && C3D.IsNull()) Standard_ProgramError::Raise
-      ("TopOpeBRepDS_BuildTool::RecomputeCurve 1");
+    if (compc3d && C3D.IsNull()) throw Standard_ProgramError("TopOpeBRepDS_BuildTool::RecomputeCurve 1");
     ApproxCurves(C, E, inewC, HDS);
     TopOpeBRepDS_Curve& newC = HDS->ChangeCurve(inewC);
     PutPCurves(newC, E, comppc1, comppc2);
@@ -829,8 +824,7 @@ void  TopOpeBRepDS_BuildTool::RecomputeCurves
       inewC = HDS->MakeCurve(C,newC1);
       TopOpeBRepDS_Curve& newC = HDS->ChangeCurve(inewC);
       if(iswalk && !approx) {
-       if (compc3d && C3D.IsNull()) Standard_ProgramError::Raise
-         ("TopOpeBRepDS_BuildTool::RecomputeCurve 1");
+       if (compc3d && C3D.IsNull()) throw Standard_ProgramError("TopOpeBRepDS_BuildTool::RecomputeCurve 1");
        newC.Curve1(C.Curve1());
        newC.Curve2(C.Curve2());
       }
@@ -1341,17 +1335,12 @@ void  TopOpeBRepDS_BuildTool::RecomputeCurve
   Standard_Boolean comppc2 = GT.CompPC2();
   
   const Handle(Geom_Curve)& C3D = C1.Curve();
-  if (compc3d && C3D.IsNull()) Standard_ProgramError::Raise
-    ("TopOpeBRepDS_BuildTool::RecomputeCurve 1");
-  if (comppc1 && C2.Shape1().IsNull()) Standard_ProgramError::Raise
-    ("TopOpeBRepDS_BuildTool::RecomputeCurve 2");
-  if (comppc2 && C2.Shape2().IsNull()) Standard_ProgramError::Raise
-    ("TopOpeBRepDS_BuildTool::RecomputeCurve 3");
+  if (compc3d && C3D.IsNull()) throw Standard_ProgramError("TopOpeBRepDS_BuildTool::RecomputeCurve 1");
+  if (comppc1 && C2.Shape1().IsNull()) throw Standard_ProgramError("TopOpeBRepDS_BuildTool::RecomputeCurve 2");
+  if (comppc2 && C2.Shape2().IsNull()) throw Standard_ProgramError("TopOpeBRepDS_BuildTool::RecomputeCurve 3");
   TopoDS_Vertex Vmin,Vmax; TopExp::Vertices(TopoDS::Edge(E),Vmin,Vmax);
-  if ( Vmin.IsNull() ) Standard_ProgramError::Raise
-    ("TopOpeBRepDS_BuildTool::RecomputeCurve 4");
-  if ( Vmax.IsNull() ) Standard_ProgramError::Raise
-    ("TopOpeBRepDS_BuildTool::RecomputeCurve 5");
+  if ( Vmin.IsNull() ) throw Standard_ProgramError("TopOpeBRepDS_BuildTool::RecomputeCurve 4");
+  if ( Vmax.IsNull() ) throw Standard_ProgramError("TopOpeBRepDS_BuildTool::RecomputeCurve 5");
 
   Standard_Boolean kbspl1 = Standard_False;
   Handle(Geom_BSplineCurve) BS = Handle(Geom_BSplineCurve)::DownCast(C3D);
@@ -1416,7 +1405,7 @@ void  TopOpeBRepDS_BuildTool::RecomputeBSpline1Curve
   }
 
   else if ( typec3d == TopOpeBRepTool_APPROX ) {
-    if (!comppc1 || !comppc2) Standard_NotImplemented::Raise("DSBuildToolAPPROX");
+    if (!comppc1 || !comppc2) throw Standard_NotImplemented("DSBuildToolAPPROX");
     myCurveTool.MakeCurves(parmin,parmax,
                           C3D,PC1,PC2,F1,F2,
                           C3Dnew,PC1new,PC2new,
@@ -1424,7 +1413,7 @@ void  TopOpeBRepDS_BuildTool::RecomputeBSpline1Curve
   }
 
   else if ( typec3d == TopOpeBRepTool_INTERPOL ) {
-    Standard_NotImplemented::Raise("DSBuildToolINTERPOL");
+    throw Standard_NotImplemented("DSBuildToolINTERPOL");
   }
 
   Standard_Real newtol,newparmin,newparmax;
index 102f4fe..1ee761c 100644 (file)
@@ -934,13 +934,13 @@ void TopOpeBRepDS_DataStructure::FillShapesSameDomain(const TopoDS_Shape& S1,
   else if ( r1 != iS1 && r2 == iS2 ) r = r1;
   else if ( r1 != iS1 && r2 != iS2 ) { 
     if (r1 != r2) {
-      //      Standard_ProgramError::Raise("FacesFiller::Insert SD 1");
+      //      throw Standard_ProgramError("FacesFiller::Insert SD 1");
     }
     r = (refFirst? r1 : r2);
   }
   
   if (r == 0) {
-    Standard_ProgramError::Raise("FacesFiller::Insert SD 2");
+    throw Standard_ProgramError("FacesFiller::Insert SD 2");
   }
 
   TopoDS_Shape Sr = Shape(r);
@@ -1142,7 +1142,7 @@ TopOpeBRepDS_Curve& TopOpeBRepDS_DataStructure::ChangeCurve(const Standard_Integ
 const TopOpeBRepDS_Point& TopOpeBRepDS_DataStructure::Point(const Standard_Integer I)const 
 {
   if ( I < 1 || I > myNbPoints ) {
-    Standard_ProgramError::Raise("TopOpeBRepDS_DataStructure::Point");
+    throw Standard_ProgramError("TopOpeBRepDS_DataStructure::Point");
   }
 
   if ( myPoints.IsBound(I) ) 
@@ -1158,7 +1158,7 @@ const TopOpeBRepDS_Point& TopOpeBRepDS_DataStructure::Point(const Standard_Integ
 TopOpeBRepDS_Point& TopOpeBRepDS_DataStructure::ChangePoint(const Standard_Integer I)
 {
   if ( I < 1 || I > myNbPoints ) {
-    Standard_ProgramError::Raise("TopOpeBRepDS_DataStructure::Point");
+    throw Standard_ProgramError("TopOpeBRepDS_DataStructure::Point");
   }
 
   if ( myPoints.IsBound(I) ) 
index 5942c7a..523650f 100644 (file)
@@ -346,7 +346,7 @@ Standard_EXPORT Standard_Real FDS_Parameter(const Handle(TopOpeBRepDS_Interferen
   else if ( I->IsKind(STANDARD_TYPE(TopOpeBRepDS_CurvePointInterference)) )
     p = Handle(TopOpeBRepDS_CurvePointInterference)::DownCast(I)->Parameter();
   else {
-    Standard_Failure::Raise("FDS_Parameter");
+    throw Standard_Failure("FDS_Parameter");
   }
   return p;
 }
index a28c40d..2fcfd69 100644 (file)
@@ -36,7 +36,7 @@
 
 static void FUN_Raise()
 {
-  Standard_ProgramError::Raise("Edge3dInterferenceTool");
+  throw Standard_ProgramError("Edge3dInterferenceTool");
 }
 
 #define POINT        (0)
index 8bd1044..b7ebf13 100644 (file)
@@ -46,7 +46,7 @@ static Standard_Real Parameter(const Handle(TopOpeBRepDS_Interference)& I)
   else if ( I->IsKind(STANDARD_TYPE(TopOpeBRepDS_CurvePointInterference)) )
     p = Handle(TopOpeBRepDS_CurvePointInterference)::DownCast(I)->Parameter();
   else {
-    Standard_ProgramError::Raise("TopOpeBRepDS_EdgeInterferenceTool1");
+    throw Standard_ProgramError("TopOpeBRepDS_EdgeInterferenceTool1");
   }
   return p;
 }
index 357a685..34dbd4d 100644 (file)
@@ -42,7 +42,7 @@ static Standard_Boolean STATIC_TOREVERSE = Standard_False; // xpu150498
 #define M_REVERSED(ori) (ori == TopAbs_REVERSED)
 
 //------------------------------------------------------
-static void FUN_RaiseError(){Standard_ProgramError::Raise("TopOpeBRepDS_FaceInterferenceTool");}
+static void FUN_RaiseError(){throw Standard_ProgramError("TopOpeBRepDS_FaceInterferenceTool");}
 
 //------------------------------------------------------
 Standard_EXPORT Standard_Boolean FUN_Parameters
@@ -99,7 +99,7 @@ Standard_EXPORT void FUN_ComputeGeomData
   // Getting the principle directions,the normal and the curvatures
   BRepLProp_SLProps props(surf,uu,vv,2,Precision::Confusion());
   Standard_Boolean curdef = props.IsCurvatureDefined();
-  if (!curdef) Standard_ProgramError::Raise("TopOpeBRepDS_FaceInterferenceTool::Init");
+  if (!curdef) throw Standard_ProgramError("TopOpeBRepDS_FaceInterferenceTool::Init");
   Standard_Boolean umbilic = props.IsUmbilic();
   if (umbilic) { 
     Cur1 = Cur2 = props.MeanCurvature(); 
@@ -118,7 +118,7 @@ Standard_EXPORT void FUN_ComputeGeomData
                                            //          describes "direct" geometry 
     }
     else                
-      Standard_Failure::Raise("FUN_ComputeGeomData");
+      throw Standard_Failure("FUN_ComputeGeomData");
     
     D1 = Norm; Standard_Real x = D1.X(),y = D1.Y(),z = D1.Z(),tol = Precision::Confusion(); 
     Standard_Boolean nullx = (Abs(x)<tol),nully = (Abs(y)<tol),nullz = (Abs(z)<tol);
@@ -325,7 +325,7 @@ void TopOpeBRepDS_FaceInterferenceTool::SetEdgePntPar(const gp_Pnt& P,const Stan
 //=======================================================================
 void TopOpeBRepDS_FaceInterferenceTool::GetEdgePntPar(gp_Pnt& P,Standard_Real& p) const
 {
-  if (!myOnEdDef) Standard_ProgramError::Raise("GetEdgePntPar");
+  if (!myOnEdDef) throw Standard_ProgramError("GetEdgePntPar");
   P = myPntOnEd;
   p = myParOnEd;
 }
index 3d9df94..0f3a257 100644 (file)
@@ -729,7 +729,7 @@ void TopOpeBRepDS_HDataStructure::StoreInterference
 {
   Standard_Boolean h = myDS.HasShape(S);
   if ( !h ) {
-    Standard_ProgramError::Raise("StoreInterference on shape out of DS");
+    throw Standard_ProgramError("StoreInterference on shape out of DS");
     return;
   }
   StoreInterference(I,myDS.ChangeShapeInterferences(S));
@@ -746,7 +746,7 @@ void TopOpeBRepDS_HDataStructure::StoreInterference
 {
   Standard_Integer n = myDS.NbShapes();
   if ( IS < 1 || IS > n ) {
-    Standard_ProgramError::Raise("StoreInterference on index out of DS");
+    throw Standard_ProgramError("StoreInterference on index out of DS");
     return;
   }
 
index 8d179e9..0d83cd5 100644 (file)
@@ -87,10 +87,8 @@ Standard_Real  TopOpeBRepDS_PointIterator::Parameter()const
     return Handle(TopOpeBRepDS_EdgeVertexInterference)::DownCast (I)->Parameter();
   }
   else {
-    Standard_ProgramError::Raise("TopOpeBRepDS_PointIterator::Parameter()");
-    return 0.;  // windowsNT
+    throw Standard_ProgramError("TopOpeBRepDS_PointIterator::Parameter()");
   }
-//  return 0.;  // windowsNT
 }
 
 //=======================================================================
@@ -126,10 +124,8 @@ Standard_Boolean TopOpeBRepDS_PointIterator::DiffOriented() const
       ->Config() == TopOpeBRepDS_DIFFORIENTED;
   }
   else {
-    Standard_ProgramError::Raise("TopOpeBRepDS_PointIterator::DiffOriented()");
-    return Standard_False; // windowsNT
+    throw Standard_ProgramError("TopOpeBRepDS_PointIterator::DiffOriented()");
   }
-//  return Standard_False; // windowsNT
 }
 
 //=======================================================================
@@ -145,8 +141,7 @@ Standard_Boolean TopOpeBRepDS_PointIterator::SameOriented() const
       ->Config() == TopOpeBRepDS_SAMEORIENTED;
   }
   else {
-    Standard_ProgramError::Raise("TopOpeBRepDS_PointIterator::SameOriented()");
-    return Standard_False; // windowsNT
+    throw Standard_ProgramError("TopOpeBRepDS_PointIterator::SameOriented()");
   }
 }
 
index 6bd84c8..0570ab7 100644 (file)
@@ -47,7 +47,7 @@ void TopOpeBRepDS_TKI::Reset()
   Standard_Integer ip = (Standard_Integer)TopOpeBRepDS_POINT;
   Standard_Integer is = (Standard_Integer)TopOpeBRepDS_SOLID;
   if (ip > is ) {
-    Standard_ProgramError::Raise("TopOpeBRepDS_TKI : enumeration badly ordered");
+    throw Standard_ProgramError("TopOpeBRepDS_TKI : enumeration badly ordered");
     return;
   }
   Standard_Integer f = 1;           // first index of table
@@ -158,7 +158,7 @@ void TopOpeBRepDS_TKI::Add(const TopOpeBRepDS_Kind K,const Standard_Integer G)
 {
   Standard_Boolean ok = IsValidKG(K,G);
   if (!ok) {
-    Standard_ProgramError::Raise("TopOpeBRepDS_TKI : Add K G");
+    throw Standard_ProgramError("TopOpeBRepDS_TKI : Add K G");
     return;
   }
 
@@ -176,7 +176,7 @@ void TopOpeBRepDS_TKI::Add(const TopOpeBRepDS_Kind K,const Standard_Integer G)
 void TopOpeBRepDS_TKI::Add(const TopOpeBRepDS_Kind K,const Standard_Integer G,const Handle(TopOpeBRepDS_Interference)& HI)
 {
   Standard_Boolean ok = IsValidKG(K,G);
-  if (!ok) Standard_ProgramError::Raise("TopOpeBRepDS_TKI : Add K G HI");
+  if (!ok) throw Standard_ProgramError("TopOpeBRepDS_TKI : Add K G HI");
 
   Add(K,G);
   ChangeInterferences(K,G).Append(HI);
index 4d31ef5..d8f7087 100644 (file)
@@ -208,7 +208,7 @@ TopAbs_ShapeEnum TopOpeBRepDS_Transition::ShapeAfter() const
 Standard_Integer TopOpeBRepDS_Transition::Index() const
 {
   if ( myIndexAfter != myIndexBefore ) 
-    Standard_Failure::Raise("Transition::Index() on different shapes");
+    throw Standard_Failure("Transition::Index() on different shapes");
   return myIndexBefore;
 }
 
index 4e49eb7..12c3825 100644 (file)
@@ -75,7 +75,7 @@ Standard_EXPORT void FDS_repvg2
     TopOpeBRepDS_Point PDS; TopoDS_Shape VDS;
     if      (ispoint)  PDS = BDS.Point(G1);
     else if (isvertex) VDS = BDS.Shape(G1);
-    else Standard_Failure::Raise("TopOpeBRepDS FDS_repvg2 1");
+    else throw Standard_Failure("TopOpeBRepDS FDS_repvg2 1");
 
     Standard_Boolean isEd1 = BRep_Tool::Degenerated(E1); if (isEd1) {it1.Next(); continue;}
     TopOpeBRepDS_ListIteratorOfListOfInterference it2(it1); if (it2.More()) it2.Next(); else {it1.Next(); continue; }
index 9e35698..743ef25 100644 (file)
@@ -183,7 +183,7 @@ const TopoDS_Shape& TopOpeBRepTool_BoxSort::HABShape(const Standard_Integer I) c
   Standard_Integer iu = myHAI->Upper();
   Standard_Boolean b = (I >= 1 && I <= iu);
   if (!b) {
-    Standard_ProgramError::Raise("BS::Box3");
+    throw Standard_ProgramError("BS::Box3");
   }
   Standard_Integer im = myHAI->Value(I);
   const TopoDS_Shape& S = myHBT->Shape(im);
index 2fbe674..24307fb 100644 (file)
@@ -154,7 +154,7 @@ Standard_EXPORT Handle(Geom2d_Curve) MakePCurve(const ProjLib_ProjectedCurve& PC
   case GeomAbs_Hyperbola : C2D = new Geom2d_Hyperbola(PC.Hyperbola()); break;
   case GeomAbs_BSplineCurve : C2D = PC.BSpline(); break;
   default :
-    Standard_NotImplemented::Raise("CurveTool::MakePCurve");
+    throw Standard_NotImplemented("CurveTool::MakePCurve");
     break;
   }
   return C2D;
index 5d2cbdf..be52805 100644 (file)
@@ -82,7 +82,7 @@ TopOpeBRepTool_FuseEdges::TopOpeBRepTool_FuseEdges(const TopoDS_Shape& theShape,
  myResultEdgesDone(Standard_False),myNbConnexEdge(0)
 {
 //  if (theShape.ShapeType() != TopAbs_SHELL && theShape.ShapeType() != TopAbs_SOLID)
-//    Standard_ConstructionError::Raise("FuseEdges");
+//    throw Standard_ConstructionError("FuseEdges");
   Standard_NullObject_Raise_if(theShape.IsNull(),"FuseEdges");
   myMapFaces.Clear();
 
@@ -347,10 +347,10 @@ void TopOpeBRepTool_FuseEdges::BuildListResultEdges()
 
          ME.Init(ExtC,VF,VL);
          if (!ME.IsDone()) 
-           Standard_ConstructionError::Raise("FuseEdges : Fusion failed");
+           throw Standard_ConstructionError("FuseEdges : Fusion failed");
        }
        else
-         Standard_ConstructionError::Raise("FuseEdges : Fusion failed");
+         throw Standard_ConstructionError("FuseEdges : Fusion failed");
       }
 
       NewEdge = ME.Edge();
index 72503f0..dc1a063 100644 (file)
@@ -106,7 +106,7 @@ void TopOpeBRepTool_HBoxTool::ComputeBox(const TopoDS_Shape& S,Bnd_Box& B)
   //modified by NIZHNY-MZV  Wed Apr  5 10:05:53 2000
   else if ( t == TopAbs_VERTEX) BRepBndLib::Add(S,B);
   else {
-    Standard_ProgramError::Raise("HBT::ComputeBox : invalid type");
+    throw Standard_ProgramError("HBT::ComputeBox : invalid type");
   }
 }
 
@@ -139,7 +139,7 @@ const Bnd_Box& TopOpeBRepTool_HBoxTool::Box(const TopoDS_Shape& S)
 {
   Standard_Boolean hb = HasBox(S);
   if (!hb) {
-    Standard_ProgramError::Raise("HBT::Box1");
+    throw Standard_ProgramError("HBT::Box1");
   }
 
   const Bnd_Box& B = myIMS.FindFromKey(S);
@@ -155,7 +155,7 @@ const Bnd_Box& TopOpeBRepTool_HBoxTool::Box(const Standard_Integer I) const
   Standard_Integer iu = Extent();
   Standard_Integer hb = (I >= 1 && I <= iu);
   if (!hb) {
-    Standard_ProgramError::Raise("HBT::Box2");
+    throw Standard_ProgramError("HBT::Box2");
   }
   const Bnd_Box& B = myIMS.FindFromIndex(I);
   return B;
@@ -180,7 +180,7 @@ const TopoDS_Shape& TopOpeBRepTool_HBoxTool::Shape(const Standard_Integer I) con
   Standard_Integer iu = Extent();
   Standard_Integer hs = (I >= 1 && I <= iu);
   if (!hs) {
-    Standard_ProgramError::Raise("HBT::Box4");
+    throw Standard_ProgramError("HBT::Box4");
   }
   const TopoDS_Shape& S = myIMS.FindKey(I);
   return S;
index 99aec65..6ba7fe1 100644 (file)
@@ -374,11 +374,11 @@ static Standard_Boolean FUN_correctDegeneratedE
   if (!uviso) return Standard_False;
 
   Standard_Real pfEin,plEin,tolEin; Handle(Geom2d_Curve) PCEin = FUNTOOLC2D_CurveOnSurface(Ein,Fsp,pfEin,plEin,tolEin); 
-  if (PCEin.IsNull()) Standard_Failure::Raise(" FUN_correctDegeneratedE : no 2d curve Ein");
+  if (PCEin.IsNull()) throw Standard_Failure(" FUN_correctDegeneratedE : no 2d curve Ein");
   Standard_Real pf1,pl1,tol1; Handle(Geom2d_Curve) PC1 = FUNTOOLC2D_CurveOnSurface(e1,Fsp,pf1,pl1,tol1); 
-  if (PC1.IsNull()) Standard_Failure::Raise(" FUN_correctDegeneratedE : no 2d curve e1");
+  if (PC1.IsNull()) throw Standard_Failure(" FUN_correctDegeneratedE : no 2d curve e1");
   Standard_Real pf2,pl2,tol2; Handle(Geom2d_Curve) PC2 = FUNTOOLC2D_CurveOnSurface(e2,Fsp,pf2,pl2,tol2); 
-  if (PC2.IsNull()) Standard_Failure::Raise(" FUN_correctDegeneratedE : no 2d curve e2");
+  if (PC2.IsNull()) throw Standard_Failure(" FUN_correctDegeneratedE : no 2d curve e2");
   
   Standard_Real parv1 = BRep_Tool::Parameter(v1,Ein,Fsp);
   Standard_Real parv2 = BRep_Tool::Parameter(v2,Ein,Fsp);
index a536cc7..30a8af4 100644 (file)
@@ -38,7 +38,7 @@
 TopOpeBRepTool_PurgeInternalEdges::TopOpeBRepTool_PurgeInternalEdges(const TopoDS_Shape& theShape,const Standard_Boolean PerformNow):myShape(theShape),myIsDone(Standard_False)
 {
 //  if (theShape.ShapeType() != TopAbs_SHELL && theShape.ShapeType() != TopAbs_SOLID)
-//    Standard_ConstructionError::Raise("PurgeInternalEdges");
+//    throw Standard_ConstructionError("PurgeInternalEdges");
   Standard_NullObject_Raise_if(theShape.IsNull(),"PurgeInternalEdges");
   
   if (PerformNow) {
index 719c827..42866a4 100644 (file)
@@ -70,7 +70,7 @@ static void FUN_Raise()
 #ifdef OCCT_DEBUG
   Standard_Boolean trc = TopOpeBRepTool_GettraceREGUSO(); 
   if (trc) cout<<"***** Failure in REGUS **********"<<endl;
-//  Standard_Failure::Raise("REGUS");
+//  throw Standard_Failure("REGUS");
 #endif
 }
 
index 700ddfc..66b5767 100644 (file)
@@ -84,7 +84,7 @@ static void FUN_Raise() {
 #ifdef OCCT_DEBUG
   Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
   if (trc) cout<<"*** Raise REGUW"<<endl;
-//  Standard_Failure::Raise("REGUW");
+//  throw Standard_Failure("REGUW");
 #endif  
 }
 
@@ -135,7 +135,7 @@ void TopOpeBRepTool_REGUW::SetEsplits(TopTools_DataMapOfShapeListOfShape& Esplit
 
 void TopOpeBRepTool_REGUW::GetEsplits(TopTools_DataMapOfShapeListOfShape& Esplits) const 
 {
-  if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
+  if (!HasInit()) throw Standard_Failure("TopOpeBRepTool_REGUW : NO INIT");
   Esplits = myEsplits;
 }
 
@@ -155,7 +155,7 @@ void TopOpeBRepTool_REGUW::SetOwNw(TopTools_DataMapOfShapeListOfShape& OwNw)
 
 void TopOpeBRepTool_REGUW::GetOwNw(TopTools_DataMapOfShapeListOfShape& OwNw) const
 {
-  if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
+  if (!HasInit()) throw Standard_Failure("TopOpeBRepTool_REGUW : NO INIT");
   OwNw = myOwNw;
 }
 
@@ -166,7 +166,7 @@ void TopOpeBRepTool_REGUW::GetOwNw(TopTools_DataMapOfShapeListOfShape& OwNw) con
 
 Standard_Boolean TopOpeBRepTool_REGUW::SplitEds()
 {
-  if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
+  if (!HasInit()) throw Standard_Failure("TopOpeBRepTool_REGUW : NO INIT");
 #ifdef OCCT_DEBUG
   Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
   if (trc) cout<<"**    SPLITTING EDGES    **"<<endl;
@@ -226,7 +226,7 @@ Standard_Boolean TopOpeBRepTool_REGUW::SplitEds()
 
 const TopoDS_Shape& TopOpeBRepTool_REGUW::S() const
 {
-  if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
+  if (!HasInit()) throw Standard_Failure("TopOpeBRepTool_REGUW : NO INIT");
   return myS;
 }
 
@@ -260,7 +260,7 @@ Standard_Boolean TopOpeBRepTool_REGUW::HasInit() const
 
 void TopOpeBRepTool_REGUW::InitStep(const TopoDS_Shape& S)
 {  
-  if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
+  if (!HasInit()) throw Standard_Failure("TopOpeBRepTool_REGUW : NO INIT");
   TopoDS_Shape null;myCORRISO.Init(null); myCORRISO.Init(S);
 
   mymapvEds.Clear();
@@ -277,7 +277,7 @@ void TopOpeBRepTool_REGUW::InitStep(const TopoDS_Shape& S)
 
 Standard_Boolean TopOpeBRepTool_REGUW::MapS()
 {
-  if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
+  if (!HasInit()) throw Standard_Failure("TopOpeBRepTool_REGUW : NO INIT");
 #ifdef OCCT_DEBUG
   Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
   if (trc) cout<<"**    MAPPING    **"<<endl;
@@ -431,7 +431,7 @@ static void FUN_nextdata(const Standard_Integer iStep,const TopoDS_Edge& e,const
 
 Standard_Boolean TopOpeBRepTool_REGUW::InitBlock()
 {  
-  if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
+  if (!HasInit()) throw Standard_Failure("TopOpeBRepTool_REGUW : NO INIT");
 #ifdef OCCT_DEBUG
   Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
 #endif
@@ -532,7 +532,7 @@ Standard_Boolean TopOpeBRepTool_REGUW::NearestE(const TopTools_ListOfShape& loe,
   Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
 #endif
 
-  if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
+  if (!HasInit()) throw Standard_Failure("TopOpeBRepTool_REGUW : NO INIT");
   efound.Nullify();
   Standard_Real fac = 0.45678;
   Standard_Real tola = Precision::Angular();
@@ -595,7 +595,7 @@ Standard_Boolean TopOpeBRepTool_REGUW::NearestE(const TopTools_ListOfShape& loe,
 
 Standard_Boolean TopOpeBRepTool_REGUW::NextinBlock()
 {
-  if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
+  if (!HasInit()) throw Standard_Failure("TopOpeBRepTool_REGUW : NO INIT");
 #ifdef OCCT_DEBUG
   Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
   if (trc) cout<<endl<<" vcur = v"<<FUN_adds(myv)<<"   p2d = ("<<myp2d.X()<<" "<<myp2d.Y()<<")"<<endl;
@@ -687,7 +687,7 @@ Standard_Boolean TopOpeBRepTool_REGUW::REGU(const Standard_Integer istep,
 #endif
                                             TopTools_ListOfShape& Splits)
 {   
-  if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
+  if (!HasInit()) throw Standard_Failure("TopOpeBRepTool_REGUW : NO INIT");
   iStep = istep;
 #ifdef OCCT_DEBUG
   Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
@@ -847,7 +847,7 @@ Standard_Boolean TopOpeBRepTool_REGUW::REGU(const Standard_Integer istep,
 
 Standard_Boolean TopOpeBRepTool_REGUW::REGU() 
 {  
-  if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
+  if (!HasInit()) throw Standard_Failure("TopOpeBRepTool_REGUW : NO INIT");
   TopTools_ListOfShape null;
 
   Standard_Boolean toregu = !myListVmultiple.IsEmpty();
@@ -889,7 +889,7 @@ Standard_Boolean TopOpeBRepTool_REGUW::REGU()
 
 Standard_Boolean TopOpeBRepTool_REGUW::GetSplits(TopTools_ListOfShape& Splits) const
 {
-  if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
+  if (!HasInit()) throw Standard_Failure("TopOpeBRepTool_REGUW : NO INIT");
   Standard_Boolean isb = myOwNw.IsBound(S());
   if (!isb) return Standard_False;
   Splits = myOwNw.Find(S());
@@ -903,7 +903,7 @@ Standard_Boolean TopOpeBRepTool_REGUW::GetSplits(TopTools_ListOfShape& Splits) c
 
 Standard_Boolean TopOpeBRepTool_REGUW::Connexity(const TopoDS_Vertex& v, TopOpeBRepTool_connexity& co) const
 {
-  if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
+  if (!HasInit()) throw Standard_Failure("TopOpeBRepTool_REGUW : NO INIT");
   Standard_Boolean isb = mymapvEds.Contains(v);
   if (!isb) return Standard_False;
   co = mymapvEds.FindFromKey(v);
@@ -917,7 +917,7 @@ Standard_Boolean TopOpeBRepTool_REGUW::Connexity(const TopoDS_Vertex& v, TopOpeB
 
 Standard_Boolean TopOpeBRepTool_REGUW::AddNewConnexity(const TopoDS_Vertex& v, const Standard_Integer OriKey,const TopoDS_Edge& e)
 {
-  if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
+  if (!HasInit()) throw Standard_Failure("TopOpeBRepTool_REGUW : NO INIT");
   Standard_Boolean isb = mymapvEds.Contains(v);
   if (!isb) return Standard_False;
 
@@ -945,7 +945,7 @@ Standard_Boolean TopOpeBRepTool_REGUW::AddNewConnexity(const TopoDS_Vertex& v, c
 
 Standard_Boolean TopOpeBRepTool_REGUW::RemoveOldConnexity(const TopoDS_Vertex& v, const Standard_Integer OriKey,const TopoDS_Edge& e)
 {
-  if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
+  if (!HasInit()) throw Standard_Failure("TopOpeBRepTool_REGUW : NO INIT");
   Standard_Boolean isb = mymapvEds.Contains(v);
   if (!isb) return Standard_False;
 
@@ -973,7 +973,7 @@ Standard_Boolean TopOpeBRepTool_REGUW::RemoveOldConnexity(const TopoDS_Vertex& v
 
 Standard_Boolean TopOpeBRepTool_REGUW::UpdateMultiple(const TopoDS_Vertex& v)
 {
-  if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
+  if (!HasInit()) throw Standard_Failure("TopOpeBRepTool_REGUW : NO INIT");
   Standard_Boolean isb = mymapvEds.Contains(v);
   if (!isb) return Standard_False;
   const TopOpeBRepTool_connexity& co = mymapvEds.FindFromKey(v);
index bae4bbe..a738177 100644 (file)
@@ -407,7 +407,7 @@ void TopOpeBRepTool_ShapeClassifier::Perform()
        }
        else {
          myState = TopAbs_UNKNOWN;
-         Standard_ProgramError::Raise("TopOpeBRepTool_ShapeClassifier !P3Ddef");
+         throw Standard_ProgramError("TopOpeBRepTool_ShapeClassifier !P3Ddef");
        }
       }
     }
@@ -434,7 +434,7 @@ void TopOpeBRepTool_ShapeClassifier::Perform()
     }
   }
   else {
-    Standard_ProgramError::Raise("StateShapeShape : bad operands");
+    throw Standard_ProgramError("StateShapeShape : bad operands");
   }
   
   // take orientation of reference shape in account
@@ -479,7 +479,7 @@ void TopOpeBRepTool_ShapeClassifier::StateEdgeReference()
          C2D = FC2D_CurveOnSurface(myEdge,F,f2d,l2d,tol2d,trimCurve);
 
          if(C2D.IsNull())
-           Standard_ProgramError::Raise("StateShapeShape : no 2d curve");
+           throw Standard_ProgramError("StateShapeShape : no 2d curve");
 
          Standard_Real t = 0.127956477;
          Standard_Real p = (1-t)*f2d + t*l2d;
@@ -498,7 +498,7 @@ void TopOpeBRepTool_ShapeClassifier::StateEdgeReference()
          C3D = BRep_Tool::Curve(myEdge,f3d,l3d);
 
          if(C3D.IsNull())
-           Standard_ProgramError::Raise("StateShapeShape : no 3d curve");
+           throw Standard_ProgramError("StateShapeShape : no 3d curve");
 
          Standard_Real t = 0.127956477;
          Standard_Real p = (1-t)*f3d + t*l3d;
@@ -522,7 +522,7 @@ void TopOpeBRepTool_ShapeClassifier::StateEdgeReference()
          C3D = BRep_Tool::Curve(myEdge,f3d,l3d);
 
          if (C3D.IsNull())
-           Standard_ProgramError::Raise("StateShapeShape : no 3d curve");
+           throw Standard_ProgramError("StateShapeShape : no 3d curve");
 
          Standard_Real t = 0.127956477;
          Standard_Real p = (1-t)*f3d + t*l3d;
@@ -532,7 +532,7 @@ void TopOpeBRepTool_ShapeClassifier::StateEdgeReference()
        }
     }
   else
-    Standard_ProgramError::Raise("StateShapeShape : bad operands");
+    throw Standard_ProgramError("StateShapeShape : bad operands");
 }
 
 
@@ -577,7 +577,7 @@ void TopOpeBRepTool_ShapeClassifier::StateP2DReference
     }
   }
   else {
-    Standard_ProgramError::Raise("StateShapeShape : bad operands");
+    throw Standard_ProgramError("StateShapeShape : bad operands");
   }
 }
 
@@ -616,7 +616,7 @@ void TopOpeBRepTool_ShapeClassifier::StateP3DReference(const gp_Pnt& P3D)
     }
   }
   else {
-    Standard_ProgramError::Raise("StateShapeShape : bad operands");
+    throw Standard_ProgramError("StateShapeShape : bad operands");
   }
 }
 
@@ -640,8 +640,7 @@ const gp_Pnt& TopOpeBRepTool_ShapeClassifier::P3D() const
   if (myP3Ddef) { 
     return myP3D;
   }
-  Standard_ProgramError::Raise("ShapeClassifier::P3D undefined");
-  return myP3D;
+  throw Standard_ProgramError("ShapeClassifier::P3D undefined");
 }
 
 //=======================================================================
@@ -654,8 +653,7 @@ const gp_Pnt2d& TopOpeBRepTool_ShapeClassifier::P2D() const
   if (myP2Ddef) {
     return myP2D;
   }
-  Standard_ProgramError::Raise("ShapeClassifier::P2D undefined");
-  return myP2D;
+  throw Standard_ProgramError("ShapeClassifier::P2D undefined");
 }
 
 //=======================================================================
index 8660479..1cb9bc2 100644 (file)
@@ -54,8 +54,7 @@ Standard_Real TopOpeBRepTool_ShapeTool::Tolerance(const TopoDS_Shape& S)
     case TopAbs_FACE   : tol = BRep_Tool::Tolerance(TopoDS::Face(S)); break;
     case TopAbs_EDGE   : tol = BRep_Tool::Tolerance(TopoDS::Edge(S)); break;
     case TopAbs_VERTEX : tol = BRep_Tool::Tolerance(TopoDS::Vertex(S)); break;
-    default : Standard_ProgramError::Raise
-    ("TopOpeBRepTool_ShapeTool : Shape has no tolerance"); break;
+    default : throw Standard_ProgramError("TopOpeBRepTool_ShapeTool : Shape has no tolerance"); break;
   }
   return tol;
 }
@@ -69,8 +68,7 @@ Standard_Real TopOpeBRepTool_ShapeTool::Tolerance(const TopoDS_Shape& S)
 gp_Pnt TopOpeBRepTool_ShapeTool::Pnt(const TopoDS_Shape& S)
 {
   if ( S.ShapeType() != TopAbs_VERTEX ) {
-    Standard_ProgramError::Raise("TopOpeBRepTool_ShapeTool::Pnt");
-    return gp_Pnt();
+    throw Standard_ProgramError("TopOpeBRepTool_ShapeTool::Pnt");
   }
   return BRep_Tool::Pnt(TopoDS::Vertex(S));
 }
@@ -318,7 +316,7 @@ Standard_Real TopOpeBRepTool_ShapeTool::PeriodizeParameter
 
   Standard_Real first,last,tolpc;
   const Handle(Geom2d_Curve) PC = FC2D_CurveOnSurface(E,F,first,last,tolpc);
-  if (PC.IsNull()) Standard_ProgramError::Raise("ShapeTool::PeriodizeParameter : no 2d curve");
+  if (PC.IsNull()) throw Standard_ProgramError("ShapeTool::PeriodizeParameter : no 2d curve");
 
   Handle(Standard_Type) TheType = PC->DynamicType();
   if (TheType == STANDARD_TYPE(Geom2d_Line)) {
index 0789697..bd3ba61 100644 (file)
@@ -96,7 +96,7 @@ Standard_Boolean TopOpeBRepTool_face::IsDone() const
 
 Standard_Boolean TopOpeBRepTool_face::Finite() const
 {
-  if (!IsDone()) Standard_Failure::Raise("TopOpeBRepTool_face NOT DONE");
+  if (!IsDone()) throw Standard_Failure("TopOpeBRepTool_face NOT DONE");
   return myfinite;
 }
 
@@ -107,7 +107,7 @@ Standard_Boolean TopOpeBRepTool_face::Finite() const
 
 const TopoDS_Face& TopOpeBRepTool_face::Ffinite() const
 {
-  if (!IsDone()) Standard_Failure::Raise("TopOpeBRepTool_face NOT DONE");
+  if (!IsDone()) throw Standard_Failure("TopOpeBRepTool_face NOT DONE");
   return myFfinite;
 }
 
index 80fa125..e248834 100644 (file)
@@ -111,11 +111,11 @@ void TopoDS_Builder::Add (TopoDS_Shape& aShape,
       aShape.TShape()->Modified(Standard_True);
     }
     else {
-      TopoDS_UnCompatibleShapes::Raise("TopoDS_Builder::Add");
+      throw TopoDS_UnCompatibleShapes("TopoDS_Builder::Add");
     }
   }
   else {
-    TopoDS_FrozenShape::Raise("TopoDS_Buider::Add");
+    throw TopoDS_FrozenShape("TopoDS_Buider::Add");
   }
 }
 
index d711570..5161492 100644 (file)
@@ -30,7 +30,7 @@ DEFINE_STANDARD_HANDLE(TopoDS_FrozenShape, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_TopoDS_FrozenShape
   #define TopoDS_FrozenShape_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) TopoDS_FrozenShape::Raise(MESSAGE);
+  if (CONDITION) throw TopoDS_FrozenShape(MESSAGE);
 #else
   #define TopoDS_FrozenShape_Raise_if(CONDITION, MESSAGE)
 #endif
index 9b9c841..609f1bb 100644 (file)
@@ -30,7 +30,7 @@ DEFINE_STANDARD_HANDLE(TopoDS_LockedShape, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_TopoDS_LockedShape
   #define TopoDS_LockedShape_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) TopoDS_LockedShape::Raise(MESSAGE);
+  if (CONDITION) throw TopoDS_LockedShape(MESSAGE);
 #else
   #define TopoDS_LockedShape_Raise_if(CONDITION, MESSAGE)
 #endif
index 9f6edf5..48775c5 100644 (file)
@@ -29,7 +29,7 @@ DEFINE_STANDARD_HANDLE(TopoDS_UnCompatibleShapes, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_TopoDS_UnCompatibleShapes
   #define TopoDS_UnCompatibleShapes_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) TopoDS_UnCompatibleShapes::Raise(MESSAGE);
+  if (CONDITION) throw TopoDS_UnCompatibleShapes(MESSAGE);
 #else
   #define TopoDS_UnCompatibleShapes_Raise_if(CONDITION, MESSAGE)
 #endif
index c13e858..83e06a4 100644 (file)
@@ -130,8 +130,7 @@ Handle(Transfer_Binder)  Transfer_Binder::NextResult () const
 
 void Transfer_Binder::SetResultPresent ()
 {
-  if (thestatus == Transfer_StatusUsed) Transfer_TransferFailure::Raise
-    ("Binder : SetResult, Result is Already Set and Used");
+  if (thestatus == Transfer_StatusUsed) throw Transfer_TransferFailure("Binder : SetResult, Result is Already Set and Used");
   theexecst = Transfer_StatusDone;
   thestatus = Transfer_StatusDefined;
 }
index c5b0fa3..04c8d1b 100644 (file)
@@ -27,8 +27,7 @@ Transfer_Iterator::Transfer_Iterator (const Standard_Boolean withstarts)
     void  Transfer_Iterator::Add
   (const Handle(Transfer_Binder)& binder)
 {
-  if (!thestarts.IsNull()) Standard_NoSuchObject::Raise
-    ("Transfer_Iterator : Add, Starting Object required not provided");
+  if (!thestarts.IsNull()) throw Standard_NoSuchObject("Transfer_Iterator : Add, Starting Object required not provided");
   AddItem(binder);
 }
 
@@ -65,11 +64,10 @@ Transfer_Iterator::Transfer_Iterator (const Standard_Boolean withstarts)
 
     const TheStart&  Transfer_Iterator::Starting () const
 {
-//  if (thecurr == 0 || thecurr > themaxi) Standard_NoSuchObject::Raise
+//  if (thecurr == 0 || thecurr > themaxi) throw Standard_NoSuchObject
 //    ("TransferIterator : Starting");
-//  if (theselect->Value(thecurr) == 0)    Standard_NoSuchObject::Raise
+//  if (theselect->Value(thecurr) == 0)    throw Standard_NoSuchObject
 //    ("TransferIterator : Starting");
-  if (thestarts.IsNull()) Standard_NoSuchObject::Raise
-    ("TransferIterator : No Starting defined at all");
+  if (thestarts.IsNull()) throw Standard_NoSuchObject("TransferIterator : No Starting defined at all");
   return thestarts->Value(thecurr);
 }
index fc45721..8ae3db4 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Transfer_TransferDeadLoop, Transfer_TransferFailure)
 
 #if !defined No_Exception && !defined No_Transfer_TransferDeadLoop
   #define Transfer_TransferDeadLoop_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Transfer_TransferDeadLoop::Raise(MESSAGE);
+  if (CONDITION) throw Transfer_TransferDeadLoop(MESSAGE);
 #else
   #define Transfer_TransferDeadLoop_Raise_if(CONDITION, MESSAGE)
 #endif
index d15d116..de09bec 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Transfer_TransferFailure, Interface_InterfaceError)
 
 #if !defined No_Exception && !defined No_Transfer_TransferFailure
   #define Transfer_TransferFailure_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Transfer_TransferFailure::Raise(MESSAGE);
+  if (CONDITION) throw Transfer_TransferFailure(MESSAGE);
 #else
   #define Transfer_TransferFailure_Raise_if(CONDITION, MESSAGE)
 #endif
index d4dec90..7a95c32 100644 (file)
@@ -56,8 +56,7 @@ Transfer_TransferInput::Transfer_TransferInput ()    {  }
       for (Standard_Integer i = 1; i <= nbres; i ++)
        iter.AddItem(mulres->Value(i));
     }
-    else Transfer_TransferFailure::Raise
-      ("TransferInput : Entities, one of the Results is not Transient Handle");
+    else throw Transfer_TransferFailure("TransferInput : Entities, one of the Results is not Transient Handle");
   }
   return iter;
 }
index 26502df..9c10bb5 100644 (file)
@@ -121,10 +121,8 @@ static Handle(Standard_Transient)   nultrans;  // pour retour const&(Null)
 
     const Handle(Transfer_Binder)&  Transfer_TransferIterator::Value () const
 {
-  if (thecurr == 0 || thecurr > themaxi) Standard_NoSuchObject::Raise
-    ("TransferIterator : Value");
-  if (theselect->Value(thecurr) == 0)    Standard_NoSuchObject::Raise
-    ("TransferIterator : Value");
+  if (thecurr == 0 || thecurr > themaxi) throw Standard_NoSuchObject("TransferIterator : Value");
+  if (theselect->Value(thecurr) == 0)    throw Standard_NoSuchObject("TransferIterator : Value");
   return theitems->Value(thecurr);
 }
 
index 44db4d7..a3603b7 100644 (file)
@@ -56,8 +56,7 @@ Handle(Transfer_TransientProcess)  Transfer_TransferOutput::TransientProcess ()
 
 void  Transfer_TransferOutput::Transfer (const Handle(Standard_Transient)& obj)
 {
-  if (themodel->Number(obj) == 0) Transfer_TransferFailure::Raise
-    ("TransferOutput : Transfer, entities do not come from same initial model");
+  if (themodel->Number(obj) == 0) throw Transfer_TransferFailure("TransferOutput : Transfer, entities do not come from same initial model");
 //  Standard_Integer scope = 0;
 //  if (thescope) scope = theproc->NewScope (obj);
 
@@ -70,8 +69,7 @@ void  Transfer_TransferOutput::Transfer (const Handle(Standard_Transient)& obj)
 
 /*  switch (theundef) {
     case Transfer_UndefIgnore  : return;
-    case Transfer_UndefFailure : Transfer_TransferFailure::Raise
-      ("TransferOutput : Transfer Undefined as Failure");
+    case Transfer_UndefFailure : throw Transfer_TransferFailure("TransferOutput : Transfer Undefined as Failure");
     case Transfer_UndefContent : break; // on ne sait pas traiter ...
     case Transfer_UndefUser    : break; // idem
   }
index d8709bf..59155c5 100644 (file)
@@ -224,8 +224,7 @@ Standard_Boolean Transfer_TransferProcess::IsAlreadyUsed(const TheStart& start)
   Handle(Transfer_Binder) binder = Find(start); //,categ); skl
   if (binder.IsNull()) {
     StartTrace (binder,start,thelevel,4);
-    Transfer_TransferFailure::Raise
-      ("TransferProcess : IsAlreadyUsed, transfer not done cannot be used...");
+    throw Transfer_TransferFailure("TransferProcess : IsAlreadyUsed, transfer not done cannot be used...");
   }
   return (binder->Status() == Transfer_StatusUsed);
 }
@@ -277,8 +276,7 @@ void Transfer_TransferProcess::Bind (const TheStart& start,
     }
     else if (former->Status() == Transfer_StatusUsed) {
       StartTrace (former,start,thelevel,4);
-      Transfer_TransferFailure::Raise
-       ("TransferProcess : Bind, already Bound");
+      throw Transfer_TransferFailure("TransferProcess : Bind, already Bound");
     }
     else {
       if (thetrace > 2) StartTrace (former,start,thelevel,5);
@@ -734,7 +732,7 @@ void Transfer_TransferProcess::BindMultiple(const TheStart& start)
   if (!binder.IsNull()) {
     if (!binder->IsKind(STANDARD_TYPE(Transfer_MultipleBinder))) {
       StartTrace (thelastbnd,start,thelevel,4);
-      Transfer_TransferFailure::Raise ("TransferProcess : BindMultiple");
+      throw Transfer_TransferFailure("TransferProcess : BindMultiple");
     }
   }
   else Bind(start,new Transfer_MultipleBinder);//,categ);skl
@@ -755,10 +753,8 @@ void Transfer_TransferProcess::AddMultiple(const TheStart& start,
     Handle(Transfer_MultipleBinder)::DownCast(binder);
   if (multr.IsNull()) {
     StartTrace (binder,start,thelevel,4);
-    if (binder.IsNull()) Transfer_TransferFailure::Raise
-      ("TransferProcess : AddMultiple, nothing bound");
-    else                 Transfer_TransferFailure::Raise
-      ("TransferProcess : AddMultiple, Binder not a MultipleBinder");
+    if (binder.IsNull()) throw Transfer_TransferFailure("TransferProcess : AddMultiple, nothing bound");
+    else                 throw Transfer_TransferFailure("TransferProcess : AddMultiple, Binder not a MultipleBinder");
   }
   multr->AddResult(res);
 }
@@ -854,7 +850,7 @@ void Transfer_TransferProcess::SetRoot (const TheStart& start)
   Standard_Integer index = MapIndex(start);
   if (index == 0) {
     //StartTrace (thelastbnd,start,thelevel,4);
-    //Transfer_TransferFailure::Raise("TransferProcess : SetRoot");
+    //throw Transfer_TransferFailure("TransferProcess : SetRoot");
     return;
   }
 
@@ -1032,8 +1028,7 @@ Handle(Transfer_Binder) Transfer_TransferProcess::Transferring(const TheStart& s
 //       (*themessenger->Out()) << flush;
        }
        else StartTrace (former, start,thelevel,4);
-       Transfer_TransferFailure::Raise
-         ("TransferProcess : Transfer in Error Status");
+       throw Transfer_TransferFailure("TransferProcess : Transfer in Error Status");
       case Transfer_StatusLoop :                  // la boucle est bouclee ...
        if (thetrace) {
          themessenger << "                  *** Transfer  Head of Dead Loop  :" << endl;
@@ -1041,8 +1036,7 @@ Handle(Transfer_Binder) Transfer_TransferProcess::Transferring(const TheStart& s
 //       (*themessenger->Out()) << flush;
        }
        else StartTrace (former, start,thelevel,4);
-       Transfer_TransferDeadLoop::Raise
-         ("TransferProcess : Transfer at Head of a Dead Loop");
+       throw Transfer_TransferDeadLoop("TransferProcess : Transfer at Head of a Dead Loop");
     }
 #ifdef TRANSLOG
     cout << "Transfer,level "<<thelevel<<Message_Flush;
@@ -1080,7 +1074,7 @@ Handle(Transfer_Binder) Transfer_TransferProcess::Transferring(const TheStart& s
          StartTrace (binder, start, thelevel-1,0);
        }
        else StartTrace (binder, start,thelevel-1,4);
-       Transfer_TransferFailure::Raise("TransferProcess : Head of Dead Loop");
+       throw Transfer_TransferFailure("TransferProcess : Head of Dead Loop");
 // Autrement dit, on change d exception (on est sorti de la boucle)
       } else {
        if (thetrace) {
@@ -1091,7 +1085,7 @@ Handle(Transfer_Binder) Transfer_TransferProcess::Transferring(const TheStart& s
       binder->AddFail("Transfer in dead Loop");
       thelevel = oldlev;
     }
-    catch (Standard_Failure) {
+    catch (Standard_Failure const& anException) {
       if (binder.IsNull()) {
        themessenger << "                  *** Exception Raised with no Result" << endl;
        binder = new Transfer_VoidBinder;
@@ -1099,7 +1093,7 @@ Handle(Transfer_Binder) Transfer_TransferProcess::Transferring(const TheStart& s
       }
       binder->AddFail("Transfer stopped by exception raising");
       if (thetrace) {
-       themessenger << "    *** Raised : " << Standard_Failure::Caught()->GetMessageString() << endl;
+       themessenger << "    *** Raised : " << anException.GetMessageString() << endl;
        StartTrace (binder, start, thelevel-1,4);
       }
       thelevel = oldlev;
index dda3338..ec7585f 100644 (file)
@@ -332,7 +332,7 @@ Handle(Units_Dimensions) Units::Dimensions(const Standard_CString aType)
        return qSeq->Value(i)->Dimensions();
      }
    }
-   Standard_NoSuchObject::Raise("Units::Dimensions");
+   throw Standard_NoSuchObject("Units::Dimensions");
  }
  return Units_Dimensions::ALess();
 }
index 33055b4..ee05da2 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Units_NoSuchType, Standard_NoSuchObject)
 
 #if !defined No_Exception && !defined No_Units_NoSuchType
   #define Units_NoSuchType_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Units_NoSuchType::Raise(MESSAGE);
+  if (CONDITION) throw Units_NoSuchType(MESSAGE);
 #else
   #define Units_NoSuchType_Raise_if(CONDITION, MESSAGE)
 #endif
index bf074d3..dad872f 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(Units_NoSuchUnit, Standard_NoSuchObject)
 
 #if !defined No_Exception && !defined No_Units_NoSuchUnit
   #define Units_NoSuchUnit_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) Units_NoSuchUnit::Raise(MESSAGE);
+  if (CONDITION) throw Units_NoSuchUnit(MESSAGE);
 #else
   #define Units_NoSuchUnit_Raise_if(CONDITION, MESSAGE)
 #endif
index 3969108..42901f6 100644 (file)
@@ -61,7 +61,7 @@ Units_Sentence::Units_Sentence(const Handle(Units_Lexicon)& alexicon,
   thesequenceoftokens = new Units_TokensSequence();
   Handle(Units_TokensSequence) lstlexicon=alexicon->Sequence();
   if(lstlexicon.IsNull())
-    Units_NoSuchType::Raise("BAD LEXICON descriptor");
+    throw Units_NoSuchType("BAD LEXICON descriptor");
   limchain=strlen(astring);
   i=0;
 
index 7313734..50b1e25 100644 (file)
@@ -186,12 +186,12 @@ void Units_UnitsSystem::Remove(const Standard_CString aquantity,
        }
       }
       
-      Units_NoSuchUnit::Raise(aunit);
+      throw Units_NoSuchUnit(aunit);
       
     }
   }
   
-  Units_NoSuchType::Raise(aquantity);
+  throw Units_NoSuchType(aquantity);
 }
 
 
@@ -219,11 +219,11 @@ void Units_UnitsSystem::Activate(const Standard_CString aquantity,
           return;
         }
       }
-      Units_NoSuchUnit::Raise(aunit);
+      throw Units_NoSuchUnit(aunit);
     }
   }
 
-  Units_NoSuchType::Raise(aquantity);
+  throw Units_NoSuchType(aquantity);
 }
 
 
@@ -276,8 +276,7 @@ TCollection_AsciiString Units_UnitsSystem::ActiveUnit(const Standard_CString aqu
     }
   }
 
-  Units_NoSuchType::Raise(aquantity);
-  return TCollection_AsciiString() ;
+  throw Units_NoSuchType(aquantity);
 }
 
 
index 4304229..3e2f231 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(V3d_BadValue, Standard_OutOfRange)
 
 #if !defined No_Exception && !defined No_V3d_BadValue
   #define V3d_BadValue_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) V3d_BadValue::Raise(MESSAGE);
+  if (CONDITION) throw V3d_BadValue(MESSAGE);
 #else
   #define V3d_BadValue_Raise_if(CONDITION, MESSAGE)
 #endif
index a678e78..cadd30e 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(V3d_UnMapped, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_V3d_UnMapped
   #define V3d_UnMapped_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) V3d_UnMapped::Raise(MESSAGE);
+  if (CONDITION) throw V3d_UnMapped(MESSAGE);
 #else
   #define V3d_UnMapped_Raise_if(CONDITION, MESSAGE)
 #endif
index ce30c49..b280fa6 100644 (file)
@@ -54,9 +54,8 @@ void V3d_View::SetLightOn (const Handle(V3d_Light)& theLight)
 {
   if (!myActiveLights.Contains (theLight))
   {
-    V3d_BadValue_Raise_if (myActiveLights.Extent() >= LightLimit(),
-                           "V3d_View::SetLightOn, "
-                           "too many lights");
+    if (myActiveLights.Extent() >= LightLimit())
+      throw V3d_BadValue("V3d_View::SetLightOn, too many lights");
     myActiveLights.Append (theLight);
     UpdateLights();
   }
@@ -68,9 +67,8 @@ void V3d_View::SetLightOn (const Handle(V3d_Light)& theLight)
 //=============================================================================
 void V3d_View::SetLightOff (const Handle(V3d_Light)& theLight)
 {
-  Standard_TypeMismatch_Raise_if (MyViewer->IsGlobalLight (theLight),
-                                  "V3d_View::SetLightOff, "
-                                  "the light is global");
+  if (MyViewer->IsGlobalLight (theLight))
+    throw Standard_TypeMismatch("V3d_View::SetLightOff, the light is global");
   myActiveLights.Remove (theLight);
   UpdateLights();
 }
index 462c182..0f57434 100644 (file)
@@ -50,7 +50,7 @@ void V3d_View::Move (const Standard_Real Dx,
     gp_Dir anUp (aCamera->Up());
     if (!ScreenAxis (aReferencePlane, anUp, myXscreenAxis, myYscreenAxis, myZscreenAxis))
     {
-          V3d_BadValue::Raise ("V3d_View::Translate, alignment of Eye,At,Up");
+          throw V3d_BadValue("V3d_View::Translate, alignment of Eye,At,Up");
     }
   }
 
@@ -136,7 +136,7 @@ void V3d_View::Translate (const Standard_Real Dx,
     gp_Dir anUp (aCamera->Up());
     if (!ScreenAxis (aReferencePlane, anUp,
                  myXscreenAxis,myYscreenAxis,myZscreenAxis))
-             V3d_BadValue::Raise ("V3d_View::Translate, alignment of Eye,At,Up");
+             throw V3d_BadValue("V3d_View::Translate, alignment of Eye,At,Up");
   }
 
   Standard_Real XX, XY, XZ, YX, YY, YZ, ZX, ZY, ZZ;
index 1af781f..3dc9aa8 100644 (file)
@@ -231,7 +231,8 @@ void V3d_Viewer::UnHighlight() const
 
 void V3d_Viewer::SetDefaultViewSize (const Standard_Real theSize)
 {
-  V3d_BadValue_Raise_if (theSize <= 0.0, "V3d_Viewer::SetDefaultViewSize, bad size");
+  if (theSize <= 0.0)
+    throw V3d_BadValue("V3d_Viewer::SetDefaultViewSize, bad size");
   myViewSize = theSize;
 }
 
index 5572280..eeca0be 100644 (file)
@@ -3417,10 +3417,10 @@ static int VExport(Draw_Interpretor& di, Standard_Integer argc, const char** arg
       di << "Error: export of image to " << aFormatStr << " failed!\n";
     }
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
     di << "Error: export of image to " << aFormatStr << " failed";
-    di << " (exception: " << Standard_Failure::Caught()->GetMessageString() << ")";
+    di << " (exception: " << anException.GetMessageString() << ")";
   }
   Standard_ENABLE_DEPRECATION_WARNINGS
   return 0;
index 3b24d06..272816b 100644 (file)
@@ -35,7 +35,7 @@ Vrml_DirectionalLight::Vrml_DirectionalLight():
   myOnOff = aOnOff;
   if (aIntensity < 0. || aIntensity > 1.)
     {
-      Standard_Failure::Raise("Error : Light intensity must be in the range 0.0 to 1.0, inclusive.");
+      throw Standard_Failure("Error : Light intensity must be in the range 0.0 to 1.0, inclusive.");
     }
   myIntensity = aIntensity;
   myColor = aColor;
@@ -56,7 +56,7 @@ void Vrml_DirectionalLight::SetIntensity(const Standard_Real aIntensity)
 {
   if (aIntensity < 0. || aIntensity > 1.)
     {
-      Standard_Failure::Raise("Error : Light intensity must be in the range 0.0 to 1.0, inclusive.");
+      throw Standard_Failure("Error : Light intensity must be in the range 0.0 to 1.0, inclusive.");
     }
   myIntensity = aIntensity;
 }
index 4fd77ac..265110d 100644 (file)
@@ -34,7 +34,7 @@ Vrml_Material::Vrml_Material(const Handle(Quantity_HArray1OfColor)& aAmbientColo
    {
      if (aShininess->Value(i) < 0. || aShininess->Value(i) > 1.)
        {
-        Standard_Failure::Raise("The value of aShininess is out of range (0 - 1)");
+        throw Standard_Failure("The value of aShininess is out of range (0 - 1)");
        }
    }
  myShininess     = aShininess;
@@ -43,7 +43,7 @@ Vrml_Material::Vrml_Material(const Handle(Quantity_HArray1OfColor)& aAmbientColo
    {
      if (aTransparency->Value(i) < 0. || aTransparency->Value(i) > 1.)
        {
-        Standard_Failure::Raise("The value of aTransparency is out of range (0 - 1)");
+        throw Standard_Failure("The value of aTransparency is out of range (0 - 1)");
        }
    }
  myTransparency  = aTransparency;
@@ -118,7 +118,7 @@ void Vrml_Material::SetShininess(const Handle(TColStd_HArray1OfReal)& aShininess
    {
      if (aShininess->Value(i) < 0. || aShininess->Value(i) > 1.)
        {
-        Standard_Failure::Raise("The value of aShininess is out of range (0 - 1)");
+        throw Standard_Failure("The value of aShininess is out of range (0 - 1)");
        }
    }
  myShininess = aShininess;
@@ -136,7 +136,7 @@ void Vrml_Material::SetTransparency(const Handle(TColStd_HArray1OfReal)& aTransp
    {
      if (aTransparency->Value(i) < 0. || aTransparency->Value(i) > 1.)
        {
-        Standard_Failure::Raise("The value of aTransparency is out of range (0 - 1)");
+        throw Standard_Failure("The value of aTransparency is out of range (0 - 1)");
        }
    }
  myTransparency = aTransparency;
index f5b22c3..5585fec 100644 (file)
@@ -34,7 +34,7 @@ Vrml_PointLight::Vrml_PointLight():
 {
   if (aIntensity < 0. || aIntensity > 1.)
     {
-      Standard_Failure::Raise("Error : Light intensity must be in the range 0.0 to 1.0, inclusive.");
+      throw Standard_Failure("Error : Light intensity must be in the range 0.0 to 1.0, inclusive.");
     }
   myOnOff = aOnOff;
   myIntensity = aIntensity;
@@ -56,7 +56,7 @@ void Vrml_PointLight::SetIntensity(const Standard_Real aIntensity)
 {
   if (aIntensity < 0. || aIntensity > 1.)
     {
-      Standard_Failure::Raise("Error : Light intensity must be in the range 0.0 to 1.0, inclusive.");
+      throw Standard_Failure("Error : Light intensity must be in the range 0.0 to 1.0, inclusive.");
     }
   myIntensity = aIntensity;
 }
index ab95f52..0ecbc5d 100644 (file)
@@ -30,7 +30,7 @@ Vrml_SFImage::Vrml_SFImage()
   Standard_Integer size = aWidth*aHeight;
   if (anArray->Length() != size)
     {
-      Standard_Failure::Raise("The size of Array is no equal (aWidth*aHeight)");
+      throw Standard_Failure("The size of Array is no equal (aWidth*aHeight)");
     }
   myWidth  = aWidth;
   myHeight = aHeight;
@@ -74,7 +74,7 @@ void Vrml_SFImage::SetArray(const Handle(TColStd_HArray1OfInteger)& anArray)
   Standard_Integer size = myWidth*myHeight;
   if (anArray->Length() != size)
     {
-      Standard_Failure::Raise("The size of Array is no equal (aWidth*aHeight)");
+      throw Standard_Failure("The size of Array is no equal (aWidth*aHeight)");
       }
   myArray = anArray; 
   myArrayFlag = Standard_True;
index 39f5b3a..23f2e51 100644 (file)
@@ -43,7 +43,7 @@ Vrml_SpotLight::Vrml_SpotLight():
   myOnOff = aOnOff;
   if (aIntensity < 0. || aIntensity > 1.)
     {
-      Standard_Failure::Raise("Error : Light intensity must be in the range 0.0 to 1.0, inclusive.");
+      throw Standard_Failure("Error : Light intensity must be in the range 0.0 to 1.0, inclusive.");
     }
   myIntensity = aIntensity;
   myColor = aColor;
@@ -67,7 +67,7 @@ void Vrml_SpotLight::SetIntensity(const Standard_Real aIntensity)
 {
   if (aIntensity < 0. || aIntensity > 1.)
     {
-      Standard_Failure::Raise("Error : Light intensity must be in the range 0.0 to 1.0, inclusive.");
+      throw Standard_Failure("Error : Light intensity must be in the range 0.0 to 1.0, inclusive.");
     }
   myIntensity = aIntensity;
 }
index dfb5aec..c38cd4a 100644 (file)
@@ -110,7 +110,7 @@ VrmlConverter_Projector::VrmlConverter_Projector (const TopTools_Array1OfShape&
 
   if( Ypers.IsParallel(Zpers,Precision::Angular()) )
     {
-      Standard_Failure::Raise("Projection Vector is Parallel to High Point Direction");
+      throw Standard_Failure("Projection Vector is Parallel to High Point Direction");
     }
   gp_Dir Xpers = Ypers.Crossed(Zpers);
 
index c2e8a89..0e47c60 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(WNT_ClassDefinitionError, Standard_ConstructionError)
 
 #if !defined No_Exception && !defined No_WNT_ClassDefinitionError
   #define WNT_ClassDefinitionError_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) WNT_ClassDefinitionError::Raise(MESSAGE);
+  if (CONDITION) throw WNT_ClassDefinitionError(MESSAGE);
 #else
   #define WNT_ClassDefinitionError_Raise_if(CONDITION, MESSAGE)
 #endif
index 519cbae..0f4c4c1 100644 (file)
@@ -56,7 +56,7 @@ WNT_WClass::WNT_WClass (const TCollection_AsciiString& theClassName,
   if (!RegisterClassW (&aWinClass))
   {
     myClassName.Clear();
-    WNT_ClassDefinitionError::Raise ("Unable to register window class");
+    throw WNT_ClassDefinitionError("Unable to register window class");
   }
   myWndProc = (Standard_Address )aWinClass.lpfnWndProc;
 }
index 31e7c8a..4fad84e 100644 (file)
@@ -53,7 +53,7 @@ WNT_Window::WNT_Window (const Standard_CString           theTitle,
 {
   if (thePxWidth <= 0 || thePxHeight <= 0)
   {
-    Aspect_WindowDefinitionError::Raise ("Coordinate(s) out of range");
+    throw Aspect_WindowDefinitionError("Coordinate(s) out of range");
   }
 
   DWORD aStyle = theStyle;
@@ -90,7 +90,7 @@ WNT_Window::WNT_Window (const Standard_CString           theTitle,
                              theClientStruct);
   if (!myHWindow)
   {
-    Aspect_WindowDefinitionError::Raise ("Unable to create window");
+    throw Aspect_WindowDefinitionError("Unable to create window");
   }
 
   myHParentWindow = theParent;
index 64c818c..c1fc093 100644 (file)
@@ -652,7 +652,7 @@ static Standard_Integer CheckProps (Draw_Interpretor& di, Standard_Integer argc,
          di << string8;
        }
       }
-      catch (Standard_Failure) {
+      catch (Standard_Failure const& anException) {
        //printf ( "%40.40s", "exception" );
        char string9[260];
        Sprintf (string9, "%40.40s", "exception" );
@@ -660,9 +660,10 @@ static Standard_Integer CheckProps (Draw_Interpretor& di, Standard_Integer argc,
 #ifdef OCCT_DEBUG
        //fflush ( stdout );
        di << ": ";
-       di << Standard_Failure::Caught()->GetMessageString();
+       di << anException.GetMessageString();
        di<<" ** Skip\n";
 #endif
+       (void)anException;
       }
     }
     else if ( wholeDoc ) {
index edd5a75..7b35844 100644 (file)
@@ -152,12 +152,13 @@ TopoDS_Shape XSAlgo_AlgoContainer::ProcessShape (const TopoDS_Shape& shape,
          context->SetResult ( S );
        }
       }
-      catch (Standard_Failure) {
+      catch (Standard_Failure const& anException) {
 #ifdef OCCT_DEBUG
        cout << "Error: XSAlgo_AlgoContainer::ProcessShape(): Exception in ShapeFix::Shape" << endl;
-        Standard_Failure::Caught()->Print(cout); cout << endl;
+        anException.Print(cout); cout << endl;
 #endif
-      }  
+       (void)anException;
+      }
       return context->Result();
     }
     // for writing, define default sequence of DirectFaces
index a4b0099..c18c160 100644 (file)
@@ -126,7 +126,7 @@ void XSControl_Controller::Record (const Standard_CString theName) const
     if (newadapt->IsKind(thisadapt->DynamicType()))
       return;
     if (!(thisadapt->IsKind(newadapt->DynamicType())) && thisadapt != newadapt)
-      Standard_DomainError::Raise("XSControl_Controller : Record");
+      throw Standard_DomainError("XSControl_Controller : Record");
   }
   listad.Bind(theName, this);
 }
index 46b0edb..b1d059a 100644 (file)
@@ -106,9 +106,9 @@ IFSelect_ReturnStatus XSControl_TransferWriter::TransferWriteTransient
     status = myController->TransferWriteTransient
       (obj,myTransferWriter,model,myTransferMode);
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     sout<<"****  ****  TransferWriteShape, EXCEPTION : ";
-    sout<<Standard_Failure::Caught()->GetMessageString(); 
+    sout<<anException.GetMessageString(); 
     sout<<endl;
     status = IFSelect_RetFail;
   }
@@ -154,9 +154,9 @@ IFSelect_ReturnStatus XSControl_TransferWriter::TransferWriteShape
     status = myController->TransferWriteShape
       (shape,myTransferWriter,model,myTransferMode);
   }
-  catch(Standard_Failure) {
+  catch(Standard_Failure const& anException) {
     sout<<"****  ****  TransferWriteShape, EXCEPTION : "; 
-    sout<<Standard_Failure::Caught()->GetMessageString(); 
+    sout<<anException.GetMessageString(); 
     sout<<endl;
     status = IFSelect_RetFail;
   }
index f0ca0c2..8e1508b 100644 (file)
@@ -138,7 +138,7 @@ static const Standard_ExtString   voidext = { 0 };
   DeclareAndCast(TColStd_HSequenceOfTransient,seqt,seqval);
   if (!seqt.IsNull())
     {  if (num <= seqt->Length()) val = seqt->Value(num);  return val;  }
-//  Standard_TypeMismatch::Raise("XSControl_Utils::SeqTraValue");
+//  throw Standard_TypeMismatch("XSControl_Utils::SeqTraValue");
   return val;
 }
 
@@ -515,7 +515,7 @@ static const Standard_ExtString   voidext = { 0 };
   if (!seqh.IsNull()) return seqh->Length();
   DeclareAndCast(TColStd_HSequenceOfInteger,seqi,seqval);
   if (!seqi.IsNull()) return seqi->Length();
-//  Standard_TypeMismatch::Raise("XSControl_Utils::SeqLength");
+//  throw Standard_TypeMismatch("XSControl_Utils::SeqLength");
   return 0;
 }
 
@@ -541,8 +541,7 @@ static const Standard_ExtString   voidext = { 0 };
     for (i = 1; i <= lng; i ++)  arrt->SetValue (i-first+1,seqt->Value(i));
     return arrt;
   }
-  Standard_TypeMismatch::Raise("XSControl_Utils::SeqToArr");
-  return val;
+  throw Standard_TypeMismatch("XSControl_Utils::SeqToArr");
 }
 
 
@@ -570,8 +569,7 @@ static const Standard_ExtString   voidext = { 0 };
     for (i = first; i <= last; i ++)  seqt->Append (arrt->Value(i));
     return seqt;
   }
-  Standard_TypeMismatch::Raise("XSControl_Utils::ArrToSeq");
-  return val;
+  throw Standard_TypeMismatch("XSControl_Utils::ArrToSeq");
 }
 
 
index 07c3152..eac3ad3 100644 (file)
@@ -211,9 +211,9 @@ static Standard_Integer igesbrep (Draw_Interpretor& di, Standard_Integer argc, c
          OCC_CATCH_SIGNALS
          DBRep::Set(fname,shape);
        }
-       catch(Standard_Failure) {
+       catch(Standard_Failure const& anException) {
          di << "** Exception : ";
-         di << Standard_Failure::Caught()->GetMessageString();
+         di << anException.GetMessageString();
          di<<" ** Skip\n";
          di << "Saving shape in variable Draw : " << fname << "\n";
          WriteShape (shape,1);
@@ -234,9 +234,9 @@ static Standard_Integer igesbrep (Draw_Interpretor& di, Standard_Integer argc, c
            OCC_CATCH_SIGNALS
            DBRep::Set(fname,shape);
          }
-         catch(Standard_Failure) {
+         catch(Standard_Failure const& anException) {
            di << "** Exception : ";
-           di << Standard_Failure::Caught()->GetMessageString();
+           di << anException.GetMessageString();
            di<<" ** Skip\n";
          }
        }
@@ -298,9 +298,9 @@ static Standard_Integer igesbrep (Draw_Interpretor& di, Standard_Integer argc, c
           OCC_CATCH_SIGNALS
           DBRep::Set(fname,shape);
         }
-        catch(Standard_Failure) {
+        catch(Standard_Failure const& anException) {
           di << "** Exception : ";
-         di << Standard_Failure::Caught()->GetMessageString();
+         di << anException.GetMessageString();
          di<<" ** Skip\n";
           di << "Saving shape in variable Draw : " << fname << "\n";
           WriteShape (shape,1);
index 59b3cec..4c62729 100644 (file)
@@ -61,9 +61,7 @@ const Handle(Standard_Transient)& XmlDrivers::Factory(const Standard_GUID& theGU
     return model_rd;
   }
  
-  Standard_Failure::Raise ("XmlDrivers : unknown GUID");
-  static Handle(Standard_Transient) aNullHandle;
-  return aNullHandle;
+  throw Standard_Failure("XmlDrivers : unknown GUID");
 }
 
 //=======================================================================
index 6419e71..9b381c2 100644 (file)
@@ -61,9 +61,7 @@ const Handle(Standard_Transient)& XmlLDrivers::Factory(const Standard_GUID& theG
     return model_rd;
   }
  
-  Standard_Failure::Raise ("XmlLDrivers : unknown GUID");
-  static Handle(Standard_Transient) aNullHandle;
-  return aNullHandle;
+  throw Standard_Failure("XmlLDrivers : unknown GUID");
 }
 
 #define SLENGTH 80
index db72502..6b677e0 100644 (file)
@@ -197,7 +197,7 @@ void XmlLDrivers_DocumentRetrievalDriver::Read
                                       theFileName + " cannot be opened for reading";
 
     theApplication->MessageDriver()->Write (aMsg.ToExtString());
-    Standard_Failure::Raise("File cannot be opened for reading");
+    throw Standard_Failure("File cannot be opened for reading");
   }
 }
 
@@ -451,9 +451,9 @@ void XmlLDrivers_DocumentRetrievalDriver::ReadFromDomDocument
     else
       myReaderStatus = PCDM_RS_OK;
   }
-  catch (Standard_Failure)
+  catch (Standard_Failure const& anException)
   {
-    TCollection_ExtendedString anErrorString (Standard_Failure::Caught()->GetMessageString());
+    TCollection_ExtendedString anErrorString (anException.GetMessageString());
     aMsgDriver -> Write (anErrorString.ToExtString());
   }
 
index 9a87517..48d4ada 100644 (file)
@@ -112,7 +112,7 @@ void XmlLDrivers_DocumentStorageDriver::Write (const Handle(CDM_Document)&
                                       theFileName + " cannot be opened for writing";
 
     theDocument->Application()->MessageDriver()->Write (aMsg.ToExtString());
-    Standard_Failure::Raise("File cannot be opened for writing");
+    throw Standard_Failure("File cannot be opened for writing");
   }
 }
 
@@ -150,7 +150,7 @@ Standard_EXPORT void XmlLDrivers_DocumentStorageDriver::Write (const Handle(CDM_
                                         " cannot be used for writing";
       theDocument->Application()->MessageDriver()->Write (aMsg.ToExtString());
       
-      Standard_Failure::Raise("File cannot be opened for writing");
+      throw Standard_Failure("File cannot be opened for writing");
     }
 
     ::take_time (0, " +++++ Fin formatting to XML : ", aMessageDriver);
@@ -312,11 +312,11 @@ Standard_Boolean XmlLDrivers_DocumentStorageDriver::WriteToDomDocument (const Ha
       OCC_CATCH_SIGNALS
       anObjNb = MakeDocument(theDocument, theElement);
     }
-    catch (Standard_Failure)
+    catch (Standard_Failure const& anException)
     {
       SetIsError (Standard_True);
       SetStoreStatus(PCDM_SS_Failure);
-      TCollection_ExtendedString anErrorString (Standard_Failure::Caught()->GetMessageString());
+      TCollection_ExtendedString anErrorString (anException.GetMessageString());
       aMessageDriver -> Write (anErrorString.ToExtString());
     }
   }
index d832124..6c5fedd 100644 (file)
@@ -344,8 +344,7 @@ static TDataXtd_ConstraintEnum ConstraintTypeEnum (const XmlObjMgt_DOMString& th
     else if (theString.equals (::ConOffsetString()))
       aResult = TDataXtd_OFFSET;
     else
-      Standard_DomainError::Raise
-        ("TDataXtd_ConstraintEnum; string value without enum term equivalence");
+      throw Standard_DomainError("TDataXtd_ConstraintEnum; string value without enum term equivalence");
   }
   return aResult;
 }
@@ -388,8 +387,6 @@ static const XmlObjMgt_DOMString& ConstraintTypeString (const TDataXtd_Constrain
   case TDataXtd_OFFSET         : return ::ConOffsetString();
     
   default:
-    Standard_DomainError::Raise("TDataXtd_ConstraintEnum; enum term unknown");
+    throw Standard_DomainError("TDataXtd_ConstraintEnum; enum term unknown");
   }
-  static XmlObjMgt_DOMString aNullString;
-  return aNullString; // To avoid compilation error message.
 }
index b5ae593..ff170ee 100644 (file)
@@ -133,8 +133,6 @@ static const XmlObjMgt_DOMString& GeometryTypeString
   case TDataXtd_ELLIPSE  : return ::GeomEllipseString();
     
   default:
-    Standard_DomainError::Raise("TDataXtd_GeometryEnum; enum term unknown");
+    throw Standard_DomainError("TDataXtd_GeometryEnum; enum term unknown");
   }
-  static XmlObjMgt_DOMString aNullString;
-  return aNullString; // To avoid compilation error message.
 }
index 79c371c..b48da1c 100644 (file)
@@ -166,7 +166,7 @@ Standard_Boolean XmlMNaming_NamedShapeDriver::Paste
       //      aBld.Replace(anOldShape,aNewShape);
       //      break;
     default:
-      Standard_DomainError::Raise("TNaming_Evolution; enum term unknown");
+      throw Standard_DomainError("TNaming_Evolution; enum term unknown");
     }
     anOldShape.Nullify();
     aNewShape.Nullify();
@@ -252,10 +252,8 @@ static const XmlObjMgt_DOMString& EvolutionString(const TNaming_Evolution i)
     case TNaming_SELECTED     : return ::EvolSelectedString();
     case TNaming_REPLACE      : return ::EvolModifyString();  //    case TNaming_REPLACE      : return ::EvolReplaceString(); for compatibility
   default:
-    Standard_DomainError::Raise("TNaming_Evolution; enum term unknown");
+    throw Standard_DomainError("TNaming_Evolution; enum term unknown");
   }
-  static XmlObjMgt_DOMString aNullString;
-  return aNullString; // To avoid compilation error message.
 }
 
 //=======================================================================
@@ -278,8 +276,7 @@ static TNaming_Evolution EvolutionEnum (const XmlObjMgt_DOMString& theString)
     else if (theString.equals (::EvolReplaceString()))
       aResult = TNaming_MODIFY; // for compatibility //TNaming_REPLACE;
     else
-      Standard_DomainError::Raise
-        ("TNaming_Evolution; string value without enum term equivalence");
+      throw Standard_DomainError("TNaming_Evolution; string value without enum term equivalence");
   }
   return aResult;
 }
index d52c14b..8283126 100644 (file)
@@ -368,10 +368,8 @@ static const XmlObjMgt_DOMString& NameTypeToString (const TNaming_NameType theE)
   case TNaming_WIREIN              : return ::NTWireInString();
   case TNaming_SHELLIN             : return ::NTShellInString();
   default:
-    Standard_DomainError::Raise("TNaming_NameType; enum term unknown ");
+    throw Standard_DomainError("TNaming_NameType; enum term unknown ");
   }
-  static XmlObjMgt_DOMString aNullString;
-  return aNullString; // To avoid compilation error message.
 }
 
 //=======================================================================
@@ -400,8 +398,7 @@ static TopAbs_ShapeEnum ShapeEnumFromString (const XmlObjMgt_DOMString& theStrin
     else if (theString.equals (::ShVertexString()))
       aResult = TopAbs_VERTEX;
     else
-      Standard_DomainError::Raise
-        ("TopAbs_ShapeEnum; string value without enum term equivalence");
+      throw Standard_DomainError("TopAbs_ShapeEnum; string value without enum term equivalence");
   }
   return aResult;
 }
@@ -438,8 +435,7 @@ static TNaming_NameType NameTypeFromString (const XmlObjMgt_DOMString& theString
     else if (theString.equals (::NTShellInString()))
       aResult = TNaming_SHELLIN;
     else
-      Standard_DomainError::Raise
-        ("TNaming_NameType; string value without enum term equivalence");
+      throw Standard_DomainError("TNaming_NameType; string value without enum term equivalence");
   }
   return aResult;
 }
index 3d1bcc8..f613a2c 100644 (file)
@@ -63,13 +63,11 @@ XmlMNaming_Shape1::XmlMNaming_Shape1 (const XmlObjMgt_Element& theEl)
     case '-' : myOrientation = TopAbs_REVERSED; break;
     case 'i' : myOrientation = TopAbs_INTERNAL; break;
     case 'e' : myOrientation = TopAbs_EXTERNAL; break;
-    default:       Standard_DomainError::Raise
-      ("XmlMNaming_Shape1; orientation value without enum term equivalence");
+    default:   throw Standard_DomainError("XmlMNaming_Shape1; orientation value without enum term equivalence");
     }
     Standard_CString anIntPtr = (Standard_CString) &aPtr[1];
     if (XmlObjMgt::GetInteger (anIntPtr, myTShapeID) == Standard_False)
-      Standard_DomainError::Raise
-        ("XmlMNaming_Shape1; tshape value cannot be initialised by integer");
+      throw Standard_DomainError("XmlMNaming_Shape1; tshape value cannot be initialised by integer");
   }
 }
 
index cd4004d..b756981 100644 (file)
@@ -76,16 +76,16 @@ Xw_Window::Xw_Window (const Handle(Aspect_DisplayConnection)& theXDisplay,
   int aDummy = 0;
   if (thePxWidth <= 0 || thePxHeight <= 0)
   {
-    Aspect_WindowDefinitionError::Raise ("Xw_Window, Coordinate(s) out of range");
+    throw Aspect_WindowDefinitionError("Xw_Window, Coordinate(s) out of range");
   }
   else if (theXDisplay.IsNull())
   {
-    Aspect_WindowDefinitionError::Raise ("Xw_Window, X Display connection is undefined");
+    throw Aspect_WindowDefinitionError("Xw_Window, X Display connection is undefined");
     return;
   }
   else if (!glXQueryExtension (myDisplay->GetDisplay(), &aDummy, &aDummy))
   {
-    Aspect_WindowDefinitionError::Raise ("Xw_Window, GLX extension is unavailable");
+    throw Aspect_WindowDefinitionError("Xw_Window, GLX extension is unavailable");
     return;
   }
 
@@ -125,7 +125,7 @@ Xw_Window::Xw_Window (const Handle(Aspect_DisplayConnection)& theXDisplay,
   }
   if (aVisInfo == NULL)
   {
-    Aspect_WindowDefinitionError::Raise ("Xw_Window, couldn't find compatible Visual (RGBA, double-buffered)");
+    throw Aspect_WindowDefinitionError("Xw_Window, couldn't find compatible Visual (RGBA, double-buffered)");
     return;
   }
 
@@ -147,7 +147,7 @@ Xw_Window::Xw_Window (const Handle(Aspect_DisplayConnection)& theXDisplay,
   XFree (aVisInfo); aVisInfo = NULL;
   if (myXWindow == 0)
   {
-    Aspect_WindowDefinitionError::Raise ("Xw_Window, Unable to create window");
+    throw Aspect_WindowDefinitionError("Xw_Window, Unable to create window");
     return;
   }
 
@@ -192,18 +192,18 @@ Xw_Window::Xw_Window (const Handle(Aspect_DisplayConnection)& theXDisplay,
   int aDummy = 0;
   if (theXWin == 0)
   {
-    Aspect_WindowDefinitionError::Raise ("Xw_Window, given invalid X window");
+    throw Aspect_WindowDefinitionError("Xw_Window, given invalid X window");
     return;
   }
   else if (theXDisplay.IsNull())
   {
-    Aspect_WindowDefinitionError::Raise ("Xw_Window, X Display connection is undefined");
+    throw Aspect_WindowDefinitionError("Xw_Window, X Display connection is undefined");
     return;
   }
   else if (!glXQueryExtension (myDisplay->GetDisplay(), &aDummy, &aDummy))
   {
     myXWindow = 0;
-    Aspect_WindowDefinitionError::Raise ("Xw_Window, GLX extension is unavailable");
+    throw Aspect_WindowDefinitionError("Xw_Window, GLX extension is unavailable");
     return;
   }
 
@@ -220,7 +220,7 @@ Xw_Window::Xw_Window (const Handle(Aspect_DisplayConnection)& theXDisplay,
   XVisualInfo* aVisInfo = XGetVisualInfo (aDisp, aVisInfoMask, &aVisInfoTmp, &aNbItems);
   if (aVisInfo == NULL)
   {
-    Aspect_WindowDefinitionError::Raise ("Xw_Window, Visual is unavailable");
+    throw Aspect_WindowDefinitionError("Xw_Window, Visual is unavailable");
     return;
   }
   XFree (aVisInfo);
index 120abb2..0196ec7 100644 (file)
@@ -131,7 +131,7 @@ void gp_GTrsf::SetForm()
   Standard_Real s = M.Determinant();
 
   if ( Abs(s) < gp::Resolution() )
-    Standard_ConstructionError::Raise("gp_GTrsf::SetForm, null determinant");
+    throw Standard_ConstructionError("gp_GTrsf::SetForm, null determinant");
 
   if (s > 0)
     s = Pow(s,1./3.);
index 511bf89..0091baf 100644 (file)
@@ -177,7 +177,7 @@ inline void gp_GTrsf::Transforms (Standard_Real& X,
 inline gp_Trsf gp_GTrsf::Trsf () const
 {
   if ( Form() == gp_Other )
-    Standard_ConstructionError::Raise("gp_GTrsf::Trsf() - non-orthogonal GTrsf");
+    throw Standard_ConstructionError("gp_GTrsf::Trsf() - non-orthogonal GTrsf");
 
   gp_Trsf T;
   T.shape = shape;
index 5519ea1..87f3b02 100644 (file)
@@ -144,22 +144,22 @@ gp_Trsf2d gp_GTrsf2d::Trsf2d () const
   const Standard_Real aTolerance2 = 2.0 * aTolerance;
 
   if ( Form() == gp_Other )
-    Standard_ConstructionError::Raise("gp_GTrsf2d::Trsf2d() - non-orthogonal GTrsf2d(0)");
+    throw Standard_ConstructionError("gp_GTrsf2d::Trsf2d() - non-orthogonal GTrsf2d(0)");
 
   Standard_Real value = (matrix.Value(1, 1) * matrix.Value(1, 1)
                       +  matrix.Value(2, 1) * matrix.Value(2, 1));
   if ( Abs(value - 1.) > aTolerance2 )
-    Standard_ConstructionError::Raise("gp_GTrsf2d::Trsf2d() - non-orthogonal GTrsf2d(1)");
+    throw Standard_ConstructionError("gp_GTrsf2d::Trsf2d() - non-orthogonal GTrsf2d(1)");
 
   value = (matrix.Value(1, 2) * matrix.Value(1, 2)
         +  matrix.Value(2, 2) * matrix.Value(2, 2));
   if ( Abs(value - 1.) > aTolerance2 )
-    Standard_ConstructionError::Raise("gp_GTrsf2d::Trsf2d() - non-orthogonal GTrsf2d(2)");
+    throw Standard_ConstructionError("gp_GTrsf2d::Trsf2d() - non-orthogonal GTrsf2d(2)");
 
   value = (matrix.Value(1, 1) * matrix.Value(1, 2)
         +  matrix.Value(2, 1) * matrix.Value(2, 2));
   if ( Abs(value) > aTolerance )
-    Standard_ConstructionError::Raise("gp_GTrsf2d::Trsf2d() - non-orthogonal GTrsf2d(3)");
+    throw Standard_ConstructionError("gp_GTrsf2d::Trsf2d() - non-orthogonal GTrsf2d(3)");
 
 
   gp_Trsf2d aTransformation;
index 2a9838c..21301c2 100644 (file)
@@ -61,7 +61,7 @@ Standard_Real gp_Vec2d::Angle (const gp_Vec2d& Other) const
   const Standard_Real theNorm = Magnitude();
   const Standard_Real theOtherNorm = Other.Magnitude();
   if (theNorm <= gp::Resolution() || theOtherNorm <= gp::Resolution())
-    gp_VectorWithNullMagnitude::Raise();
+    throw gp_VectorWithNullMagnitude();
 
   const Standard_Real D = theNorm * theOtherNorm;
   const Standard_Real Cosinus = coord.Dot   (Other.coord) / D;
index 7f4c797..c5a62bc 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(gp_VectorWithNullMagnitude, Standard_DomainError)
 
 #if !defined No_Exception && !defined No_gp_VectorWithNullMagnitude
   #define gp_VectorWithNullMagnitude_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) gp_VectorWithNullMagnitude::Raise(MESSAGE);
+  if (CONDITION) throw gp_VectorWithNullMagnitude(MESSAGE);
 #else
   #define gp_VectorWithNullMagnitude_Raise_if(CONDITION, MESSAGE)
 #endif
index 54dd640..5f965af 100644 (file)
@@ -34,7 +34,7 @@ math_EigenValuesSearcher::math_EigenValuesSearcher(const TColStd_Array1OfReal& D
 
   Standard_Integer n = Diagonal.Length();
   if (Subdiagonal.Length() != n)
-    Standard_Failure::Raise("math_EigenValuesSearcher : dimension mismatch");
+    throw Standard_Failure("math_EigenValuesSearcher : dimension mismatch");
 
   myDiagonal    = new TColStd_HArray1OfReal(1, n);
   myDiagonal->ChangeArray1() = Diagonal;
index 7e2f7a1..72b3ee9 100644 (file)
@@ -708,7 +708,7 @@ void math_FunctionSetRoot::Perform(math_FunctionSetWithDerivatives& F,
   if ((Neq <= 0)                      ||
     (StartingPoint.Length()!= Ninc) ||
     (theInfBound.Length() != Ninc)     ||
-    (theSupBound.Length() != Ninc))  { Standard_DimensionError:: Raise(); }
+    (theSupBound.Length() != Ninc))  { throw Standard_DimensionError(); }
 
   Standard_Integer i;
   Standard_Boolean ChangeDirection = Standard_False, Sort = Standard_False, isNewSol = Standard_False;
index d4ceca9..7f864bc 100644 (file)
@@ -61,7 +61,7 @@ math_Gauss::math_Gauss(const math_Matrix& A,
        StdFail_NotDone_Raise_if(!Done, " ");
 
        if(X.Length() != LU.RowNumber()) {
-         Standard_DimensionError::Raise();
+         throw Standard_DimensionError();
        }
        LU_Solve(LU,
                 Index,
index 3bdc476..f8cca05 100644 (file)
@@ -169,7 +169,7 @@ void math_Matrix::Invert()
     Sol.Invert(*this);
   }
   else {
-    math_SingularMatrix::Raise(); // SingularMatrix Exception;
+    throw math_SingularMatrix(); // SingularMatrix Exception;
   }
 }
 
index b42a56f..b436110 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(math_NotSquare, Standard_DimensionError)
 
 #if !defined No_Exception && !defined No_math_NotSquare
   #define math_NotSquare_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) math_NotSquare::Raise(MESSAGE);
+  if (CONDITION) throw math_NotSquare(MESSAGE);
 #else
   #define math_NotSquare_Raise_if(CONDITION, MESSAGE)
 #endif
index ed175c9..65f1180 100644 (file)
@@ -27,7 +27,7 @@ DEFINE_STANDARD_HANDLE(math_SingularMatrix, Standard_Failure)
 
 #if !defined No_Exception && !defined No_math_SingularMatrix
   #define math_SingularMatrix_Raise_if(CONDITION, MESSAGE) \
-  if (CONDITION) math_SingularMatrix::Raise(MESSAGE);
+  if (CONDITION) throw math_SingularMatrix(MESSAGE);
 #else
   #define math_SingularMatrix_Raise_if(CONDITION, MESSAGE)
 #endif
diff --git a/tests/bugs/fclasses/bug28217 b/tests/bugs/fclasses/bug28217
deleted file mode 100644 (file)
index 2fbfe70..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-puts "Testing intensive raising exceptions in parallel threads"
-puts "0028217: E r r o r handling is not thread safe and causing memory corruption and sporadic crashes"
-
-# this test will fail on vc10-13 and gcc less than 4.8
-set dver [dversion]
-if { ( [regexp {Compiler: MS Visual C[+][+] ([0-9]+)} $dver res ver] && $ver < 14 ) ||
-     ( [regexp {Compiler: GCC ([0-9]+[.][0-9]+)} $dver res ver] && $ver < 4.8 ) } {
-  puts "TODO OCC28217 ALL: TEST INCOMPLETE"
-  puts "TODO OCC28217 Windows: An exception was caught"
-  puts "TODO OCC28217 Windows: \\*\\* Exception \\*\\*"
-  puts "TODO ?OCC28217 Linux: An exception was caught"
-  puts "TODO ?OCC28217 Linux: \\*\\* Exception \\*\\*.*"
-  puts "TODO ?OCC28217 Linux: \\*\\*\\* Abort"
-  puts "TODO ?OCC28217 Linux: ... The exception is"
-}
-pload QAcommands
-OCC28217