Documentation ¶
Index ¶
- type CosUploader
- func (s *CosUploader) Content(name string) ([]byte, error)
- func (s *CosUploader) Exists(name string) (bool, error)
- func (s *CosUploader) GetEngineName() string
- func (s *CosUploader) GetFullUrl(name string) string
- func (s *CosUploader) List(dir string) ([]File, error)
- func (s *CosUploader) Mkdir(dir string) error
- func (s *CosUploader) Remove(name string) error
- func (s *CosUploader) Rename(oldname, newname string) error
- func (s *CosUploader) Rmdir(dir string) error
- func (s *CosUploader) Upload(storageName string, LocalFile io.Reader) (string, error)
- type File
- type FileUploader
- func (s *FileUploader) Content(name string) ([]byte, error)
- func (s *FileUploader) Exists(name string) (bool, error)
- func (s *FileUploader) GetEngineName() string
- func (s *FileUploader) GetFullUrl(name string) string
- func (s *FileUploader) List(dir string) ([]File, error)
- func (s *FileUploader) Mkdir(dir string) error
- func (s *FileUploader) Remove(name string) error
- func (s *FileUploader) Rename(oldname, newname string) error
- func (s *FileUploader) Rmdir(dir string) error
- func (s *FileUploader) Upload(storageName string, LocalFile io.Reader) (string, error)
- type FtpUploader
- func (s *FtpUploader) Content(name string) ([]byte, error)
- func (s *FtpUploader) Exists(name string) (bool, error)
- func (s *FtpUploader) GetEngineName() string
- func (s *FtpUploader) GetFullUrl(name string) string
- func (s *FtpUploader) List(dir string) ([]File, error)
- func (s *FtpUploader) Mkdir(dir string) (err error)
- func (s *FtpUploader) Remove(name string) error
- func (s *FtpUploader) Rename(oldname, newname string) error
- func (s *FtpUploader) Rmdir(dir string) error
- func (s *FtpUploader) Upload(storageName string, LocalFile io.Reader) (string, error)
- type OssUploader
- func (s *OssUploader) Content(name string) ([]byte, error)
- func (s *OssUploader) Exists(name string) (bool, error)
- func (s *OssUploader) GetEngineName() string
- func (s *OssUploader) GetFullUrl(name string) string
- func (s *OssUploader) List(dir string) ([]File, error)
- func (s *OssUploader) Mkdir(dir string) error
- func (s *OssUploader) Remove(name string) error
- func (s *OssUploader) Rename(oldname, newname string) error
- func (s *OssUploader) Rmdir(dir string) error
- func (s *OssUploader) Upload(storageName string, LocalFile io.Reader) (string, error)
- type Uploader
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CosUploader ¶
type CosUploader struct { *cos.Client // contains filtered or unexported fields }
func NewCosUploader ¶
func NewCosUploader(config map[string]string) *CosUploader
func (*CosUploader) GetEngineName ¶
func (s *CosUploader) GetEngineName() string
func (*CosUploader) GetFullUrl ¶
func (s *CosUploader) GetFullUrl(name string) string
func (*CosUploader) Mkdir ¶
func (s *CosUploader) Mkdir(dir string) error
func (*CosUploader) Remove ¶
func (s *CosUploader) Remove(name string) error
func (*CosUploader) Rename ¶
func (s *CosUploader) Rename(oldname, newname string) error
func (*CosUploader) Rmdir ¶
func (s *CosUploader) Rmdir(dir string) error
type FileUploader ¶
type FileUploader struct {
// contains filtered or unexported fields
}
func NewFileUploader ¶
func NewFileUploader(opt map[string]string) *FileUploader
func (*FileUploader) GetEngineName ¶
func (s *FileUploader) GetEngineName() string
func (*FileUploader) GetFullUrl ¶
func (s *FileUploader) GetFullUrl(name string) string
func (*FileUploader) Mkdir ¶
func (s *FileUploader) Mkdir(dir string) error
func (*FileUploader) Remove ¶
func (s *FileUploader) Remove(name string) error
func (*FileUploader) Rename ¶
func (s *FileUploader) Rename(oldname, newname string) error
func (*FileUploader) Rmdir ¶
func (s *FileUploader) Rmdir(dir string) error
type FtpUploader ¶
func NewFtpUploader ¶
func NewFtpUploader(opt map[string]string) *FtpUploader
func (*FtpUploader) GetEngineName ¶
func (s *FtpUploader) GetEngineName() string
func (*FtpUploader) GetFullUrl ¶
func (s *FtpUploader) GetFullUrl(name string) string
func (*FtpUploader) Mkdir ¶
func (s *FtpUploader) Mkdir(dir string) (err error)
func (*FtpUploader) Remove ¶
func (s *FtpUploader) Remove(name string) error
func (*FtpUploader) Rename ¶
func (s *FtpUploader) Rename(oldname, newname string) error
func (*FtpUploader) Rmdir ¶
func (s *FtpUploader) Rmdir(dir string) error
type OssUploader ¶
type OssUploader struct {
// contains filtered or unexported fields
}
func NewOssUploader ¶
func NewOssUploader(config map[string]string) *OssUploader
func (*OssUploader) GetEngineName ¶
func (s *OssUploader) GetEngineName() string
func (*OssUploader) GetFullUrl ¶
func (s *OssUploader) GetFullUrl(name string) string
func (*OssUploader) Mkdir ¶
func (s *OssUploader) Mkdir(dir string) error
func (*OssUploader) Remove ¶
func (s *OssUploader) Remove(name string) error
func (*OssUploader) Rename ¶
func (s *OssUploader) Rename(oldname, newname string) error
func (*OssUploader) Rmdir ¶
func (s *OssUploader) Rmdir(dir string) error
type Uploader ¶
type Uploader interface { Upload(storageName string, LocalFile io.Reader) (string, error) List(dir string) (list []File, err error) Exists(name string) (bool, error) GetFullUrl(name string) string Remove(name string) error GetEngineName() string Content(string) ([]byte, error) Rename(string, string) error Mkdir(string) error Rmdir(string) error }
Click to show internal directories.
Click to hide internal directories.