@Test public void loadFilename() throws IOException { final LineHandler lh = buildLineHandler(limit, line); final String filename = "src/test/java/com/lightboxtechnologies/nsrl/jackdaws"; final RecordLoader loader = new RecordLoader(); loader.load(filename, lh); }
public void load(Reader r, LineHandler lh) throws IOException { BufferedReader br = null; try { br = new BufferedReader(r); br.readLine(); String line; long linenum = 0; while ((line = br.readLine()) != null) { ++linenum; lh.handle(line, linenum); } br.close(); } finally { IOUtils.closeQuietly(br); } }
RecordLoader { public void load(Reader r, LineHandler lh) throws IOException { BufferedReader br = null; try { br = new BufferedReader(r); br.readLine(); String line; long linenum = 0; while ((line = br.readLine()) != null) { ++linenum; lh.handle(line, linenum); } br.close(); } finally { IOUtils.closeQuietly(br); } } }
RecordLoader { public void load(Reader r, LineHandler lh) throws IOException { BufferedReader br = null; try { br = new BufferedReader(r); br.readLine(); String line; long linenum = 0; while ((line = br.readLine()) != null) { ++linenum; lh.handle(line, linenum); } br.close(); } finally { IOUtils.closeQuietly(br); } }  }
RecordLoader { public void load(Reader r, LineHandler lh) throws IOException { BufferedReader br = null; try { br = new BufferedReader(r); br.readLine(); String line; long linenum = 0; while ((line = br.readLine()) != null) { ++linenum; lh.handle(line, linenum); } br.close(); } finally { IOUtils.closeQuietly(br); } }  void load(Reader r, LineHandler lh); void load(InputStream in, LineHandler lh); void load(String filename, LineHandler lh); }
RecordLoader { public void load(Reader r, LineHandler lh) throws IOException { BufferedReader br = null; try { br = new BufferedReader(r); br.readLine(); String line; long linenum = 0; while ((line = br.readLine()) != null) { ++linenum; lh.handle(line, linenum); } br.close(); } finally { IOUtils.closeQuietly(br); } }  void load(Reader r, LineHandler lh); void load(InputStream in, LineHandler lh); void load(String filename, LineHandler lh);  }