GemaCoreLib
The GeMA Core library
Public Member Functions | Private Attributes | List of all members
GmBoundaryConditionStateDumpItem Class Reference

An auxiliar class used to host the needed code for duming a boundary condition to a state dump. Its purpose os to avoid adding that code to the BC class itself. More...

#include <gmBoundaryCondition.h>

Inheritance diagram for GmBoundaryConditionStateDumpItem:
Inheritance graph
[legend]
Collaboration diagram for GmBoundaryConditionStateDumpItem:
Collaboration graph
[legend]

Public Member Functions

 GmBoundaryConditionStateDumpItem (GmBoundaryCondition *bc)
 Basic constructor.
 
virtual ~GmBoundaryConditionStateDumpItem ()
 Destructor.
 
virtual bool addStateItemsToGroup (GmStateDump *state, int groupId)
 Adds to 'state' a data item storing a control map followed by the set of data items needed for recovering application points (depending on the bc type) and then by the available value sets. More...
 
virtual bool fillDumpControlMapData (QVariantMap *map, const GmLogCategory &logger)
 Fill the control map with data just before the BC being saved. It also prepares the translation map and additional buffers that will be saved by their own dump items after the control map.
 
virtual bool dumpControlMapDataLoaded (QVariantMap *map, const GmLogCategory &logger)
 Sanity checks + processing of the dump control data map after a load operation for preparing the buffers used to read the application point data, together with BcNodeSet / BcCellBoundary objects.
 
virtual bool stateLoaded (GmStateDump *state)
 Method called after the whole BC item has been loaded. Used to adjust the application point data according to the translation map.
 
- Public Member Functions inherited from GmGroupDumpItem
virtual ~GmGroupDumpItem ()
 Virtual destructor.
 
virtual bool stateAboutToBeSaved (GmStateDump *state)
 Virtual method called just before starting a save operation on the given state. Returning false aborts the operation.
 
virtual bool stateSaved (GmStateDump *state)
 Virtual method called just after succesfully completing a save operation on the given state. Returning false aborts the operation.
 
virtual bool stateAboutToBeLoaded (GmStateDump *state)
 Virtual method called just before starting a load operation on the given state. Returning false aborts the operation.
 

Private Attributes

GmBoundaryCondition_bc
 The boundary condition.
 
QVariantMap _controlMap
 Variant map used for storing the dump control data for the bc object.
 
QMap< uintptr_t, QString_translationMap
 Translation map for app point pointers (Uses uintptr_t instead of BcTaggedPtr::Data since that class exists only in the cpp file)
 
char * _appPointDataPtr
 A pointer to the _bc->_appPointData vector data converted to a char*.
 
GmStateDumpBufferDataItem_auxObjDumpItem
 The dump item used to save BcNodeSet / BcCellBoundary data.
 
QVector< void * > _auxObj
 Temporarily stores pointers to either BcNodeSet or BcCellBoundary objects during bc data loading.
 

Detailed Description

An auxiliar class used to host the needed code for duming a boundary condition to a state dump. Its purpose os to avoid adding that code to the BC class itself.

Member Function Documentation

◆ addStateItemsToGroup()

bool GmBoundaryConditionStateDumpItem::addStateItemsToGroup ( GmStateDump state,
int  groupId 
)
virtual

Adds to 'state' a data item storing a control map followed by the set of data items needed for recovering application points (depending on the bc type) and then by the available value sets.

Data items needed for recovering application points are:

  • For bc type = Node
    • A translation map for a BcTaggedPtr value into either a GmNodeSet name or into a BcNodeSet index (stored as a string).
    • An item with the data associated with BcNodeSet objects
    • The application point data as stored by _appPointData
  • For bc type = Cell
    • The application point data as stored by _appPointData
  • For bc type = Edge or Face

Auxiliar variant map dump item that notifies us for loading and saving data to the map

< Our "father" Bc dump item object

Implements GmGroupDumpItem.


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