接口 BaseCompressHandler
- 所有已知子接口:
CmdCompressHandler,CodeCompressHandler
- 所有已知实现类:
RarCmdCompressHandler,ZipCodeCompressHandler
public interface BaseCompressHandler
压缩工具基础接口
- 从以下版本开始:
- 1.0.9
- 作者:
- yuanhang.huang
-
方法概要
-
方法详细资料
-
match
压缩文件匹配检查- 参数:
fileName- 压缩文件名- 返回:
- 是否匹配成功
-
compress
void compress(String sourcePath, String destFile, boolean cover) throws IOException, InterruptedException, RuntimeException 压缩文件- 参数:
sourcePath- 源文件/文件夹destFile- 压缩文件cover- 覆盖文件- 抛出:
IOException- IO异常InterruptedException- 中断异常RuntimeException- 运行异常
-
decompress
void decompress(String sourceFile, String destDir, boolean cover, boolean deep) throws IOException, InterruptedException, RuntimeException 解压文件- 参数:
sourceFile- 源文件destDir- 解压目录cover- 覆盖文件deep- 深度压缩(递归)- 抛出:
IOException- IO异常InterruptedException- 中断异常RuntimeException- 运行异常
-