The MessageFilter element specifies a message filter for MessageModel More...
This element was introduced in Mobility 1.1.
This element is part of the QtMobility.messaging 1.1 module.
Logical combinations of MessageFilters can be formed using MessageIntersectionFilter and MessageUnionFilter.
Setting negated to true will negate the filter.
The following example creates a filter which filters for messages less than 1024 bytes in size from martin or don, excluding replies from martin. The messages will be sorted by descending timestamp.
model: MessageModel { sortBy: MessageModel.Timestamp sortOrder: MessageModel.DescendingOrder filter: MessageIntersectionFilter { MessageFilter { type: MessageFilter.Size value: 1024 comparator: MessageFilter.LessThan } MessageUnionFilter { MessageIntersectionFilter { MessageFilter { type: MessageFilter.Sender value: "martin" comparator: MessageFilter.Includes } MessageFilter { negated: true type: MessageFilter.Subject value: "re:" comparator: MessageFilter.Includes } } MessageFilter { type: MessageFilter.Sender value: "don" comparator: MessageFilter.Includes } } } }
See also MessageUnionFilter and MessageIntersectionFilter.
comparator : enumeration |
Holds the type of comparison to apply.
comparator may be one of the following:
Note that not all comparators make sense for all filter types. For example the relational comparators (LessThan, GreaterThan, etc.) make sense for Size filters, but the inclusion comprators (Includes, Excludes) do not.
This property group was introduced in Mobility 1.1.
negated : bool |
Setting negated to true will result in the filter being locially negated.
This property group was introduced in Mobility 1.1.
type : enumeration |
Holds the field to filter on.
type may be one of the following:
Filter type | value type |
---|---|
MessageFilter.AncestorFolder | string |
MessageFilter.ParentFolder | string |
MessageFilter.Priority | enumeration
|
MessageFilter.Recipients | string |
MessageFilter.Sender | string |
MessageFilter.Size | int |
MessageFilter.StandardFolder | enumeration
|
MessageFilter.Status | enumeration
|
MessageFilter.Subject | string |
MessageFilter.Timestamp | Date |
MessageFilter.ReceptionTimestamp | Date |
MessageFilter.Type | enumeration
|
This property group was introduced in Mobility 1.1.
© 2008-2011 Nokia Corporation and/or its subsidiaries. Nokia, Qt and their respective logos are trademarks of Nokia Corporation in Finland and/or other countries worldwide.
All other trademarks are property of their respective owners. Privacy Policy
Licensees holding valid Qt Commercial licenses may use this document in accordance with the Qt Commercial License Agreement provided with the Software or, alternatively, in accordance with the terms contained in a written agreement between you and Nokia.
Alternatively, this document may be used under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation.