24#ifndef _GEMA_HDF5_MODEL_READER_H_
25#define _GEMA_HDF5_MODEL_READER_H_
129 : _d(0), _nGeometryNodes(0), _nGhostNodes(0), _nCells(0), _nPSets(0),
130 _nCellNodes(0), _nGhostCells(0), _nInactiveCells(0) {}
139 const MeshInfo* setCurrentMesh(
QString mesh,
bool meshInfo,
bool bcInfo,
bool dsInfo,
const GmPCR* pcr);
146 int* type,
int* propertySets,
int* nodes,
int* cellsPerType)
const;
147 bool loadAndSetMeshGhostCells (
GmCellMesh* mesh)
const;
148 bool loadAndSetMeshInactiveCells(
GmCellMesh* mesh)
const;
149 bool loadCellGroupData (
int groupIndex,
int* data,
int* realNumCells)
const;
150 bool loadNodeSetData (
int groupIndex,
int* data,
int* realNumNodes)
const;
157 bool loadBcApplicationPoints(
int bcIndex,
const GmMesh* mesh,
int* data,
QVector<int>& skipList)
const;
160 bool loadDsCoordinateData(
int dsIndex,
int dIndex,
double* data)
const;
161 bool loadDsBorderData (
int dsIndex,
int dIndex,
const GmCellMesh* mesh,
int* data,
int* realNumCells)
const;
162 bool loadDsTriangleData (
int dsIndex,
int dIndex,
int* data)
const;
165 bool loadSharedDictionariesInfo();
177 int checkTableLayout(
QString tablePath,
int ncol,
const H5::DataType& type,
bool required,
178 int* nlines = NULL,
int* ncolumns = NULL)
const;
180 bool loadDictionary(DictionaryType type,
QStringList& data,
bool required)
const;
181 bool loadDictionary(DictionaryType type,
QVector<DicInfo>& data,
bool required)
const;
183 bool loadDictionaryData(
int groupIndex, GroupType group,
QVector<DicInfo>& dictionary,
int* data)
const;
185 bool loadAccessorData(
const AttrInfo& attrInfo, GroupType group,
QString subGroupName,
GmValueAccessor* ac,
The GmBoundaryConditionAccessor class is a proxy object to a value accesor implementing a more conven...
Definition gmBoundaryConditionAccessor.h:74
BcType
Boundary condition type defining where a BC is applied (node, edge or face)
Definition gmBoundaryCondition.h:62
The GmCellAccessor class is a proxy object to a value accesor implementing a more convenient interfac...
Definition gmCellAccessor.h:67
Base interface class for CellMesh type plugins.
Definition gmCellMesh.h:40
DiscontinuityType
Discontinuity type (defining how the disc. geometry is defined)
Definition gmDiscontinuitySet.h:63
The GmGaussAccessor class is a proxy object to a value accessor implementing a more convenient interf...
Definition gmGaussAccessor.h:39
A helper class with enums and methods common to GmHdf5ModelWriter & GmHdf5ModelReader.
Definition gmHdf5Model.h:36
QString groupName(QString meshName, GroupType group, QString subGroupName) const
Returns the group name for the given mesh / group type. If type is GM_HDF5MODEL_BC_GROUP or GM_HDF5MO...
Definition gmHdf5Model.cpp:61
GroupType
Definition gmHdf5Model.h:58
A helper class used to parse and retrieve data from am hdf5 model file. Used by the mesh plugin to re...
Definition gmHdf5ModelReader.h:53
const GmPCR * _defPcr
Set to an identity GmDefaultPCR object when the user didn't gave us his own PCR object.
Definition gmHdf5ModelReader.h:202
const MeshInfo * currentMeshInfo() const
Returns the current mesh information structure. Equal to the pointer returned on the last call to set...
Definition gmHdf5ModelReader.h:142
const GmPCR * _pcr
The PCR object used to translate indices for the current mesh. Will point to either the user given pc...
Definition gmHdf5ModelReader.h:201
bool isFunctionValue(double v) const
Returns true if v stores a nan encoded function value index.
Definition gmHdf5ModelReader.h:189
QString _currentMesh
The current mesh set by setCurrentMesh()
Definition gmHdf5ModelReader.h:198
H5::H5File * _fileh
The hdf5 file handle.
Definition gmHdf5ModelReader.h:197
QString _fileName
The saved file name.
Definition gmHdf5ModelReader.h:194
const GmLogCategory & _logger
The logger used to emmit error messages.
Definition gmHdf5ModelReader.h:195
unsigned nanToDindex(double v) const
Returns the encoded index into the given nan encoded value.
Definition gmHdf5ModelReader.h:192
QString groupName(GroupType group, QString subGroupName) const
Returns the group name for the given group type. If type is GM_HDF5MODEL_BC_GROUP or GM_HDF5MODEL_DS_...
Definition gmHdf5ModelReader.h:175
QString fileName() const
Returns the file name.
Definition gmHdf5ModelReader.h:136
MeshInfo * _info
The current mesh info data.
Definition gmHdf5ModelReader.h:199
Class representing a category with multiple logging levels.
Definition gmLog.h:58
A Gauss index interface always indexing ALL the elements of a mesh, with support for mesh growing.
Definition gmGaussIndex.h:275
Base interface class for Mesh type plugins.
Definition gmMesh.h:48
A helper class to store an usigned index as the boxed nan value.
Definition gmNanBoxedValue.h:78
bool isIndex() const
Is this a User function pointer value?
Definition gmNanBoxedValue.h:107
unsigned toIndex() const
Returns the stored value as an index.
Definition gmNanBoxedValue.h:110
Base interface class for Partition-Color-Renumber object plugins.
Definition gmPCR.h:54
Interface class for accessing and setting values from an "indexable" collection of values.
Definition gmValueAccessor.h:60
Declaration of the GmBoundaryCondition class.
Declaration of the GmCellBoundary class.
GmCellBoundaryType
Cell boundary type.
Definition gmCellBoundary.h:31
#define GMC_API_EXPORT
Macro for controlling if the class is being exported (GEMA_CORE_LIB defined) or imported (GEMA_CORE_L...
Definition gmCoreConfig.h:35
Implementation of the GmDiscontinuitySet class.
Declaration of the GmHdf5Model class.
Declaration of support functions and macros for information logging.
Declaration of the GmNanBoxedValue class.
Aux structure with information for a data attribute.
Definition gmHdf5ModelReader.h:68
int _d
The dimension of each value.
Definition gmHdf5ModelReader.h:72
int _n
The number of attribute values.
Definition gmHdf5ModelReader.h:71
QString _name
The attribute name.
Definition gmHdf5ModelReader.h:69
bool _functions
Does the data has encoded NAN "function" references?
Definition gmHdf5ModelReader.h:73
int _state
The attribute state (0 for current, 1 for first old and so on)
Definition gmHdf5ModelReader.h:70
Aux structure with information abou a boundary condition.
Definition gmHdf5ModelReader.h:78
QString _name
The boundary condition name.
Definition gmHdf5ModelReader.h:79
int _d
The number of columns in the application points table (really depends only on _type,...
Definition gmHdf5ModelReader.h:82
GmBoundaryCondition::BcType _type
The boundary condition type.
Definition gmHdf5ModelReader.h:80
int _n
The number of boundary condition lines (application point lines)
Definition gmHdf5ModelReader.h:81
QVector< AttrInfo > _attrData
Information on each associated attribute.
Definition gmHdf5ModelReader.h:83
Aux structure with information for dictionary tables with associated data sets.
Definition gmHdf5ModelReader.h:61
QString _name
The dictionary entry name.
Definition gmHdf5ModelReader.h:62
int _n
The number of "objects" (cell ids, node ids or border definitions) tied to this entry.
Definition gmHdf5ModelReader.h:63
Aux structure with information about a discontinuity.
Definition gmHdf5ModelReader.h:88
int _n1
The number of coordinate values for polyline or surface type. The number of borders for edge or face ...
Definition gmHdf5ModelReader.h:90
QString _name
The discontinuity name.
Definition gmHdf5ModelReader.h:89
int _n2
The coord dimension for polyline type. The number of triangles for surface type. 0 for edge or face l...
Definition gmHdf5ModelReader.h:91
Aux structure with information about a discontinuity set.
Definition gmHdf5ModelReader.h:96
GmDiscontinuitySet::DiscontinuityType _type
The discontinuity set type.
Definition gmHdf5ModelReader.h:98
QVector< DiscInfo > _discData
Information on each associated discontinuity.
Definition gmHdf5ModelReader.h:99
QString _name
The discontinuity set name.
Definition gmHdf5ModelReader.h:97
General mesh information (only the "metadata" is loaded - table contents are not loaded,...
Definition gmHdf5ModelReader.h:104
int _nGhostCells
The number of cells that have ghost nodes.
Definition gmHdf5ModelReader.h:111
QVector< AttrInfo > _gaussInitialData
Information regarding gauss initial values.
Definition gmHdf5ModelReader.h:123
QVector< DicInfo > _cellGroupsDictionary
The set of stored cell groups together with the number of cells in each group.
Definition gmHdf5ModelReader.h:116
int _nGeometryNodes
The number of geometry nodes.
Definition gmHdf5ModelReader.h:106
QVector< DicInfo > _boundaryFacesDictionary
The set of stored boundary faces together with the number of faces in each group.
Definition gmHdf5ModelReader.h:119
int _nCells
The number of cells in the mesh.
Definition gmHdf5ModelReader.h:108
int _nCellNodes
The sum of the number of each cell's nodes.
Definition gmHdf5ModelReader.h:110
QVector< DicInfo > _boundaryEdgesDictionary
The set of stored boundary edges together with the number of edges in each group.
Definition gmHdf5ModelReader.h:118
int _d
The mesh dimension.
Definition gmHdf5ModelReader.h:105
QVector< AttrInfo > _nodeInitialData
Information regarding node initial values.
Definition gmHdf5ModelReader.h:121
int _nPSets
The number of property sets tied to this mesh (equal to _propertySetsDictionary.size())
Definition gmHdf5ModelReader.h:109
QStringList _propertySetsDictionary
The set of stored mesh property sets.
Definition gmHdf5ModelReader.h:115
QVector< AttrInfo > _cellInitialData
Information regarding cell initial values.
Definition gmHdf5ModelReader.h:122
int _nGhostNodes
The number of ghost nodes.
Definition gmHdf5ModelReader.h:107
int _nInactiveCells
The number of inactive cells.
Definition gmHdf5ModelReader.h:112
QVector< DicInfo > _nodeSetsDictionary
The set of stored node groups together with the number of nodes in each group.
Definition gmHdf5ModelReader.h:117
QStringList _functionsDictionary
The set of stored functions.
Definition gmHdf5ModelReader.h:114