Note

This is the documentation for the current state of the development branch of rustworkx. The documentation or APIs here can change prior to being released.

rustworkx.TopologicalSorter.get_ready#

TopologicalSorter.get_ready()#

Return a list of all the nodes that are ready.

Initially it returns all nodes with no predecessors; once those are marked as processed by calling done(), subsequent calls will return any new nodes that have all their predecessors already processed. Once no more progress can be made, an empty list is returned.

Returns:

A list of node indices of all the ready nodes.

Return type:

list[int]