|
swift
|
Property index. More...
Public Member Functions | |
| CPropertyIndex ()=default | |
| Default constructor. | |
| CPropertyIndex (int singleProperty) | |
| Non nested index. | |
| CPropertyIndex (std::initializer_list< int > il) | |
| Initializer list constructor. | |
| CPropertyIndex (const QList< int > &indexes) | |
| Construct from a list of indexes. | |
| CPropertyIndex (const QString &indexes) | |
| From string. | |
| operator CPropertyIndexRef () const | |
| Return a simplified non-owning reference. | |
| Q_REQUIRED_RESULT CPropertyIndex | copyFrontRemoved () const |
| Copy with first element removed. | |
| bool | isNested () const |
| Is nested index? | |
| bool | isMyself () const |
| Myself index, used with nesting. | |
| bool | isEmpty () const |
| Empty? | |
| QList< int > | indexList () const |
| Index list. | |
| void | prepend (int newLeftIndex) |
| Shift existing indexes to right and insert given index at front. | |
| bool | contains (int index) const |
| Contains index? | |
| template<class EnumType > | |
| bool | contains (EnumType ev) const |
| Compare with index given by enum. | |
| int | frontToInt () const |
| Front to integer. | |
| bool | startsWith (int index) const |
| Starts with given index? | |
| template<class CastType > | |
| CastType | frontCasted () const |
| First element casted to given type, usually the PropertIndex enum. | |
| template<class EnumType > | |
| bool | startsWithPropertyIndexEnum (EnumType ev) const |
| Compare with index given by enum. | |
| auto | comparator () const |
| Return a predicate function which can compare two objects based on this index. | |
| QString | convertToQString (bool i18n=false) const |
| Cast as QString. More... | |
| QJsonObject | toJson () const |
| Cast to JSON object. More... | |
| void | convertFromJson (const QJsonObject &json) |
| Assign from JSON object. More... | |
Public Member Functions inherited from swift::misc::mixin::MetaType< CPropertyIndex > | |
| int | getMetaTypeId () const |
| Returns the Qt meta type ID of this object. More... | |
| QString | getClassName () const |
| Class name. | |
| bool | isA (int metaTypeId) const |
| Returns true if this object is an instance of the class with the given meta type ID, or one of its subclasses. | |
Public Member Functions inherited from swift::misc::mixin::DBusByMetaClass< CPropertyIndex > | |
| void | marshallToDbus (QDBusArgument &arg, Tags...) const |
| Marshall without begin/endStructure, for when composed within another object. | |
| void | unmarshallFromDbus (const QDBusArgument &arg, Tags...) |
| Unmarshall without begin/endStructure, for when composed within another object. | |
Public Member Functions inherited from swift::misc::mixin::DataStreamByMetaClass< CPropertyIndex > | |
| void | marshalToDataStream (QDataStream &stream) const |
| Marshal a value to a QDataStream. | |
| void | unmarshalFromDataStream (QDataStream &stream) |
| Unmarshal a value from a QDataStream. | |
Public Member Functions inherited from swift::misc::mixin::String< CPropertyIndex > | |
| QString | toQString (bool i18n=false) const |
| Cast as QString. | |
| std::string | toStdString (bool i18n=false) const |
| To std string. | |
| QString | stringForStreaming () const |
| String for streaming operators. | |
Static Public Member Functions | |
| static const CPropertyIndex & | empty () |
| an empty property index | |
Static Public Member Functions inherited from swift::misc::mixin::MetaType< CPropertyIndex > | |
| static void | registerMetadata () |
| Register metadata. | |
Protected Member Functions | |
| void | parseFromString (const QString &indexes) |
| Parse indexes from string. | |
Property index.
The index can be nested, that's why it is a sequence (e.g. PropertyIndexPilot, PropertyIndexRealname).
Definition at line 34 of file propertyindex.h.
| void swift::misc::CPropertyIndex::convertFromJson | ( | const QJsonObject & | json | ) |
Assign from JSON object.
Definition at line 76 of file propertyindex.cpp.
| QString swift::misc::CPropertyIndex::convertToQString | ( | bool | i18n = false | ) | const |
Cast as QString.
Definition at line 41 of file propertyindex.cpp.
| QJsonObject swift::misc::CPropertyIndex::toJson | ( | ) | const |
Cast to JSON object.
Definition at line 69 of file propertyindex.cpp.