MauiKit Controls
fmh.cpp
11 return std::accumulate(keys.begin(), keys.end(), QVector<int>(), [](QVector<int> &res, const FMH::MODEL_KEY &key) {
49 return std::accumulate(list.constBegin(), list.constEnd(), res, [](FMH::MODEL_LIST &res, const QVariant &item) -> FMH::MODEL_LIST {
58 return std::accumulate(list.constBegin(), list.constEnd(), res, [](QVariantList &res, const FMH::MODEL &item) -> QVariantList {
67 return std::accumulate(keys.constBegin(), keys.constEnd(), res, [=](FMH::MODEL &res, const FMH::MODEL_KEY &key) -> FMH::MODEL {
77 return std::accumulate(list.constBegin(), list.constEnd(), res, [key](QStringList &res, const FMH::MODEL &item) -> QStringList {
const FMH::MODEL filterModel(const FMH::MODEL &model, const QVector< FMH::MODEL_KEY > &keys)
Creates a new MODEL from another by filtering in the given array of MODEL_KEY.
Definition fmh.cpp:64
static const QHash< QString, MODEL_KEY > MODEL_NAME_KEY
The mapping of a string text into a FMH::MODEL_KEY.
Definition fmh.h:378
const QVariantList toMapList(const FMH::MODEL_LIST &list)
Creates a QVariantList from a MODEL_LIST.
Definition fmh.cpp:55
const QString mapValue(const QVariantMap &map, const FMH::MODEL_KEY &key)
Extracts a value associated with that given FMH::MODEL_KEY key in a map.
Definition fmh.cpp:17
const QVector< int > modelRoles(const FMH::MODEL &model)
Given a FMH::MODEL, this function will extract all the FMH::MODEL_KEY values used as the keys/roles.
Definition fmh.cpp:8
const FMH::MODEL_LIST toModelList(const QVariantList &list)
Creates a FMH::MODEL_LIST from a QVariantList.
Definition fmh.cpp:46
const QStringList modelToList(const FMH::MODEL_LIST &list, const FMH::MODEL_KEY &key)
Extracts from a MODEL_LIST the values from a given MODEL::KEY into a QStringList.
Definition fmh.cpp:74
QVector< MODEL > MODEL_LIST
An alias for a container of multiple FMH::MODEL key-value pairs.
Definition fmh.h:537
static const QHash< MODEL_KEY, QString > MODEL_NAME
The mapping of the FMH::MODEL_KEY enum values to its string representation.
Definition fmh.h:219
QHash< MODEL_KEY, QString > MODEL
The key-value pair model structure, where the values are strings.
Definition fmh.h:532
const FMH::MODEL toModel(const QVariantMap &map)
Converts a QVariantMap to a FMH::MODEl.
Definition fmh.cpp:34
const QVariantMap toMap(const FMH::MODEL &model)
Converts a FMH::MODEL object to a QVariantMap.
Definition fmh.cpp:22
bool exists() const const
iterator insert(const Key &key, const T &value)
QList< Key > keys() const const
const_iterator constBegin() const const
const_iterator constEnd() const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2025 The KDE developers.
Generated on Fri Feb 7 2025 11:57:28 by doxygen 1.13.2 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2025 The KDE developers.
Generated on Fri Feb 7 2025 11:57:28 by doxygen 1.13.2 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.