ram

package
v0.0.0-...-91a69d6 Latest Latest
Warning

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

Go to latest
Published: Feb 23, 2025 License: 0BSD Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Address

type Address string

type Any

type Any struct {
	// contains filtered or unexported fields
}

func NewAny

func NewAny(val any) Any

type Bool

type Bool via.Any[BoolProxy]

func NewBool

func NewBool[T ~bool](val T) Bool

func (Bool) Bool

func (b Bool) Bool() bool

type BoolProxy

type BoolProxy interface {
	via.API
}

type Int

type Int via.Any[IntProxy]

func NewInt

func NewInt[T ~int8 | ~int16 | ~int32 | ~int64 | ~int](val T) Int

func (Int) Int64

func (i Int) Int64() int64

func (*Int) Set

func (i *Int) Set(val Int)

type IntProxy

type IntProxy interface {
	via.API

	Int64(via.CachedState) int64
	Set(via.CachedState, Int) Int
	Add(via.CachedState, Int) Int
}

type Map

type Map[K comparable, V any] via.Any[MapProxy[K, V]]

func MapInMemory

func MapInMemory[K comparable, V any](m map[K]V) Map[K, V]

func (Map[K, V]) Index

func (m Map[K, V]) Index(key K) V

func (Map[K, V]) SetIndex

func (m Map[K, V]) SetIndex(key K, val V)

type MapProxy

type MapProxy[K comparable, V any] interface {
	via.API

	Index(via.CachedState, K) (V, bool)
	SetIndex(via.CachedState, K, V)
	Delete(via.CachedState, K)
	Clear(via.CachedState)
	Iter(via.CachedState) iter.Seq2[K, V]
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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