Main Content

addJustification

Class: slreq.ReqSet
Namespace: slreq

Add justifications to requirement set

Syntax

jt = addJustification(rs)
jt = addJustification(rs, 'PropertyName', PropertyValue)

Description

jt = addJustification(rs) adds a justification jt to the requirement set rs.

jt = addJustification(rs, 'PropertyName', PropertyValue)adds a justification jt to the requirement set rs with additional properties specified by PropertyName and PropertyValue.

Input Arguments

expand all

Requirement set, specified as an slreq.ReqSet object.

Output Arguments

expand all

Justification added to the requirement set rs, returned as an slreq.Justification object.

Examples

expand all

This example shows how to add a justification to a requirement set.

Suppose that you have a requirement set rs. Add a justification to the requirement set.

jt1 = addJustification(rs)
jt1 = 

  Justification with properties:

              Id: '70'
         Summary: ''
     Description: ''
        Keywords: [0×0 char]
       Rationale: ''
       CreatedOn: 16-Jan-2018 10:53:28
       CreatedBy: 'John Doe'
      ModifiedBy: 'Jane Doe'
             SID: 76
    FileRevision: 1
      ModifiedOn: 16-Feb-2018 12:50:43
           Dirty: 0
        Comments: [0×0 struct]

Add a justification to the requirement set and specify the summary and description.

jt2 = addJustification(rs, 'Summary', 'New justification', ...
'Description', 'Justify safety requirement')
jt2 = 

  Justification with properties:

              Id: '71'
         Summary: 'New justification'
     Description: 'Justify safety requirement'
        Keywords: [0×0 char]
       Rationale: ''
       CreatedOn: 11-Feb-2018 11:45:12
       CreatedBy: 'John Doe'
      ModifiedBy: 'Jane Doe'
             SID: 77
    FileRevision: 1
      ModifiedOn: 12-Feb-2018 13:01:08
           Dirty: 0
        Comments: [0×0 struct]

Version History

Introduced in R2018b