Reactive Systems logo
Reactis API V2020

API - Reactis for C: MATLAB Bindings - General Reactis for C Functions

rcOpenStart a Reactis for C API session.
rcCloseEnd a Reactis for C API session.
rcGetLastErrorReturn the most recent error message.
rcGetCoverageMetricsGet coverage information from the most recent test run.
rcGetParameterValueGet the value of a global Reactis for C parameter.
rcGetParameterValueBoolGet the value of a global boolean typed Reactis for C parameter.
rcGetParameterValueDoubleGet the value of a global double typed Reactis for C parameter.
rcSetParameterValueSet the value of a global Reactis for C parameter.
rcSetStringEncodingSet string encoding.
rcVersionReturn Reactis for C API version.
rcVersionParseParse Reactis version string.


rcOpen

Start a Reactis for C API session.

Syntax

rcOpen

Description

rcOpen loads and initializes the Reactis for C API.

See Also

rcClose


rcClose

End a Reactis for C API session.

Syntax

rcClose

Description

rcClose removes the Reactis for C API library and all associated files from MATLAB memory. All currently open .rsm and .rsh files, Tester or Simulator sessions will be closed without saving.

See Also

rcOpen


rcGetLastError

Return the most recent error message.

Syntax

s = rcGetLastError

Description

s = rcGetLastError returns a string describing the most recent error that occurred during a Reactis for C API function call.


rcGetCoverageMetrics

Get coverage information from the most recent test run.

Syntax

metrics = rcGetCoverageMetrics 

Description

metrics = rcGetCoverageMetrics returns coverage information as the result of the most recent call to rcSimRunSuite, rcTester, or rcTesterStart.

metrics is a structure array containing one element for each coverage metric tracked by Reactis. The structure contains the following fields:

name
Name of the coverage metric.
numTargets
Total number of coverage targets in this metric.
numCovered
Number of covered targets for this metric.
numUncovered
Number of uncovered targets for this metric.
numUnreachable
Number of unreachable targets for this metric.
percentCovered
Coverage percentage for this metric.

See Also

rcSimRunSuite, rcTester, rcTesterStart


rcGetParameterValue

Get the value of a global Reactis for C parameter.

Syntax

value = rcGetParameterValue(paramName)

Description

value = rcGetParameterValue(paramName) returns the value of global Reactis for C parameter paramName.

Parameters of any data type may be queried by rcGetParameterValue. The return value is always a string.

Valid parameters names are listed in the Reactis Parameters section of the API chapter in the Reactis for C User's Guide.

Examples

v = rcGetParameterValue('UserName');

See Also

rcGetParameterValueBool, rcGetParameterValueDouble, rcSetParameterValue


rcGetParameterValueBool

Get the value of a global boolean typed Reactis for C parameter.

Syntax

value = rcGetParameterValueBool(paramName)

Description

value = rcGetParameterValueBool(paramName) returns the value of global boolean typed Reactis for C parameter paramName.

If the parameter is not of type boolean, then an error is raised.

Valid parameters names are listed in the Reactis Parameters section of the API chapter in the Reactis for C User's Guide.

See Also

rcGetParameterValue, rcGetParameterValueDouble


rcGetParameterValueDouble

Get the value of a global double typed Reactis for C parameter.

Syntax

value = rcGetParameterValueDouble(paramName)

Description

value = rcGetParameterValueDouble(paramName) returns the value of global double typed Reactis for C parameter paramName.

If the parameter is not of type double, then an error is raised.

Valid parameters names are listed in the Reactis Parameters section of the API chapter in the Reactis for C User's Guide.

See Also

rcGetParameterValue, rcGetParameterValueBool


rcSetParameterValue

Set the value of a global Reactis for C parameter.

Syntax

rcSetParameterValue(paramName,value)

Description

rcSetParameterValue(paramName,value) sets global Reactis for C parameter paramName to value.

Parameters of any data type may be set by rcSetParameterValue, but the paramValue argument must be given as a string.

Valid parameters names are listed in the Reactis Parameters section of the API chapter in the Reactis for C User's Guide.

Examples

rcSetParameterValue('LibraryPath', newSearchPath);

See Also

rcGetParameterValue, rcGetParameterValueBool, rcGetParameterValueDouble


rcSetStringEncoding

Set string encoding.

Syntax

rcSetStringEncoding(encoding)

Description

rcSetStringEncoding(encoding) sets the character encoding for strings returned by functions like rcGetLastError and rcTesterGetStatus. If not set, the strings will be UTF8 encoded.


rcVersion

Return Reactis for C API version.

Syntax

s = rcVersion

Description

s = rcVersion returns the version of the Reactis for C API.

See Also

rcVersionParse


rcVersionParse

Parse Reactis version string.

Syntax

major,minor,patch = rcVersionParse(version)

Description

major,minor,patch = rcVersionParse(version) parses Reactis version string version (as returned by functions rcVersion or rcSuiteGetReactisVersion) and returns the major version, minor version, and patch number.