Add decrypt, refactor
This commit is contained in:
parent
83ea81d8c3
commit
30ab03b7b7
37 changed files with 2572 additions and 1046 deletions
21
backend/interface.go
Normal file
21
backend/interface.go
Normal file
|
@ -0,0 +1,21 @@
|
|||
package backend
|
||||
|
||||
type Type string
|
||||
|
||||
const (
|
||||
Blob Type = "blob"
|
||||
Key = "key"
|
||||
Lock = "lock"
|
||||
Snapshot = "snapshot"
|
||||
Tree = "tree"
|
||||
)
|
||||
|
||||
type Server interface {
|
||||
Create(Type, []byte) (ID, error)
|
||||
Get(Type, ID) ([]byte, error)
|
||||
List(Type) (IDs, error)
|
||||
Test(Type, ID) (bool, error)
|
||||
Remove(Type, ID) error
|
||||
|
||||
Location() string
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue