MATLAB 帮助中心
本页采用了机器翻译。点击此处可查看英文原文。
检查名称是否为 Simulink 标识符 (SID) 字符串
tf = slreportgen.utils.isSID(name)
tf = slreportgen.utils.isSID(name) 测试输入的 name 是否是语法正确的 Simulink® 标识符 (SID)。
tf
name
示例
全部折叠
openExample("slrgex_pitch_control") sid_1 = slreportgen.utils.isSID("slrgex_pitch_control") sid_2 = slreportgen.utils.isSID("slrgex_pitch_control/Controller") sid_3 = slreportgen.utils.isSID("valid_syntax_not_valid_sid") getsid_4 = Simulink.ID.getSID("slrgex_pitch_control/Controller"); sid_4 = slreportgen.utils.isSID(getsid_4)
sid_1 = logical 1 sid_2 = logical 0 sid_3 = logical 1 sid_4 = logical 1
要检查是否为 SID 的名称,指定为字符串或字符数组。该实用工具仅检查输入的语法是否有效。它不检查输入是否是有效的 SID。
1
true
0
false
输入是否是语法正确的 SID,如果输入是 SID,则返回为 1 (true)。否则,返回 0 (false)。
在 R2018b 中推出
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 国家/地区网站并未针对您所在位置的访问进行优化。
美洲
欧洲
亚太
联系您当地的办事处