|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.cmu.minorthird.text.learn.ExtractorAnnotatorWrapper
public class ExtractorAnnotatorWrapper
Wraps an ExtractorAnnotator with some code to implement a simple API.
Constructor Summary | |
---|---|
ExtractorAnnotatorWrapper(ExtractorAnnotator annotator)
Construct from an annotator that implements the ExtractorAnnotator interface. |
|
ExtractorAnnotatorWrapper(java.io.File file)
Construct from a file containing a serialized extractor, as would be learned by TrainExtractor. |
|
ExtractorAnnotatorWrapper(java.io.InputStream stream)
Construct from an InputStream containing a serialized extractor, as would be learned by TrainExtractor. |
Method Summary | |
---|---|
java.lang.String[] |
extractFrom(java.lang.String source)
Apply the wrapped annotator to a string, and return all substrings extracted. |
ExtractorAnnotator |
getAnnotator()
|
static void |
main(java.lang.String[] args)
An interactive test routine to see if this thing works. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ExtractorAnnotatorWrapper(java.io.File file) throws java.io.IOException
java.io.IOException
public ExtractorAnnotatorWrapper(java.io.InputStream stream) throws java.io.IOException
java.io.IOException
public ExtractorAnnotatorWrapper(ExtractorAnnotator annotator)
Method Detail |
---|
public ExtractorAnnotator getAnnotator()
public java.lang.String[] extractFrom(java.lang.String source)
public static void main(java.lang.String[] args) throws java.lang.Exception
java.lang.Exception
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |