Salome HOME
Using files from package LightApp instead of SalomeApp
[modules/smesh.git] / idl / SMESH_Gen.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_Gen.idl
23 //  Author : Paul RASCLE, EDF
24 //  $Header$
25
26 #ifndef _SMESH_GEN_IDL_
27 #define _SMESH_GEN_IDL_
28
29 #include "SALOME_Exception.idl"
30 #include "SALOME_Component.idl"
31 #include "SALOMEDS.idl"
32
33 #include "GEOM_Gen.idl"
34
35 #include "SMESH_Mesh.idl"
36 #include "SMESH_Hypothesis.idl"
37
38 module SMESH
39 {
40   typedef sequence<GEOM::GEOM_Object> object_array;
41   typedef sequence<SMESH_Mesh> mesh_array;
42
43   interface FilterManager;
44   interface SMESH_Pattern;
45
46   interface SMESH_Gen : Engines::Component, SALOMEDS::Driver
47   {
48
49     FilterManager CreateFilterManager();
50
51     SMESH_Pattern GetPattern();
52
53     /*!
54       Set the current study
55      */
56     void SetCurrentStudy( in SALOMEDS::Study theStudy );
57
58     /*!
59       Get the current study
60      */
61     SALOMEDS::Study GetCurrentStudy();
62
63     /*!
64      * Create a hypothesis that can be shared by differents parts of the mesh.
65      * An hypothesis is either:
66      * - a method used to generate or modify a part of the mesh (algorithm).
67      * - a parameter or a law used by an algorithm.
68      * Algorithms are 1D, 2D or 3D.
69      */
70     SMESH_Hypothesis CreateHypothesis( in string theHypName,
71                                        in string theLibName )
72       raises ( SALOME::SALOME_Exception );
73
74     /*!
75      * Create a Mesh object, given a geometry shape.
76      * Mesh is created empty (no points, no elements).
77      * Shape is explored via GEOM_Client to create local copies.
78      * of TopoDS_Shapes and bind CORBA references of shape & subshapes
79      * with TopoDS_Shapes
80      */
81     SMESH_Mesh CreateMesh( in GEOM::GEOM_Object theObject )
82       raises ( SALOME::SALOME_Exception );
83     
84     /*!
85      * Create Mesh object importing data from given UNV file
86      */
87     SMESH_Mesh CreateMeshesFromUNV( in string theFileName )
88       raises ( SALOME::SALOME_Exception );
89
90     /*!
91      * Create Mesh object(s) importing data from given MED file
92      */
93      mesh_array CreateMeshesFromMED( in string theFileName,
94                                      out SMESH::DriverMED_ReadStatus theStatus )
95        raises ( SALOME::SALOME_Exception );
96
97     /*!
98      * Create Mesh object importing data from given STL file
99      */
100     SMESH_Mesh CreateMeshesFromSTL( in string theFileName )
101       raises ( SALOME::SALOME_Exception );
102
103     /*!
104      * Create a Mesh object, without a geometry shape reference
105      */
106 //      SMESH_Mesh NewEmpty()
107 //        raises ( SALOME::SALOME_Exception );
108
109     /*!
110      * Mesh a subShape. 
111      * First, verify list of hypothesis associated with the subShape,
112      * return NOK if hypothesis are not sufficient
113      */
114     boolean Compute( in SMESH_Mesh       theMesh, 
115                      in GEOM::GEOM_Object theSubObject )
116       raises ( SALOME::SALOME_Exception );
117
118     /*!
119      * 
120      */
121
122     boolean IsReadyToCompute( in SMESH_Mesh       theMesh, 
123                               in GEOM::GEOM_Object theSubObject )
124       raises ( SALOME::SALOME_Exception );
125
126     /*!
127      * 
128      */
129     long_array GetSubShapesId( in GEOM::GEOM_Object theMainObject,
130                              in object_array theListOfSubObjects )
131        raises ( SALOME::SALOME_Exception );
132     
133     /*!
134      * 
135      */
136     //    long_array GetSubMeshesState( in object_array theListOfSubShape )
137     //  raises ( SALOME::SALOME_Exception );
138     
139   };
140
141 };
142
143 #endif