Main Content

addCopyOfConfiguration

Add copy of existing variant configuration to variant configuration data object

    Description

    Note

    This function requires Variant Manager for Simulink®.

    addCopyOfConfiguration(varconfigdata,oldconfig) copies the variant configuration named oldconfig from the Simulink.VariantConfigurationData object varconfigdata and adds it to the same object. The function gives the new configuration a default name based on the name of the configuration that is copied.

    addCopyOfConfiguration(varconfigdata,oldconfig,newConfig) specifies a name for the new configuration.

    example

    Examples

    collapse all

    Add a copy of the existing variant configuration LinInterExpNoNoise to varconfigdata and name the copy LinInterExpNoise.

    addCopyOfConfiguration(varconfigdata,"LinInterExpNoNoise","NonLinExtExpNoise");

    Input Arguments

    collapse all

    Variant configuration data to which you want to copy the variant configuration oldconfig, specified as a Simulink.VariantConfigurationData object.

    Name of existing variant configuration to copy, specified as a string scalar or a character vector. This configuration must exist in the variant configuration data object varconfigdata.

    Example: "LinInterExpNoNoise"

    Data Types: char | string

    Name to be used for the copied configuration, specified as a string scalar or a character vector.

    Example: "LinInterExpNoise"

    Data Types: char | string

    Version History

    Introduced in R2013b