ezu-style
Ezu Style Spec parser for the ezu workspace.
A pure serde-based reader for the node-DAG style language. Parsing
this crate produces a [Document] — a data structure, not an
evaluator. To execute a document, feed it to
ezu-graph::build_graph with a NodeRegistry.
Spec at a glance
References inside node fields use a prefix:
@name— node reference (input wiring)$name—paramssubstitution at build time
Each features node references a host-bound layer by name
(tile.<layer> for per-tile MVT/GeoJSON data) and carries an optional
filter (entries AND-combined; values are single literals or membership
lists) and an optional min-zoom-field.
Asset src strings (in the assets block) accept either a local file
reference resolved against the host's base directory, or an
http(s):// URL — native hosts (CLI, server, the tokyo example)
prefetch URL assets via ezu_paint::host::prefetch_doc_assets before
the first render, so the loader sees an already-decoded bank.
The sources block declares per-tile data sources the host fetches
- binds before each render. Three source kinds are recognised today:
dem— raster-DEM tile pyramid (terrarium or mapbox-rgb encoding). The host stitches the 3×3 neighbourhood into a per-tileScalarField(withgeo_scalepopulated) and binds it undertile.<source-name>, ready for thedemsource node to pick up.mvt— XYZ MVT URL template (or a TileJSON document). The host fetches one tile per render, decodes every layer, and binds each one undertile.<layer-name>— the same names existingfeaturesnodes already reference.pmtiles— PMTiles archive (local path orhttp(s)://URL). Decoded layers bind the same way asmvt.
"sources":
For mvt / pmtiles, the source key (basemap above) is a label —
bindings still use the layer names from the decoded tile. Declare only
one MVT-flavoured source per style; later entries are ignored.
Types
pub type FeatureFilter = ;
Example
let doc = from_json?;
println!;
License
MIT or Apache-2.0, at your option.