Salome HOME
Merge from V6_main 12/04/2013
[modules/med.git] / src / MEDCouplingCorba_Swig / MEDCouplingCorba.i
1 // Copyright (C) 2007-2013  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.
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 %module MEDCouplingCorba
22
23 %{
24 #include "MEDCouplingFieldDoubleServant.hxx"  
25 #include "MEDCouplingFieldTemplateServant.hxx"
26 #include "MEDCouplingMultiFieldsServant.hxx"
27 #include "MEDCouplingFieldOverTimeServant.hxx"
28 #include "MEDCouplingUMeshServant.hxx"
29 #include "MEDCouplingExtrudedMeshServant.hxx"
30 #include "MEDCouplingCMeshServant.hxx"
31 #include "MEDCouplingCurveLinearMeshServant.hxx"
32 #include "DataArrayDoubleServant.hxx"
33 #include "DataArrayIntServant.hxx"
34 #include "MEDCouplingCorbaTypemaps.i"
35
36 using namespace ParaMEDMEM;
37 %}
38
39 %include "MEDCouplingCommon.i"
40
41 namespace ParaMEDMEM
42 {
43   class MEDCouplingFieldDoubleServant
44   {
45   public:
46     %extend
47        {
48          static PyObject *_this(const MEDCouplingFieldDouble *cppPointerOfMesh)
49          {
50            return buildServantAndActivate<MEDCouplingFieldDoubleServant>(cppPointerOfMesh);
51          }
52          
53          static PyObject *_this2(const MEDCouplingFieldDouble *cppPointerOfMesh)
54          {
55            return buildServantAndActivate2<MEDCouplingFieldDoubleServant>(cppPointerOfMesh);
56          }
57        }
58   };
59
60   class MEDCouplingFieldTemplateServant
61   {
62   public:
63     %extend
64        {
65          static PyObject *_this(const MEDCouplingFieldTemplate *cppPointerOfMesh)
66          {
67            return buildServantAndActivate<MEDCouplingFieldTemplateServant>(cppPointerOfMesh);
68          }
69          
70          static PyObject *_this2(const MEDCouplingFieldTemplate *cppPointerOfMesh)
71          {
72            return buildServantAndActivate2<MEDCouplingFieldTemplateServant>(cppPointerOfMesh);
73          }
74        }
75   };
76
77   class MEDCouplingMultiFieldsServant
78   {
79   public:
80     %extend
81        {
82          static PyObject *_this(const MEDCouplingMultiFields *cppPointerOfMesh)
83          {
84            return buildServantAndActivate<MEDCouplingMultiFieldsServant>(cppPointerOfMesh);
85          }
86
87          static PyObject *_this2(const MEDCouplingMultiFields *cppPointerOfMesh)
88          {
89            return buildServantAndActivate2<MEDCouplingMultiFieldsServant>(cppPointerOfMesh);
90          }
91        }
92   };
93
94   class MEDCouplingFieldOverTimeServant
95   {
96   public:
97     %extend
98        {
99          static PyObject *_this(const MEDCouplingFieldOverTime *cppPointerOfMesh)
100          {
101            return buildServantAndActivate<MEDCouplingFieldOverTimeServant>(cppPointerOfMesh);
102          }
103
104          static PyObject *_this2(const MEDCouplingFieldOverTime *cppPointerOfMesh)
105          {
106            return buildServantAndActivate2<MEDCouplingFieldOverTimeServant>(cppPointerOfMesh);
107          }
108        }
109   };
110
111   class MEDCouplingUMeshServant
112   {
113   public:
114     %extend
115        {
116          static PyObject *_this(const MEDCouplingUMesh *cppPointerOfMesh)
117          {
118            return buildServantAndActivate<MEDCouplingUMeshServant>(cppPointerOfMesh);
119          }
120
121          static PyObject *_this2(const MEDCouplingUMesh *cppPointerOfMesh)
122          {
123            return buildServantAndActivate2<MEDCouplingUMeshServant>(cppPointerOfMesh);
124          }
125        }
126   };
127
128   class MEDCouplingExtrudedMeshServant
129   {
130   public:
131     %extend
132        {
133          static PyObject *_this(const MEDCouplingExtrudedMesh *cppPointerOfMesh)
134          {
135            return buildServantAndActivate<MEDCouplingExtrudedMeshServant>(cppPointerOfMesh);
136          }
137
138          static PyObject *_this2(const MEDCouplingExtrudedMesh *cppPointerOfMesh)
139          {
140            return buildServantAndActivate2<MEDCouplingExtrudedMeshServant>(cppPointerOfMesh);
141          }
142        }
143   };
144
145   class MEDCouplingCMeshServant
146   {
147   public:
148     %extend
149        {
150          static PyObject *_this(const MEDCouplingCMesh *cppPointerOfMesh)
151          {
152            return buildServantAndActivate<MEDCouplingCMeshServant>(cppPointerOfMesh);
153          }
154          
155          static PyObject *_this2(const MEDCouplingCMesh *cppPointerOfMesh)
156          {
157            return buildServantAndActivate2<MEDCouplingCMeshServant>(cppPointerOfMesh);
158          }
159        }
160   };
161
162   class MEDCouplingCurveLinearMeshServant
163   {
164   public:
165     %extend
166        {
167          static PyObject *_this(const MEDCouplingCurveLinearMesh *cppPointerOfMesh)
168          {
169            return buildServantAndActivate<MEDCouplingCurveLinearMeshServant>(cppPointerOfMesh);
170          }
171
172          static PyObject *_this2(const MEDCouplingCurveLinearMesh *cppPointerOfMesh)
173          {
174            return buildServantAndActivate2<MEDCouplingCurveLinearMeshServant>(cppPointerOfMesh);
175          }
176        }
177   };
178
179   class DataArrayDoubleServant
180   {
181   public:
182     %extend
183        {
184          static PyObject *_this(const DataArrayDouble *cppPointerOfMesh)
185          {
186            return buildServantAndActivate<DataArrayDoubleServant>(cppPointerOfMesh);
187          }
188
189          static PyObject *_this2(const DataArrayDouble *cppPointerOfMesh)
190          {
191            return buildServantAndActivate2<DataArrayDoubleServant>(cppPointerOfMesh);
192          }
193        }
194   };
195
196   class DataArrayIntServant
197   {
198   public:
199     %extend
200        {
201          static PyObject *_this(const DataArrayInt *cppPointerOfMesh)
202          {
203            return buildServantAndActivate<DataArrayIntServant>(cppPointerOfMesh);
204          }
205
206          static PyObject *_this2(const DataArrayInt *cppPointerOfMesh)
207          {
208            return buildServantAndActivate2<DataArrayIntServant>(cppPointerOfMesh);
209          }
210        }
211   };
212 }
213
214 %pythoncode %{
215 def ParaMEDMEMDataArrayDoubleIadd(self,*args):
216     import _MEDCouplingCorba
217     return _MEDCouplingCorba.DataArrayDouble____iadd___(self, self, *args)
218 def ParaMEDMEMDataArrayDoubleIsub(self,*args):
219     import _MEDCouplingCorba
220     return _MEDCouplingCorba.DataArrayDouble____isub___(self, self, *args)
221 def ParaMEDMEMDataArrayDoubleImul(self,*args):
222     import _MEDCouplingCorba
223     return _MEDCouplingCorba.DataArrayDouble____imul___(self, self, *args)
224 def ParaMEDMEMDataArrayDoubleIdiv(self,*args):
225     import _MEDCouplingCorba
226     return _MEDCouplingCorba.DataArrayDouble____idiv___(self, self, *args)
227 def ParaMEDMEMDataArrayDoubleIpow(self,*args):
228     import _MEDCouplingCorba
229     return _MEDCouplingCorba.DataArrayDouble____ipow___(self, self, *args)
230 def ParaMEDMEMMEDCouplingFieldDoubleIadd(self,*args):
231     import _MEDCouplingCorba
232     return _MEDCouplingCorba.MEDCouplingFieldDouble____iadd___(self, self, *args)
233 def ParaMEDMEMMEDCouplingFieldDoubleIsub(self,*args):
234     import _MEDCouplingCorba
235     return _MEDCouplingCorba.MEDCouplingFieldDouble____isub___(self, self, *args)
236 def ParaMEDMEMMEDCouplingFieldDoubleImul(self,*args):
237     import _MEDCouplingCorba
238     return _MEDCouplingCorba.MEDCouplingFieldDouble____imul___(self, self, *args)
239 def ParaMEDMEMMEDCouplingFieldDoubleIdiv(self,*args):
240     import _MEDCouplingCorba
241     return _MEDCouplingCorba.MEDCouplingFieldDouble____idiv___(self, self, *args)
242 def ParaMEDMEMMEDCouplingFieldDoubleIpow(self,*args):
243     import _MEDCouplingCorba
244     return _MEDCouplingCorba.MEDCouplingFieldDouble____ipow___(self, self, *args)
245 def ParaMEDMEMDataArrayIntIadd(self,*args):
246     import _MEDCouplingCorba
247     return _MEDCouplingCorba.DataArrayInt____iadd___(self, self, *args)
248 def ParaMEDMEMDataArrayIntIsub(self,*args):
249     import _MEDCouplingCorba
250     return _MEDCouplingCorba.DataArrayInt____isub___(self, self, *args)
251 def ParaMEDMEMDataArrayIntImul(self,*args):
252     import _MEDCouplingCorba
253     return _MEDCouplingCorba.DataArrayInt____imul___(self, self, *args)
254 def ParaMEDMEMDataArrayIntIdiv(self,*args):
255     import _MEDCouplingCorba
256     return _MEDCouplingCorba.DataArrayInt____idiv___(self, self, *args)
257 def ParaMEDMEMDataArrayIntImod(self,*args):
258     import _MEDCouplingCorba
259     return _MEDCouplingCorba.DataArrayInt____imod___(self, self, *args)
260 def ParaMEDMEMDataArrayIntIpow(self,*args):
261     import _MEDCouplingCorba
262     return _MEDCouplingCorba.DataArrayInt____ipow___(self, self, *args)
263 def ParaMEDMEMDataArrayDoubleTupleIadd(self,*args):
264     import _MEDCouplingCorba
265     return _MEDCouplingCorba.DataArrayDoubleTuple____iadd___(self, self, *args)
266 def ParaMEDMEMDataArrayDoubleTupleIsub(self,*args):
267     import _MEDCouplingCorba
268     return _MEDCouplingCorba.DataArrayDoubleTuple____isub___(self, self, *args)
269 def ParaMEDMEMDataArrayDoubleTupleImul(self,*args):
270     import _MEDCouplingCorba
271     return _MEDCouplingCorba.DataArrayDoubleTuple____imul___(self, self, *args)
272 def ParaMEDMEMDataArrayDoubleTupleIdiv(self,*args):
273     import _MEDCouplingCorba
274     return _MEDCouplingCorba.DataArrayDoubleTuple____idiv___(self, self, *args)
275 def ParaMEDMEMDataArrayIntTupleIadd(self,*args):
276     import _MEDCouplingCorba
277     return _MEDCouplingCorba.DataArrayIntTuple____iadd___(self, self, *args)
278 def ParaMEDMEMDataArrayIntTupleIsub(self,*args):
279     import _MEDCouplingCorba
280     return _MEDCouplingCorba.DataArrayIntTuple____isub___(self, self, *args)
281 def ParaMEDMEMDataArrayIntTupleImul(self,*args):
282     import _MEDCouplingCorba
283     return _MEDCouplingCorba.DataArrayIntTuple____imul___(self, self, *args)
284 def ParaMEDMEMDataArrayIntTupleIdiv(self,*args):
285     import _MEDCouplingCorba
286     return _MEDCouplingCorba.DataArrayIntTuple____idiv___(self, self, *args)
287 def ParaMEDMEMDataArrayIntTupleImod(self,*args):
288     import _MEDCouplingCorba
289     return _MEDCouplingCorba.DataArrayIntTuple____imod___(self, self, *args)
290 %}
291
292 %include "MEDCouplingFinalize.i"