|

true | obj â true Instance Public methods OrâReturns true. As anObject is an argument to a method call, it is always evaluated; there is no short-circuit evaluation in this case. true | puts("or") true || puts("logical or") produces: or

each_strongly_connected_component

each_strongly_connected_component() Instance Public methods The iterator version of the strongly_connected_components method. obj.each_strongly_connected_component is similar to obj.strongly_connected_components.each, but modification of obj during the iteration may lead to unexpected results. each_strongly_connected_component returns nil.

each_strongly_connected_component_from

each_strongly_connected_component_from(node, id_map={}, stack=[]) Instance Public methods Iterates over strongly connected component in the subgraph reachable from node. Return value is unspecified. each_strongly_connected_component_from doesn't call tsort_each_node.

strongly_connected_components

strongly_connected_components() Instance Public methods Returns strongly connected components as an array of arrays of nodes. The array is sorted from children to parents. Each elements of the array represents a strongly connected component.

tsort

tsort() Instance Public methods Returns a topologically sorted array of nodes. The array is sorted from children to parents, i.e. the first element has no child and the last node has no parent. If there is a cycle, TSort::Cyclic is raised.

tsort_each

tsort_each() Instance Public methods The iterator version of the tsort method. obj.tsort_each is similar to obj.tsort.each, but modification of obj during the iteration may lead to unexpected results. tsort_each returns nil. If there is a cycle, TSort::Cyclic is raised.

tsort_each_child

tsort_each_child(node) Instance Public methods Should be implemented by a extended class. tsort_each_child is used to iterate for child nodes of node.

tsort_each_node

tsort_each_node() Instance Public methods Should be implemented by a extended class. tsort_each_node is used to iterate for all nodes over a graph.

new

new(list) Class Public methods

match

match(tuple) Instance Public methods