1 // Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
2 // All rights reserved.
3 // This component and the accompanying materials are made available
4 // under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
5 // which accompanies this distribution, and is available
6 // at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
16 #ifndef __CALENTRYVIEW_H__
17 #define __CALENTRYVIEW_H__
22 class MCalProgressCallBack;
24 class CCalEntryViewImpl;
26 /** View class for accessing calendar entries.
28 Once a session to a calendar file has been created, a view to the session
31 This view can be used to fetch, store and delete entries.
36 NONSHARABLE_CLASS(CCalEntryView) : public CBase
40 IMPORT_C static CCalEntryView* NewL(CCalSession& aSession, MCalProgressCallBack& aProgressCallBack);
41 IMPORT_C static CCalEntryView* NewL(CCalSession& aSession);
43 IMPORT_C ~CCalEntryView();
45 IMPORT_C void FetchL(const TDesC8& aUid, RPointerArray<CCalEntry>& aCalEntryArray) const;
46 IMPORT_C CCalEntry* FetchL(TCalLocalUid aId) const;
48 IMPORT_C void GetIdsModifiedSinceDateL(const TCalTime& aTime, RArray<TCalLocalUid>& aIds) const;
50 IMPORT_C void StoreL(const RPointerArray<CCalEntry>& aCalEntryList, TInt& aNumSuccessfulEntry);
51 IMPORT_C void UpdateL(const RPointerArray<CCalEntry>& aCalEntryList, TInt& aNumSuccessfulEntry);
53 IMPORT_C void DeleteL(const CDesC8Array& aUidList);
54 IMPORT_C void DeleteL(const CCalEntry& aCalEntry);
55 IMPORT_C void DeleteL(const CalCommon::TCalTimeRange& aCalTimeRange, CalCommon::TCalViewFilter aFilter, MCalProgressCallBack& aProgressCallBack);
56 IMPORT_C void DeleteL(const RArray<TCalLocalUid>& aIds, TInt& aNumSuccessfulDeleted);
60 void ConstructL(CCalSession& aSession, MCalProgressCallBack* aProgressCallBack);
62 CCalEntryViewImpl* iImpl;
65 #endif // __CALENTRYVIEW_H__