Salome HOME
updated copyright message
[modules/med.git] / src / MEDCouplingCorba_Swig / MEDCouplingCorbaSwigTestServ.py
1 # Copyright (C) 2007-2023  CEA/DEN, EDF R&D
2 #
3 # This library is free software; you can redistribute it and/or
4 # modify it under the terms of the GNU Lesser General Public
5 # License as published by the Free Software Foundation; either
6 # version 2.1 of the License, or (at your option) any later version.
7 #
8 # This library is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
11 # Lesser General Public License for more details.
12 #
13 # You should have received a copy of the GNU Lesser General Public
14 # License along with this library; if not, write to the Free Software
15 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
16 #
17 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18 #
19 # Author : Anthony Geay (CEA/DEN)
20
21 import MEDCouplingCorbaSwigTest
22 import MEDCouplingCorbaServantTest_idl
23
24 from MEDCouplingCorba import *
25
26 class MEDCouplingMeshFieldFactoryComponentPy(MEDCouplingCorbaServantTest_idl._0_SALOME_TEST__POA.MEDCouplingMeshFieldFactory):
27     def __init__(self,orb):
28         self._orb=orb
29         self._test=MEDCouplingCorbaSwigTest.MEDCouplingCorbaServBasicsTest()
30         pass
31     
32     def destroyFactory(self):
33         oid = self._default_POA().servant_to_id(self);
34         MEDCouplingCorbaServantTest_idl._0_SALOME_TEST__POA.MEDCouplingMeshFieldFactory._default_POA().deactivate_object(self,oid);
35         MEDCouplingCorbaServantTest_idl._0_SALOME_TEST__POA.MEDCouplingMeshFieldFactory._remove_ref(self);
36         
37     def shutdownOrb(self):
38         self._orb.shutdown(0)
39
40     def get1DMesh(self):
41         import SALOME_MED
42         mesh=self._test.build1DMesh()
43         ret=MEDCouplingUMeshServant._this(mesh)
44         assert isinstance(ret,SALOME_MED._objref_MEDCouplingUMeshCorbaInterface)
45         return ret
46     
47     def get2DMesh(self):
48         mesh=self._test.build2DMesh()
49         return MEDCouplingUMeshServant._this(mesh)
50     
51     def get3DMesh(self):
52         mesh=self._test.build3DMesh()
53         return MEDCouplingUMeshServant._this(mesh)
54     
55     def get3DSurfMesh(self):
56         mesh=self._test.build3DSurfMesh()
57         return MEDCouplingUMeshServant._this(mesh)
58     
59     def get0DMesh(self):
60         mesh=self._test.build0DMesh()
61         return MEDCouplingUMeshServant._this(mesh)
62     
63     def getM1DMesh(self):
64         mesh=self._test.buildM1DMesh()
65         return MEDCouplingUMeshServant._this(mesh)
66
67     def getExtrudedMesh(self):
68         mesh=self._test.buildExtrudedMesh()
69         return MEDCouplingExtrudedMeshServant._this(mesh)
70
71     def getCMesh(self):
72         mesh=self._test.buildCMesh()
73         return MEDCouplingCMeshServant._this(mesh)
74
75     def getIMesh(self):
76         mesh=self._test.buildIMesh()
77         return MEDCouplingIMeshServant._this(mesh)
78
79     def getCLMesh(self):
80         mesh=self._test.buildCLMesh()
81         return MEDCouplingCurveLinearMeshServant._this(mesh)
82
83     def get1SGTUMesh(self):
84         mesh=self._test.build1SGTUMesh()
85         return MEDCoupling1SGTUMeshServant._this(mesh)
86
87     def get1DGTUMesh(self):
88         mesh=self._test.build1DGTUMesh()
89         return MEDCoupling1DGTUMeshServant._this(mesh)
90     
91     def getFieldScalarOn2DNT(self):
92         field=self._test.buildFieldScalarOn2DNT()
93         return MEDCouplingFieldDoubleServant._this(field)
94     
95     def getFieldNodeScalarOn2DNT(self):
96         field=self._test.buildFieldNodeScalarOn2DNT()
97         return MEDCouplingFieldDoubleServant._this(field)
98     
99     def getFieldScalarOn3DNT(self):
100         field=self._test.buildFieldScalarOn3DNT()
101         return MEDCouplingFieldDoubleServant._this(field)
102     
103     def getFieldScalarOn3DSurfWT(self):
104         field=self._test.buildFieldScalarOn3DSurfWT()
105         return MEDCouplingFieldDoubleServant._this(field)
106     
107     def getFieldScalarOn3DSurfCOTI(self):
108         field=self._test.buildFieldScalarOn3DSurfCOTI()
109         return MEDCouplingFieldDoubleServant._this(field)
110     
111     def getFieldScalarOn2DLT(self):
112         field=self._test.buildFieldScalarOn2DLT()
113         return MEDCouplingFieldDoubleServant._this(field)
114
115     def getFieldGaussPt2DWT(self):
116         field=self._test.buildFieldGaussPt2DWT()
117         return MEDCouplingFieldDoubleServant._this(field)
118     
119     def getFieldGaussPtNE2DWT(self):
120         field=self._test.buildFieldGaussPtNE2DWT()
121         return MEDCouplingFieldDoubleServant._this(field)
122
123     def getFieldVectorOnExtrudedWT(self):
124         field=self._test.buildFieldVectorOnExtrudedWT()
125         return MEDCouplingFieldDoubleServant._this(field)
126
127     def getFieldVectorOnCMeshWT(self):
128         field=self._test.buildFieldVectorOnCMeshWT()
129         return MEDCouplingFieldDoubleServant._this(field)
130
131     def getFieldTemplateCellOn2D(self):
132         field=self._test.buildFieldTemplateCellOn2D()
133         return MEDCouplingFieldTemplateServant._this(field)
134     
135     def getFieldTemplateNodeOn2D(self):
136         field=self._test.buildFieldTemplateNodeOn2D()
137         return MEDCouplingFieldTemplateServant._this(field)
138     
139     def getFieldTemplateGaussPtOn2D(self):
140         field=self._test.buildFieldTemplateGaussPtOn2D()
141         return MEDCouplingFieldTemplateServant._this(field)
142     
143     def getFieldTemplateGaussNEOn2D(self):
144         field=self._test.buildFieldTemplateGaussNEOn2D()
145         return MEDCouplingFieldTemplateServant._this(field)
146
147     def getMultiFields1(self):
148         fields=self._test.buildMultiFields1()
149         return MEDCouplingMultiFieldsServant._this(fields)
150
151     def getArrayDouble1(self):
152         fields=self._test.buildArrayDouble1()
153         return DataArrayDoubleServant._this(fields)
154
155     def getArrayDouble2(self):
156         fields=self._test.buildArrayDouble2()
157         return DataArrayDoubleServant._this(fields)
158
159     def getArrayDouble3(self):
160         fields=self._test.buildArrayDouble3()
161         return DataArrayDoubleServant._this(fields)
162
163     def getArrayInt1(self):
164         fields=self._test.buildArrayInt1()
165         return DataArrayIntServant._this(fields)
166
167     def getArrayInt2(self):
168         fields=self._test.buildArrayInt2()
169         return DataArrayIntServant._this(fields)
170
171     def getArrayInt3(self):
172         fields=self._test.buildArrayInt3()
173         return DataArrayIntServant._this(fields)
174
175     def getMultiFields2(self):
176         fot=self._test.buildMultiFields2()
177         return MEDCouplingFieldOverTimeServant._this(fot)
178     pass