Main Content

Simulink.VariantManager.getConfigurationData

Get variant configuration data object associated with model

Since R2022b

Description

vcdo = Simulink.VariantManager.getConfigurationData(model) returns the variant configuration data object associated with the model model.

Note

To use this function, you must install the Variant Manager for Simulink® support package.

example

Examples

collapse all

Open the model slexVariantManagement.

model = 'slexVariantManagement';
open_system(model);

Get the existing variant configuration object for the model.

Simulink.VariantManager.getConfigurationData(model)
ans = 
  VariantConfigurationData with properties:

            Configurations: [1x7 struct]
               Constraints: [1x1 struct]
    PreferredConfiguration: ''

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

get_param(model, 'VariantConfigurationObject')
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 configuration data object associated with the model, returned as an object of the Simulink.VariantConfigurationData class.

Version History

Introduced in R2022b

expand all

Go to top of page