Versions in this module Expand all Collapse all v0 v0.0.1 Nov 13, 2026 Changes in this version + const StateCount + func Hold[T any](sc *Scope, h Handle[T]) + func RegisterChild[P, C any](s *Server) + type BuiltinLoader interface + Builtin func(key Key) bool + type DecodeContext struct + Key Key + type DepRef struct + func Dep[T any](ctx *DecodeContext, path string) DepRef[T] + type Event struct + Err error + ID ID + Key Key + Kind EventKind + type EventKind uint8 + const EventFailed + const EventLoaded + const EventModified + const EventUnloaded + type Events struct + func (e *Events) All() iter.Seq[Event] + func (e *Events) Len() int + func (e *Events) Of(t TypeID) iter.Seq[Event] + type FinishContext struct + Key Key + type Handle struct + func AddChild[C any](ctx *FinishContext, sub string, v C) Handle[C] + func HandleOf[T any](r Ref) Handle[T] + func LoadSync[T any](sc *Scope, key string) (Handle[T], error) + func Load[T any](sc *Scope, key string) Handle[T] + func Resolve[T any](ctx *FinishContext, d DepRef[T]) Handle[T] + func (h Handle[T]) Index() uint32 + func (h Handle[T]) IsZero() bool + func (h Handle[T]) Ref() Ref + type ID struct + Gen uint32 + Index uint32 + Type TypeID + type Key struct + Path string + Sub string + func ParseKey(s string) Key + func (k Key) String() string + type Loader interface + Decode func(ctx *DecodeContext, data []byte) (D, error) + Finish func(ctx *FinishContext, d D) (T, error) + Unload func(v *T) + type Options struct + CommitBudget time.Duration + FS fs.FS + KeepAlive int64 + OnError func(err error) + StrictHandles bool + WatchInterval time.Duration + Workers int + type Ref struct + func (r Ref) Index() uint32 + func (r Ref) IsZero() bool + type Scope struct + func (sc *Scope) Done() bool + func (sc *Scope) Err() error + func (sc *Scope) Name() string + func (sc *Scope) Progress() (ready, total int) + func (sc *Scope) Release() + type Server struct + func NewServer(opts Options) *Server + func (s *Server) Changed(paths ...string) + func (s *Server) Close() + func (s *Server) Global() *Scope + func (s *Server) NewScope(name string) *Scope + func (s *Server) Stats() Stats + func (s *Server) Update() *Events + type State uint8 + const Decoding + const Failed + const Missing + const Queued + const Ready + const Waiting + func (s State) String() string + type Stats struct + Bytes int64 + IdleBytes int64 + InFlight int + Parked int + Queued int + StaleHits uint64 + States [StateCount]int + Types []TypeStats + type Store struct + func Register[T, D any](s *Server, l Loader[T, D], placeholder T) *Store[T] + func StoreOf[T any](s *Server) *Store[T] + func (s *Store[T]) All() iter.Seq2[Handle[T], *T] + func (s *Store[T]) Err(h Handle[T]) error + func (s *Store[T]) Get(h Handle[T]) *T + func (s *Store[T]) ID(h Handle[T]) ID + func (s *Store[T]) Key(h Handle[T]) Key + func (s *Store[T]) Len() int + func (s *Store[T]) Lookup(h Handle[T]) (*T, State) + func (s *Store[T]) Ready(h Handle[T]) bool + func (s *Store[T]) Version(h Handle[T]) uint32 + type TypeID uint16 + func TypeIDOf[T any](s *Server) TypeID + type TypeStats struct + Bytes int64 + IdleBytes int64 + Name string + States [StateCount]int + Type TypeID