1 // Created on: 1998-08-17
2 // Created by: Pavel DURANDIN
3 // Copyright (c) 1998-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 <ShapeAnalysis_HSequenceOfFreeBounds.hxx>
24 //=======================================================================
26 //purpose : Returns shape
27 //=======================================================================
29 inline TopoDS_Shape ShapeAnalysis_FreeBoundsProperties::Shape() const
35 //=======================================================================
37 //purpose : Returns True if shape is loaded
38 //=======================================================================
40 inline Standard_Boolean ShapeAnalysis_FreeBoundsProperties::IsLoaded() const
42 return !(myShape.IsNull());
46 //=======================================================================
47 //function : Tolerance
48 //purpose : Returns tolerance
49 //=======================================================================
51 inline Standard_Real ShapeAnalysis_FreeBoundsProperties::Tolerance() const
57 //=======================================================================
58 //function : NbFreeBounds
59 //purpose : Returns number of free bounds
60 //=======================================================================
62 inline Standard_Integer ShapeAnalysis_FreeBoundsProperties::NbFreeBounds() const
64 return (myClosedFreeBounds->Length() + myOpenFreeBounds->Length());
68 //=======================================================================
69 //function : NbClosedFreeBounds
70 //purpose : Returns number of closed free bounds
71 //=======================================================================
73 inline Standard_Integer ShapeAnalysis_FreeBoundsProperties::NbClosedFreeBounds() const
75 return myClosedFreeBounds->Length();
79 //=======================================================================
80 //function : NbOpenFreeBounds
81 //purpose : Returns number of open free bounds
82 //=======================================================================
84 inline Standard_Integer ShapeAnalysis_FreeBoundsProperties::NbOpenFreeBounds() const
86 return myOpenFreeBounds->Length();
90 //=======================================================================
91 //function : ClosedFreeBounds
92 //purpose : Returns all closed free bounds
93 //=======================================================================
95 inline Handle(ShapeAnalysis_HSequenceOfFreeBounds) ShapeAnalysis_FreeBoundsProperties::ClosedFreeBounds() const
97 return myClosedFreeBounds;
100 //=======================================================================
101 //function : OpenFreeBounds
102 //purpose : Returns all open free bounds
103 //=======================================================================
105 inline Handle(ShapeAnalysis_HSequenceOfFreeBounds) ShapeAnalysis_FreeBoundsProperties::OpenFreeBounds() const
107 return myOpenFreeBounds;
110 //=======================================================================
111 //function : ClosedFreeBound
112 //purpose : Returns properties of closed free bound specified by its rank
114 //=======================================================================
116 inline Handle(ShapeAnalysis_FreeBoundData) ShapeAnalysis_FreeBoundsProperties::ClosedFreeBound(const Standard_Integer index) const
118 return myClosedFreeBounds->Value(index);
121 //=======================================================================
122 //function : OpenFreeBound
123 //purpose : Returns properties of open free bound specified by its rank
125 //=======================================================================
127 inline Handle(ShapeAnalysis_FreeBoundData) ShapeAnalysis_FreeBoundsProperties::OpenFreeBound(const Standard_Integer index) const
129 return myOpenFreeBounds->Value(index);