Main Content

setName

Set name for port

    Description

    setName(port,name) sets the name for the designated port.

    example

    Examples

    collapse all

    Create a model, get the root architecture, add a component, add a port, and set a new name for the port.

    model = systemcomposer.createModel("archModel");
    systemcomposer.openModel("archModel");
    rootArch = get(model,"Architecture");
    newComponent = addComponent(rootArch,"newComponent");
    newPort = addPort(newComponent.Architecture,"newCompPort","in");
    setName(newPort,"compPort")

    Input Arguments

    collapse all

    Name of port, specified as a character vector or string.

    Data Types: char | string

    More About

    collapse all

    Version History

    Introduced in R2019a