Simulink.VariantManager.updateModel
Obtain model compilation information and activate variant blocks in model hierarchy
Since R2024b
Syntax
Description
The Simulink.VariantManager.updateModel
function updates the
given model, obtains model compilation information, and then validates and activates a variant
configuration on the model and any referenced components in the model hierarchy. You can
update and activate a named variant configuration defined for the model or the workspace
configuration (a temporary configuration based on the current control variable values in the
data sources used by the model). Variant Manager uses this compilation information until the
model is updated again either by using
Simulink.VariantManager.updateModel
or from the Variant Manager user
interface. Model compilation information enables Variant Manager to produce more accurate
results for operations such as importing control variables to a configuration, activation,
and identifying variant parameters used by the model hierarchy.
For more information, see Obtain and Use Model Compilation Information in Variant Manager.
Simulink.VariantManager.updateModel(
updates the model and then activates the workspace variant configuration on the model
hierarchy.modelName
)
Simulink.VariantManager.updateModel(
updates the model and then activates the specified named variant configuration
modelName
,Configuration=configName
)configName
on the model hierarchy.
Note
To use this function, you must install the Variant Manager for Simulink® support package.
Examples
Input Arguments
Alternative Functionality
You can obtain model compilation information from the Variant Manager user interface. See Obtain and Use Model Compilation Information in Variant Manager.
Version History
Introduced in R2024b