Salome HOME
[EDF23738] : implementation in structure elements (SE) context of case of multiple...
[tools/medcoupling.git] / src / MEDLoader / Swig / MEDLoaderCommon.i
index 986ac311b2d83333917ba475f13d846579c942d5..d53d6d623fa5ae57a2da8d282c891bfc26cd0231 100644 (file)
@@ -185,6 +185,7 @@ using namespace MEDCoupling;
 %newobject MEDCoupling::MEDFileFieldMultiTS::getFieldAtLevelOld;
 %newobject MEDCoupling::MEDFileFieldMultiTS::getUndergroundDataArray;
 %newobject MEDCoupling::MEDFileFieldMultiTS::convertToInt;
+%newobject MEDCoupling::MEDFileFieldMultiTS::Aggregate;
 
 %newobject MEDCoupling::MEDFileInt32FieldMultiTS::New;
 %newobject MEDCoupling::MEDFileInt32FieldMultiTS::field;
@@ -3037,6 +3038,17 @@ namespace MEDCoupling
     MEDFileInt32FieldMultiTS *convertToInt(bool isDeepCpyGlobs=true) const;
     %extend
        {
+         static MEDFileAnyTypeFieldMultiTS *Aggregate(PyObject *fmtssPy, PyObject *dtsPy)
+         {
+            std::vector<const MEDFileAnyTypeFieldMultiTS *> fmtss;
+            convertFromPyObjVectorOfObj<const MEDFileAnyTypeFieldMultiTS *>(fmtssPy,SWIGTYPE_p_MEDCoupling__MEDFileAnyTypeFieldMultiTS,"MEDFileAnyTypeFieldMultiTS",fmtss);
+            std::vector< std::vector< std::pair<mcIdType,mcIdType> > > dts2;
+            convertPyToVectorVectorPairInt(dtsPy,dts2);
+            std::vector< std::vector< std::pair<int,mcIdType> > > dts(MEDVectorVectorMIIterator(0,dts2),MEDVectorVectorMIIterator(dts2.size(),dts2));
+            MCAuto<MEDFileAnyTypeFieldMultiTS> ret = MEDFileFieldMultiTS::Aggregate(fmtss,dts);
+            return ret.retn();
+         }
+
          MEDFileFieldMultiTS()
          {
            return MEDFileFieldMultiTS::New();