Version: 8.3.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
MEDCoupling::MEDFileIntField1TS Class Reference
Inheritance diagram for MEDCoupling::MEDFileIntField1TS:
Collaboration diagram for MEDCoupling::MEDFileIntField1TS:

Public Member Functions

MEDFileField1TSconvertToDouble (bool isDeepCpyGlobs=true) const
 
MEDFileIntField1TSextractPart (const std::map< int, MCAuto< DataArrayInt > > &extractDef, MEDFileMesh *mm) const
 
MEDCouplingFieldIntfield (const MEDFileMesh *mesh) const
 
MEDCouplingFieldIntgetFieldAtLevel (TypeOfField type, int meshDimRelToMax, int renumPol=0) const
 
MEDCouplingFieldIntgetFieldAtLevelOld (TypeOfField type, const std::string &mname, int meshDimRelToMax, int renumPol=0) const
 
MEDCouplingFieldIntgetFieldAtTopLevel (TypeOfField type, int renumPol=0) const
 
MEDCouplingFieldIntgetFieldOnMeshAtLevel (TypeOfField type, int meshDimRelToMax, const MEDFileMesh *mesh, int renumPol=0) const
 
MEDCouplingFieldIntgetFieldOnMeshAtLevel (TypeOfField type, const MEDCouplingMesh *mesh, int renumPol=0) const
 
DataArrayIntgetFieldWithProfile (TypeOfField type, int meshDimRelToMax, const MEDFileMesh *mesh, DataArrayInt *&pfl) const
 
DataArrayIntgetUndergroundDataArray () const
 
void setFieldNoProfileSBT (const MEDCouplingFieldInt *field)
 
void setFieldProfile (const MEDCouplingFieldInt *field, const MEDFileMesh *mesh, int meshDimRelToMax, const DataArrayInt *profile)
 
MEDFileIntField1TSshallowCpy () const
 
- Public Member Functions inherited from MEDCoupling::MEDFileAnyTypeField1TS
void changeLocsRefsNamesGen (const std::vector< std::pair< std::vector< std::string >, std::string > > &mapOfModif)
 
bool changeMeshNames (const std::vector< std::pair< std::string, std::string > > &modifTab)
 
void changePflsRefsNamesGen (const std::vector< std::pair< std::vector< std::string >, std::string > > &mapOfModif)
 
MEDFileAnyTypeField1TSWithoutSDAcontentNotNullBase ()
 
const
MEDFileAnyTypeField1TSWithoutSDA
contentNotNullBase () const
 
void convertMedBallIntoClassic ()
 
int copyTinyInfoFrom (const MEDCouplingFieldDouble *field, const DataArray *arr)
 
MEDFileAnyTypeField1TSdeepCopy () const
 
void fillIteration (std::pair< int, int > &p) const
 
void fillTypesOfFieldAvailable (std::vector< TypeOfField > &types) const
 
int getDimension () const
 
std::vector< const
BigMemoryObject * > 
getDirectChildrenWithNull () const
 
std::pair< int, int > getDtIt () const
 
std::string getDtUnit () const
 
std::vector< std::vector
< std::pair< int, int > > > 
getFieldSplitedByType (const std::string &mname, std::vector< INTERP_KERNEL::NormalizedCellType > &types, std::vector< std::vector< TypeOfField > > &typesF, std::vector< std::vector< std::string > > &pfls, std::vector< std::vector< std::string > > &locs) const
 
std::size_t getHeapMemorySizeWithoutChildren () const
 
const std::vector< std::string > & getInfo () const
 
std::vector< std::string > & getInfo ()
 
int getIteration () const
 
MEDFileFieldPerMeshPerTypePerDisc * getLeafGivenMeshAndTypeAndLocId (const std::string &mName, INTERP_KERNEL::NormalizedCellType typ, int locId)
 
const
MEDFileFieldPerMeshPerTypePerDisc * 
getLeafGivenMeshAndTypeAndLocId (const std::string &mName, INTERP_KERNEL::NormalizedCellType typ, int locId) const
 
std::vector< std::string > getLocsReallyUsed () const
 
std::vector< std::string > getLocsReallyUsedMulti () const
 
int getMeshIteration () const
 
std::string getMeshName () const
 
int getMeshOrder () const
 
std::string getName () const
 
int getNonEmptyLevels (const std::string &mname, std::vector< int > &levs) const
 
int getNumberOfComponents () const
 
int getOrder () const
 
std::vector< std::string > getPflsReallyUsed () const
 
std::vector< std::string > getPflsReallyUsedMulti () const
 
double getTime (int &iteration, int &order) const
 
std::vector< TypeOfFieldgetTypesOfFieldAvailable () const
 
bool isDealingTS (int iteration, int order) const
 
void loadArrays ()
 
void loadArraysIfNecessary ()
 
void makeReduction (INTERP_KERNEL::NormalizedCellType ct, TypeOfField tof, const DataArrayInt *pfl)
 
bool presenceOfMultiDiscPerGeoType () const
 
void setDtUnit (const std::string &dtUnit)
 
void setInfo (const std::vector< std::string > &infos)
 
void setLocNameOnLeaf (const std::string &mName, INTERP_KERNEL::NormalizedCellType typ, int locId, const std::string &newLocName, bool forceRenameOnGlob=false)
 
void setMeshName (const std::string &newMeshName)
 
void setName (const std::string &name)
 
void setProfileNameOnLeaf (const std::string &mName, INTERP_KERNEL::NormalizedCellType typ, int locId, const std::string &newPflName, bool forceRenameOnGlob=false)
 
void setTime (int iteration, int order, double val)
 
std::string simpleRepr () const
 
void simpleRepr (int bkOffset, std::ostream &oss, int f1tsId) const
 
std::vector< MCAuto
< MEDFileAnyTypeField1TS > > 
splitComponents () const
 
std::vector< MCAuto
< MEDFileAnyTypeField1TS > > 
splitDiscretizations () const
 
std::vector< MCAuto
< MEDFileAnyTypeField1TS > > 
splitMultiDiscrPerGeoTypes () const
 
void unloadArrays ()
 
void unloadArraysWithoutDataLoss ()
 
- Public Member Functions inherited from MEDCoupling::MEDFileFieldGlobsReal
void appendGlobs (const MEDFileFieldGlobsReal &other, double eps)
 
void appendLoc (const std::string &locName, INTERP_KERNEL::NormalizedCellType geoType, const std::vector< double > &refCoo, const std::vector< double > &gsCoo, const std::vector< double > &w)
 
void appendProfile (DataArrayInt *pfl)
 
void changeLocName (const std::string &oldName, const std::string &newName)
 
void changeLocsNames (const std::vector< std::pair< std::vector< std::string >, std::string > > &mapOfModif)
 
void changeLocsNamesInStruct (const std::vector< std::pair< std::vector< std::string >, std::string > > &mapOfModif)
 
void changePflName (const std::string &oldName, const std::string &newName)
 
void changePflsNames (const std::vector< std::pair< std::vector< std::string >, std::string > > &mapOfModif)
 
void changePflsNamesInStruct (const std::vector< std::pair< std::vector< std::string >, std::string > > &mapOfModif)
 
void checkGlobsCoherency () const
 
void checkGlobsLocsPartCoherency () const
 
void checkGlobsPflsPartCoherency () const
 
std::string createNewNameOfLoc () const
 
std::string createNewNameOfPfl () const
 
void deepCpyGlobs (const MEDFileFieldGlobsReal &other)
 
void deepCpyOnlyUsedGlobs (const MEDFileFieldGlobsReal &other)
 
bool existsLoc (const std::string &locName) const
 
bool existsPfl (const std::string &pflName) const
 
std::vector< const
BigMemoryObject * > 
getDirectChildrenWithNull () const
 
std::string getFileName () const
 
std::size_t getHeapMemorySizeWithoutChildren () const
 
const MEDFileFieldLocgetLocalization (const std::string &locName) const
 
MEDFileFieldLocgetLocalization (const std::string &locName)
 
const MEDFileFieldLocgetLocalizationFromId (int locId) const
 
MEDFileFieldLocgetLocalizationFromId (int locId)
 
int getLocalizationId (const std::string &loc) const
 
std::vector< std::string > getLocs () const
 
int getNbOfGaussPtPerCell (int locId) const
 
std::vector< std::string > getPfls () const
 
const DataArrayIntgetProfile (const std::string &pflName) const
 
DataArrayIntgetProfile (const std::string &pflName)
 
const DataArrayIntgetProfileFromId (int pflId) const
 
DataArrayIntgetProfileFromId (int pflId)
 
void killLocalizationIds (const std::vector< int > &locIds)
 
void killProfileIds (const std::vector< int > &pflIds)
 
void killStructureElementsInGlobs ()
 
void loadAllGlobals (med_idt fid, const MEDFileEntities *entities=0)
 
void loadGlobals (med_idt fid)
 
void loadProfileInFile (med_idt fid, int id, const std::string &pflName)
 
void loadProfileInFile (med_idt fid, int id)
 
 MEDFileFieldGlobsReal (med_idt fid)
 
 MEDFileFieldGlobsReal ()
 
void resetContent ()
 
void setFileName (const std::string &fileName)
 
void shallowCpyGlobs (const MEDFileFieldGlobsReal &other)
 
void shallowCpyOnlyUsedGlobs (const MEDFileFieldGlobsReal &other)
 
void simpleReprGlobs (std::ostream &oss) const
 
std::vector< std::vector< int > > whichAreEqualLocs (double eps) const
 
std::vector< std::vector< int > > whichAreEqualProfiles () const
 
void writeGlobals (med_idt fid, const MEDFileWritable &opt) const
 
std::vector< std::pair
< std::vector< std::string >
, std::string > > 
zipLocsNames (double eps)
 
std::vector< std::pair
< std::vector< std::string >
, std::string > > 
zipPflsNames ()
 
virtual ~MEDFileFieldGlobsReal ()
 

Static Public Member Functions

static MCAuto
< MEDCouplingFieldDouble
ConvertFieldIntToFieldDouble (const MEDCouplingFieldInt *f)
 
static MEDFileIntField1TSNew ()
 
static MEDFileIntField1TSNew (const std::string &fileName, bool loadAll=true)
 
static MEDFileIntField1TSNew (med_idt fid, bool loadAll=true)
 
static MEDFileIntField1TSNew (DataArrayByte *db)
 
static MEDFileIntField1TSNew (const std::string &fileName, const std::string &fieldName, bool loadAll=true)
 
static MEDFileIntField1TSNew (med_idt fid, const std::string &fieldName, bool loadAll=true)
 
static MEDFileIntField1TSNew (const std::string &fileName, const std::string &fieldName, int iteration, int order, bool loadAll=true)
 
static MEDFileIntField1TSNew (med_idt fid, const std::string &fieldName, int iteration, int order, bool loadAll=true)
 
static MEDFileIntField1TSNew (const MEDFileIntField1TSWithoutSDA &other, bool shallowCopyOfContent)
 
static DataArrayIntReturnSafelyDataArrayInt (MCAuto< DataArray > &arr)
 
static MCAuto
< MEDCouplingFieldInt
SetDataArrayDoubleInIntField (MEDCouplingFieldDouble *f, MCAuto< DataArray > &arr)
 
- Static Public Member Functions inherited from MEDCoupling::MEDFileAnyTypeField1TS
static int LocateField (med_idt fid, const std::string &fieldName, int &posCFormat, med_field_type &typcha, std::vector< std::string > &infos, std::string &dtunitOut, std::string &meshName)
 
static int LocateField2 (med_idt fid, int fieldIdCFormat, bool checkFieldId, std::string &fieldName, med_field_type &typcha, std::vector< std::string > &infos, std::string &dtunitOut, std::string &meshName)
 
static MEDFileAnyTypeField1TSNew (const std::string &fileName, bool loadAll=true)
 
static MEDFileAnyTypeField1TSNew (med_idt fid, bool loadAll=true)
 
static MEDFileAnyTypeField1TSNew (const std::string &fileName, const std::string &fieldName, bool loadAll=true)
 
static MEDFileAnyTypeField1TSNew (med_idt fid, const std::string &fieldName, bool loadAll=true)
 
static MEDFileAnyTypeField1TSNew (const std::string &fileName, const std::string &fieldName, int iteration, int order, bool loadAll=true)
 
static MEDFileAnyTypeField1TSNew (med_idt fid, const std::string &fieldName, int iteration, int order, bool loadAll=true)
 
static MEDFileAnyTypeField1TSNewAdv (const std::string &fileName, const std::string &fieldName, int iteration, int order, bool loadAll, const MEDFileEntities *entities)
 
static MEDFileAnyTypeField1TSNewAdv (med_idt fid, const std::string &fieldName, int iteration, int order, bool loadAll, const MEDFileEntities *entities)
 

Additional Inherited Members

- Protected Member Functions inherited from MEDCoupling::MEDFileAnyTypeField1TS
 MEDFileAnyTypeField1TS ()
 
 MEDFileAnyTypeField1TS (med_idt fid, bool loadAll, const MEDFileMeshes *ms, const MEDFileEntities *entities=0)
 
 MEDFileAnyTypeField1TS (med_idt fid, const std::string &fieldName, bool loadAll, const MEDFileMeshes *ms, const MEDFileEntities *entities=0)
 
 MEDFileAnyTypeField1TS (med_idt fid, const std::string &fieldName, int iteration, int order, bool loadAll, const MEDFileMeshes *ms, const MEDFileEntities *entities=0)
 
 MEDFileAnyTypeField1TS (const MEDFileAnyTypeField1TSWithoutSDA &other, bool shallowCopyOfContent)
 
void writeLL (med_idt fid) const
 
- Static Protected Member Functions inherited from MEDCoupling::MEDFileAnyTypeField1TS
static
MEDFileAnyTypeField1TSWithoutSDA
BuildContentFrom (med_idt fid, bool loadAll, const MEDFileMeshes *ms, const MEDFileEntities *entities)
 
static
MEDFileAnyTypeField1TSWithoutSDA
BuildContentFrom (med_idt fid, const std::string &fieldName, bool loadAll, const MEDFileMeshes *ms, const MEDFileEntities *entities)
 
static
MEDFileAnyTypeField1TSWithoutSDA
BuildContentFrom (med_idt fid, const std::string &fieldName, int iteration, int order, bool loadAll, const MEDFileMeshes *ms, const MEDFileEntities *entities)
 
static MEDFileAnyTypeField1TSBuildNewInstanceFromContent (MEDFileAnyTypeField1TSWithoutSDA *c)
 
static MEDFileAnyTypeField1TSBuildNewInstanceFromContent (MEDFileAnyTypeField1TSWithoutSDA *c, med_idt fid)
 
- Protected Attributes inherited from MEDCoupling::MEDFileAnyTypeField1TS
MCAuto
< MEDFileAnyTypeField1TSWithoutSDA
_content
 

Member Function Documentation

MEDFileIntField1TS * MEDFileIntField1TS::New ( const std::string &  fileName,
bool  loadAll = true 
)
static

References New().

MEDFileIntField1TS * MEDFileIntField1TS::New ( med_idt  fid,
bool  loadAll = true 
)
static
static MEDFileIntField1TS* MEDCoupling::MEDFileIntField1TS::New ( DataArrayByte db)
static
MEDFileIntField1TS * MEDFileIntField1TS::New ( const std::string &  fileName,
const std::string &  fieldName,
bool  loadAll = true 
)
static

References New().

MEDFileIntField1TS * MEDFileIntField1TS::New ( med_idt  fid,
const std::string &  fieldName,
bool  loadAll = true 
)
static
MEDFileIntField1TS * MEDFileIntField1TS::New ( const std::string &  fileName,
const std::string &  fieldName,
int  iteration,
int  order,
bool  loadAll = true 
)
static

References New().

MEDFileIntField1TS * MEDFileIntField1TS::New ( med_idt  fid,
const std::string &  fieldName,
int  iteration,
int  order,
bool  loadAll = true 
)
static
MEDFileIntField1TS * MEDFileIntField1TS::New ( const MEDFileIntField1TSWithoutSDA other,
bool  shallowCopyOfContent 
)
static
MEDFileField1TS * MEDFileIntField1TS::convertToDouble ( bool  isDeepCpyGlobs = true) const

This method performs a copy with datatype modification ( int32->float64 ) of this. The globals information are copied following the given input policy.

Parameters
[in]isDeepCpyGlobs- a boolean that indicates the behaviour concerning globals (profiles and localizations) By default (true) the globals are deeply copied.
Returns
MEDFileField1TS * - a new object that is the result of the conversion of this to float64 field.

References MEDCoupling::MEDFileAnyTypeField1TS::_content, MEDCoupling::MEDFileAnyTypeField1TS::BuildNewInstanceFromContent(), MEDCoupling::MEDFileIntField1TSWithoutSDA::convertToDouble(), MEDCoupling::MEDFileFieldGlobsReal::deepCpyGlobs(), MEDCoupling::MEDFileField1TS::New(), MEDCoupling::MCAuto< T >::retn(), and MEDCoupling::MEDFileFieldGlobsReal::shallowCpyGlobs().

MEDFileIntField1TS * MEDFileIntField1TS::shallowCpy ( ) const
virtual
MEDCouplingFieldInt * MEDFileIntField1TS::field ( const MEDFileMesh mesh) const

This is the simplest version to fetch a field for MED structure. One drawback : if this is a complex field (multi spatial discretization inside a same field) this method will throw exception and more advance method should be called (getFieldOnMeshAtLevel for example). But for normal usage of field in MED file world this method is the most efficient to fetch data.

Parameters
[in]mesh- the mesh the field is lying on
Returns
MEDCouplingFieldInt * - a new instance of MEDCouplingFieldInt. The caller is to delete this field using decrRef() as it is no more needed.

References MEDCoupling::MCAuto< T >::retn(), and SetDataArrayDoubleInIntField().

MEDCouplingFieldInt * MEDFileIntField1TS::getFieldAtLevel ( TypeOfField  type,
int  meshDimRelToMax,
int  renumPol = 0 
) const
MEDCouplingFieldInt * MEDFileIntField1TS::getFieldAtTopLevel ( TypeOfField  type,
int  renumPol = 0 
) const

Returns a new MEDCouplingFieldInt of a given type lying on the top level cells of the first mesh in MED file. If this field has not been constructed via file reading, an exception is thrown. For more info, see Dealing with Fields with advanced API.

Parameters
[in]type- a spatial discretization of interest.
[in]renumPol- specifies how to permute values of the result field according to the optional numbers of cells and nodes, if any. The valid values are
  • 0 - do not permute.
  • 1 - permute cells.
  • 2 - permute nodes.
  • 3 - permute cells and nodes.
Returns
MEDCouplingFieldInt * - a new instance of MEDCouplingFieldDouble. The caller is to delete this field using decrRef() as it is no more needed.
Exceptions
Ifthis field has not been constructed via file reading.
Ifthe MED file is not readable.
Ifthere is no mesh in the MED file.
Ifno field values of the given type.
Ifno field values lying on the top level support.
See Also
getFieldAtLevel()

References MEDCoupling::MEDFileFieldGlobsReal::getFileName(), MEDCoupling::MCAuto< T >::retn(), and SetDataArrayDoubleInIntField().

MEDCouplingFieldInt * MEDFileIntField1TS::getFieldOnMeshAtLevel ( TypeOfField  type,
int  meshDimRelToMax,
const MEDFileMesh mesh,
int  renumPol = 0 
) const

Returns a new MEDCouplingFieldInt of a given type lying on a given support. For more info, see Dealing with Fields with advanced API.

Parameters
[in]type- a spatial discretization of interest.
[in]meshDimRelToMax- a relative dimension of the supporting mesh entities.
[in]mesh- the supporting mesh.
[in]renumPol- specifies how to permute values of the result field according to the optional numbers of cells and nodes, if any. The valid values are
  • 0 - do not permute.
  • 1 - permute cells.
  • 2 - permute nodes.
  • 3 - permute cells and nodes.
Returns
MEDCouplingFieldInt * - a new instance of MEDCouplingFieldDouble. The caller is to delete this field using decrRef() as it is no more needed.
Exceptions
Ifthere are no mesh entities of meshDimRelToMax dimension in the mesh.
Ifno field of this is lying on mesh.
Ifno field values of the given type or given meshDimRelToMax are available.
See Also
getFieldAtLevel()
getFieldOnMeshAtLevel()

References MEDCoupling::MCAuto< T >::retn(), and SetDataArrayDoubleInIntField().

Referenced by getFieldOnMeshAtLevel().

MEDCouplingFieldInt * MEDFileIntField1TS::getFieldOnMeshAtLevel ( TypeOfField  type,
const MEDCouplingMesh mesh,
int  renumPol = 0 
) const

Returns a new MEDCouplingFieldInt of given type lying on a given mesh. For more info, see Dealing with Fields with advanced API.

Parameters
[in]type- a spatial discretization of the new field.
[in]mesh- the supporting mesh.
[in]renumPol- specifies how to permute values of the result field according to the optional numbers of cells and nodes, if any. The valid values are
  • 0 - do not permute.
  • 1 - permute cells.
  • 2 - permute nodes.
  • 3 - permute cells and nodes.
Returns
MEDCouplingFieldInt * - a new instance of MEDCouplingFieldDouble. The caller is to delete this field using decrRef() as it is no more needed.
Exceptions
Ifno field of this is lying on mesh.
Ifthe mesh is empty.
Ifno field values of the given type are available.
See Also
getFieldAtLevel()
getFieldOnMeshAtLevel()

References getFieldOnMeshAtLevel(), MEDCoupling::MCAuto< T >::retn(), and SetDataArrayDoubleInIntField().

MEDCouplingFieldInt * MEDFileIntField1TS::getFieldAtLevelOld ( TypeOfField  type,
const std::string &  mname,
int  meshDimRelToMax,
int  renumPol = 0 
) const

Returns a new MEDCouplingFieldDouble of a given type lying on a given support. This method is called "Old" because in MED3 norm a field has only one meshName attached, so this method is for readers of MED2 files. If this field has not been constructed via file reading, an exception is thrown. For more info, see Dealing with Fields with advanced API.

Parameters
[in]type- a spatial discretization of interest.
[in]mName- a name of the supporting mesh.
[in]meshDimRelToMax- a relative dimension of the supporting mesh entities.
[in]renumPol- specifies how to permute values of the result field according to the optional numbers of cells and nodes, if any. The valid values are
  • 0 - do not permute.
  • 1 - permute cells.
  • 2 - permute nodes.
  • 3 - permute cells and nodes.
Returns
MEDCouplingFieldInt * - a new instance of MEDCouplingFieldDouble. The caller is to delete this field using decrRef() as it is no more needed.
Exceptions
Ifthe MED file is not readable.
Ifthere is no mesh named mName in the MED file.
Ifthere are no mesh entities of meshDimRelToMax dimension in the mesh.
Ifthis field has not been constructed via file reading.
Ifno field of this is lying on the mesh named mName.
Ifno field values of the given type or given meshDimRelToMax are available.
See Also
getFieldAtLevel()

References MEDCoupling::MEDFileAnyTypeField1TSWithoutSDA::getFieldAtLevel(), MEDCoupling::MEDFileFieldGlobsReal::getFileName(), MEDCoupling::MCAuto< T >::retn(), and SetDataArrayDoubleInIntField().

DataArrayInt * MEDFileIntField1TS::getFieldWithProfile ( TypeOfField  type,
int  meshDimRelToMax,
const MEDFileMesh mesh,
DataArrayInt *&  pfl 
) const

Returns values and a profile of the field of a given type lying on a given support. For more info, see Dealing with Fields with advanced API.

Parameters
[in]type- a spatial discretization of the field.
[in]meshDimRelToMax- a relative dimension of the supporting mesh entities.
[in]mesh- the supporting mesh.
[out]pfl- a new instance of DataArrayInt holding ids of mesh entities the field of interest lies on. If the field lies on all entities of the given dimension, all ids in pfl are zero. The caller is to delete this array using decrRef() as it is no more needed.
Returns
DataArrayInt * - a new instance of DataArrayInt holding values of the field. The caller is to delete this array using decrRef() as it is no more needed.
Exceptions
Ifthere are no mesh entities of meshDimRelToMax dimension in mesh.
Ifno field of this is lying on mesh.
Ifno field values of the given type or given meshDimRelToMax are available.

References MEDCoupling::MEDFileAnyTypeField1TSWithoutSDA::getFieldWithProfile(), and ReturnSafelyDataArrayInt().

void MEDFileIntField1TS::setFieldNoProfileSBT ( const MEDCouplingFieldInt field)

Adds a MEDCouplingFieldInt to this. The underlying mesh of the given field is checked if its elements are sorted suitable for writing to MED file ("STB" stands for "Sort By Type"), if not, an exception is thrown. For more info, see Dealing with Fields with advanced API.

Parameters
[in]field- the field to add to this.
Exceptions
Ifthe name of field is empty.
Ifthe data array of field is not set.
Ifthe data array is already allocated but has different number of components than field.
Ifthe underlying mesh of field has no name.
Ifelements in the mesh are not in the order suitable for writing to the MED file.

References ConvertFieldIntToFieldDouble(), MEDCoupling::MEDCouplingFieldT< T >::getArray(), MEDCoupling::MEDFileAnyTypeField1TSWithoutSDA::setFieldNoProfileSBT(), and MEDCoupling::MEDFileFieldGlobsReal::setFileName().

void MEDFileIntField1TS::setFieldProfile ( const MEDCouplingFieldInt field,
const MEDFileMesh mesh,
int  meshDimRelToMax,
const DataArrayInt profile 
)

Adds a MEDCouplingFieldInt to this. As described in Main concepts of MED files a field in MED file sense can be an aggregation of several MEDCouplingFieldDouble instances. The mesh support of input parameter field is ignored here, it can be NULL. The support of field field is expected to be those computed with the input parameter mesh, meshDimRelToMax, and profile.

This method will check that the field based on the computed support is coherent. If not an exception will be thrown. A new profile is added only if no equal profile is missing. For more info, see Dealing with Fields with advanced API.

Parameters
[in]field- the field to add to this.
[in]mesh- the supporting mesh of field.
[in]meshDimRelToMax- a relative dimension of mesh entities field lies on (useless if field spatial discretization is ON_NODES).
[in]profile- ids of mesh entities on which corresponding field values lie.
Exceptions
Ifeither field or mesh or profile has an empty name.
Ifthere are no mesh entities of meshDimRelToMax dimension in mesh.
Ifthe data array of field is not set.
Ifthe data array of this is already allocated but has different number of components than field.
Ifelements in mesh are not in the order suitable for writing to the MED file.
See Also
setFieldNoProfileSBT()

References ConvertFieldIntToFieldDouble(), MEDCoupling::MEDCouplingFieldT< T >::getArray(), MEDCoupling::MEDFileAnyTypeField1TSWithoutSDA::setFieldProfile(), and MEDCoupling::MEDFileFieldGlobsReal::setFileName().

DataArrayInt * MEDFileIntField1TS::getUndergroundDataArray ( ) const
MEDFileIntField1TS * MEDFileIntField1TS::extractPart ( const std::map< int, MCAuto< DataArrayInt > > &  extractDef,
MEDFileMesh mm 
) const
virtual