matlab.unittest.constraints.Matches 类
命名空间: matlab.unittest.constraints
超类: matlab.unittest.constraints.BooleanConstraint
测试值是否与指定的正则表达式匹配
描述
matlab.unittest.constraints.Matches
类提供一个约束来测试值是否与指定的正则表达式匹配。
创建对象
描述
c = matlab.unittest.constraints.Matches(
创建一个约束来测试值是否与指定的正则表达式匹配。与 expression
)expression
匹配的字符串标量或字符向量满足该约束。
c = matlab.unittest.constraints.Matches(
使用一个或多个名称-值参量设置其他选项。例如,expression
,Name,Value
)c = matlab.unittest.constraints.Matches(expression,"IgnoringCase",true)
创建一个不区分大小写的约束。