diff -r 000000000000 -r 72b543305e3a email/pop3andsmtpmtm/popservermtm/inc/PopsTopPop.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/email/pop3andsmtpmtm/popservermtm/inc/PopsTopPop.h Thu Dec 17 08:44:11 2009 +0200 @@ -0,0 +1,99 @@ +// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies). +// All rights reserved. +// This component and the accompanying materials are made available +// under the terms of "Eclipse Public License v1.0" +// which accompanies this distribution, and is available +// at the URL "http://www.eclipse.org/legal/epl-v10.html". +// +// Initial Contributors: +// Nokia Corporation - initial contribution. +// +// Contributors: +// +// Description: +// popservermtm module header +// @internalComponent +// @released +// +// + +#ifndef __POPSTOPPOP_H__ +#define __POPSTOPPOP_H__ + +#include +#include + +class CImPop3Session; +class CImLogMessage; +class CImPop3Top; + +// +// CImPop3TopPopulate +// +// +// +// +class CImPop3TopPopulate : public CMsgActive + { +public: + static CImPop3TopPopulate *NewL(const CMsvEntrySelection&, CMsvServerEntry&, TInt aLimit, CImPop3Session*, RFs&, CImLogMessage* aLogMessage, TBool aDisconnectedMode, RArray& aRemoteSizes); + ~CImPop3TopPopulate(); + + void StartL(TRequestStatus& aStatus); + TPop3Progress Progress(); + void Pause(); + void ResumeL(CImPop3Session* aPopSession, TRequestStatus& aStatus); + void CancelAllowResume(); + +private: + + CImPop3TopPopulate( CMsvServerEntry&, TInt aLimit, CImPop3Session*, RFs&, CImLogMessage* aLogMessage, TBool aDisconnectedMode, RArray& aRemoteSizes); + void ConstructL( const CMsvEntrySelection& ); + + void DoTransferL(TMsvEntry& aEntry ); + void DoRetrieveL(); + void RetrievalCompleteL(); + + void DoRunL(); + void DoComplete(TInt& aCompleteStatus); + void DoCancel(); + + void RunLProcessingL(); + void LogFetchedMessageL(); + + + + enum + { + EPopTopPopRetrieving, + EPopTopPopDeleting, + EPopTopPopLogging + }; +private: + CMsvEntrySelection* iSource; + CMsvServerEntry& iDestination; + CImPop3Session* iPopSession; + CImPop3Top* iTop; + + TBool iCopy; + RFs iFs; + TPop3Progress iProgress; + // CRecv things + CImRecvConvert* iRecvConverter; + CImLogMessage* iLogMessage; + TBool iDisconnectedMode; + TMsvId iServiceId; + TInt iPopTopPopState; + TBool iProcessComplete; + TBool iAlreadyComplete; + TBool iMessageMarkedForDelete; + TBool iRetrieveMessage; + TInt iMsgCtr; + TMsvId iDestId; + TInt iSavedError; + TInt iTopLimit; + TInt iCurrentMsgSize; + RArray iRemoteSizes; + TBool iMigratingToNewBearer; + }; +#endif