pub struct JsonParamDef {
pub id: String,
pub name: String,
pub param_type: String,
pub default_value: Option<Value>,
pub default_value_index: Option<usize>,
pub min: Option<f64>,
pub max: Option<f64>,
pub unit: Option<String>,
pub midpoint: Option<f64>,
pub interval: Option<f64>,
pub fraction_digits: Option<u32>,
pub choices: Option<Vec<String>>,
}Expand description
JSON parameter definition (for parsing parameters.json).
Fields§
§id: StringParameter ID.
name: StringDisplay name.
param_type: StringParameter type: “boolean”, “float”, or “choice”.
default_value: Option<Value>Default value for boolean/float parameters.
default_value_index: Option<usize>Default index for choice parameters.
min: Option<f64>Minimum value for float parameters.
max: Option<f64>Maximum value for float parameters.
unit: Option<String>Unit label for float parameters (e.g., “dB”).
midpoint: Option<f64>Midpoint for skewed float parameters.
interval: Option<f64>Step interval for float parameters.
fraction_digits: Option<u32>Number of decimal places to display.
choices: Option<Vec<String>>Available choices for choice parameters.
Trait Implementations§
Source§impl Clone for JsonParamDef
impl Clone for JsonParamDef
Source§fn clone(&self) -> JsonParamDef
fn clone(&self) -> JsonParamDef
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 JsonParamDef
impl Debug for JsonParamDef
Source§impl<'de> Deserialize<'de> for JsonParamDef
impl<'de> Deserialize<'de> for JsonParamDef
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for JsonParamDef
impl RefUnwindSafe for JsonParamDef
impl Send for JsonParamDef
impl Sync for JsonParamDef
impl Unpin for JsonParamDef
impl UnwindSafe for JsonParamDef
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