00001
00002
00003
00004
00005
00011 #ifndef __FCD_OBJECT_H_
00012 #define __FCD_OBJECT_H_
00013
00014 #include "FUtils/FUObject.h"
00015 #include "FCDocument/FCDocument.h"
00016
00029 class FCOLLADA_EXPORT FCDObject : public FUObject
00030 {
00031 private:
00032 DeclareObjectType;
00033
00034
00035
00036 void* userHandle;
00037
00038
00039 FCDObject(FUObjectContainer* container);
00040
00041 public:
00044 FCDObject(FCDocument* document);
00045
00047 virtual ~FCDObject() {}
00048
00051 inline FCDocument* GetDocument() { return (FCDocument*) GetContainer(); }
00052 inline FCDocument* GetDocument() const { return (FCDocument*) GetContainer(); }
00058 inline void* GetUserHandle() const { return userHandle; }
00059
00064 inline void SetUserHandle(void* handle) { userHandle = handle; }
00065 };
00066
00080 class FCOLLADA_EXPORT FCDObjectWithId : public FCDObject
00081 {
00082 private:
00083 DeclareObjectType;
00084
00085 string daeId;
00086 bool hasUniqueId;
00087
00088 public:
00092 FCDObjectWithId(FCDocument* document, const char* baseId = "ObjectWithID");
00093
00095 virtual ~FCDObjectWithId();
00096
00101 const string& GetDaeId() const;
00102
00108 void SetDaeId(const string& id);
00109
00115 void SetDaeId(string& id);
00116
00120 void RemoveDaeId();
00121
00126 void Clone(FCDObjectWithId* clone) const;
00127 };
00128
00129 #endif // __FCD_OBJECT_H_