messagingfw/msgsrvnstore/server/inc/msvinifile.h
changeset 0 8e480a14352b
equal deleted inserted replaced
-1:000000000000 0:8e480a14352b
       
     1 // Copyright (c) 2007-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 #if !defined(__CMSVINIDATA_H__)
       
    17 #define __CMSVINIDATA_H__
       
    18 
       
    19 #include <e32base.h>
       
    20 
       
    21 
       
    22 
       
    23 
       
    24 /**
       
    25  *Defines the interface to acess to ini data file
       
    26  *
       
    27  *@internalAll Component
       
    28  *@released
       
    29  */
       
    30 
       
    31 NONSHARABLE_CLASS (CMsvIniData): public CBase 
       
    32 	{
       
    33 public:
       
    34 	// Constructor, pass in name of ini file to open
       
    35 	// Default search path is 'c:\system\data' on target filesystem
       
    36 	// ie. 'NewL(_L("c:\\system\\data\\ttools.ini"))' is equivalent
       
    37 	// to 'NewL(_L("ttools.ini"))'
       
    38 	static CMsvIniData* NewL(const TDesC& aName);
       
    39 	virtual ~CMsvIniData();
       
    40 
       
    41 	TBool FindVar(const TDesC& aKeyName, TPtrC& aResult);
       
    42 
       
    43 	TBool FindVar(const TDesC& aKeyName, TInt& aResult);
       
    44 
       
    45 	TBool FindVar(const TDesC& aSection, const TDesC& aKeyName,	TPtrC& aResult);
       
    46 
       
    47 	TBool FindVar(const TDesC& aSection, const TDesC& aKeyName,	TInt& aResult);	
       
    48 
       
    49 protected:
       
    50 	CMsvIniData();
       
    51 	void ConstructL(const TDesC& aName);
       
    52 
       
    53 private:
       
    54 	HBufC* iName;
       
    55 	HBufC* iToken;
       
    56 	TPtr iPtr;
       
    57 private:
       
    58 #ifdef SYMBIAN_MESSAGESTORE_UNIT_TESTCODE
       
    59 	friend class CTestIniData; //only for testing
       
    60 #endif
       
    61 	};
       
    62 
       
    63 #endif
       
    64