const gp_Pnt2d& thePoint,
double theTolerance ) const
{
+ if (thePolyline.IsNull())
+ {
+ return false;
+ }
+
std::vector<gp_Pnt2d> aPointsList( 1 );
aPointsList[0] = thePoint;
std::vector<TopoDS_Wire> aCurves;
const Handle( HYDROData_PolylineXY )& theTool,
double theTolerance ) const
{
+ if (thePolyline.IsNull() || theTool.IsNull())
+ {
+ return false;
+ }
+
HYDROData_SequenceOfObjects aSeq;
aSeq.Append( theTool );
return split( theDoc, thePolyline, aSeq, theTolerance, -1 );
double theTolerance,
int theIgnoreIndex ) const
{
+ if (thePolyline.IsNull())
+ {
+ return false;
+ }
+
std::vector<TopoDS_Wire> aCurves;
GetWires(thePolyline, aCurves);
std::vector<TopoDS_Wire> aToolCurves;
{
Handle( HYDROData_PolylineXY ) aToolPolyline =
Handle( HYDROData_PolylineXY )::DownCast( theTools.Value( i ) );
- std::vector<TopoDS_Wire> aTCurves;
- GetWires(aToolPolyline, aTCurves);
- append( aToolCurves, aTCurves);
+ if (!aToolPolyline.IsNull())
+ {
+ std::vector<TopoDS_Wire> aTCurves;
+ GetWires(aToolPolyline, aTCurves);
+ append( aToolCurves, aTCurves);
+ }
}
+ if (aToolCurves.empty())
+ {
+ return false;
+ }
+
const int aPSCount = aCurves.size();
const int aTSCount = aToolCurves.size();
std::vector<TopoDS_Shape> aResult;