Documentation ¶
Index ¶
- Constants
- type MinIO
- func (m *MinIO) AuthorizedUpload(key string, expires int) (string, error)
- func (m *MinIO) Cloud() string
- func (m *MinIO) DeleteObjects(keys ...string) error
- func (m *MinIO) GetObject(key string) (io.ReadCloser, error)
- func (m *MinIO) GetThumbnailSuffix(width, height int, size int64) string
- func (m *MinIO) GetURL(key string) string
- func (m *MinIO) PutObject(key string, reader io.Reader) (string, error)
- func (m *MinIO) UploadFile(key, filePath string, partSize int64, routines int) (string, error)
- type Option
Constants ¶
View Source
const (
// CloudMinIO 云服务商:MinIO
CloudMinIO = "minio"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MinIO ¶
type MinIO struct {
// contains filtered or unexported fields
}
MinIO 客户端
func NewMinIO ¶
func NewMinIO(endpoint, accessKeyID, accessKeySecret, bucketName string, opts ...Option) (*MinIO, error)
NewMinIO 新建一个 MinIO 客户端
func (*MinIO) AuthorizedUpload ¶
AuthorizedUpload 授权上传至 MinIO,expires:过期时间(秒)
func (*MinIO) DeleteObjects ¶
DeleteObjects 批量删除 MinIO 上的对象
func (*MinIO) GetObject ¶
func (m *MinIO) GetObject(key string) (io.ReadCloser, error)
GetObject 获取对象在 MinIO 的存储数据
func (*MinIO) GetThumbnailSuffix ¶
GetThumbnailSuffix 获取缩略图后缀
Click to show internal directories.
Click to hide internal directories.