主要内容

Exception by function

Option to add array layout exceptions for selected custom code functions

Model Configuration Pane: Simulation Target

Description

The Exception by function parameter specifies how input array data is handled by each external C/C++ function and class method.

Category: Simulation Target

Settings

add | remove

Specify how input array data is handled by each external C/C++ function and class method in your custom code. The array layout specified for an individual function or class method takes precedence over the option specified in Default function array layout. Use these options to add or remove the array layout setting for an individual function or class method:

add

Add custom C/C++ function or class method and specify its array layout setting. To specify a class method, use the syntax ClassName::MethodName.

remove

Remove custom C/C++ function or class method from the exception list and apply default array layout to the function or class method.

Tip

If you do not see a list of your custom code functions in the Exception by function dialog box, close the dialog box, click Validate custom code, and click Exception by function again.

Recommended Settings

ApplicationSetting
DebuggingNo impact
TraceabilityNo impact
EfficiencyNo recommendation
Safety precautionNo recommendation

Programmatic Use

Parameter: CustomCodeFunctionArrayLayout
Type: structure array
Value: structure with "FunctionName" and "ArrayLayout" fields. "ArrayLayout" can be "Column-major", "Row-major" or "Any".
Default: ""

Version History

Introduced in R2020b