1 // Created on: 1997-04-10
2 // Created by: Prestataire Mary FABIEN
3 // Copyright (c) 1997-1999 Matra Datavision
4 // Copyright (c) 1999-2012 OPEN CASCADE SAS
6 // The content of this file is subject to the Open CASCADE Technology Public
7 // License Version 6.5 (the "License"). You may not use the content of this file
8 // except in compliance with the License. Please obtain a copy of the License
9 // at http://www.opencascade.org and read it completely before using this file.
11 // The Initial Developer of the Original Code is Open CASCADE S.A.S., having its
12 // main offices at: 1, place des Freres Montgolfier, 78280 Guyancourt, France.
14 // The Original Code and all software distributed under the License is
15 // distributed on an "AS IS" basis, without warranty of any kind, and the
16 // Initial Developer hereby disclaims all such warranties, including without
17 // limitation, any warranties of merchantability, fitness for a particular
18 // purpose or non-infringement. Please see the License for the specific terms
19 // and conditions governing the rights and limitations under the License.
22 #include <TCollection_AsciiString.hxx>
23 #include <TopOpeBRepDS_Check.ixx>
24 #include <TopOpeBRepDS_Kind.hxx>
25 #include <TopOpeBRepDS_CheckStatus.hxx>
26 #include <TopOpeBRepDS_PointExplorer.hxx>
27 #include <TopOpeBRepDS.hxx>
28 #include <TopOpeBRepDS_Interference.hxx>
29 #include <TopOpeBRepDS_EdgeVertexInterference.hxx>
30 #include <TopOpeBRepDS_CurvePointInterference.hxx>
31 #include <TopOpeBRepDS_ListOfInterference.hxx>
32 #include <TopOpeBRepDS_ListIteratorOfListOfInterference.hxx>
33 #include <TopOpeBRepDS_InterferenceTool.hxx>
34 #include <TopTools_ListIteratorOfListOfShape.hxx>
35 #include <TopTools_ListOfShape.hxx>
36 #include <TopOpeBRepTool_ShapeTool.hxx>
37 #include <TColStd_IndexedMapOfInteger.hxx>
38 #include <BRep_Tool.hxx>
40 #include <TopoDS_Shape.hxx>
41 #include <TopoDS_Vertex.hxx>
44 #include <TopOpeBRepDS_DataMapOfCheckStatus.hxx>
45 #include <TopOpeBRepDS_DataMapIteratorOfDataMapOfCheckStatus.hxx>
47 //=======================================================================
50 //=======================================================================
52 TopOpeBRepDS_Check::TopOpeBRepDS_Check(const Handle(TopOpeBRepDS_HDataStructure)& HDS)
53 : mySurfaceDone(Standard_False),
54 myCurveDone(Standard_False),
55 myPointDone(Standard_False),
56 myShapeDone (Standard_False),
57 myDone(Standard_False)
60 myMapSurfaceStatus.Clear();
61 myMapCurveStatus.Clear();
62 myMapPointStatus.Clear();
63 myMapShapeStatus.Clear();
66 //=======================================================================
69 //=======================================================================
71 TopOpeBRepDS_Check::TopOpeBRepDS_Check()
72 : mySurfaceDone(Standard_False),
73 myCurveDone(Standard_False),
74 myPointDone(Standard_False),
75 myShapeDone (Standard_False),
76 myDone(Standard_False)
78 myMapSurfaceStatus.Clear();
79 myMapCurveStatus.Clear();
80 myMapPointStatus.Clear();
81 myMapShapeStatus.Clear();
84 //=======================================================================
86 //purpose : Check Integrity
87 //=======================================================================
88 Standard_Boolean CheckEdgeParameter(const Handle(TopOpeBRepDS_HDataStructure)& myHDS);
89 Standard_Boolean TopOpeBRepDS_Check::ChkIntg()
91 const TopOpeBRepDS_DataStructure& DS = myHDS->DS();
92 Standard_Boolean bI=Standard_False;
93 // Check the integrity of the DS
94 Standard_Integer i,nshape = DS.NbShapes();
95 for (i = 1; i <= nshape; i++) {
96 // Integrity of Interferences : Check support and geometry
97 const TopOpeBRepDS_ListOfInterference& LI = DS.ShapeInterferences(i);
98 bI = ChkIntgInterf(LI);
100 Standard_Integer nsurface = DS.NbSurfaces();
101 for (i = 1; i <= nsurface; i++) {
102 // Integrity of Interferences : Check support and geometry
103 const TopOpeBRepDS_ListOfInterference& LI = DS.SurfaceInterferences(i);
104 bI = bI && ChkIntgInterf(LI);
107 Standard_Integer ncurve = DS.NbCurves();
108 for (i = 1; i <= ncurve; i++) {
109 // Integrity of Interferences : Check support and geometry
110 const TopOpeBRepDS_ListOfInterference& LI = DS.CurveInterferences(i);
111 bI = bI && ChkIntgInterf(LI);
114 Standard_Integer npoint = DS.NbPoints();
115 for (i = 1; i <= npoint; i++) {
116 // Integrity of Interferences : Check support and geometry
117 const TopOpeBRepDS_ListOfInterference& LI = DS.PointInterferences(i);
118 bI = bI && ChkIntgInterf(LI);
124 // CheckEdgeParameter();
125 CheckEdgeParameter(myHDS);
130 //=======================================================================
131 //function : ChkIntgInterf
133 //=======================================================================
135 Standard_Boolean TopOpeBRepDS_Check::ChkIntgInterf
136 (const TopOpeBRepDS_ListOfInterference& LI)
138 TopOpeBRepDS_ListIteratorOfListOfInterference it1;
140 Standard_Boolean IsOK = Standard_True;
141 while (it1.More() ) {
142 Handle(TopOpeBRepDS_Interference)& I1 = it1.Value();
143 IsOK = IsOK && CheckDS(I1->Support(), I1->SupportType());
144 IsOK = IsOK && CheckDS(I1->Geometry(), I1->GeometryType());
150 //=======================================================================
153 //=======================================================================
155 Standard_Boolean TopOpeBRepDS_Check::CheckDS(const Standard_Integer I,
156 const TopOpeBRepDS_Kind K)
160 case TopOpeBRepDS_SURFACE :
162 if(myHDS->NbSurfaces() < I) {
164 cout<<"Surpassed index of TopOpeBRepDS_SURFACE. actual index : "<<I;
165 cout<<". Index max : "<<myHDS->NbSurfaces();
167 if(myMapSurfaceStatus.IsBound(I))
168 myMapSurfaceStatus.UnBind(I);
169 myMapSurfaceStatus.Bind(I, TopOpeBRepDS_NOK);
170 return Standard_False;
172 if(!myMapSurfaceStatus.IsBound(I))
173 myMapSurfaceStatus.Bind(I,TopOpeBRepDS_OK);
174 return Standard_True;
176 case TopOpeBRepDS_CURVE :
178 if(myHDS->NbCurves() < I) {
180 cout<<"Surpassed index of TopOpeBRepDS_CURVE. actual index : "<<I;
181 cout<<". Index max : "<<myHDS->NbCurves();
183 if(myMapCurveStatus.IsBound(I))
184 myMapCurveStatus.UnBind(I);
185 myMapCurveStatus.Bind(I, TopOpeBRepDS_NOK);
186 return Standard_False;
189 if(!myMapCurveStatus.IsBound(I))
190 myMapCurveStatus.Bind(I,TopOpeBRepDS_OK);
191 return Standard_True;
193 case TopOpeBRepDS_POINT :
195 if(myHDS->NbPoints() < I) {
197 cout<<"Surpassed index of TopOpeBRepDS_POINT : actual index : "<<I;
198 cout<<". Index max : "<<myHDS->NbPoints()<<endl;
200 if(myMapPointStatus.IsBound(I))
201 myMapPointStatus.UnBind(I);
202 myMapPointStatus.Bind(I, TopOpeBRepDS_NOK);
203 return Standard_False;
205 if(!myMapPointStatus.IsBound(I))
206 myMapPointStatus.Bind(I,TopOpeBRepDS_OK);
207 return Standard_True;
215 if(myHDS->NbShapes() < I) {
217 cout<<"Surpassed index of TopOpeBRepDS_Shape_. actual index : "<<I;
218 cout<<". Index max : "<<myHDS->NbShapes();
220 if(myMapShapeStatus.IsBound(I))
221 myMapShapeStatus.UnBind(I);
222 myMapShapeStatus.Bind(I,TopOpeBRepDS_NOK);
223 return Standard_False;
225 const TopoDS_Shape& S =myHDS->Shape(I);
229 TopAbs_ShapeEnum se=TopAbs_COMPOUND;
232 case TopOpeBRepDS_SOLID : se = TopAbs_SOLID; break;
233 case TopOpeBRepDS_SHELL : se = TopAbs_SHELL; break;
234 case TopOpeBRepDS_FACE : se = TopAbs_FACE; break;
235 case TopOpeBRepDS_WIRE : se = TopAbs_WIRE; break;
236 case TopOpeBRepDS_EDGE : se = TopAbs_EDGE; break;
237 case TopOpeBRepDS_VERTEX : se = TopAbs_VERTEX;break;
241 if(S.ShapeType() != se) {
243 cout<<"Error : Shape "<<I<<" is a ";
244 TopOpeBRepDS::Print(TopOpeBRepDS::ShapeToKind(S.ShapeType()), cout);
246 TopOpeBRepDS::Print(K, cout);
249 if(myMapShapeStatus.IsBound(I))
250 myMapShapeStatus.UnBind(I);
251 myMapShapeStatus.Bind(I,TopOpeBRepDS_NOK);
252 return Standard_False;
254 if(!myMapShapeStatus.IsBound(I))
255 myMapShapeStatus.Bind(I,TopOpeBRepDS_OK);
256 return Standard_True;;
259 //=======================================================================
260 //function : ChkIntgSamDom
262 //=======================================================================
264 Standard_Boolean TopOpeBRepDS_Check::ChkIntgSamDom()
266 Standard_Boolean b = Standard_True, bb = Standard_False;
267 TopOpeBRepDS_DataStructure& BDS = myHDS->ChangeDS();
268 Standard_Integer NbSh = myHDS->NbShapes(), i, Curr, Loc;
269 for(i = 1;i <= NbSh; i++) {
270 // Verifie que les Shapes de mySameDomaine existe bien dans la DS
271 const TopoDS_Shape& Sind = myHDS->Shape(i);
272 const TopTools_ListOfShape& losi = BDS.ShapeSameDomain(Sind);
273 if(!CheckShapes(losi)) {
275 cout<<"Shape of ShapeSameDomain (n*n "<<i;
276 cout<<") is not defined in the DS"<<endl;
281 // Verification de SameDomaineRef
282 Curr = BDS.SameDomainRef(i);
283 Loc = BDS.SameDomainRef(Curr);
284 if(Curr && (Curr != Loc)) {
286 cout<<"SameDomaineRef of Shape "<<i<<" = "<<Curr;
287 cout<<". SameDomaineRef of Shape "<<Curr<<" = "<<Loc<<endl;
293 // Verification du type des differents Shapes SameDomain
294 const TopoDS_Shape& Sref = myHDS->Shape(Curr);
295 if(Sind.ShapeType() != Sref.ShapeType()) {
297 cout<<"Shapes n*n "<<i<<" and "<<Curr<<" are SameDomain."<<endl;
298 cout<<"Type of Shape n*n "<<i<<" = ";
299 PrintShape(Sind.ShapeType(),cout);
300 cout<<endl<<"Type of Shape n*n "<<Curr<<" = ";
301 PrintShape(Sref.ShapeType(),cout); cout<<endl;
306 // Verifier que ShapeSameDomain(Sref) contient bien Sind
307 // sauf si Sind == Sref
309 const TopTools_ListOfShape& losr = BDS.ShapeSameDomain(Sref);
310 TopTools_ListIteratorOfListOfShape liolos;
311 liolos.Initialize(losr);
312 while (liolos.More() ) {
313 const TopoDS_Shape& Sh = liolos.Value();
314 Loc = myHDS->Shape(Sh);
323 cout<<"Shapes n*n "<<i<<" and "<<Curr<<" are SameDomain. ";
324 cout<<"The reference of "<<i<<", is "<<Curr<<"."<<endl;
325 cout<<"However, Shape n*n "<<i;
326 cout<<" is not in the list of Shape SameDomain of "<<Curr<<endl;
336 //=======================================================================
337 //function : CheckShapes
339 //=======================================================================
341 Standard_Boolean TopOpeBRepDS_Check::CheckShapes
342 (const TopTools_ListOfShape& LS ) const
344 Standard_Integer index;
345 TopTools_ListIteratorOfListOfShape it(LS);
347 const TopoDS_Shape& itS = it.Value();
348 index = myHDS->Shape(itS);
349 if (!index) return Standard_False;
352 return Standard_True;
355 //=======================================================================
356 //function : OneVertexOnPnt
358 //=======================================================================
360 Standard_Boolean TopOpeBRepDS_Check::OneVertexOnPnt(){
361 Standard_Boolean b = Standard_True;
362 // Standard_Integer i, j, k;
363 Standard_Integer i, j;
364 Standard_Integer Curr1, Curr2, sdr1, sdr2;
365 Standard_Integer NbVe = 0, NbPo = myHDS->NbPoints();
366 // Standard_Real tol, tol1, tol2, Dist;
367 Standard_Real tol1, tol2, Dist;
368 TColStd_IndexedMapOfInteger vert;
370 for(i = 1;i <= myHDS->NbShapes();i++) {
371 const TopoDS_Shape& S = myHDS->Shape(i);
372 if((S.ShapeType() == TopAbs_VERTEX) &&
376 NbVe = vert.Extent();
377 for(i = 1;i <= NbVe; i++) {
378 Curr1 = vert.FindKey(i);
379 const TopoDS_Shape& S1 = myHDS->Shape(Curr1);
380 sdr1 = myHDS->SameDomainReference(S1);
381 for(j = i+1;j <= NbVe; j++) {
382 Curr2 = vert.FindKey(j);
383 const TopoDS_Shape& S2 = myHDS->Shape(Curr2);
384 sdr2 = myHDS->SameDomainReference(S2);
385 tol1 = TopOpeBRepTool_ShapeTool::Tolerance(S1);
386 tol2 = TopOpeBRepTool_ShapeTool::Tolerance(S2);
387 const gp_Pnt& P1 = TopOpeBRepTool_ShapeTool::Pnt(S1);
388 const gp_Pnt& P2 = TopOpeBRepTool_ShapeTool::Pnt(S2);
389 Dist = P1.Distance(P2);
390 if(Dist <= tol1 + tol2) {
393 cout<<"Pb Vertex n+n"<<Curr1<<" and n*n"<<Curr2;
394 cout<<" : same place, not SameDomain"<<endl;
395 cout<<" Tol of Vertex n*n"<<Curr1<<" = "<<tol1<<endl;
396 cout<<" Tol of Vertex n*n"<<Curr2<<" = "<<tol2<<endl;
397 cout<<" Distance between two Vertexes = "<<Dist<<endl<<endl;
402 else if(sdr1 == sdr2) {
404 cout<<"Pb Vertex "<<Curr1<<" and "<<Curr2;
405 cout<<" : SameDomain, not same place"<<endl;
406 cout<<" Tol of Vertex n*n"<<Curr1<<" = "<<tol1<<endl;
407 cout<<" Tol of Vertex n*n"<<Curr2<<" = "<<tol2<<endl;
408 cout<<" Distance between two Vertexes = "<<Dist<<endl<<endl;
413 TopOpeBRepDS_PointExplorer PE(myHDS->DS());
414 for(;PE.More(); PE.Next()) {
415 const TopOpeBRepDS_Point& dsPnt = PE.Point();
416 const gp_Pnt& Pnt1 = dsPnt.Point();
417 tol1 = dsPnt.Tolerance();
418 tol2 = TopOpeBRepTool_ShapeTool::Tolerance(S1);
419 const gp_Pnt& Pnt2 = TopOpeBRepTool_ShapeTool::Pnt(S1);
420 Dist = Pnt1.Distance(Pnt2);
421 if(Dist <= tol1 + tol2) {
423 cout<<"Attention : Vertex "<<Curr1<<" and Point "<<PE.Index();
424 cout<<" are confused"<<endl;
425 cout<<" Tol of Vertex n*n"<<Curr1<<" = "<<tol1<<endl;
426 cout<<" Tol of Point n*n"<<PE.Index()<<" = "<<tol2<<endl;
427 cout<<" Distance between the two = "<<Dist<<endl<<endl;
433 for(i = 1;i <= NbPo; i++) {
434 TopOpeBRepDS_PointExplorer PE(myHDS->DS());
436 const TopOpeBRepDS_Point& dsPnt1 = myHDS->Point(i);
437 for(j = i+1;j < NbPo;j++) {
438 const TopOpeBRepDS_Point& dsPnt2 = myHDS->Point(j);
439 if(dsPnt1.IsEqual(dsPnt2)) {
441 cout<<"Attention : points "<<i<<" and "<<j<<" are confused"<<endl;
442 cout<<" Tol of Point n*n"<<i<<" = "<<dsPnt1.Tolerance()<<endl;
443 cout<<" Tol of Point n*n"<<j<<" = "<<dsPnt1.Tolerance()<<endl;
444 Dist = dsPnt1.Point().Distance(dsPnt2.Point());
445 cout<<" Distance between the two = "<<Dist<<endl<<endl;
455 //=======================================================================
456 //function : CheckEdgeParameter
458 //=======================================================================
460 ///Standard_Boolean TopOpeBRepDS_Check::CheckEdgeParameter() const
461 Standard_Boolean CheckEdgeParameter(const Handle(TopOpeBRepDS_HDataStructure)& myHDS)
463 TopOpeBRepDS_ListIteratorOfListOfInterference it1;
464 const TopOpeBRepDS_DataStructure& DS = myHDS->DS();
465 Standard_Integer i,nshape = DS.NbShapes();
466 Standard_Boolean IsOK = Standard_True;
467 for (i = 1; i <= nshape; i++) {
468 // Integrity of Interferences : Check parameter of EdgeInterferences
469 const TopOpeBRepDS_ListOfInterference& LI = DS.ShapeInterferences(i);
471 while (it1.More() ) {
472 Handle(TopOpeBRepDS_Interference)& I1 = it1.Value();
473 Handle(TopOpeBRepDS_EdgeVertexInterference) EVI =
474 Handle(TopOpeBRepDS_EdgeVertexInterference)::DownCast(I1);
477 // Standard_Integer Param = EVI->Parameter();
479 Standard_Integer Param = (Standard_Integer ) EVI->Parameter();
482 I1->Dump(cout,"!!**!!** WARNING : sur l'interference : \n",
483 "parameter > 1.e50");
484 IsOK = Standard_False;
491 Standard_Integer ncurve = DS.NbCurves();
492 for (i = 1; i <= ncurve; i++) {
493 // Integrity of Interferences : Check parameter of CurvesInterferences
494 const TopOpeBRepDS_ListOfInterference& LI = DS.CurveInterferences(i);
496 while (it1.More() ) {
497 const Handle(TopOpeBRepDS_Interference)& I1 = it1.Value();
498 const Handle(TopOpeBRepDS_CurvePointInterference)& CPI =
499 Handle(TopOpeBRepDS_CurvePointInterference)::DownCast(I1);
501 Standard_Integer Param =
503 // TopOpeBRepDS_InterferenceTool::Parameter(CPI);
505 (Standard_Integer ) TopOpeBRepDS_InterferenceTool::Parameter(CPI);
508 I1->Dump(cout,"!!**!!** WARNING : sur l'interference : \n",
509 "parameter > 1.e50");
510 IsOK = Standard_False;
520 //=======================================================================
521 //function : PrintIntg
523 //=======================================================================
524 Standard_OStream& TopOpeBRepDS_Check::PrintIntg(Standard_OStream& OS)
526 OS<<endl<<endl<<"************************************************"<<endl;
527 OS<<"state of the DS : (only the tested elements)"<<endl<<endl;
529 //Display of the geometry
530 PrintMap(myMapSurfaceStatus, "Surface", OS);
531 PrintMap(myMapCurveStatus, "Curve", OS);
532 PrintMap(myMapPointStatus, "Point", OS);
534 //display of the topology
535 TopOpeBRepDS_DataMapIteratorOfDataMapOfCheckStatus DMI(myMapShapeStatus);
536 TopOpeBRepDS_DataMapOfCheckStatus MapVertex, MapEdge, MapWire, MapFace, MapSolid;
538 // different Map keep their index of myMapShapeStatus
539 for(DMI.Reset();DMI.More();DMI.Next()) {
541 const TopoDS_Shape& S =myHDS->Shape(i);
542 switch(S.ShapeType()) {
543 case TopAbs_VERTEX: MapVertex.Bind(i, DMI.Value()); break;
544 case TopAbs_EDGE: MapEdge.Bind(i, DMI.Value()); break;
545 case TopAbs_WIRE: MapWire.Bind(i, DMI.Value()); break;
546 case TopAbs_FACE: MapFace.Bind(i, DMI.Value()); break;
547 case TopAbs_SOLID: MapSolid.Bind(i, DMI.Value()); break;
553 PrintMap(MapVertex, "Vertex", OS);
554 PrintMap(MapEdge, "Edge", OS);
555 PrintMap(MapWire, "Wire", OS);
556 PrintMap(MapFace, "Face", OS);
557 PrintMap(MapSolid, "Solid", OS);
563 //=======================================================================
564 //function : PrintMap
566 //=======================================================================
568 Standard_OStream& TopOpeBRepDS_Check::PrintMap(TopOpeBRepDS_DataMapOfCheckStatus& MapStat,
569 const Standard_CString eltstr,
570 Standard_OStream& OS)
572 TopOpeBRepDS_DataMapIteratorOfDataMapOfCheckStatus DMI(MapStat);
573 DMI.Initialize(MapStat);
575 Standard_Boolean b = Standard_True;
576 OS<<" "<<eltstr<<"\t"<<"(/"<<MapStat.Extent()<<")\tnumber ";
578 PrintElts(MapStat, TopOpeBRepDS_OK, b, OS);
579 if(!b) OS<<" = OK"<<endl;
580 PrintElts(MapStat, TopOpeBRepDS_NOK, b, OS);
581 if(!b) OS<<" = NOK"<<endl;
586 //=======================================================================
587 //function : PrintElts
588 //purpose : Print the elements in the state stat of MapStat
589 //=======================================================================
590 Standard_OStream& TopOpeBRepDS_Check::PrintElts(TopOpeBRepDS_DataMapOfCheckStatus& MapStat,
591 const TopOpeBRepDS_CheckStatus Stat,
593 Standard_OStream& OS)
595 TopOpeBRepDS_DataMapIteratorOfDataMapOfCheckStatus DMI(MapStat);
596 Standard_Boolean bb = !b;
599 TopOpeBRepDS_CheckStatus s;
600 for(DMI.Reset();DMI.More();DMI.Next()) {
605 if(bb){OS<<"\t\tnumber ";bb=!bb;}
612 //=======================================================================
615 //=======================================================================
616 Standard_OStream& TopOpeBRepDS_Check::Print
617 (const TopOpeBRepDS_CheckStatus stat,
618 Standard_OStream& OS)
621 case TopOpeBRepDS_OK: OS<<"OK";break;
622 case TopOpeBRepDS_NOK: OS<<"NOK";break;
628 //=======================================================================
629 //function : PrintShape
631 //=======================================================================
632 Standard_OStream& TopOpeBRepDS_Check::PrintShape
633 (const TopAbs_ShapeEnum SE,
634 Standard_OStream& OS)
637 case TopAbs_SOLID : OS<<"Solid "; break;
638 case TopAbs_SHELL : OS<<"Shell "; break;
639 case TopAbs_FACE : OS<<"Face "; break;
640 case TopAbs_WIRE : OS<<"Wire "; break;
641 case TopAbs_EDGE : OS<<"Edge "; break;
642 case TopAbs_VERTEX : OS<<"Vertex"; break;
649 //=======================================================================
650 //function : PrintShape
652 //=======================================================================
653 Standard_OStream& TopOpeBRepDS_Check::PrintShape
654 (const Standard_Integer index,
655 Standard_OStream& OS)
657 if(myHDS->NbShapes() < index) {
658 OS<<"**PB**IN**TopOpeBRepDS_Check::PrintShape** ";
661 if(!myMapShapeStatus.IsBound(index)) {
662 OS<<"NO CHECK HAS PROCESSING"<<endl;
667 const TopoDS_Shape& S =
672 PrintShape(S.ShapeType(),cout);
673 OS<<" "<<index<<" = ";
674 Print(myMapShapeStatus.Find(index), cout);
679 //=======================================================================
682 //=======================================================================
684 const Handle(TopOpeBRepDS_HDataStructure)& TopOpeBRepDS_Check::HDS()const
690 //=======================================================================
691 //function : ChangeHDS
693 //=======================================================================
695 Handle(TopOpeBRepDS_HDataStructure)& TopOpeBRepDS_Check::ChangeHDS()