0023365: Name collision of global IsEqual() leads to overriding user's definition
[occt.git] / src / AIS / AIS_EqualDistanceRelation.cdl
CommitLineData
b311480e 1-- Created on: 1998-01-24
2-- Created by: Julia GERASIMOVA
3-- Copyright (c) 1998-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
23class EqualDistanceRelation from AIS inherits Relation from AIS
24
25 ---Purpose: A framework to display equivalent distances between
26 -- shapes and a given plane.
27 -- The distance is the length of a projection from the
28 -- shape to the plane.
29 -- These distances are used to compare shapes by this vector alone.
30
31uses
32 Shape from TopoDS,
33 Plane from Geom,
34 PresentationManager3d from PrsMgr,
35 Presentation from Prs3d,
36 Projector from Prs3d,
37 Transformation from Geom,
38 PresentationManager2d from PrsMgr,
39 GraphicObject from Graphic2d,
40 Selection from SelectMgr,
41 Pnt from gp,
42 Drawer from AIS,
43 ExtendedString from TCollection,
44 Edge from TopoDS,
45 Vertex from TopoDS,
46 Box from Bnd,
47 Dir from gp,
48 ArrowSide from DsgPrs,
49 TypeOfDist from AIS
50
51is
52 Create( aShape1 : Shape from TopoDS;
53 aShape2 : Shape from TopoDS;
54 aShape3 : Shape from TopoDS;
55 aShape4 : Shape from TopoDS;
56 aPlane : Plane from Geom )
57 ---Purpose: Constructs a framework to display equivalent
58 -- distances between the shapes aShape1, aShape2,
59 -- aShape3, aShape4 and the plane aPlane.
60 -- The distance is the length of a projection from the
61 -- shape to the plane.
62 returns mutable EqualDistanceRelation from AIS;
63
64 SetShape3( me: mutable; aShape : Shape from TopoDS )
65 is static;
66 ---Purpose:
67 -- Sets the shape aShape to be used as the shape
68 -- aShape3 in the framework created at construction time.
69 ---C++: inline
70
71 Shape3(me) returns Shape from TopoDS
72 is static;
73 ---Purpose:
74 -- Returns the shape aShape3 from the framework
75 -- created at construction time.
76 ---C++: return const &
77 ---C++: inline
78
79 SetShape4( me: mutable; aShape : Shape from TopoDS )
80 is static;
81 ---C++: inline
82 ---Purpose:
83 -- Sets the shape aShape to be used as the shape
84 -- aShape4 in the framework created at construction time.
85
86 Shape4(me) returns Shape from TopoDS
87 is static;
88 ---C++: return const &
89 ---C++: inline
90 ---Purpose:
91 -- Returns the shape aShape4 from the framework
92 -- created at construction time.
93
94-- Methods from PresentableObject
95
96 Compute( me : mutable;
97 aPresentationManager: PresentationManager3d from PrsMgr;
98 aPresentation : mutable Presentation from Prs3d;
99 aMode : Integer from Standard= 0 )
100 is redefined static private;
101
102 Compute( me : mutable;
103 aProjector : Projector from Prs3d;
104 aPresentation : mutable Presentation from Prs3d )
105 is redefined static private;
106
107 Compute( me : mutable;
108 aPresentationManager : PresentationManager2d from PrsMgr;
109 aPresentation : mutable GraphicObject from Graphic2d;
110 aMode : Integer from Standard = 0 )
111 is redefined static private;
112
113 Compute(me : mutable;
114 aProjector : Projector from Prs3d;
115 aTrsf : Transformation from Geom;
116 aPresentation : mutable Presentation from Prs3d)
117 is redefined;
118 ---Purpose: Computes the presentation according to a point of view
119 -- given by <aProjector>.
120 -- To be Used when the associated degenerated Presentations
121 -- have been transformed by <aTrsf> which is not a Pure
122 -- Translation. The HLR Prs can't be deducted automatically
123 -- WARNING :<aTrsf> must be applied
124 -- to the object to display before computation !!!
125
126-- Methods from SelectableObject
127
128 ComputeSelection( me : mutable;
129 aSelection : mutable Selection from SelectMgr;
130 aMode : Integer from Standard)
131 is private;
132-- ota -- begin
133 ComputeTwoEdgesLength (myclass;
134 aPresentation : mutable Presentation from Prs3d;
135 aDrawer : Drawer from AIS;
136 ArrowSize : Real from Standard;
137 FirstEdge : Edge from TopoDS;
138 SecondEdge : Edge from TopoDS;
139 Plane : Plane from Geom;
140 AutomaticPos : Boolean from Standard;
141 IsSetBndBox : Boolean from Standard;
142 BndBox : Box from Bnd;
143 Position : out Pnt from gp;
144 FirstAttach : out Pnt from gp;
145 SecondAttach : out Pnt from gp;
146 FirstExtreme : out Pnt from gp;
147 SecondExtreme : out Pnt from gp;
148 SymbolPrs : out ArrowSide from DsgPrs );
149 ---Purpose: Computes the location of an intreval between
150 -- between two edges. FirstAttach , SecondAttach
151 -- are the returned extreme points of the interval.
152
153 ComputeTwoVerticesLength(myclass;
154 aPresentation : mutable Presentation from Prs3d;
155 aDrawer : Drawer from AIS;
156 ArrowSize : Real from Standard;
157 FirstVertex : Vertex from TopoDS;
158 SecondVertex : Vertex from TopoDS;
159 Plane : Plane from Geom;
160 AutomaticPos : Boolean from Standard;
161 IsSetBndBox : Boolean from Standard;
162 BndBox : Box from Bnd;
163 TypeDist : TypeOfDist from AIS;
164 Position : out Pnt from gp;
165 FirstAttach : out Pnt from gp;
166 SecondAttach : out Pnt from gp;
167 FirstExtreme : out Pnt from gp;
168 SecondExtreme : out Pnt from gp;
169 SymbolPrs : out ArrowSide from DsgPrs );
170 ---Purpose: Computes the interval position between two vertexs. FirstAttach,
171 -- SecondAttach are the returned extreme points of the interval.
172
173 ComputeOneEdgeOneVertexLength(myclass;
174 aPresentation : mutable Presentation from Prs3d;
175 aDrawer : Drawer from AIS;
176 ArrowSize : Real from Standard;
177 FirstShape : Shape from TopoDS;
178 SecondShape : Shape from TopoDS;
179 Plane : Plane from Geom;
180 AutomaticPos : Boolean from Standard;
181 IsSetBndBox : Boolean from Standard;
182 BndBox : Box from Bnd;
183 Position : out Pnt from gp;
184 FirstAttach : out Pnt from gp;
185 SecondAttach : out Pnt from gp;
186 FirstExtreme : out Pnt from gp;
187 SecondExtreme : out Pnt from gp;
188 SymbolPrs : out ArrowSide from DsgPrs );
189 ---Purpose: Compute the interval location between a vertex and an edge. Edge may be
190 -- a line or a circle.
191
192-- ota -- end
193
194fields
195
196 myShape3 : Shape from TopoDS;
197 myShape4 : Shape from TopoDS;
198
199 myAttachPoint1 : Pnt from gp; -- the start points of constraint curves
200 myAttachPoint2 : Pnt from gp;
201 myAttachPoint3 : Pnt from gp;
202 myAttachPoint4 : Pnt from gp;
203
204 myPoint1 : Pnt from gp; -- the end points constraint curves
205 myPoint2 : Pnt from gp;
206 myPoint3 : Pnt from gp;
207 myPoint4 : Pnt from gp;
208
209end EqualDistanceRelation;