Contenido principal

Simulink.VariantManager.getVariantConfigurations

R2026b

Get variant configurations object associated with model

Renamed from Simulink.VariantManager.getConfigurationData in R2026b

Description

varConfigs = Simulink.VariantManager.getVariantConfigurations(model) returns the variant configurations object associated with the model model.

example

Examples

collapse all

Open the model slexVariantManagement.

model = 'slexVariantManagement';
open_system(model);

Get the existing variant configurations object for the model.

Simulink.VariantManager.getVariantConfigurations(model)
ans = 
  VariantConfigurations with properties:

            Configurations: [1×7 struct]
               Constraints: [1×1 struct]
    PreferredConfiguration: ''

Get the name of variant configurations object associated with the model.

get_param(model, 'VariantConfigurations')
ans = 
'vcd'

Input Arguments

collapse all

Name of the model, specified as a character vector or string.

Example: "slexVariantManagement"

Data Types: char | string

Output Arguments

collapse all

Variant configurations object associated with the model, returned as a Simulink.VariantConfigurations object.

Version History

Introduced in R2022b

expand all