emailuis/nmframeworkadapter/inc/nmfwamessagesendingoperation.h
changeset 23 2dc6caa42ec3
parent 20 ecc8def7944a
equal deleted inserted replaced
20:ecc8def7944a 23:2dc6caa42ec3
    16  */
    16  */
    17 
    17 
    18 #ifndef NMFWAMESSAGESENDINGOPERATION_H_
    18 #ifndef NMFWAMESSAGESENDINGOPERATION_H_
    19 #define NMFWAMESSAGESENDINGOPERATION_H_
    19 #define NMFWAMESSAGESENDINGOPERATION_H_
    20 
    20 
    21 #include <QObject>
    21 #include <QPointer>
    22 #include <nmmessagesendingoperation.h>
    22 #include <nmmessagesendingoperation.h>
    23 #include <nmcommon.h>
    23 #include <nmcommon.h>
    24 #include <CFSMailCommon.h>
    24 #include <CFSMailCommon.h>
    25 #include <MFSMailRequestObserver.h>
    25 #include <MFSMailRequestObserver.h>
    26 
    26 
    35 public:
    35 public:
    36     NmFwaMessageSendingOperation(NmDataPluginInterface &pluginInterface,
    36     NmFwaMessageSendingOperation(NmDataPluginInterface &pluginInterface,
    37                                  NmMessage *message,
    37                                  NmMessage *message,
    38                                  CFSMailClient &mailClient);
    38                                  CFSMailClient &mailClient);
    39     
    39     
    40     ~NmFwaMessageSendingOperation();
       
    41 
       
    42     const NmMessage *getMessage() const;
    40     const NmMessage *getMessage() const;
    43 
    41 
    44     // from MFSMailRequestObserver
    42     // from MFSMailRequestObserver
    45     void RequestResponseL(TFSProgress aEvent, TInt aRequestId);
    43     void RequestResponseL(TFSProgress aEvent, TInt aRequestId);
    46 
    44 
    51     void doRunAsyncOperation();
    49     void doRunAsyncOperation();
    52     void doCompleteOperation();
    50     void doCompleteOperation();
    53     void doCancelOperation();
    51     void doCancelOperation();
    54 
    52 
    55 private:
    53 private:
       
    54     ~NmFwaMessageSendingOperation();
    56     int saveMessageWithSubparts();
    55     int saveMessageWithSubparts();
    57     int sendMessageL();
    56     int sendMessageL();
    58 
    57 
    59 private:
    58 private:
    60     NmDataPluginInterface &mPluginInterface;
    59     NmDataPluginInterface &mPluginInterface;
    61     NmOperation *mSaveOperation;    // Owned
    60     QPointer<NmOperation> mSaveOperation;    // Not owned
    62     NmMessage *mMessage;            // Owned
    61     NmMessage *mMessage;                     // Owned
    63     CFSMailClient &mMailClient;
    62     CFSMailClient &mMailClient;
    64     TInt mRequestId;
    63     TInt mRequestId;
    65     bool mSaved;
    64     bool mSaved;
    66 };
    65 };
    67 
    66