~/bend-docscommunity

snapshot_data.bend checks

raw source on the hub · import bendvy-ecs-core@0.1.0.3/snapshot_data.bend as Snapshot_data

8 imports
import Base
import ./execution_lifecycle_notices.bend as Notice
import ./clock_state.bend as Clock
import entity_key.bend as Key
import entity_allocator.bend as Alloc
import ./world.bend as W
import ./decode_data.bend as D
import ./deferred_command.bend as Deferred

Types

type Entity source · line 11 · raw

Data

Basic detached Data only; runtime checkpoint state is intentionally not encoded.

type Snapshot source · line 13 · raw

Data

type Outcome source · line 18 · raw

@A:Data -> Data

Ordinary save either exports detached Data or refuses pending structural work. Refusal returns the same World separately; it does not execute or discard work.

Templates

template pending_ready source · line 22 · raw

@-World:Type -> @pending:List<&1, 0x704c77730661eff4309838fc738ef615/deferred_command.Command<World>> -> Pair(List<&1, 0x704c77730661eff4309838fc738ef615/deferred_command.Command<World>>, Bool)

template ready_joined source · line 26 · raw

@-S:Data -> @-C:Type -> @-R:Type -> @-E:Data -> @namespace:U32 -> @allocator:0x704c77730661eff4309838fc738ef615/entity_allocator.Allocator -> @store:C -> @resource:R -> @events:List<&2, E> -> @registrations:List<&2, 0x704c77730661eff4309838fc738ef615/world.RegistrationMeta> -> @nextSystemId:U32 -> @clock:0x704c77730661eff4309838fc738ef615/clock_state.State -> @result:Pair(List<&1, 0x704c77730661eff4309838fc738ef615/deferred_command.Command<0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E>>>, Bool) -> @lifecycle:0x704c77730661eff4309838fc738ef615/execution_lifecycle_notices.Journal<S> -> Pair(0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E>, Bool)

template ready source · line 30 · raw

@-S:Data -> @-C:Type -> @-R:Type -> @-E:Data -> @world:0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E> -> Pair(0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E>, Bool)

Internal constant-time structural admission, before any trusted projection.

template allocator source · line 36 · raw

@-S:Data -> @-C:Type -> @-R:Type -> @-E:Data -> @world:0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E> -> Pair(0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E>, U32)

Internal experimental accessor: exact actual allocator, no inferred live count. Rebuild the SAME owner with every field returned unchanged.

template finish source · line 44 · raw

@-S:Data -> @-C:Type -> @-R:Type -> @-E:Data -> @nextEntity:U32 -> @entities:List<&2, Entity> -> @observed:Pair(0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E>, List<&2, 0x704c77730661eff4309838fc738ef615/decode_data.Field>) -> Pair(0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E>, Snapshot)

Closed schema providers must return the actual store/resource owners. Their projections, transient omission and name bindings are trusted author inputs. This is NOT the still-missing public constructed-descriptor validation gate.

template with_entities source · line 47 · raw

@-S:Data -> @-C:Type -> @-R:Type -> @-E:Data -> @-resources:(@_:R -> Pair(R, List<&2, 0x704c77730661eff4309838fc738ef615/decode_data.Field>)) -> @nextEntity:U32 -> @observed:Pair(0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E>, List<&2, Entity>) -> Pair(0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E>, Snapshot)

template with_handles source · line 50 · raw

@-S:Data -> @-C:Type -> @-R:Type -> @-E:Data -> @-rows:(@_:List<&2, 0x704c77730661eff4309838fc738ef615/world.Handle<S>> -> @_:C -> Pair(C, List<&2, Entity>)) -> @-resources:(@_:R -> Pair(R, List<&2, 0x704c77730661eff4309838fc738ef615/decode_data.Field>)) -> @nextEntity:U32 -> @observed:Pair(0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E>, List<&2, 0x704c77730661eff4309838fc738ef615/world.Handle<S>>) -> Pair(0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E>, Snapshot)

template with_allocator source · line 53 · raw

@-S:Data -> @-C:Type -> @-R:Type -> @-E:Data -> @-rows:(@_:List<&2, 0x704c77730661eff4309838fc738ef615/world.Handle<S>> -> @_:C -> Pair(C, List<&2, Entity>)) -> @-resources:(@_:R -> Pair(R, List<&2, 0x704c77730661eff4309838fc738ef615/decode_data.Field>)) -> @observed:Pair(0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E>, U32) -> Pair(0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E>, Snapshot)

template saved source · line 56 · raw

@-S:Data -> @-C:Type -> @-R:Type -> @-E:Data -> @result:Pair(0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E>, Snapshot) -> Pair(0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E>, Outcome<Snapshot>)

template basic_ready source · line 59 · raw

@-S:Data -> @-C:Type -> @-R:Type -> @-E:Data -> @-rows:(@_:List<&2, 0x704c77730661eff4309838fc738ef615/world.Handle<S>> -> @_:C -> Pair(C, List<&2, Entity>)) -> @-resources:(@_:R -> Pair(R, List<&2, 0x704c77730661eff4309838fc738ef615/decode_data.Field>)) -> @result:Pair(0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E>, Bool) -> Pair(0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E>, Outcome<Snapshot>)

template basic source · line 63 · raw

@-S:Data -> @-C:Type -> @-R:Type -> @-E:Data -> @-rows:(@_:List<&2, 0x704c77730661eff4309838fc738ef615/world.Handle<S>> -> @_:C -> Pair(C, List<&2, Entity>)) -> @-resources:(@_:R -> Pair(R, List<&2, 0x704c77730661eff4309838fc738ef615/decode_data.Field>)) -> @world:0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E> -> Pair(0x704c77730661eff4309838fc738ef615/world.World<S, C, R, E>, Outcome<Snapshot>)