18#ifndef ELEMENTS_COLLECTION_CACHE_H
19#define ELEMENTS_COLLECTION_CACHE_H
23#include <QSqlDatabase>
52 const QUuid &uuid = QUuid::createUuid());
54 const QUuid &uuid = QUuid::createUuid());
Definition elementscollectioncache.h:32
QSqlQuery * insert_name_
Prepared statement to insert names into the cache.
Definition elementscollectioncache.h:61
bool fetchNameFromCache(const QString &path, const QUuid &uuid)
ElementsCollectionCache::fetchNameFromCache Retrieve the name for an element, given its path and uuid...
Definition elementscollectioncache.cpp:223
bool setPixmapStorageFormat(const QString &)
Definition elementscollectioncache.cpp:121
bool cachePixmap(const QString &path, const QUuid &uuid=QUuid::createUuid())
ElementsCollectionCache::cachePixmap Cache the current (i.e. last retrieved) pixmap.
Definition elementscollectioncache.cpp:306
QSqlQuery * select_pixmap_
Prepared statement to fetch pixmaps from the cache.
Definition elementscollectioncache.h:60
void setLocale(const QString &)
Definition elementscollectioncache.cpp:103
QString pixmapStorageFormat() const
Definition elementscollectioncache.cpp:133
bool cacheName(const QString &path, const QUuid &uuid=QUuid::createUuid())
ElementsCollectionCache::cacheName Cache the current (i.e. last retrieved) name The cache entry will ...
Definition elementscollectioncache.cpp:283
QString current_name_
Last name fetched.
Definition elementscollectioncache.h:65
bool fetchData(const ElementsLocation &)
Definition elementscollectioncache.cpp:199
QPixmap pixmap() const
Definition elementscollectioncache.cpp:187
QSqlDatabase cache_db_
Object providing access to the SQLite database this cache relies on.
Definition elementscollectioncache.h:58
QString name() const
Definition elementscollectioncache.cpp:179
QSqlQuery * insert_pixmap_
Prepared statement to insert pixmaps into the cache.
Definition elementscollectioncache.h:62
QString pixmap_storage_format_
Storage format for cached pixmaps.
Definition elementscollectioncache.h:64
QString locale_
Locale to be used when dealing with names.
Definition elementscollectioncache.h:63
bool fetchElement(ElementsLocation &location)
ElementsCollectionCache::fetchElement Retrieve the data for a given element, using the cache if avail...
Definition elementscollectioncache.cpp:147
QPixmap current_pixmap_
Last pixmap fetched.
Definition elementscollectioncache.h:66
bool fetchPixmapFromCache(const QString &path, const QUuid &uuid)
ElementsCollectionCache::fetchPixmapFromCache Retrieve the pixmap for an element, given its path and ...
Definition elementscollectioncache.cpp:252
~ElementsCollectionCache() override
Definition elementscollectioncache.cpp:90
QSqlQuery * select_name_
Prepared statement to fetch names from the cache.
Definition elementscollectioncache.h:59
QString locale() const
Definition elementscollectioncache.cpp:110
The ElementsLocation class This class represents the location, the location of an element or of a cat...
Definition elementslocation.h:47