21#if U_SHOW_CPLUSPLUS_API
28#if !UCONFIG_NO_BREAK_ITERATION
40class LanguageBreakEngine;
66#ifndef U_HIDE_INTERNAL_API
86 int32_t fRuleStatusIndex;
92 BreakCache *fBreakCache;
98 class DictionaryCache;
99 DictionaryCache *fDictionaryCache;
108 UStack *fLanguageBreakEngines;
117 UnhandledEngine *fUnhandledBreakEngine;
124 uint32_t fDictionaryCharCount;
148 int32_t *fLookAheadMatches;
153 UBool fIsPhraseBreaking;
187 friend class RBBIRuleBuilder;
410 virtual int32_t
first(
void)
override;
417 virtual int32_t
last(
void)
override;
429 virtual int32_t
next(int32_t n)
override;
436 virtual int32_t
next(
void)
override;
568#ifndef U_FORCE_HIDE_DEPRECATED_API
666 int32_t handleSafePrevious(int32_t fromPosition);
680 int32_t handleNext();
698 template<
typename RowType, PTrieFunc trieFunc>
699 int32_t handleSafePrevious(int32_t fromPosition);
701 template<
typename RowType, PTrieFunc trieFunc>
702 int32_t handleNext();
711 const LanguageBreakEngine *getLanguageBreakEngine(
UChar32 c);
714#ifndef U_HIDE_INTERNAL_API
The BreakIterator class implements methods for finding the location of boundaries in text.
bool operator!=(const BreakIterator &rhs) const
Returns the complement of the result of operator==.
Abstract class that defines an API for iteration on text objects.
A subclass of BreakIterator whose behavior is specified using a list of rules.
virtual int32_t current(void) const override
Returns the current iteration position.
virtual int32_t following(int32_t offset) override
Sets the iterator to refer to the first boundary position following the specified position.
virtual bool operator==(const BreakIterator &that) const override
Equality operator.
RBBIDataWrapper * fData
The rule data for this BreakIterator instance.
virtual RuleBasedBreakIterator * clone() const override
Returns a newly-constructed RuleBasedBreakIterator with the same behavior, and iterating over the sam...
virtual RuleBasedBreakIterator * createBufferClone(void *stackBuffer, int32_t &BufferSize, UErrorCode &status) override
Deprecated functionality.
void dumpTables()
Debugging function only.
virtual UClassID getDynamicClassID(void) const override
Returns a unique class ID POLYMORPHICALLY.
virtual int32_t last(void) override
Sets the current iteration position to the end of the text.
virtual int32_t getRuleStatus() const override
Return the status tag from the break rule that determined the boundary at the current iteration posit...
virtual UText * getUText(UText *fillIn, UErrorCode &status) const override
Get a UText for the text being analyzed.
virtual UBool isBoundary(int32_t offset) override
Returns true if the specified position is a boundary position.
void dumpCache()
Debugging function only.
virtual RuleBasedBreakIterator & refreshInputText(UText *input, UErrorCode &status) override
Set the subject text string upon which the break iterator is operating without changing any other asp...
RuleBasedBreakIterator()
Default constructor.
virtual int32_t getRuleStatusVec(int32_t *fillInVec, int32_t capacity, UErrorCode &status) override
Get the status (tag) values from the break rule(s) that determined the boundary at the current iterat...
virtual int32_t first(void) override
Sets the current iteration position to the beginning of the text, position zero.
RuleBasedBreakIterator & operator=(const RuleBasedBreakIterator &that)
Assignment operator.
static UClassID getStaticClassID(void)
Returns the class ID for this class.
virtual int32_t preceding(int32_t offset) override
Sets the iterator to refer to the last boundary position before the specified position.
RuleBasedBreakIterator(const RuleBasedBreakIterator &that)
Copy constructor.
virtual CharacterIterator & getText(void) const override
virtual int32_t previous(void) override
Moves the iterator backwards, to the last boundary preceding this one.
virtual void adoptText(CharacterIterator *newText) override
Set the iterator to analyze a new piece of text.
RuleBasedBreakIterator(UDataMemory *image, UErrorCode &status)
This constructor uses the udata interface to create a BreakIterator whose internal tables live in a m...
virtual const UnicodeString & getRules(void) const
Returns the description used to create this iterator.
virtual int32_t next(int32_t n) override
Advances the iterator either forward or backward the specified number of steps.
virtual void setText(UText *text, UErrorCode &status) override
Reset the break iterator to operate over the text represented by the UText.
virtual ~RuleBasedBreakIterator()
Destructor.
RuleBasedBreakIterator(const UnicodeString &rules, UParseError &parseError, UErrorCode &status)
Construct a RuleBasedBreakIterator from a set of rules supplied as a string.
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 int32_t hashCode(void) const
Compute a hash code for this BreakIterator.
virtual int32_t next(void) override
Advances the iterator to the next boundary position.
RuleBasedBreakIterator(const uint8_t *compiledRules, uint32_t ruleLength, UErrorCode &status)
Construct a RuleBasedBreakIterator from a set of precompiled binary rules.
virtual void setText(const UnicodeString &newText) override
Set the iterator to analyze a new piece of text.
A concrete subclass of CharacterIterator that iterates over the characters (code units or code points...
UnicodeString is a string class that stores Unicode characters directly and provides similar function...
U_EXPORT UBool operator==(const StringPiece &x, const StringPiece &y)
Global operator == for StringPiece.
bool operator!=(const StringPiece &x, const StringPiece &y)
Global operator != for StringPiece.
C API: Parse Error Information.
C++ API: String Character Iterator.
Immutable Unicode code point trie structure.
A UParseError struct is used to returned detailed information about parsing errors.
C API: Data loading interface.
struct UDataMemory UDataMemory
Forward declaration of the data memory type.
int32_t UChar32
Define UChar32 as a type for single Unicode code points.
int8_t UBool
The ICU boolean type, a signed-byte integer.
void * UClassID
UClassID is used to identify classes without using the compiler's RTTI.
Basic definitions for ICU, for both C and C++ APIs.
UErrorCode
Standard ICU4C error code type, a substitute for exceptions.
#define U_COMMON_API
Set to export library symbols from inside the common library, and to import them from outside.