Versions in this module Expand all Collapse all v1 v1.2.0 Jul 2, 2023 Changes in this version + type PresignUploadConfig struct + ContentType string + ExpiredTime *time.Time + FilePath string + Filename string + MaxSizeUpload uint64 + MinSizeUpload uint64 type StorageBase + func (base *StorageBase) PreSignGetFiles(storageType, storagePath, filename string) (presignUrl string, err error) + func (base *StorageBase) PresignUploadFiles(presignConfig PresignUploadConfig) (formData interface{}, err error) v1.0.0 Sep 4, 2022 Changes in this version + const ContentTypeGIF + const ContentTypeJPEG + const ContentTypeJPG + const ContentTypeJXL + const ContentTypePNG + func AvailableImageSize(width int64, height int64) (isAvailable bool) + func GetImageDimensions(imageSize string) (width int64, height int64, isValid bool, err error) + type FileData struct + ContentType string + Extension string + Filename string + ImageFile image.Image + IsImage bool + StoragePath string + type GCSSetup struct + BucketName string + CredentialPath string + FilePath string + ProjectID string + Region string + TimeOut string + type S3Setup struct + AccessKey string + BucketName string + FilePath string + Region string + SecretKey string + type StorageBase struct + NonScaledTypes string + func NewStorageBase(fileHeader *multipart.FileHeader, fileType string) *StorageBase + func (base *StorageBase) GetFiles(storageType, storagePath, filename string) (files *os.File, err error) + func (base *StorageBase) SetAwsS3(s3Setup *S3Setup) *StorageBase + func (base *StorageBase) SetGoogleGCS(gcsSetup *GCSSetup) *StorageBase + func (base *StorageBase) UploadFiles() (storageModel *StorageData, err error) + type StorageData struct + Filename string + Mime string + OriginalFilename string + Path string + Type string