Skip to main content

default_value_factory

Function default_value_factory 

Source
pub fn default_value_factory(value: &Value) -> BspValue
Expand description

The default static-input mapping: JSON bools/numbers/strings become typed values (so dataflow nodes downcast them exactly as if set_static_input had been called with the Rust value), and anything else arrives as a wrapped serde_json::Value.

Consumers wanting different typing (e.g. the snarl bridge, which historically injects bool/i64/f64/String from property JSON) override this with NodeRegistry::register_value_factory.