use of org.apache.poi.hssf.eventusermodel.HSSFListener in project poi by apache.
the class EFBiffViewer method run.
public void run() throws IOException {
NPOIFSFileSystem fs = new NPOIFSFileSystem(new File(file), true);
try {
InputStream din = BiffViewer.getPOIFSInputStream(fs);
try {
HSSFRequest req = new HSSFRequest();
req.addListenerForAllRecords(new HSSFListener() {
public void processRecord(Record rec) {
System.out.println(rec);
}
});
HSSFEventFactory factory = new HSSFEventFactory();
factory.processEvents(req, din);
} finally {
din.close();
}
} finally {
fs.close();
}
}
Aggregations