Changeset 810 for code/branches/core/src/orxonox/core/Identifier.h
- Timestamp:
- Feb 13, 2008, 2:58:55 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
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.