KDbUtils::PropertySet

Search for usage in LXR

KDbUtils::PropertySet Class Reference

#include <KDbUtils.h>

Inheritance diagram for KDbUtils::PropertySet:

Public Member Functions

 PropertySet (const PropertySet &other)
 
void insert (const QByteArray &name, const QVariant &value, const QString &caption=QString())
 
QList< QByteArraynames () const
 
bool operator!= (const PropertySet &other) const
 
PropertySetoperator= (const PropertySet &other)
 
bool operator== (const PropertySet &other) const
 
Property property (const QByteArray &name) const
 
void remove (const QByteArray &name)
 
void setCaption (const QByteArray &name, const QString &caption)
 
void setValue (const QByteArray &name, const QVariant &value)
 

Detailed Description

A set of properties.

Note
These properties are general-purpose and not related to Qt Properties.
See also
KDbUtils::Property

Definition at line 479 of file KDbUtils.h.

Member Function Documentation

◆ insert()

void PropertySet::insert ( const QByteArray name,
const QVariant value,
const QString caption = QString() 
)

Inserts property with a given name, value and caption.

If caption is empty, caption from existing property is reused. name must be a valid identifier (see KDb::isIdentifier()).

Definition at line 659 of file KDbUtils.cpp.

◆ names()

QList< QByteArray > PropertySet::names ( ) const
Returns
a list of property names.

Definition at line 704 of file KDbUtils.cpp.

◆ operator!=()

bool KDbUtils::PropertySet::operator!= ( const PropertySet other) const
inline
Returns
true if this property differs in at least one property from other
Since
3.1

Definition at line 497 of file KDbUtils.h.

◆ operator=()

PropertySet & PropertySet::operator= ( const PropertySet other)

Assigns other to this property set and returns a reference to this property set.

Definition at line 645 of file KDbUtils.cpp.

◆ operator==()

bool PropertySet::operator== ( const PropertySet other) const
Returns
true if this property set has exactly the same properties as other
Since
3.1

Definition at line 654 of file KDbUtils.cpp.

◆ property()

Property PropertySet::property ( const QByteArray name) const
Returns
property with a given name. If not found, a null Property is returned (Property::isNull).

Definition at line 698 of file KDbUtils.cpp.

◆ remove()

void PropertySet::remove ( const QByteArray name)

Removes property with a given name.

Definition at line 693 of file KDbUtils.cpp.

◆ setCaption()

void PropertySet::setCaption ( const QByteArray name,
const QString caption 
)

Sets caption for property name to caption.

If such property does not exist, does nothing.

Since
3.1

Definition at line 677 of file KDbUtils.cpp.

◆ setValue()

void PropertySet::setValue ( const QByteArray name,
const QVariant value 
)

Sets value for property name to value.

If such property does not exist, does nothing.

Since
3.1

Definition at line 685 of file KDbUtils.cpp.


The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2022 The KDE developers.
Generated on Thu Dec 8 2022 04:10:39 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.