主要内容

removeConfiguration

R2026b

Remove variant configuration from variant configurations object

    Description

    removeConfiguration(varConfigs,ConfigurationName=nameOfConfig) removes the variant configuration named nameOfConfig from the Simulink.VariantConfigurations object varConfigs.

    example

    Examples

    collapse all

    Open the slexVariantManagement model.

    modelName = "slexVariantManagement";
    open_system(modelName);

    Remove the variant configuration named LinInterExpNoNoise from the variant configurations object varConfigs, which is the Simulink.VariantConfigurations object associated with the model.

    varConfigs = Simulink.VariantManager.getVariantConfigurations(modelName);
    removeConfiguration(varConfigs,ConfigurationName="LinInterExpNoNoise");

    Input Arguments

    collapse all

    Variant configurations object from which you want to remove the configuration, specified as a Simulink.VariantConfigurations object.

    Name of the configuration to be removed, specified as a character vector or string scalar.

    Example: "LinInterExpNoNoise"

    Data Types: char | string

    Version History

    Introduced in R2013b

    expand all