std::basic_string< CepsChar > CepsString
C++ format string.
std::vector< _Type, _Alloc > CepsVector
C++ vector.
std::make_unsigned_t< CepsInt > CepsUInt
Unsigned version on CepsInt.
int32_t CepsInt
Need 32 bit integer.
Base class that regroups common reader functionalities.
Abstract base class that encapsulates primary functionalities of each mesh reader.
CepsInt m_nodesBegin
line start of nodes
CepsUInt m_nbAttrPerCell
attributes per cell
CepsUInt getNbCellsRead() const
Number of cells that have been read until now.
virtual void readNodes(CepsUInt indexStart, CepsUInt indexEnd, CepsUInt nodeOffset, CepsVector< CepsReal > &coords, CepsVector< CepsAttribute > &attr, CepsVector< CepsUInt > &attrPtr)=0
Reads several nodes in mesh file.
virtual CepsInt getNbAttributesPerCell() const
Number of attributes per cell.
CepsUInt getNbNodes() const
Number of nodes of current mesh.
CepsBool m_initialized
Flag to ensure call of initializeReader()
void checkCanReadNodes(CepsUInt indexStart, CepsUInt indexEnd) const
Aborts if passed indices are wrong.
MeshReader()=delete
Deleted default constructor.
CepsUInt m_nbNodesPerBdryCell
nb nodes per boundary cell
virtual void readCells(CepsUInt indexStart, CepsUInt indexEnd, CepsUInt nodeOffset, CepsUInt cellOffset, CepsVector< CepsNodeGlobalIndex > &nodeIndices, CepsVector< CepsUInt > &nodeIndicesPtr, CepsVector< CepsAttribute > &cellAttr, CepsVector< CepsUInt > &cellAttrPtr, CepsVector< CepsChar > &isBoundaryCell)=0
Reads several cells in mesh file.
CepsBool m_quads
Reader for quadratic cells.
CepsUInt m_bdryCellsRead
Keeps track of already read boundary cells.
~MeshReader() override
Destructor.
CepsUInt m_nbNodesPerCell
nb nodes per cell
CepsUInt getNbBdryCells() const
Number of boundary cell of current mesh.
virtual CepsInt getNbAttributesPerBdryCell() const
Number of attributes per boundary cell.
CepsUInt m_nbBdryCells
number of boundary cells in mesh, appropriate for dimension
CepsUInt getNbCells() const
Number of cell of current mesh.
CepsUInt m_nbAttrPerBdryCell
attributes per boundary cell
CepsUInt m_cellsRead
Keeps track of already read cells.
CepsUInt m_nbAttrPerNode
attributes per node
virtual CepsInt getNbAttributesPerNode() const
Number of attributes per node.
virtual CepsBool checkExtension() const
Stop if extension is not ok, extension must be defined in child classes.
CepsInt m_cellsBegin
line start of cells
CepsUInt m_expectedDim
Expected dimension of mesh.
CepsUInt m_nbCellsTotal
number of all cells in file
CepsInt m_bdryCellsBegin
line start of boundary cells
CepsString m_extension
File name extension.
CepsUInt m_nbNodes
number of nodes in mesh
CepsUInt getNbBdryCellsRead() const
Number of boundary cells that have been read.
CepsUInt m_nbCells
number of cells in mesh, appropriate for dimension
virtual void initialize()=0
The routine MUST set the number of nodes and cells.
virtual void getNextCell(CepsUInt cellId, CepsUInt fileCellId, CepsUInt nodeOffset, CepsVector< CepsNodeGlobalIndex > &nodeIndices, CepsVector< CepsUInt > &nodeIndicesPtr, CepsVector< CepsAttribute > &cellAttr, CepsVector< CepsUInt > &cellAttrPtr, CepsVector< CepsChar > &isBoundaryCell, CepsBool boundaryFlag)=0
Reads a single cell in mesh file.
void checkCanReadCells(CepsUInt indexStart, CepsUInt indexEnd) const
Aborts if passed indices are wrong.