类 MinioUtil
java.lang.Object
com.mbap.upload.utils.minio.MinioUtil
Minio工具类
- 作者:
- BW.Panda Mar 10, 2020
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明void删除文件下载文件,返回stream.返回bucketName预览图片voidupload(InputStream inputStream, String objectName, long size, String contentType) 上传文件到minio中
-
构造器详细资料
-
MinioUtil
public MinioUtil()
-
-
方法详细资料
-
getBucketName
返回bucketName- 返回:
- String
-
upload
上传文件到minio中- 参数:
inputStream- stream to upload.objectName- Object name to create in the bucket.size- Size of all the data that will be uploaded.contentType- Content type of the stream.
-
preview
预览图片- 参数:
fileName-- 返回:
-
download
下载文件,返回stream. The InputStream must be closed after use else the connection will remain open.- 参数:
objectName- Object name to create in the bucket.- 返回:
InputStream
-
delete
删除文件- 参数:
objectName- Object name to create in the bucket.
-