Changeset 366 for code/branches/objecthierarchy/src/orxonox/core
- Timestamp:
- Dec 2, 2007, 2:07:01 AM (17 years ago)
- Location:
- code/branches/objecthierarchy/src/orxonox/core
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/objecthierarchy/src/orxonox/core/OrxonoxClass.cc
r365 r366 8 8 namespace orxonox 9 9 { 10 /** @brief Constructor: Sets identifier_ and parents_ to zero. */10 /** @brief Constructor: Sets the default values. */ 11 11 OrxonoxClass::OrxonoxClass() 12 12 { 13 13 this->identifier_ = 0; 14 14 this->parents_ = 0; 15 16 this->bActive_ = true; 17 this->bVisible_ = true; 15 18 } 16 19 -
code/branches/objecthierarchy/src/orxonox/core/OrxonoxClass.h
r365 r366 43 43 inline MetaObjectList& getMetaList() { return this->metaList_; } 44 44 45 inline bool isA(const Identifier* identifier) 46 { return this->getIdentifier()->isA(identifier); } 47 inline bool isDirectlyA(const Identifier* identifier) 48 { return this->getIdentifier()->isDirectlyA(identifier); } 49 inline bool isChildOf(const Identifier* identifier) 50 { return this->getIdentifier()->isChildOf(identifier); } 51 inline bool isParentOf(const Identifier* identifier) 52 { return this->getIdentifier()->isParentOf(identifier); } 53 54 inline bool isA(const SubclassIdentifier<class B>* identifier) 55 { return this->getIdentifier()->isA(identifier->getIdentifier()); } 56 inline bool isDirectlyA(const SubclassIdentifier<class B>* identifier) 57 { return this->getIdentifier()->isDirectlyA(identifier->getIdentifier()); } 58 inline bool isChildOf(const SubclassIdentifier<class B>* identifier) 59 { return this->getIdentifier()->isChildOf(identifier->getIdentifier()); } 60 inline bool isParentOf(const SubclassIdentifier<class B>* identifier) 61 { return this->getIdentifier()->isParentOf(identifier->getIdentifier()); } 62 63 inline bool isA(const SubclassIdentifier<class B> identifier) 64 { return this->getIdentifier()->isA(identifier.getIdentifier()); } 65 inline bool isDirectlyA(const SubclassIdentifier<class B> identifier) 66 { return this->getIdentifier()->isDirectlyA(identifier.getIdentifier()); } 67 inline bool isChildOf(const SubclassIdentifier<class B> identifier) 68 { return this->getIdentifier()->isChildOf(identifier.getIdentifier()); } 69 inline bool isParentOf(const SubclassIdentifier<class B> identifier) 70 { return this->getIdentifier()->isParentOf(identifier.getIdentifier()); } 71 72 inline bool isA(const OrxonoxClass* object) 73 { return this->getIdentifier()->isA(object->getIdentifier()); } 74 inline bool isDirectlyA(const OrxonoxClass* object) 75 { return this->getIdentifier()->isDirectlyA(object->getIdentifier()); } 76 inline bool isChildOf(const OrxonoxClass* object) 77 { return this->getIdentifier()->isChildOf(object->getIdentifier()); } 78 inline bool isParentOf(const OrxonoxClass* object) 79 { return this->getIdentifier()->isParentOf(object->getIdentifier()); } 80 81 82 inline void setName(const std::string& name) { this->name_ = name; } 83 inline const std::string& getName() const { return this->name_; } 84 85 inline void setActive(bool bActive) { this->bActive_ = bActive; } 86 inline const bool isActive() const { return this->bActive_; } 87 88 inline void setVisible(bool bVisible) { this->bVisible_ = bVisible; } 89 inline const bool isVisible() const { return this->bVisible_; } 90 45 91 private: 46 92 Identifier* identifier_; //!< The Identifier of the object 47 93 IdentifierList* parents_; //!< List of all parents of the object 48 94 MetaObjectList metaList_; //!< MetaObjectList, containing all ObjectLists and ObjectListElements the object is registered in 95 96 std::string name_; 97 bool bActive_; 98 bool bVisible_; 49 99 }; 50 100 }
Note: See TracChangeset
for help on using the changeset viewer.