public class LengthGoalBreakIterator extends BreakIterator
BreakIterator to skip past breaks that would result in passages that are too
 short.  It's still possible to get a short passage but only at the very end of the input text.
 
 Important: This is not a general purpose BreakIterator; it's only designed to work in a way
 compatible with the UnifiedHighlighter.  Some assumptions are checked with Java assertions.
DONE| Modifier and Type | Method and Description | 
|---|---|
| Object | clone() | 
| static LengthGoalBreakIterator | createClosestToLength(BreakIterator baseIter,
                     int targetLength)Deprecated.  | 
| static LengthGoalBreakIterator | createClosestToLength(BreakIterator baseIter,
                     int targetLength,
                     float fragmentAlignment)Breaks will be on average  targetLengthapart; the closest break to this target (before or after)
 is chosen. | 
| static LengthGoalBreakIterator | createMinLength(BreakIterator baseIter,
               int minLength)Deprecated.  | 
| static LengthGoalBreakIterator | createMinLength(BreakIterator baseIter,
               int minLength,
               float fragmentAlignment)Breaks will be at least  minLengthapart (to the extent possible),
 while trying to position the match inside the fragment according tofragmentAlignment. | 
| int | current() | 
| int | first() | 
| int | following(int matchEndIndex) | 
| CharacterIterator | getText() | 
| boolean | isBoundary(int offset) | 
| int | last() | 
| int | next() | 
| int | next(int n) | 
| int | preceding(int matchStartIndex) | 
| int | previous() | 
| void | setText(CharacterIterator newText) | 
| void | setText(String newText) | 
| String | toString() | 
getAvailableLocales, getCharacterInstance, getCharacterInstance, getLineInstance, getLineInstance, getSentenceInstance, getSentenceInstance, getWordInstance, getWordInstancepublic static LengthGoalBreakIterator createMinLength(BreakIterator baseIter, int minLength, float fragmentAlignment)
minLength apart (to the extent possible),
 while trying to position the match inside the fragment according to fragmentAlignment.@Deprecated public static LengthGoalBreakIterator createMinLength(BreakIterator baseIter, int minLength)
public static LengthGoalBreakIterator createClosestToLength(BreakIterator baseIter, int targetLength, float fragmentAlignment)
targetLength apart; the closest break to this target (before or after)
 is chosen. The match will be positioned according to fragmentAlignment as much as possible.@Deprecated public static LengthGoalBreakIterator createClosestToLength(BreakIterator baseIter, int targetLength)
public Object clone()
clone in class BreakIteratorpublic CharacterIterator getText()
getText in class BreakIteratorpublic void setText(String newText)
setText in class BreakIteratorpublic void setText(CharacterIterator newText)
setText in class BreakIteratorpublic int current()
current in class BreakIteratorpublic int first()
first in class BreakIteratorpublic int last()
last in class BreakIteratorpublic int next(int n)
next in class BreakIteratorpublic int next()
next in class BreakIteratorpublic int previous()
previous in class BreakIteratorpublic int following(int matchEndIndex)
following in class BreakIteratorpublic int preceding(int matchStartIndex)
preceding in class BreakIteratorpublic boolean isBoundary(int offset)
isBoundary in class BreakIteratorCopyright © 2000-2021 Apache Software Foundation. All Rights Reserved.