package cn.com.css.common.util;
import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.math.BigDecimal;
import java.util.HashMap;
import java.util.Map;
import org.apache.poi.hssf.usermodel.HSSFCell;
import org.apache.poi.xssf.usermodel.XSSFCell;
import org.apache.poi.xssf.usermodel.XSSFRow;
import org.apache.poi.xssf.usermodel.XSSFSheet;
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
public class ExcelParser {
private XSSFWorkbook xssfWorkbook;
private XSSFSheet xssfSheet;
private XSSFRow xssfRow;
private int columnNumbers;
private int totalRows;
/**
* @param args
* @throws Exception
*/
private String getCellFormatValue(XSSFCell cell) {
String cellvalue = "";
if (cell != null) {
// 推断当前Cell的Type
switch (cell.getCellType()) {
// 假设当前Cell的Type为NUMERIC
case XSSFCell.CELL_TYPE_NUMERIC: {
BigDecimal big = new BigDecimal(cell.getNumericCellValue());
cellvalue = bi