Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
May 25, 2015, 12:25:29 PM (6 years ago)
Author:
landauf
Message:

NetworkFunctionBase doesn't have to inherit from Listable: there's a list of all instances stored in NetworkFunctionManager stored anyway

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/core7/src/libraries/network/NetworkFunction.cc

    r10468 r10470  
    2929#include "NetworkFunction.h"
    3030#include "NetworkFunctionManager.h"
    31 #include "core/CoreIncludes.h"
    3231
    3332namespace orxonox
     
    3635  std::map<uint32_t, NetworkMemberFunctionBase*> NetworkMemberFunctionBase::idMap_;
    3736
    38   // no suitable factory for NetworkFunctionBase (and children), so we declare it abstract
    39   RegisterAbstractClass(NetworkFunctionBase).inheritsFrom<Listable>();
    40   RegisterAbstractClass(NetworkFunctionStatic).inheritsFrom<NetworkFunctionBase>();
    41   RegisterAbstractClass(NetworkMemberFunctionBase).inheritsFrom<NetworkFunctionBase>();
    42 
    4337  NetworkFunctionBase::NetworkFunctionBase(const std::string& name)
    4438  {
    45       RegisterObject(NetworkFunctionBase);
    46 
    4739    static uint32_t networkID = 0;
    4840    this->networkID_ = networkID++;
     
    5951    NetworkFunctionBase(name)
    6052  {
    61     RegisterObject(NetworkFunctionStatic);
    62 
    6353    this->functor_ = functor;
    6454    NetworkFunctionStatic::getFunctorMap()[p] = this;
     
    8272    NetworkFunctionBase(name)
    8373  {
    84     RegisterObject(NetworkMemberFunctionBase);
    85 
    8674    this->functorMap_[p] = this;
    8775    this->idMap_[ this->getNetworkID() ] = this;
Note: See TracChangeset for help on using the changeset viewer.