public class CuratorTextAnnotationBuilder extends Object implements TextAnnotationBuilder
TextAnnotation
builder, that uses CuratorClient to create a
TextAnnotation and populate it with
ViewNames.TOKENS and
ViewNames.SENTENCE views.SPLIT_ON_DASH| Constructor and Description |
|---|
CuratorTextAnnotationBuilder(CuratorClient curatorClient) |
| Modifier and Type | Method and Description |
|---|---|
TextAnnotation |
createTextAnnotation(String text)
A method for creating
TextAnnotation by
tokenizing the given text string. |
TextAnnotation |
createTextAnnotation(String corpusId,
String textId,
String text)
An overloaded version of
TextAnnotationBuilder.createTextAnnotation(String) which takes in a corpus Id and
text Id. |
TextAnnotation |
createTextAnnotation(String corpusId,
String textId,
String text,
Tokenizer.Tokenization tokenization)
A method for creating
TextAnnotation by
respecting the pre-tokenization of text passed as an instance of
Tokenizer.Tokenization. |
String |
getName() |
public CuratorTextAnnotationBuilder(CuratorClient curatorClient)
public TextAnnotation createTextAnnotation(String text) throws IllegalArgumentException
TextAnnotationBuilderTextAnnotation by
tokenizing the given text string.createTextAnnotation in interface TextAnnotationBuildertext - Raw text stringIllegalArgumentExceptionpublic TextAnnotation createTextAnnotation(String corpusId, String textId, String text) throws IllegalArgumentException
TextAnnotationBuilderTextAnnotationBuilder.createTextAnnotation(String) which takes in a corpus Id and
text Id. These strings can be used for bookkeeping.createTextAnnotation in interface TextAnnotationBuildertext - Raw text string.IllegalArgumentExceptionpublic TextAnnotation createTextAnnotation(String corpusId, String textId, String text, Tokenizer.Tokenization tokenization) throws IllegalArgumentException
TextAnnotationBuilderTextAnnotation by
respecting the pre-tokenization of text passed as an instance of
Tokenizer.Tokenization.createTextAnnotation in interface TextAnnotationBuildertext - Raw text stringtokenization - An instance containing tokens, character offsets, and sentence
boundaries.IllegalArgumentExceptionpublic String getName()
getName in interface TextAnnotationBuilderCopyright © 2017. All rights reserved.