2#pragma warning(disable : 4251)
11class EntityMeshCartesianFaceList;
12class EntityMeshCartesianNodes;
13class EntityCartesianVector;
15class __declspec(dllexport) EntityMeshCartesianData :
public EntityContainer
18 EntityMeshCartesianData(
ot::UID ID, EntityBase *parent, EntityObserver *obs, ModelState *ms, ClassFactoryHandler* factory,
const std::string &owner);
19 virtual ~EntityMeshCartesianData();
21 virtual bool considerForPropertyFilter(
void)
override {
return true; };
22 virtual bool considerChildrenForPropertyFilter(
void)
override {
return false; };
24 virtual bool updateFromProperties(
void)
override;
26 virtual bool getEntityBox(
double &xmin,
double &xmax,
double &ymin,
double &ymax,
double &zmin,
double &zmax)
override;
28 virtual void StoreToDataBase(
void)
override;
30 virtual void addVisualizationNodes(
void)
override;
31 void addVisualizationItem(
bool isHidden);
33 virtual std::string getClassName(
void) {
return "EntityMeshCartesianData"; }
35 virtual entityType getEntityType(
void)
override {
return TOPOLOGY; }
37 virtual void removeChild(EntityBase *child)
override;
39 size_t getNumberLinesX(
void) {
return meshCoords[0].size(); }
40 size_t getNumberLinesY(
void) {
return meshCoords[1].size(); }
41 size_t getNumberLinesZ(
void) {
return meshCoords[2].size(); }
43 size_t getNumberCells(
void) {
return getNumberLinesX() * getNumberLinesY() * getNumberLinesZ(); }
45 std::vector<double> &getMeshLinesX(
void) {
return meshCoords[0]; }
46 std::vector<double> &getMeshLinesY(
void) {
return meshCoords[1]; }
47 std::vector<double> &getMeshLinesZ(
void) {
return meshCoords[2]; }
49 double getSmallestStepWidth(
void);
50 double getLargestStepWidth(
void);
51 double getStepRatio(
void);
53 size_t findLowerIndex(
int direction,
double value);
54 size_t findUpperIndex(
int direction,
double value);
56 EntityMeshCartesianFaceList *getMeshFaces(
void);
57 long long getMeshFacesStorageId(
void) {
return meshFacesStorageId; }
59 EntityMeshCartesianNodes *getMeshNodes(
void);
60 long long getMeshNodesStorageId(
void) {
return meshNodesStorageId; }
62 void storeMeshFaces(
void);
63 void releaseMeshFaces(
void);
65 void storeMeshNodes(
void);
66 void releaseMeshNodes(
void);
68 void setDsMatrix(EntityCartesianVector *matrix);
69 void setDualDsMatrix(EntityCartesianVector *matrix);
70 void setDaMatrix(EntityCartesianVector *matrix);
71 void setDualDaMatrix(EntityCartesianVector *matrix);
72 void setDepsMatrix(EntityCartesianVector *matrix);
73 void setDmuMatrix(EntityCartesianVector *matrix);
74 void setDsigmaMatrix(EntityCartesianVector *matrix);
76 bool applyDsMatrix(std::vector<double> &
vector,
bool keepMatrixInMemory);
77 bool applyDualDsMatrix(std::vector<double> &
vector,
bool keepMatrixInMemory);
78 bool applyDaMatrix(std::vector<double> &
vector,
bool keepMatrixInMemory);
79 bool applyDualDaMatrix(std::vector<double> &
vector,
bool keepMatrixInMemory);
80 bool applyDepsMatrix(std::vector<double> &
vector,
bool keepMatrixInMemory);
81 bool applyDmuMatrix(std::vector<double> &
vector,
bool keepMatrixInMemory);
82 bool applyDsigmaMatrix(std::vector<double> &
vector,
bool keepMatrixInMemory);
85 virtual int getSchemaVersion(
void) {
return 1; };
86 virtual void AddStorageData(bsoncxx::builder::basic::document &storage);
87 virtual void readSpecificDataFromDataBase(bsoncxx::document::view &doc_view, std::map<ot::UID, EntityBase *> &entityMap)
override;
88 void EnsureFacesLoaded(
void);
89 void EnsureNodesLoaded(
void);
90 void EnsureMatrixLoaded(EntityCartesianVector *&matrix,
long long storageId,
long long storageVersion);
91 long long getStorageId(bsoncxx::document::view &doc_view,
const std::string dataName);
92 EntityCartesianVector* getDsMatrix(
void);
93 EntityCartesianVector* getDualDsMatrix(
void);
94 EntityCartesianVector* getDaMatrix(
void);
95 EntityCartesianVector* getDualDaMatrix(
void);
96 EntityCartesianVector* getDepsMatrix(
void);
97 EntityCartesianVector* getDmuMatrix(
void);
98 EntityCartesianVector* getDsigmaMatrix(
void);
99 bool prepareMatrixApplication(std::vector<double> &
vector,
bool keepMatrixInMemory, EntityCartesianVector *matrix, EntityCartesianVector *&loadedMatrix);
101 std::vector<double> meshCoords[3];
103 EntityMeshCartesianFaceList *meshFaces;
104 long long meshFacesStorageId;
105 long long meshFacesStorageVersion;
107 EntityMeshCartesianNodes *meshNodes;
108 long long meshNodesStorageId;
109 long long meshNodesStorageVersion;
111 EntityCartesianVector *matrixDs;
112 EntityCartesianVector *matrixDualDs;
113 EntityCartesianVector *matrixDa;
114 EntityCartesianVector *matrixDualDa;
115 EntityCartesianVector *matrixDeps;
116 EntityCartesianVector *matrixDmu;
117 EntityCartesianVector *matrixDsigma;
119 long long matrixDsStorageId;
120 long long matrixDsStorageVersion;
121 long long matrixDualDsStorageId;
122 long long matrixDualDsStorageVersion;
123 long long matrixDaStorageId;
124 long long matrixDaStorageVersion;
125 long long matrixDualDaStorageId;
126 long long matrixDualDaStorageVersion;
127 long long matrixDepsStorageId;
128 long long matrixDepsStorageVersion;
129 long long matrixDmuStorageId;
130 long long matrixDmuStorageVersion;
131 long long matrixDsigmaStorageId;
132 long long matrixDsigmaStorageVersion;
bsoncxx::types::value value
Definition DocumentManager.h:16
@ vector
Definition MonitorSettings.h:18
unsigned long UID
Unique identifier (32 bit unsigned integer)
Definition CoreTypes.h:27