Main Content

本页采用了机器翻译。点击此处可查看英文原文。

addJustification

类: slreq.ReqSet
命名空间: slreq

向需求集添加申述

语法

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

说明

jt = addJustification(rs) 向需求集rs 添加申述jt

jt = addJustification(rs, 'PropertyName', PropertyValue) 向需求集rs 添加了申述jt,并附加了由 PropertyNamePropertyValue 指定的属性。

输入参数

全部展开

需求集,指定为 slreq.ReqSet 对象。

输出参量

全部展开

向需求集rs 中添加申述,作为 slreq.Justification 对象返回。

示例

全部展开

此示例显示如何向需求集添加申述。

假设您有一个需求集rs。为需求集添加申述。

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]

为需求集添加申述并指定摘要和描述。

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]

版本历史记录

在 R2018b 中推出