Package it.uniroma1.lcl.babelnet.data
Class BabelTokenWord
- java.lang.Object
-
- it.uniroma1.lcl.babelnet.data.BabelTokenWord
-
- All Implemented Interfaces:
Serializable
,Comparable<BabelTokenWord>
public class BabelTokenWord extends Object implements Comparable<BabelTokenWord>, Serializable
Represents the token unit which can be used to build sentences.- Author:
- vannella
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description BabelTokenWord(int s, int e, String lemma)
Creates a new instance of aBabelTokenWord
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compareTo(BabelTokenWord f)
boolean
equals(Object o)
int
getEnd()
Gets the end index of the tokenString
getLemma()
Gets the lemma of thisBabelTokenWord
.int
getStart()
Gets the start index of the tokenint
hashCode()
String
toString()
-
-
-
Constructor Detail
-
BabelTokenWord
public BabelTokenWord(int s, int e, String lemma)
Creates a new instance of aBabelTokenWord
- Parameters:
s
- start position within the sentencee
- end position within the sentencelemma
- the lemma of the inflected form in the string range
-
-
Method Detail
-
getLemma
public String getLemma()
Gets the lemma of thisBabelTokenWord
.- Returns:
- the lemma of this
BabelTokenWord
.
-
getStart
public int getStart()
Gets the start index of the token- Returns:
- the first integer
-
getEnd
public int getEnd()
Gets the end index of the token- Returns:
- the second integer
-
compareTo
public int compareTo(BabelTokenWord f)
- Specified by:
compareTo
in interfaceComparable<BabelTokenWord>
-
-