Versions in this module Expand all Collapse all v0 v0.0.1 Jul 22, 2023 Changes in this version + const Asc + const Desc + func IsContentTypeSupported(c ContentType) bool + type Body = *[]byte + type ContentLength = int64 + type ContentType = string + const ImageJpeg + const ImageJpg + const ImagePng + const ImageWebp + const VideoMkv + const VideoMp4 + type DerivedMedia struct + Body Body + ContentLength ContentLength + ContentType ContentType + CreatedAt time.Time + UpdatedAt time.Time + type DownloadResponse struct + Body io.ReadCloser + ContentLength int64 + ContentType ContentType + type FileInfo struct + ContentLength ContentLength + ContentType ContentType + type FileStorer interface + Copy func(src, dst Path) error + Delete func(p Path) error + Download func(p Path) (*DownloadResponse, error) + DownloadArchive func(p []Path) (Body, error) + Move func(src, dst Path) error + ReadMany func(p Path) ([]FileInfo, error) + ReadOne func(p Path) (*FileInfo, error) + SpaceUsage func() (float64, error) + Upload func(in UploadInput) error + type Media struct + Body Body + ContentLength ContentLength + ContentType ContentType + CreatedAt time.Time + DerivedMedias []DerivedMedia + EmbeddedMetadata Metadata + Tags []Tag + UpdatedAt time.Time + type Metadata map[string]string + type Path struct + Path string + func NewPath(path string) Path + func (p *Path) AppendSuffix(suffix string) Path + func (p *Path) BasePath() Path + func (p *Path) Basename() string + func (p *Path) Dir() string + func (p *Path) Extension() string + func (p *Path) Filename() string + func (p *Path) SetDir(dir string) Path + func (p *Path) SetExtension(ext string) Path + func (p *Path) ToString() string + func (p *Path) Uuid() string + type PathFactory struct + func (f *PathFactory) BuildDerivedMedisPath(m Media) Path + type ReadManyInput struct + Asc bool + Limit int + Offset int + Path Path + SortBy string + type SortBy = map[string]string + type Storer interface + Delete func(path Path) error + ReadMany func(in ReadManyInput) ([]Media, error) + ReadOne func(path Path) (*Media, error) + Save func(media *Media) error + type Tag struct + ConfidenceScore float32 + Provider string + Value string + type UploadInput struct + Body io.Reader + ContentLength ContentLength + ContentType ContentType + Path Path