Go to the documentation of this file.
21 #if U_SHOW_CPLUSPLUS_API
28 #if !UCONFIG_NO_BREAK_ITERATION
38 class LanguageBreakEngine;
39 struct RBBIDataHeader;
40 class RBBIDataWrapper;
41 class UnhandledEngine;
64 #ifndef U_HIDE_INTERNAL_API
84 int32_t fRuleStatusIndex;
90 BreakCache *fBreakCache;
96 class DictionaryCache;
97 DictionaryCache *fDictionaryCache;
106 UStack *fLanguageBreakEngines;
115 UnhandledEngine *fUnhandledBreakEngine;
122 uint32_t fDictionaryCharCount;
160 friend class RBBIRuleBuilder;
402 virtual int32_t
next(int32_t n);
541 #ifndef U_FORCE_HIDE_DEPRECATED_API
571 #endif // U_FORCE_HIDE_DEPRECATED_API
646 int32_t handleSafePrevious(int32_t fromPosition);
660 int32_t handleNext();
669 const LanguageBreakEngine *getLanguageBreakEngine(
UChar32 c);
672 #ifndef U_HIDE_INTERNAL_API
virtual void adoptText(CharacterIterator *newText)
Set the iterator to analyze a new piece of text.
The BreakIterator class implements methods for finding the location of boundaries in text.
C API: Parse Error Information.
Basic definitions for ICU, for both C and C++ APIs.
int8_t UBool
The ICU boolean type.
virtual int32_t preceding(int32_t offset)
Sets the iterator to refer to the last boundary position before the specified position.
RBBIDataWrapper * fData
The rule data for this BreakIterator instance.
virtual RuleBasedBreakIterator * clone() const
Returns a newly-constructed RuleBasedBreakIterator with the same behavior, and iterating over the sam...
void dumpCache()
Debugging function only.
RuleBasedBreakIterator()
Default constructor.
RuleBasedBreakIterator(UDataMemory *image, UErrorCode &status)
This constructor uses the udata interface to create a BreakIterator whose internal tables live in a m...
U_EXPORT UBool operator==(const StringPiece &x, const StringPiece &y)
Global operator == for StringPiece.
RuleBasedBreakIterator(const UnicodeString &rules, UParseError &parseError, UErrorCode &status)
Construct a RuleBasedBreakIterator from a set of rules supplied as a string.
#define U_COMMON_API
Set to export library symbols from inside the common library, and to import them from outside.
virtual RuleBasedBreakIterator * createBufferClone(void *stackBuffer, int32_t &BufferSize, UErrorCode &status)
Deprecated functionality.
RuleBasedBreakIterator & operator=(const RuleBasedBreakIterator &that)
Assignment operator.
virtual ~RuleBasedBreakIterator()
Destructor.
A UParseError struct is used to returned detailed information about parsing errors.
RuleBasedBreakIterator(const uint8_t *compiledRules, uint32_t ruleLength, UErrorCode &status)
Construct a RuleBasedBreakIterator from a set of precompiled binary rules.
virtual int32_t getRuleStatus() const
Return the status tag from the break rule that determined the boundary at the current iteration posit...
UnicodeString is a string class that stores Unicode characters directly and provides similar function...
C++ API: String Character Iterator.
virtual UBool isBoundary(int32_t offset)
Returns true if the specified position is a boundary position.
virtual int32_t following(int32_t offset)
Sets the iterator to refer to the first boundary position following the specified position.
A concrete subclass of CharacterIterator that iterates over the characters (code units or code points...
int32_t UChar32
Define UChar32 as a type for single Unicode code points.
void * UClassID
UClassID is used to identify classes without using the compiler's RTTI.
UErrorCode
Standard ICU4C error code type, a substitute for exceptions.
virtual int32_t next(int32_t n)
Advances the iterator either forward or backward the specified number of steps.
A subclass of BreakIterator whose behavior is specified using a list of rules.
C API: Data loading interface.
UBool operator!=(const StringPiece &x, const StringPiece &y)
Global operator != for StringPiece.
UBool operator!=(const BreakIterator &rhs) const
Returns the complement of the result of operator==.
static UClassID getStaticClassID(void)
Returns the class ID for this class.
RuleBasedBreakIterator(const RuleBasedBreakIterator &that)
Copy constructor.
virtual int32_t current(void) const
Returns the current iteration position.
struct UDataMemory UDataMemory
Forward declaration of the data memory type.
virtual RuleBasedBreakIterator & refreshInputText(UText *input, UErrorCode &status)
Set the subject text string upon which the break iterator is operating without changing any other asp...
Abstract class that defines an API for iteration on text objects.
virtual void setText(UText *text, UErrorCode &status)
Reset the break iterator to operate over the text represented by the UText.
virtual int32_t next(void)
Advances the iterator to the next boundary position.
void dumpTables()
Debugging function only.
virtual int32_t getRuleStatusVec(int32_t *fillInVec, int32_t capacity, UErrorCode &status)
Get the status (tag) values from the break rule(s) that determined the boundary at the current iterat...
virtual CharacterIterator & getText(void) const
virtual UClassID getDynamicClassID(void) const
Returns a unique class ID POLYMORPHICALLY.
virtual int32_t hashCode(void) const
Compute a hash code for this BreakIterator.
virtual int32_t last(void)
Sets the current iteration position to the end of the text.
virtual UText * getUText(UText *fillIn, UErrorCode &status) const
Get a UText for the text being analyzed.
virtual void setText(const UnicodeString &newText)
Set the iterator to analyze a new piece of text.
virtual const UnicodeString & getRules(void) const
Returns the description used to create this iterator.
virtual int32_t previous(void)
Moves the iterator backwards, to the last boundary preceding this one.
virtual int32_t first(void)
Sets the current iteration position to the beginning of the text, position zero.
virtual const uint8_t * getBinaryRules(uint32_t &length)
Return the binary form of compiled break rules, which can then be used to create a new break iterator...
virtual UBool operator==(const BreakIterator &that) const
Equality operator.