Changeset 3196 for code/trunk/src/core/XMLPort.h
- Timestamp:
- Jun 20, 2009, 9:20:47 AM (16 years ago)
- Location:
- code/trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk
- Property svn:mergeinfo changed
/code/branches/pch (added) merged: 3114-3118,3124-3125,3127-3131,3133,3138-3194
- Property svn:mergeinfo changed
-
code/trunk/src/core/XMLPort.h
r2896 r3196 44 44 45 45 #include <cassert> 46 #include <string> 46 47 #include <tinyxml/ticpp.h> 48 47 49 #include "util/Debug.h" 48 50 #include "util/Exception.h" 49 51 #include "util/MultiType.h" 50 #include "XMLIncludes.h" 52 #include "util/OrxAssert.h" 53 #include "Factory.h" 54 #include "Identifier.h" 51 55 #include "Executor.h" 52 #include "CoreIncludes.h"53 56 #include "BaseObject.h" 54 57 … … 176 179 */ 177 180 #define XMLPortParamGeneric(containername, classname, objectclass, object, paramname, loadexecutor, saveexecutor, xmlelement, mode) \ 178 orxonox::XMLPortClassParamContainer<objectclass>* containername = (orxonox::XMLPortClassParamContainer<objectclass>*)(ClassIdentifier<classname>::getIdentifier()->getXMLPortParamContainer(paramname)); \181 orxonox::XMLPortClassParamContainer<objectclass>* containername = static_cast<orxonox::XMLPortClassParamContainer<objectclass>*>(ClassIdentifier<classname>::getIdentifier()->getXMLPortParamContainer(paramname)); \ 179 182 if (!containername) \ 180 183 { \ … … 545 548 for (ticpp::Iterator<ticpp::Element> child = xmlsubelement->FirstChildElement(false); child != child.end(); child++) 546 549 { 547 Identifier* identifier = ClassByString(child->Value());550 Identifier* identifier = Factory::getIdentifier(child->Value()); 548 551 if (identifier) 549 552 { 550 if (identifier->isA(Class (O)))553 if (identifier->isA(ClassIdentifier<O>::getIdentifier())) 551 554 { 552 555 if (identifier->isLoadable()) … … 606 609 else 607 610 { 608 COUT(2) << object->getLoaderIndentation() << "Warning: '" << child->Value() << "' is not a '" << Class (O)->getName() << "'." << std::endl;611 COUT(2) << object->getLoaderIndentation() << "Warning: '" << child->Value() << "' is not a '" << ClassIdentifier<O>::getIdentifier()->getName() << "'." << std::endl; 609 612 } 610 613 } … … 626 629 { 627 630 COUT(1) << std::endl; 628 COUT(1) << "An error occurred in XMLPort.h while loading a '" << Class (O)->getName() << "' in '" << this->sectionname_ << "' of '" << this->identifier_->getName() << "' (objectname: " << object->getName() << ") in " << object->getFilename() << ":" << std::endl;631 COUT(1) << "An error occurred in XMLPort.h while loading a '" << ClassIdentifier<O>::getIdentifier()->getName() << "' in '" << this->sectionname_ << "' of '" << this->identifier_->getName() << "' (objectname: " << object->getName() << ") in " << object->getFilename() << ":" << std::endl; 629 632 COUT(1) << ex.what() << std::endl; 630 633 }
Note: See TracChangeset
for help on using the changeset viewer.