pub struct ParameterDef {Show 16 fields
pub name: String,
pub label: String,
pub description: String,
pub param_type: ParameterType,
pub default: Option<Value>,
pub constraints: Option<Constraints>,
pub placeholder: Option<String>,
pub visible_when: Option<ParamCondition>,
pub required_when: Option<ParamCondition>,
pub surfaceable: bool,
pub group: Option<String>,
pub suffix: Option<String>,
pub control: Option<String>,
pub accept: Option<Vec<String>>,
pub presets: Option<Vec<PresetEntry>>,
pub inverted: Option<bool>,
}Expand description
A complete definition of one parameter a node accepts. Provides everything the engine (validation) and UI (control rendering) need.
Fields§
§name: String§label: String§description: String§param_type: ParameterTypeValue type — determines what UI control to render.
default: Option<Value>§constraints: Option<Constraints>§placeholder: Option<String>§visible_when: Option<ParamCondition>§required_when: Option<ParamCondition>§surfaceable: boolWhether this param can be surfaced in container config panels.
group: Option<String>§suffix: Option<String>§control: Option<String>Override control identifier (e.g., "slider", "select", "file").
accept: Option<Vec<String>>§presets: Option<Vec<PresetEntry>>§inverted: Option<bool>Flip the semantic of a boolean control.
Trait Implementations§
Source§impl Clone for ParameterDef
impl Clone for ParameterDef
Source§fn clone(&self) -> ParameterDef
fn clone(&self) -> ParameterDef
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ParameterDef
impl Debug for ParameterDef
Source§impl Default for ParameterDef
impl Default for ParameterDef
Source§impl PartialEq for ParameterDef
impl PartialEq for ParameterDef
Source§impl Serialize for ParameterDef
impl Serialize for ParameterDef
impl StructuralPartialEq for ParameterDef
Auto Trait Implementations§
impl Freeze for ParameterDef
impl RefUnwindSafe for ParameterDef
impl Send for ParameterDef
impl Sync for ParameterDef
impl Unpin for ParameterDef
impl UnsafeUnpin for ParameterDef
impl UnwindSafe for ParameterDef
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more