Main Content

sinkedTransitions

Identify transitions with specified destination

Description

example

transitions = sinkedTransitions(destination) returns an array of Stateflow.Transition objects with the specified destination.

Examples

collapse all

Suppose that ch is the Stateflow.Chart object that corresponds to this chart.

Stateflow chart with a hierarchy of states. The outer state is called A. It contains two inner states called A1 and A2.

Find the Stateflow.State object named A2.

sA2 = find(ch,'-isa','Stateflow.State','Name','A2');

Identify the transition whose destination is state A2. Display the name of the source.

tr = sinkedTransitions(sA2);
tr.Source.Name
ans =

    'A1'

Input Arguments

collapse all

Destination object, specified as a Stateflow® API object of one of these types:

Introduced in R2012a