MCPcopy
hub / github.com/Place1/wg-access-server / Storage

Interface Storage

internal/storage/contracts.go:12–21  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

10)
11
12type Storage interface {
13 Watcher
14 Save(device *Device) error
15 List(owner string) ([]*Device, error)
16 Get(owner string, name string) (*Device, error)
17 GetByPublicKey(publicKey string) (*Device, error)
18 Delete(device *Device) error
19 Close() error
20 Open() error
21}
22
23type Watcher interface {
24 OnAdd(cb Callback)

Callers 26

RunMethod · 0.95
SetSessionFunction · 0.65
ClearSessionFunction · 0.65
SaveDeviceMethod · 0.65
SaveMethod · 0.65
RunMethod · 0.95
ListAllDevicesMethod · 0.65
ListDevicesMethod · 0.65
GetSessionFunction · 0.65
SetSessionFunction · 0.65
ClearSessionFunction · 0.65
LookupMethod · 0.65

Implementers 2

SQLStorageinternal/storage/sql.go
InMemoryStorageinternal/storage/inmemory.go

Calls

no outgoing calls

Tested by

no test coverage detected