Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Apr 26, 2015, 3:10:58 PM (9 years ago)
Author:
landauf
Message:

use typeid(T) instead of typeid(T).name() to identify a class. this avoids ambiguity if two classes in different anonymous namespaces use the same name.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/core7/src/libraries/core/class/IdentifierManager.h

    r10395 r10399  
    3838
    3939#include <map>
     40#include <set>
    4041#include <list>
    4142#include <string>
     
    7475            Identifier* getIdentifierByLowercaseString(const std::string& name);
    7576            Identifier* getIdentifierByID(uint32_t id);
    76             Identifier* getIdentifierByTypeidName(const std::string& typeidName);
     77            Identifier* getIdentifierByTypeInfo(const std::type_info& typeInfo);
    7778
    7879            void clearNetworkIDs();
     
    100101                { hierarchyCreatingCounter_s--; }
    101102
    102             std::map<std::string, Identifier*> identifierByTypeidName_;      //!< Map with the names as received by typeid(). This is only used internally.
    103 
     103            std::set<Identifier*> identifiers_;                              //!< All identifiers. This is only used internally.
    104104            std::map<std::string, Identifier*> identifierByString_;          //!< Map that stores all Identifiers with their names.
    105105            std::map<std::string, Identifier*> identifierByLowercaseString_; //!< Map that stores all Identifiers with their names in lowercase.
Note: See TracChangeset for help on using the changeset viewer.