orderctxstore

package
v0.14.1 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2026 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Compact

func Compact[T any](orders map[string]T, limit int, updatedAt func(T) time.Time)

Compact keeps only the newest limit contexts according to updatedAt.

func Load

func Load[T any](path string, dst map[string]T, limit int, updatedAt func(T) time.Time) error

Load reads persisted order contexts from path into dst and compacts to limit. It returns nil when the file does not exist.

func Persist

func Persist[T any](path string, src map[string]T) error

Persist atomically writes order contexts to disk.

Types

This section is empty.

Jump to

Keyboard shortcuts

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