주요 콘텐츠

getReferencedDictionaries

Get referenced dictionaries

Since R2026a

Description

dicts = getReferencedDictionaries(dictionary) gets dictionaries referenced by the specified dictionary.

dicts = getReferencedDictionaries(dictionary,recurse) gets referenced dictionaries with the option to recurse and find references of references.

example

Examples

collapse all

Add a data interface named newInterface to the local dictionary of the model. Save the local dictionary to a shared dictionary as an SLDD file.

arch = systemcomposer.createModel("newModel");
systemcomposer.openModel("newModel");
addInterface(arch.InterfaceDictionary,"newInterface");
saveToDictionary(arch,"TopDictionary")
topDictionary = systemcomposer.openDictionary("TopDictionary.sldd");

Create a new dictionary and add it as a reference to the existing dictionary.

refDictionary = systemcomposer.createDictionary("ReferenceDictionary.sldd");
addReference(topDictionary,"ReferenceDictionary.sldd")

Create a second dictionary and add it as a reference to the referenced dictionary.

newDictionary = systemcomposer.createDictionary("NewDictionary.sldd");
addReference(refDictionary,"NewDictionary.sldd")

Get the dictionary references for the TopDictionary.sldd dictionary with recurse set as true.

dicts = getReferencedDictionaries(topDictionary,true)
dicts = 

  1×2 Dictionary array with properties:

    Interfaces
    Profiles
    UUID
    ExternalUID

Input Arguments

collapse all

Data dictionary, specified as a systemcomposer.interface.Dictionary object. For information on how to create a data dictionary, see createDictionary.

Whether to recurse, specified as 1 (true) or 0 (false).

Data Types: logical

Output Arguments

collapse all

Data dictionary, returned as a systemcomposer.interface.Dictionary object or an array of systemcomposer.interface.Dictionary objects.

More About

collapse all

Version History

Introduced in R2026a

See Also

Functions

Objects

Blocks

Tools