meetingrequest/mricalviewer/inc/cesmrmrinfoicalretriever.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:  ESMR mrinfo calendar entry retriever definition
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef CESMRMRINFOICALRETRIEVERCMD_H
       
    20 #define CESMRMRINFOICALRETRIEVERCMD_H
       
    21 
       
    22 #include <e32base.h>
       
    23 //<cmail>
       
    24 #include "mmrinfoobject.h"
       
    25 //</cmail>
       
    26 #include "cesmricalviewercommandbase.h"
       
    27 
       
    28 class TESMRInputParams;
       
    29 class CCalEntry;
       
    30 class CESMRAttachmentInfo;
       
    31 
       
    32 /**
       
    33  * CESMRInfoIcalRetrieverCmd is the command used to execute
       
    34  * calendar entry retrievals from calendar db based on 
       
    35  * MMRInfoObject objects
       
    36  */
       
    37 NONSHARABLE_CLASS( CESMRInfoIcalRetrieverCmd ) :
       
    38         public CESMRIcalViewerCommandBase
       
    39     {
       
    40 public: // Construction and destruction
       
    41     /**
       
    42      * Creates and initializes new CESMRInfoIcalRetriever object. Ownership
       
    43      * is transferred to caller.
       
    44      * @param aCalSession Reference to calendar database session
       
    45      * @aInputParameters set of parameters for the command class
       
    46      * @return Pointer to CESMRInfoIcalRetriever object.
       
    47      */
       
    48     static CESMRInfoIcalRetrieverCmd* NewL(
       
    49             CCalSession& aCalSession,
       
    50             TESMRInputParams& aInputParameters );
       
    51 
       
    52     /**
       
    53      * C++ destructor.
       
    54      */
       
    55     ~CESMRInfoIcalRetrieverCmd();
       
    56 
       
    57 public: // From MESMRIcalRetriever
       
    58     void ExecuteCommandL(
       
    59             CFSMailMessage& aMessage,
       
    60             MESMRIcalViewerObserver& aObserver );
       
    61     void CancelCommand();
       
    62 
       
    63 private: // Implementation
       
    64     TBool RetrieveCalendarEntryL();
       
    65     CESMRInfoIcalRetrieverCmd(
       
    66             CCalSession& aCalSession,
       
    67             TESMRInputParams& aInputParameters );
       
    68     void ConstructL();
       
    69     void CreateEntryL();
       
    70     void FillCommonFieldsL();
       
    71     void FillRecurrenceL();
       
    72     void FillAttachmentInfoL();
       
    73 
       
    74 private: // Data
       
    75     // Own: Supported fields array
       
    76     RArray<MMRInfoObject::TESMRInfoField> iSupportedFields;
       
    77     /// Own: Calendar entry object
       
    78     CCalEntry* iConvertedEntry;
       
    79     /// Ref: Reference to MRINFO object
       
    80     MMRInfoObject* iMRInfoObject;
       
    81     /// Ref: Reference to input parameters
       
    82     TESMRInputParams& iInputParameters;
       
    83     /// Own: Result structure
       
    84     MESMRIcalViewerObserver::TIcalViewerOperationResult iResult;
       
    85     // Own
       
    86     CESMRAttachmentInfo* iAttachmentInfo;
       
    87     };
       
    88 
       
    89 #endif 
       
    90