00001
00002
00003
00004
00005
00006
00007
00008 #ifndef UNIFILT_H
00009 #define UNIFILT_H
00010
00011 #include "unicode/unifunct.h"
00012 #include "unicode/unimatch.h"
00013
00014 U_NAMESPACE_BEGIN
00015
00041 class U_I18N_API UnicodeFilter : public UnicodeFunctor, public UnicodeMatcher {
00042
00043 public:
00048 virtual ~UnicodeFilter();
00049
00057 virtual UBool contains(UChar32 c) const = 0;
00058
00063 virtual UnicodeMatcher* toMatcher() const;
00064
00068 UnicodeString& toPattern(UnicodeString& result,
00069 UBool escapeUnprintable) const;
00070
00074 UBool matchesIndexValue(uint8_t v) const;
00075
00079 virtual UMatchDegree matches(const Replaceable& text,
00080 int32_t& offset,
00081 int32_t limit,
00082 UBool incremental);
00083
00087 virtual void setData(const TransliterationRuleData*) {}
00088
00089 protected:
00090
00091 UnicodeFilter();
00092 };
00093
00094 inline UnicodeFilter::UnicodeFilter() {}
00095 inline UnicodeFilter::~UnicodeFilter() {}
00096
00097 U_NAMESPACE_END
00098
00099 #endif