Hauptinhalt

getRows

R2026b

Get all rows from state transition table or parent row

Since R2026b

Description

rows = getRows(stt) returns all top-level rows in the state transition table stt as an array of Stateflow.StateTransitionTableRow objects, including state rows, default transition path rows, and inner transition path rows.

example

rows = getRows(parentRow) returns all child rows of parentRow, including state rows, default transition path rows, and inner transition path rows.

Examples

collapse all

Retrieve all top-level rows in a table.

Open a model that contains a state transition table and get a handle to the table.

open_system("myModel")
stt = find(sfroot, "-isa", "Stateflow.StateTransitionTableChart", ...
    Name="mySTT");

Get all top-level rows in the table.

rows = getRows(stt);

Input Arguments

collapse all

State transition table from which to get rows, specified as a Stateflow.StateTransitionTableChart object.

Parent row from which to get child rows, specified as a Stateflow.StateTransitionTableRow object.

Output Arguments

collapse all

Rows, returned as an array of Stateflow.StateTransitionTableRow objects. The array includes state rows, default transition path rows, and inner transition path rows. If no rows exist, the function returns an empty array.

Version History

Introduced in R2026b

expand all