Documentation
¶
Index ¶
- func New(opt *Option) (driver.FS, error)
- type Option
- type S3
- func (d *S3) Copy(ctx context.Context, src, dst string) error
- func (d *S3) Create(path string) (driver.FileWriter, error)
- func (d *S3) Get(ctx context.Context, path string) (driver.File, error)
- func (d *S3) List(ctx context.Context, path string, metas ...driver.Meta) ([]driver.File, error)
- func (d *S3) MakeDir(ctx context.Context, path string) error
- func (d *S3) Move(ctx context.Context, src, dst string) error
- func (d *S3) Open(path string) (driver.FileReader, error)
- func (d *S3) Remove(ctx context.Context, path string) error
- func (d *S3) Rename(ctx context.Context, path, newName string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Option ¶
type Option struct {
base.Option
Endpoint string `json:"endpoint" validate:"required"`
Bucket string `json:"bucket" validate:"required"`
Region string `json:"region"`
AccessKey string `json:"access_key"`
SecretKey string `json:"secret_key" validate:"required_with=AccessKey"`
SessionToken string `json:"session_token"`
ListVersion string `json:"list_version" validate:"omitempty,oneof=v1 v2"`
ForcePathStyle bool `json:"force_path_style"`
}
Click to show internal directories.
Click to hide internal directories.