ContactListFilters
#include <bb/pim/contacts/ContactListFilters>
To link against this class, add the following line to your .pro file: LIBS += -lbbpim
The ContactListFilters class represents a set of filters that are used for listing and sorting contacts.
You can use this class to list and sort Contact objects. This class is designed to work with ContactService::contacts() to specify the number, type, and sorting of the contacts that are returned.
BlackBerry 10.0.0
Public Functions Index
| ContactListFilters () | |
| ContactListFilters (const ContactListFilters ©) | |
| ~ContactListFilters () | |
| ContactListFilters & | operator= (const ContactListFilters &operand) |
| QVariantList | contactIds () const |
| int | limit () const |
| ContactId | anchorId () const |
| int | offset () const |
| bool | isFavourite () const |
| bool | isVideoChatContact () const |
| ContactListFilters & | setContactIds (QList< int > &contactIds) |
| ContactListFilters & | setLimit (int limit) |
| ContactListFilters & | setHasKindSubkind (const KindSubKindSpecifier present) |
| ContactListFilters & | setHasKindSubkind (const QSet< KindSubKindSpecifier > &present) |
| ContactListFilters & | setIsFavourite (bool isFavourite) |
| ContactListFilters & | setIsVideoChatContact (bool isVideoChatContact) |
| ContactListFilters & | setHasAttribute (AttributeKind::Type present) |
| ContactListFilters & | setHasAttribute (const QSet< AttributeKind::Type > &present) |
| ContactListFilters & | setAnchorId (ContactId contactId, bool inclusive=false) |
| ContactListFilters & | setOffset (int offset) |
| ContactListFilters & | setSortBy (SortColumn::Type column, SortOrder::Type order) |
| ContactListFilters & | setSortBy (const SortSpecifier &sort) |
| ContactListFilters & | setSortBy (const QList< SortSpecifier > &sorts) |
| ContactListFilters & | setSortAndAnchorBy (const AnchorValueSpecifier &anchorValue) |
| ContactListFilters & | setSortAndAnchorBy (const QList< AnchorValueSpecifier > &anchorValues) |
| ContactListFilters & | setHasAccount (AccountId accountId) |
| ContactListFilters & | setHasAccounts (const QList< AccountId > &accountId) |
| ContactListFilters & | setExcludeAccount (AccountId accountId) |
| ContactListFilters & | setExcludeAccounts (const QList< AccountId > &accountId) |
| ContactListFilters & | setExcludeAccount (AccountId accountId, bool includeMergedContacts) |
| ContactListFilters & | setExcludeAccounts (const QList< AccountId > &accountId, bool includeMergedContacts) |
| ContactListFilters & | setIncludePhotos (bool value) |
| ContactListFilters & | setIncludeAttribute (AttributeKind::Type kind) |
| ContactListFilters & | setIncludeAttributes (const QList< AttributeKind::Type > &kinds) |
| ContactListFilters & | setIncludePostalAddress (bool value) |
Public Functions
Copy constructor.
This function constructs a ContactListFilters containing exactly the same values as the provided ContactListFilters.
| Parameters | |
|---|---|
| copy |
The ContactListFilters to be copied. |
BlackBerry 10.0.0
Destructor.
BlackBerry 10.0.0
ContactListFilters &
Assignment operator.
This operator copies all values from the provided ContactListFilters into this ContactListFilters.
| Parameters | |
|---|---|
| operand |
The ContactListFilters from which to copy all values. |
A ContactListFilters with all copied data
BlackBerry 10.0.0
QVariantList
Retrieves the list of contact IDs that are associated with this ContactListFilters.
A list of contact IDs that are associated with this ContactListFilters.
BlackBerry 10.0.0
int
Retrieves the result limit of this ContactListFilters.
This value represents the maximum number of results that are returned for the contact list.
The result limit of this ContactListFilters.
BlackBerry 10.0.0
ContactId
Retrieves the anchor ID of this ContactListFilters.
This function returns the anchor ID of the contact for the list of contacts that you receive by calling ContactService::contacts().
The anchor ID of this ContactListFilters.
BlackBerry 10.0.0
int
retrieve the offset of this ContactListFilters
This value represent the place to start query from
The offset of this ContactListFilters
BlackBerry 10.0.0
bool
Indicates whether only favorite contacts are returned when using this ContactListFilters.
true if only favorite contacts are returned, false otherwise.
BlackBerry 10.0.0
bool
Indicates whether only video chat contacts are returned when using this ContactListFilters.
true if only video chat contacts are returned, false otherwise.
BlackBerry 10.0.0
ContactListFilters &
Sets the list of contact IDs that are returned when using this ContactListFilters.
| Parameters | |
|---|---|
| contactIds |
The list of contact IDs that should be returned. |
A ContactListFilters with the provided list of contact IDs.
BlackBerry 10.0.0
ContactListFilters &
Sets the result limit of this ContactListFilters.
This value represents the maximum number of results that are returned for the contact list.
| Parameters | |
|---|---|
| limit |
The maximum number of results that are returned. |
A ContactListFilters with the provided result limit.
BlackBerry 10.0.0
ContactListFilters &
Filters the returned contact list to contain only contacts with the provided kind/sub-kind combination.
| Parameters | |
|---|---|
| present |
The kind/sub-kind combination to filter based on. |
A ContactListFilters with the provided kind/sub-kind combination filter.
BlackBerry 10.0.0
ContactListFilters &
Filters the returned contact list to contain only contacts with the provided set of kind/sub-kind combinations.
| Parameters | |
|---|---|
| present |
The set of kind/sub-kind combinations to filter based on. |
A ContactListFilters with the provided kind/sub-kind combination filter.
BlackBerry 10.0.0
ContactListFilters &
Sets whether only favorite contacts are returned when using this ContactListFilters.
| Parameters | |
|---|---|
| isFavourite |
If true only favorite contacts are returned, if false all contacts are returned. |
A ContactListFilters with the provided indication of whether favorite contacts are returned.
BlackBerry 10.0.0
ContactListFilters &
Sets whether only video chat contacts are returned when using this ContactListFilters.
| Parameters | |
|---|---|
| isVideoChatContact |
If true only video chat contacts are returned, if false all contacts are returned. |
A ContactListFilters with the provided indication of whether video chat contacts are returned.
BlackBerry 10.0.0
ContactListFilters &
Filters the returned contact list to contain only contacts with the provided attribute kind.
| Parameters | |
|---|---|
| present |
The attribute kind to filter based on. |
A ContactListFilters with the provided attribute kind filter.
BlackBerry 10.0.0
ContactListFilters &
Filters the returned contact list to contain only contacts with the provided set of attribute kinds.
| Parameters | |
|---|---|
| present |
The set of attribute kinds to filter based on. |
A ContactListFilters with the provided attribute kind filter.
BlackBerry 10.0.0
ContactListFilters &
Sets the anchor ID and indicates how paging works in the returned contact list.
This function sets the anchor ID to the provided contact ID. If paging is set to inclusive (that is, the inclusive parameter is true), the contact with the specified contact ID is returned as the first contact. Otherwise, the first contact that's returned is the next logical contact in the list.
| Parameters | |
|---|---|
| contactId |
The contact ID to set as the anchor ID. |
| inclusive |
If true the contact with the specified contact ID is returned as the first contact in the list, if false the contact after the one with the specified contact ID is returned as the first contact. |
A ContactListFilters with the provided anchor ID and paging behavior.
BlackBerry 10.0.0
ContactListFilters &
Set offset to start query of this ContactListFilters.
@ details This value represents the place to start query from
| Parameters | |
|---|---|
| offset |
The offset number to start searching from |
A ContactListFilters with the provided offset
BlackBerry 10.0.0
ContactListFilters &
Sets the sort column and sort order of this ContactListFilters.
The default sort column is FirstName and the default sort order is ascending.
| Parameters | |
|---|---|
| column |
The sort column to set. |
| order |
The sort order to set. |
A ContactListFilters with the provided sort column and sort order.
BlackBerry 10.0.0
ContactListFilters &
Sets the sort column and sort order of this ContactListFilters using a SortSpecifier.
The default sort column is FirstName and the default sort order is ascending.
| Parameters | |
|---|---|
| sort |
The sort column and sort order pair to set, represented by a SortSpecifier. |
A ContactListFilters with the provided sort column and sort order.
BlackBerry 10.0.0
ContactListFilters &
Sets the sort columns and sort orders of this ContactListFilters using a list of SortSpecifier objects.
The default sort column is FirstName and the default sort order is ascending. The returned contact list is first sorted according to the first SortSpecifier in the provided list, then by the second SortSpecifier in the list, and so on.
| Parameters | |
|---|---|
| sorts |
The set of sort column and sort order pairs to set, represented by SortSpecifier objects. |
A ContactListFilters with the provided sort columns and sort orders.
BlackBerry 10.0.0
ContactListFilters &
Sets the sort column, sort order, and anchor value of this ContactListFilters using an AnchorValueSpecifier.
This function specifies a sort column and order, and offsets the response by a certain anchor value. When anchoring by value, contacts matching the values are included in the response.
| Parameters | |
|---|---|
| anchorValue |
The sort column, sort order, and anchor value to set, represented by a AnchorValueSpecifier object. |
A ContactListFilters with the provided sort column, sort order, and anchor value.
BlackBerry 10.0.0
ContactListFilters &
Sets the sort columns, sort orders, and anchor values of this ContactListFilters using a list of AnchorValueSpecifier objects.
This function specifies a set of sort columns and orders, and offsets the response by anchor values. When anchoring by value, contacts matching the values are included in the response.
| Parameters | |
|---|---|
| anchorValues |
The set of sort columns, sort orders, and anchor values to set, represented by AnchorValueSpecifier objects. |
A ContactListFilters with the provided sort columns, sort orders, and anchor values.
BlackBerry 10.0.0
ContactListFilters &
Filters the returned contact list to contain only contacts where the source of the contact comes from the provided account ID.
| Parameters | |
|---|---|
| accountId |
The account ID to filter based on. |
A ContactListFilters with the provided account ID filter.
BlackBerry 10.0.0
ContactListFilters &
Filters the returned contact list to contain only contacts where the sources of the contact come from any of the provided account IDs.
| Parameters | |
|---|---|
| accountId |
The set of account IDs to filter based on. |
A ContactListFilters with the provided account ID filter.
BlackBerry 10.0.0
ContactListFilters &
Filters the returned contact list to contain only contacts where the source of the contact doesn't come from the provided account ID.
| Parameters | |
|---|---|
| accountId |
The account ID to filter based on. |
A ContactListFilters with the provided account ID filter.
BlackBerry 10.0.0
ContactListFilters &
Filters the returned contact list to contain only contacts where the sources of the contact don't come from any of the provided account IDs.
| Parameters | |
|---|---|
| accountId |
The set of account IDs to filter based on. |
A ContactListFilters with the provided account ID filter.
BlackBerry 10.0.0
ContactListFilters &
Filters the returned contact list to contain the contacts where the source of the contact doesn't come from the provided account ID.
| Parameters | |
|---|---|
| accountId |
The account ID to filter based on. |
| includeMergedContacts |
Indicates whether contacts that belong to more than one account should be included in the result if one of the source accounts is not excluded. |
A ContactListFilters with the provided account ID filter.
BlackBerry 10.0.0
ContactListFilters &
Filters the returned contact list to contain the contacts where the sources of the contact don't come from any of the provided account IDs.
| Parameters | |
|---|---|
| accountId |
The set of account IDs to filter based on. |
| includeMergedContacts |
Indicates whether contacts that belong to more than one account should be included in the result if one of the source accounts is not excluded. |
A ContactListFilters with the provided account ID filter.
BlackBerry 10.0.0
ContactListFilters &
Sets whether to include photos in the returned contact list.
If set to true, the primary photos that are associated with the contacts are returned. The default value is false.
| Parameters | |
|---|---|
| value |
If true photos are included in the returned contact list, if false photos are not included in the returned contact list. |
A ContactListFilters with the provided indication of whether to include photos in the returned contact list.
BlackBerry 10.0.0
ContactListFilters &
Filters the returned contact list to contain only contacts with the provided attribute kind.
This function is mutually exclusive with setIncludeAttributes().
| Parameters | |
|---|---|
| kind |
The attribute kind to filter based on. |
A ContactListFilter with the provided attribute kind filter.
BlackBerry 10.0.0
ContactListFilters &
Filters the returned contact list to contain only contacts with the provided attribute kinds.
This function is mutually exclusive with setIncludeAttribute().
| Parameters | |
|---|---|
| kinds |
The set of attribute kinds to filter based on. |
A ContactListFilter with the provided attribute kinds filter.
BlackBerry 10.0.0
ContactListFilters &
Sets whether to include postal addresses in the returned contact list.
This function specifies whether postal addresses are included in the response, if these addresses are available for the contacts.
| Parameters | |
|---|---|
| value |
If true postal addresses are included in the returned contact list, if false postal addresses are not included in the returned contact list. |
A ContactListFilters with the provided indication of whether to include postal addresses in the returned contact list.
BlackBerry 10.0.0