#include <FemlabMeshReader.hpp>
Public Member Functions | |
FemlabMeshReader (std::string pathBaseName, std::string nodeFileName, std::string elementFileName, std::string edgeFileName) | |
virtual | ~FemlabMeshReader () |
Private Member Functions | |
std::vector< std::vector < double > > | TokenizeStringsToDoubles (std::vector< std::string > rawData) |
std::vector< std::vector < unsigned > > | TokenizeStringsToInts (std::vector< std::string > rawData, unsigned dimensionOfObject) |
Definition at line 44 of file FemlabMeshReader.hpp.
FemlabMeshReader< ELEMENT_DIM, SPACE_DIM >::FemlabMeshReader | ( | std::string | pathBaseName, | |
std::string | nodeFileName, | |||
std::string | elementFileName, | |||
std::string | edgeFileName | |||
) | [inline] |
The constructor takes the path to and names of a set of Femlab mesh files (ie. the node, elements and face files (in that order) and allows the data to be queried. Typical use: AbstractMeshReader *pMeshReader=new FemlabMeshReader( "pdes/tests/meshdata/", "femlab_lshape_nodes.dat", "femlab_lshape_elements.dat", "femlab_lshape_edges.dat",);
Definition at line 72 of file FemlabMeshReader.hpp.
References AbstractCachedMeshReader< ELEMENT_DIM, SPACE_DIM >::GetRawDataFromFile(), AbstractCachedMeshReader< ELEMENT_DIM, SPACE_DIM >::mElementData, AbstractCachedMeshReader< ELEMENT_DIM, SPACE_DIM >::mElementRawData, AbstractCachedMeshReader< ELEMENT_DIM, SPACE_DIM >::mFaceData, AbstractCachedMeshReader< ELEMENT_DIM, SPACE_DIM >::mFaceRawData, AbstractCachedMeshReader< ELEMENT_DIM, SPACE_DIM >::mNodeData, AbstractCachedMeshReader< ELEMENT_DIM, SPACE_DIM >::mNodeRawData, AbstractCachedMeshReader< ELEMENT_DIM, SPACE_DIM >::mpElementIterator, AbstractCachedMeshReader< ELEMENT_DIM, SPACE_DIM >::mpFaceIterator, AbstractCachedMeshReader< ELEMENT_DIM, SPACE_DIM >::mpNodeIterator, FemlabMeshReader< ELEMENT_DIM, SPACE_DIM >::TokenizeStringsToDoubles(), and FemlabMeshReader< ELEMENT_DIM, SPACE_DIM >::TokenizeStringsToInts().
FemlabMeshReader< ELEMENT_DIM, SPACE_DIM >::~FemlabMeshReader | ( | ) | [inline, virtual] |
Destructor
Definition at line 235 of file FemlabMeshReader.hpp.
std::vector< std::vector< double > > FemlabMeshReader< ELEMENT_DIM, SPACE_DIM >::TokenizeStringsToDoubles | ( | std::vector< std::string > | rawData | ) | [inline, private] |
TokenizeStringsToDoubles is specific to reading node data which came from a Femlab or Matlab PDE toolbox file.
Each string is expected to be a series of doubles. Return value is a vector where each item is a vector of double which represents position. Indices are implicit in the vector.
Definition at line 122 of file FemlabMeshReader.hpp.
Referenced by FemlabMeshReader< ELEMENT_DIM, SPACE_DIM >::FemlabMeshReader().
std::vector< std::vector< unsigned > > FemlabMeshReader< ELEMENT_DIM, SPACE_DIM >::TokenizeStringsToInts | ( | std::vector< std::string > | rawData, | |
unsigned | dimensionOfObject | |||
) | [inline, private] |
TokenizeStringsToInts is for reading element, face or edge data which came from a Femlab or Matlab PDE toolbox file. Each string is expected to be a series of unsigned which represent: The first several lines denote the indices of nodes The rest contains extra information which are ignored currently. ( In 2-D: 2 indices for an edge, 3 for a triangle) ( In 3-D: 3 indices for a face, 4 for a tetrahedron) Return value is a vector where each item is a vector of ints which represents indices of nodes.
Definition at line 188 of file FemlabMeshReader.hpp.
Referenced by FemlabMeshReader< ELEMENT_DIM, SPACE_DIM >::FemlabMeshReader().