CFx SDK Documentation 2024 SP0
Loading...
Searching...
No Matches
FxBIMDatabaseReference.h
Go to the documentation of this file.
1//
2// (C) Copyright 2020-2023 by Graebert GmbH.
3//
4// Permission to use, copy, modify, and distribute this software in
5// object code form for any purpose and without fee is hereby granted,
6// provided that the above copyright notice appears in all copies and
7// that both that copyright notice and the limited warranty and
8// restricted rights notice below appear in all supporting
9// documentation.
10//
11// GRAEBERT PROVIDES THIS PROGRAM "AS IS" AND WITH ALL FAULTS.
12// GRAEBERT SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTY OF
13// MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE. GRAEBERT GMBH
14// DOES NOT WARRANT THAT THE OPERATION OF THE PROGRAM WILL BE
15// UNINTERRUPTED OR ERROR FREE.
16
17#pragma once
18
19#include "FxBIM.h"
20
21#include <DbObject.h>
22#include <DoubleArray.h>
23
26
27class CFxBIMDatabase;
29
31class OdDbDwgFiler;
32
34{
35public:
37
39
40 static CFxBIMDatabaseReferencePtr Create( const OdString& dwgPath, const OdString& originalPath, const OdString& projectPath, Error& err );
41
42 virtual const OdString& BimFileName() const;
43 virtual const OdString& BimViewName() const;
45
46 virtual Error CreateEntityRefs( OdDbObjectId idOwner, const OdGeMatrix3d& trf );
49
50 virtual Error Load( bool bNotify = true );
51 virtual Error Unload();
52
53 virtual bool IsUnloaded();
54
55 virtual OdDouble Scale() const;
56
57 virtual const OdGeMatrix3d& Transform() const;
58 virtual void SetTransform( const OdGeMatrix3d& transform );
59
60 virtual size_t EntityRefCount() const;
61 virtual OdDbObjectId EntityRef( size_t index ) const; //CFxBIMEntityReference
62
63 virtual bool IsLocked() const;
64 virtual Error Lock();
65 virtual Error Unlock();
66
67 virtual bool IsOn() const;
68 virtual Error On();
69 virtual Error Off();
70
71 virtual Error Insert();
72
73 virtual Error Remove();
75
76 enum Flags
77 {
78 eNone = 0,
79 eLoad = 0x1,
80 eMaterials = 0x2,
81 eUnused0 = 0x4,
82 eUnused1 = 0x8,
83 };
84
85 virtual int Flags() const;
86 virtual void SetFlags( int flags );
87
88public:
89 OdResult dwgInFields( OdDbDwgFiler* pFiler ) override;
90 void dwgOutFields( OdDbDwgFiler* pFiler ) const override;
91
92 OdResult dxfInFields( OdDbDxfFiler* pFiler ) override;
93 void dxfOutFields( OdDbDxfFiler* pFiler ) const override;
94
95 void subClose() override;
96
97 void applyPartialUndo( OdDbDwgFiler* pFiler, OdRxClass* pClass ) override;
98
99 void subHandOverTo( OdDbObject* pNewObject ) override;
100
101protected:
103};
double OdDouble
Definition: DoubleArray.h:31
Error
Definition: FxBIM.h:66
#define FXBIM_API
Definition: FxBIM.h:20
OdSmartPtr< CFxBIMDatabaseReference > CFxBIMDatabaseReferencePtr
OdSmartPtr< CFxBIMDatabase > CFxBIMDatabasePtr
OdResult
Definition: OdResult.h:29
void dxfOutFields(OdDbDxfFiler *pFiler) const override
virtual Error Unload()
virtual CFxBIMDatabasePtr BimDatabase(OdDb::OpenMode openMode)
void dwgOutFields(OdDbDwgFiler *pFiler) const override
virtual void SetFlags(int flags)
virtual Error Off()
virtual int Flags() const
virtual Error CreateEntityRefs(OdDbObjectId idOwner, const OdGeMatrix3d &trf)
static CFxBIMDatabaseReferencePtr Create(const OdString &dwgPath, const OdString &originalPath, const OdString &projectPath, Error &err)
OdResult dxfInFields(OdDbDxfFiler *pFiler) override
virtual bool IsLocked() const
virtual Error Insert()
virtual Error Load(bool bNotify=true)
virtual const OdGeMatrix3d & Transform() const
virtual Error On()
virtual bool IsOn() const
virtual Error ReloadFrom(CFxBIMDatabaseReferencePtr pNew, OdDbObjectId idOwner, const OdGeMatrix3d &trf)
virtual const OdString & BimFileName() const
virtual OdDbObjectId EntityRef(size_t index) const
virtual OdDouble Scale() const
virtual bool IsUnloaded()
virtual Error RemoveReferredObjectsFromGsModel()
virtual Error Lock()
virtual void SetTransform(const OdGeMatrix3d &transform)
virtual const OdString & BimViewName() const
virtual Error Remove()
virtual size_t EntityRefCount() const
void subHandOverTo(OdDbObject *pNewObject) override
void subClose() override
void applyPartialUndo(OdDbDwgFiler *pFiler, OdRxClass *pClass) override
OdResult dwgInFields(OdDbDwgFiler *pFiler) override
ODDB_DECLARE_MEMBERS(CFxBIMDatabaseReference)
virtual Error DestroyEntityRefs()
virtual ~CFxBIMDatabaseReference()
virtual Error Unlock()
GLuint index
Definition: gles2_ext.h:265
OpenMode
Definition: DbObjectId.h:54