feat(lru): change string to proto.KeyBase
This commit is contained in:
parent
d08e50f4ce
commit
f9ad4d914e
|
@ -1,6 +1,7 @@
|
|||
package lru
|
||||
|
||||
import (
|
||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
||||
"gitee.com/timedb/wheatCache/pkg/structure"
|
||||
"sync"
|
||||
)
|
||||
|
@ -26,7 +27,8 @@ const (
|
|||
|
||||
type CacheInterface interface {
|
||||
Del() error
|
||||
Get(key string) (structure.KeyBaseInterface, bool)
|
||||
Add(key string, val structure.KeyBaseInterface)
|
||||
Get(key *proto.BaseKey) (structure.KeyBaseInterface, bool)
|
||||
Add(key *proto.BaseKey, val structure.KeyBaseInterface)
|
||||
UpdateLruSize(length structure.UpdateLength)
|
||||
}
|
||||
DelByKey(key *proto.BaseKey) error
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue