Package com.jgalgo.alg.shortestpath
Class SimplePathsEnumeratorAbstract
- java.lang.Object
-
- com.jgalgo.alg.shortestpath.SimplePathsEnumeratorAbstract
-
- All Implemented Interfaces:
SimplePathsEnumerator
- Direct Known Subclasses:
SimplePathsEnumeratorSedgewick
public abstract class SimplePathsEnumeratorAbstract extends Object implements SimplePathsEnumerator
Abstract class for enumerating all simple paths between a source and target vertices.The class implements the interface by solving the problem on the index graph and then maps the results back to the original graph. The implementation for index graphs is abstract and left to the subclasses.
- Author:
- Barak Ugav
-
-
Constructor Summary
Constructors Constructor Description SimplePathsEnumeratorAbstract()
Default constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description <V,E>
Iterator<Path<V,E>>simplePathsIter(Graph<V,E> g, V source, V target)
Iterate over all the simple paths between a source and a target vertices in the given graph.-
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.jgalgo.alg.shortestpath.SimplePathsEnumerator
allSimplePaths
-
-
-
-
Method Detail
-
simplePathsIter
public <V,E> Iterator<Path<V,E>> simplePathsIter(Graph<V,E> g, V source, V target)
Description copied from interface:SimplePathsEnumerator
Iterate over all the simple paths between a source and a target vertices in the given graph.If
g
is anIntGraph
, an iterator ofIPath
objects will be returned.- Specified by:
simplePathsIter
in interfaceSimplePathsEnumerator
- Type Parameters:
V
- the vertices typeE
- the edges type- Parameters:
g
- a graphsource
- the source vertextarget
- the target vertex- Returns:
- an iterator that iteration over all simple paths between the two vertices in the graph
-
-