intl/icu/source/i18n/uni2name.h

Wed, 31 Dec 2014 07:22:50 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 07:22:50 +0100
branch
TOR_BUG_3246
changeset 4
fc2d59ddac77
permissions
-rw-r--r--

Correct previous dual key logic pending first delivery installment.

     1 /*
     2 **********************************************************************
     3 *   Copyright (C) 2001-2007, International Business Machines
     4 *   Corporation and others.  All Rights Reserved.
     5 **********************************************************************
     6 *   Date        Name        Description
     7 *   06/06/01    aliu        Creation.
     8 **********************************************************************
     9 */
    10 #ifndef UNI2NAME_H
    11 #define UNI2NAME_H
    13 #include "unicode/utypes.h"
    15 #if !UCONFIG_NO_TRANSLITERATION
    17 #include "unicode/translit.h"
    19 U_NAMESPACE_BEGIN
    21 /**
    22  * A transliterator that performs character to name mapping.
    23  * It generates the Perl syntax \N{name}.
    24  * @author Alan Liu
    25  */
    26 class UnicodeNameTransliterator : public Transliterator {
    28  public:
    30     /**
    31      * Constructs a transliterator.
    32      * @param adoptedFilter the filter to be adopted.
    33      */
    34     UnicodeNameTransliterator(UnicodeFilter* adoptedFilter = 0);
    36     /**
    37      * Destructor.
    38      */
    39     virtual ~UnicodeNameTransliterator();
    41     /**
    42      * Copy constructor.
    43      */
    44     UnicodeNameTransliterator(const UnicodeNameTransliterator&);
    46     /**
    47      * Transliterator API.
    48      */
    49     virtual Transliterator* clone(void) const;
    51     /**
    52      * ICU "poor man's RTTI", returns a UClassID for the actual class.
    53      */
    54     virtual UClassID getDynamicClassID() const;
    56     /**
    57      * ICU "poor man's RTTI", returns a UClassID for this class.
    58      */
    59     U_I18N_API static UClassID U_EXPORT2 getStaticClassID();
    61  protected:
    63     /**
    64      * Implements {@link Transliterator#handleTransliterate}.
    65      * @param text        the buffer holding transliterated and
    66      *                    untransliterated text
    67      * @param offset      the start and limit of the text, the position
    68      *                    of the cursor, and the start and limit of transliteration.
    69      * @param incremental if true, assume more text may be coming after
    70      *                    pos.contextLimit.  Otherwise, assume the text is complete.
    71      */
    72     virtual void handleTransliterate(Replaceable& text, UTransPosition& offset,
    73                                      UBool isIncremental) const;
    75 private:
    76     /**
    77      * Assignment operator.
    78      */
    79     UnicodeNameTransliterator& operator=(const UnicodeNameTransliterator&);
    81 };
    83 U_NAMESPACE_END
    85 #endif /* #if !UCONFIG_NO_TRANSLITERATION */
    87 #endif

mercurial