GemaMesh
The GeMA Mesh Plugin
Public Member Functions | Public Attributes | Private Member Functions | List of all members
GmpGemaMeshData< Vector > Struct Template Reference

Auxiliar structure used to share data between GmpGemaMesh and GmpMeshLoader. More...

#include <gmpGemaMeshData.h>

Inheritance diagram for GmpGemaMeshData< Vector >:
Inheritance graph
[legend]
Collaboration diagram for GmpGemaMeshData< Vector >:
Collaboration graph
[legend]

Public Member Functions

 GmpGemaMeshData (GmMesh *mesh)
 Constructor.
 
virtual ~GmpGemaMeshData ()
 Virtual destructor.
 
virtual int addFirstNodes (GmMesh *mesh, int numAddedNodes, int numGhostNodes, QList< GmValueInfo * > infoList=QList< GmValueInfo * >())
 
virtual int addNewNodes (GmMesh *mesh, int numAddedNodes)
 
virtual void clear (GmMesh *mesh)
 Removes all mesh nodes + removes all values from node based value sets, preserving object state so that future node addition can be made.
 
virtual void releaseMemory ()
 Releases all the memory DIRECTLY owned by the object.
 
virtual int numNodes () const
 
virtual size_t nodeMemory () const
 Returns the approximate memory used for storing mesh nodes.
 
virtual bool addStateGeometryData (GmStateDump *state, int groupId)
 Adds to the state an item storing node set nodes followed by an item storing node coordinates.
 
virtual bool fillDumpControlMapData (GmMesh *mesh, QVariantMap *map, const GmLogCategory &logger)
 Stores the Gema mesh data control info on the stored map.
 
virtual bool dumpControlMapDataLoaded (GmMesh *mesh, QVariantMap *map, const GmLogCategory &logger)
 Loads the map data into the object + adjusts vector sizes if necessary.
 
- Public Member Functions inherited from GmpMeshData< Vector >
 GmpMeshData (GmMesh *mesh)
 Constructor. The unused mesh parameter is a helper to the Surface Mesh code.
 
virtual ~GmpMeshData ()
 Virtual destructor.
 
virtual bool setCoordinateDimension (int ncoord)
 
int addFirstGhostNodes (GmMesh *mesh, int numAddedNodes, QList< GmValueInfo * > infoList)
 
int addNewGhostNodes (GmMesh *mesh, int numAddedNodes)
 
bool ghostEnabled ()
 
void setGhostEnabled (bool state)
 
int numGhostNodes () const
 
virtual size_t nodeSetsMemory () const
 Returns the approximate memory used for storing mesh node sets.
 
void setGhostCoordinatesData (int nodeIndex, int coordId, double coordVal)
 Updates a ghost node cooridnate.
 
bool addNodeValueSets (GmMesh *mesh, QList< GmValueInfo * > infoList, int numAddedNodes, int numGhostNodes, bool ghost)
 Adds new value sets to the mesh as specified by infoList. The ownership of the list metadata is transferred to the mesh. The gven number of nodes is used to initialize the set sizes. If ghost is false, expects that the affected nodes on the list includes only geometry or both entries. If ghost is true, the list should include ghost and both entries, with the later ones not added to the mesh. In this case, numAddedNodes should be zero.
 
bool resizeValueSets (const QList< GmValueSet * > &valueSets, int numAddedNodes)
 Resizes the given set of value sets adding the specified number of nodes. Either all the sets are resized (and the function returns true), or none are (and the function returns false). Can cope with NULL values in the list. Expects the non-NULL value sets to have the same size.
 

Public Attributes

int _numNodes
 Number of nodes in the mesh.
 
Vector< double > _coordinates
 Coordinate vector. Size = _coordInfo->size() * _numNodes. Values stored by node.
 
- Public Attributes inherited from GmpMeshData< Vector >
GmValueInfo_coordInfo
 Information about node coordinates.
 
bool _ghostEnabled
 Are ghost nodes enabled for this mesh?
 
int _numGhostNodes
 The number of mesh ghost nodes.
 
Vector< double > _ghostCoordinates
 Coordinate vector for ghost nodes. Size = _coordInfo->size() * _numGhostNodes. Values stored by node.
 
QMap< QString, GmNodeSet * > _nodeSets
 A map with the definition of each node set associated with the mesh. Map entries are instances of the GmpGemaNodeSet class.
 
GmStateDump_state
 

Private Member Functions

void releaseMeshNodes ()
 Releases memory owned directly by this class, without releasing memory owned by the base class.
 

Additional Inherited Members

- Public Types inherited from GmpMeshData< Vector >
template<typename U >
using VectorType = Vector< U >
 A type identifying which vector type we are using.
 

Detailed Description

template<template< class > class Vector>
struct GmpGemaMeshData< Vector >

Auxiliar structure used to share data between GmpGemaMesh and GmpMeshLoader.


The documentation for this struct was generated from the following files: