Skip to main content

Crate dendryform_parse

Crate dendryform_parse 

Source
Expand description

§dendryform-parse

YAML and JSON parser for dendryform diagram definitions.

Reads a diagram string or file, deserializes it into a validated dendryform_core::Diagram. Validation (duplicate IDs, dangling edges, empty tiers, nesting depth) happens automatically during deserialization.

§Quick Start

use dendryform_parse::parse_yaml_file;

let diagram = parse_yaml_file("examples/taproot/architecture.yaml").unwrap();
println!("Diagram: {}", diagram.header().title().text());

Enums§

ParseError
Errors that occur when parsing a diagram file.

Functions§

parse_json
Parses a JSON string into a validated Diagram.
parse_json_file
Parses a JSON file into a validated Diagram.
parse_yaml
Parses a YAML string into a validated Diagram.
parse_yaml_file
Parses a YAML file into a validated Diagram.
version
Returns the version of the dendryform-parse crate.