| Simulink® Verification and Validation™ | ![]() |
You specify the input parameters a custom check uses in analyzing the model. Users access input parameters in the Model Advisor window.
input_param = ModelAdvisor.InputParameter
A variable representing the input parameter object you create.
| Name | Description |
|---|---|
| setColSpan | Specify columns parameter occupies |
| setRowSpan | Specify rows parameter occupies |
Specify columns parameter occupies
input_param.setColSpan([start_col end_col])
A variable representing the input parameter object.
A positive integer representing the first column the input parameter occupies in the layout grid.
A positive integer representing the last column the input parameter occupies in the layout grid.
Specify the number of columns the parameter occupies. Use this method to specify where an input parameter is located in the layout grid when there are multiple input parameters.
Specify rows parameter occupies
input_param.setRowSpan([start_row end_row])
A variable representing the input parameter object.
A positive integer representing the first row the input parameter occupies in the layout grid.
A positive integer representing the last row the input parameter occupies in the layout grid.
Specify the number of rows the parameter occupies. Use this method to specify where an input parameter is located in the layout grid when there are multiple input parameters.
Note The following example is a fragment of code from the sl_customization.m file for the demo model slvnvdemo_mdladv. The example does not execute as shown without the additional content found in the sl_customization.m file. |
See Demo and Code Example for more information.
rec = ModelAdvisor.Check('com.mathworks.sample.Check1');
rec.setInputParametersLayoutGrid([3 2]);
% define input parameters
inputParam1 = ModelAdvisor.InputParameter;
inputParam1.Name = 'Skip font checks.';
inputParam1.Type = 'Bool';
inputParam1.Value = false;
inputParam1.Description = 'sample tooltip';
inputParam1.setRowSpan([1 1]);
inputParam1.setColSpan([1 1]);
inputParam2 = ModelAdvisor.InputParameter;
inputParam2.Name = 'Standard font size';
inputParam2.Value='12';
inputParam2.Type='String';
inputParam2.Description='sample tooltip';
inputParam2.setRowSpan([2 2]);
inputParam2.setColSpan([1 1]);
inputParam3 = ModelAdvisor.InputParameter;
inputParam3.Name='Valid font';
inputParam3.Type='Combobox';
inputParam3.Description='sample tooltip';
inputParam3.Entries={'Arial', 'Arial Black'};
inputParam3.setRowSpan([2 2]);
inputParam3.setColSpan([2 2]);
rec.setInputParameters({inputParam1,inputParam2,inputParam3});![]() | ModelAdvisor.Image | ModelAdvisor.LineBreak | ![]() |
| © 1984-2008- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |