disc=_type->clone();
MEDCouplingAutoRefCountObjectPtr<MEDCouplingFieldDouble> ret=new MEDCouplingFieldDouble(getNature(),tdo,disc.retn());
ret->setMesh(getMesh());
- ret->setName(getName());
- ret->setDescription(getDescription());
+ ret->setName(getName().c_str());
+ ret->setDescription(getDescription().c_str());
return ret.retn();
}
* renumbering. The underlying mesh is deeply copied and its cells are also permuted.
* The number of cells remains the same; for that the permutation array \a old2NewBg
* should not contain equal ids.
+ * ** Warning, this method modifies the mesh aggreagated by \a this (by performing a deep copy ) **.
+ *
* \param [in] old2NewBg - the permutation array in "Old to New" mode. Its length is
* to be equal to \a this->getMesh()->getNumberOfCells().
* \param [in] check - if \c true, \a old2NewBg is transformed to a new permutation
MEDCouplingTimeDiscretization *td=_time_discr->keepSelectedComponents(compoIds);
td->copyTinyAttrFrom(*_time_discr);
MEDCouplingAutoRefCountObjectPtr<MEDCouplingFieldDouble> ret=new MEDCouplingFieldDouble(getNature(),td,_type->clone());
- ret->setName(getName());
+ ret->setName(getName().c_str());
ret->setMesh(getMesh());
return ret.retn();
}
td->copyTinyAttrFrom(*f1->_time_discr);
MEDCouplingAutoRefCountObjectPtr<MEDCouplingFieldDouble> ret=new MEDCouplingFieldDouble(f1->getNature(),td,f1->_type->clone());
ret->setMesh(m);
- ret->setName(f1->getName());
- ret->setDescription(f1->getDescription());
+ ret->setName(f1->getName().c_str());
+ ret->setDescription(f1->getDescription().c_str());
return ret.retn();
}
tds[i]=a[i]->_time_discr;
}
MEDCouplingAutoRefCountObjectPtr<MEDCouplingUMesh> m=MEDCouplingUMesh::MergeUMeshes(ms2);
- m->setName(ms2[0]->getName()); m->setDescription(ms2[0]->getDescription());
+ m->setName(ms2[0]->getName().c_str()); m->setDescription(ms2[0]->getDescription().c_str());
MEDCouplingTimeDiscretization *td=tds[0]->aggregate(tds);
td->copyTinyAttrFrom(*(a[0]->_time_discr));
MEDCouplingAutoRefCountObjectPtr<MEDCouplingFieldDouble> ret=new MEDCouplingFieldDouble(a[0]->getNature(),td,a[0]->_type->clone());
ret->setMesh(m);
- ret->setName(a[0]->getName());
- ret->setDescription(a[0]->getDescription());
+ ret->setName(a[0]->getName().c_str());
+ ret->setDescription(a[0]->getDescription().c_str());
return ret.retn();
}
}
TypeOfField typ=cur->getTypeOfField();
if(typ==ON_CELLS)
- cur->getArray()->writeVTK(coss,8,cur->getName());
+ cur->getArray()->writeVTK(coss,8,cur->getName().c_str());
else if(typ==ON_NODES)
- cur->getArray()->writeVTK(noss,8,cur->getName());
+ cur->getArray()->writeVTK(noss,8,cur->getName().c_str());
}
m->writeVTKAdvanced(fileName,coss.str(),noss.str());
}
nat=MEDCouplingNatureOfField::GetRepr(_nature);
stream << "Nature of field : " << nat << ".\n";
}
- catch(INTERP_KERNEL::Exception& e)
+ catch(INTERP_KERNEL::Exception& /*e*/)
{ }
const MEDCouplingFieldDiscretization *fd(_type);
if(!fd)