diff -r d45095c2f4f3 -r bee149131e4b mmappcomponents/mmmtpdataprovider/mmmtpdprequestprocessor/inc/ccopyobject.h --- a/mmappcomponents/mmmtpdataprovider/mmmtpdprequestprocessor/inc/ccopyobject.h Tue Feb 02 00:27:58 2010 +0200 +++ b/mmappcomponents/mmmtpdataprovider/mmmtpdprequestprocessor/inc/ccopyobject.h Fri Feb 19 23:18:32 2010 +0200 @@ -22,7 +22,6 @@ #include "crequestprocessor.h" class RFs; -class CFileMan; class CMTPObjectMetaData; class CMTPTypeObjectPropList; class CMTPTypeObjectPropListElement; @@ -70,32 +69,10 @@ */ IMPORT_C void ServiceL(); - /** - * Set MetaData to CMetadataAccessWrapper, for internal use - * @param aPropCode, specify property code of aMediaProp - * @param aNewData, object property value which will be get from - * aObjectMetaData - * @param aObjectMetaData, owner of the property which should be - * inserted or updated into database - * @return response code - */ - IMPORT_C TMTPResponseCode ServiceMetaDataToWrapper( const TUint16 aPropCode, - MMTPType& aNewData, - const CMTPObjectMetaData& aObject ); - virtual void ServiceGetSpecificObjectPropertyL( TUint16 aPropCode, TUint32 aHandle, const CMTPObjectMetaData& aObjectMetaData ) = 0; - virtual TMTPResponseCode ServiceSetSpecificObjectPropertyL( TUint16 aPropCode, - const CMTPObjectMetaData& aObject, - const CMTPTypeObjectPropListElement& aElement ) = 0; - - // from CActive - IMPORT_C void RunL(); - - IMPORT_C TInt RunError( TInt aError ); - private: /** * Retrieve the parameters of the request @@ -107,13 +84,13 @@ /** * Copy object operation */ - void CopyObjectL( TUint32& aNewHandle ); + void CopyObjectL(); /** * Check if we can copy the file to the new location */ TMTPResponseCode CanCopyObjectL( const TDesC& aOldName, - const TDesC& aNewName ) const; + const TDesC& aNewName ) const; /** * Save the object properties before doing the copy @@ -132,53 +109,22 @@ */ TUint32 CopyFileL( const TDesC& aNewFileName ); - /* - * Generate the list of handles that need to be copied to the new location. - */ - void GenerateObjectHandleListL( TUint32 aParentHandle ); - - /** - * A helper function of CopyObjectL. - * @param aNewFolderName the new full file folder name after copy. - * @return objecthandle of new copy of the folder. - */ - TUint32 CopyFolderL( const TDesC& aNewFolderName ); - - /** - * Set the object properties in the object property store. - */ - void SetPropertiesL( const TDesC& aOldFileName, - const TDesC& aNewFileName, - const CMTPObjectMetaData& aObject ); - /** * Update object info in the database. */ - TUint32 UpdateObjectInfoL( const TDesC& aOldObjectName, - const TDesC& aNewObjectName); - - /* - * A helper function of CopyObjectL - * Copy a single object and update the database - */ - void CopyAndUpdateL( TUint32 objectHandle ); + TUint32 AddObjectToStoreL( const TDesC& aOldObjectName, + const TDesC& aNewObjectName ); protected: CMTPTypeObjectPropListElement* iPropertyElement; MMmMtpDpConfig& iDpConfig; CMTPTypeObjectPropList* iPropertyList; + private: + TUint32 iStorageId; CMTPObjectMetaData* iObjectInfo; // Not owned - RArray iObjectHandles; - CFileMan* iFileMan; HBufC* iDest; TUint32 iNewParentHandle; - TUint32 iHandle; - TUint32 iStorageId; - TInt iCopyObjectIndex; - TInt iNumberOfObjects; - HBufC* iPathToCopy; - HBufC* iNewRootFolder; TTime iPreviousModifiedTime; };