DatenpaketStreamer { public void readDatenpaket() throws IOException { readVorsatz(); while (true) { Satz satz = Datenpaket.importSatz(reader); notice(satz); if (satz.getSatzart() == 9999) { break; } } } DatenpaketStreamer(final InputStream istream);  DatenpaketStreamer(final Reader reader); void register(final ImportListener listener); void readDatenpaket(); boolean canReadDatenpaket();  }
@IntegrationTest @Test public void testReadDatenpaket() throws IOException { InputStream istream = this.getClass().getResourceAsStream("/musterdatei_041222.txt"); try { readDatenpaket(istream); } finally { istream.close(); } }
@IntegrationTest @Test public void testRead2Datenpakete() throws IOException { InputStream istream = this.getClass().getResourceAsStream("/zwei_datenpakete.txt"); try { readDatenpaket(istream); readDatenpaket(istream); } finally { istream.close(); } }