dependencySearch library

Functions

dependencySearch<T>(T root, Iterable<T> getChildren(T node)) → Map<T, int>
Return the level for every visited node inside the graph. (The graph must be cycle free.) The level is definied as the maximum step number (one edge == one step) to the root node.