Xantham.Decoder
Xantham.Decoder is the .NET-side counterpart of Xantham.Fable. It reads the
JSON wire format produced by the extractor and materialises it into strongly
typed F# structures suitable for downstream generators.
The decoder is intentionally thin: it does not generate F# code itself. Its job is to:
- Deserialize the JSON IR (
Schema.EncodedResult) usingThoth.Json.Net. - Apply optional compression and sanitization passes over the type/export maps.
- Produce a
DecodedResultof frozen, key-addressable maps. -
Optionally lift those maps into an in-memory object graph (
ArenaInterner) in whichTypeKeyreferences becomeLazy<ResolvedType>values, breaking cycles at the lazy boundary.
Pipeline at a glance
JSON file
DecodedResult
XanthamTree
ArenaInterner / ResolvedType
Page index
- Runtime —
XanthamTree, the main façade for generators. - Decoder — JSON read pipeline, settings, health check.
-
Names & Casing —
Name, units-of-measure for casing, normalization helpers. -
Code Keys —
CodeKey/TypeCodeKey/ExportCodeKeytagged dispatch overTypeKeys. - Dependency Graph —
Graph.createand the dependency view. - ArenaInterner — lazy resolved object graph.
API reference
The full XML-doc generated reference is available under the
Reference section, organised by the same category
groups that appear in this guide.