title: Removing a row from an Excel sheet with Apache POI HSSF
body: <p>I'm using the Apache POi HSSF library to import info into my application. The problem is that the files have some extra/empty rows that need to be removed first before parsing.</p>
  
  <p>There's not a <code>HSSFSheet.removeRow( int rowNum )</code> method. Only <code>removeRow( HSSFRow row )</code>. The problem with this it that empty rows can't be removed. For example:  </p>
  
  <pre><code>sheet.removeRow( sheet.getRow(rowNum) );
  </code></pre>
  
  <p>gives a NullPointerException on empty rows because <code>getRow()</code> returns null.
  Also, as I read on forums, <code>removeRow()</code> only erases the cell contents but the row is still there as an empty row.</p>
  
  <p>Is there a way of removing rows (empty or not) without creating a whole new sheet without the rows that I want to remove?</p>