public interface IFileWrapper extends Closeable
Modifier and Type | Method and Description |
---|---|
long |
getContentLength()
获取文件长度
|
String |
getContentType()
获取文件类型
|
String |
getErrorMsg()
获取错误描述信息
|
File |
getFile()
获取文件对象
|
String |
getFileName()
获取文件名称(含扩展名称)
|
InputStream |
getInputStream()
获取文件输入流
|
String |
getName()
获取文件名称(不含扩展名称)
|
String |
getSuffix()
获取文件扩展名称
|
boolean |
hasError()
是否存在错误
|
org.apache.http.entity.mime.content.ContentBody |
toContentBody()
将文件转换为ContentBody对象
|
void |
writeTo(File distFile)
复制文件到目标文件
|
boolean hasError()
String getErrorMsg()
String getFileName()
String getName()
String getSuffix()
long getContentLength()
String getContentType()
InputStream getInputStream() throws IOException
IOException
- 可能产生的异常File getFile()
void writeTo(File distFile) throws IOException
distFile
- 目标文件IOException
- 可能产生的异常org.apache.http.entity.mime.content.ContentBody toContentBody() throws IOException
IOException
- 可能产生的异常Copyright © 2022. All rights reserved.