]> SALOME platform Git repositories - modules/shaper_study.git/blob - idl/SHAPERSTUDY_Gen.idl
Salome HOME
Copyright update 2020
[modules/shaper_study.git] / idl / SHAPERSTUDY_Gen.idl
1 // Copyright (C) 2019-2020  CEA/DEN, EDF R&D
2 //
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License, or (at your option) any later version.
7 //
8 // This library is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
11 // Lesser General Public License for more details.
12 //
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
16 //
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18 //
19
20 #ifndef __SHAPERSTUDY_GEN__
21 #define __SHAPERSTUDY_GEN__
22
23 #include "GEOM_Gen.idl"
24 #include "SALOMEDS.idl"
25 #include "SALOME_Exception.idl"
26
27 module SHAPERSTUDY_ORB
28 {
29
30 interface SHAPER_Object : GEOM::GEOM_Object
31 {
32   /*!
33   *  \brief Puts the shape to the object by BRep stream.
34   */
35   void SetShapeByStream(in string theStream);
36   /*!
37   *  \brief Sets the internal entry of the object, common for all objects in SHAPER-STUDY
38   */
39   void SetEntry( in string theInternalEntry );
40   /*!
41   *  \brief Sets SObject of this object (when it is published)
42   */
43   void SetSO( in SALOMEDS::SObject theInternalEntry );
44   /*!
45   *  \brief Returns SObject of this object
46   */
47   SALOMEDS::SObject GetSO();
48   /*!
49   *  \brief Returns true if shape is already dead
50   */
51   boolean IsDead();
52   /*!
53   *  \brief Makes the dead-copy of the shape and returns it
54   */
55   SHAPER_Object MakeDead();
56   /*!
57   *  \brief Returns the stream of the previous version of the shape stored here
58   */
59   SALOMEDS::TMPFile GetOldShapeStream();
60   /*!
61   *  \brief Sets internal type of operation created this object. For group it is 37, shape 1.
62   */
63   void SetType( in long theType );
64
65   /*!
66   *  \brief Sets the shape by the pointer to the TopoDS_Shape
67   */
68   void SetShapeByPointer(in long long theShape);
69 };
70
71 /*!
72  * A group extension of the SHAPER object:
73  * it contains the selection-type and selected sub-shapes indices.
74  */
75 interface SHAPER_Group : SHAPER_Object
76 {
77   /*!
78   *  \brief Sets what is returned in the GEOM_IGroupOperations::GetType
79   */
80   void SetSelectionType(in long theType);
81   /*!
82   *  \brief Returns the type of the selected sub-shapes
83   */
84   long GetSelectionType();
85   /*!
86   *  \brief Sets what is returned in the GEOM_IGroupOperations::GetObjects
87   */
88   void SetSelection(in GEOM::ListOfLong theSelection);
89   /*!
90   *  \brief Returns the selected sub-shapes indices
91   */
92   GEOM::ListOfLong GetSelection();
93   /*!
94   *  \brief Returns the old selected sub-shapes indices (to restore on break-link)
95   */
96   GEOM::ListOfLong GetSelectionOld();
97 };
98
99 interface Gen : GEOM::GEOM_Gen
100 {
101   /*!
102    *  \brief Searches existing or creates a new SHAPERSTUDY_Object to interact with SHAPER
103    */
104   SHAPER_Object FindOrCreateShape(in string theInternalEntry);
105
106   /*!
107   *  \brief Stores the variable names of the SHAPER dump to python
108   */
109   void StoreVariableName(in string theEntry, in string theVarName);
110 };
111
112 interface IShapesOperations : GEOM::GEOM_IShapesOperations
113 {
114 };
115
116 interface IGroupOperations  : GEOM::GEOM_IGroupOperations
117 {
118   /*!
119   *  \brief Searches existing group of theOwner shape by the entry. Returns NULL if can not find.
120   */
121   SHAPER_Group FindGroup(in SHAPER_Object theOwner, in string theEntry);
122 };
123
124 interface SHAPER_Field             : GEOM::GEOM_Field
125 {
126   /*!
127   *  \brief Sets the type of values in the field
128   */
129   void SetValuesType(in short theType);
130   /*!
131   *  \brief Returns the type of values in the field
132   */
133   short GetValuesType();
134
135   /*!
136   *  \brief Sets the list of time step IDs in the field
137   */
138   void SetSteps(in GEOM::ListOfLong theSteps);
139
140   /*!
141   *  \brief Sets the names of components
142   */
143   void SetComponents( in GEOM::string_array theComponents );
144   /*!
145   *  \brief Erases all steps of this field
146   */
147   void ClearFieldSteps();
148
149   /*!
150   *  \brief Appends a step data to this field
151   */
152   void AddFieldStep( in long theStampID, in long theStepID, in GEOM::ListOfDouble theValues);
153
154
155   /*!
156   *  \brief Sets what is returned in the GEOM_IGroupOperations::GetType
157   */
158   void SetSelectionType(in long theType);
159   /*!
160   *  \brief Returns the type of the selected sub-shapes
161   */
162   long GetSelectionType();
163   /*!
164   *  \brief Sets what is returned in the GEOM_IGroupOperations::GetObjects
165   */
166   void SetSelection(in GEOM::ListOfLong theSelection);
167   /*!
168   *  \brief Returns the selected sub-shapes indices
169   */
170   GEOM::ListOfLong GetSelection();
171   /*!
172   *  \brief Returns the old selected sub-shapes indices (to restore on break-link)
173   */
174   GEOM::ListOfLong GetSelectionOld();
175
176   /*!
177   *  \brief Sets the internal entry of the object, common for all objects in SHAPER-STUDY
178   */
179   void SetEntry( in string theInternalEntry );
180   /*!
181   *  \brief Sets SObject of this object (when it is published)
182   */
183   void SetSO( in SALOMEDS::SObject theInternalEntry );
184   /*!
185   *  \brief Returns SObject of this object
186   */
187   SALOMEDS::SObject GetSO();
188   /*!
189   *  \brief Returns true if shape is already dead
190   */
191   boolean IsDead();
192   /*!
193   *  \brief Makes the dead-copy of the shape and returns it
194   */
195   SHAPER_Object MakeDead();
196
197 };
198
199 interface IFieldOperations  : GEOM::GEOM_IFieldOperations
200 {
201   /*!
202   *  \brief Searches existing field of theOwner shape by the entry. Returns NULL if can not find.
203   */
204   SHAPER_Field FindField(in SHAPER_Object theOwner, in string theEntry);
205   /*!
206   *  \brief Creates a field of theMainShape.
207   */
208   SHAPER_Field CreateFieldByType(in GEOM::GEOM_Object theMainShape, in long theShapeType);
209 };
210
211 interface IMeasureOperations  : GEOM::GEOM_IMeasureOperations
212 {
213 };
214
215 interface SHAPER_DoubleFieldStep   : GEOM::GEOM_DoubleFieldStep
216 {
217 };
218
219 interface SHAPER_IntFieldStep      : GEOM::GEOM_IntFieldStep
220 {
221 };
222
223 interface SHAPER_BoolFieldStep     : GEOM::GEOM_BoolFieldStep
224 {
225 };
226
227 };
228
229 #endif