Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jun 7, 2015, 2:16:55 PM (9 years ago)
Author:
landauf
Message:

clean and explicit setup/shutdown of singletons that are used by statically initialized instances

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/core7/src/libraries/network/NetworkFunctionManager.h

    r10520 r10542  
    3636#include <set>
    3737
     38#include "util/Singleton.h"
     39#include "NetworkFunction.h"
     40
    3841namespace orxonox
    3942{
    40     class _NetworkExport NetworkFunctionManager
     43    class _NetworkExport NetworkFunctionManager : public Singleton<NetworkFunctionManager>
    4144    {
     45        friend class Singleton<NetworkFunctionManager>;
     46
    4247        public:
    43             static NetworkFunctionManager& getInstance();
    44 
    4548            void registerFunction(NetworkFunctionBase* function);
    4649            void unregisterFunction(NetworkFunctionBase* function);
     
    5861            std::map<NetworkFunctionPointer, NetworkFunctionBase*> functorMap_;
    5962            std::map<uint32_t, NetworkFunctionBase*> idMap_;
     63
     64            static NetworkFunctionManager* singletonPtr_s;
    6065    };
    6166}
Note: See TracChangeset for help on using the changeset viewer.