first draft of an accounts interface

This commit is contained in:
A.Unger
2020-02-03 19:47:05 +01:00
parent 4b595b4b07
commit eef2de244f
+17
View File
@@ -0,0 +1,17 @@
package accounts
// Account is an accounts service interface
type Account interface {
// Read a record
Read(key string) (*Record, error)
// Write a record
Write(Record) Record
// List all records
List() []*Record
}
// Record is an entry in the account storage
type Record struct {
Key string
Value []byte
}