type

BoundTypedCollection

type BoundTypedCollection[Document, Create, Update any] struct { definition TypedCollection[Document, Create, Update] local *LocalAPI }

Typed Create, Import, Find, List, Update, UpdateRevision, and Delete methods.

Source core/typed_local.go:35

Create(ctx, input, actor)(Document, error)
Validate and create a typed document.
Import(ctx, input, options, actor)(Document, error)
Import a typed document while preserving migration metadata.
Find(ctx, id, actor)(Document, error)
Read and JSON-decode one document into the generated model.
List(ctx, options)(TypedPage[Document], error)
List and JSON-decode a typed page into generated models.
Update(ctx, id, input, actor)(Document, error)
Apply a typed partial update.
UpdateRevision(ctx, id, input, expectedRevision, actor)(Document, error)
Update only when the expected revision still matches.
Delete(ctx, id, actor)(Document, error)
Delete through the ordinary access-controlled operation pipeline.

Inputs and outputs cross the same operation engine as untyped LocalAPI. JSON conversion reports incompatible field types; unknown stored fields are ignored and absent model fields keep their Go zero values. The wrapper does not create a second runtime.

Methods