public class LabeledSpan extends Object implements Span
| Constructor and Description |
|---|
LabeledSpan(Span span,
Label label,
boolean isBackground) |
LabeledSpan(Span span,
Label label,
boolean isBackground,
double confidence) |
| Modifier and Type | Method and Description |
|---|---|
double |
getConfidence() |
Object |
getDocument() |
int |
getEndIdx()
Returns an integer index identifying the end of this span.
|
Label |
getLabel() |
Span |
getSpan() |
int |
getStartIdx()
Returns an integer index identifying the start of this span.
|
String |
getText()
Returns a textual representatio of the span, suitable for XML output, e.g.
|
Span |
intersection(Span r)
Returns a new span that is the intersection of this span and another.
|
boolean |
intersects(Span r) |
boolean |
isBackground() |
boolean |
isSubspan(Span r) |
String |
toString() |
public Span getSpan()
public Label getLabel()
public String getText()
Spanpublic Object getDocument()
getDocument in interface Spanpublic double getConfidence()
public boolean intersects(Span r)
intersects in interface Spanpublic Span intersection(Span r)
Spanintersection in interface Spanpublic int getEndIdx()
Spanpublic int getStartIdx()
SpangetStartIdx in interface Spanpublic boolean isBackground()
Copyright © 2019 JULIE Lab, Germany. All rights reserved.