Documentation ¶
Index ¶
- func BareFilename(filename string) string
- func Base64ToUrlSafe(b64 string) string
- func ByteSizeStr(b int64) string
- func CacheGet[T any](cache *freecache.Cache, sf *singleflight.Group, key string, ...) (T, error)
- func CalcContentMD5(reader io.Reader) (string, error)
- func CalcFileContentMD5(filename string) (string, error)
- func CalcMultipartFileHeaderContentMD5(fh *multipart.FileHeader) (string, error)
- func ChangeExtname(filename, extname string) string
- func CmdExist(cmd string) bool
- func Coalesce[T comparable](s ...T) T
- func Contains[T comparable](item T, list []T) bool
- func Convert[T, R any](inputs []T, fn func(T) (R, error)) ([]R, error)
- func CopyFile(src, dst string) error
- func FileExist(path string) bool
- func Map[T, R any](inputs []T, fn func(T) R) []R
- func MustParseInt64(s string) int64
- func RandString(length int) string
- type FileInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BareFilename ¶
func Base64ToUrlSafe ¶
func ByteSizeStr ¶
func CalcFileContentMD5 ¶
func CalcMultipartFileHeaderContentMD5 ¶
func CalcMultipartFileHeaderContentMD5(fh *multipart.FileHeader) (string, error)
func ChangeExtname ¶
func Coalesce ¶
func Coalesce[T comparable](s ...T) T
func Contains ¶
func Contains[T comparable](item T, list []T) bool
func MustParseInt64 ¶
func RandString ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.