2019-04-19 04:43:36 +00:00
|
|
|
package needle_map
|
2017-05-27 05:51:25 +00:00
|
|
|
|
2018-07-08 09:28:04 +00:00
|
|
|
import (
|
2019-09-02 10:28:40 +00:00
|
|
|
. "github.com/joeslay/seaweedfs/weed/storage/types"
|
2018-07-08 09:28:04 +00:00
|
|
|
)
|
|
|
|
|
2017-05-27 05:51:25 +00:00
|
|
|
type NeedleValueMap interface {
|
2018-07-08 09:28:04 +00:00
|
|
|
Set(key NeedleId, offset Offset, size uint32) (oldOffset Offset, oldSize uint32)
|
|
|
|
Delete(key NeedleId) uint32
|
|
|
|
Get(key NeedleId) (*NeedleValue, bool)
|
2019-05-19 05:46:24 +00:00
|
|
|
AscendingVisit(visit func(NeedleValue) error) error
|
2017-05-27 05:51:25 +00:00
|
|
|
}
|