MATLAB 帮助中心
本页采用了机器翻译。点击此处可查看最新英文版本。
类: slreq.ReqSet 命名空间: slreq
获取有关需求集自定义属性的信息
atrb = inspectAttribute(rs,name)
atrb = inspectAttribute(rs,name) 返回一个结构体,其中包含有关需求集 name 中 rs 指定的自定义属性名称的信息。
atrb
rs
name
全部展开
slreq.ReqSet
需求集,指定为 slreq.ReqSet 对象。
自定义属性名称,指定为字符数组。
struct
自定义属性信息,以 struct 形式返回。
此示例显示如何获取有关需求集自定义属性的信息。
加载 crs_req_func_spec,它描述了巡航控制系统。找到一个需求集并将其分配给一个变量。
crs_req_func_spec
slreq.load('crs_req_func_spec'); rs = slreq.find('Type','ReqSet');
向需求集添加 Checkbox 自定义属性并附加说明。使用 inspectAttribute 获取有关自定义属性的信息。
Checkbox
inspectAttribute
addAttribute(rs,'MyCheckbox','Checkbox','Description',... 'This checkbox atrribute can be true or false.'); atrb = inspectAttribute(rs,'MyCheckbox')
atrb = struct with fields: name: 'MyCheckbox' type: Checkbox description: 'This checkbox atrribute can be true or false.' default: 0
在 R2020b 中推出
slreq.ReqSet | addAttribute | deleteAttribute | updateAttribute
addAttribute
deleteAttribute
updateAttribute
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
选择网站
选择网站以获取翻译的可用内容,以及查看当地活动和优惠。根据您的位置,我们建议您选择:。
您也可以从以下列表中选择网站:
如何获得最佳网站性能
选择中国网站(中文或英文)以获得最佳网站性能。其他 MathWorks 国家/地区网站并未针对您所在位置的访问进行优化。
美洲
欧洲
亚太
联系您当地的办事处