node-api/apps/drivers/types.go
Adam Štrauch bc50cb1105
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/pr Build is passing
Support for snapshots
* full implementation of snapshots
* tests of the snapshot backend
* Drone CI pipeline
* New snapshots handlers
* Filesystem driver
* S3 driver
2021-10-26 18:57:52 +02:00

23 lines
616 B
Go

package drivers
// DriverInterface defined methods every storage driver needs to implement
type DriverInterface interface {
// Create creates a new object in the storage from given file name
Create(key string, filePath string) error
// Write writes content of body into key
Write(key string, body []byte) error
// Get returns content of given key
Get(key string, filePath string) error
// Read returns content of given key
Read(key string) ([]byte, error)
// List returns list of objects in fiven prefix
List(prefix string) ([]string, error)
// Delete deletes one object
Delete(key string) error
}