From 4c22ba01f2901896d1ec9ca302640f4d7e50d147 Mon Sep 17 00:00:00 2001 From: abn Date: Fri, 16 Oct 2020 14:54:18 +0200 Subject: [PATCH] MEDFileCurveLinearMesh -> getSpaceDimension() was missing --- src/MEDLoader/MEDFileMesh.cxx | 9 ++++++++- src/MEDLoader/MEDFileMesh.hxx | 6 ++++-- src/MEDLoader/Swig/MEDLoaderCommon.i | 2 ++ src/MEDLoader/Swig/MEDLoaderTest4.py | 1 + 4 files changed, 15 insertions(+), 3 deletions(-) diff --git a/src/MEDLoader/MEDFileMesh.cxx b/src/MEDLoader/MEDFileMesh.cxx index 076c7c177..10a17bc42 100644 --- a/src/MEDLoader/MEDFileMesh.cxx +++ b/src/MEDLoader/MEDFileMesh.cxx @@ -7131,10 +7131,17 @@ MEDFileCurveLinearMesh *MEDFileCurveLinearMesh::deepCopy() const int MEDFileCurveLinearMesh::getMeshDimension() const { if(!((const MEDCouplingCurveLinearMesh*)_clmesh)) - throw INTERP_KERNEL::Exception("MEDFileCurveLinearMesh::getMeshDimension : unable to get meshdimension because no mesh set !"); + throw INTERP_KERNEL::Exception("MEDFileCurveLinearMesh::getMeshDimension : unable to get mesh dimension because no mesh set !"); return _clmesh->getMeshDimension(); } +int MEDFileCurveLinearMesh::getSpaceDimension() const +{ + if(!((const MEDCouplingCurveLinearMesh*)_clmesh)) + throw INTERP_KERNEL::Exception("MEDFileCurveLinearMesh::getMeshDimension : unable to get space dimension because no mesh set !"); + return _clmesh->getSpaceDimension(); +} + std::string MEDFileCurveLinearMesh::simpleRepr() const { return MEDFileStructuredMesh::simpleRepr(); diff --git a/src/MEDLoader/MEDFileMesh.hxx b/src/MEDLoader/MEDFileMesh.hxx index 88e972418..f50321917 100644 --- a/src/MEDLoader/MEDFileMesh.hxx +++ b/src/MEDLoader/MEDFileMesh.hxx @@ -167,6 +167,7 @@ namespace MEDCoupling MEDLOADER_EXPORT void normalizeFamIdsTrio(); MEDLOADER_EXPORT void normalizeFamIdsMEDFile(); MEDLOADER_EXPORT virtual int getMeshDimension() const = 0; + MEDLOADER_EXPORT virtual int getSpaceDimension() const = 0; MEDLOADER_EXPORT virtual std::string simpleRepr() const; MEDLOADER_EXPORT virtual std::string advancedRepr() const = 0; // @@ -392,9 +393,9 @@ MCAuto& coords, MCAuto& partCoords, MCAuto > _ms; + std::vector< MCAuto > _ms; ///< The array of single-dimension constituting meshes, stored in decreasing order (dimRelativeToMax=0,-1,-2, ...) MCAuto _coords; - MCAuto _fam_coords; ///< Node family indices + MCAuto _fam_coords; ///< Node family indices MCAuto _num_coords; MCAuto _global_num_coords; MCAuto _name_coords; @@ -532,6 +533,7 @@ MCAuto& coords, MCAuto& partCoords, MCAuto