EventKey

Since: BlackBerry 10.0.0

#include <bb/pim/calendar/EventKey>

To link against this class, add the following line to your .pro file: LIBS += -lbbpim

The EventKey class represents a database key for calendar events.

This class includes attributes (such as event ID, account ID, and dates) that uniquely identify an event in the calendar database.

EventKey objects are used by the EventSearchParameters class, which itself is used when you want to search for specific events in the calendar database. When you call EventSearchParameters::events(), a list of EventKey objects is returned. Each object represents a particular event to search for. You can call EventSearchParameters::addEvent() or EventSearchParameters::setEvents() to add or set events to search for.


Overview

Public Functions Index

EventKey ()
EventKey (const EventKey &other)
~EventKey ()
AccountIdaccountId () const
voidaddDate (const QDateTime &date)
QList< QDateTime >dates () const
EventIdeventId () const
boolisValid () const
EventKey &operator= (const EventKey &other)
voidresetDates ()
voidsetAccountId (AccountId accountId)
voidsetDates (const QList< QDateTime > &dates)
voidsetEventId (EventId eventId)

Public Functions

EventKey ()

Constructs a new EventKey.

Since:

BlackBerry 10.0.0

EventKey (

Copy constructor.

This function constructs an EventKey containing exactly the same values as the provided EventKey.

Parameters
other

The EventKey to be copied.

Since:

BlackBerry 10.0.0

~EventKey ()

Destructor.

Since:

BlackBerry 10.0.0

AccountId accountId ()

Retrieves the account ID of this EventKey.

The account ID is the database identifier for a particular account.

Return:

The account ID of this EventKey.

Since:

BlackBerry 10.0.0

void addDate (

Adds a new date to the list of recurrence dates for this EventKey.

Parameters
date

The date to add.

Since:

BlackBerry 10.0.0

QList< QDateTime > dates ()

Retrieves the recurrence dates for this EventKey.

This is an optional attribute that's used to select occurrences of a recurring event by date. A query with dates is faster because it overrides the recurrence expansion mechanism.

Return:

The recurrence dates for this EventKey.

Since:

BlackBerry 10.0.0

EventId eventId ()

Retrieves the event ID of this EventKey.

The event ID uniquely identifies an event in a particular account. Two events in different accounts may have the same event ID.

Return:

The event ID of this EventKey.

Since:

BlackBerry 10.0.0

bool isValid ()

Indicates whether this EventKey is valid.

This function determines whether the attributes of this EventKey object have acceptable values.

Return:

true if this EventKey is valid, false otherwise.

Since:

BlackBerry 10.0.0

EventKey & operator= (

Assignment operator.

This operator copies all values from the provided EventKey into this EventKey.

Parameters
other

The EventKey from which to copy all values.

Return:

A reference to this EventKey.

Since:

BlackBerry 10.0.0

void resetDates ()

Removes all recurrence dates from this EventKey.

Since:

BlackBerry 10.0.0

void setAccountId (
  • AccountIdaccountId)

Sets the account ID of this EventKey.

Parameters
accountId

The new account ID.

Since:

BlackBerry 10.0.0

void setDates (

Sets the list of recurrence dates for this EventKey.

This function replaces the current list of recurrence dates with the provided list.

Parameters
dates

The new list of recurrence dates.

Since:

BlackBerry 10.0.0

void setEventId (
  • EventIdeventId)

Sets the event ID of this EventKey.

Parameters
eventId

The new event ID.

Since:

BlackBerry 10.0.0

Last modified: 2014-03-13

comments powered by Disqus