Changeset 1313 for code/branches/console/src/core/OrxonoxClass.cc
- Timestamp:
- May 17, 2008, 3:58:19 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/console/src/core/OrxonoxClass.cc
r1056 r1313 33 33 34 34 #include "OrxonoxClass.h" 35 #include "MetaObjectList.h" 36 #include "Identifier.h" 35 37 36 38 namespace orxonox … … 39 41 OrxonoxClass::OrxonoxClass() 40 42 { 43 this->metaList_ = new MetaObjectList(); 44 41 45 this->setConfigValues(); 42 46 … … 48 52 OrxonoxClass::~OrxonoxClass() 49 53 { 54 delete this->metaList_; 55 50 56 // parents_ exists only if isCreatingHierarchy() of the associated Identifier returned true while creating the class 51 57 if (this->parents_) 52 58 delete this->parents_; 53 59 } 60 61 /** @brief Returns true if the objects class is of the given type or a derivative. */ 62 bool OrxonoxClass::isA(const Identifier* identifier) 63 { return this->getIdentifier()->isA(identifier); } 64 /** @brief Returns true if the objects class is exactly of the given type. */ 65 bool OrxonoxClass::isExactlyA(const Identifier* identifier) 66 { return this->getIdentifier()->isExactlyA(identifier); } 67 /** @brief Returns true if the objects class is a child of the given type. */ 68 bool OrxonoxClass::isChildOf(const Identifier* identifier) 69 { return this->getIdentifier()->isChildOf(identifier); } 70 /** @brief Returns true if the objects class is a direct child of the given type. */ 71 bool OrxonoxClass::isDirectChildOf(const Identifier* identifier) 72 { return this->getIdentifier()->isDirectChildOf(identifier); } 73 /** @brief Returns true if the objects class is a parent of the given type. */ 74 bool OrxonoxClass::isParentOf(const Identifier* identifier) 75 { return this->getIdentifier()->isParentOf(identifier); } 76 /** @brief Returns true if the objects class is a direct parent of the given type. */ 77 bool OrxonoxClass::isDirectParentOf(const Identifier* identifier) 78 { return this->getIdentifier()->isDirectParentOf(identifier); } 79 80 81 /** @brief Returns true if the objects class is of the given type or a derivative. */ 82 bool OrxonoxClass::isA(const SubclassIdentifier<class B>* identifier) 83 { return this->getIdentifier()->isA(identifier->getIdentifier()); } 84 /** @brief Returns true if the objects class is exactly of the given type. */ 85 bool OrxonoxClass::isExactlyA(const SubclassIdentifier<class B>* identifier) 86 { return this->getIdentifier()->isExactlyA(identifier->getIdentifier()); } 87 /** @brief Returns true if the objects class is a child of the given type. */ 88 bool OrxonoxClass::isChildOf(const SubclassIdentifier<class B>* identifier) 89 { return this->getIdentifier()->isChildOf(identifier->getIdentifier()); } 90 /** @brief Returns true if the objects class is a direct child of the given type. */ 91 bool OrxonoxClass::isDirectChildOf(const SubclassIdentifier<class B>* identifier) 92 { return this->getIdentifier()->isDirectChildOf(identifier->getIdentifier()); } 93 /** @brief Returns true if the objects class is a parent of the given type. */ 94 bool OrxonoxClass::isParentOf(const SubclassIdentifier<class B>* identifier) 95 { return this->getIdentifier()->isParentOf(identifier->getIdentifier()); } 96 /** @brief Returns true if the objects class is a direct parent of the given type. */ 97 bool OrxonoxClass::isDirectParentOf(const SubclassIdentifier<class B>* identifier) 98 { return this->getIdentifier()->isDirectParentOf(identifier->getIdentifier()); } 99 100 101 /** @brief Returns true if the objects class is of the given type or a derivative. */ 102 bool OrxonoxClass::isA(const SubclassIdentifier<class B> identifier) 103 { return this->getIdentifier()->isA(identifier.getIdentifier()); } 104 /** @brief Returns true if the objects class is exactly of the given type. */ 105 bool OrxonoxClass::isExactlyA(const SubclassIdentifier<class B> identifier) 106 { return this->getIdentifier()->isExactlyA(identifier.getIdentifier()); } 107 /** @brief Returns true if the objects class is a child of the given type. */ 108 bool OrxonoxClass::isChildOf(const SubclassIdentifier<class B> identifier) 109 { return this->getIdentifier()->isChildOf(identifier.getIdentifier()); } 110 /** @brief Returns true if the objects class is a direct child of the given type. */ 111 bool OrxonoxClass::isDirectChildOf(const SubclassIdentifier<class B> identifier) 112 { return this->getIdentifier()->isDirectChildOf(identifier.getIdentifier()); } 113 /** @brief Returns true if the objects class is a parent of the given type. */ 114 bool OrxonoxClass::isParentOf(const SubclassIdentifier<class B> identifier) 115 { return this->getIdentifier()->isParentOf(identifier.getIdentifier()); } 116 /** @brief Returns true if the objects class is a direct parent of the given type. */ 117 bool OrxonoxClass::isDirectParentOf(const SubclassIdentifier<class B> identifier) 118 { return this->getIdentifier()->isDirectParentOf(identifier.getIdentifier()); } 119 120 121 /** @brief Returns true if the objects class is of the given type or a derivative. */ 122 bool OrxonoxClass::isA(const OrxonoxClass* object) 123 { return this->getIdentifier()->isA(object->getIdentifier()); } 124 /** @brief Returns true if the objects class is exactly of the given type. */ 125 bool OrxonoxClass::isExactlyA(const OrxonoxClass* object) 126 { return this->getIdentifier()->isExactlyA(object->getIdentifier()); } 127 /** @brief Returns true if the objects class is a child of the given type. */ 128 bool OrxonoxClass::isChildOf(const OrxonoxClass* object) 129 { return this->getIdentifier()->isChildOf(object->getIdentifier()); } 130 /** @brief Returns true if the objects class is a direct child of the given type. */ 131 bool OrxonoxClass::isDirectChildOf(const OrxonoxClass* object) 132 { return this->getIdentifier()->isDirectChildOf(object->getIdentifier()); } 133 /** @brief Returns true if the objects class is a parent of the given type. */ 134 bool OrxonoxClass::isParentOf(const OrxonoxClass* object) 135 { return this->getIdentifier()->isParentOf(object->getIdentifier()); } 136 /** @brief Returns true if the objects class is a direct child of the given type. */ 137 bool OrxonoxClass::isDirectParentOf(const OrxonoxClass* object) 138 { return this->getIdentifier()->isDirectParentOf(object->getIdentifier()); } 54 139 }
Note: See TracChangeset
for help on using the changeset viewer.