Home · All Classes · Annotated · Functions

QCategoryFilter Class Reference

The QCategoryFilter class filters category sets. More...

#include <QCategoryFilter>

Public Types

Public Functions


Detailed Description

The QCategoryFilter class filters category sets.

The QCategoryFilter class allows consistent filtering of records or objects that have a set of categories assigned. It also provides methods to store the current filtering method in a QSettings file.


Member Type Documentation

enum QCategoryFilter::FilterType

ConstantValueDescription
QCategoryFilter::List0Only accept category sets that contain all of the required categories.
QCategoryFilter::Unfiled1Only accept empty category sets.
QCategoryFilter::All2Accept all category sets.


Member Function Documentation

QCategoryFilter::QCategoryFilter ()

Constructs a QCategoryFilter object. By default this object will accept all category sets.

QCategoryFilter::QCategoryFilter ( FilterType t )

Constructs a QCategoryFilter object of the type t.

See also FilterType.

QCategoryFilter::QCategoryFilter ( const QList<QString> & set )

Constructs a QCategoryFilter object that only accepts category sets containing all the categories listed in set.

QCategoryFilter::QCategoryFilter ( const QString & c )

Constructs a QCategoryFilter object that only accepts category sets containing the category c.

QCategoryFilter::QCategoryFilter ( const QCategoryFilter & other )

Constructs a QCategoryFilter object as a copy of other.

QCategoryFilter::~QCategoryFilter ()

Destroys a QCategoryFilter object.

bool QCategoryFilter::acceptAll () const

Returns true if the QCategoryFilterObject accepts all category sets. Otherwise returns false.

bool QCategoryFilter::acceptUnfiledOnly () const

Returns true if the QCategoryFilterObject only accepts empty category sets. Otherwise returns false.

bool QCategoryFilter::accepted ( const QList<QString> & list ) const

Returns true if the set of categories described by list is accepted by the QCategoryFilter object. Otherwise returns false.

QString QCategoryFilter::label ( const QString & scope = QString() ) const

Returns a translated string that briefly describe the QCategoryFilter object. scope specifies the scope in which to search for the label.

void QCategoryFilter::readConfig ( const QSettings & c, const QString & key )

Reads the QCategoryFilter from the QSettings file c using the key key.

See also writeConfig().

QList<QString> QCategoryFilter::requiredCategories () const

Returns the list of categories that must be in a set for the set to be accepted.

void QCategoryFilter::writeConfig ( QSettings & c, const QString & key ) const

Writes the QCategoryFilter to the QSettings file c using the key key.

See also readConfig().

bool QCategoryFilter::operator!= ( const QCategoryFilter & other ) const

Returns true if the QCategoryFilter object is not equivilent to other. Otherwise returns false.

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

Assigns the QCategoryFilter object to be a copy of other.

bool QCategoryFilter::operator== ( const QCategoryFilter & other ) const

Returns true if the QCategoryFilter object is equivilent to other. Otherwise returns false.


Copyright © 2006 Trolltech Trademarks
Qtopia 4.1.7