Package opennlp.tools.postag
Class POSSample
- java.lang.Object
-
- opennlp.tools.postag.POSSample
-
- All Implemented Interfaces:
java.io.Serializable
public class POSSample extends java.lang.Object implements java.io.Serializable
Represents an pos-tagged sentence.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description POSSample(java.lang.String[] sentence, java.lang.String[] tags)
POSSample(java.lang.String[] sentence, java.lang.String[] tags, java.lang.String[][] additionalContext)
POSSample(java.util.List<java.lang.String> sentence, java.util.List<java.lang.String> tags)
POSSample(java.util.List<java.lang.String> sentence, java.util.List<java.lang.String> tags, java.lang.String[][] additionalContext)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object obj)
java.lang.String[][]
getAddictionalContext()
java.lang.String[]
getSentence()
java.lang.String[]
getTags()
int
hashCode()
static POSSample
parse(java.lang.String sentenceString)
java.lang.String
toString()
-
-
-
Constructor Detail
-
POSSample
public POSSample(java.lang.String[] sentence, java.lang.String[] tags)
-
POSSample
public POSSample(java.util.List<java.lang.String> sentence, java.util.List<java.lang.String> tags)
-
POSSample
public POSSample(java.util.List<java.lang.String> sentence, java.util.List<java.lang.String> tags, java.lang.String[][] additionalContext)
-
POSSample
public POSSample(java.lang.String[] sentence, java.lang.String[] tags, java.lang.String[][] additionalContext)
-
-
Method Detail
-
getSentence
public java.lang.String[] getSentence()
-
getTags
public java.lang.String[] getTags()
-
getAddictionalContext
public java.lang.String[][] getAddictionalContext()
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
parse
public static POSSample parse(java.lang.String sentenceString) throws InvalidFormatException
- Throws:
InvalidFormatException
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
-