Stateflow    
findDeep

Return specified objects in this object at all levels of containment below this object

Syntax

Description

The findDeep method of this object returns all objects of the specified type at any and all depths of containment within this object. You specify the object type as a string argument. Only one type is allowed.

Arguments

thisObject
The object for which to find objects at all levels of containment. It can be an object of type Root, Machine, Chart, State, Box, or Function.
Type
The string name for the type of objects to find. Values can be 'Machine', 'Chart', 'State', 'Box', 'Function', 'Note', 'Transition', 'Junction', 'Event', 'Data', or 'Target'.

Returns

objArray
Array of objects of the specified type found in this object at any (all) depths.

Example

Chart object ch contains state A and state B, connected by a transition. State A contains states A11 and A12, also connected by a transition. State A11 contains state A111 and a junction. The command ch.findDeep('State') returns an array of state objects for states A, A11, A12, A111, and B.

See Also

The methods findShallow and find


  find findShallow