Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/branches/objecthierarchie/src/orxonox/core/Factory.cc @ 255

Last change on this file since 255 was 255, checked in by landauf, 17 years ago

moved files into the new folders

File size: 543 bytes
RevLine 
[218]1#include "Factory.h"
2#include "Identifier.h"
[219]3#include "BaseObject.h"
[218]4
5namespace orxonox
6{
[244]7    Factory* Factory::pointer_s = NULL;
[218]8
[244]9    Identifier* Factory::getIdentifier(const std::string& name)
[218]10    {
[219]11        if (!pointer_s)
[244]12            pointer_s = new Factory;
[218]13
[244]14        return pointer_s->identifierMap_[name];
[218]15    }
16
[244]17    void Factory::add(const std::string& name, Identifier* identifier)
[218]18    {
[219]19        if (!pointer_s)
[244]20            pointer_s = new Factory;
[218]21
[219]22        pointer_s->identifierMap_[name] = identifier;
[218]23    }
24}
Note: See TracBrowser for help on using the repository browser.