Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Nov 25, 2007, 5:21:53 PM (16 years ago)
Author:
landauf
Message:

reimplementation of the factory and parts of the class-hierarchy-generating-algorithm. interfaces with protected constructors are now allowed.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/objecthierarchie/src/Factory.cc

    r219 r244  
    55namespace orxonox
    66{
    7     ClassFactory* ClassFactory::pointer_s = NULL;
     7    Factory* Factory::pointer_s = NULL;
    88
    9     BaseObject* ClassFactory::fabricate(const std::string& name)
     9    Identifier* Factory::getIdentifier(const std::string& name)
    1010    {
    1111        if (!pointer_s)
    12             pointer_s = new ClassFactory;
     12            pointer_s = new Factory;
    1313
    14         return pointer_s->identifierMap_[name]->fabricate();
     14        return pointer_s->identifierMap_[name];
    1515    }
    1616
    17     void ClassFactory::add(const std::string& name, Identifier* identifier)
     17    void Factory::add(const std::string& name, Identifier* identifier)
    1818    {
    1919        if (!pointer_s)
    20             pointer_s = new ClassFactory;
     20            pointer_s = new Factory;
    2121
    2222        pointer_s->identifierMap_[name] = identifier;
Note: See TracChangeset for help on using the changeset viewer.