-
- Enclosing class:
- TextUtil
public static interface TextUtil.CutStringCriteraDefine the cutting critera of the string.- Since:
- 4.0
- Version:
- 17.0 2020-01-04 14:41:39
- Author:
- Stéphane GALLAND
- Maven Group Id:
- org.arakhne.afc.core
- Maven Artifact Id:
- text
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description longgetCritera()Replies the critera.intgetCutIndexFor(String str)Replies the character index at which the given string may be cut to fit the critera.longgetLengthFor(String str)Replies the length of the given string.booleanisOverfull(long lineLength, String word)Replies if the given word is overfull the line.
-
-
-
Method Detail
-
isOverfull
boolean isOverfull(long lineLength, String word)Replies if the given word is overfull the line.- Parameters:
lineLength- is the current length of the line.word- is the word to add.- Returns:
trueif the word is overfulling the line,falseotherwise.
-
getLengthFor
long getLengthFor(String str)
Replies the length of the given string.- Parameters:
str- the string.- Returns:
- the length of
str.
-
getCutIndexFor
int getCutIndexFor(String str)
Replies the character index at which the given string may be cut to fit the critera.- Parameters:
str- the string.- Returns:
- the character index.
-
getCritera
long getCritera()
Replies the critera.- Returns:
- the critera.
-
-