use of eu.clarin.weblicht.wlfxb.tc.api.TextCorpus in project webanno by webanno.
the class TcfReader method getNext.
@Override
public void getNext(JCas aJCas) throws IOException, CollectionException {
Resource res = nextFile();
initCas(aJCas, res);
InputStream is = null;
try {
is = new BufferedInputStream(res.getInputStream());
WLData wLData = WLDObjector.read(is);
TextCorpus aCorpusData = wLData.getTextCorpus();
convertToCas(aJCas, aCorpusData);
} catch (WLFormatException e) {
throw new CollectionException(e);
} finally {
closeQuietly(is);
}
}
Aggregations