同步代码
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
package org.dromara.resource.api;
|
||||
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import org.dromara.common.core.exception.ServiceException;
|
||||
import org.dromara.resource.api.domain.RemoteFile;
|
||||
|
||||
@@ -22,6 +21,14 @@ public interface RemoteFileService {
|
||||
*/
|
||||
RemoteFile upload(String name, String originalFilename, String contentType, byte[] file) throws ServiceException;
|
||||
|
||||
/**
|
||||
* 文件上传
|
||||
* @param file 文件信息
|
||||
* @return 结果
|
||||
* @throws ServiceException
|
||||
*/
|
||||
RemoteFile upload(byte[] file) throws ServiceException;
|
||||
|
||||
/**
|
||||
* 通过ossId查询对应的url
|
||||
*
|
||||
@@ -41,7 +48,7 @@ public interface RemoteFileService {
|
||||
/**
|
||||
* 文件下载方法,支持一次性下载完整文件
|
||||
*
|
||||
* @param ossId OSS对象ID
|
||||
* @param ossId OSS对象ID
|
||||
* @return byte[] 返回下载的字节数组
|
||||
*/
|
||||
byte[] downloadToByteArray(Long ossId) throws IOException;
|
||||
|
Reference in New Issue
Block a user