Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 5651 in orxonox.OLD for trunk/src/util/loading/load_param.cc


Ignore:
Timestamp:
Nov 20, 2005, 5:14:27 PM (18 years ago)
Author:
bensch
Message:

orxonox/trunk: new (LoadParam && ExecutorSpecials)-Functionality that enables the Loading of XML-elements.
The new Executor really works out, and makes the understanding of loadParam way easier (given you won't read Executor :)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/util/loading/load_param.cc

    r5646 r5651  
    111111  this->loadString = grabParameter(root, paramName);
    112112  this->object = object;
    113   if (loadString != NULL && root != NULL)
     113  if (root != NULL)
    114114  {
    115115    this->executor = executor.clone();
     
    119119    this->executor = NULL;
    120120  }
     121
    121122}
     123
     124
    122125LoadParamBase::~LoadParamBase()
    123126{
    124127  if (likely(this->executor != NULL))
    125128  {
    126     if (this->loadString!= NULL && likely(this->object != NULL))
    127     this->executor->execute(this->object, this->loadString);
     129   if (likely(this->object != NULL))
     130     this->executor->execute(this->object, this->loadString);
    128131
    129132    delete this->executor;
     
    175178  const TiXmlNode* node;
    176179
    177   if (root == NULL)
     180  if (root == NULL || parameterName == NULL)
    178181    return NULL;
    179182  assert( parameterName != NULL);
Note: See TracChangeset for help on using the changeset viewer.