sl@0: /* sl@0: * Copyright (c) 2003 Nokia Corporation and/or its subsidiary(-ies). sl@0: * All rights reserved. sl@0: * This component and the accompanying materials are made available sl@0: * under the terms of "Eclipse Public License v1.0" sl@0: * which accompanies this distribution, and is available sl@0: * at the URL "http://www.eclipse.org/legal/epl-v10.html". sl@0: * sl@0: * Initial Contributors: sl@0: * Nokia Corporation - initial contribution. sl@0: * sl@0: * Contributors: sl@0: * sl@0: * Description: (Thai) sl@0: * sl@0: */ sl@0: sl@0: sl@0: sl@0: sl@0: sl@0: // INCLUDES sl@0: #include sl@0: #include sl@0: #include sl@0: #include sl@0: #include sl@0: // New Interface class sl@0: class CWin874Implementation : public CCharacterSetConverterPluginInterface sl@0: { sl@0: public: sl@0: virtual const TDesC8& ReplacementForUnconvertibleUnicodeCharacters(); sl@0: sl@0: virtual TInt ConvertFromUnicode( sl@0: CCnvCharacterSetConverter::TEndianness aDefaultEndiannessOfForeignCharacters, sl@0: const TDesC8& aReplacementForUnconvertibleUnicodeCharacters, sl@0: TDes8& aForeign, sl@0: const TDesC16& aUnicode, sl@0: CCnvCharacterSetConverter::TArrayOfAscendingIndices& aIndicesOfUnconvertibleCharacters ); sl@0: sl@0: virtual TInt ConvertToUnicode( sl@0: CCnvCharacterSetConverter::TEndianness aDefaultEndiannessOfForeignCharacters, sl@0: TDes16& aUnicode, sl@0: const TDesC8& aForeign, sl@0: TInt&, sl@0: TInt& aNumberOfUnconvertibleCharacters, sl@0: TInt& aIndexOfFirstByteOfFirstUnconvertibleCharacter ); sl@0: sl@0: virtual TBool IsInThisCharacterSetL( sl@0: TBool& aSetToTrue, sl@0: TInt& aConfidenceLevel, sl@0: const TDesC8& ); sl@0: sl@0: static CWin874Implementation* NewL(); sl@0: sl@0: virtual ~CWin874Implementation(); sl@0: private: sl@0: CWin874Implementation(); sl@0: }; sl@0: sl@0: const TDesC8& CWin874Implementation::ReplacementForUnconvertibleUnicodeCharacters() sl@0: { sl@0: return ReplacementForUnconvertibleUnicodeCharacters_internal(); sl@0: } sl@0: sl@0: TInt CWin874Implementation::ConvertFromUnicode( sl@0: CCnvCharacterSetConverter::TEndianness aDefaultEndiannessOfForeignCharacters, sl@0: const TDesC8& aReplacementForUnconvertibleUnicodeCharacters, sl@0: TDes8& aForeign, sl@0: const TDesC16& aUnicode, sl@0: CCnvCharacterSetConverter::TArrayOfAscendingIndices& aIndicesOfUnconvertibleCharacters ) sl@0: { sl@0: return CCnvCharacterSetConverter::DoConvertFromUnicode( sl@0: conversionData, sl@0: aDefaultEndiannessOfForeignCharacters, sl@0: aReplacementForUnconvertibleUnicodeCharacters, sl@0: aForeign, sl@0: aUnicode, sl@0: aIndicesOfUnconvertibleCharacters ); sl@0: } sl@0: sl@0: TInt CWin874Implementation::ConvertToUnicode( sl@0: CCnvCharacterSetConverter::TEndianness aDefaultEndiannessOfForeignCharacters, sl@0: TDes16& aUnicode, sl@0: const TDesC8& aForeign, sl@0: TInt&, sl@0: TInt& aNumberOfUnconvertibleCharacters, sl@0: TInt& aIndexOfFirstByteOfFirstUnconvertibleCharacter ) sl@0: { sl@0: return CCnvCharacterSetConverter::DoConvertToUnicode( sl@0: conversionData, sl@0: aDefaultEndiannessOfForeignCharacters, sl@0: aUnicode, sl@0: aForeign, sl@0: aNumberOfUnconvertibleCharacters, sl@0: aIndexOfFirstByteOfFirstUnconvertibleCharacter ); sl@0: } sl@0: sl@0: sl@0: TBool CWin874Implementation::IsInThisCharacterSetL( sl@0: TBool& aSetToTrue, sl@0: TInt& aConfidenceLevel, sl@0: const TDesC8& ) sl@0: { sl@0: aSetToTrue=EFalse; sl@0: aConfidenceLevel=0; sl@0: return EFalse; sl@0: } sl@0: sl@0: CWin874Implementation* CWin874Implementation::NewL() sl@0: { sl@0: CWin874Implementation* self = new(ELeave) CWin874Implementation; sl@0: return self; sl@0: } sl@0: sl@0: CWin874Implementation::CWin874Implementation() sl@0: { sl@0: //default constructor.. do nothing sl@0: } sl@0: sl@0: CWin874Implementation::~CWin874Implementation() sl@0: { sl@0: //default destructor .. do nothing sl@0: } sl@0: sl@0: // ECOM CREATION FUNCTION sl@0: const TImplementationProxy ImplementationTable[] = sl@0: { sl@0: // Note: This is the same UID as defined in old mmp-file sl@0: // Used also in 12221212.rss ( implementation_uid ) sl@0: IMPLEMENTATION_PROXY_ENTRY( 0x101F854A, CWin874Implementation::NewL ) sl@0: }; sl@0: sl@0: EXPORT_C const TImplementationProxy* ImplementationGroupProxy( TInt& aTableCount ) sl@0: { sl@0: aTableCount = sizeof( ImplementationTable ) / sizeof(TImplementationProxy); sl@0: return ImplementationTable; sl@0: } sl@0: