0023024: Update headers of OCCT files
[occt.git] / src / BRep / BRep_CurveOn2Surfaces.cxx
CommitLineData
b311480e 1// Created on: 1993-07-06
2// Created by: Remi LEQUETTE
3// Copyright (c) 1993-1999 Matra Datavision
4// Copyright (c) 1999-2012 OPEN CASCADE SAS
5//
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.
10//
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.
13//
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.
20
7fd59977 21
22
23#include <BRep_CurveOn2Surfaces.ixx>
24
25
26//=======================================================================
27//function : BRep_CurveOn2Surfaces
28//purpose :
29//=======================================================================
30
31BRep_CurveOn2Surfaces::BRep_CurveOn2Surfaces(const Handle(Geom_Surface)& S1,
32 const Handle(Geom_Surface)& S2,
33 const TopLoc_Location& L1,
34 const TopLoc_Location& L2,
35 const GeomAbs_Shape C) :
36 BRep_CurveRepresentation(L1),
37 mySurface(S1),
38 mySurface2(S2),
39 myLocation2(L2),
40 myContinuity(C)
41{
42}
43
44//=======================================================================
45//function : D0
46//purpose :
47//=======================================================================
48
49void BRep_CurveOn2Surfaces::D0(const Standard_Real , gp_Pnt& )const
50{
51 Standard_NullObject::Raise("BRep_CurveOn2Surfaces::D0");
52}
53
54
55//=======================================================================
56//function : IsRegularity
57//purpose :
58//=======================================================================
59
60Standard_Boolean BRep_CurveOn2Surfaces::IsRegularity()const
61{
62 return Standard_True;
63}
64
65
66//=======================================================================
67//function : IsRegularity
68//purpose :
69//=======================================================================
70
71Standard_Boolean BRep_CurveOn2Surfaces::IsRegularity
72 (const Handle_Geom_Surface& S1,
73 const Handle_Geom_Surface& S2,
74 const TopLoc_Location& L1,
75 const TopLoc_Location& L2)const
76{
77 return ((mySurface == S1 && mySurface2 == S2 &&
78 myLocation == L1 && myLocation2 == L2) ||
79 (mySurface == S2 && mySurface2 == S1 &&
80 myLocation == L2 && myLocation2 == L1));
81}
82
83
84//=======================================================================
85//function : Surface
86//purpose :
87//=======================================================================
88
89const Handle(Geom_Surface)& BRep_CurveOn2Surfaces::Surface()const
90{
91 return mySurface;
92}
93
94//=======================================================================
95//function : Surface2
96//purpose :
97//=======================================================================
98
99const Handle(Geom_Surface)& BRep_CurveOn2Surfaces::Surface2()const
100{
101 return mySurface2;
102}
103
104
105//=======================================================================
106//function : Location2
107//purpose :
108//=======================================================================
109
110const TopLoc_Location& BRep_CurveOn2Surfaces::Location2()const
111{
112 return myLocation2;
113}
114
115//=======================================================================
116//function : Continuity
117//purpose :
118//=======================================================================
119
120const GeomAbs_Shape& BRep_CurveOn2Surfaces::Continuity()const
121{
122 return myContinuity;
123}
124
125//=======================================================================
126//function : Continuity
127//purpose :
128//=======================================================================
129
130void BRep_CurveOn2Surfaces::Continuity(const GeomAbs_Shape C)
131{
132 myContinuity = C;
133}
134
135
136//=======================================================================
137//function : Copy
138//purpose :
139//=======================================================================
140
141Handle(BRep_CurveRepresentation) BRep_CurveOn2Surfaces::Copy() const
142{
143 Handle(BRep_CurveOn2Surfaces) C = new
144 BRep_CurveOn2Surfaces(Surface(),Surface2(),
145 Location(),Location2(),
146 myContinuity);
147 return C;
148}