CalendarFolder

Since: BlackBerry 10.0.0

#include <bb/pim/calendar/CalendarFolder>

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

The CalendarFolder class represents a distinct calendar in the Calendar application.

Calendar folders are containers for events. A calendar in the Calendar application is represented by a CalendarFolder object. This object includes information about the calendar, including name, type, owner email address, and color.

When you create a CalendarEvent, you can specify the folder that you want to add the event to. You can update an existing CalendarFolder in the database by calling CalendarService::updateFolder().


Overview

Public Functions Index

CalendarFolder ()
CalendarFolder (const CalendarFolder &other)
~CalendarFolder ()
AccountIdaccountId () const
unsigned intcolor () const
FolderIdid () const
boolisReadOnly () const
boolisValid () const
boolisVisible () const
QStringname () const
CalendarFolder &operator= (const CalendarFolder &other)
QStringownerEmail () const
FolderIdparentId () const
QStringproviderData () const
voidsetAccountId (AccountId accountId)
voidsetColor (unsigned int color)
voidsetId (FolderId id)
voidsetName (const QString &name)
voidsetOwnerEmail (const QString &ownerEmail)
voidsetParentId (FolderId parentId)
voidsetProviderData (const QString &providerData)
voidsetReadOnly (bool readOnly)
voidsetSyncId (const QString &syncId)
voidsetType (int type)
voidsetVisible (bool visible)
QStringsyncId () const
inttype () const

Public Functions

CalendarFolder ()

Constructs a new CalendarFolder.

Since:

BlackBerry 10.0.0

CalendarFolder (

Copy constructor.

This function constructs a CalendarFolder containing exactly the same values as the provided CalendarFolder.

Parameters
other

The CalendarFolder to be copied.

Since:

BlackBerry 10.0.0

~CalendarFolder ()

Destructor.

Since:

BlackBerry 10.0.0

AccountId accountId ()

Retrieves the account ID of this CalendarFolder.

Return:

The account ID of this CalendarFolder.

Since:

BlackBerry 10.0.0

unsigned int color ()

Retrieves the color of this CalendarFolder.

This function returns this folder's color, encoded as a 24-bit RGB value.

Return:

The color of this CalendarFolder.

Since:

BlackBerry 10.0.0

FolderId id ()

Retrieves the database ID of this CalendarFolder.

Return:

The database ID of this CalendarFolder.

Since:

BlackBerry 10.0.0

bool isReadOnly ()

Indicates whether this CalendarFolder is read-only.

Return:

true if this CalendarFolder is read-only, false otherwise.

Since:

BlackBerry 10.0.0

bool isValid ()

Indicates whether this CalendarFolder is valid.

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

Return:

true if this CalendarFolder is valid, false otherwise.

Since:

BlackBerry 10.0.0

bool isVisible ()

Indicates whether this CalendarFolder has been marked as visible in the Calendar application.

Return:

true if this CalendarFolder has been marked as visible in the Calendar application, false otherwise.

Since:

BlackBerry 10.0.0

QString name ()

Retrieves the name of this CalendarFolder.

Return:

The name of this CalendarFolder.

Since:

BlackBerry 10.0.0

CalendarFolder & operator= (

Assignment operator.

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

Parameters
other

The CalendarFolder from which to copy all values.

Return:

A reference to this CalendarFolder.

Since:

BlackBerry 10.0.0

QString ownerEmail ()

Retrieves the email address of the owner of this CalendarFolder.

Return:

The email address of the owner of this CalendarFolder.

Since:

BlackBerry 10.0.0

FolderId parentId ()

Retrieves the parent folder ID of this CalendarFolder.

This function returns the ID of this folder's parent folder (that is, the folder that contains this folder).

Return:

The parent folder ID of this CalendarFolder.

Since:

BlackBerry 10.0.0

QString providerData ()

Retrieves the provider data for this CalendarFolder.

The provider data is used for synchronization with remote servers.

Return:

The provider data for this CalendarFolder.

Since:

BlackBerry 10.0.0

void setAccountId (
  • AccountIdaccountId)

Sets the account ID of this CalendarFolder.

Parameters
accountId

The new account ID.

Since:

BlackBerry 10.0.0

void setColor (
  • unsigned intcolor)

Sets the color of this CalendarFolder.

Parameters
color

The new color, encoded as a 24-bit RGB value.

Since:

BlackBerry 10.0.0

void setId (
  • FolderIdid)

Sets the folder ID of this CalendarFolder.

Parameters
id

The new folder ID.

Since:

BlackBerry 10.0.0

void setName (

Sets the name of this CalendarFolder.

Parameters
name

The new name.

Since:

BlackBerry 10.0.0

void setOwnerEmail (

Sets the email address of the owner of this CalendarFolder.

Parameters
ownerEmail

The new owner email address.

Since:

BlackBerry 10.0.0

void setParentId (
  • FolderIdparentId)

Sets the parent folder ID of this CalendarFolder.

Parameters
parentId

The new parent folder ID.

Since:

BlackBerry 10.0.0

void setProviderData (

Sets the provider data for this CalendarFolder.

Parameters
providerData

The new provider data.

Since:

BlackBerry 10.0.0

void setReadOnly (
  • boolreadOnly)

Sets whether this CalendarFolder is read-only.

Parameters
readOnly

If true this CalendarFolder is read-only, if false this CalendarFolder is not read-only.

Since:

BlackBerry 10.0.0

void setSyncId (

Sets the synchronization ID of this CalendarFolder.

Parameters
syncId

The new synchronization ID.

Since:

BlackBerry 10.0.0

void setType (
  • inttype)

Sets the type of this CalendarEvent.

Parameters
type

The new type.

Since:

BlackBerry 10.0.0

void setVisible (
  • boolvisible)

Sets whether this CalendarFolder is visible in the Calendar application.

Parameters
visible

If true this CalendarFolder is visible in the Calendar application, if false this CalendarFolder is not visible.

Since:

BlackBerry 10.0.0

QString syncId ()

Retrieves the synchronization ID of this CalendarFolder.

The synchronization ID is a token that's used for synchronization with remote servers.

Return:

The synchronization ID of this CalendarFolder.

Since:

BlackBerry 10.0.0

int type ()

Retrieves the type of this CalendarFolder.

The two possible values for the type of a calendar folder are 8 (default calendar) and 13 (user calendar).

Return:

The type of this CalendarFolder.

Since:

BlackBerry 10.0.0

Last modified: 2014-09-30



Got questions about leaving a comment? Get answers from our Disqus FAQ.

comments powered by Disqus