filemanager/bkupengine/inc/CMMCScBkupStateArchiveOpJavaData.h
branchRCL_3
changeset 39 65326cf895ed
parent 0 6a9f87576119
equal deleted inserted replaced
38:491b3ed49290 39:65326cf895ed
       
     1 /*
       
     2 * Copyright (c) 2005 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: Declaration for CMMCScBkupStateArchiveOpJavaData
       
    15 *     
       
    16 *
       
    17 */
       
    18 
       
    19 #ifndef __CMMCSCBKUPSTATEARCHIVEOPJAVADATA_H__
       
    20 #define __CMMCSCBKUPSTATEARCHIVEOPJAVADATA_H__
       
    21 
       
    22 // System includes
       
    23 #include <connect/sbtypes.h>
       
    24 
       
    25 // User includes
       
    26 #include "CMMCScBkupStateOpAware.h"
       
    27 #include "TMMCScBkupArchiveVector.h"
       
    28 #include "CMMCScBkupTransferWriteRequest.h"
       
    29 #include "CMMCScBkupTransferReadRequest.h"
       
    30 
       
    31 // Namespaces
       
    32 using namespace conn;
       
    33 
       
    34 // Classes referenced
       
    35 class CMMCScBkupDataOwnerInfo;
       
    36 
       
    37 
       
    38 
       
    39 /**
       
    40 *
       
    41 *
       
    42 * @since 3.0
       
    43 */
       
    44 NONSHARABLE_CLASS(CMMCScBkupStateArchiveOpJavaData) : public CMMCScBkupStateOpAware, public MMMCScBkupIndexHandler
       
    45     {
       
    46     public:
       
    47 
       
    48         /**
       
    49         * Static constructor
       
    50         */
       
    51         static CMMCScBkupStateArchiveOpJavaData* NewL( MMMCScBkupDriver& aDriver );
       
    52 
       
    53         /**
       
    54         * C++ destructor
       
    55         */
       
    56         ~CMMCScBkupStateArchiveOpJavaData( );
       
    57 
       
    58     private:
       
    59 
       
    60         /**
       
    61         * C++ default constructor
       
    62         */
       
    63         CMMCScBkupStateArchiveOpJavaData( MMMCScBkupDriver& aDriver );
       
    64 
       
    65     public: // From CMMCScBkupState
       
    66         TMMCScBkupStateId StateId() const;
       
    67 
       
    68     public: // From CMMCScBkupStateOpAware
       
    69         TMMCScBkupStateId NextStateBackupId( TBool aPartial ) const;
       
    70         TMMCScBkupStateId NextStateRestoreId( TBool aPartial ) const;
       
    71 
       
    72     private: // From CMMCScBkupStateOpAware
       
    73         void PerformStateInitBackupL( TBool aPartial );
       
    74         void PerformStateInitRestoreL( TBool aPartial );
       
    75         void PerformAsynchronousStateStepBackupL( TBool aPartial );
       
    76         void PerformAsynchronousStateStepRestoreL( TBool aPartial );
       
    77         void PerformLastRightsBackupL( TBool aPartial );
       
    78         void PerformLastRightsRestoreL( TBool aPartial );
       
    79         TBool PerformAsynchronousErrorCleanupBackup( TBool aPartial, TInt aError );
       
    80         TBool PerformAsynchronousErrorCleanupRestore( TBool aPartial, TInt aError );
       
    81 
       
    82     private: // From CMMCScBkupState
       
    83         void PerformAsynchronousCancellation();
       
    84 
       
    85     private: // From MMMCScBkupIndexHandler
       
    86         void AddIndexRecordL( CMMCScBkupArchiveFooter& aFooter, CMMCScBkupDataOwnerInfo& aDataOwner, const TMMCScBkupArchiveVector& aInfo, TDriveNumber aDrive );
       
    87 
       
    88     private: // Internal enumerations
       
    89         enum TJavaState
       
    90             {
       
    91             EJavaStateIdle = 0,
       
    92             EJavaStateMidlet,
       
    93             EJavaStateMidletData
       
    94             };
       
    95 
       
    96     private: // Internal methods
       
    97         void BackupMidletL();
       
    98         void BackupMidletDataL();
       
    99         void RestoreMidletL();
       
   100         void RestoreMidletDataL();
       
   101 
       
   102     private: // Member data
       
   103 
       
   104         //
       
   105         TInt iIndexValueCurrent;
       
   106         //
       
   107         TJavaState iCurrentJavaState;
       
   108         //
       
   109         RArray<TMMCScBkupArchiveDriveAndVector> iRestoreEntries;
       
   110         //
       
   111         CMMCScBkupWriteDataTransferRequest< TJavaTransferType >* iBackupTransferObjectMidlet;
       
   112         CMMCScBkupWriteDataTransferRequest< TJavaTransferType >* iBackupTransferObjectMidletData;
       
   113         CMMCScBkupReadDataTransferRequest< TJavaTransferType >* iRestoreTransferObjectMidlet;
       
   114         CMMCScBkupReadDataTransferRequest< TJavaTransferType >* iRestoreTransferObjectMidletData;
       
   115     };
       
   116 
       
   117 
       
   118 
       
   119 
       
   120 
       
   121 #endif // __CMMCSCBKUPSTATEARCHIVEOPJAVADATA_H__
       
   122 
       
   123 //End of File