email/imap4mtm/imapsession/inc/cimaprfc822headerfields.h
changeset 0 72b543305e3a
equal deleted inserted replaced
-1:000000000000 0:72b543305e3a
       
     1 // Copyright (c) 2006-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 "Eclipse Public License v1.0"
       
     5 // which accompanies this distribution, and is available
       
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 //
       
    15 
       
    16 #ifndef __CIMAPRFC822HEADERFIELDS_H__
       
    17 #define __CIMAPRFC822HEADERFIELDS_H__
       
    18 
       
    19 #include <msvstd.h>
       
    20 #include "cimapheaderfields.h"
       
    21 
       
    22 /**
       
    23 Stores the RFC822 header information that is returned by a BODY[HEADER.FIELDS(...)] request.
       
    24 The data is stored as a simple array of heap descriptors, one for each field type.
       
    25 @internalTechnology
       
    26 @prototype
       
    27 */
       
    28 NONSHARABLE_CLASS(CImapRfc822HeaderFields) : public CImapHeaderFields
       
    29 	{
       
    30 public:
       
    31 	/**
       
    32 	Provides an index into the field value array
       
    33 	*/
       
    34 	enum THeaderFields
       
    35 		{
       
    36 		EImapFrom,
       
    37 		EImapReplyTo,
       
    38 		EImapTo,
       
    39 		EImapCc,
       
    40 		EImapBcc,
       
    41 		EImapSubject,
       
    42 		EImapDate,
       
    43 		EImapReceived,
       
    44 		EImapMessageId,
       
    45 		EImapXMailer,
       
    46 		EImapPriority,
       
    47 		EImapXPriority,
       
    48 		EImapXMSMailPriority,
       
    49 		EImapPrecedence,
       
    50 		EImapImportance,
       
    51 		EImapReturnReceiptTo,
       
    52 		EImapXReturnReceiptTo,
       
    53 		EImapDispositionNotificationTo,
       
    54 		EImapDispositionNotificationOptions,
       
    55 
       
    56 		EImapCountFields
       
    57 		};
       
    58 
       
    59 	static CImapRfc822HeaderFields* NewL();
       
    60 	~CImapRfc822HeaderFields();
       
    61 
       
    62 	IMPORT_C const TDesC8& FieldValue(THeaderFields aFieldId);
       
    63 	IMPORT_C TBool FieldExists(THeaderFields aFieldId);
       
    64 	IMPORT_C TMsvPriority PriorityL();
       
    65 	IMPORT_C TTime Date();
       
    66 	IMPORT_C const TDesC8& ReturnReceiptField();
       
    67 
       
    68 private:
       
    69 	CImapRfc822HeaderFields();
       
    70 	void ConstructL();
       
    71 	TInt Match(const TDesC8& aFieldName, TBool& aNeedToStripSpaces);
       
    72 	};
       
    73 
       
    74 #endif // __CIMAPRFC822HEADERFIELDS_H__