charconvfw/charconv_fw/src/charconv/charconv_tls.h
changeset 0 1fb32624e06b
equal deleted inserted replaced
-1:000000000000 0:1fb32624e06b
       
     1 /*
       
     2 * Copyright (c) 1997-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 "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description: 
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #if !defined(__CHARCONV_TLS_H__)
       
    20 #define __CHARCONV_TLS_H__
       
    21 
       
    22 #if !defined(__E32STD_H__)
       
    23 #include <e32std.h>
       
    24 #endif
       
    25 
       
    26 #if !defined(__E32BASE_H__)
       
    27 #include <e32base.h>
       
    28 #endif
       
    29 
       
    30 
       
    31 /** 
       
    32 Thread local storage used by CCnvCharacterSetConverter
       
    33 
       
    34 @internalTechnology
       
    35 
       
    36 */
       
    37 class TTlsData
       
    38 	{
       
    39 public:
       
    40 	static void CharacterSetConverterIsBeingCreatedL();
       
    41 	static void CharacterSetConverterIsBeingDestroyed();
       
    42 	static void SetCurrentCharacterSetConverter(const CCnvCharacterSetConverter* aCharacterSetConverter);
       
    43 	IMPORT_C static const CCnvCharacterSetConverter* CurrentCharacterSetConverter();
       
    44 public:
       
    45 	inline TTlsData() :iReferenceCount(1), iCurrentCharacterSetConverter(NULL) {}
       
    46 private:
       
    47 	TInt iReferenceCount;
       
    48 	const CCnvCharacterSetConverter* iCurrentCharacterSetConverter;
       
    49 	};
       
    50 	
       
    51 
       
    52 #endif
       
    53