Main Content

destroy

Remove and delete AUTOSAR architecture element

Since R2020a

Description

destroy(archElement) removes and deletes architecture element archElement from an architecture model. The archElement argument is a component, composition, port, or connector handle returned by a previous call to addComponent, addComposition, addPort, connect, or find.

example

Examples

collapse all

In an AUTOSAR architecture model, find, remove, and delete a software composition.

% Create AUTOSAR architecture model
modelName = 'myArchModel';
archModel = autosar.arch.createModel(modelName);

% Add a composition
addComposition(archModel,'Sensors2');

% Find and destroy the composition
composition = find(archModel,'Composition');
destroy(composition);

Input Arguments

collapse all

Component, composition, port, or connector element to remove and delete. The argument is a component, composition, port, or connector handle returned by a previous call to addComponent, addComposition, addPort, connect, or find.

Example: composition

Version History

Introduced in R2020a