All Downloads are FREE. Search and download functionalities are using the official Maven repository.

top.coos.poi.excel.sax.AbstractExcelSaxReader Maven / Gradle / Ivy

There is a newer version: 2.2.7.1
Show newest version
package top.coos.poi.excel.sax;

import java.io.File;
import java.io.InputStream;

import top.coos.core.io.FileUtil;
import top.coos.poi.exceptions.POIException;

/**
 * 抽象的Sax方式Excel读取器,提供一些共用方法
 * 

 *
 * @param  子对象类型,用于标记返回值this
 * @since 3.2.0
 */
public abstract class AbstractExcelSaxReader implements ExcelSaxReader {
	
	@Override
	public T read(String path) throws POIException {
		return read(FileUtil.file(path));
	}

	@Override
	public T read(File file) throws POIException {
		return read(file, -1);
	}

	@Override
	public T read(InputStream in) throws POIException {
		return read(in, -1);
	}

	@Override
	public T read(String path, int sheetIndex) throws POIException {
		return read(FileUtil.file(path), sheetIndex);
	}
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy