Main Content

remove

Class: slreq.Link
Namespace: slreq

Delete links

Description

remove(myLink) deletes the link myLink.

example

Input Arguments

expand all

Link, specified as an slreq.Link object.

Examples

expand all

This example shows how to get and delete broken links.

Load the myAddRequirements requirement set, which links to lines of code in myAddBroken.m.

rs = slreq.load("myAddBroken");

Get a handle to the link set.

myLinkSet = slreq.find(Type="LinkSet");

Get the broken links in the link set. Display the number of broken links.

[brokenLinks,details] = getBrokenLinks(myLinkSet);
numBrokenLinks = numel(brokenLinks)
numBrokenLinks = 
1

Delete the broken link.

remove(brokenLinks(1))

Confirm that there are no broken links.

brokenLinks = getBrokenLinks(myLinkSet)
brokenLinks =

     []

Version History

Introduced in R2019a