0023024: Update headers of OCCT files
[occt.git] / src / GC / GC_MakeCircle.cdl
1 -- Created on: 1992-09-28
2 -- Created by: Remi GILET
3 -- Copyright (c) 1992-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
21
22 class MakeCircle from GC inherits Root from GC
23
24     ---Purpose : This class implements the following algorithms used 
25     --           to create Cirlec from Geom.
26     --           
27     --           * Create a Circle parallel to another and passing 
28     --             though a point.
29     --           * Create a Circle parallel to another at the distance 
30     --             Dist.
31     --           * Create a Circle passing through 3 points.
32     --           * Create a Circle with its center and the normal of its 
33     --             plane and its radius.
34     --           * Create a Circle with its axis and radius.
35     --  The circle's parameter is the angle (Radian).
36     --  The parametrization range is [0,2*PI].
37     --  The circle is a closed and periodic curve.
38     --  The center of the circle is the Location point of its axis
39     --  placement. The XDirection of the axis placement defines the 
40     --  origin of the parametrization. 
41
42 uses Pnt       from gp,
43      Circ      from gp,
44      Circle    from Geom,
45      Dir       from gp,
46      Ax1       from gp,
47      Ax2       from gp,
48      Real      from Standard
49
50 raises NotDone from StdFail
51
52 is
53
54 Create (C : Circ from gp)   returns MakeCircle;
55     --- Purpose :  creates a circle from a non persistent circle C by its conversion.
56
57 Create (A2     : Ax2  from gp      ; 
58         Radius : Real from Standard)  returns MakeCircle;
59     --- Purpose :
60     --  A2 is the local coordinates system of the circle.
61     --  It is not forbidden to create a circle with Radius = 0.0
62     --  Status is "NegativeRadius" if Radius < 0.
63
64 Create(Circ : Circ from gp      ;
65        Dist : Real from Standard) returns MakeCircle;
66     ---Purpose : Make a Circle from Geom <TheCirc> parallel to another 
67     --           Circ <Circ> with a distance <Dist>.
68     --           If Dist is greater than zero the result is enclosing 
69     --           the circle <Circ>, else the result is enclosed by the 
70     --           circle <Circ>.
71
72 Create(Circ    :     Circ from gp;
73        Point   :     Pnt  from gp) returns MakeCircle;
74     ---Purpose : Make a Circle from Geom <TheCirc> parallel to another 
75     --           Circ <Circ> and passing through a Pnt <Point>.
76
77 Create(P1,P2,P3 : Pnt  from gp) returns MakeCircle;
78     ---Purpose : Make a Circ from gp <TheCirc> passing through 3 
79     --           Pnt2d <P1>,<P2>,<P3>.
80
81 Create(Center  : Pnt  from gp      ;
82        Norm    : Dir  from gp      ;
83        Radius  : Real from Standard) returns MakeCircle;
84     ---Purpose : Make a Circle from Geom <TheCirc> with its center 
85     --           <Center> and the normal of its plane <Norm> and 
86     --           its radius <Radius>.
87
88 Create(Center  : Pnt  from gp      ;
89        PtAxis  : Pnt  from gp      ;
90        Radius  : Real from Standard) returns MakeCircle;
91     ---Purpose : Make a Circle from Geom <TheCirc> with its center 
92     --           <Center> and the normal of its plane defined by the 
93     --           two points <Center> and <PtAxis> and its radius <Radius>.
94
95 Create(Axis   : Ax1  from gp      ;
96        Radius : Real from Standard) returns MakeCircle;
97     ---Purpose : Make a Circle from Geom <TheCirc> with its center 
98     --           <Center> and its radius <Radius>.
99
100 Value(me) returns Circle from Geom
101     raises NotDone
102     is static;
103     --- Purpose:
104     -- Returns the constructed circle.
105     -- Exceptions
106     -- StdFail_NotDone if no circle is constructed.
107     ---C++: return const&
108
109 Operator(me) returns Circle from Geom
110     is static;
111     ---C++: return const&
112     ---C++: alias "Standard_EXPORT operator Handle_Geom_Circle() const;"
113
114 fields
115
116     TheCircle : Circle from Geom;
117     --The solution from Geom.
118     
119 end MakeCircle;
120