os/textandloc/charconvfw/charconvplugins/test/rtest/tsrc/plugins/tis1620.h
author sl
Tue, 10 Jun 2014 14:32:02 +0200
changeset 1 260cb5ec6c19
permissions -rw-r--r--
Update contrib.
sl@0
     1
/*
sl@0
     2
* Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
sl@0
     3
* All rights reserved.
sl@0
     4
* This component and the accompanying materials are made available
sl@0
     5
* under the terms of "Eclipse Public License v1.0"
sl@0
     6
* which accompanies this distribution, and is available
sl@0
     7
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
sl@0
     8
*
sl@0
     9
* Initial Contributors:
sl@0
    10
* Nokia Corporation - initial contribution.
sl@0
    11
*
sl@0
    12
* Contributors:
sl@0
    13
*
sl@0
    14
* Description: 
sl@0
    15
* Two dummy character set converters
sl@0
    16
*
sl@0
    17
*/
sl@0
    18
sl@0
    19
sl@0
    20
#ifndef __TIS1620_H__
sl@0
    21
#define __TIS1620_H__
sl@0
    22
sl@0
    23
#include <e32std.h>
sl@0
    24
#include <charconv.h>
sl@0
    25
#include <charactersetconverter.h>
sl@0
    26
sl@0
    27
const TInt32 KTIS1620aImplUid = 0xA0001344;
sl@0
    28
const TInt32 KTIS1620bImplUid = 0xA0001345;
sl@0
    29
sl@0
    30
// A dummy character set converter plugin for testing having
sl@0
    31
// multiple implementations in a single DLL.
sl@0
    32
class CTIS1620aImplementation : public CCharacterSetConverterPluginInterface
sl@0
    33
{
sl@0
    34
public:
sl@0
    35
	virtual const TDesC8& ReplacementForUnconvertibleUnicodeCharacters();
sl@0
    36
sl@0
    37
	virtual TInt ConvertFromUnicode(
sl@0
    38
		CCnvCharacterSetConverter::TEndianness  aDefaultEndiannessOfForeignCharacters, 
sl@0
    39
		const TDesC8& aReplacementForUnconvertibleUnicodeCharacters, 
sl@0
    40
		TDes8& aForeign, 
sl@0
    41
		const TDesC16& aUnicode, 
sl@0
    42
		CCnvCharacterSetConverter::TArrayOfAscendingIndices& aIndicesOfUnconvertibleCharacters);
sl@0
    43
	
sl@0
    44
	virtual TInt ConvertToUnicode(
sl@0
    45
		CCnvCharacterSetConverter::TEndianness aDefaultEndiannessOfForeignCharacters, 
sl@0
    46
		TDes16& aUnicode, 
sl@0
    47
		const TDesC8& aForeign, 
sl@0
    48
		TInt& aState, 
sl@0
    49
		TInt& aNumberOfUnconvertibleCharacters, 
sl@0
    50
		TInt& aIndexOfFirstByteOfFirstUnconvertibleCharacter);
sl@0
    51
sl@0
    52
	virtual TBool IsInThisCharacterSetL(
sl@0
    53
		TBool& aSetToTrue, 
sl@0
    54
		TInt& aConfidenceLevel, 
sl@0
    55
		const TDesC8& aSample);
sl@0
    56
sl@0
    57
	static CTIS1620aImplementation* NewL();
sl@0
    58
	virtual ~CTIS1620aImplementation();
sl@0
    59
sl@0
    60
private:
sl@0
    61
	CTIS1620aImplementation();
sl@0
    62
sl@0
    63
};
sl@0
    64
sl@0
    65
// Another dummy character set converter plugin for testing having
sl@0
    66
// multiple implementations in one DLL.
sl@0
    67
class CTIS1620bImplementation : public CCharacterSetConverterPluginInterface
sl@0
    68
{
sl@0
    69
public:
sl@0
    70
	virtual const TDesC8& ReplacementForUnconvertibleUnicodeCharacters();
sl@0
    71
sl@0
    72
	virtual TInt ConvertFromUnicode(
sl@0
    73
		CCnvCharacterSetConverter::TEndianness  aDefaultEndiannessOfForeignCharacters, 
sl@0
    74
		const TDesC8& aReplacementForUnconvertibleUnicodeCharacters, 
sl@0
    75
		TDes8& aForeign, 
sl@0
    76
		const TDesC16& aUnicode, 
sl@0
    77
		CCnvCharacterSetConverter::TArrayOfAscendingIndices& aIndicesOfUnconvertibleCharacters);
sl@0
    78
	
sl@0
    79
	virtual TInt ConvertToUnicode(
sl@0
    80
		CCnvCharacterSetConverter::TEndianness aDefaultEndiannessOfForeignCharacters, 
sl@0
    81
		TDes16& aUnicode, 
sl@0
    82
		const TDesC8& aForeign, 
sl@0
    83
		TInt& aState, 
sl@0
    84
		TInt& aNumberOfUnconvertibleCharacters, 
sl@0
    85
		TInt& aIndexOfFirstByteOfFirstUnconvertibleCharacter);
sl@0
    86
sl@0
    87
	virtual TBool IsInThisCharacterSetL(
sl@0
    88
		TBool& aSetToTrue, 
sl@0
    89
		TInt& aConfidenceLevel, 
sl@0
    90
		const TDesC8& aSample);
sl@0
    91
sl@0
    92
	static CTIS1620bImplementation* NewL();
sl@0
    93
	virtual ~CTIS1620bImplementation();
sl@0
    94
sl@0
    95
private:
sl@0
    96
	CTIS1620bImplementation();
sl@0
    97
sl@0
    98
};
sl@0
    99
sl@0
   100
#endif