#include <object.h>
Definition at line 10181 of file object.h.
◆ CodePointIterator() [1/2]
dart::String::CodePointIterator::CodePointIterator |
( |
const String & |
str | ) |
|
|
inlineexplicit |
Definition at line 10183 of file object.h.
10184 : str_(str), ch_(0), index_(-1), end_(str.Length()) {
10186 }
◆ CodePointIterator() [2/2]
dart::String::CodePointIterator::CodePointIterator |
( |
const String & |
str, |
|
|
intptr_t |
start, |
|
|
intptr_t |
length |
|
) |
| |
|
inline |
Definition at line 10188 of file object.h.
10189 : str_(str), ch_(0), index_(start - 1), end_(start +
length) {
10191 ASSERT(end_ <= str.Length());
10192 }
◆ Current()
int32_t dart::String::CodePointIterator::Current |
( |
| ) |
const |
|
inline |
Definition at line 10194 of file object.h.
10194 {
10197 return ch_;
10198 }
◆ Next()
bool dart::String::CodePointIterator::Next |
( |
| ) |
|
Definition at line 24318 of file object.cc.
24318 {
24321 if (index_ < (end_ -
length)) {
24323 ch_ = str_.
CharAt(index_);
24325 int32_t ch2 = str_.
CharAt(index_ + 1);
24328 }
24329 }
24330 return true;
24331 }
24332 index_ = end_;
24333 return false;
24334}
uint16_t CharAt(intptr_t index) const
static int32_t Decode(uint16_t lead, uint16_t trail)
static bool IsLeadSurrogate(uint32_t ch)
static intptr_t Length(int32_t ch)
static bool IsTrailSurrogate(uint32_t ch)
The documentation for this class was generated from the following files:
- third_party/dart-lang/sdk/runtime/vm/object.h
- third_party/dart-lang/sdk/runtime/vm/object.cc