1 // Copyright (c) 1998-2009 Nokia Corporation and/or its subsidiary(-ies).
2 // All rights reserved.
3 // This component and the accompanying materials are made available
4 // under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
5 // which accompanies this distribution, and is available
6 // at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
14 // Client MTM utilities for POP3, SMTP and IMAP4 protocols
18 #if !defined (__IMCMUTIL_H__)
19 #define __IMCMUTIL_H__
21 #if !defined (__MSVFTEXT_H__)
25 #if !defined (__MIUTHDR_H__)
29 #if !defined (__MIUTDEF_H__)
33 _LIT(KMsvAutoSendExe, "Autosend.exe");
34 const TUid KMsvAutoSendExeUid = {0x1000A402}; //268477442
36 class CClientMtmRegistry;
37 class CImClientMTMUtils : public CBase
39 Utilities for use by email client MTMs for searching a message.
45 IMPORT_C static CImClientMTMUtils* NewL();
46 IMPORT_C ~CImClientMTMUtils();
48 IMPORT_C void FindL(const TDesC& aTextToFind, CRichText& aRichText, CImHeader& aHeader, TMsvPartList aPartList, TMsvPartList& rReturnList);
49 IMPORT_C TMsvPartList FindInHeaderL(const TDesC& aTextToFind, CImHeader& aHeader, TMsvPartList aPartList);
50 IMPORT_C TMsvPartList FindInBodyL(const TDesC& aTextToFind, CRichText& aRichText, TMsvPartList aPartList);
53 TBool FindInMessagePartRecipientL(const TDesC& aTextToFind,TMsvPartList aPartList,CDesCArray& aRecipients);
56 CMsvFindText* iFindText;
59 class CImEmailAutoSend : public CActive
66 static CImEmailAutoSend* NewL(CMsvSession& aSession,TMsvId aServiceId);
67 static CImEmailAutoSend* NewLC(CMsvSession& aSession,TMsvId aServiceId);
69 void SendOnNextConnectionL();
71 void ChangeService(TMsvId aServiceId);
73 CImEmailAutoSend(CMsvSession& aSession,TMsvId aServiceId);
77 void LoadSMTPClientMtmL();
80 CMsvSession& iSession;
81 CClientMtmRegistry* iClientRegistry;
83 CMsvOperation* iOperation;
84 CMsvEntrySelection* iSelection;