isValid
Syntax
Description
Examples
Create and Apply View to Requirements Editor
This example shows how to create a view and apply it to the Requirements Editor and Requirements Perspective.
Open the myAddRequirements
requirement set, which contains requirements with Type
set to Functional
.
rs = slreq.open("myAddRequirements");
Create a view with the name NewView
.
myView = slreq.View.create("NewView")
myView = View with properties: Name: 'NewView' ReqFilter: '' LinkFilter: '' Host: ''
Set the requirement filter to only display requirements that have Type
set to Container
.
myView.ReqFilter = "{'ReqType','Container'};"
myView = View with properties: Name: 'NewView' ReqFilter: '{'ReqType','Container'};' LinkFilter: '' Host: ''
Check if the view is valid.
tf = isValid(myView)
tf = logical
1
Apply the view to the Requirements Editor and Requirements Perspective.
activate(myView)
Confirm that the active view is NewView
.
appliedView = slreq.View.getActiveView
appliedView = View with properties: Name: 'NewView' ReqFilter: '{'ReqType','Container'};' LinkFilter: '' Host: ''
The myAddRequirements
requirement set does not contain any requirements with Type
set to Container
, so all of the requirements are filtered out.
Input Arguments
view
— View settings
slreq.View
object
View settings, specified as an slreq.View
object.
Output Arguments
tf
— Validity check status
0
|
1
Validity check status, returned as a 1
or 0
of
data type logical
.
Version History
Introduced in R2022b
MATLAB 명령
다음 MATLAB 명령에 해당하는 링크를 클릭했습니다.
명령을 실행하려면 MATLAB 명령 창에 입력하십시오. 웹 브라우저는 MATLAB 명령을 지원하지 않습니다.
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)