Salome HOME
untabify
[modules/geom.git] / src / GEOM_I_Superv / GEOM_Superv_i.hh
1 //  Copyright (C) 2007-2008  CEA/DEN, EDF R&D, OPEN CASCADE
2 //
3 //  Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 //  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
5 //
6 //  This library is free software; you can redistribute it and/or
7 //  modify it under the terms of the GNU Lesser General Public
8 //  License as published by the Free Software Foundation; either
9 //  version 2.1 of the License.
10 //
11 //  This library is distributed in the hope that it will be useful,
12 //  but WITHOUT ANY WARRANTY; without even the implied warranty of
13 //  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14 //  Lesser General Public License for more details.
15 //
16 //  You should have received a copy of the GNU Lesser General Public
17 //  License along with this library; if not, write to the Free Software
18 //  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
19 //
20 //  See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
21 //
22 #ifndef __GEOM_SUPERV_I_H__
23 #define __GEOM_SUPERV_I_H__
24
25 // IDL headers
26 #include <SALOMEconfig.h>
27 #include CORBA_SERVER_HEADER(GEOM_Superv)
28
29 #include "GEOM_Gen_i.hh"
30 #include "GEOM_List_i.hh"
31
32 class GEOM_Superv_i : public virtual POA_GEOM::GEOM_Superv,
33                       public Engines_Component_i
34 {
35 public:
36   GEOM_Superv_i(CORBA::ORB_ptr orb,
37                 PortableServer::POA_ptr poa,
38                 PortableServer::ObjectId * contId, 
39                 const char *instanceName, 
40                 const char *interfaceName);
41   ~GEOM_Superv_i();
42
43   // generic method to be put in a super class
44   void register_name(char * name);
45   void setGeomEngine();
46
47   void getBasicOp();
48   void get3DPrimOp();
49   void getBoolOp();
50   void getInsOp();
51   void getTransfOp();
52   void getShapesOp();
53   void getBlocksOp();
54   void getCurvesOp();
55   void getLocalOp();
56   void getGroupOp();  
57
58   PortableServer::ServantBase_var GetServant(CORBA::Object_ptr       theObject,
59                                              PortableServer::POA_ptr thePOA);
60
61   //-----------------------------------------------------------------------//
62   // Set current stydy ID                                                  //
63   //-----------------------------------------------------------------------//
64   void SetStudyID( CORBA::Long theId );      
65
66   //-----------------------------------------------------------//
67   // Create ListOfGO and add items to it                       // 
68   //-----------------------------------------------------------//
69   GEOM::GEOM_List_ptr CreateListOfGO();
70   void AddItemToListOfGO(GEOM::GEOM_List_ptr& theList, 
71                          GEOM::GEOM_Object_ptr theObject);
72
73   //-----------------------------------------------------------//
74   // Create ListOfLong and add items to it                     // 
75   //-----------------------------------------------------------//
76   GEOM::GEOM_List_ptr CreateListOfLong();
77   void AddItemToListOfLong(GEOM::GEOM_List_ptr& theList, 
78                            CORBA::Long theObject);
79   
80   //-----------------------------------------------------------//
81   // Create ListOfDouble and add items to it                   // 
82   //-----------------------------------------------------------//
83   GEOM::GEOM_List_ptr CreateListOfDouble();
84   void AddItemToListOfDouble(GEOM::GEOM_List_ptr& theList, 
85                              CORBA::Double theObject);
86
87   //-----------------------------------------------------------------------//
88   // Inherited methods from SALOMEDS::Driver                               //
89   //-----------------------------------------------------------------------//    
90
91   SALOMEDS::TMPFile* Save(SALOMEDS::SComponent_ptr theComponent,
92                           const char* theURL,
93                           CORBA::Boolean isMultiFile);
94
95   SALOMEDS::TMPFile* SaveASCII(SALOMEDS::SComponent_ptr theComponent,
96                                const char* theURL,
97                                CORBA::Boolean isMultiFile);
98   
99   CORBA::Boolean Load(SALOMEDS::SComponent_ptr theComponent,
100                       const SALOMEDS::TMPFile& theStream,
101                       const char* theURL,
102                       CORBA::Boolean isMultiFile);
103
104   CORBA::Boolean LoadASCII(SALOMEDS::SComponent_ptr theComponent,
105                            const SALOMEDS::TMPFile& theStream,
106                            const char* theURL,
107                            CORBA::Boolean isMultiFile);
108
109   void Close(SALOMEDS::SComponent_ptr theComponent);
110   char* ComponentDataType();
111
112
113   char* IORToLocalPersistentID(SALOMEDS::SObject_ptr theSObject,
114                                const char* IORString,
115                                CORBA::Boolean isMultiFile,
116                                CORBA::Boolean isASCII);
117   char* LocalPersistentIDToIOR(SALOMEDS::SObject_ptr theSObject,
118                                const char* aLocalPersistentID,
119                                CORBA::Boolean isMultiFile,
120                                CORBA::Boolean isASCII);
121
122   CORBA::Boolean CanPublishInStudy(CORBA::Object_ptr theIOR);
123   SALOMEDS::SObject_ptr PublishInStudy(SALOMEDS::Study_ptr theStudy,
124                                        SALOMEDS::SObject_ptr theSObject,
125                                        CORBA::Object_ptr theObject,
126                                        const char* theName) throw (SALOME::SALOME_Exception) ;
127
128   GEOM::ListOfGO* PublishNamedShapesInStudy(SALOMEDS::Study_ptr theStudy,
129                                             //SALOMEDS::SObject_ptr theSObject,
130                                             CORBA::Object_ptr theObject);
131
132   CORBA::Boolean CanCopy(SALOMEDS::SObject_ptr theObject);
133   SALOMEDS::TMPFile* CopyFrom(SALOMEDS::SObject_ptr theObject, CORBA::Long& theObjectID);
134   CORBA::Boolean CanPaste(const char* theComponentName, CORBA::Long theObjectID);
135   SALOMEDS::SObject_ptr PasteInto(const SALOMEDS::TMPFile& theStream,
136                                   CORBA::Long theObjectID,
137                                   SALOMEDS::SObject_ptr theObject);
138
139   //-----------------------------------------------------------//
140   // Primitives Construction : BasicOperations                 // 
141   //-----------------------------------------------------------//
142   GEOM::GEOM_Object_ptr MakePointXYZ (CORBA::Double theX,
143                                       CORBA::Double theY,
144                                       CORBA::Double theZ);
145   GEOM::GEOM_Object_ptr MakePointWithReference (GEOM::GEOM_Object_ptr theReference,
146                                                 CORBA::Double theX, 
147                                                 CORBA::Double theY, 
148                                                 CORBA::Double theZ);
149   GEOM::GEOM_Object_ptr MakePointOnCurve (GEOM::GEOM_Object_ptr theRefCurve,
150                                           CORBA::Double theParameter);
151   GEOM::GEOM_Object_ptr MakePointOnCurveByCoord (GEOM::GEOM_Object_ptr theRefCurve,
152                                                  CORBA::Double theXParameter,
153                                                  CORBA::Double theYParameter,
154                                                  CORBA::Double theZParameter);
155   GEOM::GEOM_Object_ptr MakePointOnSurface (GEOM::GEOM_Object_ptr theRefSurface,
156                                             CORBA::Double theUParameter,
157                                             CORBA::Double theVParameter);
158   GEOM::GEOM_Object_ptr MakePointOnSurfaceByCoord (GEOM::GEOM_Object_ptr theRefSurface,
159                                                    CORBA::Double theXParameter,
160                                                    CORBA::Double theYParameter,
161                                                    CORBA::Double theZParameter);
162   GEOM::GEOM_Object_ptr MakePointOnLinesIntersection (GEOM::GEOM_Object_ptr theRefLine1,
163                                                       GEOM::GEOM_Object_ptr theRefLine2);
164   GEOM::GEOM_Object_ptr MakeTangentOnCurve (GEOM::GEOM_Object_ptr theRefCurve,
165                                              CORBA::Double theParameter);
166   GEOM::GEOM_Object_ptr MakeVectorDXDYDZ (CORBA::Double theDX,
167                                           CORBA::Double theDY,
168                                           CORBA::Double theDZ);
169   GEOM::GEOM_Object_ptr MakeVectorTwoPnt (GEOM::GEOM_Object_ptr thePnt1,
170                                           GEOM::GEOM_Object_ptr thePnt2);
171   GEOM::GEOM_Object_ptr MakeLineTwoPnt (GEOM::GEOM_Object_ptr thePnt1,
172                                         GEOM::GEOM_Object_ptr thePnt2);
173   GEOM::GEOM_Object_ptr MakeLineTwoFaces (GEOM::GEOM_Object_ptr theFace1,
174                                           GEOM::GEOM_Object_ptr theFace2);
175   GEOM::GEOM_Object_ptr MakePlaneThreePnt (GEOM::GEOM_Object_ptr thePnt1,
176                                            GEOM::GEOM_Object_ptr thePnt2,
177                                            GEOM::GEOM_Object_ptr thePnt3,
178                                            CORBA::Double theTrimSize);
179   GEOM::GEOM_Object_ptr MakePlanePntVec (GEOM::GEOM_Object_ptr thePnt,
180                                          GEOM::GEOM_Object_ptr theVec,
181                                          CORBA::Double theTrimSize);
182   GEOM::GEOM_Object_ptr MakePlaneFace (GEOM::GEOM_Object_ptr theFace,
183                                        CORBA::Double theTrimSize);
184   GEOM::GEOM_Object_ptr MakePlane2Vec (GEOM::GEOM_Object_ptr theVec1,
185                                        GEOM::GEOM_Object_ptr theVec2,
186                                        CORBA::Double theTrimSize);
187   GEOM::GEOM_Object_ptr MakePlaneLCS (GEOM::GEOM_Object_ptr theLCS,
188                                       CORBA::Double theTrimSize,
189                                       CORBA::Double theOrientation);
190   GEOM::GEOM_Object_ptr MakeMarker (CORBA::Double theOX , CORBA::Double theOY , CORBA::Double theOZ,
191                                     CORBA::Double theXDX, CORBA::Double theXDY, CORBA::Double theXDZ,
192                                     CORBA::Double theYDX, CORBA::Double theYDY, CORBA::Double theYDZ);
193
194   GEOM::GEOM_Object_ptr MakeTangentPlaneOnFace (GEOM::GEOM_Object_ptr theFace, 
195                                                  CORBA::Double theParameterU,
196                                                  CORBA::Double theParameterV,
197                                                  CORBA::Double theTrimSize);
198
199   //-----------------------------------------------------------//
200   // Primitives Construction : 3DPrimOperations                //
201   //-----------------------------------------------------------//
202   GEOM::GEOM_Object_ptr MakeBox (CORBA::Double theX1,
203                                  CORBA::Double theY1,
204                                  CORBA::Double theZ1,
205                                  CORBA::Double theX2,
206                                  CORBA::Double theY2,
207                                  CORBA::Double theZ2);
208   GEOM::GEOM_Object_ptr MakeBoxDXDYDZ (CORBA::Double theDX, 
209                                        CORBA::Double theDY, 
210                                        CORBA::Double theDZ);
211   GEOM::GEOM_Object_ptr MakeBoxTwoPnt (GEOM::GEOM_Object_ptr thePnt1, 
212                                        GEOM::GEOM_Object_ptr thePnt2);
213   GEOM::GEOM_Object_ptr MakeFaceHW (CORBA::Double theH,
214                                     CORBA::Double theW,
215                                     CORBA::Short  theOrientation);
216   GEOM::GEOM_Object_ptr MakeFaceObjHW (GEOM::GEOM_Object_ptr theObj, 
217                                        CORBA::Double theH,
218                                        CORBA::Double theW);
219   GEOM::GEOM_Object_ptr MakeDiskPntVecR (GEOM::GEOM_Object_ptr theCenter,
220                                          GEOM::GEOM_Object_ptr theVector,
221                                          CORBA::Double theR);
222   GEOM::GEOM_Object_ptr MakeDiskThreePnt (GEOM::GEOM_Object_ptr thePnt1,
223                                           GEOM::GEOM_Object_ptr thePnt2,
224                                           GEOM::GEOM_Object_ptr thePnt3);
225   GEOM::GEOM_Object_ptr MakeDiskR (CORBA::Double theR,
226                                    CORBA::Short  theOrientation);
227   GEOM::GEOM_Object_ptr MakeCylinderPntVecRH (GEOM::GEOM_Object_ptr thePnt,
228                                               GEOM::GEOM_Object_ptr theAxis,
229                                               CORBA::Double theRadius,
230                                               CORBA::Double theHeight);
231   GEOM::GEOM_Object_ptr MakeCylinderRH (CORBA::Double theR, 
232                                         CORBA::Double theH);
233   GEOM::GEOM_Object_ptr MakeSphere (CORBA::Double theX,
234                                     CORBA::Double theY,
235                                     CORBA::Double theZ,
236                                     CORBA::Double theRadius);
237   GEOM::GEOM_Object_ptr MakeSphereR (CORBA::Double theR);
238   GEOM::GEOM_Object_ptr MakeSpherePntR (GEOM::GEOM_Object_ptr thePnt, 
239                                         CORBA::Double theR);
240   GEOM::GEOM_Object_ptr MakeTorusPntVecRR (GEOM::GEOM_Object_ptr thePnt,
241                                            GEOM::GEOM_Object_ptr theVec,
242                                            CORBA::Double theRMajor,
243                                            CORBA::Double theRMinor);
244   GEOM::GEOM_Object_ptr MakeTorusRR (CORBA::Double theRMajor,
245                                      CORBA::Double theRMinor);
246   GEOM::GEOM_Object_ptr MakeConePntVecR1R2H (GEOM::GEOM_Object_ptr thePnt,
247                                              GEOM::GEOM_Object_ptr theAxis,
248                                              CORBA::Double theR1,
249                                              CORBA::Double theR2,
250                                              CORBA::Double theHeight);
251   GEOM::GEOM_Object_ptr MakeConeR1R2H (CORBA::Double theR1, 
252                                        CORBA::Double theR2, 
253                                        CORBA::Double theHeight);
254   GEOM::GEOM_Object_ptr MakePrismVecH (GEOM::GEOM_Object_ptr theBase,
255                                        GEOM::GEOM_Object_ptr theVec,
256                                        CORBA::Double         theH);
257   GEOM::GEOM_Object_ptr MakePrismVecH2Ways (GEOM::GEOM_Object_ptr theBase,
258                                             GEOM::GEOM_Object_ptr theVec,
259                                             CORBA::Double         theH);
260   GEOM::GEOM_Object_ptr MakePrismTwoPnt (GEOM::GEOM_Object_ptr theBase,
261                                          GEOM::GEOM_Object_ptr thePoint1,
262                                          GEOM::GEOM_Object_ptr thePoint2);
263   GEOM::GEOM_Object_ptr MakePrismTwoPnt2Ways (GEOM::GEOM_Object_ptr theBase,
264                                               GEOM::GEOM_Object_ptr thePoint1,
265                                               GEOM::GEOM_Object_ptr thePoint2);
266   GEOM::GEOM_Object_ptr MakePrismDXDYDZ (GEOM::GEOM_Object_ptr theBase,
267                                          CORBA::Double         theDX,
268                                          CORBA::Double         theDY,
269                                          CORBA::Double         theDZ);
270   GEOM::GEOM_Object_ptr MakePrismDXDYDZ2Ways (GEOM::GEOM_Object_ptr theBase,
271                                               CORBA::Double         theDX,
272                                               CORBA::Double         theDY,
273                                               CORBA::Double         theDZ);
274   GEOM::GEOM_Object_ptr MakePipe (GEOM::GEOM_Object_ptr theBase, 
275                                   GEOM::GEOM_Object_ptr thePath);
276   GEOM::GEOM_Object_ptr MakeRevolutionAxisAngle (GEOM::GEOM_Object_ptr theBase,
277                                                  GEOM::GEOM_Object_ptr theAxis,
278                                                  CORBA::Double theAngle);
279   GEOM::GEOM_Object_ptr MakeRevolutionAxisAngle2Ways (GEOM::GEOM_Object_ptr theBase,
280                                                       GEOM::GEOM_Object_ptr theAxis,
281                                                       CORBA::Double theAngle);
282   GEOM::GEOM_Object_ptr MakeFilling (GEOM::GEOM_Object_ptr theShape,
283                                      CORBA::Long theMinDeg, CORBA::Long theMaxDeg,
284                                      CORBA::Double theTol2D, CORBA::Double theTol3D,
285                                      CORBA::Long theNbIter, CORBA::Boolean theApprox);
286
287   GEOM::GEOM_Object_ptr MakeThruSections(const GEOM::ListOfGO& theSeqSections,
288                                          CORBA::Boolean theModeSolid,
289                                          CORBA::Double thePreci,
290                                          CORBA::Boolean theRuled);
291   
292   GEOM::GEOM_Object_ptr MakePipeWithDifferentSections(const GEOM::ListOfGO& theBases,
293                                                       const GEOM::ListOfGO& theLocations,
294                                                       GEOM::GEOM_Object_ptr thePath,
295                                                       CORBA::Boolean theWithContact,
296                                                       CORBA::Boolean theWithCorrections);
297   
298   GEOM::GEOM_Object_ptr MakePipeWithShellSections(const GEOM::ListOfGO& theBases,
299                                                   const GEOM::ListOfGO& theSubBases,
300                                                   const GEOM::ListOfGO& theLocations,
301                                                   GEOM::GEOM_Object_ptr thePath,
302                                                   CORBA::Boolean theWithContact,
303                                                   CORBA::Boolean theWithCorrections);
304
305   GEOM::GEOM_Object_ptr MakePipeShellsWithoutPath(const GEOM::ListOfGO& theBases,
306                                                   const GEOM::ListOfGO& theLocations);
307   
308   GEOM::GEOM_Object_ptr MakePipeBiNormalAlongVector (GEOM::GEOM_Object_ptr theBase,
309                                                      GEOM::GEOM_Object_ptr thePath,
310                                                      GEOM::GEOM_Object_ptr theVec);
311
312   //-----------------------------------------------------------//
313   // BooleanOperations                                         //
314   //-----------------------------------------------------------//
315   GEOM::GEOM_Object_ptr MakeBoolean (GEOM::GEOM_Object_ptr theShape1,
316                                      GEOM::GEOM_Object_ptr theShape2,
317                                      CORBA::Long theOperation);
318   GEOM::GEOM_Object_ptr MakeFuse (GEOM::GEOM_Object_ptr theShape1,
319                                   GEOM::GEOM_Object_ptr theShape2);
320   GEOM::GEOM_Object_ptr MakePartition (GEOM::GEOM_List_ptr   theShapes,
321                                        GEOM::GEOM_List_ptr   theTools,
322                                        GEOM::GEOM_List_ptr   theKeepInside,
323                                        GEOM::GEOM_List_ptr   theRemoveInside,
324                                        CORBA::Short      theLimit,
325                                        CORBA::Boolean    theRemoveWebs,
326                                        GEOM::GEOM_List_ptr theMaterials,
327                                        CORBA::Short theKeepNonlimitShapes);
328   GEOM::GEOM_Object_ptr MakeHalfPartition (GEOM::GEOM_Object_ptr theShape,
329                                            GEOM::GEOM_Object_ptr thePlane);
330
331   //-----------------------------------------------------------//
332   // InsertOperations                                          //
333   //-----------------------------------------------------------//
334   GEOM::GEOM_Object_ptr MakeCopy (GEOM::GEOM_Object_ptr theOriginal);
335   void Export (GEOM::GEOM_Object_ptr theObject, 
336                const char*           theFileName, 
337                const char*           theFormatName);
338   GEOM::GEOM_Object_ptr Import (const char* theFileName, 
339                                 const char* theFormatName);
340   void ImportTranslators (GEOM::string_array_out theFormats,
341                           GEOM::string_array_out thePatterns);
342   void ExportTranslators (GEOM::string_array_out theFormats,
343                           GEOM::string_array_out thePatterns);
344
345   //-----------------------------------------------------------//
346   // TransformOperations                                       //
347   //-----------------------------------------------------------//
348   GEOM::GEOM_Object_ptr TranslateTwoPoints (GEOM::GEOM_Object_ptr theObject,
349                                             GEOM::GEOM_Object_ptr thePoint1,
350                                             GEOM::GEOM_Object_ptr thePoint2);
351   GEOM::GEOM_Object_ptr TranslateTwoPointsCopy (GEOM::GEOM_Object_ptr theObject,
352                                                 GEOM::GEOM_Object_ptr thePoint1,
353                                                 GEOM::GEOM_Object_ptr thePoint2);
354   GEOM::GEOM_Object_ptr TranslateDXDYDZ (GEOM::GEOM_Object_ptr theObject,
355                                          CORBA::Double theDX, 
356                                          CORBA::Double theDY, 
357                                          CORBA::Double theDZ);
358   GEOM::GEOM_Object_ptr TranslateDXDYDZCopy (GEOM::GEOM_Object_ptr theObject,
359                                              CORBA::Double theDX, 
360                                              CORBA::Double theDY, 
361                                              CORBA::Double theDZ);
362   GEOM::GEOM_Object_ptr TranslateVector (GEOM::GEOM_Object_ptr theObject,
363                                          GEOM::GEOM_Object_ptr theVector);
364   GEOM::GEOM_Object_ptr TranslateVectorCopy (GEOM::GEOM_Object_ptr theObject,
365                                              GEOM::GEOM_Object_ptr theVector);
366   GEOM::GEOM_Object_ptr TranslateVectorDistance (GEOM::GEOM_Object_ptr theObject,
367                                                  GEOM::GEOM_Object_ptr theVector,
368                                                  CORBA::Double theDistance,
369                                                  CORBA::Boolean theCopy);
370   GEOM::GEOM_Object_ptr MultiTranslate1D (GEOM::GEOM_Object_ptr theObject,
371                                           GEOM::GEOM_Object_ptr theVector,
372                                           CORBA::Double theStep,
373                                           CORBA::Long theNbTimes);
374   GEOM::GEOM_Object_ptr MultiTranslate2D (GEOM::GEOM_Object_ptr theObject,
375                                           GEOM::GEOM_Object_ptr theVector1,
376                                           CORBA::Double theStep1,
377                                           CORBA::Long theNbTimes1,
378                                           GEOM::GEOM_Object_ptr theVector2,
379                                           CORBA::Double theStep2,
380                                           CORBA::Long theNbTimes2);
381   GEOM::GEOM_Object_ptr Rotate (GEOM::GEOM_Object_ptr theObject,
382                                 GEOM::GEOM_Object_ptr theAxis,
383                                 CORBA::Double theAngle);
384   GEOM::GEOM_Object_ptr RotateCopy (GEOM::GEOM_Object_ptr theObject,
385                                     GEOM::GEOM_Object_ptr theAxis,
386                                     CORBA::Double theAngle);
387
388   GEOM::GEOM_Object_ptr RotateThreePoints (GEOM::GEOM_Object_ptr theObject,
389                                            GEOM::GEOM_Object_ptr theCentPoint,
390                                            GEOM::GEOM_Object_ptr thePoint1,
391                                            GEOM::GEOM_Object_ptr thePoint2);
392
393   GEOM::GEOM_Object_ptr RotateThreePointsCopy (GEOM::GEOM_Object_ptr theObject,
394                                                GEOM::GEOM_Object_ptr theCentPoint,
395                                                GEOM::GEOM_Object_ptr thePoint1,
396                                                GEOM::GEOM_Object_ptr thePoint2);
397
398   GEOM::GEOM_Object_ptr MultiRotate1D (GEOM::GEOM_Object_ptr theObject,
399                                        GEOM::GEOM_Object_ptr theAxis,
400                                        CORBA::Long theNbTimes);
401   GEOM::GEOM_Object_ptr MultiRotate2D (GEOM::GEOM_Object_ptr theObject,
402                                        GEOM::GEOM_Object_ptr theAxis,
403                                        CORBA::Double theAngle,
404                                        CORBA::Long theNbTimes1,
405                                        CORBA::Double theStep,
406                                        CORBA::Long theNbTimes2);
407   GEOM::GEOM_Object_ptr MirrorPlane (GEOM::GEOM_Object_ptr theObject, 
408                                      GEOM::GEOM_Object_ptr thePlane);
409   GEOM::GEOM_Object_ptr MirrorPlaneCopy (GEOM::GEOM_Object_ptr theObject, 
410                                          GEOM::GEOM_Object_ptr thePlane);
411   GEOM::GEOM_Object_ptr MirrorAxis (GEOM::GEOM_Object_ptr theObject, 
412                                     GEOM::GEOM_Object_ptr theAxis);
413   GEOM::GEOM_Object_ptr MirrorAxisCopy (GEOM::GEOM_Object_ptr theObject, 
414                                         GEOM::GEOM_Object_ptr theAxis);
415   GEOM::GEOM_Object_ptr MirrorPoint (GEOM::GEOM_Object_ptr theObject, 
416                                      GEOM::GEOM_Object_ptr thePoint);
417   GEOM::GEOM_Object_ptr MirrorPointCopy (GEOM::GEOM_Object_ptr theObject, 
418                                          GEOM::GEOM_Object_ptr thePoint);
419   GEOM::GEOM_Object_ptr OffsetShape (GEOM::GEOM_Object_ptr theObject, 
420                                      CORBA::Double theOffset);
421   GEOM::GEOM_Object_ptr OffsetShapeCopy (GEOM::GEOM_Object_ptr theObject, 
422                                          CORBA::Double theOffset);
423   GEOM::GEOM_Object_ptr ScaleShape (GEOM::GEOM_Object_ptr theObject, 
424                                     GEOM::GEOM_Object_ptr thePoint,
425                                     CORBA::Double theFactor);
426   GEOM::GEOM_Object_ptr ScaleShapeCopy (GEOM::GEOM_Object_ptr theObject, 
427                                         GEOM::GEOM_Object_ptr thePoint,
428                                         CORBA::Double theFactor);
429   GEOM::GEOM_Object_ptr ScaleShapeAlongAxes (GEOM::GEOM_Object_ptr theObject,
430                                              GEOM::GEOM_Object_ptr thePoint,
431                                              CORBA::Double theFactorX,
432                                              CORBA::Double theFactorY,
433                                              CORBA::Double theFactorZ);
434   GEOM::GEOM_Object_ptr ScaleShapeAlongAxesCopy (GEOM::GEOM_Object_ptr theObject,
435                                                  GEOM::GEOM_Object_ptr thePoint,
436                                                  CORBA::Double theFactorX,
437                                                  CORBA::Double theFactorY,
438                                                  CORBA::Double theFactorZ);
439   GEOM::GEOM_Object_ptr PositionShape (GEOM::GEOM_Object_ptr theObject,
440                                        GEOM::GEOM_Object_ptr theStartLCS,
441                                        GEOM::GEOM_Object_ptr theEndLCS);
442   GEOM::GEOM_Object_ptr PositionShapeCopy (GEOM::GEOM_Object_ptr theObject,
443                                            GEOM::GEOM_Object_ptr theStartLCS,
444                                            GEOM::GEOM_Object_ptr theEndLCS);
445   GEOM::GEOM_Object_ptr PositionAlongPath (GEOM::GEOM_Object_ptr theObject,
446                                            GEOM::GEOM_Object_ptr thePath,
447                                            CORBA::Double         theDistance,
448                                            CORBA::Boolean        theCopy,
449                                            CORBA::Boolean        theReverse);
450
451   //-----------------------------------------------------------//
452   // ShapesOperations                                          //
453   //-----------------------------------------------------------//
454   GEOM::GEOM_Object_ptr MakeEdge (GEOM::GEOM_Object_ptr thePnt1,
455                                   GEOM::GEOM_Object_ptr thePnt2);
456   GEOM::GEOM_Object_ptr MakeWire (GEOM::GEOM_List_ptr theEdgesAndWires,
457                                   CORBA::Double       theTolerance);
458   GEOM::GEOM_Object_ptr MakeFace (GEOM::GEOM_Object_ptr theWire,
459                                   CORBA::Boolean isPlanarWanted);
460   GEOM::GEOM_Object_ptr MakeFaceWires (GEOM::GEOM_List_ptr theWires,
461                                        CORBA::Boolean isPlanarWanted);
462   GEOM::GEOM_Object_ptr MakeShell (GEOM::GEOM_List_ptr theFacesAndShells);
463   GEOM::GEOM_Object_ptr MakeSolidShell (GEOM::GEOM_Object_ptr theShell);
464   GEOM::GEOM_Object_ptr MakeSolidShells (GEOM::GEOM_List_ptr theShells);
465   GEOM::GEOM_Object_ptr MakeCompound (GEOM::GEOM_List_ptr theShapes);
466   GEOM::GEOM_Object_ptr MakeGlueFaces (GEOM::GEOM_Object_ptr theShape,
467                                        CORBA::Double theTolerance,
468                                        CORBA::Boolean doKeepNonSolids);
469   GEOM::GEOM_List_ptr GetGlueFaces (GEOM::GEOM_Object_ptr theShape,
470                                     CORBA::Double theTolerance);
471   GEOM::GEOM_Object_ptr MakeGlueFacesByList (GEOM::GEOM_Object_ptr theShape,
472                                              CORBA::Double theTolerance,
473                                              const GEOM::ListOfGO& theFaces,
474                                              CORBA::Boolean doKeepNonSolids);
475   GEOM::GEOM_List_ptr MakeExplode (GEOM::GEOM_Object_ptr theShape,
476                                        CORBA::Long theShapeType,
477                                        CORBA::Boolean isSorted);
478   CORBA::Long NumberOfFaces (GEOM::GEOM_Object_ptr theShape);
479   CORBA::Long NumberOfEdges (GEOM::GEOM_Object_ptr theShape);
480   GEOM::GEOM_Object_ptr ChangeOrientation (GEOM::GEOM_Object_ptr theShape);
481
482   GEOM::GEOM_List_ptr GetShapesOnShape (GEOM::GEOM_Object_ptr theCheckShape,
483                                         GEOM::GEOM_Object_ptr theShape,
484                                         CORBA::Short theShapeType,
485                                         GEOM::shape_state theState);
486   GEOM::GEOM_Object_ptr GetShapesOnShapeAsCompound
487                                        (GEOM::GEOM_Object_ptr theCheckShape,
488                                         GEOM::GEOM_Object_ptr theShape,
489                                         CORBA::Short theShapeType,
490                                         GEOM::shape_state theState);
491
492
493   //-----------------------------------------------------------//
494   // BlocksOperations                                          //
495   //-----------------------------------------------------------//
496   GEOM::GEOM_Object_ptr MakeQuad4Vertices (GEOM::GEOM_Object_ptr thePnt1,
497                                            GEOM::GEOM_Object_ptr thePnt2,
498                                            GEOM::GEOM_Object_ptr thePnt3,
499                                            GEOM::GEOM_Object_ptr thePnt4);
500   GEOM::GEOM_Object_ptr MakeQuad (GEOM::GEOM_Object_ptr theEdge1,
501                                   GEOM::GEOM_Object_ptr theEdge2,
502                                   GEOM::GEOM_Object_ptr theEdge3,
503                                   GEOM::GEOM_Object_ptr theEdge4);
504   GEOM::GEOM_Object_ptr MakeQuad2Edges (GEOM::GEOM_Object_ptr theEdge1,
505                                         GEOM::GEOM_Object_ptr theEdge2);
506   GEOM::GEOM_Object_ptr MakeHexa (GEOM::GEOM_Object_ptr theFace1,
507                                   GEOM::GEOM_Object_ptr theFace2,
508                                   GEOM::GEOM_Object_ptr theFace3,
509                                   GEOM::GEOM_Object_ptr theFace4,
510                                   GEOM::GEOM_Object_ptr theFace5,
511                                   GEOM::GEOM_Object_ptr theFace6);
512   GEOM::GEOM_Object_ptr MakeHexa2Faces (GEOM::GEOM_Object_ptr theFace1,
513                                         GEOM::GEOM_Object_ptr theFace2);
514   GEOM::GEOM_Object_ptr GetPoint (GEOM::GEOM_Object_ptr theShape,
515                                   CORBA::Double   theX,
516                                   CORBA::Double   theY,
517                                   CORBA::Double   theZ,
518                                   CORBA::Double   theEpsilon);
519   GEOM::GEOM_Object_ptr GetEdge (GEOM::GEOM_Object_ptr theShape,
520                                  GEOM::GEOM_Object_ptr thePoint1,
521                                  GEOM::GEOM_Object_ptr thePoint2);
522   GEOM::GEOM_Object_ptr GetEdgeNearPoint (GEOM::GEOM_Object_ptr theShape,
523                                           GEOM::GEOM_Object_ptr thePoint);
524   GEOM::GEOM_Object_ptr GetFaceByPoints (GEOM::GEOM_Object_ptr theShape,
525                                          GEOM::GEOM_Object_ptr thePoint1,
526                                          GEOM::GEOM_Object_ptr thePoint2,
527                                          GEOM::GEOM_Object_ptr thePoint3,
528                                          GEOM::GEOM_Object_ptr thePoint4);
529   GEOM::GEOM_Object_ptr GetFaceByEdges (GEOM::GEOM_Object_ptr theShape,
530                                         GEOM::GEOM_Object_ptr theEdge1,
531                                         GEOM::GEOM_Object_ptr theEdge2);
532   GEOM::GEOM_Object_ptr GetOppositeFace (GEOM::GEOM_Object_ptr theBlock,
533                                          GEOM::GEOM_Object_ptr theFace);
534   GEOM::GEOM_Object_ptr GetFaceNearPoint (GEOM::GEOM_Object_ptr theShape,
535                                           GEOM::GEOM_Object_ptr thePoint);
536   GEOM::GEOM_Object_ptr GetFaceByNormale (GEOM::GEOM_Object_ptr theBlock,
537                                           GEOM::GEOM_Object_ptr theVector);
538   CORBA::Boolean IsCompoundOfBlocks (GEOM::GEOM_Object_ptr theCompound,
539                                      CORBA::Long     theMinNbFaces,
540                                      CORBA::Long     theMaxNbFaces,
541                                      CORBA::Long&          theNbBlocks);
542   CORBA::Boolean CheckCompoundOfBlocks (GEOM::GEOM_Object_ptr theCompound,
543                                         GEOM::GEOM_IBlocksOperations::BCErrors_out theErrors);
544   char* PrintBCErrors (GEOM::GEOM_Object_ptr theCompound,
545                        const GEOM::GEOM_IBlocksOperations::BCErrors& theErrors);
546   GEOM::GEOM_List_ptr ExplodeCompoundOfBlocks (GEOM::GEOM_Object_ptr theCompound,
547                                                    CORBA::Long     theMinNbFaces,
548                                                    CORBA::Long     theMaxNbFaces);
549   GEOM::GEOM_Object_ptr GetBlockNearPoint (GEOM::GEOM_Object_ptr theCompound,
550                                            GEOM::GEOM_Object_ptr thePoint);
551   GEOM::GEOM_Object_ptr GetBlockByParts (GEOM::GEOM_Object_ptr theCompound,
552                                          GEOM::GEOM_List_ptr theParts);
553   GEOM::GEOM_List_ptr GetBlocksByParts (GEOM::GEOM_Object_ptr theCompound,
554                                             GEOM::GEOM_List_ptr theParts);
555   GEOM::GEOM_Object_ptr MakeMultiTransformation1D (GEOM::GEOM_Object_ptr theBlock,
556                                                    CORBA::Long     theDirFace1,
557                                                    CORBA::Long     theDirFace2,
558                                                    CORBA::Long     theNbTimes);
559   GEOM::GEOM_Object_ptr MakeMultiTransformation2D (GEOM::GEOM_Object_ptr theBlock,
560                                                    CORBA::Long     theDirFace1U,
561                                                    CORBA::Long     theDirFace2U,
562                                                    CORBA::Long     theNbTimesU,
563                                                    CORBA::Long     theDirFace1V,
564                                                    CORBA::Long     theDirFace2V,
565                                                    CORBA::Long     theNbTimesV);
566
567   //-----------------------------------------------------------//
568   // CurvesOperations                                          //
569   //-----------------------------------------------------------//
570   GEOM::GEOM_Object_ptr MakeCirclePntVecR (GEOM::GEOM_Object_ptr theCenter,
571                                            GEOM::GEOM_Object_ptr theVector,
572                                            CORBA::Double theR);
573   GEOM::GEOM_Object_ptr MakeCircleThreePnt (GEOM::GEOM_Object_ptr thePnt1,
574                                             GEOM::GEOM_Object_ptr thePnt2,
575                                             GEOM::GEOM_Object_ptr thePnt3);
576   GEOM::GEOM_Object_ptr MakeCircleCenter2Pnt (GEOM::GEOM_Object_ptr thePnt1,
577                                               GEOM::GEOM_Object_ptr thePnt2,
578                                               GEOM::GEOM_Object_ptr thePnt3);
579   GEOM::GEOM_Object_ptr MakeEllipse (GEOM::GEOM_Object_ptr theCenter,
580                                      GEOM::GEOM_Object_ptr theVector,
581                                      CORBA::Double theRMajor, CORBA::Double theRMinor);
582   GEOM::GEOM_Object_ptr MakeEllipseVec (GEOM::GEOM_Object_ptr theCenter,
583                                         GEOM::GEOM_Object_ptr theVector,
584                                         CORBA::Double theRMajor, CORBA::Double theRMinor,
585                                         GEOM::GEOM_Object_ptr theVectorMajor);
586   GEOM::GEOM_Object_ptr MakeArc (GEOM::GEOM_Object_ptr thePnt1,
587                                  GEOM::GEOM_Object_ptr thePnt2,
588                                  GEOM::GEOM_Object_ptr thePnt3);
589   GEOM::GEOM_Object_ptr MakeArcCenter (GEOM::GEOM_Object_ptr theCenter,
590                                        GEOM::GEOM_Object_ptr thePnt1,
591                                        GEOM::GEOM_Object_ptr thePnt2,
592                                        CORBA::Boolean theSense);
593   GEOM::GEOM_Object_ptr MakeArcOfEllipse (GEOM::GEOM_Object_ptr thePnt1,
594                                           GEOM::GEOM_Object_ptr thePnt2,
595                                           GEOM::GEOM_Object_ptr thePnt3);
596   GEOM::GEOM_Object_ptr MakePolyline (GEOM::GEOM_List_ptr thePoints);
597   GEOM::GEOM_Object_ptr MakeSplineBezier (GEOM::GEOM_List_ptr thePoints);
598   GEOM::GEOM_Object_ptr MakeSplineInterpolation (GEOM::GEOM_List_ptr thePoints,
599                                                  CORBA::Boolean      theIsClosed);
600   GEOM::GEOM_Object_ptr MakeSketcher (const char* theCommand, 
601                                                 GEOM::GEOM_List_ptr theWorkingPlane);
602   GEOM::GEOM_Object_ptr Make3DSketcher (GEOM::GEOM_List_ptr theCoordinates);
603
604   //-----------------------------------------------------------//
605   // LocalOperations                                           //
606   //-----------------------------------------------------------//
607   GEOM::GEOM_Object_ptr MakeFilletAll (GEOM::GEOM_Object_ptr theShape,
608                                        CORBA::Double theR);
609   GEOM::GEOM_Object_ptr MakeFilletEdges (GEOM::GEOM_Object_ptr theShape, CORBA::Double theR,
610                                          GEOM::GEOM_List_ptr theEdges);
611   GEOM::GEOM_Object_ptr MakeFilletEdgesR1R2 (GEOM::GEOM_Object_ptr theShape, CORBA::Double theR1,
612                                              CORBA::Double theR2, GEOM::GEOM_List_ptr theEdges);
613   GEOM::GEOM_Object_ptr MakeFilletFaces (GEOM::GEOM_Object_ptr theShape, CORBA::Double theR,
614                                          GEOM::GEOM_List_ptr theFaces);
615   GEOM::GEOM_Object_ptr MakeFilletFacesR1R2 (GEOM::GEOM_Object_ptr theShape, CORBA::Double theR1,
616                                              CORBA::Double theR2, GEOM::GEOM_List_ptr theFaces);
617   GEOM::GEOM_Object_ptr MakeFillet2D (GEOM::GEOM_Object_ptr theShape, CORBA::Double theR,
618                                       GEOM::GEOM_List_ptr theVertexes);
619   GEOM::GEOM_Object_ptr MakeFillet1D (GEOM::GEOM_Object_ptr theShape, CORBA::Double theR,
620                                       GEOM::GEOM_List_ptr theVertexes);
621   GEOM::GEOM_Object_ptr MakeChamferAll (GEOM::GEOM_Object_ptr theShape, CORBA::Double theD);
622   GEOM::GEOM_Object_ptr MakeChamferEdge (GEOM::GEOM_Object_ptr theShape,
623                                          CORBA::Double theD1, CORBA::Double theD2,
624                                          CORBA::Long theFace1, CORBA::Long theFace2);
625   GEOM::GEOM_Object_ptr MakeChamferEdgeAD (GEOM::GEOM_Object_ptr theShape,
626                                            CORBA::Double theD, CORBA::Double theAngle,
627                                            CORBA::Long theFace1, CORBA::Long theFace2);
628   GEOM::GEOM_Object_ptr MakeChamferFaces (GEOM::GEOM_Object_ptr theShape,
629                                           CORBA::Double theD1, CORBA::Double theD2,
630                                           GEOM::GEOM_List_ptr theFaces);
631   GEOM::GEOM_Object_ptr MakeChamferFacesAD (GEOM::GEOM_Object_ptr theShape,
632                                             CORBA::Double theD, CORBA::Double theAngle,
633                                             GEOM::GEOM_List_ptr theFaces);
634   GEOM::GEOM_Object_ptr MakeChamferEdges (GEOM::GEOM_Object_ptr theShape,
635                                           CORBA::Double theD1, CORBA::Double theD2,
636                                           GEOM::GEOM_List_ptr theEdges);
637   GEOM::GEOM_Object_ptr MakeChamferEdgesAD (GEOM::GEOM_Object_ptr theShape,
638                                             CORBA::Double theD, CORBA::Double theAngle,
639                                             GEOM::GEOM_List_ptr theEdges);
640   GEOM::GEOM_Object_ptr MakeArchimede (GEOM::GEOM_Object_ptr theShape,
641                                        CORBA::Double theWeight,
642                                        CORBA::Double theWaterDensity,
643                                        CORBA::Double theMeshingDeflection);
644   CORBA::Long GetSubShapeIndex (GEOM::GEOM_Object_ptr theShape,
645                                 GEOM::GEOM_Object_ptr theSubShape);
646
647   //-----------------------------------------------------------//
648   // GroupOperations                                           //
649   //-----------------------------------------------------------//
650   GEOM::GEOM_Object_ptr CreateGroup (GEOM::GEOM_Object_ptr theMainShape, 
651                                      CORBA::Long theShapeType);
652   void AddObject (GEOM::GEOM_Object_ptr theGroup, 
653                   CORBA::Long theSubShapeId);
654   void RemoveObject (GEOM::GEOM_Object_ptr theGroup, 
655                      CORBA::Long theSubShapeId);
656   CORBA::Long GetType (GEOM::GEOM_Object_ptr theGroup);
657   GEOM::GEOM_Object_ptr GetMainShape (GEOM::GEOM_Object_ptr theGroup);
658   GEOM::GEOM_List_ptr GetObjects (GEOM::GEOM_Object_ptr theGroup);
659   
660 private:
661   SALOME_NamingService *  name_service; 
662   GEOM::GEOM_Gen_var      myGeomEngine;
663   CORBA::Long             myStudyID;
664   CORBA::Long             myLastStudyID; // mkr : PAL10770
665   PortableServer::POA_var myPOA;
666   
667   GEOM::GEOM_IBasicOperations_var     myBasicOp;
668   GEOM::GEOM_I3DPrimOperations_var    my3DPrimOp;
669   GEOM::GEOM_IBooleanOperations_var   myBoolOp;
670   GEOM::GEOM_IInsertOperations_var    myInsOp;
671   GEOM::GEOM_ITransformOperations_var myTransfOp;
672   GEOM::GEOM_IShapesOperations_var    myShapesOp;
673   GEOM::GEOM_IBlocksOperations_var    myBlocksOp;
674   GEOM::GEOM_ICurvesOperations_var    myCurvesOp;
675   GEOM::GEOM_ILocalOperations_var     myLocalOp;
676   GEOM::GEOM_IGroupOperations_var     myGroupOp;
677
678 };
679
680 #endif