Public Member Functions | |
int | copyTinyInfoFrom (const MEDCouplingFieldDouble *field) throw (INTERP_KERNEL::Exception) |
int | getDimension () const |
int | getIteration () const |
int | getOrder () const |
double | getTime (int &iteration, int &order) const |
void | setTime (double val, int iteration, int order) |
std::string | getName () const |
void | simpleRepr (int bkOffset, std::ostream &oss, int f1tsId) const |
const std::string & | getDtUnit () const |
std::string | getMeshName () const throw (INTERP_KERNEL::Exception) |
int | getMeshIteration () const throw (INTERP_KERNEL::Exception) |
int | getMeshOrder () const throw (INTERP_KERNEL::Exception) |
int | getNumberOfComponents () const |
void | simpleReprWithoutHeader (std::ostream &oss) const |
bool | isDealingTS (int iteration, int order) const |
std::pair< int, int > | getDtIt () const |
void | fillIteration (std::pair< int, int > &p) const |
void | fillTypesOfFieldAvailable (std::vector< TypeOfField > &types) const throw (INTERP_KERNEL::Exception) |
const std::vector< std::string > & | getInfo () const |
std::vector< std::string > & | getInfo () |
void | finishLoading (med_idt fid) throw (INTERP_KERNEL::Exception) |
virtual void | writeLL (med_idt fid) const throw (INTERP_KERNEL::Exception) |
std::vector< std::string > | getPflsReallyUsed2 () const |
std::vector< std::string > | getLocsReallyUsed2 () const |
std::vector< std::string > | getPflsReallyUsedMulti2 () const |
std::vector< std::string > | getLocsReallyUsedMulti2 () const |
void | changePflsRefsNamesGen2 (const std::vector< std::pair< std::vector< std::string >, std::string > > &mapOfModif) throw (INTERP_KERNEL::Exception) |
void | changeLocsRefsNamesGen2 (const std::vector< std::pair< std::vector< std::string >, std::string > > &mapOfModif) throw (INTERP_KERNEL::Exception) |
void | setFieldNoProfileSBT (const MEDCouplingFieldDouble *field, MEDFieldFieldGlobsReal &glob) throw (INTERP_KERNEL::Exception) |
void | setFieldProfile (const MEDCouplingFieldDouble *field, const MEDFileMesh *mesh, int meshDimRelToMax, const DataArrayInt *profile, MEDFieldFieldGlobsReal &glob) throw (INTERP_KERNEL::Exception) |
int | getNonEmptyLevels (const char *mname, std::vector< int > &levs) const throw (INTERP_KERNEL::Exception) |
std::vector< TypeOfField > | getTypesOfFieldAvailable () const throw (INTERP_KERNEL::Exception) |
std::vector< std::vector < std::pair< int, int > > > | getFieldSplitedByType (const char *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 throw (INTERP_KERNEL::Exception) |
std::vector< std::vector < DataArrayDouble * > > | getFieldSplitedByType2 (const char *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 throw (INTERP_KERNEL::Exception) |
MEDCouplingFieldDouble * | getFieldAtLevel (TypeOfField type, int meshDimRelToMax, const char *mName, int renumPol, const MEDFieldFieldGlobsReal *glob) const throw (INTERP_KERNEL::Exception) |
MEDCouplingFieldDouble * | getFieldOnMeshAtLevel (TypeOfField type, int meshDimRelToMax, int renumPol, const MEDFieldFieldGlobsReal *glob, const MEDFileMesh *mesh) const throw (INTERP_KERNEL::Exception) |
MEDCouplingFieldDouble * | getFieldAtTopLevel (TypeOfField type, const char *mName, int renumPol, const MEDFieldFieldGlobsReal *glob) const throw (INTERP_KERNEL::Exception) |
MEDCouplingFieldDouble * | getFieldOnMeshAtLevel (TypeOfField type, int renumPol, const MEDFieldFieldGlobsReal *glob, const MEDCouplingMesh *mesh, const DataArrayInt *cellRenum, const DataArrayInt *nodeRenum) const throw (INTERP_KERNEL::Exception) |
DataArrayDouble * | getFieldWithProfile (TypeOfField type, int meshDimRelToMax, const MEDFileMesh *mesh, DataArrayInt *&pfl, const MEDFieldFieldGlobsReal *glob) const throw (INTERP_KERNEL::Exception) |
DataArrayDouble * | getUndergroundDataArray () const throw (INTERP_KERNEL::Exception) |
DataArrayDouble * | getUndergroundDataArrayExt (std::vector< std::pair< std::pair< INTERP_KERNEL::NormalizedCellType, int >, std::pair< int, int > > > &entries) const throw (INTERP_KERNEL::Exception) |
MEDFileField1TSWithoutDAS () | |
DataArrayDouble * | getOrCreateAndGetArray () |
const DataArrayDouble * | getOrCreateAndGetArray () const |
![]() | |
bool | decrRef () const |
void | incrRef () const |
Static Public Member Functions | |
static MEDFileField1TSWithoutDAS * | New (const char *fieldName, int csit, int fieldtype, int iteration, int order, const std::vector< std::string > &infos) |
static void | CheckMeshDimRel (int meshDimRelToMax) throw (INTERP_KERNEL::Exception) |
static std::vector< int > | CheckSBTMesh (const MEDCouplingMesh *mesh) throw (INTERP_KERNEL::Exception) |
Protected Member Functions | |
int | addNewEntryIfNecessary (const MEDCouplingMesh *mesh) throw (INTERP_KERNEL::Exception) |
int | getMeshIdFromMeshName (const char *mName) const throw (INTERP_KERNEL::Exception) |
MEDFileFieldPerMeshPerTypePerDisc * | getLeafGivenMeshAndTypeAndLocId (const char *mName, INTERP_KERNEL::NormalizedCellType typ, int locId) throw (INTERP_KERNEL::Exception) |
const MEDFileFieldPerMeshPerTypePerDisc * | getLeafGivenMeshAndTypeAndLocId (const char *mName, INTERP_KERNEL::NormalizedCellType typ, int locId) const throw (INTERP_KERNEL::Exception) |
MEDFileField1TSWithoutDAS (const char *fieldName, int csit, int fieldtype, int iteration, int order, const std::vector< std::string > &infos) | |
![]() | |
RefCountObject () | |
RefCountObject (const RefCountObject &other) | |
virtual | ~RefCountObject () |
Protected Attributes | |
std::string | _dt_unit |
MEDCouplingAutoRefCountObjectPtr < DataArrayDouble > | _arr |
std::vector < MEDCouplingAutoRefCountObjectPtr < MEDFileFieldPerMesh > > | _field_per_mesh |
int | _csit |
int | _field_type |
int | _iteration |
int | _order |
double | _dt |
DAS is for Shared Data Arrays such as profiles.
|
protected |
MEDFileField1TSWithoutDAS::MEDFileField1TSWithoutDAS | ( | ) |
Referenced by New().
int MEDFileField1TSWithoutDAS::copyTinyInfoFrom | ( | const MEDCouplingFieldDouble * | field | ) | throw (INTERP_KERNEL::Exception) |
This method copyies tiny info but also preallocated the DataArrayDouble instance in this->_arr. This not allocated it allocates to the size of 'field' array. If already allocated it grows the array to the previous size + the size of the array of the input 'field'. This method returns the position (in tuple id) where to start to feed 'this->_arr'
References ParaMEDMEM::DataArray::getInfoOnComponents(), ParaMEDMEM::DataArray::getNumberOfComponents(), ParaMEDMEM::DataArray::getNumberOfTuples(), and ParaMEDMEM::DataArrayDouble::New().
int MEDFileField1TSWithoutDAS::getDimension | ( | ) | const |
This method returns the max dimension of 'this'. This method returns -2 if 'this' is empty, -1 if only nodes are defined.
References _field_per_mesh.
int ParaMEDMEM::MEDFileField1TSWithoutDAS::getIteration | ( | ) | const |
int ParaMEDMEM::MEDFileField1TSWithoutDAS::getOrder | ( | ) | const |
double ParaMEDMEM::MEDFileField1TSWithoutDAS::getTime | ( | int & | iteration, |
int & | order | ||
) | const |
Referenced by ParaMEDMEM::MEDFileFieldMultiTSWithoutDAS::getTimeSteps().
void ParaMEDMEM::MEDFileField1TSWithoutDAS::setTime | ( | double | val, |
int | iteration, | ||
int | order | ||
) |
std::string MEDFileField1TSWithoutDAS::getName | ( | ) | const |
References ParaMEDMEM::DataArray::getName(), and getOrCreateAndGetArray().
void MEDFileField1TSWithoutDAS::simpleRepr | ( | int | bkOffset, |
std::ostream & | oss, | ||
int | f1tsId | ||
) | const |
References _arr, _dt, _dt_unit, _field_per_mesh, _iteration, _order, ParaMEDMEM::DataArray::getInfoOnComponents(), ParaMEDMEM::DataArray::getName(), ParaMEDMEM::DataArray::getNumberOfTuples(), and ParaMEDMEM::DataArrayDouble::isAllocated().
Referenced by ParaMEDMEM::MEDFileFieldMultiTSWithoutDAS::simpleRepr().
const std::string& ParaMEDMEM::MEDFileField1TSWithoutDAS::getDtUnit | ( | ) | const |
std::string MEDFileField1TSWithoutDAS::getMeshName | ( | ) | const throw (INTERP_KERNEL::Exception) |
References _field_per_mesh.
int MEDFileField1TSWithoutDAS::getMeshIteration | ( | ) | const throw (INTERP_KERNEL::Exception) |
References _field_per_mesh.
int MEDFileField1TSWithoutDAS::getMeshOrder | ( | ) | const throw (INTERP_KERNEL::Exception) |
References _field_per_mesh.
int MEDFileField1TSWithoutDAS::getNumberOfComponents | ( | ) | const |
References ParaMEDMEM::DataArray::getNumberOfComponents(), and getOrCreateAndGetArray().
void ParaMEDMEM::MEDFileField1TSWithoutDAS::simpleReprWithoutHeader | ( | std::ostream & | oss | ) | const |
bool MEDFileField1TSWithoutDAS::isDealingTS | ( | int | iteration, |
int | order | ||
) | const |
References _iteration, and _order.
std::pair< int, int > MEDFileField1TSWithoutDAS::getDtIt | ( | ) | const |
References fillIteration().
void MEDFileField1TSWithoutDAS::fillIteration | ( | std::pair< int, int > & | p | ) | const |
References _iteration, and _order.
Referenced by getDtIt().
void MEDFileField1TSWithoutDAS::fillTypesOfFieldAvailable | ( | std::vector< TypeOfField > & | types | ) | const throw (INTERP_KERNEL::Exception) |
Referenced by getTypesOfFieldAvailable().
const std::vector< std::string > & MEDFileField1TSWithoutDAS::getInfo | ( | ) | const |
References ParaMEDMEM::DataArray::getInfoOnComponents(), and getOrCreateAndGetArray().
std::vector< std::string > & MEDFileField1TSWithoutDAS::getInfo | ( | ) |
References ParaMEDMEM::DataArray::getInfoOnComponents(), and getOrCreateAndGetArray().
|
static |
References MEDFileField1TSWithoutDAS().
Referenced by ParaMEDMEM::MEDFileFieldMultiTSWithoutDAS::finishLoading(), and getOrCreateAndGetArray().
void MEDFileField1TSWithoutDAS::finishLoading | ( | med_idt | fid | ) | throw (INTERP_KERNEL::Exception) |
Referenced by ParaMEDMEM::MEDFileFieldMultiTSWithoutDAS::finishLoading().
|
virtual |
std::vector< std::string > MEDFileField1TSWithoutDAS::getPflsReallyUsed2 | ( | ) | const |
References _field_per_mesh.
std::vector< std::string > MEDFileField1TSWithoutDAS::getLocsReallyUsed2 | ( | ) | const |
References _field_per_mesh.
std::vector< std::string > MEDFileField1TSWithoutDAS::getPflsReallyUsedMulti2 | ( | ) | const |
References _field_per_mesh.
std::vector< std::string > MEDFileField1TSWithoutDAS::getLocsReallyUsedMulti2 | ( | ) | const |
References _field_per_mesh.
void MEDFileField1TSWithoutDAS::changePflsRefsNamesGen2 | ( | const std::vector< std::pair< std::vector< std::string >, std::string > > & | mapOfModif | ) | throw (INTERP_KERNEL::Exception) |
References _field_per_mesh.
void MEDFileField1TSWithoutDAS::changeLocsRefsNamesGen2 | ( | const std::vector< std::pair< std::vector< std::string >, std::string > > & | mapOfModif | ) | throw (INTERP_KERNEL::Exception) |
References _field_per_mesh.
|
static |
|
static |
void MEDFileField1TSWithoutDAS::setFieldNoProfileSBT | ( | const MEDCouplingFieldDouble * | field, |
MEDFieldFieldGlobsReal & | glob | ||
) | throw (INTERP_KERNEL::Exception) |
SBT means Sort By Type. This method is the most basic method to assign field in this. Basic in sense that no renumbering is done. Underlying mesh in 'field' is globaly ignored except for type contiguous check.
References CheckSBTMesh(), and ParaMEDMEM::ON_NODES.
Referenced by ParaMEDMEM::MEDFileFieldMultiTS::appendFieldNoProfileSBT(), and ParaMEDMEM::MEDFileField1TS::setFieldNoProfileSBT().
void MEDFileField1TSWithoutDAS::setFieldProfile | ( | const MEDCouplingFieldDouble * | field, |
const MEDFileMesh * | mesh, | ||
int | meshDimRelToMax, | ||
const DataArrayInt * | profile, | ||
MEDFieldFieldGlobsReal & | glob | ||
) | throw (INTERP_KERNEL::Exception) |
Generalization of MEDFileField1TSWithoutDAS::setFieldNoProfileSBT method.
References ParaMEDMEM::ON_NODES.
Referenced by ParaMEDMEM::MEDFileFieldMultiTS::appendFieldProfile(), and ParaMEDMEM::MEDFileField1TS::setFieldProfile().
int MEDFileField1TSWithoutDAS::getNonEmptyLevels | ( | const char * | mname, |
std::vector< int > & | levs | ||
) | const throw (INTERP_KERNEL::Exception) |
This method has one input 'mname'. It can be null if the user is the general case where there is only one meshName lying on 'this' This method returns two things.
This method is designed for MEDFileField1TS instances that have a discritization ON_CELLS, ON_GAUSS_NE and ON_GAUSS. Only these 3 discretizations will be taken into account here.
If 'this' is empty this method will throw an INTERP_KERNEL::Exception. If there is only node fields defined in 'this' -1 is returned and 'levs' output parameter will be empty. In this case the caller has to know the underlying mesh it refers to. By defaut it is the level 0 of the corresponding mesh.
This method is usefull to make the link between meshDimension of the underlying mesh in 'this' and the levels on 'this'. It is possible (even if it is not common) that the highest level in 'this' were not equal to the meshDimension of the underlying mesh in 'this'.
Let's consider the typical following case :
In this case f1->getNonEmptyLevelsExt will return (3,[0,-2]) and f2->getNonEmptyLevelsExt will return (2,[0,-1])
To retrieve the highest level of f1 it should be done, f1->getFieldAtLevel(ON_CELLS,3-3+0);//absDim-meshDim+relativeLev To retrieve the lowest level of f1 it should be done, f1->getFieldAtLevel(ON_CELLS,3-3+(-2));//absDim-meshDim+relativeLev To retrieve the highest level of f2 it should be done, f1->getFieldAtLevel(ON_CELLS,2-3+0);//absDim-meshDim+relativeLev To retrieve the lowest level of f2 it should be done, f1->getFieldAtLevel(ON_CELLS,2-3+(-1));//absDim-meshDim+relativeLev
References INTERP_KERNEL::NORM_ERROR.
std::vector< TypeOfField > MEDFileField1TSWithoutDAS::getTypesOfFieldAvailable | ( | ) | const throw (INTERP_KERNEL::Exception) |
References fillTypesOfFieldAvailable().
std::vector< std::vector< std::pair< int, int > > > MEDFileField1TSWithoutDAS::getFieldSplitedByType | ( | const char * | 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 throw (INTERP_KERNEL::Exception) |
entry point for users that want to iterate into MEDFile DataStructure without any overhead.
References _field_per_mesh, and getMeshIdFromMeshName().
Referenced by ParaMEDMEM::MEDFileFieldMultiTSWithoutDAS::getFieldSplitedByType().
std::vector< std::vector< DataArrayDouble * > > MEDFileField1TSWithoutDAS::getFieldSplitedByType2 | ( | const char * | 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 throw (INTERP_KERNEL::Exception) |
entry point for users that want to iterate into MEDFile DataStructure with a reduced overhead because output arrays are extracted (created) specially for the call of this method. That's why the DataArrayDouble instance in returned vector of vector should be dealed by the caller.
References _arr, _field_per_mesh, and getMeshIdFromMeshName().
Referenced by ParaMEDMEM::MEDFileFieldMultiTSWithoutDAS::getFieldSplitedByType2().
MEDCouplingFieldDouble * MEDFileField1TSWithoutDAS::getFieldAtLevel | ( | TypeOfField | type, |
int | meshDimRelToMax, | ||
const char * | mName, | ||
int | renumPol, | ||
const MEDFieldFieldGlobsReal * | glob | ||
) | const throw (INTERP_KERNEL::Exception) |
MEDCouplingFieldDouble * MEDFileField1TSWithoutDAS::getFieldOnMeshAtLevel | ( | TypeOfField | type, |
int | meshDimRelToMax, | ||
int | renumPol, | ||
const MEDFieldFieldGlobsReal * | glob, | ||
const MEDFileMesh * | mesh | ||
) | const throw (INTERP_KERNEL::Exception) |
MEDCouplingFieldDouble * MEDFileField1TSWithoutDAS::getFieldAtTopLevel | ( | TypeOfField | type, |
const char * | mName, | ||
int | renumPol, | ||
const MEDFieldFieldGlobsReal * | glob | ||
) | const throw (INTERP_KERNEL::Exception) |
References getFieldOnMeshAtLevel(), and ParaMEDMEM::MEDFileMesh::New().
Referenced by ParaMEDMEM::MEDFileField1TS::getFieldAtTopLevel(), and ParaMEDMEM::MEDFileFieldMultiTS::getFieldAtTopLevel().
MEDCouplingFieldDouble * MEDFileField1TSWithoutDAS::getFieldOnMeshAtLevel | ( | TypeOfField | type, |
int | renumPol, | ||
const MEDFieldFieldGlobsReal * | glob, | ||
const MEDCouplingMesh * | mesh, | ||
const DataArrayInt * | cellRenum, | ||
const DataArrayInt * | nodeRenum | ||
) | const throw (INTERP_KERNEL::Exception) |
References ParaMEDMEM::RefCountObject::incrRef().
DataArrayDouble * MEDFileField1TSWithoutDAS::getFieldWithProfile | ( | TypeOfField | type, |
int | meshDimRelToMax, | ||
const MEDFileMesh * | mesh, | ||
DataArrayInt *& | pfl, | ||
const MEDFieldFieldGlobsReal * | glob | ||
) | const throw (INTERP_KERNEL::Exception) |
DataArrayDouble * MEDFileField1TSWithoutDAS::getUndergroundDataArray | ( | ) | const throw (INTERP_KERNEL::Exception) |
This method retrieves direct access to the underground ParaMEDMEM::DataArrayDouble instance. The returned array is not a newly created array so it should not be dealed by the caller. This method allows to the user a direct access to the values. This method is quite unusable if there is more than a nodal field or a cell field on single geometric cell type.
References _arr.
DataArrayDouble * MEDFileField1TSWithoutDAS::getUndergroundDataArrayExt | ( | std::vector< std::pair< std::pair< INTERP_KERNEL::NormalizedCellType, int >, std::pair< int, int > > > & | entries | ) | const throw (INTERP_KERNEL::Exception) |
This method returns an array that the caller must deal with (contrary to those returned by MEDFileField1TSWithoutDAS::getUndergroundDataArray method). The returned array is the result of the aggregation of all sub arrays stored in the MED file. So to allow the caller to select the output param 'entries' is returned. This output param is a vector of a pair of 2 pairs. The first pair of pair informs of the geometric type it refers to and the discretization id attached to it. The second pair of pair precise the range [begin,end) into the returned array. This method makes the hypothesis that the field lies only on one mesh. If it is not the case an exception will be thrown.
References _field_per_mesh.
Referenced by ParaMEDMEM::MEDFileFieldMultiTSWithoutDAS::getUndergroundDataArrayExt().
|
protected |
References ParaMEDMEM::DataArrayInt::begin(), and ParaMEDMEM::DataArrayInt::empty().
|
protected |
[in] | mName | specifies the underlying mesh name. This value can be pointer 0 for users that do not deal with fields on multi mesh. |
Referenced by getFieldSplitedByType(), and getFieldSplitedByType2().
|
protected |
[in] | mName | specifies the underlying mesh name. This value can be pointer 0 for users that do not deal with fields on multi mesh. |
[in] | typ | is for the geometric cell type (or INTERP_KERNEL::NORM_ERROR for node field) entry to find the right MEDFileFieldPerMeshPerTypePerDisc instance to set. |
[in] | locId | is the localization id to find the right MEDFileFieldPerMeshPerTypePerDisc instance to set. It corresponds to the position of pfls [std::distance(types.begin(),std::find(types.begin(),typ)] vector in MEDFileField1TSWithoutDAS::getFieldSplitedByType. For non gausspoints field users, the value is 0. |
|
protected |
[in] | mName | specifies the underlying mesh name. This value can be pointer 0 for users that do not deal with fields on multi mesh. |
[in] | typ | is for the geometric cell type (or INTERP_KERNEL::NORM_ERROR for node field) entry to find the right MEDFileFieldPerMeshPerTypePerDisc instance to set. |
[in] | locId | is the localization id to find the right MEDFileFieldPerMeshPerTypePerDisc instance to set. It corresponds to the position of pfls [std::distance(types.begin(),std::find(types.begin(),typ)] vector in MEDFileField1TSWithoutDAS::getFieldSplitedByType. For non gausspoints field users, the value is 0. |
DataArrayDouble * MEDFileField1TSWithoutDAS::getOrCreateAndGetArray | ( | ) |
Referenced by getInfo(), getName(), getNumberOfComponents(), and MEDFileField1TSWithoutDAS().
const DataArrayDouble * MEDFileField1TSWithoutDAS::getOrCreateAndGetArray | ( | ) | const |
References _arr, ParaMEDMEM::DataArrayDouble::New(), and New().
|
protected |
Referenced by simpleRepr().
|
protected |
Referenced by getFieldSplitedByType2(), getOrCreateAndGetArray(), getUndergroundDataArray(), and simpleRepr().
|
protected |
Referenced by changeLocsRefsNamesGen2(), changePflsRefsNamesGen2(), getDimension(), getFieldSplitedByType(), getFieldSplitedByType2(), getLocsReallyUsed2(), getLocsReallyUsedMulti2(), getMeshIteration(), getMeshName(), getMeshOrder(), getPflsReallyUsed2(), getPflsReallyUsedMulti2(), getUndergroundDataArrayExt(), and simpleRepr().
|
mutableprotected |
only useable on reading
|
mutableprotected |
only useable on reading. 0 is for float, 1 for int32, 2 for int64
|
protected |
Referenced by fillIteration(), isDealingTS(), and simpleRepr().
|
protected |
Referenced by fillIteration(), isDealingTS(), and simpleRepr().
|
protected |
Referenced by simpleRepr().