对话流实现 文件上传
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
package org.xyzh.api.file;
|
||||
|
||||
import java.io.File;
|
||||
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.xyzh.common.core.domain.ResultDomain;
|
||||
import org.xyzh.common.dto.system.TbSysFile;
|
||||
@@ -120,5 +122,33 @@ public interface FileService {
|
||||
* @since 2025-10-16
|
||||
*/
|
||||
ResultDomain<TbSysFile> batchDeleteFiles(String[] fileIds);
|
||||
|
||||
/**
|
||||
* @description 保存临时文件(不入库,仅存储到磁盘)
|
||||
* @param file 文件对象
|
||||
* @param module 模块名称
|
||||
* @return ResultDomain<String> 返回临时文件路径
|
||||
* @author yslg
|
||||
* @since 2025-11-06
|
||||
*/
|
||||
ResultDomain<String> saveTempFile(MultipartFile file, String module);
|
||||
|
||||
/**
|
||||
* @description 删除临时文件
|
||||
* @param tempFilePath 临时文件路径
|
||||
* @return ResultDomain<Boolean> 删除结果
|
||||
* @author yslg
|
||||
* @since 2025-11-06
|
||||
*/
|
||||
ResultDomain<Boolean> deleteTempFile(String tempFilePath);
|
||||
|
||||
/**
|
||||
* @description 通过相对路径获取文件的绝对路径File对象
|
||||
* @param relativePath 相对路径
|
||||
* @return File 文件对象
|
||||
* @author yslg
|
||||
* @since 2025-11-06
|
||||
*/
|
||||
File getFileByRelativePath(String relativePath);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user