CFavouritesItem Class Reference

#include <mw/favouritesitem.h>

Link against: FavouritesEngine.lib

class CFavouritesItem : public CBase

Inherits from

  • CFavouritesItem
    Public Member Enumerations
    enumTType { ENone, EItem, EFolder }
    Public Member Functions
    virtual ~CFavouritesItem()
    IMPORT_C voidClearL()
    IMPORT_C TInt32ContextId()
    voidExternalizeL(RWriteStream &)
    voidInternalizeL(RReadStream &)
    IMPORT_C TBoolIsFactoryItem()
    IMPORT_C TBoolIsFolder()
    IMPORT_C TBoolIsHidden()
    IMPORT_C TBoolIsItem()
    IMPORT_C TBoolIsReadOnly()
    IMPORT_C TTimeModified()
    IMPORT_C const TPtrCName()
    IMPORT_C CFavouritesItem *NewL()
    IMPORT_C CFavouritesItem *NewLC()
    IMPORT_C TIntParentFolder()
    IMPORT_C const TPtrCPassword()
    IMPORT_C voidSetContextId(TInt32)
    IMPORT_C TBoolSetHidden(TBool)
    IMPORT_C voidSetNameL(const TDesC &)
    IMPORT_C voidSetParentFolder(TInt)
    IMPORT_C voidSetPasswordL(const TDesC &)
    IMPORT_C voidSetType(TType)
    IMPORT_C voidSetUrlL(const TDesC &)
    IMPORT_C voidSetUserNameL(const TDesC &)
    IMPORT_C voidSetWapAp(const TFavouritesWapAp &)
    IMPORT_C TTypeType()
    IMPORT_C TIntUid()
    IMPORT_C const TPtrCUrl()
    IMPORT_C const TPtrCUserName()
    IMPORT_C TFavouritesWapApWapAp()
    IMPORT_C CFavouritesItem &operator=(const CFavouritesItem &)
    Inherited Functions
    CBase::CBase()
    CBase::Delete(CBase *)
    CBase::Extension_(TUint,TAny *&,TAny *)
    CBase::operator new(TUint)
    CBase::operator new(TUint,TAny *)
    CBase::operator new(TUint,TLeave)
    CBase::operator new(TUint,TLeave,TUint)
    CBase::operator new(TUint,TUint)
    CBase::~CBase()

    Detailed Description

    CFavouritesItem is the base class for representing one favourites entry (item or folder). Instances of this class are used to exchange data between the Favourites Engine and clients using it.

    Member Enumeration Documentation

    Enum TType

    Type of an item (item or folder).

    Defines the type of an item (item or folder).

    EnumeratorValueDescription
    ENone
    EItem
    EFolder

    Constructor & Destructor Documentation

    ~CFavouritesItem ( )

    IMPORT_C~CFavouritesItem()[virtual]
    Destructor.
    Since
    0.9

    Member Function Documentation

    ClearL ( )

    IMPORT_C voidClearL()
    Reset the item to default values.
    Since
    0.9

    Returns: void

    ContextId ( )

    IMPORT_C TInt32ContextId()const
    Get context id associated with this item.
    Since
    0.9

    Returns: The context id.

    ExternalizeL ( RWriteStream & )

    voidExternalizeL(RWriteStream &aStream)const
    Externalize into a stream.
    Since
    0.9
    ParameterDescription
    aStreamThe stream to externalize to.

    Returns: void

    InternalizeL ( RReadStream & )

    voidInternalizeL(RReadStream &aStream)
    Internalize from a stream.
    Since
    0.9
    ParameterDescription
    aStreamThe stream to externalize from.

    Returns: void

    IsFactoryItem ( )

    IMPORT_C TBoolIsFactoryItem()const
    Check if this is a factory item.
    Since
    0.9

    Returns: ETrue if this is a factory item.

    IsFolder ( )

    IMPORT_C TBoolIsFolder()const
    Check if this is a folder.
    Since
    0.9

    Returns: ETrue if this is a folder.

    IsHidden ( )

    IMPORT_C TBoolIsHidden()const
    Check if this is a hidden.
    Since
    0.9

    Returns: ETrue if this is hidden.

    IsItem ( )

    IMPORT_C TBoolIsItem()const
    Check if this is an item (not folder).
    Since
    0.9

    Returns: ETrue if this is an item.

    IsReadOnly ( )

    IMPORT_C TBoolIsReadOnly()const
    Check if this is a read-only in database. Note that ETrue value does not prevent modifying this CFavouritesItem object.
    Since
    0.9

    Returns: ETrue if this is read-only in database.

    Modified ( )

    IMPORT_C TTimeModified()const
    Get last modification time (of database entry), universal time. This can be zero if:
    • Last modification time is not available in database (old databases); or

    • Engine does not support this feature. Note that zero means Modified().Int64() == 0, and not Time::NullTTime().
      Since
      0.9

    Returns: TTime, last modification time

    Name ( )

    IMPORT_C const TPtrCName()const
    Get the name of this item.
    Since
    0.9

    Returns: The name of this item.

    NewL ( )

    IMPORT_C CFavouritesItem *NewL()[static]
    Two-phased constructor. Leaves on failure.
    Since
    0.9

    Returns: The constructed item.

    NewLC ( )

    IMPORT_C CFavouritesItem *NewLC()[static]
    Two-phased constructor. Leaves on failure. Places the instance on the cleanup stack.
    Since
    0.9

    Returns: The constructed item.

    ParentFolder ( )

    IMPORT_C TIntParentFolder()const
    Get the uid of the parent folder of this item.
    Since
    0.9

    Returns: The unique id of the parent folder.

    Password ( )

    IMPORT_C const TPtrCPassword()const
    Get password associated with this item.
    Since
    0.9

    Returns: The password.

    SetContextId ( TInt32 )

    IMPORT_C voidSetContextId(TInt32aContextId)
    Set context id of the item.
    Since
    0.9
    ParameterDescription
    aContextIdThe context id to be set.

    Returns: void

    SetHidden ( TBool )

    IMPORT_C TBoolSetHidden(TBoolaHidden)const
    Set hidden value of the item.
    Since
    0.9
    ParameterDescription
    aHiddenThe hidden value to be set.

    Returns: void

    SetNameL ( const TDesC & )

    IMPORT_C voidSetNameL(const TDesC &aName)
    Set name of the item. Leading or trailing whitespace is trimmed. Length limit is KFavouritesMaxName (leaves with KErrOverflow).
    Since
    0.9
    ParameterDescription
    aNameThe name to be set.

    Returns: void

    SetParentFolder ( TInt )

    IMPORT_C voidSetParentFolder(TIntaId)
    Set parent folder.
    Since
    0.9
    ParameterDescription
    aIdThe unique id of the parent folder.

    Returns: void

    SetPasswordL ( const TDesC & )

    IMPORT_C voidSetPasswordL(const TDesC &aPassword)
    Set password. Length limit is KFavouritesMaxPassword (leaves with KErrOverflow).
    Since
    0.9
    ParameterDescription
    aPasswordThe password to be set.

    Returns: void

    SetType ( TType )

    IMPORT_C voidSetType(TTypeaType)
    Set item type (item or folder).
    Since
    0.9
    ParameterDescription
    aTypeThe type to be set. ENone cannot be set (if that is specified, it is ignored).

    Returns: void

    SetUrlL ( const TDesC & )

    IMPORT_C voidSetUrlL(const TDesC &aUrl)
    Set URL of the item.
    Since
    0.9 Length limit is KFavouritesMaxURL (leaves with KErrOverflow).
    ParameterDescription
    aUrlThe URL to be set.

    Returns: void

    SetUserNameL ( const TDesC & )

    IMPORT_C voidSetUserNameL(const TDesC &aUserName)
    Set username of the item. Length limit is KFavouritesMaxUserName (leaves with KErrOverflow).
    Since
    0.9
    ParameterDescription
    aUserNameThe username to be set.

    Returns: void

    SetWapAp ( const TFavouritesWapAp & )

    IMPORT_C voidSetWapAp(const TFavouritesWapAp &aAccessPoint)
    Set WAP Access Point of the item.
    Since
    0.9
    ParameterDescription
    aAccessPointThe WAP Access point to be set.

    Returns: void

    Type ( )

    IMPORT_C TTypeType()const
    Get type of the item (item or folder).
    Since
    0.9

    Returns: The type of the item. It is either EFolder or EItem (never ENone).

    Uid ( )

    IMPORT_C TIntUid()const
    Get unique id of the item.
    Since
    0.9

    Returns: The unique id.

    Url ( )

    IMPORT_C const TPtrCUrl()const
    Get the URL of this item.
    Since
    0.9

    Returns: The URL of this item.

    UserName ( )

    IMPORT_C const TPtrCUserName()const
    Get the username associated with this item.
    Since
    0.9

    Returns: The username.

    WapAp ( )

    IMPORT_C TFavouritesWapApWapAp()const
    Get WAP Access Point id associated with this item.
    Since
    0.9

    Returns: The WAP Access Point id.

    operator= ( const CFavouritesItem & )

    IMPORT_C CFavouritesItem &operator=(const CFavouritesItem &aCopyFrom)
    Assignment operator.
    Since
    0.9
    ParameterDescription
    aCopyFromAssign from this.