The current BreakIterator only has the iterator operation, based on its index. It would be useful if it supports stream, such that,
Stream<String> BreakIterator.graphemes(String);
Stream<String> BreakIterator.words(String);
Stream<String> BreakIterator.sentences(String);
Stream<String> BreakIterator.lines(String);
Would return stream of string, instead of iterating over the text with the index. This is in addition to the existing iterator operation.
Stream<String> BreakIterator.graphemes(String);
Stream<String> BreakIterator.words(String);
Stream<String> BreakIterator.sentences(String);
Stream<String> BreakIterator.lines(String);
Would return stream of string, instead of iterating over the text with the index. This is in addition to the existing iterator operation.
- relates to
-
JDK-8291660 Grapheme support in BreakIterator
- Resolved