Changeset 5783 for code/branches/core5/src/libraries/core/Identifier.cc
- Timestamp:
- Sep 24, 2009, 8:58:27 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/core5/src/libraries/core/Identifier.cc
r5780 r5783 66 66 this->bHasConsoleCommands_ = false; 67 67 68 this->children_ = new std::set<const Identifier*>();69 this->directChildren_ = new std::set<const Identifier*>();70 71 68 // Default network ID is the class ID 72 69 this->networkID_ = this->classID_; … … 78 75 Identifier::~Identifier() 79 76 { 80 delete this->children_;81 delete this->directChildren_;82 77 delete this->objects_; 83 78 … … 165 160 { 166 161 // Tell the parent we're one of it's children 167 (*it)-> getChildrenIntern().insert((*it)->getChildrenIntern().end(), this);162 (*it)->children_.insert((*it)->children_.end(), this); 168 163 169 164 // Erase all parents of our parent from our direct-parent-list … … 187 182 { 188 183 // Tell the parent we're one of it's direct children 189 (*it)-> getDirectChildrenIntern().insert((*it)->getDirectChildrenIntern().end(), this);184 (*it)->directChildren_.insert((*it)->directChildren_.end(), this); 190 185 191 186 // Create the super-function dependencies … … 201 196 { 202 197 COUT(3) << "*** Identifier: Create class-hierarchy" << std::endl; 203 std::map<std::string, Identifier*>::const_iterator it; 204 it = Identifier::getStringIdentifierMap().begin(); 205 Identifier::getStringIdentifierMap().begin()->second->startCreatingHierarchy(); 206 for (it = Identifier::getStringIdentifierMap().begin(); it != Identifier::getStringIdentifierMap().end(); ++it) 198 Identifier::startCreatingHierarchy(); 199 for (std::map<std::string, Identifier*>::const_iterator it = Identifier::getStringIdentifierMap().begin(); it != Identifier::getStringIdentifierMap().end(); ++it) 207 200 { 208 201 // To create the new branch of the class-hierarchy, we create a new object and delete it afterwards. … … 213 206 } 214 207 } 215 Identifier:: getStringIdentifierMap().begin()->second->stopCreatingHierarchy();208 Identifier::stopCreatingHierarchy(); 216 209 COUT(3) << "*** Identifier: Finished class-hierarchy creation" << std::endl; 217 210 } … … 315 308 bool Identifier::isParentOf(const Identifier* identifier) const 316 309 { 317 return (this->children_ ->find(identifier) != this->children_->end());310 return (this->children_.find(identifier) != this->children_.end()); 318 311 } 319 312 … … 324 317 bool Identifier::isDirectParentOf(const Identifier* identifier) const 325 318 { 326 return (this->directChildren_ ->find(identifier) != this->directChildren_->end());319 return (this->directChildren_.find(identifier) != this->directChildren_.end()); 327 320 } 328 321
Note: See TracChangeset
for help on using the changeset viewer.