Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Apr 28, 2005, 2:25:08 AM (20 years ago)
Author:
bensch
Message:

orxonox/branches/ll2trunktemp: some small modifications, testing, why 2 instances of fabricate are deleted, and not just the first one

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/branches/ll2trunktemp/src/defs/stdincl.h

    r3940 r4003  
    3030#include "factory.h"
    3131
    32 #define CREATE_FACTORY(x) \
    33                 class x ## Factory : public Factory { \
    34                  public:        \
    35                   x ## Factory (){setNext( NULL); setClassname( #x ); initialize();} \
    36                   ~x ## Factory () {}; \
    37                  private: \
    38                         BaseObject* fabricate( TiXmlElement* root) \
    39                         { \
    40                                 if(!strcmp(root->Value(), getClassname())) return new  x ( root); \
    41                                 else if( getNext() != NULL) return getNext()->fabricate( root); \
    42                                 else return NULL; \
    43                         } \
    44                 }; \
    45                 x ## Factory global_ ## x ## Factory;
    46                
    4732#endif /* _STDINCL_H */
Note: See TracChangeset for help on using the changeset viewer.