]> git.saurik.com Git - apple/icu.git/blame - icuSources/i18n/remtrans.h
ICU-6.2.15.tar.gz
[apple/icu.git] / icuSources / i18n / remtrans.h
CommitLineData
b75a7d8f
A
1/*
2**********************************************************************
374ca955 3* Copyright (c) 2001-2004, International Business Machines
b75a7d8f
A
4* Corporation and others. All Rights Reserved.
5**********************************************************************
6* Date Name Description
7* 04/02/2001 aliu Creation.
8**********************************************************************
9*/
10#ifndef REMTRANS_H
11#define REMTRANS_H
12
13#include "unicode/utypes.h"
14
15#if !UCONFIG_NO_TRANSLITERATION
16
17#include "unicode/translit.h"
18
19U_NAMESPACE_BEGIN
20
21/**
22 * A transliterator that removes text.
23 * @author Alan Liu
24 */
25class U_I18N_API RemoveTransliterator : public Transliterator {
26
27public:
28
29 /**
30 * Constructs a transliterator.
31 */
32 RemoveTransliterator();
33
34 /**
35 * Destructor.
36 */
37 virtual ~RemoveTransliterator();
38
39 /**
40 * System registration hook.
41 */
42 static void registerIDs();
43
44 /**
45 * Transliterator API.
46 * @return A copy of the object.
47 */
374ca955 48 virtual Transliterator* clone(void) const;
b75a7d8f
A
49
50 /**
51 * Implements {@link Transliterator#handleTransliterate}.
52 * @param text the buffer holding transliterated and
53 * untransliterated text
54 * @param offset the start and limit of the text, the position
55 * of the cursor, and the start and limit of transliteration.
56 * @param incremental if true, assume more text may be coming after
57 * pos.contextLimit. Otherwise, assume the text is complete.
58 */
59 virtual void handleTransliterate(Replaceable& text, UTransPosition& offset,
60 UBool isIncremental) const;
61
62 /**
63 * ICU "poor man's RTTI", returns a UClassID for the actual class.
64 *
65 * @draft ICU 2.2
66 */
374ca955 67 virtual UClassID getDynamicClassID() const;
b75a7d8f
A
68
69 /**
70 * ICU "poor man's RTTI", returns a UClassID for this class.
71 *
72 * @draft ICU 2.2
73 */
374ca955 74 static UClassID U_EXPORT2 getStaticClassID();
b75a7d8f
A
75
76 private:
77
78 /**
79 * Factory method
80 */
81 static Transliterator* _create(const UnicodeString& ID, Token context);
b75a7d8f
A
82};
83
84U_NAMESPACE_END
85
86#endif /* #if !UCONFIG_NO_TRANSLITERATION */
87
88#endif