public class Span extends Object
| Constructor and Description |
|---|
Span(int tokenStart,
int tokenEnd,
int characterStart,
int characterEnd)
Creates a new span.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
int |
getCharacterEnd()
Gets the character's end of the start of the span.
|
int |
getCharacterStart()
Gets the character's start of the span.
|
int |
getTokenEnd()
Gets the end of the span.
|
int |
getTokenStart()
Gets the token's start of the span.
|
int |
hashCode() |
void |
setCharacterEnd(int characterEnd)
Sets the character-based index of the end of the span.
|
void |
setCharacterStart(int characterStart)
Sets the character-based index of the span.
|
String |
toString()
Returns the token-based span as a formatted string.
|
public Span(int tokenStart,
int tokenEnd,
int characterStart,
int characterEnd)
tokenStart - The position of the start of the token's span.tokenEnd - The position of the end of the token's span.characterStart - The character-based position of the span.characterEnd - The character-based position of the span.public String toString()
public int getTokenStart()
public int getTokenEnd()
public int getCharacterStart()
public void setCharacterStart(int characterStart)
characterStart - The character-based index of the span.public int getCharacterEnd()
public void setCharacterEnd(int characterEnd)
characterStart - The character-based index of the end of the span.Copyright © 2017. All rights reserved.