vain/storage.go
Stephen McQuay (smcquay) c575677088
Use in-memory, on-disk-backed DB
- removed sqlite
- added stubs for MemDB
- removed sqlite3 vendor

Fixes #7

Change-Id: I97b7f274be8db5ff02d9a4e4b8f616403fd6313a
2016-06-25 13:37:23 -07:00

19 lines
406 B
Go

package vain
import "time"
// Storer defines the db interface.
type Storer interface {
NSForToken(ns namespace, tok Token) error
Package(path string) (Package, error)
AddPackage(p Package) error
RemovePackage(pth path) error
PackageExists(pth path) bool
Pkgs() []Package
Register(e Email) (Token, error)
Confirm(tok Token) (Token, error)
Forgot(e Email, window time.Duration) (Token, error)
}