Salome HOME
Join modifications from branch OCC_development_for_3_2_0a2
[modules/smesh.git] / idl / SMESH_Mesh.idl
1 //  Copyright (C) 2003  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
2 //  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
3 //
4 //  This library is free software; you can redistribute it and/or
5 //  modify it under the terms of the GNU Lesser General Public
6 //  License as published by the Free Software Foundation; either
7 //  version 2.1 of the License.
8 //
9 //  This library is distributed in the hope that it will be useful,
10 //  but WITHOUT ANY WARRANTY; without even the implied warranty of
11 //  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
12 //  Lesser General Public License for more details.
13 //
14 //  You should have received a copy of the GNU Lesser General Public
15 //  License along with this library; if not, write to the Free Software
16 //  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
17 //
18 //  See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
19 //
20 //
21 //
22 //  File   : SMESH_Mesh.idl
23 //  Author : Paul RASCLE, EDF
24 //  $Header$
25
26 #ifndef _SMESH_MESH_IDL_
27 #define _SMESH_MESH_IDL_
28
29 #include "SALOME_Exception.idl"
30 #include "SALOME_GenericObj.idl"
31
32 module GEOM
33 {
34   interface GEOM_Object;
35 };
36
37
38 module SALOME_MED
39 {
40   interface MESH;
41   interface FAMILY;
42 };
43
44
45 module SMESH
46 {
47   interface SMESH_Hypothesis;
48   typedef sequence<SMESH_Hypothesis> ListOfHypothesis;
49
50   typedef sequence<double> double_array ;
51   typedef sequence<long> long_array ;
52   typedef sequence<string> string_array ;
53   typedef sequence<long_array> array_of_long_array ;
54
55   enum log_command
56     {
57       ADD_NODE,
58       ADD_EDGE,
59       ADD_TRIANGLE,
60       ADD_QUADRANGLE,
61       ADD_POLYGON,
62       ADD_TETRAHEDRON,
63       ADD_PYRAMID,
64       ADD_PRISM,
65       ADD_HEXAHEDRON,
66       ADD_POLYHEDRON,
67       REMOVE_NODE,
68       REMOVE_ELEMENT,
69       MOVE_NODE,
70       CHANGE_ELEMENT_NODES,
71       CHANGE_POLYHEDRON_NODES,
72       RENUMBER,
73       ADD_QUADEDGE,
74       ADD_QUADTRIANGLE,
75       ADD_QUADQUADRANGLE,
76       ADD_QUADTETRAHEDRON,
77       ADD_QUADPYRAMID,
78       ADD_QUADPENTAHEDRON,
79       ADD_QUADHEXAHEDRON
80     };
81
82   struct log_block
83   {
84     long commandType;
85     long number;
86     double_array coords;
87     long_array indexes;
88   };
89
90   struct PointStruct { double x;
91                        double y;
92                        double z; } ;
93   struct DirStruct   { PointStruct PS ; } ;          // analog to Occ Direction
94
95   struct AxisStruct  { double x;
96                        double y;
97                        double z;
98                        double vx;
99                        double vy;
100                        double vz; } ;
101
102
103   /*!
104    * Enumeration for element type, like in SMDS
105    */
106   enum ElementType
107   {
108     ALL,
109     NODE,
110     EDGE,
111     FACE,
112     VOLUME
113   };
114
115   /*!
116    * Enumeration for hypothesis status (used by AddHypothesis() and RemoveHypothesis() methods)
117    */
118   enum Hypothesis_Status // in the order of severity
119   {
120     HYP_OK,
121     HYP_MISSING,      // algo misses a hypothesis
122     HYP_CONCURENT,    // several applicable hypotheses
123     HYP_BAD_PARAMETER,// hypothesis has a bad parameter value
124     HYP_UNKNOWN_FATAL,//  --- all statuses below should be considered as fatal
125                       //      for Add/RemoveHypothesis operations
126     HYP_INCOMPATIBLE, // hypothesis does not fit algo
127     HYP_NOTCONFORM,   // not conform mesh is produced appling a hypothesis
128     HYP_ALREADY_EXIST,// such hypothesis already exist
129     HYP_BAD_DIM,      // bad dimension
130     HYP_BAD_SUBSHAPE  // shape is neither the main one, nor its subshape, nor a group
131   };
132
133   /*!
134    * Enumeration for DriverMED read status (used by ImportMEDFile() method)
135    */
136   enum DriverMED_ReadStatus // in the order of severity
137   {
138     DRS_OK,
139     DRS_EMPTY,          // a MED file contains no mesh with the given name
140     DRS_WARN_RENUMBER,  // a MED file has overlapped ranges of element numbers,
141                         // so the numbers from the file are ignored
142     DRS_WARN_SKIP_ELEM, // some elements were skipped due to incorrect file data
143     DRS_FAIL            // general failure (exception etc.)
144   };
145
146   /*!
147    * Enumeration for DriverMED (used by Perform() method)
148    */
149   enum MED_VERSION // in the order of severity
150   {
151     MED_V2_1,
152     MED_V2_2
153   };
154
155   typedef sequence<log_block> log_array;
156
157
158   /*!
159    * Auxilary flags for advanced extrusion.
160    * BOUNDARY: create or not boundary for result of extrusion
161    * SEW:      try to use existing nodes or create new nodes in any case
162    */
163   const long EXTRUSION_FLAG_BOUNDARY = 1;
164   const long EXTRUSION_FLAG_SEW = 2;
165   
166   interface SMESH_IDSource
167   {
168     /*!
169      * Returns a sequence of all element IDs
170      */
171     long_array GetIDs();
172   };
173
174   interface SMESH_GroupBase;
175   interface SMESH_Group;
176   interface SMESH_GroupOnGeom;
177   interface SMESH_subMesh;
178   interface SMESH_MeshEditor;
179   interface SMESH_Mesh : SALOME::GenericObj, SMESH_IDSource
180   {
181     ///*!
182     // * Associate a Shape to a Mesh created with NewEmpty
183     // */
184     //boolean SetMesh(in GEOM::GEOM_Object anObject)
185     //  raises (SALOME::SALOME_Exception);
186
187     /*!
188      * Get the subMesh object associated to a subShape. The subMesh object
189      * gives access to nodes and elements IDs.
190      * SubMesh will be used instead of SubShape in a next idl version to
191      * adress a specific subMesh...
192      */
193     SMESH_subMesh GetSubMesh(in GEOM::GEOM_Object aSubObject, in string name)
194       raises (SALOME::SALOME_Exception);
195
196     ///*!
197     // * Create a subMesh without reference to a subShape
198     // */
199     //SMESH_subMesh NewEmpty()
200     //  raises (SALOME::SALOME_Exception);
201
202     /*!
203      * Get geom shape to mesh. A result may be nil
204      */
205     GEOM::GEOM_Object GetShapeToMesh()
206       raises (SALOME::SALOME_Exception);
207
208     /*!
209      * Remove a submesh
210      */
211     void RemoveSubMesh(in SMESH_subMesh aSubMesh)
212       raises (SALOME::SALOME_Exception);
213
214     /*!
215      * Create a group
216      */
217     SMESH_Group CreateGroup( in ElementType elem_type,
218                              in string name )
219       raises (SALOME::SALOME_Exception);
220
221     /*!
222      * Create a group from geometry group
223      */
224     SMESH_GroupOnGeom CreateGroupFromGEOM( in ElementType elem_type,
225                                           in string name,
226                                           in GEOM::GEOM_Object theGeomObject )
227       raises (SALOME::SALOME_Exception);
228
229     /*!
230      * Remove a group
231      */
232     void RemoveGroup(in SMESH_GroupBase aGroup)
233       raises (SALOME::SALOME_Exception);
234
235     /*!
236      *  Remove group with its contents
237      */
238     void RemoveGroupWithContents( in SMESH_GroupBase aGroup )
239       raises (SALOME::SALOME_Exception);
240
241     /*!
242      * Union of two groups
243      *    New group is created. All mesh elements that are
244      *    present in initial groups are added to the new one
245      */
246     SMESH_Group UnionGroups (in SMESH_GroupBase aGroup1,
247                              in SMESH_GroupBase aGroup2,
248                              in string          name )
249       raises (SALOME::SALOME_Exception);
250
251     /*!
252      *  Intersection of two groups
253      *  New group is created. All mesh elements that are
254      *  present in both initial groups are added to the new one.
255      */
256     SMESH_Group IntersectGroups (in SMESH_GroupBase aGroup1,
257                                  in SMESH_GroupBase aGroup2,
258                                  in string          name )
259       raises (SALOME::SALOME_Exception);
260
261     /*!
262      *  Cut of two groups
263      *  New group is created. All mesh elements that are present in
264      *  main group but do not present in tool group are added to the new one
265      */
266     SMESH_Group CutGroups (in SMESH_GroupBase aMainGroup,
267                            in SMESH_GroupBase aToolGroup,
268                            in string          name )
269       raises (SALOME::SALOME_Exception);
270
271     /*!
272      * Add hypothesis to the mesh, under a particular subShape
273      * (or the main shape itself)
274      * The Add method is only used to prepare the build of the mesh and store
275      * the algorithms and associated parameters.
276      * Actual job of mesh the shape is done by MESH_Gen.
277      * @params
278      * - aSubShape : subShape obtained by a shape explode in GEOM
279      *   (or main shape)
280      * - anHyp : hypothesis object
281      * @return
282      * - OK if the hypothesis is compatible with the subShape
283      *   (and all previous hypothesis on the subShape)
284      * - NOK if the hypothesis is not compatible with the subShape
285      *   (or one previous hypothesis on the subShape)
286      * raises exception if hypothesis has not been created
287      */
288     Hypothesis_Status AddHypothesis(in GEOM::GEOM_Object aSubObject,
289                                     in SMESH_Hypothesis anHyp)
290       raises (SALOME::SALOME_Exception);
291 //     boolean AddHypothesis(in SMESH_subMesh aSubMesh, in SMESH_Hypothesis anHyp)
292 //       raises (SALOME::SALOME_Exception);
293
294     /*!
295      * Remove an hypothesis previouly added with AddHypothesis.
296      */
297     Hypothesis_Status RemoveHypothesis(in GEOM::GEOM_Object aSubObject,
298                                        in SMESH_Hypothesis anHyp)
299       raises (SALOME::SALOME_Exception);
300 //     boolean RemoveHypothesis(in SMESH_subMesh aSubMesh,
301 //                           in SMESH_Hypothesis anHyp)
302 //       raises (SALOME::SALOME_Exception);
303
304     /*!
305      * Get the list of hypothesis added on a subShape
306      */
307     ListOfHypothesis GetHypothesisList(in GEOM::GEOM_Object aSubObject)
308       raises (SALOME::SALOME_Exception);
309 //     ListOfHypothesis GetHypothesisList(in SMESH_subMesh aSubMesh)
310 //       raises (SALOME::SALOME_Exception);
311
312     /*!
313      * Get the log of nodes and elements added or removed since previous
314      * clear of the log.
315      * @params
316      * - clearAfterGet : log is emptied after Get (safe if concurrents access)
317      */
318     //    string_array GetLog(in boolean clearAfterGet)
319     //      raises (SALOME::SALOME_Exception);
320     log_array GetLog(in boolean clearAfterGet)
321       raises (SALOME::SALOME_Exception);
322
323     /*!
324      * Clear the log of nodes and elements added or removed since previous
325      * clear. Must be used immediately after GetLog if clearAfterGet is false.
326      */
327     void ClearLog()
328       raises (SALOME::SALOME_Exception);
329
330     /*!
331      * Get the internal Id
332      */
333     long GetId();
334
335     /*!
336      * Get the study Id
337      */
338     long GetStudyId();
339
340     /*!
341      * Obtain instance of SMESH_MeshEditor
342      */
343     SMESH_MeshEditor GetMeshEditor()
344       raises (SALOME::SALOME_Exception);
345
346     /*! Check group names for duplications.
347      *  Consider maximum group name length stored in MED file.
348      */
349     boolean HasDuplicatedGroupNamesMED();
350
351     /*!
352      * Export Mesh to different MED Formats
353      * @params
354      * - auto_groups : boolean parameter for creating/not creating
355      *   the groups Group_On_All_Nodes, Group_On_All_Faces, ... ;
356      *   the typical use is auto_groups=false.
357      * - theVersion : define the version of format of MED file, that will be created
358      */
359     void ExportToMED( in string file, in boolean auto_groups, in MED_VERSION theVersion )
360       raises (SALOME::SALOME_Exception);
361
362     /*!
363      * Export Mesh to MED_V2_1 MED format
364      * Works, just the same as ExportToMED, with MED_VERSION parameter equal to MED_V2_1.
365      * The method is kept in order to support old functionality
366      */
367     void ExportMED( in string file, in boolean auto_groups )
368       raises (SALOME::SALOME_Exception);
369
370     /*!
371      * Export Mesh to DAT, UNV and STL Formats
372      */
373     void ExportDAT( in string file )
374       raises (SALOME::SALOME_Exception);
375     void ExportUNV( in string file )
376       raises (SALOME::SALOME_Exception);
377     void ExportSTL( in string file, in boolean isascii )
378       raises (SALOME::SALOME_Exception);
379
380     /*!
381      * Get MED Mesh
382      */
383     SALOME_MED::MESH GetMEDMesh()
384       raises (SALOME::SALOME_Exception);
385
386     /*!
387      * Get informations about mesh contents
388      */
389     long NbNodes()
390       raises (SALOME::SALOME_Exception);
391
392     long NbElements()
393       raises (SALOME::SALOME_Exception);
394
395     long NbEdges()
396       raises (SALOME::SALOME_Exception);
397
398     long NbFaces()
399       raises (SALOME::SALOME_Exception);
400
401     long NbTriangles()
402       raises (SALOME::SALOME_Exception);
403
404     long NbQuadrangles()
405       raises (SALOME::SALOME_Exception);
406
407     long NbPolygons()
408       raises (SALOME::SALOME_Exception);
409
410     long NbVolumes()
411       raises (SALOME::SALOME_Exception);
412
413     long NbTetras()
414       raises (SALOME::SALOME_Exception);
415
416     long NbHexas()
417       raises (SALOME::SALOME_Exception);
418
419     long NbPyramids()
420       raises (SALOME::SALOME_Exception);
421
422     long NbPrisms()
423       raises (SALOME::SALOME_Exception);
424
425     long NbPolyhedrons()
426       raises (SALOME::SALOME_Exception);
427
428     long NbSubMesh()
429       raises (SALOME::SALOME_Exception);
430
431     long_array GetElementsId()
432       raises (SALOME::SALOME_Exception);
433
434     long_array GetElementsByType( in ElementType theType )
435       raises (SALOME::SALOME_Exception);
436
437     long_array GetNodesId()
438       raises (SALOME::SALOME_Exception);
439     
440     /*!
441      * Returns type of mesh element
442      */    
443     ElementType GetElementType( in long id, in boolean iselem )
444       raises (SALOME::SALOME_Exception);
445
446     /*!
447      * Get mesh description
448      */
449     string Dump();
450
451     /*!
452      * Get mesh pointer
453      */
454     long GetMeshPtr();
455
456   };
457
458   interface SMESH_subMesh : SALOME::GenericObj, SMESH_IDSource
459   {
460     /*!
461      *
462      */
463     long GetNumberOfElements()
464       raises (SALOME::SALOME_Exception);
465
466     /*!
467      *
468      */
469     long GetNumberOfNodes( in boolean all )
470       raises (SALOME::SALOME_Exception);
471
472     /*!
473      *
474      */
475     long_array GetElementsId()
476       raises (SALOME::SALOME_Exception);
477
478     /*!
479      *
480      */
481     long_array GetElementsByType( in ElementType theType )
482       raises (SALOME::SALOME_Exception);
483     
484     /*!
485      * Return type of submesh element
486      */
487     ElementType GetElementType( in long id, in boolean iselem )
488       raises (SALOME::SALOME_Exception);
489
490     /*!
491      *
492      */
493     long_array GetNodesId()
494       raises (SALOME::SALOME_Exception);
495
496     /*!
497      * Get geom shape the submesh is dedicated to
498      */
499     GEOM::GEOM_Object GetSubShape()
500       raises (SALOME::SALOME_Exception);
501
502     /*!
503      * Get SMESH_Mesh which stores nodes coordinates & elements definition
504      */
505     SMESH_Mesh GetFather()
506       raises (SALOME::SALOME_Exception);
507
508     /*!
509      * Get the internal Id
510      */
511     long GetId();
512
513     /*!
514      * Get MED subMesh
515      */
516     SALOME_MED::FAMILY GetFamily()
517       raises (SALOME::SALOME_Exception);
518   };
519
520   /*!
521    * This interface makes modifications on the Mesh - removing elements and nodes etc.
522    */
523   interface NumericalFunctor;
524   interface SMESH_MeshEditor
525   {
526     boolean RemoveElements(in long_array IDsOfElements);
527
528     boolean RemoveNodes(in long_array IDsOfNodes);
529
530     boolean AddNode(in double x, in double y, in double z);
531
532     boolean AddEdge(in long_array IDsOfNodes);
533
534     boolean AddFace(in long_array IDsOfNodes);
535
536     boolean AddPolygonalFace(in long_array IdsOfNodes);
537
538     boolean AddVolume(in long_array IDsOfNodes);
539
540     /*!
541      *  Create volume of many faces, giving nodes for each face.
542      *  \param IdsOfNodes List of node IDs for volume creation face by face.
543      *  \param Quantities List of integer values, Quantities[i]
544      *         gives quantity of nodes in face number i.
545      */
546     boolean AddPolyhedralVolume (in long_array IdsOfNodes,
547                                  in long_array Quantities);
548
549     /*!
550      *  Create volume of many faces, giving IDs of existing faces.
551      *  \param IdsOfFaces List of face IDs for volume creation.
552      *  \note The created volume will refer only to nodes
553      *        of the given faces, not to the faces itself.
554      */
555     boolean AddPolyhedralVolumeByFaces (in long_array IdsOfFaces);
556
557     boolean MoveNode(in long NodeID, in double x, in double y, in double z);
558
559     boolean InverseDiag(in long NodeID1, in long NodeID2);
560
561     boolean DeleteDiag(in long NodeID1, in long NodeID2);
562
563     boolean Reorient(in long_array IDsOfElements);
564
565     boolean ReorientObject(in SMESH_IDSource theObject);
566
567     /*!
568      * \brief Fuse neighbour triangles into quadrangles.
569      * \param theElems     The triangles to be fused.
570      * \param theCriterion Is used to choose a neighbour to fuse with.
571      * \param theMaxAngle  Is a max angle between element normals at which fusion
572      *                     is still performed; theMaxAngle is mesured in radians.
573      * \return TRUE in case of success, FALSE otherwise.
574      */
575     boolean TriToQuad (in long_array       IDsOfElements,
576                        in NumericalFunctor Criterion,
577                        in double           MaxAngle);
578
579     /*!
580      * \brief Fuse neighbour triangles into quadrangles.
581      *
582      * Behaves like the above method, taking list of elements from \a theObject
583      */
584     boolean TriToQuadObject (in SMESH_IDSource   theObject,
585                              in NumericalFunctor Criterion,
586                              in double           MaxAngle);
587
588     /*!
589      * \brief Split quadrangles into triangles.
590      * \param theElems     The faces to be splitted.
591      * \param theCriterion Is used to choose a diagonal for splitting.
592      * \return TRUE in case of success, FALSE otherwise.
593      */
594     boolean QuadToTri (in long_array       IDsOfElements,
595                        in NumericalFunctor Criterion);
596
597     /*!
598      * \brief Split quadrangles into triangles.
599      *
600      * Behaves like the above method, taking list of elements from \a theObject
601      */
602     boolean QuadToTriObject (in SMESH_IDSource   theObject,
603                              in NumericalFunctor Criterion);
604
605     /*!
606      * \brief Split quadrangles into triangles.
607      * \param theElems  The faces to be splitted.
608      * \param the13Diag Is used to choose a diagonal for splitting.
609      * \return TRUE in case of success, FALSE otherwise.
610      */
611     boolean SplitQuad (in long_array IDsOfElements,
612                        in boolean    Diag13);
613
614     /*!
615      * \brief Split quadrangles into triangles.
616      *
617      * Behaves like the above method, taking list of elements from \a theObject
618      */
619     boolean SplitQuadObject (in SMESH_IDSource theObject,
620                              in boolean        Diag13);
621
622     /*!
623      *  Find better splitting of the given quadrangle.
624      *  \param IDOfQuad  ID of the quadrangle to be splitted.
625      *  \param Criterion A criterion to choose a diagonal for splitting.
626      *  \return 1 if 1-3 diagonal is better, 2 if 2-4
627      *          diagonal is better, 0 if error occurs.
628      */
629     long BestSplit (in long             IDOfQuad,
630                     in NumericalFunctor Criterion);
631
632     enum Smooth_Method { LAPLACIAN_SMOOTH, CENTROIDAL_SMOOTH };
633
634     boolean Smooth(in long_array    IDsOfElements,
635                    in long_array    IDsOfFixedNodes,
636                    in long          MaxNbOfIterations,
637                    in double        MaxAspectRatio,
638                    in Smooth_Method Method);
639
640     boolean SmoothObject(in SMESH_IDSource  theObject,
641                          in long_array      IDsOfFixedNodes,
642                          in long            MaxNbOfIterations,
643                          in double          MaxAspectRatio,
644                          in Smooth_Method   Method);
645
646     boolean SmoothParametric(in long_array    IDsOfElements,
647                              in long_array    IDsOfFixedNodes,
648                              in long          MaxNbOfIterations,
649                              in double        MaxAspectRatio,
650                              in Smooth_Method Method);
651
652     boolean SmoothParametricObject(in SMESH_IDSource  theObject,
653                                    in long_array      IDsOfFixedNodes,
654                                    in long            MaxNbOfIterations,
655                                    in double          MaxAspectRatio,
656                                    in Smooth_Method   Method);
657
658     void RenumberNodes();
659
660     void RenumberElements();
661
662     void RotationSweep(in long_array       IDsOfElements,
663                        in AxisStruct       Axix,
664                        in double           AngleInRadians,
665                        in long             NbOfSteps,
666                        in double           Tolerance);
667
668     void RotationSweepObject(in SMESH_IDSource  theObject,
669                              in AxisStruct      Axix,
670                              in double          AngleInRadians,
671                              in long            NbOfSteps,
672                              in double          Tolerance);
673
674     void ExtrusionSweep(in long_array      IDsOfElements,
675                         in DirStruct       StepVector,
676                         in long            NbOfSteps);
677
678    /*!
679     * Generate new elements by extrusion of theElements 
680     * by StepVector by NbOfSteps
681     * param ExtrFlags set flags for performing extrusion
682     * param SewTolerance - uses for comparing locations of nodes if flag
683     *   EXTRUSION_FLAG_SEW is set
684     */
685     void AdvancedExtrusion(in long_array      IDsOfElements,
686                            in DirStruct       StepVector,
687                            in long            NbOfSteps,
688                            in long            ExtrFlags,
689                            in double          SewTolerance);
690
691     void ExtrusionSweepObject(in SMESH_IDSource  theObject,
692                               in DirStruct       StepVector,
693                               in long            NbOfSteps);
694
695     void ExtrusionSweepObject1D(in SMESH_IDSource theObject,
696                                 in DirStruct      StepVector,
697                                 in long           NbOfSteps);
698
699     void ExtrusionSweepObject2D(in SMESH_IDSource theObject,
700                                 in DirStruct      StepVector,
701                                 in long           NbOfSteps);
702
703     enum Extrusion_Error {
704       EXTR_OK,
705       EXTR_NO_ELEMENTS,
706       EXTR_PATH_NOT_EDGE,
707       EXTR_BAD_PATH_SHAPE,
708       EXTR_BAD_STARTING_NODE,
709       EXTR_BAD_ANGLES_NUMBER,
710       EXTR_CANT_GET_TANGENT
711       };
712
713     Extrusion_Error ExtrusionAlongPath(in long_array        IDsOfElements,
714                                        in SMESH_Mesh        PathMesh,
715                                        in GEOM::GEOM_Object PathShape,
716                                        in long              NodeStart,
717                                        in boolean           HasAngles,
718                                        in double_array      Angles,
719                                        in boolean           HasRefPoint,
720                                        in PointStruct       RefPoint);
721
722     Extrusion_Error ExtrusionAlongPathObject(in SMESH_IDSource    theObject,
723                                              in SMESH_Mesh        PathMesh,
724                                              in GEOM::GEOM_Object PathShape,
725                                              in long              NodeStart,
726                                              in boolean           HasAngles,
727                                              in double_array      Angles,
728                                              in boolean           HasRefPoint,
729                                              in PointStruct       RefPoint);
730
731     enum MirrorType { POINT, AXIS, PLANE };
732
733     void Mirror (in long_array       IDsOfElements,
734                  in AxisStruct       Mirror,
735                  in MirrorType       theMirrorType,
736                  in boolean          Copy);
737
738     void MirrorObject (in SMESH_IDSource  theObject,
739                        in AxisStruct      Mirror,
740                        in MirrorType      theMirrorType,
741                        in boolean         Copy);
742
743     void Translate (in long_array      IDsOfElements,
744                     in DirStruct       Vector,
745                     in boolean         Copy);
746
747     void TranslateObject (in SMESH_IDSource  theObject,
748                           in DirStruct       Vector,
749                           in boolean         Copy);
750
751     void Rotate (in long_array       IDsOfElements,
752                  in AxisStruct       Axis,
753                  in double           AngleInRadians,
754                  in boolean          Copy);
755
756     void RotateObject (in SMESH_IDSource  theObject,
757                        in AxisStruct      Axis,
758                        in double          AngleInRadians,
759                        in boolean         Copy);
760
761     void FindCoincidentNodes (in  double              Tolerance,
762                               out array_of_long_array GroupsOfNodes);
763
764     void MergeNodes (in array_of_long_array GroupsOfNodes);
765
766     void MergeEqualElements();
767
768     enum Sew_Error {
769       SEW_OK,
770       SEW_BORDER1_NOT_FOUND,
771       SEW_BORDER2_NOT_FOUND,
772       SEW_BOTH_BORDERS_NOT_FOUND,
773       SEW_BAD_SIDE_NODES,
774       SEW_VOLUMES_TO_SPLIT,
775       // for SewSideElements() only:
776       SEW_DIFF_NB_OF_ELEMENTS,
777       SEW_TOPO_DIFF_SETS_OF_ELEMENTS,
778       SEW_BAD_SIDE1_NODES,
779       SEW_BAD_SIDE2_NODES
780       };
781
782     Sew_Error SewFreeBorders (in long FirstNodeID1,
783                               in long SecondNodeID1,
784                               in long LastNodeID1,
785                               in long FirstNodeID2,
786                               in long SecondNodeID2,
787                               in long LastNodeID2,
788                               in boolean CreatePolygons,
789                               in boolean CreatePolyedrs);
790
791     Sew_Error SewConformFreeBorders (in long FirstNodeID1,
792                                      in long SecondNodeID1,
793                                      in long LastNodeID1,
794                                      in long FirstNodeID2,
795                                      in long SecondNodeID2);
796
797     Sew_Error SewBorderToSide (in long FirstNodeIDOnFreeBorder,
798                                in long SecondNodeIDOnFreeBorder,
799                                in long LastNodeIDOnFreeBorder,
800                                in long FirstNodeIDOnSide,
801                                in long LastNodeIDOnSide,
802                                in boolean CreatePolygons,
803                                in boolean CreatePolyedrs);
804
805     Sew_Error SewSideElements (in long_array IDsOfSide1Elements,
806                                in long_array IDsOfSide2Elements,
807                                in long       NodeID1OfSide1ToMerge,
808                                in long       NodeID1OfSide2ToMerge,
809                                in long       NodeID2OfSide1ToMerge,
810                                in long       NodeID2OfSide2ToMerge);
811
812   };
813 };
814
815 #endif