Anim 0.1
|
Specialised container mapping stringID to entities owned by this container. More...
#include <StringIDMap.h>
Public Member Functions | |
StringId | ToID (std::string const &key) const |
Converts a string to a stringID, stores this result for later retrieval. | |
std::string | ToString (StringId const key) const |
Converts a string to a stringID, if this map has never seen this stringID then this operation will fail and will return an empty string. | |
void | Add (string const &key, Ptr< T > item) |
void | Remove (string const &key) |
T & | Get (string const &key) const |
T & | Get (StringId const id) const |
ValueResult< std::reference_wrapper< T > > | TryGet (string const &key) const |
ValueResult< std::reference_wrapper< T > > | TryGet (StringId key) const |
vector< StringId > | GetAllKeyIDs () const |
std::vector< string > | GetAllKeyStrings () const |
void | Foreach (std::function< void(T &)> &&functionDelegate) const |
Performs the provided function on each value in the collection. | |
int | Count () const |
bool | Contains (string const &key) const |
bool | Contains (StringId const id) const |
Specialised container mapping stringID to entities owned by this container.
T | Entity contained type |
Ptr | The type of smart pointer this container uses |