mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-07-21 15:09:48 +08:00
修改方法参数名
This commit is contained in:
@@ -744,19 +744,19 @@ public class CommonsFtp extends AbstractFtp {
|
|||||||
/**
|
/**
|
||||||
* 读取文件为输入流
|
* 读取文件为输入流
|
||||||
*
|
*
|
||||||
* @param path 服务端的文件路径
|
* @param dir 服务端的文件目录
|
||||||
* @param fileName 服务端的文件名
|
* @param fileName 服务端的文件名
|
||||||
* @return {@link InputStream}
|
* @return {@link InputStream}
|
||||||
* @throws IORuntimeException IO异常
|
* @throws IORuntimeException IO异常
|
||||||
*/
|
*/
|
||||||
public InputStream read(String path, String fileName) throws IORuntimeException {
|
public InputStream read(String dir, String fileName) throws IORuntimeException {
|
||||||
String pwd = null;
|
String pwd = null;
|
||||||
if (isBackToPwd()) {
|
if (isBackToPwd()) {
|
||||||
pwd = pwd();
|
pwd = pwd();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!cd(path)) {
|
if (!cd(dir)) {
|
||||||
throw new FtpException("Change dir to [{}] error, maybe dir not exist!", path);
|
throw new FtpException("Change dir to [{}] error, maybe dir not exist!", dir);
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
client.setFileType(FTPClient.BINARY_FILE_TYPE);
|
client.setFileType(FTPClient.BINARY_FILE_TYPE);
|
||||||
|
Reference in New Issue
Block a user