- java.lang.Object
-
- it.unive.lisa.util.datastructures.graph.algorithms.Fixpoint<G,N,E,T>
-
- Type Parameters:
G
- the type of the sourceGraph
N
- the type of theNode
s in the source graphE
- the type of theEdge
s in the source graphT
- the type of data computed by the fixpoint
public class Fixpoint<G extends Graph<G,N,E>,N extends Node<G,N,E>,E extends Edge<G,N,E>,T> extends java.lang.Object
A fixpoint algorithm for aGraph
, parametric to theFixpoint.FixpointImplementation
that one wants to use to compute the results.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
Fixpoint.FixpointImplementation<N,E,T>
Concrete implementation of the general methods used by a fixpoint algorithm to perform.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Map<N,T>
fixpoint(java.util.Map<N,T> startingPoints, WorkingSet<N> ws, Fixpoint.FixpointImplementation<N,E,T> implementation)
Runs the fixpoint.
-
-
-
Method Detail
-
fixpoint
public java.util.Map<N,T> fixpoint(java.util.Map<N,T> startingPoints, WorkingSet<N> ws, Fixpoint.FixpointImplementation<N,E,T> implementation) throws FixpointException
Runs the fixpoint. Invoking this method effectively recomputes the result: no caching on previous runs is executed.- Parameters:
startingPoints
- a map containing all the nodes to start the fixpoint at, each mapped to its entry state.ws
- the instance ofWorkingSet
to use for the fixpointimplementation
- theFixpoint.FixpointImplementation
to use for running the fixpoint- Returns:
- a mapping from each (reachable) node of the source graph to the fixpoint result computed at that node
- Throws:
FixpointException
- if something goes wrong during the fixpoint execution
-
-