00001 /* 00002 * Copyright (C) 1999, International Business Machines Corporation and others. All Rights Reserved. 00003 ********************************************************************** 00004 * Date Name Description 00005 * 11/17/99 aliu Creation. 00006 ********************************************************************** 00007 */ 00008 #ifndef UNIFILT_H 00009 #define UNIFILT_H 00010 00011 #include "unicode/unimatch.h" 00012 00013 U_NAMESPACE_BEGIN 00014 00040 class U_I18N_API UnicodeFilter : public UnicodeMatcher { 00041 00042 public: 00047 virtual ~UnicodeFilter(); 00048 00056 virtual UBool contains(UChar32 c) const = 0; 00057 00061 UnicodeString& toPattern(UnicodeString& result, 00062 UBool escapeUnprintable) const; 00063 00067 UBool matchesIndexValue(uint8_t v) const; 00068 00072 virtual UMatchDegree matches(const Replaceable& text, 00073 int32_t& offset, 00074 int32_t limit, 00075 UBool incremental); 00076 00077 protected: 00078 00079 UnicodeFilter(); 00080 }; 00081 00082 inline UnicodeFilter::UnicodeFilter() {} 00083 inline UnicodeFilter::~UnicodeFilter() {} 00084 00085 U_NAMESPACE_END 00086 00087 #endif