Simulink.Mask.PortConstraint Class
Description
Use an instance of the Simulink.Mask.PortConstraint
class to add or remove
port constraints on a masked block.
Properties
Name
— Name of constraint
character vector
Name of port constraint, specified as a string.
Data Types: char
ParameterConditions
— Mask parameter conditions
array of Simulink.Mask.ParameterCondition
object
Mask parameter conditions, specified as an array of
Simulink.Mask.ParameterCondition
objects. The port constraints are
active on the associated port only when the port satisfies all the parameter
conditions.
Rule
— Allowed datatype, complexity, and dimension associated with constraint
Simulink.Mask.PortConstraintRule
object
Allowed datatype, complexity, and dimension associated with constraint, specified as
a Simulink.Mask.PortConstraintRule
object.
Data Types: string
DiagnosticLevel
— Type of diagnostic message displayed when validation condition fails
error (default) | warning
Type of diagnostic message displayed when validation condition fails, specified as error or warning.
Data Types: char
DiagnosticMessage
— Diagnostic message displayed when validation fails
character vector
Diagnostic message displayed when validation fails, specified as a character vector.
Data Types: char
Methods
Public Methods
addParameterCondition | Creates a mask parameter condition for constraint |
getParameterCondition | Returns parameter condition associated with constraint |
removeParameterCondition | Removes specified parameter condition on constraint |
removeAllParameterConditions | Removes all parameter conditions from constraint |
setRule | Create rules that are validated against data at port |
Version History
Introduced in R2022a
MATLAB Command
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.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 日本Japanese (日本語)
- 한국Korean (한국어)