Main Content


Set name for signal interface element



    setName(interfaceElem,name) sets the name for the designated signal interface element.


    collapse all

    Create a model named 'archModel', add an interface, create an interface element with a name 'x', and set a new name for the interface element 'newName'.

    modelName = 'archModel';
    arch = systemcomposer.createModel(modelName); % Create model
    interface = arch.InterfaceDictionary.addInterface('interface'); % Add interface
    elem = interface.addElement('x'); % Create interface element
    setName(elem,'newName'); % Set new name for interface element

    Input Arguments

    collapse all

    Interface element to be renamed, specified as a systemcomposer.interface.SignalElement object.

    Name of interface element, specified as a character vector.

    Data Types: char

    Introduced in R2019a