Serialization
Serialization converts domain objects back to wire form - the outgoing direction complementary to instantiate.
Methods
| Method | Returns | Description |
|---|---|---|
dump | wire InputType (LooseInputType<…>, the brand-free wire-form value) | Walk schema graph, apply encoders, filter |
dumpJson | string | Same as dump but returns a JSON string |
toSchema | Record<string, unknown> | undefined | Reconstruct JSON Schema from the canonical graph |
All examples use the bookstore domain. See instantiate for the incoming direction.
Related
instantiate- the incoming direction (wire to domain)Transform.create- register encode/decode pairs used bydumpjt.encode- single-schema encode
See also
- Bookstore domain - schemas used throughout serialization examples
- Transforms - how Transform encoders apply during
dump