📄 mtmsexampleengine.h
字号:
#ifndef MTMSEXAMPLEENGINE_H_
#define MTMSEXAMPLEENGINE_H_
#include <e32base.h> // CBase
#include <msvapi.h> // MMsvSessionObserver
// FORWARD DECLARATIONS
class CClientMtmRegistry;
class CMtmsExampleDialog;
class CSmsClientMtm;
class CMmsClientMtm;
// CLASS DECLARATION
class MMtmsExampleEngineObserver
{
public:
virtual void HandleMessageSentL(TInt aError) = 0;
};
class CMtmsExampleEngine : public CActive, public MMsvSessionObserver
{
public:
static CMtmsExampleEngine* NewL(MMtmsExampleEngineObserver& aObserver);
~CMtmsExampleEngine();
public:
inline TBool IsReady() const;
// SMS
void CreateDraftSMSL(const TDesC& aAddress);
TBool ValidateSMS();
void SendSMSL();
// MMS
void CreateDraftMMSL(const TDesC& aAddress);
TBool ValidateMMS();
void SendMMSL();
private:
CMtmsExampleEngine(MMtmsExampleEngineObserver& aObserver);
void ConstructL();
void CompleteConstructL();
void AddMMSAttachmentsL();
private: // from CActive
virtual void DoCancel();
virtual void RunL();
private: // from MMsvSessionObserver
void HandleSessionEventL(TMsvSessionEvent aEvent, TAny* aArg1, TAny* aArg2, TAny* aArg3);
private:
MMtmsExampleEngineObserver& iObserver;
CMsvOperation* iOp;
CMsvEntrySelection* iEntrySelection;
CMsvSession* iSession; // Session to the messaging server
CClientMtmRegistry* iMtmReg;
CSmsClientMtm* iSmsMtm;
CMmsClientMtm* iMmsMtm;
TBool iReady;
TMsvId iSmsId;
TMsvId iMmsId;
};
inline TBool CMtmsExampleEngine::IsReady() const
{
return iReady;
}
#endif /*MTMSEXAMPLEENGINE_H_*/
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -