Documentation
¶
Index ¶
- type S3Storage
- func (s *S3Storage) DeleteFile(ctx context.Context, bucket string, fileKey string) error
- func (s *S3Storage) GenerateDownloadURL(ctx context.Context, bucket string, fileKey string, expireSeconds int) (string, error)
- func (s *S3Storage) GenerateUploadURL(ctx context.Context, bucket string, prefix string, fileName string, ...) (string, string, error)
- func (s *S3Storage) GetFile(ctx context.Context, bucket string, fileKey string) ([]byte, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type S3Storage ¶
type S3Storage struct {
// contains filtered or unexported fields
}
S3Storage S3 存储服务实现(基于 MinIO)
func (*S3Storage) DeleteFile ¶
DeleteFile 删除文件
func (*S3Storage) GenerateDownloadURL ¶
func (s *S3Storage) GenerateDownloadURL(ctx context.Context, bucket string, fileKey string, expireSeconds int) (string, error)
GenerateDownloadURL 生成预签名下载 URL
Click to show internal directories.
Click to hide internal directories.