Package it.uniroma1.lcl.babelnet.data
Class BabelTokenId
- java.lang.Object
-
- it.uniroma1.lcl.babelnet.data.BabelTokenId
-
- All Implemented Interfaces:
Serializable,Comparable<BabelTokenId>
public class BabelTokenId extends Object implements Comparable<BabelTokenId>, Serializable
Represents the association between the word that appears in a Babel gloss and theBabelSynsetIDthat identifies the lemma in BabelNet.- Author:
- vannella
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description BabelTokenId(int s, int e, BabelSynsetID id, String word)Creates a new instance of aBabelTokenId
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intcompareTo(BabelTokenId f)booleanequals(Object o)intgetEnd()Gets the end index of the tokenBabelSynsetIDgetID()Returns the BabelSynset idintgetStart()Gets the start index of the tokenStringgetWord()Gets the word of thisBabelTokenId.inthashCode()StringtoString()
-
-
-
Constructor Detail
-
BabelTokenId
public BabelTokenId(int s, int e, BabelSynsetID id, String word)Creates a new instance of aBabelTokenId- Parameters:
s- the start positione- the end positionid- the id of theBabelSynsetword- the word being annotated
-
-
Method Detail
-
getID
public BabelSynsetID getID()
Returns the BabelSynset id- Returns:
- the BabelSynsetID
-
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
-
getWord
public String getWord()
Gets the word of thisBabelTokenId.- Returns:
- the word of this
BabelTokenId.
-
compareTo
public int compareTo(BabelTokenId f)
- Specified by:
compareToin interfaceComparable<BabelTokenId>
-
-