parent
Class: slreq.Requirement
Namespace: slreq
Find parent item of requirement
Syntax
parentObj = parent(req)
Description
returns the parent object parentObj
= parent(req
)parentObj
of the
slreq.Requirement
object req
.
Input Arguments
req
— Requirement instance
slreq.Requirement
object
Requirement specified as an slreq.Requirement
object.
Output Arguments
parentObj
— Parent object
slreq.Requirement
object | slreq.ReqSet
object
The parent of the requirement req
, returned as an
slreq.Requirement
object or as an
slreq.ReqSet
object.
Examples
Find Parent Objects of Requirements
Load a requirement set file and add two new requirements.
rs = slreq.load("C:\MATLAB\My_Requirements_Set_1.slreqx"); req1 = add(rs,"Id","5","Summary","Additional Requirement"); req2 = add(req1,"Id","5.1","Summary","Additional Child Requirement");
Find the parent of
req2
.parentReq1 = parent(req2)
parentReq1 = Requirement with properties: Id: '5' Summary: 'Additional Requirement' Keywords: [0×0 char] Description: '' Rationale: '' SID: 10 CreatedBy: 'John Doe' CreatedOn: 05-Oct-2007 16:09:38 ModifiedBy: 'Jane Doe' ModifiedOn: 21-Dec-2016 11:10:05 Comments: [0×0 struct]
Find the parent of
req1
.parentReq2 = parent(req1)
parentReq2 = ReqSet with properties: Description: '' Name: 'My_Requirements_Set_1' Filename: 'C:\MATLAB\My_Requirements_Set_1.slreqx' Revision: 6 Dirty: 1 CustomAttributeNames: {}
Version History
Introduced in R2018a
See Also
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)