Revision a873a3ba
Von Christian Ehringfeld vor etwa 8 Jahren hinzugefügt
src/cache.cpp | ||
---|---|---|
#include "entityhelper.h"
|
||
using namespace CuteEntityManager;
|
||
Cache::Cache() {
|
||
|
||
}
|
||
QHash<QString, QWeakPointer<Entity> > Cache::getCache() const {
|
||
QHash<QString, QWeakPointer<Entity>> Cache::getCache() const {
|
||
return cache;
|
||
}
|
||
|
||
... | ... | |
return false;
|
||
}
|
||
|
||
void Cache::clear() {
|
||
this->cache.clear();
|
||
}
|
||
|
||
void Cache::insert(QSharedPointer<Entity> &entity) {
|
||
if (entity && entity->getId() > -1) {
|
||
QString key = this->generateKey(entity->getId(),
|
Auch abrufbar als: Unified diff
closes #614