epoc32/include/app/calfilechangenotification.h
branchSymbian3
changeset 4 837f303aceeb
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/epoc32/include/app/calfilechangenotification.h	Wed Mar 31 12:33:34 2010 +0100
     1.3 @@ -0,0 +1,80 @@
     1.4 +// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
     1.5 +// All rights reserved.
     1.6 +// This component and the accompanying materials are made available
     1.7 +// under the terms of "Eclipse Public License v1.0"
     1.8 +// which accompanies this distribution, and is available
     1.9 +// at the URL "http://www.eclipse.org/legal/epl-v10.html".
    1.10 +//
    1.11 +// Initial Contributors:
    1.12 +// Nokia Corporation - initial contribution.
    1.13 +//
    1.14 +// Contributors:
    1.15 +//
    1.16 +// Description:
    1.17 +//
    1.18 +
    1.19 +#ifndef __CALFILECHANGENOTIFICATION_H__
    1.20 +#define __CALFILECHANGENOTIFICATION_H__
    1.21 +
    1.22 +class CAgnFileChangeInfo;
    1.23 +class CCalFileChangeInfo;
    1.24 +
    1.25 +/** The mixin/interface class used for recieving calendar file change notifications.
    1.26 +
    1.27 +The call back returns an array containing information about at least
    1.28 +one change to the calendar file. The information includes the file name and type of change.
    1.29 +
    1.30 +A client will not be notified of a change if it has register with the CCalSession.
    1.31 +
    1.32 +@publishedAll
    1.33 +@prototype
    1.34 +*/
    1.35 +class MCalFileChangeObserver
    1.36 +	{
    1.37 +public:
    1.38 +
    1.39 +	/** An enum to describe the types of file changes that may occur */
    1.40 +	enum TChangeType
    1.41 +		{
    1.42 +		/** A calendar file has been created */
    1.43 +		ECalendarFileCreated,
    1.44 +		/** A calendar file has been deleted */
    1.45 +		ECalendarFileDeleted,
    1.46 +		/** Calendar info has been set on a calendar file */
    1.47 +		ECalendarInfoCreated,
    1.48 +		/** A calendar file had its calendar info updated */
    1.49 +		ECalendarInfoUpdated,
    1.50 +		/** Calendar info has been deleted on a calendar file */
    1.51 +		ECalendarInfoDeleted
    1.52 +		};
    1.53 +
    1.54 +public:
    1.55 +
    1.56 +	/** The callback that will recieve 1 or more file change notifications */
    1.57 +	virtual void CalendarInfoChangeNotificationL(RPointerArray<CCalFileChangeInfo>& aCalendarInfoChangeEntries) = 0;
    1.58 +	};
    1.59 +	
    1.60 +/** This class provides information about the calendar file change
    1.61 +
    1.62 +@publishedAll
    1.63 +@prototype
    1.64 +*/
    1.65 +class CCalFileChangeInfo : public CBase
    1.66 +	{
    1.67 +public:
    1.68 +	static CCalFileChangeInfo* NewL(CAgnFileChangeInfo* aAgnFileChangeInfo);
    1.69 +	~CCalFileChangeInfo();
    1.70 +	
    1.71 +	/** Get the file name of the file that has changed */
    1.72 +	IMPORT_C const TDesC& FileNameL() const;
    1.73 +	
    1.74 +	/** Get the type of change that happened to the file */
    1.75 +	IMPORT_C MCalFileChangeObserver::TChangeType ChangeType() const;
    1.76 +	
    1.77 +private:
    1.78 +	CCalFileChangeInfo(CAgnFileChangeInfo* aAgnFileChangeInfo);
    1.79 +
    1.80 +private:
    1.81 +    CAgnFileChangeInfo* iImpl;
    1.82 +	};
    1.83 +#endif