1 // Created on: 1993-07-26
2 // Created by: Remi LEQUETTE
3 // Copyright (c) 1993-1999 Matra Datavision
4 // Copyright (c) 1999-2014 OPEN CASCADE SAS
6 // This file is part of Open CASCADE Technology software library.
8 // This library is free software; you can redistribute it and/or modify it under
9 // the terms of the GNU Lesser General Public License version 2.1 as published
10 // by the Free Software Foundation, with special exception defined in the file
11 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12 // distribution for complete text of the license and disclaimer of any warranty.
14 // Alternatively, this file may be used under the terms of Open CASCADE
15 // commercial license or contractual agreement.
17 #include <PBRep_TEdge.ixx>
19 static const Standard_Integer ParameterMask = 1;
20 static const Standard_Integer RangeMask = 2;
21 static const Standard_Integer DegeneratedMask = 4;
23 //=======================================================================
24 //function : PBRep_TEdge
26 //=======================================================================
28 PBRep_TEdge::PBRep_TEdge() :
34 //=======================================================================
35 //function : Tolerance
37 //=======================================================================
39 Standard_Real PBRep_TEdge::Tolerance()const
45 //=======================================================================
46 //function : Tolerance
48 //=======================================================================
50 void PBRep_TEdge::Tolerance(const Standard_Real T)
56 //=======================================================================
57 //function : SameParameter
59 //=======================================================================
61 Standard_Boolean PBRep_TEdge::SameParameter()const
63 return myFlags & ParameterMask;
67 //=======================================================================
68 //function : SameParameter
70 //=======================================================================
72 void PBRep_TEdge::SameParameter(const Standard_Boolean S)
74 if (S) myFlags |= ParameterMask;
75 else myFlags &= ~ParameterMask;
79 //=======================================================================
80 //function : SameRange
82 //=======================================================================
84 Standard_Boolean PBRep_TEdge::SameRange()const
86 return myFlags & RangeMask;
90 //=======================================================================
91 //function : SameRange
93 //=======================================================================
95 void PBRep_TEdge::SameRange(const Standard_Boolean S)
97 if (S) myFlags |= RangeMask;
98 else myFlags &= ~RangeMask;
101 //=======================================================================
102 //function : Degenerated
104 //=======================================================================
106 Standard_Boolean PBRep_TEdge::Degenerated()const
108 return myFlags & DegeneratedMask;
112 //=======================================================================
113 //function : Degenerated
115 //=======================================================================
117 void PBRep_TEdge::Degenerated(const Standard_Boolean S)
119 if (S) myFlags |= DegeneratedMask;
120 else myFlags &= ~DegeneratedMask;
124 //=======================================================================
127 //=======================================================================
129 Handle(PBRep_CurveRepresentation) PBRep_TEdge::Curves()const
135 //=======================================================================
138 //=======================================================================
140 void PBRep_TEdge::Curves(const Handle(PBRep_CurveRepresentation)& C)