Documentation ¶
Index ¶
- Constants
- func FolderExistOrCreate(path string) error
- func GetLink(ctx context.Context, fileName string, userId uint32) (link string, err error)
- func GetLocalPath(ctx context.Context, fileName string) string
- func IsExist(filePath string) (bool, error)
- func IsFileExist(ctx context.Context, fileName string) (bool, error)
- func ParseFont(fontFile string) (f *truetype.Font, err error)
- type FSStorage
- func (f FSStorage) GetLink(ctx context.Context, fileName string) (string, error)
- func (f FSStorage) GetLocalPath(ctx context.Context, fileName string) string
- func (f FSStorage) IsFileExist(ctx context.Context, fileName string) (bool, error)
- func (f FSStorage) Upload(ctx context.Context, fileName string, content io.Reader) (output *PutObjectOutput, err error)
- type PutObjectOutput
Constants ¶
View Source
const ( StorageType = "fs" SystemStartPath = "/tmp" SystemBaseUrl = "http://localhost/" )
Variables ¶
This section is empty.
Functions ¶
func FolderExistOrCreate ¶
FolderExistOrCreate 检查目录是否存在, 如果不存在就创建 递归创建目录
Types ¶
type FSStorage ¶
type FSStorage struct { }
TODO: context 应当使用飞行记录器记录,如果要使用,请将 go version 更新到 22.1.0 以上版本
func (FSStorage) GetLocalPath ¶
func (FSStorage) IsFileExist ¶
Click to show internal directories.
Click to hide internal directories.