Fesapi  2.0.0.0
This project provides C++ classes which allow an easy access in import and export to the Energistics standards.
Public Member Functions | Static Public Attributes | List of all members
resqml2_2::UnstructuredGridRepresentation Class Referencefinal

An unstructured grid representation. This class cannot be inherited. More...

#include <UnstructuredGridRepresentation.h>

Inheritance diagram for resqml2_2::UnstructuredGridRepresentation:
resqml2::UnstructuredGridRepresentation resqml2::AbstractGridRepresentation resqml2::AbstractRepresentation common::AbstractObject

Public Member Functions

 UnstructuredGridRepresentation (gsoap_resqml2_0_1::eml20__DataObjectReference *partialObject)
 
 UnstructuredGridRepresentation (common::DataObjectRepository *repo, const std::string &guid, const std::string &title, uint64_t cellCount)
 Constructor. More...
 
 UnstructuredGridRepresentation (resqml2::AbstractFeatureInterpretation *interp, const std::string &guid, const std::string &title, uint64_t cellCount)
 Constructor. More...
 
 UnstructuredGridRepresentation (gsoap_eml2_3::_resqml22__UnstructuredGridRepresentation *fromGsoap)
 Creates an instance of this class by wrapping a gsoap instance. More...
 
 ~UnstructuredGridRepresentation ()=default
 
bool hasGeometry () const final
 
common::DataObjectReference getHdfProxyDor () const final
 Gets the data object reference of the HDF proxy which is used for storing the numerical values of this representation (i.e. its geometry). More...
 
void getXyzPointsOfPatch (unsigned int patchIndex, double *xyzPoints) const final
 Gets all the xyz points of a particular patch of this representation. xyz points are given in the local CRS. More...
 
void getFaceIndicesOfCells (uint64_t *faceIndices) const final
 
void getCumulativeFaceCountPerCell (uint64_t *cumulativeFaceCountPerCell_) const final
 
bool isFaceCountOfCellsConstant () const final
 
unsigned int getConstantFaceCountOfCells () const final
 
void getNodeIndicesOfFaces (uint64_t *nodeIndices) const final
 
void getCumulativeNodeCountPerFace (uint64_t *nodeCountPerFace) const final
 
bool isNodeCountOfFacesConstant () const final
 
unsigned int getConstantNodeCountOfFaces () const final
 
uint64_t getCellCount () const final
 
uint64_t getFaceCount () const final
 
uint64_t getNodeCount () const final
 
void getCellFaceIsRightHanded (unsigned char *cellFaceIsRightHanded) const final
 
void setGeometryUsingExistingDatasets (const std::string &cellFaceIsRightHanded, const std::string &points, uint64_t pointCount, eml2::AbstractHdfProxy *proxy, const std::string &faceIndicesPerCell, const std::string &faceIndicesCumulativeCountPerCell, uint64_t faceCount, const std::string &nodeIndicesPerFace, const std::string &nodeIndicesCumulativeCountPerFace, gsoap_resqml2_0_1::resqml20__CellShape cellShape, resqml2::AbstractLocal3dCrs *localCrs=nullptr) final
 
std::string getXmlNamespace () const final
 
- Public Member Functions inherited from resqml2::UnstructuredGridRepresentation
 UnstructuredGridRepresentation (gsoap_resqml2_0_1::eml20__DataObjectReference *partialObject)
 
 UnstructuredGridRepresentation ()
 
 UnstructuredGridRepresentation (gsoap_resqml2_0_1::_resqml20__UnstructuredGridRepresentation *fromGsoap)
 
 UnstructuredGridRepresentation (gsoap_eml2_3::_resqml22__UnstructuredGridRepresentation *fromGsoap)
 
uint64_t getXyzPointCountOfPatch (unsigned int patchIndex) const final
 
uint64_t const * getCumulativeFaceCountPerCell () const
 
void getFaceCountPerCell (uint64_t *faceCountPerCell) const
 
void getNodeCountPerFace (uint64_t *nodeCountPerFace) const
 
void loadGeometry ()
 
void unloadGeometry ()
 
unsigned int getFaceCountOfCell (uint64_t cellIndex) const
 
unsigned int getNodeCountOfFaceOfCell (uint64_t cellIndex, unsigned int localFaceIndex) const
 
uint64_t const * getNodeIndicesOfFaceOfCell (uint64_t cellIndex, unsigned int localFaceIndex) const
 
void setGeometry (unsigned char *cellFaceIsRightHanded, double *points, uint64_t pointCount, eml2::AbstractHdfProxy *proxy, uint64_t *faceIndicesPerCell, uint64_t *faceIndicesCumulativeCountPerCell, uint64_t faceCount, uint64_t *nodeIndicesPerFace, uint64_t *nodeIndicesCumulativeCountPerFace, gsoap_resqml2_0_1::resqml20__CellShape cellShape, resqml2::AbstractLocal3dCrs *localCrs=nullptr)
 
void setTetrahedraOnlyGeometryUsingExistingDatasets (const std::string &cellFaceIsRightHanded, const std::string &points, uint64_t pointCount, uint64_t faceCount, eml2::AbstractHdfProxy *proxy, const std::string &faceIndicesPerCell, const std::string &nodeIndicesPerFace, resqml2::AbstractLocal3dCrs *localCrs=nullptr)
 Sets a geometry which is only defined by means of tetrahedra using some existing HDF5 dataset. More...
 
void setTetrahedraOnlyGeometry (unsigned char *cellFaceIsRightHanded, double *points, uint64_t pointCount, uint64_t faceCount, eml2::AbstractHdfProxy *proxy, uint64_t *faceIndicesPerCell, uint64_t *nodeIndicesPerFace, resqml2::AbstractLocal3dCrs *localCrs=nullptr)
 Sets a geometry which is only defined by means of tetrahedra and creates corresponding HDF5 datasets. More...
 
void setHexahedraOnlyGeometryUsingExistingDatasets (const std::string &cellFaceIsRightHanded, const std::string &points, uint64_t pointCount, uint64_t faceCount, eml2::AbstractHdfProxy *proxy, const std::string &faceIndicesPerCell, const std::string &nodeIndicesPerFace, resqml2::AbstractLocal3dCrs *localCrs=nullptr)
 
void setHexahedraOnlyGeometry (unsigned char *cellFaceIsRightHanded, double *points, uint64_t pointCount, uint64_t faceCount, eml2::AbstractHdfProxy *proxy, uint64_t *faceIndicesPerCell, uint64_t *nodeIndicesPerFace, resqml2::AbstractLocal3dCrs *localCrs=nullptr)
 
unsigned int getPatchCount () const final
 
virtual std::string getXmlTag () const final
 
- Public Member Functions inherited from resqml2::AbstractGridRepresentation
virtual ~AbstractGridRepresentation ()=default
 
std::vector< class GridConnectionSetRepresentation * > getGridConnectionSetRepresentationSet () const
 
unsigned int getGridConnectionSetRepresentationCount () const
 
class GridConnectionSetRepresentationgetGridConnectionSetRepresentation (unsigned int index) const
 
AbstractGridRepresentationgetParentGrid () const
 
common::DataObjectReference getParentGridDor () const
 
std::vector< resqml2::AbstractGridRepresentation * > getChildGridSet () const
 
unsigned int getChildGridCount () const
 
AbstractGridRepresentationgetChildGrid (unsigned int index) const
 
void setParentWindow (uint64_t *cellIndices, uint64_t cellIndexCount, class UnstructuredGridRepresentation *parentGrid, eml2::AbstractHdfProxy *proxy=nullptr)
 
void setParentWindow (unsigned int *columnIndices, unsigned int columnIndexCount, unsigned int kLayerIndexRegridStart, unsigned int *childCellCountPerInterval, unsigned int *parentCellCountPerInterval, unsigned int intervalCount, class AbstractColumnLayerGridRepresentation *parentGrid, eml2::AbstractHdfProxy *proxy=nullptr, double *childCellWeights=nullptr)
 
void setParentWindow (unsigned int iCellIndexRegridStart, unsigned int *childCellCountPerIInterval, unsigned int *parentCellCountPerIInterval, unsigned int iIntervalCount, unsigned int jCellIndexRegridStart, unsigned int *childCellCountPerJInterval, unsigned int *parentCellCountPerJInterval, unsigned int jIntervalCount, unsigned int kCellIndexRegridStart, unsigned int *childCellCountPerKInterval, unsigned int *parentCellCountPerKInterval, unsigned int kIntervalCount, class AbstractIjkGridRepresentation *parentGrid, eml2::AbstractHdfProxy *proxy=nullptr, double *iChildCellWeights=nullptr, double *jChildCellWeights=nullptr, double *kChildCellWeights=nullptr)
 
void setParentWindow (unsigned int iCellIndexRegridStart, unsigned int constantChildCellCountPerIInterval, unsigned int constantParentCellCountPerIInterval, unsigned int iIntervalCount, unsigned int jCellIndexRegridStart, unsigned int constantChildCellCountPerJInterval, unsigned int constantParentCellCountPerJInterval, unsigned int jIntervalCount, unsigned int kCellIndexRegridStart, unsigned int constantChildCellCountPerKInterval, unsigned int constantParentCellCountPerKInterval, unsigned int kIntervalCount, class AbstractIjkGridRepresentation *parentGrid, eml2::AbstractHdfProxy *proxy=nullptr, double *iChildCellWeights=nullptr, double *jChildCellWeights=nullptr, double *kChildCellWeights=nullptr)
 Indicates that this grid takes place into another IJK parent grid. This method assumes that the count of cells per regrid interval is constant in both child and parent grids. More...
 
void setParentWindow (unsigned int iCellIndexRegridStart, unsigned int iChildCellCount, unsigned int iParentCellCount, unsigned int jCellIndexRegridStart, unsigned int jChildCellCount, unsigned int jParentCellCount, unsigned int kCellIndexRegridStart, unsigned int kChildCellCount, unsigned int kParentCellCount, class AbstractIjkGridRepresentation *parentGrid, eml2::AbstractHdfProxy *proxy=nullptr, double *iChildCellWeights=nullptr, double *jChildCellWeights=nullptr, double *kChildCellWeights=nullptr)
 
void setForcedNonRegridedParentCell (uint64_t *cellIndices, uint64_t cellIndexCount)
 
void setCellOverlap (uint64_t parentChildCellPairCount, uint64_t *parentChildCellPair, const std::string &volumeUom, double *overlapVolumes=nullptr)
 
int64_t getParentCellIndexCount () const
 
void getParentCellIndices (uint64_t *parentCellIndices) const
 
int64_t getParentColumnIndexCount () const
 
void getParentColumnIndices (uint64_t *parentColumnIndices) const
 
uint64_t getRegridStartIndexOnParentGrid (char dimension) const
 
uint64_t getRegridIntervalCount (char dimension) const
 
bool isRegridCellCountPerIntervalConstant (char dimension, bool childVsParentCellCount) const
 
uint64_t getRegridConstantCellCountPerInterval (char dimension, bool childVsParentCellCount) const
 
void getRegridCellCountPerInterval (char dimension, uint64_t *childCellCountPerInterval, bool childVsParentCellCount) const
 
bool hasRegridChildCellWeights (char dimension) const
 
void getRegridChildCellWeights (char dimension, double *childCellWeights) const
 
bool hasForcedNonRegridedParentCell () const
 
void setCellAssociationWithStratigraphicOrganizationInterpretation (uint64_t *stratiUnitIndices, uint64_t nullValue, class AbstractStratigraphicOrganizationInterpretation *stratiOrgInterp)
 
class AbstractStratigraphicOrganizationInterpretationgetStratigraphicOrganizationInterpretation () const
 
virtual common::DataObjectReference getStratigraphicOrganizationInterpretationDor () const
 
bool hasCellStratigraphicUnitIndices () const
 
uint64_t getCellStratigraphicUnitIndices (uint64_t *stratiUnitIndices)
 
void setCellAssociationWithRockFluidOrganizationInterpretation (uint64_t *rockFluidUnitIndices, uint64_t nullValue, class RockFluidOrganizationInterpretation *rockFluidOrgInterp)
 
class RockFluidOrganizationInterpretationgetRockFluidOrganizationInterpretation () const
 
virtual common::DataObjectReference getRockFluidOrganizationInterpretationDor () const
 
bool hasCellFluidPhaseUnitIndices () const
 
uint64_t getCellFluidPhaseUnitIndices (uint64_t *rockfluidUnitIndices)
 
bool isTruncated () const
 
uint64_t getTruncatedFaceCount () const
 
void getNodeIndicesOfTruncatedFaces (uint64_t *nodeIndices) const
 
void getCumulativeNodeCountPerTruncatedFace (uint64_t *nodeCountPerFace) const
 
void getNodeCountPerTruncatedFace (uint64_t *nodeCountPerFace) const
 
uint64_t getTruncatedCellCount () const
 
void getTruncatedCellIndices (uint64_t *cellIndices) const
 
void getTruncatedFaceIndicesOfTruncatedCells (uint64_t *faceIndices) const
 
void getCumulativeTruncatedFaceCountPerTruncatedCell (uint64_t *cumulativeFaceCountPerCell) const
 
void getTruncatedFaceCountPerTruncatedCell (uint64_t *faceCountPerCell) const
 
void getNonTruncatedFaceIndicesOfTruncatedCells (uint64_t *faceIndices) const
 
void getCumulativeNonTruncatedFaceCountPerTruncatedCell (uint64_t *cumulativeFaceCountPerCell) const
 
void getNonTruncatedFaceCountPerTruncatedCell (uint64_t *faceCountPerCell) const
 
void getTruncatedFaceIsRightHanded (unsigned char *cellFaceIsRightHanded) const
 
void loadTargetRelationships ()
 
- Public Member Functions inherited from resqml2::AbstractRepresentation
virtual ~AbstractRepresentation ()=default
 
class AbstractLocal3dCrsgetLocalCrs (unsigned int patchIndex) const
 
virtual common::DataObjectReference getLocalCrsDor (unsigned int patchIndex) const
 
std::vector< class AbstractProperty * > getPropertySet () const
 
void setInterpretation (class AbstractFeatureInterpretation *interp)
 
class AbstractFeatureInterpretationgetInterpretation () const
 
common::DataObjectReference getInterpretationDor () const
 
uint64_t getXyzPointCountOfAllPatches () const
 
void getXyzPointsOfPatchInGlobalCrs (unsigned int patchIndex, double *xyzPoints) const
 Gets all the xyz points of a particular patch of this representation. xyz points are given in the global CRS. More...
 
void getXyzPointsOfAllPatches (double *xyzPoints) const
 Gets all the xyz points of all patches of this representation. xyz points are given in the local CRS. More...
 
bool isInSingleLocalCrs () const
 
bool isInSingleGlobalCrs () const
 
void getXyzPointsOfAllPatchesInGlobalCrs (double *xyzPoints) const
 
AbstractRepresentationgetSeismicSupportOfPatch (const unsigned int &patchIndex) const
 
std::set< AbstractRepresentation * > getAllSeismicSupport () const
 
void pushBackIntoRepresentationSet (class RepresentationSetRepresentation *repSet)
 
void addSeismic3dCoordinatesToPatch (unsigned int patchIndex, double *inlines, double *crosslines, unsigned int pointCount, resqml2::AbstractRepresentation *seismicSupport, eml2::AbstractHdfProxy *proxy)
 
void addSeismic3dCoordinatesToPatch (unsigned int patchIndex, double startInline, double incrInline, unsigned int countInline, double startCrossline, double incrCrossline, unsigned int countCrossline, resqml2::AbstractRepresentation *seismicSupport)
 
void addSeismic2dCoordinatesToPatch (unsigned int patchIndex, double *lineAbscissa, resqml2::AbstractRepresentation *seismicSupport, eml2::AbstractHdfProxy *proxy)
 
void getSeismicLineAbscissaOfPointsOfPatch (unsigned int patchIndex, double *values) const
 
void getInlinesOfPointsOfPatch (unsigned int patchIndex, double *values) const
 
void getCrosslinesOfPointsOfPatch (unsigned int patchIndex, double *values) const
 
- Public Member Functions inherited from common::AbstractObject
bool isPartial () const
 
virtual bool isTopLevelElement () const
 
std::string getUuid () const
 
std::string getTitle () const
 
std::string getEditor () const
 
time_t getCreation () const
 
tm getCreationAsTimeStructure () const
 
std::string getOriginator () const
 
std::string getDescription () const
 
time_t getLastUpdate () const
 
tm getLastUpdateAsTimeStructure () const
 
std::string getFormat () const
 
std::string getDescriptiveKeywords () const
 
std::string getVersion () const
 
void setTitle (const std::string &title)
 
void setEditor (const std::string &editor)
 
void setCreation (time_t creation)
 
void setCreation (const tm &creation)
 
void setOriginator (const std::string &originator)
 
void setDescription (const std::string &description)
 
void setLastUpdate (time_t lastUpdate)
 
void setLastUpdate (const tm &lastUpdate)
 
void setDescriptiveKeywords (const std::string &descriptiveKeywords)
 
void setVersion (const std::string &version)
 
void setMetadata (const std::string &title, const std::string &editor, time_t creation, const std::string &originator, const std::string &description, time_t lastUpdate, const std::string &descriptiveKeywords)
 
void serializeIntoStream (std::ostream *stream)
 
void setGsoapProxy (gsoap_resqml2_0_1::eml20__AbstractCitedDataObject *gsoapProxy)
 
void setGsoapProxy (gsoap_eml2_1::eml21__AbstractObject *gsoapProxy)
 
gsoap_resqml2_0_1::eml20__AbstractCitedDataObject * getEml20GsoapProxy () const
 
gsoap_eml2_1::eml21__AbstractObject * getEml21GsoapProxy () const
 
gsoap_eml2_2::eml22__AbstractObject * getEml22GsoapProxy () const
 
void setGsoapProxy (gsoap_eml2_2::eml22__AbstractObject *gsoapProxy)
 
gsoap_eml2_3::eml23__AbstractObject * getEml23GsoapProxy () const
 
void setGsoapProxy (gsoap_eml2_3::eml23__AbstractObject *gsoapProxy)
 
soap * getGsoapContext () const
 
int getGsoapType () const
 
gsoap_resqml2_0_1::eml20__DataObjectReference * newResqmlReference () const
 
gsoap_eml2_1::eml21__DataObjectReference * newEmlReference () const
 
gsoap_eml2_2::eml22__DataObjectReference * newEml22Reference () const
 
gsoap_eml2_3::eml23__DataObjectReference * newEml23Reference () const
 
gsoap_resqml2_0_1::resqml20__ContactElementReference * newContactElementReference2_0_1 () const
 
gsoap_eml2_3::resqml22__ContactElement * newContactElementReference2_2 () const
 
common::DataObjectRepositorygetRepository () const
 
virtual std::string getXmlNamespaceVersion () const
 
virtual std::string getContentType () const
 
virtual std::string getQualifiedType () const
 
virtual std::string getPartNameInEpcDocument () const
 
std::string serializeIntoString ()
 
void addAlias (const std::string &authority, const std::string &title)
 
unsigned int getAliasCount () const
 
std::string getAliasAuthorityAtIndex (unsigned int index) const
 
std::string getAliasTitleAtIndex (unsigned int index) const
 
std::vector< eml2::Activity * > getActivitySet () const
 
unsigned int getActivityCount () const
 
eml2::ActivitygetActivity (unsigned int index) const
 
void pushBackExtraMetadata (const std::string &key, const std::string &value)
 
std::unordered_map< std::string, std::string > getExtraMetadataSet () const
 
std::vector< std::string > getExtraMetadata (const std::string &key) const
 
unsigned int getExtraMetadataCount () const
 
std::string getExtraMetadataKeyAtIndex (unsigned int index) const
 
std::string getExtraMetadataStringValueAtIndex (unsigned int index) const
 

Static Public Attributes

static const char * XML_NS
 
- Static Public Attributes inherited from resqml2::UnstructuredGridRepresentation
static const char * XML_TAG
 
- Static Public Attributes inherited from resqml2::AbstractGridRepresentation
static const char * XML_TAG
 
- Static Public Attributes inherited from resqml2::AbstractRepresentation
static const char * XML_TAG
 

Additional Inherited Members

- Public Types inherited from resqml2::AbstractRepresentation
enum  indexableElement {
  NODE = 0 , EDGE = 1 , FACE = 2 , VOLUME = 3 ,
  PILLAR = 4
}
 
- Public Types inherited from common::AbstractObject
enum  hdfDatatypeEnum {
  UNKNOWN = 0 , DOUBLE = 1 , FLOAT = 2 , LONG_64 = 3 ,
  ULONG_64 = 4 , INT = 5 , UINT = 6 , SHORT = 7 ,
  USHORT = 8 , CHAR = 9 , UCHAR = 10
}
 
- Static Public Member Functions inherited from common::AbstractObject
static void setFormat (const std::string &vendor, const std::string &applicationName, const std::string &applicationVersionNumber)
 

Detailed Description

An unstructured grid representation. This class cannot be inherited.

Constructor & Destructor Documentation

◆ UnstructuredGridRepresentation() [1/4]

resqml2_2::UnstructuredGridRepresentation::UnstructuredGridRepresentation ( gsoap_resqml2_0_1::eml20__DataObjectReference *  partialObject)
inline

Only to be used in partial transfer context

◆ UnstructuredGridRepresentation() [2/4]

resqml2_2::UnstructuredGridRepresentation::UnstructuredGridRepresentation ( common::DataObjectRepository repo,
const std::string &  guid,
const std::string &  title,
uint64_t  cellCount 
)

Constructor.

Parameters
[in]repoThe soap context where the underlying gsoap proxy is going to be created.
guidUnique identifier.
titleThe title.
cellCountNumber of cells.

◆ UnstructuredGridRepresentation() [3/4]

resqml2_2::UnstructuredGridRepresentation::UnstructuredGridRepresentation ( resqml2::AbstractFeatureInterpretation interp,
const std::string &  guid,
const std::string &  title,
uint64_t  cellCount 
)

Constructor.

Parameters
[in]interpIf non-nullptr, the interp.
guidUnique identifier.
titleThe title.
cellCountNumber of cells.

◆ UnstructuredGridRepresentation() [4/4]

resqml2_2::UnstructuredGridRepresentation::UnstructuredGridRepresentation ( gsoap_eml2_3::_resqml22__UnstructuredGridRepresentation *  fromGsoap)
inline

Creates an instance of this class by wrapping a gsoap instance.

Parameters
[in]fromGsoapIf non-nullptr, from gsoap.

◆ ~UnstructuredGridRepresentation()

resqml2_2::UnstructuredGridRepresentation::~UnstructuredGridRepresentation ( )
virtualdefault

Destructor does nothing since the memory is managed by the gsoap context.

Reimplemented from resqml2::UnstructuredGridRepresentation.

Member Function Documentation

◆ getCellCount()

uint64_t resqml2_2::UnstructuredGridRepresentation::getCellCount ( ) const
finalvirtual

Gets the count of (volumetric) cells in the grid.

Exceptions
std::range_errorIf the cell count is strictly greater than unsigned int max.
std::logic_errorIf this grid is partial.
Returns
The cell count.

Implements resqml2::UnstructuredGridRepresentation.

◆ getCellFaceIsRightHanded()

void resqml2_2::UnstructuredGridRepresentation::getCellFaceIsRightHanded ( unsigned char *  cellFaceIsRightHanded) const
finalvirtual

Gets the orientation of each cell face. That is to say tells for each cell face, if its face normal defined using a right hand rule is outwardly directed.

Exceptions
std::logic_errorIf this grid is partial.
std::logic_errorIf the geometry is not loaded.
std::logic_errorIf the data structure used to store the orientation of the cell is not already supported by fesapi.
Parameters
[out]cellFaceIsRightHandedPreallocated array for receiving the orientation of each cell face. The size is the last value returned by getCumulativeFaceCountPerCell().

Implements resqml2::UnstructuredGridRepresentation.

◆ getConstantFaceCountOfCells()

unsigned int resqml2_2::UnstructuredGridRepresentation::getConstantFaceCountOfCells ( ) const
finalvirtual

Gets the constant face count per cell in this unstructured grid.

Exceptions
std::logic_errorIf the face count per cell is not constant (please check the constantness of the face count per cell with isFaceCountOfCellsConstant() before calling this method).
std::logic_errorIf this grid is partial.
std::logic_errorIf this grid has no geometry (please check the existence of a geometry thanks to hasGeometry() before calling this method).
std::range_errorIf the cumulative face count per cell is stored in an integer constant array while there is more than one cell in this grid.
Returns
The constant face count per cell.

Implements resqml2::UnstructuredGridRepresentation.

◆ getConstantNodeCountOfFaces()

unsigned int resqml2_2::UnstructuredGridRepresentation::getConstantNodeCountOfFaces ( ) const
finalvirtual

Gets the constant node count per face in this unstructured grid.

Exceptions
std::logic_errorIf the node count per face is not constant (please check the constantness of the node count per face with isNodeCountOfFacesConstant() before calling this method).
std::logic_errorIf this grid is partial.
std::logic_errorIf this grid has no geometry (please check the existence of a geometry thanks to hasGeometry() before calling this method).
Returns
The constant node count per face.

Implements resqml2::UnstructuredGridRepresentation.

◆ getCumulativeFaceCountPerCell()

void resqml2_2::UnstructuredGridRepresentation::getCumulativeFaceCountPerCell ( uint64_t *  cumulativeFaceCountPerCell_) const
finalvirtual

Gets the cumulative face count per cell. A single face count should be at least 4.

Exceptions
std::logic_errorIf this grid is partial.
std::logic_errorIf this grid has no geometry (please check the existence of a geometry thanks to hasGeometry() before calling this method).
std::invalid_argumentIf a required HDF proxy is missing.
std::range_errorIf the cumulative face count per cell is stored in an integer constant array while there is more than one cell in this grid.
Parameters
[out]cumulativeFaceCountPerCell_Preallocated array of size getCellCount() to receive the cumulative face count per cell. First value is the count of faces in the first cell. Second value is the count of faces in the first and in the second cell. Third value is the count of faces in the first and in the second and in the third cell. And so on.

Implements resqml2::UnstructuredGridRepresentation.

◆ getCumulativeNodeCountPerFace()

void resqml2_2::UnstructuredGridRepresentation::getCumulativeNodeCountPerFace ( uint64_t *  nodeCountPerFace) const
finalvirtual

Gets the cumulative node count per face. A single node count should be at least 3.

Exceptions
std::logic_errorIf this grid is partial.
std::logic_errorIf this grid has no geometry (please check the existence of a geometry thanks to hasGeometry() before calling this method).
std::invalid_argumentIf a required HDF proxy is missing.
std::range_errorIf the cumulative node count per face is stored in a integer constant array.
Parameters
[out]nodeCountPerFacePreallocated array to receive the cumulative node count per face. Its size must be getFaceCount(). First value is the count of nodes in the first face. Second value is the count of nodes in the first and in the second face. Third value is the count of nodes in the first and in the second and in the third face. And so on.

Implements resqml2::UnstructuredGridRepresentation.

◆ getFaceCount()

uint64_t resqml2_2::UnstructuredGridRepresentation::getFaceCount ( ) const
finalvirtual

Gets the face count

Exceptions
std::logic_errorIf this grid is partial.
Returns
The face count.

Implements resqml2::UnstructuredGridRepresentation.

◆ getFaceIndicesOfCells()

void resqml2_2::UnstructuredGridRepresentation::getFaceIndicesOfCells ( uint64_t *  faceIndices) const
finalvirtual

Gets all the face indices of all the cells.

Exceptions
std::logic_errorIf this grid is partial.
std::logic_errorIf this grid has no geometry (please check the existence of a geometry thanks to hasGeometry() before calling this method).
std::logic_errorIf the data structure used to store the face indices of the cells is not already supported by fesapi.
std::invalid_argumentIf a required HDF proxy is missing.
Parameters
[out]faceIndicesPreallocated array to receive all the face indices of all the cells. It size must be the last value outputted by getCumulativeFaceCountPerCell(). It is ordered first by faces and then by cells.

Implements resqml2::UnstructuredGridRepresentation.

◆ getHdfProxyDor()

common::DataObjectReference resqml2_2::UnstructuredGridRepresentation::getHdfProxyDor ( ) const
finalvirtual

Gets the data object reference of the HDF proxy which is used for storing the numerical values of this representation (i.e. its geometry).

Exceptions
std::logic_errorIf this representation is partial.
Returns
The data object reference of the HDF proxy used for storing the geometry, or empty data object reference if it fails.

Implements resqml2::AbstractRepresentation.

◆ getNodeCount()

uint64_t resqml2_2::UnstructuredGridRepresentation::getNodeCount ( ) const
finalvirtual

Get the node count

Exceptions
std::logic_errorIf this grid is partial.
Returns
The node count.

Implements resqml2::UnstructuredGridRepresentation.

◆ getNodeIndicesOfFaces()

void resqml2_2::UnstructuredGridRepresentation::getNodeIndicesOfFaces ( uint64_t *  nodeIndices) const
finalvirtual

Gets all the node indices of all the faces.

Exceptions
std::logic_errorIf this grid is partial.
std::logic_errorIf this grid has no geometry (please check the existence of a geometry thanks to hasGeometry() before calling this method).
std::logic_errorIf the data structure used to store the node indices of the faces is not already supported by fesapi.
std::invalid_argumentIf a required HDF proxy is missing.
Parameters
[out]nodeIndicesPreallocated array to receive all the node indices of all the faces. It size must be the last value outputted by getCumulativeNodeCountPerFace(). It is ordered first by nodes, then by faces and then by cells.

Implements resqml2::UnstructuredGridRepresentation.

◆ getXmlNamespace()

std::string resqml2_2::UnstructuredGridRepresentation::getXmlNamespace ( ) const
inlinefinalvirtual

Get the standard XML namespace for serializing this data object.

Implements common::AbstractObject.

◆ getXyzPointsOfPatch()

void resqml2_2::UnstructuredGridRepresentation::getXyzPointsOfPatch ( unsigned int  patchIndex,
double *  xyzPoints 
) const
finalvirtual

Gets all the xyz points of a particular patch of this representation. xyz points are given in the local CRS.

Exceptions
std::out_of_rangeIf patchIndex is out of range.
std::logic_errorIf this representation is partial.
Parameters
patchIndexZero-based index of the patch from which we look for the xyz points.
[out]xyzPointsA linearized 2d array where the first (quickest) dimension is the coordinate dimension (x, y or z) and second dimension is vertex dimension. It must be preallocated with a size of 3 * getXyzPointCountOfPatch(patchIndex).

Implements resqml2::AbstractRepresentation.

◆ hasGeometry()

bool resqml2_2::UnstructuredGridRepresentation::hasGeometry ( ) const
finalvirtual

Indicates whether this grid has a geometry or not.

Returns
True if this grid has a geometry, false if not.

Implements resqml2::UnstructuredGridRepresentation.

◆ isFaceCountOfCellsConstant()

bool resqml2_2::UnstructuredGridRepresentation::isFaceCountOfCellsConstant ( ) const
finalvirtual

Checks whether the face count per cell is constant in this unstructured grid.

Exceptions
std::logic_errorIf this grid is partial.
std::logic_errorIf this grid has no geometry (please check the existence of a geometry thanks to hasGeometry() before calling this method).
std::range_errorIf the cumulative face count per cell is stored in an integer constant array while there is more than one cell in this grid.
Returns
True if the face count per cell is constant, false if not.

Implements resqml2::UnstructuredGridRepresentation.

◆ isNodeCountOfFacesConstant()

bool resqml2_2::UnstructuredGridRepresentation::isNodeCountOfFacesConstant ( ) const
finalvirtual

Checks whether the node count per face is constant in this unstructured grid.

Exceptions
std::logic_errorIf this grid is partial.
std::logic_errorIf this grid has no geometry (please check the existence of a geometry thanks to hasGeometry() before calling this method).
Returns
True if the node count per face is constant, false if not.

Implements resqml2::UnstructuredGridRepresentation.

◆ setGeometryUsingExistingDatasets()

void resqml2_2::UnstructuredGridRepresentation::setGeometryUsingExistingDatasets ( const std::string &  cellFaceIsRightHanded,
const std::string &  points,
uint64_t  pointCount,
eml2::AbstractHdfProxy proxy,
const std::string &  faceIndicesPerCell,
const std::string &  faceIndicesCumulativeCountPerCell,
uint64_t  faceCount,
const std::string &  nodeIndicesPerFace,
const std::string &  nodeIndicesCumulativeCountPerFace,
gsoap_resqml2_0_1::resqml20__CellShape  cellShape,
resqml2::AbstractLocal3dCrs localCrs = nullptr 
)
finalvirtual

Sets the geometry using some existing HDF5 dataset.

Exceptions
std::logic_errorIf this grid is partial.
std::invalid_argumentIf cellFaceIsRightHanded, points, faceIndicesPerCell, faceIndicesCumulativeCountPerCell, nodeIndicesPerFace or nodeIndicesCumulativeCountPerFace is empty.
std::invalid_argumentIf proxy == nullptr and no default HDF proxy is defined in the repository.
std::invalid_argumentIf localCrs == nullptr and no default local CRS is defined in the repository.
Parameters
cellFaceIsRightHandedThe path to the HDF5 dataset in the HDF proxy where a boolean mask is used to indicate which cell faces have an outwardly directed normal following a right hand rule. Array length is the sum of the cell face count per cell, and the data follows the order of the faces per cell RESQMLlist-of-lists.
pointsThe path to the HDF5 dataset in the HDF proxy where all the xyz points defining the nodes of the unstructured grid are defined. There must a double count of pointCount * 3.
pointCountThe count of points defining the nodes of this unstructured grid.
[in,out]proxyThe HDF proxy which contains the datasets given in this method by means of paths. If nullptr, then the repository default HDF proxy will be used.
faceIndicesPerCellThe path to the HDF5 dataset in the HDF proxy where each item defines the index of the face of a cell. There must be a count of the last value in faceIndicesCumulativeCountPerCell.
faceIndicesCumulativeCountPerCellThe path to the HDF5 dataset in the HDF proxy where each item defines the cumulative count of faces. The count of this array must be equal to the count of cells in this unstructured grid. For example if the first cell a 4 faces, the second cell 5 faces and the third cell 6 faces then the array would be {4, 9, 15}.
faceCountThe count of faces in this unstructured grid. Be aware this count does not duplicate shared faces. Most of time, you have less faceCount than the last value of faceIndicesCumulativeCountPerCell which is the count of faces per cell.
nodeIndicesPerFaceThe path to the HDF5 dataset in the HDF proxy where each item defines the index of the node of a face. There must be a count of the last value in nodeIndicesCumulativeCountPerFace.
nodeIndicesCumulativeCountPerFaceThe path to the HDF5 dataset in the HDF proxy where each item defines the cumulative count of nodes. The count of this array must be equal to faceCount.
cellShapeA denormalization of the information which gives quick access to the most complex shape of polyhedron encountered in this unstructured grid.
[in]localCrs(Optional) The local CRS. If nullptr (default), then the repository default local CRS will be used.

Implements resqml2::UnstructuredGridRepresentation.

Member Data Documentation

◆ XML_NS

const char* resqml2_2::UnstructuredGridRepresentation::XML_NS
static

The standard XML namespace for serializing this data object.


The documentation for this class was generated from the following file: