6#ifndef SWIFT_MISC_NAMEVARIANPAIRTLIST_H
7#define SWIFT_MISC_NAMEVARIANPAIRTLIST_H
Generic ordered container with value semantics.
Value object for icons. An icon is stored in the global icon repository and identified by its index....
Value object encapsulating a list of name/variant pairs.
QStringList getNames(bool sorted=true) const
Get all names.
CNameVariantPair getValue(const QString &name) const
Get value.
int getIndexForName(const QString &name) const
Get name's index, -1 if not found.
CSequence()=default
Default constructor.
CVariant getVariantValue(const QString &name) const
Get pair's variant value or default if not existing.
QString getValueAsString(const QString &name) const
Get pair's variant value as string (empty if not existing).
bool addOrReplaceValue(const QString &name, const CVariant &value, const CIcon &icon=CIcon())
Add value, if name already exists replace (true) If one is sure(!) the name does not exists,...
bool containsName(const QString &name) const
Contains name.
CNameVariantPairList()=default
Default constructor.
CSequence()=default
Default constructor.
Q_REQUIRED_RESULT CSequence sorted(Predicate p) const
Wrapper around QVariant which provides transparent access to CValueObject methods of the contained ob...
Free functions in swift::misc.
#define SWIFT_DECLARE_SEQUENCE_MIXINS(Namespace, T, List)
Explicit template declaration of mixins for a CSequence subclass to be placed near the top of the hea...
#define SWIFT_MISC_EXPORT
Export a class or function from the library.