appinstaller/AppinstUi/Daemon/Inc/silentuninstaller.h
changeset 0 ba25891c3a9e
child 25 7333d7932ef7
equal deleted inserted replaced
-1:000000000000 0:ba25891c3a9e
       
     1 /*
       
     2 * Copyright (c) 2004 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 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef SILENTUNINSTALLER_H
       
    20 #define SILENTUNINSTALLER_H
       
    21 
       
    22 //  INCLUDES
       
    23 #include <e32base.h>
       
    24 #include <f32file.h>
       
    25 #include <SWInstApi.h>
       
    26 
       
    27 namespace Swi
       
    28 {
       
    29 /**
       
    30  *  CSilentUninstaller class handles uninstalling of the single sisx file. 
       
    31  */
       
    32 class CSilentUninstaller : public CBase
       
    33     {
       
    34     public:  
       
    35         
       
    36         /**
       
    37          * Two-phased constructor.
       
    38          * 
       
    39          * @param aFs File server session.
       
    40          */
       
    41         static CSilentUninstaller* NewL( RFs& aFs );
       
    42         
       
    43         /**
       
    44          * Destructor.
       
    45          */
       
    46         virtual ~CSilentUninstaller();
       
    47 
       
    48     public:  
       
    49 
       
    50         /**
       
    51          * This function requests silent uninstalling from the 
       
    52          * SWI installer.
       
    53          *          
       
    54          * @param aUid Package UID
       
    55          * @param aReqStatus Request status
       
    56          * @param aMIME MIME type descriptor.
       
    57          */
       
    58         void UninstallL(         
       
    59                 TUid& aUid, 
       
    60                 TRequestStatus& aReqStatus, 
       
    61                 TDesC8& aMIME  );
       
    62 
       
    63         /**
       
    64          * Cancel the current installation.        
       
    65          */
       
    66         void Cancel();        
       
    67         
       
    68     private:
       
    69 
       
    70         /**
       
    71          * Constructor.
       
    72          * 
       
    73          * @param aFs File server 
       
    74          */  
       
    75         CSilentUninstaller( RFs& aFs );
       
    76          
       
    77         /**
       
    78          * 2nd phase constructor.
       
    79          */
       
    80         void ConstructL();
       
    81 
       
    82     private: //  Data
       
    83         
       
    84         // Silent uninstaller
       
    85         SwiUI::RSWInstSilentLauncher iLauncher;
       
    86         // Uninstall options
       
    87         SwiUI::TUninstallOptions iOptions;
       
    88         // Uninstall options package
       
    89         SwiUI::TUninstallOptionsPckg iOptionsPckg;
       
    90         // File server
       
    91         RFs& iFs;
       
    92         // Defines need of connection to install server.
       
    93         TBool iConnected;
       
    94     };
       
    95 }
       
    96 
       
    97 #endif /*SILENTUNINSTALLER_H*/
       
    98             
       
    99 // End of File