OpenTwin 0.1
OpenTwin
 
Loading...
Searching...
No Matches
EntityMeshTetFaceData.h
Go to the documentation of this file.
1#pragma once
2#pragma warning(disable : 4251)
3
4#include "EntityBase.h"
5#include "OldTreeIcon.h"
6
7#include <list>
8
9class EntityMeshTetFace;
10class EntityMeshTetInfo;
11
12class __declspec(dllexport) EntityMeshTetFaceData : public EntityBase
13{
14public:
15 EntityMeshTetFaceData(ot::UID ID, EntityBase *parent, EntityObserver *obs, ModelState *ms, ClassFactoryHandler* factory, const std::string &owner);
16 virtual ~EntityMeshTetFaceData();
17
18 virtual bool getEntityBox(double &xmin, double &xmax, double &ymin, double &ymax, double &zmin, double &zmax) override;
19
20 EntityMeshTetFace *getFace(int faceId);
21 void setFace(int faceId, EntityMeshTetFace *face);
22
23 virtual void StoreToDataBase(void) override;
24
25 virtual std::string getClassName(void) { return "EntityMeshTetFaceData"; };
26
27 void addMeshFaceStorageIds(EntityMeshTetInfo *meshInfo);
28
29 virtual entityType getEntityType(void) override { return DATA; };
30 virtual void removeChild(EntityBase *child) override;
31
32 std::map<int, EntityMeshTetFace*> getAllFaces(void) { return meshFaces; }
33
34private:
35 virtual int getSchemaVersion(void) { return 1; };
36 virtual void AddStorageData(bsoncxx::builder::basic::document &storage);
37 virtual void readSpecificDataFromDataBase(bsoncxx::document::view &doc_view, std::map<ot::UID, EntityBase *> &entityMap) override;
38 void EnsureFacesLoaded(void);
39 void storeMeshFaces(void);
40 void releaseMeshFaces(void);
41
42 std::map<int, EntityMeshTetFace*> meshFaces;
43 std::map<EntityBase*, int> meshFacesIndex;
44 std::map<int, std::pair<ot::UID, ot::UID>> meshFaceStorageIds;
45};
46
47
48
unsigned long UID
Unique identifier (32 bit unsigned integer)
Definition CoreTypes.h:27