ipsservices/ipssosplugin/inc/ipsplgdisconnectop.h
changeset 20 ecc8def7944a
parent 18 578830873419
child 23 2dc6caa42ec3
--- a/ipsservices/ipssosplugin/inc/ipsplgdisconnectop.h	Fri Apr 16 14:51:52 2010 +0300
+++ b/ipsservices/ipssosplugin/inc/ipsplgdisconnectop.h	Mon May 03 12:23:15 2010 +0300
@@ -18,94 +18,87 @@
 #ifndef IPSPLGDISCONNECTOP_H
 #define IPSPLGDISCONNECTOP_H
 
-
 #include "ipsplgonlineoperation.h"
 
-
 /**
-* Disconnect operation.
-* 
+* Disconnect operation
+* Handles both POP and IMAP cases
 */
 NONSHARABLE_CLASS ( CIpsPlgDisconnectOp ) :
     public CIpsPlgOnlineOperation
     {
 public:
-
-        /**
-        *
-        */
-        static CIpsPlgDisconnectOp* NewL(
-            CMsvSession& aMsvSession,
-            TRequestStatus& aObserverRequestStatus,
-            TMsvId aService,
-            CIpsPlgTimerOperation& aActivityTimer,
-            TFSMailMsgId aFSMailBoxId,
-            MFSMailRequestObserver& aFSOperationObserver,
-            TInt aFSRequestId,
-            TBool aDoRemoveAfterDisconnect = EFalse );
+    /**
+    * Construction
+    * @param aMsvSession client/server session to MsvServer
+    * @param aObserverRequestStatus caller's status
+    * @param aService serviceId of the mailbox
+    * @param aActivityTimer mailbox specific activity timer
+    * @param aFSMailBoxId specifies mailbox
+    * @param aFSOperationObserver observer of the operation
+    * @param aFSRequestId identifier for this request instance
+    * @param aDoRemoveAfterDisconnect
+    * @return instance of this operation class
+    */
+    // <qmail> parameter removed
+    static CIpsPlgDisconnectOp* NewL(
+        CMsvSession& aMsvSession,
+        TRequestStatus& aObserverRequestStatus,
+        TMsvId aService,
+        CIpsPlgTimerOperation& aActivityTimer,
+        TFSMailMsgId aFSMailBoxId,
+        MFSMailRequestObserver* aFSOperationObserver,
+        TInt aFSRequestId );
 
-        /**
-        *
-        */
-        virtual ~CIpsPlgDisconnectOp();
-
-        /**
-        *
-        */
-        const TDesC8& ProgressL();
+    virtual ~CIpsPlgDisconnectOp();
 
-        /**
-        *
-        */
-        const TDesC8& GetErrorProgressL( TInt aError );
-        
-        /**
-        * 
-        */
-       TFSProgress GetFSProgressL() const;
-
-// <qmail> Connected() used from baseclass
-    protected:
+    /**
+    * From MsvOperation
+    * Gets information on the progress of the operation
+    * (see MsvOperation header)
+    */
+    const TDesC8& ProgressL();
 
-        /**
-        * From CActive
-        */
-        void DoRunL();
-        
-    private:
+    /**
+    * From CIpsPlgBaseOperation
+    * For reporting if DoRunL leaves
+    */
+    const TDesC8& GetErrorProgressL( TInt aError );
+    
+   TFSProgress GetFSProgressL() const;
 
-        /**
-        *
-        */
-        CIpsPlgDisconnectOp(
-            CMsvSession& aMsvSession,
-            TRequestStatus& aObserverRequestStatus,
-            TMsvId aServiceId,
-            CIpsPlgTimerOperation& aActivityTimer,
-            TFSMailMsgId aFSMailBoxId,
-            MFSMailRequestObserver& aFSOperationObserver,
-            TInt aFSRequestId,
-            TBool aDoRemoveAfterDisconnect );
+   // <qmail> Connected() used from baseclass
+   
+   // <qmail> new function in this op
+   TIpsOpType IpsOpType() const;
+   
+protected: // From CActive
+    void DoRunL();
+    
+private:
 
-        /**
-        *
-        */
-        void ConstructL();
+    CIpsPlgDisconnectOp(
+        CMsvSession& aMsvSession,
+        TRequestStatus& aObserverRequestStatus,
+        TMsvId aServiceId,
+        CIpsPlgTimerOperation& aActivityTimer,
+        TFSMailMsgId aFSMailBoxId,
+        MFSMailRequestObserver* aFSOperationObserver,
+        TInt aFSRequestId );
 
-        /**
-        *
-        */
-        void DoDisconnectL();
+    void ConstructL();
 
-        
-    private: // Data
-        
-        TPckgBuf<TPop3Progress> iPopProgress;
-        TPckgBuf<TImap4CompoundProgress> iImapProgress;
-        TMsvEntry               iTEntry;
-        TBool                   iDisconnected;
-        TBool                   iDoRemoveAfterDisconnect;
-        
+    /**
+    * Sends the disconnect command to MsvServer
+    */
+    void DoDisconnectL();
+
+private: // Data
+    TPckgBuf<TPop3Progress>          iPopProgress;
+    TPckgBuf<TImap4CompoundProgress> iImapProgress;
+    TMsvEntry                        iTEntry;
+    // <qmail> iDisconnected; removed; using baseclass's Connected() instead
+    // <qmail> iDoRemoveAfterDisconnect removed; not a task for disconnect op
     };
 
 #endif //IPSPLGDISCONNECTOP_H