java.lang.Object
net.fellbaum.jemoji.IndexedAlias
Represents an alias with character and codepoint indexes.
-
Method Summary
Modifier and TypeMethodDescriptiongetAlias()Gets the captured alias.intGets the character index at which the alias starts.intGets the codepoint index at which the alias starts.Gets theEmojis.intGets the character index at which the alias ends.intGets the codepoint index at which the alias ends.toString()
-
Method Details
-
getEmojis
Gets theEmojis.- Returns:
- The emojis.
-
getAlias
Gets the captured alias.- Returns:
- The captured alias.
-
getCharIndex
public int getCharIndex()Gets the character index at which the alias starts.The index is included in
0 < input <= input.length() - 1- Returns:
- The character index at which the alias starts.
-
getCodePointIndex
public int getCodePointIndex()Gets the codepoint index at which the alias starts.This must not be confused with
getCharIndex(), a codepoint can contain one or two characters, which means the codepoint index will likely be lower than the character index.- Returns:
- The character index at which the alias starts.
-
getEndCharIndex
public int getEndCharIndex()Gets the character index at which the alias ends.The index is included in
0 < input <= input.length() - 1- Returns:
- The character index at which the alias ends.
-
getEndCodePointIndex
public int getEndCodePointIndex()Gets the codepoint index at which the alias ends.This must not be confused with
getEndCharIndex(), a codepoint can contain one or two characters, which means the codepoint index will likely be lower than the character index.- Returns:
- The character index at which the alias ends.
-
toString
-