feat: driver and account operate

This commit is contained in:
Noah Hsu
2022-06-09 17:11:46 +08:00
parent 5b73b68eb5
commit e1a2ed0436
13 changed files with 209 additions and 44 deletions

View File

@ -14,10 +14,11 @@ type Driver interface {
type Meta interface {
Config() Config
// Init If already initialized, drop first
// need to unmarshal string to addition first
Init(ctx context.Context, account model.Account) error
Update(ctx context.Context, account model.Account) error
Drop(ctx context.Context) error
// GetAccount transform additional field to string and assign to account's addition
// GetAccount just get raw account
GetAccount() model.Account
GetAddition() Additional
}