CPbkViewState Class Reference

#include <app/CPbkViewState.h>

class CPbkViewState : public CBase

Inherits from

  • CPbkViewState
    Public Member Enumerations
    enumTDataType { EEnd, EFocusedContactId, ETopContactId, EMarkedContactIds, ..., EFlags }
    enumTFlags { ENullFlags, EFocusFirst, EFocusLast, EInitialized, ESendToBackground }
    Public Member Functions
    ~CPbkViewState()
    IMPORT_C voidExternalizeL(RWriteStream &)
    IMPORT_C CPbkFieldDataArray *FieldDataArray()
    IMPORT_C TUintFlags()
    IMPORT_C TContactItemIdFocusedContactId()
    IMPORT_C TIntFocusedFieldIndex()
    IMPORT_C voidInternalizeL(RReadStream &)
    IMPORT_C const CContactIdArray *MarkedContactIds()
    IMPORT_C CContactIdArray *MarkedContactIds()
    voidMergeViewState(CPbkViewState &)
    IMPORT_C CPbkViewState *NewL()
    IMPORT_C CPbkViewState *NewL(RReadStream &)
    IMPORT_C CPbkViewState *NewL(const TDesC8 &)
    IMPORT_C CPbkViewState *NewLC()
    IMPORT_C CPbkViewState *NewLC(RReadStream &)
    IMPORT_C CPbkViewState *NewLC(const TDesC8 &)
    IMPORT_C HBufC8 *PackL()
    IMPORT_C HBufC8 *PackLC()
    IMPORT_C TContactItemIdParentContactId()
    IMPORT_C voidReset()
    IMPORT_C voidSetFieldDataArray(CPbkFieldDataArray *)
    IMPORT_C voidSetFlags(TUint)
    IMPORT_C voidSetFocusedContactId(TContactItemId)
    IMPORT_C voidSetFocusedFieldIndex(TInt)
    IMPORT_C voidSetMarkedContactIds(CContactIdArray *)
    IMPORT_C voidSetParentContactId(TContactItemId)
    IMPORT_C voidSetTopContactId(TContactItemId)
    IMPORT_C voidSetTopFieldIndex(TInt)
    IMPORT_C TContactItemIdTopContactId()
    IMPORT_C TIntTopFieldIndex()
    IMPORT_C TUidUid()
    IMPORT_C voidUnpackL(const TDesC8 &)
    IMPORT_C TBooloperator==(const CPbkViewState &)
    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

    Generic Phonebook view state class. Class can be used to pass parameters the Phonebook application when launching the application with the symbian view launching mechanism.

    Member Enumeration Documentation

    Enum TDataType

    Enum TFlags

    EnumeratorValueDescription
    ENullFlags0Reset flags.
    EFocusFirst0x0001Focus the first item in list views.
    EFocusLast0x0002Focus the last item in list views.
    EInitialized0x0004Reset state to the view's initial state.
    ESendToBackground0x0008Send application to background.

    Constructor & Destructor Documentation

    ~CPbkViewState ( )

    ~CPbkViewState()

    Destructor.

    Member Function Documentation

    ExternalizeL ( RWriteStream & )

    IMPORT_C voidExternalizeL(RWriteStream &aStream)const

    Externalizes this object to aStream.

    See also: InternalizeL

    FieldDataArray ( )

    IMPORT_C CPbkFieldDataArray *FieldDataArray()const

    Returns field data array, NULL if not set.

    Returns: Field data array object, NULL if not set.

    Flags ( )

    IMPORT_C TUintFlags()const

    Returns the view state flags. See CPbkViewState::TFlags.

    Returns: View state object flags

    FocusedContactId ( )

    IMPORT_C TContactItemIdFocusedContactId()const

    Returns id of the focused contact.

    Returns: Contact item id of the focused contact, KNullContactId if not set.

    FocusedFieldIndex ( )

    IMPORT_C TIntFocusedFieldIndex()const

    Returns index of the focused field (field is from FocusedContactId()), -1 when no field focused.

    Returns: Index of the focused field, -1 if no field is focused.

    InternalizeL ( RReadStream & )

    IMPORT_C voidInternalizeL(RReadStream &aStream)

    Internalizes this object from aStream.

    See also: ExternalizeL

    ParameterDescription
    aStreamA stream from where this objects state can be internalized from.

    MarkedContactIds ( )

    IMPORT_C const CContactIdArray *MarkedContactIds()const

    Returns const array of marked contacts ids, NULL if not set.

    Returns: Contact id array of the marked contacts, NULL if not set.

    MarkedContactIds ( )

    IMPORT_C CContactIdArray *MarkedContactIds()

    Returns array of marked contacts ids, NULL if not set. Owmership not transferred.

    Returns: Contact id array of the marked contacts, NULL if not set.

    MergeViewState ( CPbkViewState & )

    voidMergeViewState(CPbkViewState &aOtherState)

    Merges another view state to this view state by setting values from the parameter and overriding any previous values in this state.

    ParameterDescription
    aOtherStateThe state to merge to this state. The properties which have a value in aOtherState override properties in this object. The aOtherState object may be modified by this function.

    NewL ( )

    IMPORT_C CPbkViewState *NewL()[static]

    Creates and returns a new instance of this class.

    NewL ( RReadStream & )

    IMPORT_C CPbkViewState *NewL(RReadStream &aStream)[static]

    Creates and returns a new instance of this class initialized from aStream.

    ParameterDescription
    aStreamA view state stream to internalize.

    NewL ( const TDesC8 & )

    IMPORT_C CPbkViewState *NewL(const TDesC8 &aBuf)[static]

    Creates and returns a new instance of this class initialized from aBuf.

    ParameterDescription
    aBufA view state buffer to internalize.

    NewLC ( )

    IMPORT_C CPbkViewState *NewLC()[static]

    Like NewL(), but leaves the object on the cleanup stack

    See also: NewL

    NewLC ( RReadStream & )

    IMPORT_C CPbkViewState *NewLC(RReadStream &aStream)[static]

    Like NewL(RReadStream& aStream) but leaves the object on the cleanup stack.

    See also: NewL(RReadStream& aStream)

    ParameterDescription
    aStreamA view state stream to internalize.

    NewLC ( const TDesC8 & )

    IMPORT_C CPbkViewState *NewLC(const TDesC8 &aBuf)[static]

    Like NewL(const TDesC8& aBuf) but leaves the object on the cleanup stack.

    See also: NewL(const TDesC8& aBuf)

    ParameterDescription
    aBufA view state buffer to internalize.

    PackL ( )

    IMPORT_C HBufC8 *PackL()const

    Packages and returns this object in a buffer. Caller is responsible of deleting the buffer.

    Returns: Packaged state in a buffer.

    PackLC ( )

    IMPORT_C HBufC8 *PackLC()const

    Like PackL, but leaves the buffer on the cleanup stack.

    See also: PackL

    Returns: Packaged state in a buffer.

    ParentContactId ( )

    IMPORT_C TContactItemIdParentContactId()const

    Returns the focused contact id's parent, KNullContactId if not set.

    Returns: Focused contact id's parent, KNullContactId if not set.

    Reset ( )

    IMPORT_C voidReset()

    Reset this state to empty.

    SetFieldDataArray ( CPbkFieldDataArray * )

    IMPORT_C voidSetFieldDataArray(CPbkFieldDataArray *aFieldDataArray)

    Sets field data array to aArray. Destroys previous array and takes ownership of aArray.

    ParameterDescription
    aFieldDataArraySets the field data array.

    SetFlags ( TUint )

    IMPORT_C voidSetFlags(TUintaFlags)

    Sets the view state flags.

    ParameterDescription
    aFlagsSets the view state parameters. See CPbkViewState::TFlags.

    SetFocusedContactId ( TContactItemId )

    IMPORT_C voidSetFocusedContactId(TContactItemIdaId)

    Sets id of the focused contact to aId.

    ParameterDescription
    aIdSets the focused contact id.

    SetFocusedFieldIndex ( TInt )

    IMPORT_C voidSetFocusedFieldIndex(TIntaIndex)

    Sets index of the focused field to aIndex (field from FocusedContactId()), -1 when no field focused.

    ParameterDescription
    aIndexSets focused field index.

    SetMarkedContactIds ( CContactIdArray * )

    IMPORT_C voidSetMarkedContactIds(CContactIdArray *aArray)

    Sets the array of marked contact ids to aArray. Destroys previous array and takes ownership of aArray.

    ParameterDescription
    aArraySets the marked contact ids.

    SetParentContactId ( TContactItemId )

    IMPORT_C voidSetParentContactId(TContactItemIdaParentContactId)

    Sets the focused contact ids parent contact id.

    ParameterDescription
    aParentContactIdSets the contact ids parent id.

    SetTopContactId ( TContactItemId )

    IMPORT_C voidSetTopContactId(TContactItemIdaId)

    Sets id of the topmost contact to aId.

    ParameterDescription
    aIdSets the topmost contact id.

    SetTopFieldIndex ( TInt )

    IMPORT_C voidSetTopFieldIndex(TIntaIndex)

    Sets index of the topmost field to aIndex (field from FocusedContactId()), -1 when no topmost field.

    ParameterDescription
    aIndexSets the topmost field index.

    TopContactId ( )

    IMPORT_C TContactItemIdTopContactId()const

    Returns id of the topmost contact.

    Returns: Contact item id of the top contact, KNullContactId if not set.

    TopFieldIndex ( )

    IMPORT_C TIntTopFieldIndex()const

    Returns index of the topmost field (field is from FocusedContactId()), -1 when no topmost field.

    Returns: Index of the topmost field, -1 if no topmost field.

    Uid ( )

    IMPORT_C TUidUid()[static]

    Returns the message uid for use with view server messages.

    UnpackL ( const TDesC8 & )

    IMPORT_C voidUnpackL(const TDesC8 &aPack)

    Sets this state from aPack previously created with PackL.

    See also: PackL PackLC

    ParameterDescription
    aPackPreviously packaged state.

    operator== ( const CPbkViewState & )

    IMPORT_C TBooloperator==(const CPbkViewState &aRhs)const