}
private void open(InputStreamReader isr) throws MaltChainedException {
try {
XMLInputFactory factory = XMLInputFactory.newInstance();
setReader(factory.createXMLStreamReader(new BufferedReader(isr)));
} catch (XMLStreamException e) {
throw new DataFormatException("XML input file could be opened. ", e);
}
setSentenceCount(0);
}