Salome HOME
NRI : Add documentation.
[modules/geom.git] / src / GEOM / GEOM_Gen_i.hh
1 // File :      GEOM_GEN_i.h file
2 // Created :   April 2002
3 // Author :    Lucien PIGNOLONI
4 // Project :   SALOME
5 // Copyright : OPEN CASCADE
6 // $Header$ 
7
8
9 #ifndef __GEOM_GEN_I_H__
10 #define __GEOM_GEN_I_H__
11
12 // standard C++ headers
13 #include <TDocStd_Document.hxx>
14 #include "GEOMDS_DataMapOfIntegerTransient.hxx"
15 #include "GEOMDS_Application.hxx"
16 #include <TopTools_MapOfShape.hxx>
17 #include <TopTools_SequenceOfShape.hxx>
18 #include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
19 #include <TopAbs_ShapeEnum.hxx>
20 #include <TopoDS_Wire.hxx>
21 #include <TopoDS_Face.hxx>
22
23 // IDL headers
24 #include <SALOMEconfig.h>
25 #include CORBA_SERVER_HEADER(GEOM_Gen)
26 #include CORBA_SERVER_HEADER(GEOM_Shape)
27 #include CORBA_SERVER_HEADER(SALOMEDS)
28
29 #include "SALOME_Component_i.hxx"
30 #include "GEOM_Shape_i.hh"
31
32 #include "SALOME_NamingService.hxx"
33 #include <iostream.h>
34
35 #include <Standard_ErrorHandler.hxx> // CAREFUL ! position of this file is critic : see Lucien PIGNOLONI / OCC
36
37
38 //=====================================================================
39 // GEOM_Gen_i : class definition
40 //=====================================================================
41 class GEOM_Gen_i: public POA_GEOM::GEOM_Gen,
42   public Engines_Component_i
43 {
44  private:
45
46   SALOME_NamingService * name_service;
47   char * _name;
48   Handle(GEOMDS_Application)        myOCAFApp;          /* geom/OCAF Application             */
49   Handle(TDocStd_Document)          myCurrentOCAFDoc;   /* Current geom/OCAF Document        */
50   GEOMDS_DataMapOfIntegerTransient  myStudyIDToDoc;     /* Map to bind a Study to a Document */
51
52   int myStudyID;
53
54   GEOM::GEOM_Shape_ptr CreateObject(TopoDS_Shape& tds) ;
55
56   GEOM::GEOM_Shape_ptr CreateSubObject(const TopoDS_Shape& SubShape,
57                                        const GEOM::GEOM_Shape_ptr MainShape,
58                                        const GEOM::GEOM_Shape::ListOfSubShapeID& ListOfID);
59   // Create and insert(!) SubShape of MainShape
60
61   GEOM::GEOM_Shape_ptr GEOM_Gen_i::SubShapesOne( GEOM::GEOM_Shape_ptr shape, 
62                                                 const TopAbs_ShapeEnum ShapeType, 
63                                                 const GEOM::GEOM_Shape::ListOfSubShapeID& ListOfID,
64                                                 const Standard_Boolean sorted=Standard_False)
65     throw (SALOME::SALOME_Exception);
66   // return all listed subshapes as one shape
67   
68   GEOM::GEOM_Gen::ListOfGeomShapes* SubShapesAll(GEOM::GEOM_Shape_ptr shape,
69                                                  const TopAbs_ShapeEnum type,
70                                                  const Standard_Boolean sorted=Standard_False)
71     throw (SALOME::SALOME_Exception);
72   // return all subshapes by type
73
74   TopoDS_Face FindSameFace(const TopoDS_Shape& aShape, 
75                            const TopoDS_Face& F,
76                            double tol3d);
77   TopoDS_Edge FindSameEdge(const TopoDS_Face& newFace, 
78                            TopoDS_Edge& Eold,
79                            double tol3d);
80
81  public:
82   //-----------------------------------------------------------------------//
83   // Constructor / Destructor                                              //
84   //-----------------------------------------------------------------------//
85   // constructor to be called for servant creation. 
86   GEOM_Gen_i();
87   GEOM_Gen_i(CORBA::ORB_ptr orb,
88              PortableServer::POA_ptr poa,
89              PortableServer::ObjectId * contId, 
90              const char *instanceName, 
91              const char *interfaceName);
92
93   // destructor, doing nothing (for now)
94   virtual ~GEOM_Gen_i();
95
96   // generic method to be put in a super class
97   void register_name(char * name);
98
99   //-----------------------------------------------------------------------//
100   // Studies Management                                                    //
101   //-----------------------------------------------------------------------//
102   void GetCurrentStudy (CORBA::Long StudyID);
103
104   CORBA::Short NbLabels();
105
106   // inherited methods from SALOMEDS::Driver
107   SALOMEDS::TMPFile* Save(SALOMEDS::SComponent_ptr theComponent,
108                           const char* theURL,
109                           bool isMultiFile);
110
111   CORBA::Boolean Load(SALOMEDS::SComponent_ptr theComponent,
112                       const SALOMEDS::TMPFile& theStream,
113                       const char* theURL,
114                       bool isMultiFile);
115   void Close(SALOMEDS::SComponent_ptr theComponent);
116   char* ComponentDataType();
117
118
119   char* IORToLocalPersistentID(SALOMEDS::SObject_ptr theSObject,
120                                const char* IORString,
121                                CORBA::Boolean isMultiFile);
122   char* LocalPersistentIDToIOR(SALOMEDS::SObject_ptr theSObject,
123                                const char* aLocalPersistentID,
124                                CORBA::Boolean isMultiFile);
125
126   bool CanPublishInStudy(CORBA::Object_ptr theIOR);
127   SALOMEDS::SObject_ptr PublishInStudy(SALOMEDS::Study_ptr theStudy,
128                                        SALOMEDS::SObject_ptr theSObject,
129                                        CORBA::Object_ptr theObject,
130                                        const char* theName) throw (SALOME::SALOME_Exception) ;
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   // Shapes Management                                                     //
141   //-----------------------------------------------------------------------//
142   const char* InsertInLabel(TopoDS_Shape S,
143                             const char *nameIor,
144                             Handle(TDocStd_Document) OCAFDoc) ;
145
146   const char* InsertInLabelDependentShape(TopoDS_Shape S,
147                                           const char *nameIor,
148                                           GEOM::GEOM_Shape_ptr mainshape_ptr,
149                                           Handle(TDocStd_Document) OCAFDoc) ;
150   
151   void InsertInLabelOneArgument(TopoDS_Shape main_topo,
152                                 GEOM::GEOM_Shape_ptr shape_ptr,
153                                 TopoDS_Shape result_topo,                               
154                                 GEOM::GEOM_Shape_ptr result,    
155                                 Handle(TDocStd_Document) OCAFDoc) ;
156
157   void InsertInLabelMoreArguments(TopoDS_Shape main_topo,
158                                   GEOM::GEOM_Shape_ptr result,
159                                   const GEOM::GEOM_Gen::ListOfIOR& ListShapes,                          
160                                   Handle(TDocStd_Document) OCAFDoc) ;
161
162   // Methods used by SuppressFaces
163   int SuppressFacesGlue( const TopoDS_Shape& S,
164                         const TopTools_MapOfShape& mapFaces,
165                         TopoDS_Shape& aCompoundOfShells ) throw (SALOME::SALOME_Exception) ;
166
167   // various services
168   int GetIndexTopology( const TopoDS_Shape& subshape,
169                        const TopoDS_Shape& mainShape ) ;
170
171   bool GetShapeFromIndex( const TopoDS_Shape& aShape,
172                          const TopAbs_ShapeEnum aType, 
173                          const int index,
174                          TopoDS_Shape& tds) ; 
175
176   GEOM::GEOM_Shape::ListOfSubShapeID* IndexOfFacesOfSubShell( const TopoDS_Shape& S,
177                                                              const TopoDS_Shape subShell )
178     throw (SALOME::SALOME_Exception) ;
179
180   bool ListOfIDIntoMapOfShapes( const TopoDS_Shape& S,
181                                const GEOM::GEOM_Shape::ListOfSubShapeID& L, 
182                                const int subShapeType,
183                                TopTools_MapOfShape& aMap ) ;
184
185   bool ListOfIDIntoSequenceOfShapes( const TopoDS_Shape& S,
186                                     const GEOM::GEOM_Shape::ListOfSubShapeID& L,
187                                     const int subShapeType,
188                                     TopTools_SequenceOfShape& aSequenceOfShapes ) ;
189
190   // Returns a  TopoDS_Shape from a GEOM::GEOM_Shape_ptr
191   TopoDS_Shape GetTopoShape(GEOM::GEOM_Shape_ptr shape_ptr) ;
192
193   // Define a sequence of shapes from 'listShapes' and return its length
194   int SequenceOfShapeFromListOfGeomShape( const GEOM::GEOM_Gen::ListOfGeomShapes& listShapes,
195                                          TopTools_SequenceOfShape& SS ) ;
196
197   // Get a string representing a shape ref IOR
198   const char* GetStringFromIOR(GEOM::GEOM_Shape_var shapeIOR);
199
200   // Return the shape ref represented by a string of IOR
201   GEOM::GEOM_Shape_ptr GetIORFromString(const char* stringIOR);
202
203   GEOM::GEOM_Gen::ListOfIOR* GetReferencedObjects(GEOM::GEOM_Shape_ptr shape);
204   GEOM::GEOM_Gen::ListOfIOR* GetObjects(GEOM::GEOM_Shape_ptr shape);
205
206
207   //-----------------------------------------------------------------------//
208   // Internal structure of shapes                                          //
209   //-----------------------------------------------------------------------//
210   // Explode SubShape
211   GEOM::GEOM_Shape_ptr SubShape(GEOM::GEOM_Shape_ptr shape,
212                                 CORBA::Short ShapeType, 
213                                 const GEOM::GEOM_Shape::ListOfSubShapeID& ListOfID)
214     throw (SALOME::SALOME_Exception) ;
215
216   // Explode SubShape in predictable order
217   GEOM::GEOM_Shape_ptr SubShapeSorted(GEOM::GEOM_Shape_ptr shape,
218                                       CORBA::Short ShapeType, 
219                                       const GEOM::GEOM_Shape::ListOfSubShapeID& ListOfID)
220     throw (SALOME::SALOME_Exception) ;
221   
222   // Explode SubShape
223   GEOM::GEOM_Gen::ListOfGeomShapes*  SubShapeAll(GEOM::GEOM_Shape_ptr shape,
224                                                  CORBA::Short ShapeType)
225     throw (SALOME::SALOME_Exception) ;
226   
227   // Explode SubShape in predictable order for TUI or GUI
228   GEOM::GEOM_Gen::ListOfGeomShapes*  SubShapeAllSorted(GEOM::GEOM_Shape_ptr shape,
229                                                        CORBA::Short ShapeType)
230     throw (SALOME::SALOME_Exception) ;
231
232   // Suppress faces in a shape 
233   GEOM::GEOM_Gen::ListOfGeomShapes* SuppressFaces( GEOM::GEOM_Shape_ptr shape,
234                                                   const GEOM::GEOM_Shape::ListOfSubShapeID& ListOfID )
235     throw (SALOME::SALOME_Exception) ;
236
237   // Suppress one or more holes in a face or shell independant topology
238   GEOM::GEOM_Shape_ptr SuppressHolesInFaceOrShell( GEOM::GEOM_Shape_ptr shapeFaceShell,
239                                                   const GEOM::GEOM_Shape::ListOfSubShapeID& ListOfIdWires)
240     throw (SALOME::SALOME_Exception) ;
241
242   // Suppress a single hole in a topology (face) shell or solid with/without hole traversing
243   GEOM::GEOM_Shape_ptr SuppressHole( GEOM::GEOM_Shape_ptr shape,
244                                     const GEOM::GEOM_Shape::ListOfSubShapeID& ListIdFace,
245                                     const GEOM::GEOM_Shape::ListOfSubShapeID& ListIdWire,
246                                     const GEOM::GEOM_Shape::ListOfSubShapeID& ListIdEndFace )
247     throw (SALOME::SALOME_Exception) ;
248
249   bool RebuildFaceRemovingHoles( const TopoDS_Face& aFace,
250                                 const TopTools_MapOfShape& mapHoles,
251                                 TopoDS_Shape& resultFace ) ;
252
253   void SuppressHoleSubRoutine( const TopoDS_Shape& mainShape,
254                                const TopoDS_Face& aFace,
255                                const TopTools_SequenceOfShape& SSedgesOfWire,
256                                const TopTools_IndexedDataMapOfShapeListOfShape& aMapEdgesFaces,
257                                const TopTools_MapOfShape& MSfaces,
258                                TopTools_MapOfShape& MSfacesSuppress,
259                                const Standard_Boolean withEndFace,
260                                const TopoDS_Face& endFace,
261                                TopTools_MapOfShape& MSwireEndEdges )
262     throw (SALOME::SALOME_Exception ) ;  
263   
264   bool BuildShapeHoleNotTraversing( const TopoDS_Shape& aShape,
265                                    const TopoDS_Face& aFace,
266                                    const TopoDS_Wire& aWire,
267                                    const TopTools_MapOfShape& MFSuppress,
268                                    TopoDS_Shape& resultTds )
269     throw (SALOME::SALOME_Exception) ;
270
271   bool BuildShapeHoleTraversing( const TopoDS_Shape& aShape,
272                                 const TopoDS_Face& aFace,
273                                 const TopoDS_Wire& aWire,
274                                 const TopTools_MapOfShape& MFSuppress,
275                                  const TopoDS_Face& endFace,
276                                 const TopoDS_Wire& endWire,
277                                 TopoDS_Shape& resultTds )
278     throw (SALOME::SALOME_Exception) ;
279
280   bool FindCompareWireHoleOnFace( const TopoDS_Face& F,
281                                  const TopTools_MapOfShape& MSwireEdges,
282                                  TopoDS_Wire& aFoundWire ) ;
283
284   bool IsShapeInSequence( const TopTools_SequenceOfShape& SS, const TopoDS_Shape& aShape ) ;
285
286   void FreeEdgesFromMapOfFace(const TopTools_MapOfShape& MSfaces, TopTools_MapOfShape& MS ) ;
287
288   void MapRemoveSequence( const TopTools_MapOfShape& MS,
289                          const TopTools_SequenceOfShape& SSRemove,
290                          TopTools_SequenceOfShape& ST) ;
291
292   bool BuildShellWithFaceCompound( const TopoDS_Compound Comp,
293                                   TopoDS_Shell& resultShell ) ;
294
295   //-----------------------------------------------------------------------//
296   // Basic structures                                                      //
297   //-----------------------------------------------------------------------//
298   GEOM::PointStruct MakePointStruct(CORBA::Double x,
299                                           CORBA::Double y,
300                                           CORBA::Double z) ;
301   GEOM::DirStruct   MakeDirection(const GEOM::PointStruct& p) ;
302
303   GEOM::AxisStruct  MakeAxisStruct(CORBA::Double x,
304                                          CORBA::Double y,
305                                          CORBA::Double z,
306                                          CORBA::Double vx,
307                                          CORBA::Double vy,
308                                          CORBA::Double vz) ;
309
310   //----------------------------------------------------------------------//
311   // Boolean Operations                                                   //
312   //----------------------------------------------------------------------//
313   GEOM::GEOM_Shape_ptr MakeBoolean(GEOM::GEOM_Shape_ptr shape1,
314                                    GEOM::GEOM_Shape_ptr shape2,
315                                    CORBA::Long operation)
316     throw (SALOME::SALOME_Exception) ;
317   GEOM::GEOM_Shape_ptr MakeFuse(GEOM::GEOM_Shape_ptr shape1,
318                                 GEOM::GEOM_Shape_ptr shape2)
319     throw (SALOME::SALOME_Exception) ;
320
321   //----------------------------------------------------------------------//
322   // Advanced Operations                                                  //
323   //----------------------------------------------------------------------//
324   GEOM::GEOM_Shape_ptr Partition(const GEOM::GEOM_Gen::ListOfIOR& ListShapes, 
325                                  const GEOM::GEOM_Gen::ListOfIOR& ListTools,
326                                  const GEOM::GEOM_Gen::ListOfIOR& ListKeepInside,
327                                  const GEOM::GEOM_Gen::ListOfIOR& ListRemoveInside,
328                                  const CORBA::Short               Limit)
329     throw (SALOME::SALOME_Exception) ;
330
331   // Filling a surface with section curves
332   GEOM::GEOM_Shape_ptr MakeFilling(GEOM::GEOM_Shape_ptr shape,
333                                    CORBA::Short mindeg,
334                                    CORBA::Short maxdeg,
335                                    CORBA::Double tol3d,
336                                    CORBA::Double tol2d,
337                                    CORBA::Short nbiter)
338     throw (SALOME::SALOME_Exception) ;
339   // Sewing of shapes
340   GEOM::GEOM_Shape_ptr MakeSewing(const GEOM::GEOM_Gen::ListOfIOR& ListShapes,
341                                   CORBA::Double precision)
342     throw (SALOME::SALOME_Exception) ;
343
344   GEOM::GEOM_Shape_ptr MakeSewingShape( GEOM::GEOM_Shape_ptr aShape,
345                                        CORBA::Double precision )
346     throw (SALOME::SALOME_Exception);
347
348   GEOM::GEOM_Shape_ptr MakeGlueFaces(GEOM::GEOM_Shape_ptr myShape,
349                                      double tol3d)
350     throw (SALOME::SALOME_Exception);
351
352   // Change the orientation of a (new) shape
353   GEOM::GEOM_Shape_ptr OrientationChange(GEOM::GEOM_Shape_ptr shape)
354     throw (SALOME::SALOME_Exception) ;
355
356   GEOM::GEOM_Shape_ptr MakePlacedBox(CORBA::Double x1,  CORBA::Double y1,  CORBA::Double z1,
357                                      CORBA::Double delta1, CORBA::Double delta2, CORBA::Double delta3)
358     throw (SALOME::SALOME_Exception) ;
359
360   GEOM::GEOM_Shape_ptr MakePanel(GEOM::GEOM_Shape_ptr shape,
361                                  CORBA::Short directiontype,
362                                  CORBA::Double delta)
363     throw (SALOME::SALOME_Exception) ;
364
365   //---------------------------------------------------------------------//
366   // Transformations Operations                                          //
367   //---------------------------------------------------------------------//
368   // Copy 
369   GEOM::GEOM_Shape_ptr MakeCopy( GEOM::GEOM_Shape_ptr shape)
370     throw (SALOME::SALOME_Exception) ;
371
372   // Translation
373   GEOM::GEOM_Shape_ptr MakeTranslation( GEOM::GEOM_Shape_ptr shape,
374                                        CORBA::Double x,
375                                        CORBA::Double y,
376                                        CORBA::Double z)
377     throw (SALOME::SALOME_Exception) ;
378   // Rotation
379   GEOM::GEOM_Shape_ptr MakeRotation( GEOM::GEOM_Shape_ptr shape,
380                                     const GEOM::AxisStruct& axis,
381                                     CORBA::Double angle)
382     throw (SALOME::SALOME_Exception) ;
383   // Create a shape using a scale factor
384   GEOM::GEOM_Shape_ptr MakeScaleTransform(GEOM::GEOM_Shape_ptr shape,
385                                           const GEOM::PointStruct& theCenterOfScale,
386                                           CORBA::Double factor)
387     throw (SALOME::SALOME_Exception) ;
388   // Mirror of a shape by a  plane
389   GEOM::GEOM_Shape_ptr MakeMirrorByPlane(GEOM::GEOM_Shape_ptr shape,
390                                          GEOM::GEOM_Shape_ptr shapePlane)
391     throw (SALOME::SALOME_Exception) ;  
392
393   // Shape by revolution of another around an axis
394   GEOM::GEOM_Shape_ptr MakeRevolution(GEOM::GEOM_Shape_ptr shape,
395                                       const GEOM::AxisStruct& axis,
396                                       CORBA::Double angle)
397     throw (SALOME::SALOME_Exception) ;
398
399   // Create a prism with a base shape along a vector P1 to P2 
400   GEOM::GEOM_Shape_ptr MakePrism(GEOM::GEOM_Shape_ptr baseShape,
401                                  const GEOM::PointStruct& P1,
402                                  const GEOM::PointStruct& P2)
403     throw (SALOME::SALOME_Exception) ;
404   // Create a shape by sweeping a baseShape along a pathShape
405   GEOM::GEOM_Shape_ptr MakePipe(GEOM::GEOM_Shape_ptr pathShape,
406                                 GEOM::GEOM_Shape_ptr baseShape)
407     throw (SALOME::SALOME_Exception) ;
408
409   //---------------------------------------------------------------------//
410   // Patterns Operations                                                 //
411   //---------------------------------------------------------------------//
412
413   // Multi Translation 1D
414   GEOM::GEOM_Shape_ptr MakeMultiTranslation1D( GEOM::GEOM_Shape_ptr shape,
415                                               const GEOM::DirStruct& dir,
416                                               CORBA::Double step,
417                                               CORBA::Short nbtimes)
418     throw (SALOME::SALOME_Exception) ;
419
420   // Multi Translation 2D
421   GEOM::GEOM_Shape_ptr MakeMultiTranslation2D( GEOM::GEOM_Shape_ptr shape,
422                                               const GEOM::DirStruct& dir1,
423                                               CORBA::Double step1,
424                                               CORBA::Short nbtimes1,
425                                               const GEOM::DirStruct& dir2,
426                                               CORBA::Double step2,
427                                               CORBA::Short nbtimes2)
428     throw (SALOME::SALOME_Exception) ;
429
430   // Multi Rotation 1D
431   GEOM::GEOM_Shape_ptr MakeMultiRotation1D( GEOM::GEOM_Shape_ptr shape,
432                                            const GEOM::DirStruct& dir,
433                                            const GEOM::PointStruct& loc,
434                                            CORBA::Short nbtimes)
435     throw (SALOME::SALOME_Exception) ;
436
437   // Multi Rotation 2D
438   GEOM::GEOM_Shape_ptr MakeMultiRotation2D( GEOM::GEOM_Shape_ptr shape,
439                                            const GEOM::DirStruct& dir,
440                                            const GEOM::PointStruct& loc,
441                                            CORBA::Double ang,
442                                            CORBA::Short nbtimes1,
443                                            CORBA::Double step,
444                                            CORBA::Short nbtimes2)
445     throw (SALOME::SALOME_Exception) ;
446
447   //--------------------------------------------------------------------//
448   // Primitives Construction                                            //
449   //--------------------------------------------------------------------//
450   GEOM::GEOM_Shape_ptr MakeBox(CORBA::Double x1,
451                                CORBA::Double y1,
452                                CORBA::Double z1,
453                                CORBA::Double x2,
454                                CORBA::Double y2,
455                                CORBA::Double z2)
456     throw (SALOME::SALOME_Exception) ;
457   GEOM::GEOM_Shape_ptr MakeSphere(CORBA::Double x1,
458                                   CORBA::Double y1,
459                                   CORBA::Double z1,
460                                   CORBA::Double radius)
461     throw (SALOME::SALOME_Exception) ;
462   GEOM::GEOM_Shape_ptr MakeCylinder(const  GEOM::PointStruct& pstruct,
463                                     const GEOM::DirStruct& dstruct,
464                                     CORBA::Double radius,
465                                     CORBA::Double height)
466     throw (SALOME::SALOME_Exception) ;
467   GEOM::GEOM_Shape_ptr MakeTorus(const GEOM::PointStruct& pstruct,
468                                  const GEOM::DirStruct& dstruct,
469                                  CORBA::Double major_radius,
470                                  CORBA::Double minor_radius)
471     throw (SALOME::SALOME_Exception) ;
472   GEOM::GEOM_Shape_ptr MakeCone(const GEOM::PointStruct& pstruct,
473                                 const GEOM::DirStruct& dstruct,
474                                 CORBA::Double radius1,
475                                 CORBA::Double radius2,
476                                 CORBA::Double height)
477     throw (SALOME::SALOME_Exception) ;
478
479   //-------------------------------------------------------------------//
480   // Import/Export                                                     //
481   //-------------------------------------------------------------------//
482   GEOM::GEOM_Shape_ptr ImportIGES(const char* filename) throw (SALOME::SALOME_Exception) ;
483   GEOM::GEOM_Shape_ptr ImportBREP(const char* filename) throw (SALOME::SALOME_Exception) ;
484   GEOM::GEOM_Shape_ptr ImportSTEP(const char* filename) throw (SALOME::SALOME_Exception) ;
485
486   void ExportIGES(const char* filename,GEOM::GEOM_Shape_ptr theShape) throw (SALOME::SALOME_Exception) ;
487   void ExportBREP(const char* filename,GEOM::GEOM_Shape_ptr theShape) throw (SALOME::SALOME_Exception) ;
488   void ExportSTEP(const char* filename,GEOM::GEOM_Shape_ptr theShape) throw (SALOME::SALOME_Exception) ;
489   //-------------------------------------------------------------------//
490   // Fillet and Chamfer construction                                   //
491   //-------------------------------------------------------------------//
492   GEOM::GEOM_Shape_ptr MakeFillet (GEOM::GEOM_Shape_ptr shape,
493                                    CORBA::Double radius,
494                              CORBA::Short ShapeType,
495                                    const GEOM::GEOM_Shape::ListOfSubShapeID& ListOfID)
496     throw (SALOME::SALOME_Exception) ;
497
498   GEOM::GEOM_Shape_ptr MakeChamfer(GEOM::GEOM_Shape_ptr shape,
499                                    CORBA::Double d1,
500                                    CORBA::Double d2,
501                                    CORBA::Short ShapeType,
502                                    const GEOM::GEOM_Shape::ListOfSubShapeID& ListOfID)
503     throw (SALOME::SALOME_Exception) ;
504
505   //-------------------------------------------------------------------//
506   // Mesures Construction                                              //
507   //-------------------------------------------------------------------//
508   GEOM::GEOM_Shape_ptr MakeCDG(GEOM::GEOM_Shape_ptr shape)
509     throw (SALOME::SALOME_Exception) ;
510
511   //-------------------------------------------------------------------//
512   // Check Shape                                                       //
513   //-------------------------------------------------------------------//
514   CORBA::Boolean CheckShape(GEOM::GEOM_Shape_ptr shape)
515     throw (SALOME::SALOME_Exception) ;
516
517   //-------------------------------------------------------------------//
518   // Primitives Construction                                           //
519   //-------------------------------------------------------------------//
520   GEOM::GEOM_Shape_ptr MakeVertex(CORBA::Double x,
521                                   CORBA::Double y,
522                                   CORBA::Double z)
523     throw (SALOME::SALOME_Exception) ;
524   GEOM::GEOM_Shape_ptr MakeVector(const GEOM::PointStruct& pstruct1,
525                                   const GEOM::PointStruct& pstruct2)
526     throw (SALOME::SALOME_Exception) ;
527   GEOM::GEOM_Shape_ptr MakeLine  (const GEOM::PointStruct& pstruct,
528                                   const GEOM::DirStruct& dstruc)
529     throw (SALOME::SALOME_Exception) ;
530   GEOM::GEOM_Shape_ptr MakePlane (const GEOM::PointStruct& pstruct,
531                                   const GEOM::DirStruct& dstruc,
532                                   CORBA::Double trimsize)
533     throw (SALOME::SALOME_Exception) ;
534   GEOM::GEOM_Shape_ptr MakeCircle(const  GEOM::PointStruct& pstruct,
535                                   const GEOM::DirStruct& dstruct,
536                                   CORBA::Double radius)
537     throw (SALOME::SALOME_Exception) ;
538   GEOM::GEOM_Shape_ptr MakeArc   (const  GEOM::PointStruct& pInit,
539                                   const  GEOM::PointStruct& pCircle,
540                                   const  GEOM::PointStruct& pEnd)
541     throw (SALOME::SALOME_Exception) ;
542
543   GEOM::GEOM_Shape_ptr MakeCompound (const GEOM::GEOM_Gen::ListOfIOR& ListShapes)
544     throw (SALOME::SALOME_Exception) ;
545   GEOM::GEOM_Shape_ptr MakeWire     (const GEOM::GEOM_Gen::ListOfIOR& ListShapes)
546     throw (SALOME::SALOME_Exception) ;
547   GEOM::GEOM_Shape_ptr MakeEdge     (const GEOM::PointStruct& pstruct1,
548                                      const GEOM::PointStruct& pstruct2)
549     throw (SALOME::SALOME_Exception) ;
550   GEOM::GEOM_Shape_ptr MakeFace     (GEOM::GEOM_Shape_ptr wire, CORBA::Boolean wantplanarface)
551     throw (SALOME::SALOME_Exception) ;
552
553
554   //-------------------------------------------------------------------//
555   // Speciic method Archimede                                          //
556   //-------------------------------------------------------------------//
557   GEOM::GEOM_Shape_ptr Archimede(GEOM::GEOM_Shape_ptr aShape,
558                                  CORBA::Double aWeight,
559                                  CORBA::Double aWaterDensity,
560                                  CORBA::Double aMeshingDeflection)
561     throw (SALOME::SALOME_Exception) ;
562
563 };
564
565 #endif