Documentation ¶
Index ¶
- Constants
- type Config
- type FileInfo
- type PublicLinkResponse
- type S3
- func (s *S3) Delete(ctx context.Context, fileId string) error
- func (s *S3) Download(ctx context.Context, fileId, path string) (*os.File, error)
- func (s *S3) DownloadAsBase64(ctx context.Context, fileId string) (string, error)
- func (s *S3) FileInfo(ctx context.Context, fileId string) (FileInfo, error)
- func (s *S3) GetFileExt(nameWithExt string) string
- func (s *S3) PublicLink(ctx context.Context, fileId string, publicLinkExpiration time.Duration) (PublicLinkResponse, error)
- func (s *S3) SanitizeFileName(nameWithoutExt string) string
- func (s *S3) Upload(ctx context.Context, file io.ReadSeeker, name, ext string) (FileInfo, error)
- func (s *S3) UploadFromBase64(ctx context.Context, base64String, name, ext string) (FileInfo, error)
Constants ¶
View Source
const DefaultPublicLinkExpiration = 30 * time.Minute
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PublicLinkResponse ¶
type S3 ¶
type S3 struct {
// contains filtered or unexported fields
}
func (*S3) DownloadAsBase64 ¶ added in v1.1.0
func (*S3) GetFileExt ¶ added in v1.1.1
func (*S3) PublicLink ¶
func (*S3) SanitizeFileName ¶ added in v1.1.1
Click to show internal directories.
Click to hide internal directories.