TCalenInstanceId Class Reference

class TCalenInstanceId

This class is meant to be used, when we want to store what instance was used/focused/modified/displayed, but we don't want to store actual instance. Actual instance might become unusable, if underlying entry is modified or removed.

Thus it's safer to store weak reference to it and fetch instance when needed.

Entry type is cached to this class only for optimization. Entry type is needed e.g. when opening Options-menus to decide what items should be there and fetching real instances to get entry type would be too heavy operation.

Constructor & Destructor Documentation

TCalenInstanceId()

TCalenInstanceId ( ) [inline]

TCalenInstanceId(const TCalLocalUid &, const TTime &, CCalEntry::TType, const TCalCollectionId)

TCalenInstanceId ( const TCalLocalUid & aLuid,
const TTime & aInstanceTime,
CCalEntry::TType aType,
const TCalCollectionId aColId = -1
) [inline]

Parameters

const TCalLocalUid & aLuid The local uid of type TCalLocalUid
const TTime & aInstanceTime The instance time
CCalEntry::TType aType The entry type specified by CCalEntry::TType
const TCalCollectionId aColId = -1 The collection id.

TCalenInstanceId(const TCalLocalUid &, const TTime &, TBool, const TCalCollectionId)

TCalenInstanceId ( const TCalLocalUid & aLuid,
const TTime & aInstanceTime,
TBool aInstanceViewed,
const TCalCollectionId aColId = -1
) [inline]

Parameters

const TCalLocalUid & aLuid The local UID
const TTime & aInstanceTime The instance time
TBool aInstanceViewed ETrue if the instance is viewed in viewer, EFalse otherwise
const TCalCollectionId aColId = -1 The collection id.

Member Functions Documentation

CreateL(const CCalInstance &)

TCalenInstanceId CreateL ( const CCalInstance & aInstance ) [static, inline]

Parameters

const CCalInstance & aInstance Reference of type CCalInstance for which the instance id is required

CreateL(const CCalEntry &, const TCalTime &, const TCalCollectionId)

TCalenInstanceId CreateL ( const CCalEntry & aEntry,
const TCalTime & aInstanceTime,
const TCalCollectionId aColId = -1
) [static, inline]

Parameters

const CCalEntry & aEntry Reference of type CCalEntry for which the instance id is required
const TCalTime & aInstanceTime Reference of type TCalTime
const TCalCollectionId aColId = -1 The collection id

CreateL(const TCalLocalUid &, const TTime &, TBool, const TCalCollectionId)

TCalenInstanceId CreateL ( const TCalLocalUid & aLuid,
const TTime & aInstanceTime,
TBool aInstanceViewed,
const TCalCollectionId aColId = -1
) [static, inline]

Parameters

const TCalLocalUid & aLuid Reference of type TCalLocalUid for which the instance id is required
const TTime & aInstanceTime Reference of type TTime
TBool aInstanceViewed ETrue if the instance is viewed in the viewer, EFalse otherwise
const TCalCollectionId aColId = -1 The collection id.

NullInstanceId()

TCalenInstanceId NullInstanceId ( ) [static, inline]

operator==(const TCalenInstanceId &)

TBool operator== ( const TCalenInstanceId & aX ) const [inline]

Parameters

const TCalenInstanceId & aX

Member Data Documentation

TCalCollectionId iColId

TCalCollectionId iColId

TCalLocalUid iEntryLocalUid

TCalLocalUid iEntryLocalUid

TTime iInstanceTime

TTime iInstanceTime

TBool iInstanceViewed

TBool iInstanceViewed

CCalEntry::TType iType

CCalEntry::TType iType