Class MissingRecordAwareHSSFListener

java.lang.Object
org.apache.poi.hssf.eventusermodel.MissingRecordAwareHSSFListener
All Implemented Interfaces:
HSSFListener

public final class MissingRecordAwareHSSFListener extends Object implements HSSFListener

A HSSFListener which tracks rows and columns, and will trigger your HSSFListener for all rows and cells, even the ones that aren't actually stored in the file.

This allows your code to have a more "Excel" like view of the data in the file, and not have to worry (as much) about if a particular row/cell is in the file, or was skipped from being written as it was blank.

  • Constructor Details

    • MissingRecordAwareHSSFListener

      public MissingRecordAwareHSSFListener(HSSFListener listener)
      Constructs a new MissingRecordAwareHSSFListener, which will fire processRecord on the supplied child HSSFListener for all Records, and missing records.
      Parameters:
      listener - The HSSFListener to pass records on to
  • Method Details

    • processRecord

      public void processRecord(Record record)
      Description copied from interface: HSSFListener
      process an HSSF Record. Called when a record occurs in an HSSF file.
      Specified by:
      processRecord in interface HSSFListener
      Parameters:
      record - the record to be processed