findTerminals
fun CompositionNode.findTerminals(filter: (CompositionNode) -> Boolean): List<CompositionNode>(source)
Recursively finds all terminal nodes within the composition tree starting from the current node and applies the provided filter to determine which nodes to include in the result.
Return
A list of terminal nodes within the composition tree that satisfy the given filter.
Parameters
filter
A predicate function used to filter terminal nodes. Only nodes that satisfy this predicate will be included in the result.