Documentation
¶
Index ¶
- type ImageUpload
- func (h *ImageUpload) CleanupImageOnFailure(imagePath string)
- func (h *ImageUpload) EnsureUploadDirectory(uploadDir string) error
- func (h *ImageUpload) ProcessImageUpload(c echo.Context, uploadDir string, file *multipart.FileHeader, isDocument bool) (string, error)
- func (h *ImageUpload) SaveUploadedFile(file *multipart.FileHeader, dst string) error
- type ImageUploads
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ImageUpload ¶
type ImageUpload struct {
// contains filtered or unexported fields
}
func (*ImageUpload) CleanupImageOnFailure ¶
func (h *ImageUpload) CleanupImageOnFailure(imagePath string)
func (*ImageUpload) EnsureUploadDirectory ¶
func (h *ImageUpload) EnsureUploadDirectory(uploadDir string) error
func (*ImageUpload) ProcessImageUpload ¶
func (h *ImageUpload) ProcessImageUpload(c echo.Context, uploadDir string, file *multipart.FileHeader, isDocument bool) (string, error)
func (*ImageUpload) SaveUploadedFile ¶
func (h *ImageUpload) SaveUploadedFile(file *multipart.FileHeader, dst string) error
type ImageUploads ¶
type ImageUploads interface {
EnsureUploadDirectory(uploadDir string) error
ProcessImageUpload(c echo.Context, uploadDir string, file *multipart.FileHeader, isDocument bool) (string, error)
CleanupImageOnFailure(imagePath string)
SaveUploadedFile(file *multipart.FileHeader, dst string) error
}
func NewImageUpload ¶
func NewImageUpload(logger logger.LoggerInterface) ImageUploads
Click to show internal directories.
Click to hide internal directories.