types

package
v0.8.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 25, 2025 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Keyed

type Keyed interface {
	MapKey() uint64
	ShardKey() uint64
}

Keyed defines a unique key and a precomputed shard key for the value.

type Sized

type Sized interface {
	Weight() int64
}

Sized provides memory usage accounting for cache entries.

type SizedBox

type SizedBox[T any] struct {
	Value        T
	CalcWeightFn func(s *SizedBox[T]) int64
}

func (*SizedBox[T]) Weight

func (s *SizedBox[T]) Weight() int64

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL