fotaapplication/fotaserver/fotacustcmds/inc/fotacustcmdfirmwareupdate.h
changeset 44 39aa16f3fdc2
parent 43 c8e5c3d81b42
child 53 b3a7d8e28262
child 57 f5b689a4f7a2
equal deleted inserted replaced
43:c8e5c3d81b42 44:39aa16f3fdc2
     1 /*
       
     2 * Copyright (c) 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:
       
    15 * Declaration of CFotaCustCmdFirmwareUpdate class.
       
    16 *
       
    17 */
       
    18 
       
    19 #ifndef FOTACUSTCMDFIRMWAREUPDATE_H
       
    20 #define FOTACUSTCMDFIRMWAREUPDATE_H
       
    21 
       
    22 #include <e32base.h>
       
    23 #include <ssm/ssmcustomcommand.h>
       
    24 
       
    25 /**
       
    26  *  Each command is implemented in a class derived from MSsmCustomCommand.
       
    27  *  It is also possible to implement multiple similar command in the same
       
    28  *  class and differentiate between them based on constructor parameters
       
    29  *  from the factory method.
       
    30  */
       
    31 NONSHARABLE_CLASS( CFotaCustCmdFirmwareUpdate ) : public CBase, public MSsmCustomCommand
       
    32     {
       
    33 
       
    34 public:
       
    35 
       
    36     /**
       
    37      * Two-phased constructor
       
    38      */
       
    39 	static CFotaCustCmdFirmwareUpdate* NewL();
       
    40 
       
    41     /**
       
    42      * Destructor
       
    43      */
       
    44     virtual ~CFotaCustCmdFirmwareUpdate();
       
    45 
       
    46 private: // From MSsmCustomCommand
       
    47 
       
    48     /**
       
    49      * @see MSsmCustomCommand
       
    50      */
       
    51     TInt Initialize( CSsmCustomCommandEnv* aCmdEnv );
       
    52 
       
    53     /**
       
    54      * @see MSsmCustomCommand
       
    55      */
       
    56 	void Execute( const TDesC8& aParams, TRequestStatus& aRequest );
       
    57 	
       
    58 	  /**
       
    59      * invokes fotaengine after fota update
       
    60      * @Params None
       
    61      * @return  None
       
    62      *
       
    63      */
       
    64 	void ExecuteL();
       
    65 
       
    66     /**
       
    67      * @see MSsmCustomCommand
       
    68      */
       
    69 	void ExecuteCancel();
       
    70 
       
    71     /**
       
    72      * @see MSsmCustomCommand
       
    73      */
       
    74 	void Close();
       
    75 
       
    76     /**
       
    77      * @see MSsmCustomCommand
       
    78      */
       
    79 	void Release();
       
    80 
       
    81 private: // data
       
    82 
       
    83     /**
       
    84     * If the command needs command env in Execute function, it should store it
       
    85     * to member variable:
       
    86     *
       
    87     * Custom command environment. Not owned. Set in Initialize.
       
    88     * CSsmCustomCommandEnv* iEnv;
       
    89     */
       
    90 
       
    91     };
       
    92 
       
    93 #endif // FOTACUSTCMDFIRMWAREUPDATE_H