b311480e |
1 | // Created on: 1993-06-23 |
2 | // Created by: Jean Yves LEBEY |
3 | // Copyright (c) 1993-1999 Matra Datavision |
973c2be1 |
4 | // Copyright (c) 1999-2014 OPEN CASCADE SAS |
b311480e |
5 | // |
973c2be1 |
6 | // This file is part of Open CASCADE Technology software library. |
b311480e |
7 | // |
d5f74e42 |
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 |
973c2be1 |
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. |
b311480e |
13 | // |
973c2be1 |
14 | // Alternatively, this file may be used under the terms of Open CASCADE |
15 | // commercial license or contractual agreement. |
7fd59977 |
16 | |
42cf5bc1 |
17 | |
18 | #include <Geom2d_Curve.hxx> |
19 | #include <Standard_Type.hxx> |
20 | #include <TopOpeBRepDS_Interference.hxx> |
21 | #include <TopOpeBRepDS_SurfaceCurveInterference.hxx> |
22 | #include <TopOpeBRepDS_Transition.hxx> |
7fd59977 |
23 | |
92efcf78 |
24 | IMPLEMENT_STANDARD_RTTIEXT(TopOpeBRepDS_SurfaceCurveInterference,TopOpeBRepDS_Interference) |
25 | |
0797d9d3 |
26 | #ifdef OCCT_DEBUG |
7fd59977 |
27 | #include <TopOpeBRepDS_Dumper.hxx> |
28 | #endif |
29 | |
30 | //======================================================================= |
31 | //function : TopOpeBRepDS_SurfaceCurveInterference |
32 | //purpose : |
33 | //======================================================================= |
34 | |
35 | TopOpeBRepDS_SurfaceCurveInterference::TopOpeBRepDS_SurfaceCurveInterference() |
36 | { |
37 | } |
38 | |
39 | //======================================================================= |
40 | //function : TopOpeBRepDS_SurfaceCurveInterference |
41 | //purpose : |
42 | //======================================================================= |
43 | |
44 | TopOpeBRepDS_SurfaceCurveInterference::TopOpeBRepDS_SurfaceCurveInterference |
45 | (const TopOpeBRepDS_Transition& T, |
46 | const TopOpeBRepDS_Kind ST, |
47 | const Standard_Integer S, |
48 | const TopOpeBRepDS_Kind GT, |
49 | const Standard_Integer G, |
50 | const Handle(Geom2d_Curve)& PC) : |
51 | TopOpeBRepDS_Interference(T,ST,S,GT,G), |
52 | myPCurve(PC) |
53 | { |
54 | } |
55 | |
56 | //======================================================================= |
57 | //function : TopOpeBRepDS_SurfaceCurveInterference |
58 | //purpose : |
59 | //======================================================================= |
60 | |
61 | TopOpeBRepDS_SurfaceCurveInterference::TopOpeBRepDS_SurfaceCurveInterference |
62 | (const Handle(TopOpeBRepDS_Interference)& I) : |
63 | TopOpeBRepDS_Interference(I) |
64 | { |
65 | } |
66 | |
67 | |
68 | //======================================================================= |
69 | //function : PCurve |
70 | //purpose : |
71 | //======================================================================= |
72 | |
73 | const Handle(Geom2d_Curve)& TopOpeBRepDS_SurfaceCurveInterference::PCurve |
74 | ()const |
75 | { |
76 | return myPCurve; |
77 | } |
78 | |
79 | //======================================================================= |
80 | //function : PCurve |
81 | //purpose : |
82 | //======================================================================= |
83 | |
84 | void TopOpeBRepDS_SurfaceCurveInterference::PCurve |
85 | (const Handle(Geom2d_Curve)& PC) |
86 | { |
87 | myPCurve = PC; |
88 | } |
89 | |
90 | |
91 | //======================================================================= |
92 | //function : DumpPCurve |
93 | //purpose : |
94 | //======================================================================= |
95 | |
96 | Standard_OStream& TopOpeBRepDS_SurfaceCurveInterference::DumpPCurve |
97 | (Standard_OStream& OS, |
0797d9d3 |
98 | #ifdef OCCT_DEBUG |
498ce76b |
99 | const Standard_Boolean compact |
100 | #else |
101 | const Standard_Boolean |
102 | #endif |
103 | )const |
7fd59977 |
104 | { |
0797d9d3 |
105 | #ifdef OCCT_DEBUG |
7fd59977 |
106 | Dump(OS); OS<<endl; |
107 | |
108 | OS<<"PCurve "; |
109 | if (!PCurve().IsNull()) TopOpeBRepDS_Dumper::Print(PCurve(),OS,compact); |
110 | else OS<<" is null"; |
111 | OS<<endl; |
112 | #endif |
113 | |
114 | return OS; |
115 | } |
116 | |
117 | |
118 | //======================================================================= |
119 | //function : Dump |
120 | //purpose : |
121 | //======================================================================= |
122 | |
123 | Standard_OStream& TopOpeBRepDS_SurfaceCurveInterference::Dump |
124 | (Standard_OStream& OS) const |
125 | { |
0797d9d3 |
126 | #ifdef OCCT_DEBUG |
7fd59977 |
127 | OS<<"SCI ";TopOpeBRepDS_Dumper::PrintType(myPCurve,OS);OS<<" "; |
128 | TopOpeBRepDS_Interference::Dump(OS); |
129 | #endif |
130 | |
131 | return OS; |
132 | } |