This repository has been archived on 2023-12-05. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
protect_trans_info/adapters/inmemorycache/cache.go
2023-08-24 23:40:46 +03:00

12 lines
188 B
Go

package inmemorycache
type Cache map[uint64][]string
func (c Cache) Get(id uint64) []string {
return c[id]
}
func (c Cache) Append(id uint64, ip string) {
c[id] = append(c[id], ip)
}