destroy
Description
destroy(
destroys the data
interface dataInterfaceObj
)dataInterfaceObj
and removes it from its parent interface
dictionary.
Examples
Delete Data Interface from an Interface Dictionary
This example shows how to delete a data interface and remove it from an interface dictionary.
Create a Simulink.interface.Dictionary
object by opening an
existing interface dictionary.
interfaceDictObj = Simulink.interface.dictionary.open('myInterfaceDict.sldd')
interfaceDictObj = Dictionary with properties: DictionaryFileName: 'myInterfaceDict.sldd' Interfaces: [1×1 Simulink.interface.dictionary.DataInterface] DataTypes: [0×0 Simulink.interface.dictionary.DataType]
This interface dictionary has one data interface definition.
interfaceObj = interfaceDictObj.Interfaces
interfaceObj = DataInterface with properties: Name: 'interface1' Description: '' Elements: [1×2 Simulink.interface.dictionary.DataElement] Owner: [1×1 Simulink.interface.Dictionary]
Use the destroy
function to delete the interface and remove it
from the interface dictionary.
destroy(interfaceObj) interfaceDictObj
interfaceDictObj = Dictionary with properties: DictionaryFileName: 'myInterfaceDict.sldd' Interfaces: [0×0 Simulink.interface.dictionary.DataInterface] DataTypes: [0×0 Simulink.interface.dictionary.DataType]
The interface dictionary interfaceDictObj
now has no
interfaces.
Input Arguments
dataInterfaceObj
— Data interface to delete
Simulink.interface.dictionary.DataInterface
object
Data interface to delete, specified as a Simulink.interface.dictionary.DataInterface
object.
Version History
Introduced in R2022bR2023b: Simulink.interface.Dictionary
object replaced by Simulink.dictionary.ArchitecturalData
object
Starting in R2023b, use the Simulink.dictionary.ArchitecturalData
object to programmatically manage architectural data instead of the
Simulink.interface.Dictionary
object.
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)