meetingrequest/mricalviewer/inc/cesmricalviewerremovemrfromcalcmd.h
changeset 0 8466d47a6819
child 16 4ce476e64c59
equal deleted inserted replaced
-1:000000000000 0:8466d47a6819
       
     1 /*
       
     2 * Copyright (c) 2007-2009 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:  Responsing to meeting request asynchronously
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef CESMRICALVIEWERREMOVEMRFROMCALCMD_H
       
    20 #define CESMRICALVIEWERREMOVEMRFROMCALCMD_H
       
    21 
       
    22 #include "cesmricalviewerasynccommand.h"
       
    23 #include "tesmrinputparams.h"
       
    24 //<cmail>
       
    25 #include "mesmricalviewerobserver.h"
       
    26 #include "esmricalviewerdefs.hrh"
       
    27 //</cmail>
       
    28 #include <MAgnEntryUi.h>
       
    29 
       
    30 class CFSMailClient;
       
    31 class CESMRUiLauncher;
       
    32 
       
    33 /**
       
    34  * Command for removing meeting request from calendar
       
    35  * Command completion is reported to caller via MESMRIcalViewerObserver
       
    36  * interface.
       
    37  */
       
    38 NONSHARABLE_CLASS( CESMRIcalViewerRemoveMRFromCalCmd ) :
       
    39     public CESMRIcalViewerAsyncCommand,
       
    40     public MESMRIcalViewerObserver,
       
    41     public MAgnEntryUiCallback
       
    42     {
       
    43 public: // Construction and destruction
       
    44 
       
    45     /**
       
    46      * Creates and initializes new CESMRIcalViewerResponseToMRCmd command.
       
    47      * @param aCalSession Reference to calendar session.
       
    48      * @param aMailClient Reference to FS Email mail client object
       
    49      */
       
    50     static CESMRIcalViewerRemoveMRFromCalCmd* NewL(
       
    51             CCalSession& aCalSession,
       
    52             CFSMailClient& aMailClient );
       
    53     
       
    54     /**
       
    55      * C++ Desctruction
       
    56      */
       
    57     ~CESMRIcalViewerRemoveMRFromCalCmd();
       
    58 
       
    59 public: // From MESMRIcalViewerObserver
       
    60     void OperationCompleted(
       
    61             MESMRIcalViewerObserver::TIcalViewerOperationResult aResult );
       
    62     void OperationError(
       
    63             MESMRIcalViewerObserver::TIcalViewerOperationResult aResult );
       
    64 
       
    65 public: // From MAgnEntryUiCallback
       
    66     void ProcessCommandL(TInt aCommandId);
       
    67     TInt ProcessCommandWithResultL( TInt aCommandId );
       
    68     TBool IsCommandAvailable( TInt aCommandId );
       
    69 
       
    70 private: // From MESMRIcalViewerAsyncCommand
       
    71     void ExecuteAsyncCommandL();
       
    72     void CancelAsyncCommand();
       
    73 
       
    74 private: // Implementation
       
    75     CESMRIcalViewerRemoveMRFromCalCmd(
       
    76             CCalSession& aCalSession,
       
    77             CFSMailClient& aMailClient );
       
    78     void ConstructL();
       
    79     void LaunchUiL();
       
    80     void HandleOperationCompletedL(
       
    81             MESMRIcalViewerObserver::TIcalViewerOperationResult aResult );
       
    82 
       
    83 private: // Data
       
    84     /// Ref: Reference to input parameters
       
    85     TESMRInputParams iESMRInputParams;
       
    86     /// Ref: Reference to mail client
       
    87     CFSMailClient& iMailClient;
       
    88     /// Own: MR retriever command
       
    89     RPointerArray< MESMRIcalViewerCommand > iMRRetrieverCommands;
       
    90     /// Own: Current command index
       
    91     TInt iCurrentCommand;
       
    92     /// Own: UI launcher
       
    93     CESMRUiLauncher* iUILauncher;
       
    94     };
       
    95 
       
    96 #endif
       
    97 
       
    98 // EOF