Documentation
¶
Index ¶
- type FileSystem
- func (fs *FileSystem) Create(fullpath string, data []byte) error
- func (fs *FileSystem) CreateOrUpdate(fullpath string, data []byte) error
- func (fs *FileSystem) Delete(fullpath string) error
- func (fs *FileSystem) Get(fullpath string) ([]byte, error)
- func (fs *FileSystem) GetRoot() string
- func (fs *FileSystem) List(fullpath string) ([]string, error)
- func (fs *FileSystem) Update(fullpath string, data []byte) error
- type S3
- func (store *S3) Create(fullpath string, data []byte) error
- func (store *S3) Delete(fullpath string) error
- func (store *S3) Get(fullpath string) ([]byte, error)
- func (store *S3) GetRoot() string
- func (store *S3) List(fullpath string) ([]string, error)
- func (store *S3) Update(fullpath string, data []byte) error
- type Storer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FileSystem ¶
func NewFileSystem ¶
func NewFileSystem(env string) *FileSystem
NewFileSystem is constructor for FileSystem
func (*FileSystem) Create ¶
func (fs *FileSystem) Create(fullpath string, data []byte) error
Create saves JSON data with fullpath as key.
func (*FileSystem) CreateOrUpdate ¶
func (fs *FileSystem) CreateOrUpdate(fullpath string, data []byte) error
func (*FileSystem) Delete ¶
func (fs *FileSystem) Delete(fullpath string) error
Delete removes item with fullpath as key.
func (*FileSystem) Get ¶
func (fs *FileSystem) Get(fullpath string) ([]byte, error)
Get returns JSON data with fullpath as key.
type S3 ¶
type S3 struct {
Env string
AccessKey string
SecretKey string
RegionName string
BucketName string
Root string
Region goamz_aws.Region
Connection *goamz_s3.S3
Bucket *goamz_s3.Bucket
}
Click to show internal directories.
Click to hide internal directories.