Changeset 5646 in orxonox.OLD for trunk/src/util
- Timestamp:
- Nov 19, 2005, 10:01:46 PM (19 years ago)
- Location:
- trunk/src/util/loading
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/util/loading/load_param.cc
r5645 r5646 110 110 { 111 111 this->loadString = grabParameter(root, paramName); 112 112 this->object = object; 113 113 if (loadString != NULL && root != NULL) 114 114 { 115 115 this->executor = executor.clone(); 116 this->executor->execute(object, loadString);117 116 } 118 117 else … … 124 123 { 125 124 if (likely(this->executor != NULL)) 125 { 126 if (this->loadString!= NULL && likely(this->object != NULL)) 127 this->executor->execute(this->object, this->loadString); 128 126 129 delete this->executor; 130 } 127 131 128 132 } -
trunk/src/util/loading/load_param.h
r5645 r5646 38 38 class LoadParamDescription; 39 39 class MultiType; 40 41 42 /** 43 * Loads a Parameter from ROOT named PARAMETER_NAME 44 * onto OBJECT of CLASS, trough the FUNCTION 45 * @param ROOT the TiXmlElement to load the Parameter from 46 * @param PARAMETER_NAME the Name of the Parameter to load 47 * @param OBJECT The BaseObject to load the new setting to. 48 * @param CLASS What Class the BaseObejct is of (this is for identifying the Functuon) 49 * @param FUNCTION The function of Class to Load (if you want to call &CLASS::FUNCTION write FUNCTION here). 50 */ 51 #define LoadParamNEW(ROOT, PARAMETER_NAME, OBJECT, CLASS, FUNCTION) \ 52 LoadParamBase(ROOT, PARAMETER_NAME, OBJECT, ExecutorObjective<CLASS>(&CLASS::FUNCTION)) 53 40 54 41 55 /************************** … … 57 71 protected: 58 72 Executor* executor; 73 BaseObject* object; 59 74 60 75 LoadClassDescription* classDesc; //!< The LoadClassDescription of this LoadParameter
Note: See TracChangeset
for help on using the changeset viewer.