meetingrequest/mricalviewer/inc/mesmricalviewerobserver.h
changeset 0 8466d47a6819
equal deleted inserted replaced
-1:000000000000 0:8466d47a6819
       
     1 /*
       
     2 * Copyright (c) 2007-2008 Nokia Corporation and/or its subsidiary(-ies). 
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  ICal viewer's observer interface.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef MESMRICALVIEWEROBSERVER_H
       
    20 #define MESMRICALVIEWEROBSERVER_H
       
    21 
       
    22 // INCLUDES
       
    23 #include <e32cmn.h>
       
    24 //<cmail>
       
    25 #include "esmricalviewerdefs.hrh"      // tesmrmeetingrequestmethod
       
    26 #include "esmricalvieweropcodes.hrh"   // tesmricalvieweroperationtype
       
    27 //</cmail>
       
    28 
       
    29 // FORWARD DECLARATIONS
       
    30 class CFSMailMessage;
       
    31 
       
    32 // CLASS DECLARATIONS
       
    33 /**
       
    34  * ICal viewer's observer interface.
       
    35  * This is used to signal client about asynchronous operation's completion.
       
    36  */
       
    37 class MESMRIcalViewerObserver
       
    38     {
       
    39     public: // Types
       
    40         /**
       
    41          * Result for iCal viewer operation
       
    42          */
       
    43         struct TIcalViewerOperationResult
       
    44             {
       
    45             /// Own: Type of the operation
       
    46             TESMRIcalViewerOperationType iOpType;
       
    47             /// Own: Operation result e.g. KErrCancel if user has canceled operation.
       
    48             ///         System wide error code.
       
    49             TInt iResultCode;
       
    50             /// Own: Relevant only if the iOpType is EResolveMRMethod
       
    51             TESMRMeetingRequestMethod iMethod;
       
    52             /// Ref: Mail message related to this operation
       
    53             CFSMailMessage* iMessage;
       
    54             /// Own: Relevant only when user has responsed to MR
       
    55             ///      Otherwise this is always set to EESMRAttendeeStatusUnknown
       
    56             TESMRAttendeeStatus iAttendeeStatus;
       
    57             };
       
    58 
       
    59     public: // New functions
       
    60         /**
       
    61          * Called when the operation is completed succesfully.
       
    62          *
       
    63          * @param aResult A result of the operation.
       
    64          */
       
    65         virtual void OperationCompleted(
       
    66                         TIcalViewerOperationResult aResult ) = 0;
       
    67 
       
    68         /**
       
    69          * Called when error occurs during the operation.
       
    70          *
       
    71          * @param aResult error result of the operation.
       
    72          */
       
    73         virtual void OperationError(
       
    74                         TIcalViewerOperationResult aResult ) = 0;
       
    75 
       
    76         /**
       
    77          * Returns an extension point for this interface or NULL.
       
    78          * @param aExtensionUid Uid of extension
       
    79          * @return Extension point or NULL
       
    80          */
       
    81         virtual TAny* MRIcalViewerObserverExtension(
       
    82                 TUid /*aExtensionUid*/ ) { return NULL; }
       
    83 
       
    84     protected: // construction and destruction
       
    85         /**
       
    86          * C++ Destructor
       
    87          */
       
    88         virtual ~MESMRIcalViewerObserver() { }
       
    89     };
       
    90 
       
    91 #endif // MESMRICALVIEWEROBSERVER_H
       
    92 
       
    93 // End of file