CFx SDK Documentation 2024 SP0
Loading...
Searching...
No Matches
IfcModelFiller.h
Go to the documentation of this file.
1
2// Copyright (C) 2002-2022, Open Design Alliance (the "Alliance").
3// All rights reserved.
4//
5// This software and its documentation and related materials are owned by
6// the Alliance. The software may only be incorporated into application
7// programs owned by members of the Alliance, subject to a signed
8// Membership Agreement and Supplemental Software License Agreement with the
9// Alliance. The structure and organization of this software are the valuable
10// trade secrets of the Alliance and its suppliers. The software is also
11// protected by copyright law and international treaty provisions. Application
12// programs incorporating this software must include the following statement
13// with their copyright notices:
14//
15// This application incorporates Open Design Alliance software pursuant to a license
16// agreement with Open Design Alliance.
17// Open Design Alliance Copyright (C) 2002-2022 by Open Design Alliance.
18// All rights reserved.
19//
20// By use of this software, its documentation or related materials, you
21// acknowledge and accept the above terms.
23
24#ifndef _IFC_MODEL_FILLER_H
25#define _IFC_MODEL_FILLER_H
26
27#include "OdPlatformSettings.h"
28
29#include "IfcModel.h"
30#include "IfcEntity.h"
31
33{
34protected:
35
37 {
38 const OdDAI::Entity* IfcAxis2Placement2D;
39 const OdDAI::Entity* IfcAxis2Placement3D;
40 const OdDAI::Entity* IfcBuilding;
41 const OdDAI::Entity* IfcCartesianPoint;
42 const OdDAI::Entity* IfcDirection;
43 const OdDAI::Entity* IfcOwnerHistory;
44 const OdDAI::Entity* IfcProduct;
45 const OdDAI::Entity* IfcProject;
46 const OdDAI::Entity* IfcRoot;
47 const OdDAI::Entity* IfcSite;
48 const OdDAI::Entity* IfcSiUnit;
49 };
52
53protected:
54
56
57 OdIfcModelFiller(OdDAI::Model *model)
58 : m_model(model)
59 {
60 initEntities();
61 }
62
63 OdIfc::OdIfcEntityPtr m_person;
64 OdIfc::OdIfcEntityPtr m_ownerHistory;
65 OdIfc::OdIfcEntityPtr m_unitAssignment;
66 OdIfc::OdIfcEntityPtr m_project;
67 OdIfc::OdIfcEntityPtr m_site;
68
69 //
70 // Common entities, must not be changed as their purposes are predefined:
71 //
72 OdDAIObjectId m_dirX;
73 OdDAIObjectId m_dirY;
74 OdDAIObjectId m_dirZ;
75 OdDAIObjectId m_posOrigin;
76 OdDAIObjectId m_identity;
77
78 OdDAIObjectId m_dirX2D;
79 OdDAIObjectId m_dirY2D;
80 OdDAIObjectId m_posOrigin2D;
81 OdDAIObjectId m_identity2D;
82
87
88public:
89
93 virtual ~OdIfcModelFiller() {};
94
99 OdIfcModelPtr model() { return m_model; };
100
105 OdIfc::OdIfcEntityPtr createFromScratch(
106 const OdString &organizationName,
107 const OdString &applicationDeveloperName,
108 const OdString &applicationDeveloperDescription,
109 const OdString &applicationFullName,
110 const OdString &applicationVersion,
111 const OdString &applicationIdentifier
112 );
113
114 //
115 // Common instances accessors
116 //
117 const OdDAIObjectId& dirX() const { return m_dirX; };
118 const OdDAIObjectId& dirY() const { return m_dirY; };
119 const OdDAIObjectId& dirZ() const { return m_dirZ; };
120 const OdDAIObjectId& origin() const { return m_posOrigin; };
121 const OdDAIObjectId& identity() const { return m_identity; };
122
123 const OdDAIObjectId& dirX2D() const { return m_dirX2D; };
124 const OdDAIObjectId& dirY2D() const { return m_dirY2D; };
125 const OdDAIObjectId& origin2D() const { return m_posOrigin2D; };
126 const OdDAIObjectId& identity2D() const { return m_identity2D; };
127
128 OdIfc::OdIfcEntityPtr person() { return m_person; };
129 OdIfc::OdIfcEntityPtr ownerHistory() { return m_ownerHistory; };
130 OdIfc::OdIfcEntityPtr unitAssignment() { return m_unitAssignment; };
131 OdIfc::OdIfcEntityPtr project() { return m_project; };
132 OdIfc::OdIfcEntityPtr site() { return m_site; };
133
134 OdIfc::OdIfcEntityPtr createSiUnit(const char *unitType, const char *prefix, const char *name, bool append = false);
135
139 OdIfc::OdIfcEntityPtr createCartesianPoint(const OdGePoint3d &p);
140
144 OdIfc::OdIfcEntityPtr createCartesianPoint(const OdGePoint2d &p);
145
149 OdIfc::OdIfcEntityPtr createDirection(const OdGeVector3d &v);
150
154 OdIfc::OdIfcEntityPtr createDirection(const OdGeVector2d &v);
155
156 OdIfc::OdIfcEntityPtr createAxis2Placement3D(const OdGeMatrix3d &m);
157
158 OdIfc::OdIfcEntityPtr createAxis2Placement2D(const OdGeMatrix2d &m);
159
160 friend class OdIfcFile;
161};
163
164#endif // _IFC_MODEL_FILLER_H
#define IFCCORE_EXPORT
OdDAI::ModelPtr OdIfcModelPtr
Definition: IfcModel.h:37
OdSharedPtr< OdIfcModelFiller > OdIfcModelFillerPtr
const OdDAIObjectId & identity() const
EntityDefinitions Entity
OdDAIObjectId m_dirX2D
OdIfcModelFiller(OdDAI::Model *model)
OdIfc::OdIfcEntityPtr project()
const OdDAIObjectId & dirZ() const
OdDAIObjectId m_posOrigin2D
OdDAIObjectId m_posOrigin
const OdDAIObjectId & origin2D() const
OdIfc::OdIfcEntityPtr createFromScratch(const OdString &organizationName, const OdString &applicationDeveloperName, const OdString &applicationDeveloperDescription, const OdString &applicationFullName, const OdString &applicationVersion, const OdString &applicationIdentifier)
OdIfc::OdIfcEntityPtr createCartesianPoint(const OdGePoint3d &p)
const OdDAIObjectId & identity2D() const
OdDAIObjectId m_identity2D
OdIfc::OdIfcEntityPtr createDirection(const OdGeVector2d &v)
const OdDAIObjectId & dirY() const
const OdDAIObjectId & dirX2D() const
OdIfcModelPtr model()
OdIfc::OdIfcEntityPtr unitAssignment()
OdIfc::OdIfcEntityPtr m_site
void appendSharedInstances()
OdIfc::OdIfcEntityPtr m_unitAssignment
const OdDAIObjectId & dirY2D() const
OdDAIObjectId m_dirY
OdIfcModelPtr m_model
OdIfc::OdIfcEntityPtr person()
OdDAIObjectId m_identity
OdIfc::OdIfcEntityPtr createAxis2Placement3D(const OdGeMatrix3d &m)
OdDAIObjectId m_dirY2D
virtual ~OdIfcModelFiller()
const OdDAIObjectId & dirX() const
OdIfc::OdIfcEntityPtr createDirection(const OdGeVector3d &v)
OdIfc::OdIfcEntityPtr m_person
OdIfc::OdIfcEntityPtr m_ownerHistory
OdIfc::OdIfcEntityPtr m_project
OdIfc::OdIfcEntityPtr createSiUnit(const char *unitType, const char *prefix, const char *name, bool append=false)
OdIfc::OdIfcEntityPtr ownerHistory()
OdIfc::OdIfcEntityPtr createAxis2Placement2D(const OdGeMatrix2d &m)
OdDAIObjectId m_dirZ
OdDAIObjectId m_dirX
OdIfc::OdIfcEntityPtr createCartesianPoint(const OdGePoint2d &p)
OdIfc::OdIfcEntityPtr site()
const OdDAIObjectId & origin() const
GLuint const GLchar * name
Definition: gles2_ext.h:265
const GLfloat * v
Definition: gles2_ext.h:315
const OdDAI::Entity * IfcProject
const OdDAI::Entity * IfcBuilding
const OdDAI::Entity * IfcAxis2Placement2D
const OdDAI::Entity * IfcProduct
const OdDAI::Entity * IfcCartesianPoint
const OdDAI::Entity * IfcOwnerHistory
const OdDAI::Entity * IfcDirection
const OdDAI::Entity * IfcAxis2Placement3D