Updated interfaces and added EntryID Hash
This commit is contained in:
@@ -5,13 +5,14 @@ import (
|
||||
)
|
||||
|
||||
type EntryStore interface {
|
||||
Put(ctx context.Context, id EntryID, canonical []byte) error
|
||||
Get(ctx context.Context, id EntryID) ([]byte, error)
|
||||
Has(ctx context.Context, id EntryID) (bool, error)
|
||||
Store(ctx context.Context, entry Entry) error
|
||||
Load(ctx context.Context, id EntryID) (Entry, error)
|
||||
Exists(ctx context.Context, id EntryID) (bool, error)
|
||||
Delete(ctx context.Context, id EntryID) error
|
||||
}
|
||||
|
||||
type ReferenceStore interface {
|
||||
GetRef(ctx context.Context, name string) (EntryID, bool, error)
|
||||
SetRef(ctx context.Context, name string, entryID EntryID) (bool, error)
|
||||
RemoveRef(ctx context.Context, name string) error
|
||||
Set(ctx context.Context, name string, entryID EntryID) error
|
||||
Get(ctx context.Context, name string) (EntryID, error)
|
||||
Delete(ctx context.Context, name string) error
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user