Main Page   Class Hierarchy   Alphabetical List   Data Structures   File List   Data Fields   Globals  

CompoundTransliterator Class Reference

A transliterator that is composed of two or more other transliterator objects linked together. More...

#include <cpdtrans.h>

Inheritance diagram for CompoundTransliterator:

Transliterator

Public Methods

 CompoundTransliterator (Transliterator *const transliterators[], int32_t transliteratorCount, UnicodeFilter *adoptedFilter=0)
 Constructs a new compound transliterator given an array of transliterators. More...

 CompoundTransliterator (const UnicodeString &id, UTransDirection dir, UnicodeFilter *adoptedFilter, UParseError &parseError, UErrorCode &status)
 Constructs a new compound transliterator. More...

 CompoundTransliterator (const UnicodeString &id, UParseError &parseError, UErrorCode &status)
 Constructs a new compound transliterator in the FORWARD direction with a NULL filter. More...

virtual ~CompoundTransliterator ()
 Destructor. More...

 CompoundTransliterator (const CompoundTransliterator &)
 Copy constructor. More...

CompoundTransliterator & operator= (const CompoundTransliterator &)
 Assignment operator. More...

Transliteratorclone (void) const
 Transliterator API. More...

virtual int32_t getCount (void) const
 Returns the number of transliterators in this chain. More...

virtual const TransliteratorgetTransliterator (int32_t index) const
 Returns the transliterator at the given index in this chain. More...

void setTransliterators (Transliterator *const transliterators[], int32_t count)
 Sets the transliterators. More...

void adoptTransliterators (Transliterator *adoptedTransliterators[], int32_t count)
 Adopts the transliterators. More...

virtual UnicodeStringtoRules (UnicodeString &result, UBool escapeUnprintable) const
 Override Transliterator: Create a rule string that can be passed to createFromRules() to recreate this transliterator. More...

virtual void handleTransliterate (Replaceable &text, UTransPosition &index, UBool incremental) const
 Implements Transliterator::handleTransliterate. More...


Friends

class Transliterator
class TransliteratorAlias

Detailed Description

A transliterator that is composed of two or more other transliterator objects linked together.

For example, if one transliterator transliterates from script A to script B, and another transliterates from script B to script C, the two may be combined to form a new transliterator from A to C.

Composed transliterators may not behave as expected. For example, inverses may not combine to form the identity transliterator. See the class documentation for Transliterator for details.

Copyright © IBM Corporation 1999. All rights reserved.

Author:
Alan Liu
Version:
RCSfile:
cpdtrans.h,v
Revision:
1.28
Date:
2002/03/01 21:56:40
Deprecated:
To be removed after 2002-sep-30.


Constructor & Destructor Documentation

CompoundTransliterator::CompoundTransliterator Transliterator *const    transliterators[],
int32_t    transliteratorCount,
UnicodeFilter   adoptedFilter = 0
 

Constructs a new compound transliterator given an array of transliterators.

The array of transliterators may be of any length, including zero or one, however, useful compound transliterators have at least two components.

Parameters:
transliterators  array of Transliterator objects
transliteratorCount  The number of Transliterator objects in transliterators.
filter  the filter. Any character for which filter.contains() returns false will not be altered by this transliterator. If filter is null then no filtering is applied.
Deprecated:
To be removed after 2002-sep-30; use the Transliterator::createInstance factory method.

CompoundTransliterator::CompoundTransliterator const UnicodeString   id,
UTransDirection    dir,
UnicodeFilter   adoptedFilter,
UParseError &    parseError,
UErrorCode   status
 

Constructs a new compound transliterator.

Parameters:
id  compound ID
dir  either UTRANS_FORWARD or UTRANS_REVERSE
adoptedFilter  a global filter for this compound transliterator or NULL
Deprecated:
To be removed after 2002-sep-30; use the Transliterator::createInstance factory method.

CompoundTransliterator::CompoundTransliterator const UnicodeString   id,
UParseError &    parseError,
UErrorCode   status
 

Constructs a new compound transliterator in the FORWARD direction with a NULL filter.

Deprecated:
To be removed after 2002-sep-30; use the Transliterator::createInstance factory method.

virtual CompoundTransliterator::~CompoundTransliterator   [virtual]
 

Destructor.

Deprecated:
To be removed after 2002-sep-30.

CompoundTransliterator::CompoundTransliterator const CompoundTransliterator &   
 

Copy constructor.

Deprecated:
To be removed after 2002-sep-30; use the Transliterator::createInstance factory method.


Member Function Documentation

void CompoundTransliterator::adoptTransliterators Transliterator   adoptedTransliterators[],
int32_t    count
 

Adopts the transliterators.

Deprecated:
To be removed after 2002-sep-30.

Transliterator* CompoundTransliterator::clone void    const [virtual]
 

Transliterator API.

Deprecated:
To be removed after 2002-sep-30.

Reimplemented from Transliterator.

virtual int32_t CompoundTransliterator::getCount void    const [virtual]
 

Returns the number of transliterators in this chain.

Returns:
number of transliterators in this chain.
Deprecated:
To be removed after 2002-sep-30.

virtual const Transliterator& CompoundTransliterator::getTransliterator int32_t    index const [virtual]
 

Returns the transliterator at the given index in this chain.

Parameters:
index  index into chain, from 0 to getCount() - 1
Returns:
transliterator at the given index
Deprecated:
To be removed after 2002-sep-30.

virtual void CompoundTransliterator::handleTransliterate Replaceable   text,
UTransPosition   index,
UBool    incremental
const [virtual]
 

Implements Transliterator::handleTransliterate.

Deprecated:
To be removed after 2002-sep-30.

Implements Transliterator.

CompoundTransliterator& CompoundTransliterator::operator= const CompoundTransliterator &   
 

Assignment operator.

Deprecated:
To be removed after 2002-sep-30.

void CompoundTransliterator::setTransliterators Transliterator *const    transliterators[],
int32_t    count
 

Sets the transliterators.

Deprecated:
To be removed after 2002-sep-30.

virtual UnicodeString& CompoundTransliterator::toRules UnicodeString   result,
UBool    escapeUnprintable
const [virtual]
 

Override Transliterator: Create a rule string that can be passed to createFromRules() to recreate this transliterator.

Parameters:
result  the string to receive the rules. Previous contents will be deleted.
escapeUnprintable  if TRUE then convert unprintable character to their hex escape representations, \uxxxx or \Uxxxxxxxx. Unprintable characters are those other than U+000A, U+0020..U+007E.
Deprecated:
To be removed after 2002-sep-30.

Reimplemented from Transliterator.


The documentation for this class was generated from the following file:
Generated on Mon Mar 4 20:07:57 2002 for ICU 2.0 by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002