wvuing/wvcommandutils/Inc/CCAContactEditCmd.h
changeset 0 094583676ce7
equal deleted inserted replaced
-1:000000000000 0:094583676ce7
       
     1 /*
       
     2 * Copyright (c) 2006 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: Login Command class
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 #ifndef CCACONTACTEDITCMD_H
       
    21 #define CCACONTACTEDITCMD_H
       
    22 
       
    23 
       
    24 //  INCLUDES
       
    25 #include <e32base.h>
       
    26 #include "MCACommand.h"
       
    27 #include "MCAUiContactEditCmdCB.h"
       
    28 #include "MCAMainViewArrayPC.h"
       
    29 #include "CCAContactEditPC.h"
       
    30 
       
    31 
       
    32 // FORWARD DECLARATIONS
       
    33 class MCAProcessManager;
       
    34 
       
    35 
       
    36 // CLASS DECLARATION
       
    37 /**
       
    38 *  Login Command class.
       
    39 *
       
    40 */
       
    41 NONSHARABLE_CLASS( CCAContactEditCmd ) : public CBase, public MCACommand
       
    42     {
       
    43 public:
       
    44     // Constructors and destructor
       
    45 
       
    46     /**
       
    47     * Destructor.
       
    48     */
       
    49     virtual ~CCAContactEditCmd();
       
    50 
       
    51 
       
    52 public:
       
    53 
       
    54     /**
       
    55     * Set command observer.
       
    56     *
       
    57     * @param aObserver Command observer
       
    58     */
       
    59     void SetObserver( MCACommandObserver& aObserver );
       
    60 
       
    61     /**
       
    62     * Cancel command.
       
    63     *
       
    64     */
       
    65     void CancelCommand();
       
    66     /**
       
    67     * Executes the command.
       
    68     *
       
    69     */
       
    70     void ExecuteCommandL();
       
    71 
       
    72     /**
       
    73     *
       
    74     * @return ETrue if the command is asynchronous, otherwise EFalse.
       
    75     */
       
    76     TBool IsAsynchronous();
       
    77 
       
    78     /**
       
    79     * Two-phased constructor
       
    80     * @param aProcessManager reference to MCAProcessManager
       
    81     * @param aContactEditCmdCB reference to MCAUiContactEditCmdCB
       
    82     * @return New instance of CCAContactEditCmd
       
    83     */
       
    84     static CCAContactEditCmd* NewL( MCAProcessManager& aProcessManager,
       
    85                                     MCAUiContactEditCmdCB& aContactEditCmdCB );
       
    86 
       
    87     /**
       
    88     * Two-phased constructor
       
    89     * @param aProcessManager reference to MCAProcessManager
       
    90     * @param aContactEditCmdCB reference to MCAUiContactEditCmdCB
       
    91     * @return New instance of CCAContactEditCmd
       
    92     */
       
    93     static CCAContactEditCmd* NewLC( MCAProcessManager& aProcessManager,
       
    94                                      MCAUiContactEditCmdCB& aContactEditCmdCB );
       
    95 
       
    96 
       
    97 protected:
       
    98 
       
    99 
       
   100     /**
       
   101     * LoadCCAContactDetails command.
       
   102     *
       
   103     * @param MCAUiContactEditCmdCB::TContactEditParams - Required
       
   104     *			data to perform the load operation
       
   105     */
       
   106     void LoadCCAContactDetailsL(
       
   107         MCAUiContactEditCmdCB::TContactEditParams &aParams );
       
   108 
       
   109     /**
       
   110     * SaveCCAContactDetails command.
       
   111     *
       
   112     * @param MCAUiContactEditCmdCB::TContactEditParams - Required
       
   113     *			data to perform the save operation
       
   114     */
       
   115     void CCAContactEditCmd::SaveCCAContactDetailsL
       
   116     ( MCAUiContactEditCmdCB::TContactEditParams &aParams );
       
   117 
       
   118     /**
       
   119     * MoveContactL command.
       
   120     *
       
   121     * @param MCAUiContactEditCmdCB::TContactEditParams - Required
       
   122     *			data to perform the move operation
       
   123     */
       
   124     void MoveContactL( MCAUiContactEditCmdCB::TContactEditParams &aParams );
       
   125 
       
   126 private:
       
   127 
       
   128     /**
       
   129     * C++ default constructor.
       
   130     * @param1 Reference to UI call back object
       
   131     * @param2 Reference to contact editors process component
       
   132     */
       
   133     CCAContactEditCmd( MCAUiContactEditCmdCB& aUiContactEditCmdCB,
       
   134                        MCAContactEditPC& aContactEditPC );
       
   135 
       
   136 
       
   137 private:
       
   138 
       
   139     //not owned - Reference to UI call back object
       
   140     MCAUiContactEditCmdCB& iUiContactEditCmdCB;
       
   141 
       
   142     //not owned - Reference to contact editors process component
       
   143     CCAContactEditPC&	iCCAContactEditPC;
       
   144     };
       
   145 
       
   146 #endif      // CCACONTACTEDITCMD_H
       
   147 
       
   148 // End of File