1 import Base 2 import ./ordinary_app_schema.bend as SchemaApp 3 import ./ordinary_app_composer.bend as Build 4 import ./event_family_routing.bend as Route 5 import ./world.bend as W 6 import ./ordinary_app_event_family_runtime.bend as App 7 import ./ordinary_app_dump.bend as Dump 8 import ./ordinary_dump_filter.bend as Filter 9 import ./ordinary_app_observation_data.bend as DTO 10 import ./ordinary_app_registration_fields.bend as Records 11 # Reuses the schema-derived dump while preserving the actual family/tick/readers. 12 # Return the App with an optional filtered schema dump. Disabled debug bypasses 13 # dump derivation; enabled uses trusted ordinary count/presentation adapters. 14 # Preserve actual family, tick and registration owners without synchronizing or 15 # acknowledging event readers; opaque value presentation remains caller supplied. 16 def snapshot(~S:Data,~C:Type,~R:Type,~P:Data,~F:Type,~Owners:Type,~Rows:Data,~observe:W.World -> W.World & DTO.Observation,~fold:Owners -> Owners & List<&2,Records.Fields>,~count:C -> List<&2,W.Handle> -> C & List<&2,Maybe<&2,U32>>,~components:C -> U32 -> C & List<&2,Maybe<&2,String>>,~resources:R -> R & List<&2,Maybe<&2,String>>,criteria:Filter.Filter,value:App.Application) -> App.Application & Maybe<&2,Dump.Dump>: 17 match value: 18 case App.Application{schema,Route.Runtime{world,family,tick},owners,recipe,debug}:App.returned(~S,~C,~R,~P,~F,~Owners,~Rows,~observe,~fold,~Maybe<&2,Dump.Dump>,family,tick,Dump.schema_snapshot(~S,~C,~R,~P,~Owners,~Rows,~observe,~fold,~count,~components,~resources,criteria,SchemaApp.Application{schema,Build.Registered{world,owners,recipe,debug}}))