|
Q_INVOKABLE qint64 | count (const QString &typeName) const |
| Counts the number of datasets for the given type. More...
|
|
Q_INVOKABLE QStringList | keys (const QString &typeName) const |
| Returns all saved keys for the given type. More...
|
|
Q_INVOKABLE QVariantList | loadAll (const QString &typeName) const |
| Loads all existing datasets for the given type. More...
|
|
Q_INVOKABLE QT_DATASYNC_REVISION_2 bool | contains (const QString &typeName, const QString &key) const |
| Checks if a dataset exists in the store for the given key. More...
|
|
Q_INVOKABLE QVariant | load (const QString &typeName, const QString &key) const |
| Loads the dataset with the given key for the given type. More...
|
|
Q_INVOKABLE void | save (const QString &typeName, const QVariant &value) |
| Saves the given dataset in the store. More...
|
|
Q_INVOKABLE bool | remove (const QString &typeName, const QString &key) |
| Removes the dataset with the given key for the given type. More...
|
|
Q_INVOKABLE QVariantList | search (const QString &typeName, const QString &query, DataStore::SearchMode mode=DataStore::RegexpMode) const |
| Searches the store for datasets of the given type where the key matches the query. More...
|
|
Q_INVOKABLE void | clear (const QString &typeName) |
| Removes all datasets of the given type from the store. More...
|
|
Q_INVOKABLE QString | typeName (int typeId) const |
| Returns the name of the type identified by the given type id. More...
|
|
| DataStore (QObject *parent=nullptr) |
| Default constructor, uses the default setup. More...
|
|
| DataStore (const QString &setupName, QObject *parent=nullptr) |
| Constructor with an explicit setup. More...
|
|
QString | setupName () const |
| Returns the name of the setup this class operates on. More...
|
|
qint64 | count (int metaTypeId) const |
| Counts the number of datasets for the given type. More...
|
|
QStringList | keys (int metaTypeId) const |
| Returns all saved keys for the given type. More...
|
|
QVariantList | loadAll (int metaTypeId) const |
| Loads all existing datasets for the given type. More...
|
|
bool | contains (int metaTypeId, const QString &key) const |
| Checks if a dataset exists in the store for the given key. More...
|
|
bool | contains (int metaTypeId, const QVariant &key) const |
| Checks if a dataset exists in the store for the given key. More...
|
|
QVariant | load (int metaTypeId, const QString &key) const |
| Loads the dataset with the given key for the given type. More...
|
|
QVariant | load (int metaTypeId, const QVariant &key) const |
| Loads the dataset with the given key for the given type. More...
|
|
void | save (int metaTypeId, QVariant value) |
| Saves the given dataset in the store. More...
|
|
bool | remove (int metaTypeId, const QString &key) |
| Removes the dataset with the given key for the given type. More...
|
|
bool | remove (int metaTypeId, const QVariant &key) |
| Removes the dataset with the given key for the given type. More...
|
|
void | update (int metaTypeId, QObject *object) const |
| Loads the dataset with the given key for the given type into the existing object by updating it's properties. More...
|
|
QVariantList | search (int metaTypeId, const QString &query, SearchMode mode=RegexpMode) const |
| Searches the store for datasets of the given type where the key matches the query. More...
|
|
void | iterate (int metaTypeId, const std::function< bool(QVariant)> &iterator) const |
| Iterates over all existing datasets of the given types. More...
|
|
void | iterate (int metaTypeId, const std::function< bool(QVariant)> &iterator, bool skipBroken) const |
| Iterates over all existing datasets of the given types. More...
|
|
void | clear (int metaTypeId) |
| Removes all datasets of the given type from the store. More...
|
|
template<typename T > |
quint64 | count () const |
| Counts the number of datasets for the given type. More...
|
|
template<typename T > |
QStringList | keys () const |
| Returns all saved keys for the given type. More...
|
|
template<typename T , typename K > |
QList< K > | keys () const |
| Returns all saved keys for the given type. More...
|
|
template<typename T > |
QList< T > | loadAll () const |
| Loads all existing datasets for the given type. More...
|
|
template<typename T > |
bool | contains (const QString &key) const |
| Checks if a dataset exists in the store for the given key. More...
|
|
template<typename T , typename K > |
bool | contains (const K &key) const |
| Checks if a dataset exists in the store for the given key. More...
|
|
template<typename T > |
T | load (const QString &key) const |
| Loads the dataset with the given key for the given type. More...
|
|
template<typename T , typename K > |
T | load (const K &key) const |
| Loads the dataset with the given key for the given type. More...
|
|
template<typename T > |
void | save (const T &value) |
| Saves the given dataset in the store. More...
|
|
template<typename T > |
bool | remove (const QString &key) |
| Removes the dataset with the given key for the given type. More...
|
|
template<typename T , typename K > |
bool | remove (const K &key) |
| Removes the dataset with the given key for the given type. More...
|
|
template<typename T > |
void | update (T object) const |
| Loads the dataset with the given key for the given type into the existing object by updating it's properties. More...
|
|
template<typename T > |
QList< T > | search (const QString &query, SearchMode mode=RegexpMode) const |
| Searches the store for datasets of the given type where the key matches the query. More...
|
|
template<typename T > |
void | iterate (const std::function< bool(T)> &iterator, bool skipBroken=false) const |
| Iterates over all existing datasets of the given types. More...
|
|
template<typename T > |
void | clear () |
| Removes all datasets of the given type from the store. More...
|
|
virtual const QMetaObject * | metaObject () const const |
|
virtual void * | qt_metacast (const char *) |
|
virtual int | qt_metacall (QMetaObject::Call, int, void **) |
|
| QObject (QObject *parent) |
|
virtual bool | event (QEvent *e) |
|
virtual bool | eventFilter (QObject *watched, QEvent *event) |
|
QString | objectName () const const |
|
void | setObjectName (const QString &name) |
|
bool | isWidgetType () const const |
|
bool | isWindowType () const const |
|
bool | signalsBlocked () const const |
|
bool | blockSignals (bool block) |
|
QThread * | thread () const const |
|
void | moveToThread (QThread *targetThread) |
|
int | startTimer (int interval, Qt::TimerType timerType) |
|
int | startTimer (std::chrono::milliseconds time, Qt::TimerType timerType) |
|
void | killTimer (int id) |
|
T | findChild (const QString &name, Qt::FindChildOptions options) const const |
|
QList< T > | findChildren (const QString &name, Qt::FindChildOptions options) const const |
|
QList< T > | findChildren (const QRegExp ®Exp, Qt::FindChildOptions options) const const |
|
QList< T > | findChildren (const QRegularExpression &re, Qt::FindChildOptions options) const const |
|
const QObjectList & | children () const const |
|
void | setParent (QObject *parent) |
|
void | installEventFilter (QObject *filterObj) |
|
void | removeEventFilter (QObject *obj) |
|
QMetaObject::Connection | connect (const QObject *sender, const char *signal, const char *method, Qt::ConnectionType type) const const |
|
bool | disconnect (const char *signal, const QObject *receiver, const char *method) const const |
|
bool | disconnect (const QObject *receiver, const char *method) const const |
|
void | dumpObjectTree () |
|
void | dumpObjectInfo () |
|
void | dumpObjectTree () const const |
|
void | dumpObjectInfo () const const |
|
bool | setProperty (const char *name, const QVariant &value) |
|
QVariant | property (const char *name) const const |
|
QList< QByteArray > | dynamicPropertyNames () const const |
|
void | destroyed (QObject *obj) |
|
void | objectNameChanged (const QString &objectName) |
|
QObject * | parent () const const |
|
bool | inherits (const char *className) const const |
|
void | deleteLater () |
|
|
enum | SearchMode {
RegexpMode,
WildcardMode,
ContainsMode,
StartsWithMode,
EndsWithMode
} |
| Possible pattern modes for the search mechanism. More...
|
|
QString | tr (const char *sourceText, const char *disambiguation, int n) |
|
QString | trUtf8 (const char *sourceText, const char *disambiguation, int n) |
|
QMetaObject::Connection | connect (const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type) |
|
QMetaObject::Connection | connect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method, Qt::ConnectionType type) |
|
QMetaObject::Connection | connect (const QObject *sender, PointerToMemberFunction signal, const QObject *receiver, PointerToMemberFunction method, Qt::ConnectionType type) |
|
QMetaObject::Connection | connect (const QObject *sender, PointerToMemberFunction signal, Functor functor) |
|
QMetaObject::Connection | connect (const QObject *sender, PointerToMemberFunction signal, const QObject *context, Functor functor, Qt::ConnectionType type) |
|
bool | disconnect (const QObject *sender, const char *signal, const QObject *receiver, const char *method) |
|
bool | disconnect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method) |
|
bool | disconnect (const QMetaObject::Connection &connection) |
|
bool | disconnect (const QObject *sender, PointerToMemberFunction signal, const QObject *receiver, PointerToMemberFunction method) |
|
QObject * | sender () const const |
|
int | senderSignalIndex () const const |
|
int | receivers (const char *signal) const const |
|
bool | isSignalConnected (const QMetaMethod &signal) const const |
|
virtual void | timerEvent (QTimerEvent *event) |
|
virtual void | childEvent (QChildEvent *event) |
|
virtual void | customEvent (QEvent *event) |
|
virtual void | connectNotify (const QMetaMethod &signal) |
|
virtual void | disconnectNotify (const QMetaMethod &signal) |
|