QOrganizerItemDetailRangeFilter Class

The QOrganizerItemDetailRangeFilter class provides a filter based around a detail value range criterion. More...

Header: #include <QOrganizerItemDetailRangeFilter>
Inherits: QOrganizerItemFilter

Public Types

enum RangeFlag { IncludeLower, IncludeUpper, ExcludeLower, ExcludeUpper }
flags RangeFlags

Public Functions

QOrganizerItemDetailRangeFilter()
QOrganizerItemDetailRangeFilter(const QOrganizerItemFilter &other)
int detailField() const
QOrganizerItemDetail::DetailType detailType() const
QOrganizerItemFilter::MatchFlags matchFlags() const
QVariant maxValue() const
QVariant minValue() const
RangeFlags rangeFlags() const
void setDetail(QOrganizerItemDetail::DetailType detailType, int field = -1)
void setMatchFlags(QOrganizerItemFilter::MatchFlags flags)
void setRange(const QVariant &min, const QVariant &max, RangeFlags flags = 0)

Detailed Description

The QOrganizerItemDetailRangeFilter class provides a filter based around a detail value range criterion.

It may be used to select organizer items which contain a detail of a particular type, whose value falls in a particular range.

Member Type Documentation

enum QOrganizerItemDetailRangeFilter::RangeFlag
flags QOrganizerItemDetailRangeFilter::RangeFlags

This enumeration describes the semantics of the boundary conditions of the detail range filter.

ConstantValue
QOrganizerItemDetailRangeFilter::IncludeLower0
QOrganizerItemDetailRangeFilter::IncludeUpper1
QOrganizerItemDetailRangeFilter::ExcludeLower2
QOrganizerItemDetailRangeFilter::ExcludeUpper0

The RangeFlags type is a typedef for QFlags<RangeFlag>. It stores an OR combination of RangeFlag values.

Member Function Documentation

QOrganizerItemDetailRangeFilter::QOrganizerItemDetailRangeFilter()

Constructs a new detail range filter.

QOrganizerItemDetailRangeFilter::QOrganizerItemDetailRangeFilter(const QOrganizerItemFilter &other)

Constructs a copy of other if possible, otherwise constructs a new detail range filter.

int QOrganizerItemDetailRangeFilter::detailField() const

Returns the detail field containing the value which will be matched against the value criterion.

See also setDetail().

QOrganizerItemDetail::DetailType QOrganizerItemDetailRangeFilter::detailType() const

Returns the type of the detail which will be inspected for matching values.

See also setDetail().

QOrganizerItemFilter::MatchFlags QOrganizerItemDetailRangeFilter::matchFlags() const

Returns the match flags of the criterion, which define semantics such as case sensitivity, prefix matching, exact matching, etc.

See also setMatchFlags().

QVariant QOrganizerItemDetailRangeFilter::maxValue() const

Returns the upper bound of the value range criterion.

See also setRange().

QVariant QOrganizerItemDetailRangeFilter::minValue() const

Returns the lower bound of the value range criterion.

See also setRange().

RangeFlags QOrganizerItemDetailRangeFilter::rangeFlags() const

Returns a set of flags which defines the boundary condition semantics of the value range criterion.

See also setRange().

void QOrganizerItemDetailRangeFilter::setDetail(QOrganizerItemDetail::DetailType detailType, int field = -1)

Sets the type of detail which will be matched to detailType, and the field of the detail which will contain the value criterion to field.

If detailType is QOrganizerItemDetail::TypeUndefined, the detail filter will match no organizer items. If field is not specified, or equal to -1, the detail filter acts like a "detail exists" filter; if any detail of the specified type is present in the organizer item, that organizer item will match the filter, regardless of what values might be stored in that detail.

See also detailType() and detailField().

void QOrganizerItemDetailRangeFilter::setMatchFlags(QOrganizerItemFilter::MatchFlags flags)

Sets the match flags of the filter criterion to flags.

Not all flags are supported by a range filter. The supported flags include:

Unsupported flags will be ignored.

See also matchFlags().

void QOrganizerItemDetailRangeFilter::setRange(const QVariant &min, const QVariant &max, RangeFlags flags = 0)

Sets the value range criterion of the filter to within min and max, with boundary conditions specified in the given flags.

See also minValue(), maxValue(), and rangeFlags().