Skip to main content

ParameterGroups

Trait ParameterGroups 

Source
pub trait ParameterGroups {
    // Provided methods
    fn group_count(&self) -> usize { ... }
    fn group_info(&self, index: usize) -> Option<GroupInfo> { ... }
    fn find_group_by_name(&self, name: &str) -> Option<GroupId> { ... }
}
Expand description

Trait for querying parameter group hierarchy.

Implemented automatically by #[derive(Parameters)] when nested groups are present. Provides information about parameter groups for DAW display.

Group IDs are assigned dynamically at runtime to support deeply nested groups where the same nested struct type can appear in multiple contexts with different parent groups.

Provided Methods§

Source

fn group_count(&self) -> usize

Total number of groups (including root).

Returns 1 if there are no groups (just the root group). For nested groups, this returns 1 + total nested groups (including deeply nested).

Source

fn group_info(&self, index: usize) -> Option<GroupInfo>

Get group info by index.

Index 0 always returns the root group. Returns GroupInfo by value to support dynamic construction for nested groups.

Source

fn find_group_by_name(&self, name: &str) -> Option<GroupId>

Find group ID by name (linear search).

Implementors§