email/testutils/inc/T_UtilsReadEmailSettingsFromConfigFile.h
branchSymbian2
changeset 1 8758140453c0
child 6 c108117318cb
equal deleted inserted replaced
0:e8c1ea2c6496 1:8758140453c0
       
     1 /**
       
     2 * Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of the License "Symbian Foundation License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.symbianfoundation.org/legal/sfl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:
       
    15 * This is the header file for CT_MsgUtilsReadEmailSettingsFromConfigFile
       
    16 * 
       
    17 *
       
    18 */
       
    19 
       
    20 
       
    21 
       
    22 
       
    23 
       
    24 /**
       
    25  @file
       
    26 */
       
    27 
       
    28  
       
    29 #ifndef __T_READ_EMAIL_SETTINGS_FROM_CONFIG_FILE_H__
       
    30 #define __T_READ_EMAIL_SETTINGS_FROM_CONFIG_FILE_H__
       
    31 
       
    32 _LIT(KNone, "NONE");
       
    33 
       
    34 // Forward declarations
       
    35 class CImIAPPreferences;
       
    36 class CImImap4Settings;
       
    37 class CImPop3Settings;
       
    38 class CImSmtpSettings;
       
    39 class CT_MsgUtilsConfigFileParserUtility;
       
    40 class TImapAccount;
       
    41 
       
    42 
       
    43 /**
       
    44 CT_MsgUtilsReadEmailSettingsFromConfigFile is the utility class used to read the
       
    45 fields from the configuration/setting file and and update the set the data members of 
       
    46 CImImap4Settings, CImPop3Settings, CImSmtpSettings and CImIAPPreferences objects.
       
    47 */
       
    48 class CT_MsgUtilsReadEmailSettingsFromConfigFile
       
    49 	{
       
    50 public:	
       
    51 	CT_MsgUtilsReadEmailSettingsFromConfigFile() {};
       
    52 	
       
    53 	~CT_MsgUtilsReadEmailSettingsFromConfigFile() {};
       
    54 	
       
    55 	IMPORT_C static TBool CompareIapPrefs(CImIAPPreferences& prefs1, CImIAPPreferences& prefs2);
       
    56 	
       
    57 	IMPORT_C static void ReadImapSettingsFromConfigurationFileL(TDesC& aSettingsFile,
       
    58 							CImImap4Settings& aImapSet, CImIAPPreferences& aImapIapPref, const TDesC& aPtrEmailAdd = KNone());
       
    59 										
       
    60 	IMPORT_C static void ReadPopSettingsFromConfigurationFileL(TDesC& aSettingsFile,
       
    61 							CImPop3Settings& aPopSet, CImIAPPreferences& aPopIapPref, const TDesC& aPtrEmailAdd = KNone());
       
    62 										
       
    63 	IMPORT_C static void ReadSmtpSettingsFromConfigurationFileL(TDesC& aSettingsFile,
       
    64 							CImSmtpSettings& aSmtpSet, CImIAPPreferences& aSmtpIapPref,const TDesC& aPtrEmailAdd = KNone());
       
    65 	
       
    66 private:
       
    67 	IMPORT_C static void ReadImapIAPAndAddL(CT_MsgUtilsConfigFileParserUtility* aScriptFileParser,
       
    68 			const TDesC& aParamListName, CImIAPPreferences& aIapPref);
       
    69 			
       
    70 	IMPORT_C static void ReadImapIAPAndAddFieldL(CT_MsgUtilsConfigFileParserUtility* aScriptFileParser, 
       
    71 			const TDesC& aFieldName, CImIAPPreferences& aIapPref);
       
    72 	
       
    73 	IMPORT_C static void ReadPopIAPAndAddL(CT_MsgUtilsConfigFileParserUtility* aScriptFileParser,
       
    74 			const TDesC& aParamListName, CImIAPPreferences& aIapPref);
       
    75 			
       
    76 	IMPORT_C static void ReadPopIAPAndAddFieldL(CT_MsgUtilsConfigFileParserUtility* aScriptFileParser, 
       
    77 			const TDesC& aFieldName, CImIAPPreferences& aIapPref);
       
    78 			
       
    79 	IMPORT_C static void ReadSmtpIAPAndAddL(CT_MsgUtilsConfigFileParserUtility* aScriptFileParser, 
       
    80 			const TDesC& aParamListName, CImIAPPreferences& aSmtpIapPref);
       
    81 			
       
    82 	IMPORT_C static void ReadSmtpIAPAndAddFieldL(CT_MsgUtilsConfigFileParserUtility* aScriptFileParser, 
       
    83 			const TDesC& aFieldName, CImIAPPreferences& aIapPref);
       
    84 			
       
    85 	IMPORT_C static TBool GetString(TDesC& aStringPtr, TInt& aStart, TInt aEnd, TPtrC& aBaseString);
       
    86 	};
       
    87 #endif //__T_READ_EMAIL_SETTINGS_FROM_CONFIG_FILE_H__