diff options
author | Gabriel Arakaki Giovanini <mail@gabrielgio.me> | 2022-10-16 19:13:41 +0200 |
---|---|---|
committer | Gabriel Arakaki Giovanini <mail@gabrielgio.me> | 2022-10-16 19:16:35 +0200 |
commit | eb1b7d7d9149114eb6b4287b7cb40c49dccfb26e (patch) | |
tree | 12f797651abeda9512d56d8922199ae9edb2a293 /storage/storage.go | |
parent | 98844247a424558939228b82e9b5f28d723c4fe0 (diff) | |
download | porg-master.tar.gz porg-master.tar.bz2 porg-master.zip |
With this is easier to interact with storage layers.
Diffstat (limited to 'storage/storage.go')
-rw-r--r-- | storage/storage.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/storage/storage.go b/storage/storage.go index b788efb..880396a 100644 --- a/storage/storage.go +++ b/storage/storage.go @@ -17,6 +17,12 @@ const ( type Storage interface { Walk(path string, walkMode WalkMode) <-chan string Get(path string) (io.Reader, error) + Put(path string, f io.Reader) error + List(path string) ([]string, error) + Move(src string, dest string) error + Copy(src string, dest string) error + Mkdir(path string) error + Exists(path string) (bool, error) } func CalculateSHA256(r io.Reader) (string, error) { |