1 // Created on: 2004-09-03
2 // Created by: Oleg FEDYAEV
3 // Copyright (c) 2004-2014 OPEN CASCADE SAS
5 // This file is part of Open CASCADE Technology software library.
7 // This library is free software; you can redistribute it and/or modify it under
8 // the terms of the GNU Lesser General Public License version 2.1 as published
9 // by the Free Software Foundation, with special exception defined in the file
10 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
11 // distribution for complete text of the license and disclaimer of any warranty.
13 // Alternatively, this file may be used under the terms of Open CASCADE
14 // commercial license or contractual agreement.
16 #ifndef _BOPAlgo_CheckResult_HeaderFile
17 #define _BOPAlgo_CheckResult_HeaderFile
19 #include <Standard.hxx>
20 #include <Standard_DefineAlloc.hxx>
21 #include <Standard_Handle.hxx>
23 #include <TopoDS_Shape.hxx>
24 #include <BOPAlgo_CheckStatus.hxx>
25 #include <TopTools_ListOfShape.hxx>
26 #include <Standard_Real.hxx>
30 //! contains information about faulty shapes and faulty types
31 //! can't be processed by Boolean Operations
32 class BOPAlgo_CheckResult
40 Standard_EXPORT BOPAlgo_CheckResult();
42 //! sets ancestor shape (object) for faulty sub-shapes
43 Standard_EXPORT void SetShape1 (const TopoDS_Shape& TheShape);
45 //! adds faulty sub-shapes from object to a list
46 Standard_EXPORT void AddFaultyShape1 (const TopoDS_Shape& TheShape);
48 //! sets ancestor shape (tool) for faulty sub-shapes
49 Standard_EXPORT void SetShape2 (const TopoDS_Shape& TheShape);
51 //! adds faulty sub-shapes from tool to a list
52 Standard_EXPORT void AddFaultyShape2 (const TopoDS_Shape& TheShape);
54 //! returns ancestor shape (object) for faulties
55 Standard_EXPORT const TopoDS_Shape& GetShape1() const;
57 //! returns ancestor shape (tool) for faulties
58 Standard_EXPORT const TopoDS_Shape& GetShape2() const;
60 //! returns list of faulty shapes for object
61 Standard_EXPORT const TopTools_ListOfShape& GetFaultyShapes1() const;
63 //! returns list of faulty shapes for tool
64 Standard_EXPORT const TopTools_ListOfShape& GetFaultyShapes2() const;
66 //! set status of faulty
67 Standard_EXPORT void SetCheckStatus (const BOPAlgo_CheckStatus TheStatus);
69 //! gets status of faulty
70 Standard_EXPORT BOPAlgo_CheckStatus GetCheckStatus() const;
72 //! Sets max distance for the first shape
73 Standard_EXPORT void SetMaxDistance1 (const Standard_Real theDist);
75 //! Sets max distance for the second shape
76 Standard_EXPORT void SetMaxDistance2 (const Standard_Real theDist);
78 //! Sets the parameter for the first shape
79 Standard_EXPORT void SetMaxParameter1 (const Standard_Real thePar);
81 //! Sets the parameter for the second shape
82 Standard_EXPORT void SetMaxParameter2 (const Standard_Real thePar);
84 //! Returns the distance for the first shape
85 Standard_EXPORT Standard_Real GetMaxDistance1() const;
87 //! Returns the distance for the second shape
88 Standard_EXPORT Standard_Real GetMaxDistance2() const;
90 //! Returns the parameter for the fircst shape
91 Standard_EXPORT Standard_Real GetMaxParameter1() const;
93 //! Returns the parameter for the second shape
94 Standard_EXPORT Standard_Real GetMaxParameter2() const;
109 TopoDS_Shape myShape1;
110 TopoDS_Shape myShape2;
111 BOPAlgo_CheckStatus myStatus;
112 TopTools_ListOfShape myFaulty1;
113 TopTools_ListOfShape myFaulty2;
114 Standard_Real myMaxDist1;
115 Standard_Real myMaxDist2;
116 Standard_Real myMaxPar1;
117 Standard_Real myMaxPar2;
128 #endif // _BOPAlgo_CheckResult_HeaderFile