com.twitter.summingbird

graph

package graph

Collection of graph algorithms

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. graph
  2. AnyRef
  3. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Type Members

  1. abstract class DependantGraph[T] extends AnyRef

    Given Dag and a List of immutable nodes, and a function to get dependencies, compute the dependants (reverse the graph)

  2. type NeighborFn[T] = (T) ⇒ Iterable[T]

Value Members

  1. def dagDepth[T](nodes: Iterable[T])(nf: (T) ⇒ Iterable[T]): Map[T, Int]

    Return the depth of each node in the dag.

    Return the depth of each node in the dag. a node that has no dependencies has depth == 0 else it is max of parent + 1

    Behavior is not defined if the graph is not a DAG (for now, it runs forever, may throw later)

  2. def depthFirstOf[T](t: T)(nf: (T) ⇒ Iterable[T]): List[T]

    Return the depth first enumeration of reachable nodes, NOT INCLUDING INPUT, unless it can be reached via neighbors

  3. def reversed[T](nodes: Iterable[T])(nf: (T) ⇒ Iterable[T]): (T) ⇒ Iterable[T]

    Return a NeighborFn for the graph of reversed edges defined by this set of nodes and nf We avoid Sets which use hash-codes which may depend on addresses which are not stable from one run to the next.

Inherited from AnyRef

Inherited from Any

Ungrouped