Changeset 810
- Timestamp:
- Feb 13, 2008, 2:58:55 AM (17 years ago)
- Location:
- code/branches/core/src/orxonox/core
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/core/src/orxonox/core/ClassManager.h
r809 r810 134 134 static std::string unknownClassName = std::string("unknown"); 135 135 136 if (ClassManager<T>::getSingleton()->bInitialized )136 if (ClassManager<T>::getSingleton()->bInitialized_) 137 137 return ClassManager<T>::getSingleton()->identifier_->getName(); 138 138 else -
code/branches/core/src/orxonox/core/Identifier.h
r809 r810 299 299 SubclassIdentifier() 300 300 { 301 T* temp = new T; 302 this->subclassIdentifier_ = temp->getIdentifier(); 303 delete temp; 301 std::string name = ClassManager<T>::getName(); 302 303 if (name != "unknown") 304 this->subclassIdentifier_ = ClassManager<T>::getIdentifier(name); 305 else 306 this->subclassIdentifier_ = 0; 304 307 305 308 this->identifier_ = this->subclassIdentifier_; 309 } 310 311 /** 312 @brief Copyconstructor: Assigns the given Identifier. 313 @param identifier The Identifier 314 */ 315 SubclassIdentifier(Identifier* identifier) 316 { 317 std::string name = ClassManager<T>::getName(); 318 319 if (name != "unknown") 320 this->subclassIdentifier_ = ClassManager<T>::getIdentifier(name); 321 else 322 this->subclassIdentifier_ = 0; 323 324 this->identifier_ = identifier; 306 325 } 307 326
Note: See TracChangeset
for help on using the changeset viewer.