96 enum { DONE = 0xffff };
131 virtual int32_t hashCode(
void)
const = 0;
150 virtual UChar nextPostInc(
void) = 0;
160 virtual UChar32 next32PostInc(
void) = 0;
171 virtual UBool hasNext() = 0;
387 virtual UChar first(
void) = 0;
397 virtual UChar firstPostInc(
void);
408 virtual UChar32 first32(
void) = 0;
418 virtual UChar32 first32PostInc(
void);
427 inline int32_t setToStart();
436 virtual UChar last(
void) = 0;
445 virtual UChar32 last32(
void) = 0;
454 inline int32_t setToEnd();
464 virtual UChar setIndex(int32_t position) = 0;
477 virtual UChar32 setIndex32(int32_t position) = 0;
484 virtual UChar current(
void)
const = 0;
491 virtual UChar32 current32(
void)
const = 0;
500 virtual UChar next(
void) = 0;
512 virtual UChar32 next32(
void) = 0;
521 virtual UChar previous(
void) = 0;
530 virtual UChar32 previous32(
void) = 0;
541 virtual UBool hasPrevious() = 0;
553 inline int32_t startIndex(
void)
const;
564 inline int32_t endIndex(
void)
const;
574 inline int32_t getIndex(
void)
const;
582 inline int32_t getLength()
const;
595 virtual int32_t move(int32_t delta, EOrigin origin) = 0;
608 virtual int32_t move32(int32_t delta, EOrigin origin) = 0;
641 CharacterIterator(int32_t length, int32_t textBegin, int32_t textEnd, int32_t position);
692 CharacterIterator::setToStart() {
693 return move(0, kStart);
697 CharacterIterator::setToEnd() {
698 return move(0, kEnd);
702 CharacterIterator::startIndex(
void)
const {
707 CharacterIterator::endIndex(
void)
const {
712 CharacterIterator::getIndex(
void)
const {
717 CharacterIterator::getLength(
void)
const {
virtual UClassID getDynamicClassID() const =0
ICU4C "poor man's RTTI", returns a UClassID for the actual ICU class.
U_EXPORT UBool operator==(const StringPiece &x, const StringPiece &y)
Global operator == for StringPiece.
void * UClassID
UClassID is used to identify classes without using the compiler's RTTI.
#define U_NAMESPACE_BEGIN
This is used to begin a declaration of a public ICU C++ API.
Abstract class that defines an API for iteration on text objects.
UBool operator!=(const StringPiece &x, const StringPiece &y)
Global operator != for StringPiece.
int32_t textLength
Base class text length field.
int32_t UChar32
Define UChar32 as a type for single Unicode code points.
int32_t begin
Base class field for the start of the iteration range.
C++ API: Common ICU base class UObject.
uint16_t UChar
Define UChar to be UCHAR_TYPE, if that is #defined (for example, to char16_t), or wchar_t if that is ...
#define U_NAMESPACE_END
This is used to end a declaration of a public ICU C++ API.
int32_t pos
Base class field for the current position.
Abstract class that defines an API for forward-only iteration on text objects.
Basic definitions for ICU, for both C and C++ APIs.
#define U_COMMON_API
Set to export library symbols from inside the common library, and to import them from outside...
UnicodeString is a string class that stores Unicode characters directly and provides similar function...
ForwardCharacterIterator & operator=(const ForwardCharacterIterator &)
Assignment operator to be overridden in the implementing class.
int32_t end
Base class field for the end of the iteration range.
UObject is the common ICU "boilerplate" class.
EOrigin
Origin enumeration for the move() and move32() functions.
int8_t UBool
The ICU boolean type.