Package eu.clarin.weblicht.wlfxb.tc.api
Interface TextStructureLayer
-
- All Superinterfaces:
TextCorpusLayer
- All Known Implementing Classes:
TextStructureLayerStored
public interface TextStructureLayer extends TextCorpusLayer
The TextStructureLayer preserves the original structure of a written text. Within the layer, a token sequence can be annotated as belonging to some text structure element, such as to a page, a paragraph, a line, a title, etc. textspan element represents text structure annotation on a token sequence. The token sequence is specified by start token id and end token id. The type of the text structure element is specified by the corresponding attribute.- Author:
- Yana Panchenko
-
-
Method Summary
Modifier and Type Method Description TextSpanaddSpan(TextSpan parentSpan, Token spanStart, Token spanEnd, String type)TextSpanaddSpan(TextSpan parentSpan, Token spanStart, Token spanEnd, String type, int startChar, int endChar)TextSpanaddSpan(TextSpan parentSpan, Token spanStart, Token spanEnd, String type, String value)TextSpanaddSpan(Token spanStart, Token spanEnd, String type)TextSpanaddSpan(Token spanStart, Token spanEnd, String type, int startChar, int endChar)TextSpanaddSpan(Token spanStart, Token spanEnd, String type, String value)TextSpangetSpan(int index)TextSpangetSpan(Token token, String type)List<TextSpan>getSpans(Token token)List<TextSpan>getSpans(String type)Token[]getTokens(TextSpan span)-
Methods inherited from interface eu.clarin.weblicht.wlfxb.tc.api.TextCorpusLayer
isEmpty, size
-
-
-
-
Method Detail
-
getSpan
TextSpan getSpan(int index)
-
addSpan
TextSpan addSpan(TextSpan parentSpan, Token spanStart, Token spanEnd, String type) throws WLFormatException
- Throws:
WLFormatException
-
addSpan
TextSpan addSpan(TextSpan parentSpan, Token spanStart, Token spanEnd, String type, int startChar, int endChar) throws WLFormatException
- Throws:
WLFormatException
-
addSpan
TextSpan addSpan(TextSpan parentSpan, Token spanStart, Token spanEnd, String type, String value) throws WLFormatException
- Throws:
WLFormatException
-
-