Expand description
Code rendering infrastructure for Rust type generation.
This module defines the Renderer
and supporting components responsible
for converting fully resolved DataTypes
into structured Rust code modules.
It provides a flexible, composable rendering pipeline through the
RenderStep
trait, allowing each rendering step to be added, removed, or
customized as needed.
The Renderer
can be extended with custom RenderStep
implementations
or modified using configuration methods such as flags()
,
derive()
, and dyn_type_traits()
.
Example usage:
ⓘ
let module = Renderer::new(&types)
.with_default_steps()
.derive(["Debug", "Clone"])
.finish();
Structs§
- Context
- Context for the rendering process.
- Defaults
Render Step - Implements a
RenderStep
that renders associated methods that return the default values of the different attributes and elements according to the schema. - Meta
Data - Meta data of the render process.
- Namespace
Constants Render Step - Implements a
RenderStep
that renders constants for the different namespaces used in the schema. - Quick
XmlDeserialize Render Step - Implements a
RenderStep
that renders the code for thequick_xml
deserialization. - Quick
XmlSerialize Render Step - Implements a
RenderStep
that renders the code for thequick_xml
serialization. - Renderer
- The
Renderer
is the central orchestrator for Rust code generation from resolved schema types. - Serde
Quick XmlTypes Render Step - Implements a
RenderStep
that renders rust types of the types defined in the schema withquick-xml
support. - Serde
XmlRs V7Types Render Step - Implements a
RenderStep
that renders rust types of the types defined in the schema withserde-xml-rs <= 0.7
support. - Serde
XmlRs V8Types Render Step - Implements a
RenderStep
that renders rust types of the types defined in the schema withserde-xml-rs >= 0.8
support. - Types
Render Step - Implements a
RenderStep
that renders the actual rust types of the types defined in the schema. - With
Namespace Trait Render Step - Implements a
RenderStep
that renders theWithNamespace
trait for each type defined in the schema.
Enums§
Traits§
- Render
Step - Trait that is used to define a renderer.