public class TopologicalSort extends Object
Modifier and Type | Class and Description |
---|---|
static interface |
TopologicalSort.Traversable<T>
User provider callback used for walking the graph
|
Modifier and Type | Method and Description |
---|---|
static <T> com.google.common.collect.ImmutableList<? extends T> |
snowflakeSort(Iterable<? extends T> roots,
TopologicalSort.Traversable<T> traversable,
Comparator<T> comparator)
Deprecated.
This is silly. You should just use the normal sort. This is here because c/c++ link
command lines are sensitive to argument order, but aren't strict about it being correct.
Since they aren't strict, code has evolved to depend on the specific order that Buck has
been ordering link lines, and so this preserves that legacy behavior until code that
depends on it is fixed.
|
static <T> com.google.common.collect.ImmutableList<? extends T> |
sort(Iterable<? extends T> roots,
TopologicalSort.Traversable<T> traversable)
Returns a topologically sorted list of all nodes in the graph.
|
static <T> com.google.common.collect.ImmutableList<T> |
sort(TraversableGraph<T> graph)
Returns a topologically sorted list of the nodes in the graph.
|
public static <T> com.google.common.collect.ImmutableList<T> sort(TraversableGraph<T> graph)
public static <T> com.google.common.collect.ImmutableList<? extends T> sort(Iterable<? extends T> roots, TopologicalSort.Traversable<T> traversable)
@Deprecated public static <T> com.google.common.collect.ImmutableList<? extends T> snowflakeSort(Iterable<? extends T> roots, TopologicalSort.Traversable<T> traversable, Comparator<T> comparator)