RBkNode Class Reference
RBkNode is the base class for RBkBookmark and RBkFolder handle classes. Bookmarks and folders have many attributes in common. This class encapulates these elements and provides the implementation for accessing and setting them. It is also used when iterating through a folders child list where you can't know in advance whether the item is a bookmark or folder. A RBkNode can be passed as a parameter when opening RBkBookmark and RBkFolder handles once you know the RBkNode's type
Constructor & Destructor Documentation
Member Functions Documentation
Close()
Closes the RBkNode handle and decrements the reference count
DeleteBkmrkItem(TAny *)
void | DeleteBkmrkItem | ( | TAny * | aPtr | ) | [private, static] |
DescriptionL()
IMPORT_C const TDesC & | DescriptionL | ( | ) | const |
Gets the item description text.
ExtendedPropertiesL()
Not intended for external use.
GetCustomPropertyL(TUid, TInt &)
IMPORT_C void | GetCustomPropertyL | ( | TUid | aPropertyId, |
| TInt & | aValue |
| ) | const |
Gets a custom property for the given property ID. This method will leave if no such property has been registered on the database
Parameters
TUid aPropertyId | The ID of the property you wish to get |
TInt & aValue | An integer the data value |
GetCustomPropertyL(TUid, TReal &)
IMPORT_C void | GetCustomPropertyL | ( | TUid | aPropertyId, |
| TReal & | aValue |
| ) | const |
Gets a custom property for the given property ID. This method will leave if no such property has been registered on the database
Parameters
TUid aPropertyId | The ID of the property you wish to get |
TReal & aValue | A floating point data value |
GetCustomPropertyL(TUid, TDes &)
IMPORT_C void | GetCustomPropertyL | ( | TUid | aPropertyId, |
| TDes & | aValue |
| ) | const |
Gets a custom property for the given property ID. This method will leave if no such property has been registered on the database
Parameters
TUid aPropertyId | The ID of the property you wish to get |
TDes & aValue | A 16 bit descriptor |
GetCustomPropertyL(TUid, TDes8 &)
IMPORT_C void | GetCustomPropertyL | ( | TUid | aPropertyId, |
| TDes8 & | aValue |
| ) | const |
Gets a custom property for the given property ID. This method will leave if no such property has been registered on the database
Parameters
TUid aPropertyId | The ID of the property you wish to get |
TDes8 & aValue | An 8 bit descriptor |
IconIdL()
Returns the ID if an icon is assigned to this bookmark item.
Id()
Method for querying the bookmark item's database id.
IsPublic()
IMPORT_C TBool | IsPublic | ( | ) | const |
Returns whether the item is public or private
IsWritable()
IMPORT_C TBool | IsWritable | ( | ) | const |
Returns whether the item is read only or not
Item()
Not intended for external use.
LastModifiedL()
IMPORT_C TTime | LastModifiedL | ( | ) | const |
Returns the last modified time. If the last modified time was never set, this will return the value of midnight January 1st 1970 UTC. This can occur when using a version 1.0.0 database.
LeaveIfRootL()
void | LeaveIfRootL | ( | ) | const [private] |
OpenBookmarkL()
Opens RBkBookmark handle from this RBkNode handle. This is usually done when iterating through a folder. You must ensure that this RBkNode handle is of the type: Bookmark::ETypeBookmark before calling this method.
This method does NOT close the RBkNode handle
-
leave
- Bookmark::KErrWrongType The method will leave if an attempt is made to call this with a RBkNode handle which is not of the Bookmark::ETypeBookmark type.
OpenFolderL()
Opens RBkFolder handle from this RBkNode handle. This is usually done when iterating through a folder. You must ensure that this RBkNode handle is of the type: Bookmark::ETypeFolder before calling this method.
This method does NOT close the RBkNode handle
-
leave
- Bookmark::KErrWrongType The method will leave if an attempt is made to call this with a RBkNode handle which is not of the Bookmark::ETypeFolder type.
OpenParentL()
Method for querying a bookmark item's parent folder. Only the root will not have a parent. The method will leave if an attempt is made to call this on the root folder
-
leave
- KErrNotFound This will leave if called on the root folder (the root folder has no parent).
OwnerL()
Returns the item's owner if it is a private bookmark.
Bookmark::TVisibility
- leave
- KErrPermissionDenied This function will leave when the bookmark database is not opened as Bookmark::EVisibilityManager.
SetCustomPropertyL(TUid, TInt)
IMPORT_C void | SetCustomPropertyL | ( | TUid | aPropertyId, |
| TInt | aValue |
| ) | |
Assigns a new custom property value to the bookmark item. This method will leave if no such property has been registered on the database
Parameters
TUid aPropertyId | The ID of the property you wish to set |
TInt aValue | An integer data value |
SetCustomPropertyL(TUid, TReal)
IMPORT_C void | SetCustomPropertyL | ( | TUid | aPropertyId, |
| TReal | aValue |
| ) | |
Assigns a new custom property value to the bookmark item. This method will leave if no such property has been registered on the database
Parameters
TUid aPropertyId | The ID of the property you wish to set |
TReal aValue | A floating point data value |
SetCustomPropertyL(TUid, const TDesC &)
IMPORT_C void | SetCustomPropertyL | ( | TUid | aPropertyId, |
| const TDesC & | aValue |
| ) | |
Assigns a new custom property value to the bookmark item. This method will leave if no such property has been registered on the database
Parameters
TUid aPropertyId | The ID of the property you wish to set |
const TDesC & aValue | A 16 bit descriptor |
SetCustomPropertyL(TUid, const TDesC8 &)
IMPORT_C void | SetCustomPropertyL | ( | TUid | aPropertyId, |
| const TDesC8 & | aValue |
| ) | |
Assigns a new custom property value to the bookmark item. This method will leave if no such property has been registered on the database
Parameters
TUid aPropertyId | The ID of the property you wish to set |
const TDesC8 & aValue | An 8 bit descriptor |
SetDescriptionL(const TDesC &)
IMPORT_C void | SetDescriptionL | ( | const TDesC & | aDescription | ) | |
Sets the item's decription text.
Parameters
const TDesC & aDescription | The item's new description |
SetIconIdL(Bookmark::TAttachmentId)
Sets the icon. Call this with KNullIconID to remove the icon. Icons are stored centrally in the database and are shared by bookmark items. If the icon oes not exist in the database this method will leave
SetItem(CBookmarkBase &)
Not intended for external use.
SetLastModifiedL(const TTime &)
IMPORT_C void | SetLastModifiedL | ( | const TTime & | aTime | ) | |
Sets the last modified time to an arbitrary value. Only applications which have opened the bookmark database as Bookmark::EVisibilityManager can use this function, otherwise it will leave with KErrPermissionDenied error code.
Note: The last modified time is automatically set to the current time during a commit. This function should only be used if the caller needs to set to a different time (for example when synchronising bookmarks).
-
leave
- KErrPermissionDenied This function will leave, when the bookmark database is not opened in Bookmark::EVisibilityManager.
Parameters
const TTime & aTime | The time to set. |
SetOwnerL(TSecureId)
Sets the owner security ID of this bookmark item. All applications which have opened the bookmark database as Bookmark::EVisibilityManager can use this function. In other visibility modes the aOwner must be the current SID, otherwise function will leave with KErrPermissionDenied
-
leave
- KErrPermissionDenied When the aOwner is not the current SID and the bookmark database is opened in non-manager mode.
-
leave
- Bookmark::KErrOperationDenied This function will leave, if called on the root folder.
SetParentL(RBkFolder &)
IMPORT_C void | SetParentL | ( | RBkFolder & | aNewParent | ) | |
Moves the item to another folder
This function will leave if called on the root folder or an out of memory condition occurs.
-
leave
- Bookmark::KErrReadOnly This function will leave if the item is read only.
SetPublicL(TBool)
IMPORT_C void | SetPublicL | ( | TBool | aPublic | ) | |
Sets the public or private status.
Parameters
TBool aPublic | Whether the item is to be public or private |
SetTitleL(const TDesC &)
IMPORT_C void | SetTitleL | ( | const TDesC & | aTitle | ) | |
Sets the item's title text. Folder titles must be unique.
Parameters
const TDesC & aTitle | The item's new title. |
SetWritableL(TBool)
IMPORT_C void | SetWritableL | ( | TBool | aWritable | ) | |
Sets item to Read Only. An item can always be made Read Only, but the bookmark database must be opened as Bookmark::EVisibilityManager in order to set an item back to Read/Write. This function will leave if called on the root folder.
Bookmark::TVisibility
- leave
- KErrPermissionDenied This function will leave, when the bookmark database is not opened in Bookmark::EVisibilityManager.
- leave
- Bookmark::KErrOperationDenied This function will leave, if called on the root folder.
Parameters
TBool aWritable | Whether the item is to be read only or not |
Title()
IMPORT_C const TDesC & | Title | ( | ) | const |
Gets the items title text.
Type()
Returns the type of the object that the RBkNode handle is connected to
Member Data Documentation
Copyright ©2010 Nokia Corporation and/or its subsidiary(-ies).
All rights
reserved. Unless otherwise stated, these materials are provided under the terms of the Eclipse Public License
v1.0.