Documentation
¶
Index ¶
- Variables
- func Custom() *client
- func DeleteFileCommon(ctx context.Context, fileName string, isExpired bool) error
- func DeleteFileCommonWithExpire(ctx context.Context, fileName string) error
- func DeleteFileCommonWithNotExpire(ctx context.Context, fileName string) error
- func DownloadFileToMemory(ctx context.Context, minioFilePath string) ([]byte, error)
- func FileUpload() *client
- func GetUploadFileCommon(ctx context.Context, fileName string, isExpired bool) (string, error)
- func GetUploadFileWithExpire(ctx context.Context, fileName string) (string, error)
- func GetUploadFileWithNotExpire(ctx context.Context, fileName string) (string, error)
- func InitAssistant(ctx context.Context, cfg Config, initBucketName string) error
- func InitCustom(ctx context.Context, cfg Config) error
- func InitFileUpload(ctx context.Context, cfg Config) error
- func InitKnowledge(ctx context.Context, cfg Config, initBucketName string, public bool) error
- func InitSafety(ctx context.Context, cfg Config, initBucketName string) error
- func Knowledge() *client
- func Safety() *client
- func SplitFilePath(filePath string) (bucketName string, objectName string, fileName string)
- func UploadFile(ctx context.Context, bucketName string, dir string, fileName string, ...) (string, int64, error)
- func UploadFileCommon(ctx context.Context, reader io.Reader, fileType string, objectSize int64, ...) (string, int64, error)
- func UploadFileCommonWithExpire(ctx context.Context, reader io.Reader, fileType string, objectSize int64) (string, int64, error)
- func UploadFileCommonWithNotExpire(ctx context.Context, reader io.Reader, fileType string, objectSize int64) (string, int64, error)
- type Config
Constants ¶
This section is empty.
Variables ¶
View Source
var ( BucketFileUpload = "file-upload" DirFileExpire = "file-expire" DirFileNotExpire = "file-not-expire" StoreExpireDays = 1 )
View Source
var (
BucketCustom = "custom-upload"
)
Functions ¶
func DeleteFileCommon ¶
func DownloadFileToMemory ¶ added in v0.1.5
func FileUpload ¶
func FileUpload() *client
func GetUploadFileCommon ¶
func GetUploadFileWithExpire ¶
func InitAssistant ¶
func InitKnowledge ¶
func InitSafety ¶ added in v0.1.5
func SplitFilePath ¶ added in v0.1.5
func UploadFile ¶
func UploadFileCommon ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.