0026850: Replace nested instantiations of TCollection generic classes by NCollection...
[occt.git] / src / Contap / Contap_ArcFunction.lxx
1 // Created on: 1993-06-03
2 // Created by: Jacques GOUSSARD
3 // Copyright (c) 1993-1999 Matra Datavision
4 // Copyright (c) 1999-2014 OPEN CASCADE SAS
5 //
6 // This file is part of Open CASCADE Technology software library.
7 //
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.
13 //
14 // Alternatively, this file may be used under the terms of Open CASCADE
15 // commercial license or contractual agreement.
16
17 inline void Contap_ArcFunction::Set(const gp_Dir& Direction,
18                                     const Standard_Real Angle)
19 {
20   myType = Contap_DraftStd;
21   myDir  = Direction;
22   myCosAng = Cos(M_PI/2.+Angle);
23 }
24
25 inline void Contap_ArcFunction::Set(const gp_Pnt& Eye,
26                                     const Standard_Real Angle)
27 {
28   myType = Contap_DraftPrs;
29   myEye  = Eye;
30   myCosAng = Cos(M_PI/2.+Angle);
31 }
32
33 inline void Contap_ArcFunction::Set(const gp_Dir& Direction)
34 {
35   myType = Contap_ContourStd;
36   myDir  = Direction;
37 }
38
39 inline void Contap_ArcFunction::Set(const gp_Pnt& Eye)
40 {
41   myType = Contap_ContourPrs;
42   myEye  = Eye;
43 }
44
45 inline void Contap_ArcFunction::Set(const Handle(Adaptor2d_HCurve2d)& A)
46 {
47   myArc = A;
48   seqpt.Clear();
49 }
50
51 inline const gp_Pnt& Contap_ArcFunction::Valpoint
52   (const Standard_Integer Index) const
53 {
54   return seqpt(Index);
55 }