0024977: There are compilation errors in products csharp sample
[occt.git] / src / AIS / AIS_ConnectedShape.cdl
1 -- Created on: 1997-01-08
2 -- Created by: Robert COUBLANC
3 -- Copyright (c) 1997-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 --Modified by rob on Jul-28-97          
18
19
20 class ConnectedShape from AIS inherits ConnectedInteractive from AIS
21
22         ---Purpose: Constructs a Connected Interactive Object with an
23         -- AIS_Shape presentation as its reference Interactive Object.
24         -- In topological decomposition of the shape, this class
25         -- assigns the same owners to the sensitive primitives
26         -- as those in AIS_Shape. Like AIS_Shape, it allows a
27         -- presentation of hidden parts. These are calculated
28         -- automatically from the shape of its reference entity.
29
30     
31
32 uses
33
34     Shape                from TopoDS,
35     Projector            from Prs3d,
36     Presentation         from Prs3d,
37     Selection            from SelectMgr,
38     Integer              from Standard,
39     Shape                from AIS,
40     TypeOfPresentation3d from PrsMgr,
41     PresentationManager3d from PrsMgr,
42     InteractiveObject    from AIS,
43     KindOfInteractive    from AIS,
44     Location             from TopLoc,
45     Transformation       from Geom
46 raises
47     NotImplemented from Standard
48
49 is
50
51     Create (aTypeOfPresentation : TypeOfPresentation3d from PrsMgr 
52                                   =PrsMgr_TOP_ProjectorDependant) 
53     returns  ConnectedShape  from  AIS;
54         ---Purpose: Initializes the type of 3d presentation aTypeOfPresentation
55         
56     Create (aInteractiveShape   : Shape from AIS;
57             aTypeOfPresentation : TypeOfPresentation3d from PrsMgr 
58                                   =PrsMgr_TOP_ProjectorDependant)  
59     returns  ConnectedShape  from  AIS;
60         ---Purpose: Initializes the entity aInteractiveShape and the type of 3d presentation aTypeOfPresentation.
61
62     Create(aConnectedShape     : ConnectedShape from AIS;
63            aTypeOfPresentation : TypeOfPresentation3d from PrsMgr 
64                                 =PrsMgr_TOP_ProjectorDependant)  
65     returns  ConnectedShape  from  AIS;
66         ---Purpose: Initializes the entity aConnectedShape and the type of 3d presentation aTypeOfPresentation.
67     
68     ---Category:  Redefined methods...
69
70     Type(me) returns KindOfInteractive from AIS
71     is redefined virtual;
72
73     Signature(me) returns Integer from Standard
74     is redefined virtual;
75
76     AcceptShapeDecomposition(me) 
77     returns Boolean from Standard is redefined;
78
79
80
81            
82     Connect(me          : mutable; 
83             anotherIObj : InteractiveObject from AIS) is redefined ;
84         ---Purpose:  Establishes the connection between the Connected
85         -- Interactive Object, anotherIobj, and its reference
86         -- entity. If there is already a previous connection with
87         -- an Interactive Object, this connection is removed.
88
89     Connect(me:mutable;
90             anotherIobj: InteractiveObject from AIS;
91             aLocation : Location from TopLoc) is redefined;
92         ---Purpose: Establishes the connection between the Connected
93         -- Interactive Object, anotherIobj, and its reference
94         -- entity. If there is already a previous connection with
95         -- an Interactive Object, this connection is removed.
96         -- This syntax also initiates the location of the Connected Interactive Object.
97
98
99     Compute(me:mutable;
100                 aProjector   :         Projector    from Prs3d;
101                 aPresentation: Presentation from Prs3d)
102     is redefined virtual private;
103  
104     Compute(me                   : mutable;
105             aProjector           : Projector from Prs3d;
106             aTrsf                : Transformation from Geom;
107             aPresentation        : Presentation from Prs3d)
108     is redefined virtual private;
109
110     ComputeSelection(me:mutable; aSelection : Selection from SelectMgr;
111                                  aMode      :        Integer   from Standard)
112     is redefined virtual private;
113         ---Purpose: Generates sensitive entities by copying 
114         -- them from myReferense selection specified by aMode,  
115         -- creates and sets an entity owner for this entities and adds 
116         -- them to aSelection.
117     
118     Shape(me:mutable) returns Shape from TopoDS;
119         ---C++: return const&
120         ---Purpose: Returns the topological shape which is the reference
121         -- for the connected shape. Sets hilight mode to index
122         -- 0. This returns a wireframe presentation.
123         
124
125     UpdateShape(me:mutable;WithLocation:Boolean from Standard = Standard_True)
126     is static private;
127     
128     Compute(me:mutable;
129                 aProjector   :         Projector    from Prs3d;
130                 aPresentation: Presentation from Prs3d;
131                 aShape       :         Shape from TopoDS)
132     is  private;
133
134     
135 fields
136     
137     myOwnSh : Shape   from TopoDS; -- used for HLR and selection...
138     
139 end ConnectedShape;