SpaghettiKart
Loading...
Searching...
No Matches
DataRegistry< TObject > Class Template Reference

#include <DataRegistry.h>

Collaboration diagram for DataRegistry< TObject >:
[legend]

Public Member Functions

void Add (const std::string &resourceName, TObject &&object)
 
void Add (const std::string &resourceName, const TObject &object)
 
TObject * Get (const std::string &resourceName)
 
const TObject * Get (const std::string &resourceName) const
 
bool Remove (const std::string &resourceName)
 
size_t Size () const
 
void Clear ()
 

Private Attributes

std::unordered_map< std::string, std::unique_ptr< TObject > > mMap
 

Member Function Documentation

◆ Add() [1/2]

template<typename TObject>
void DataRegistry< TObject >::Add ( const std::string & resourceName,
const TObject & object )
inline

◆ Add() [2/2]

template<typename TObject>
void DataRegistry< TObject >::Add ( const std::string & resourceName,
TObject && object )
inline
Here is the caller graph for this function:

◆ Clear()

template<typename TObject>
void DataRegistry< TObject >::Clear ( )
inline

◆ Get() [1/2]

template<typename TObject>
TObject * DataRegistry< TObject >::Get ( const std::string & resourceName)
inline

◆ Get() [2/2]

template<typename TObject>
const TObject * DataRegistry< TObject >::Get ( const std::string & resourceName) const
inline

◆ Remove()

template<typename TObject>
bool DataRegistry< TObject >::Remove ( const std::string & resourceName)
inline

◆ Size()

template<typename TObject>
size_t DataRegistry< TObject >::Size ( ) const
inline

Field Documentation

◆ mMap

template<typename TObject>
std::unordered_map<std::string, std::unique_ptr<TObject> > DataRegistry< TObject >::mMap
private

The documentation for this class was generated from the following file: