b311480e |
1 | // Created on: 1993-11-03 |
2 | // Created by: Jean Marc LACHAUME |
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 | |
17 | //======================================================================= |
0b85f9a6 |
18 | // Function : Geom2dHatch_Element |
7fd59977 |
19 | // Purpose : Magic Constructor. |
20 | //======================================================================= |
21 | |
0b85f9a6 |
22 | #include <Geom2dAdaptor_Curve.hxx> |
42cf5bc1 |
23 | #include <Geom2dHatch_Element.hxx> |
0b85f9a6 |
24 | |
25 | Geom2dHatch_Element::Geom2dHatch_Element (const Geom2dHatch_Element& Other) |
7fd59977 |
26 | : myCurve(Other.myCurve), myOrientation(Other.myOrientation) { |
27 | } |
28 | |
29 | //======================================================================= |
0b85f9a6 |
30 | // Function : Geom2dHatch_Element |
7fd59977 |
31 | // Purpose : Empty Constructor. |
32 | //======================================================================= |
33 | |
0b85f9a6 |
34 | Geom2dHatch_Element::Geom2dHatch_Element () { |
7fd59977 |
35 | } |
36 | |
37 | //======================================================================= |
0b85f9a6 |
38 | // Function : Geom2dHatch_Element |
7fd59977 |
39 | // Purpose : Constructor. |
40 | //======================================================================= |
41 | |
0b85f9a6 |
42 | Geom2dHatch_Element::Geom2dHatch_Element (const Geom2dAdaptor_Curve& Curve, |
7fd59977 |
43 | const TopAbs_Orientation Orientation) : |
44 | myCurve (Curve), |
45 | myOrientation (Orientation) |
46 | { |
47 | } |
48 | |
49 | //======================================================================= |
50 | // Function : Curve |
51 | // Purpose : Returns the curve associated to the hatching. |
52 | //======================================================================= |
53 | |
0b85f9a6 |
54 | const Geom2dAdaptor_Curve& Geom2dHatch_Element::Curve () const |
7fd59977 |
55 | { |
56 | return myCurve ; |
57 | } |
58 | |
59 | //======================================================================= |
60 | // Function : ChangeCurve |
61 | // Purpose : Returns the curve associated to the hatching. |
62 | //======================================================================= |
63 | |
0b85f9a6 |
64 | Geom2dAdaptor_Curve& Geom2dHatch_Element::ChangeCurve () |
7fd59977 |
65 | { |
66 | return myCurve ; |
67 | } |
68 | |
69 | //======================================================================= |
70 | // Function : Orientation |
71 | // Purpose : Sets the orientation of the element. |
72 | //======================================================================= |
73 | |
0b85f9a6 |
74 | void Geom2dHatch_Element::Orientation (const TopAbs_Orientation Orientation) |
7fd59977 |
75 | { |
76 | myOrientation = Orientation ; |
77 | } |
78 | |
79 | //======================================================================= |
80 | // Function : Orientation |
81 | // Purpose : Returns the orientation of the element. |
82 | //======================================================================= |
83 | |
0b85f9a6 |
84 | TopAbs_Orientation Geom2dHatch_Element::Orientation () const |
7fd59977 |
85 | { |
86 | return myOrientation ; |
87 | } |
88 | |
89 | |
90 | |