16 lines
328 B
Go
16 lines
328 B
Go
package utils
|
|
|
|
type DBObject interface {
|
|
GetName() string
|
|
Deserialize(j map[string]interface{}) DBObject
|
|
GetAccessor() Accessor
|
|
}
|
|
|
|
type Accessor interface {
|
|
SetLogger()
|
|
LoadOne(id string) DBObject
|
|
DeleteOne(id string) DBObject
|
|
StoreOne(data DBObject) DBObject
|
|
UpdateOne(set map[string]interface{}, id string) DBObject
|
|
}
|