0024047: Exception in TPrsStd_AISPresentation during destruction of TDocStd_Document
[occt.git] / src / AIS / AIS_MultipleConnectedInteractive.cdl
1 -- Created on: 1997-04-22
2 -- Created by: Guest Design
3 -- Copyright (c) 1997-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 MultipleConnectedInteractive from AIS inherits InteractiveObject from AIS
23
24     
25     ---Purpose: Defines an Interactive Object by gathering together
26     -- several object presentations. This is done through a
27     -- list of interactive objects. These can also be
28     -- Connected objects. That way memory-costly
29     -- calculations of presentation are avoided.
30         
31         
32 uses
33
34
35     TypeOfPresentation3d   from PrsMgr,
36     InteractiveObject      from AIS,
37     Boolean                from Standard,
38     SequenceOfInteractive  from AIS,
39     KindOfInteractive      from AIS,
40     PresentationManager3d  from PrsMgr,
41     Presentation           from Prs3d,
42     Projector             from Prs3d,
43     Transformation        from Geom,
44     Integer                from Standard,
45     Selection              from SelectMgr
46
47 is 
48     
49
50     Create (aTypeOfPresentation3d: TypeOfPresentation3d from PrsMgr = PrsMgr_TOP_AllView) 
51     returns  mutable  MultipleConnectedInteractive  from  AIS;
52     ---Purpose: Initializes the Interactive Object with multiple
53     -- presentation connections. If aTypeOfPresentation3d
54     -- does not have the affectation PrsMgr_TOP_AllView,
55     -- it is projector dependent.
56     
57     Connect(me          : mutable; 
58             anotherIObj : InteractiveObject from AIS);
59     ---Purpose: Add anotherIObj in the presentation of me
60
61
62     Type(me) returns KindOfInteractive from AIS
63     is redefined virtual;         
64
65     Signature(me) returns Integer from Standard
66     is redefined virtual;
67
68     HasConnection(me) returns Boolean from Standard;
69     ---Purpose: Returns true if the object is connected to others.
70    
71      ConnectedTo(me) returns SequenceOfInteractive from AIS;
72      ---Purpose:
73      -- Returns the connection references of the previous
74      -- Interactive Objects in view.
75      ---C++: inline
76      ---C++: return const&
77
78     Disconnect(me:mutable;
79                anotherIObj : InteractiveObject from AIS);
80     ---Purpose:  Removes the connection anotherIObj to an entity.
81
82     DisconnectAll(me:mutable);
83     ---Purpose: Clears all the connections to objects.
84     
85     Compute(me:mutable;
86             aPresentationManager :         PresentationManager3d from PrsMgr;
87             aPresentation        : mutable Presentation          from Prs3d;
88             aMode                :         Integer               from Standard = 0)
89     ---Level: Internal 
90     ---Purpose: this method is redefined virtual;
91     --          when the instance is connected to another
92     --          InteractiveObject,this method doesn't
93     --          compute anything, but just uses the 
94     --          presentation of this last object, with
95     --          a transformation if there's one stored. 
96     is redefined virtual protected; 
97
98     Compute(me            : mutable;
99             aProjector    : Projector from Prs3d;
100             aTrsf         : Transformation from Geom;
101             aPresentation : mutable Presentation from Prs3d)
102     is redefined;
103     ---Purpose: computes the presentation according to a point of view
104     --          given by <aProjector>. 
105     --          To be Used when the associated degenerated Presentations 
106     --          have been transformed by <aTrsf> which is not a Pure
107     --          Translation. The HLR Prs can't be deducted automatically
108     --          WARNING :<aTrsf> must be applied
109     --           to the object to display before computation  !!!
110
111     Compute(me:mutable;
112                 aProjector: Projector from Prs3d;
113                 aPresentation: mutable Presentation from Prs3d)
114     is redefined ;     
115
116     ComputeSelection(me:mutable; aSelection :mutable Selection from SelectMgr;
117                                  aMode      :        Integer   from Standard)
118     is redefined virtual private;
119
120
121
122 fields
123
124     myReferences         : SequenceOfInteractive from AIS;
125     myPreviousReferences : SequenceOfInteractive from AIS;
126     
127 end MultipleConnectedInteractive;