- Type Parameters:
V
- the graph vertex typeE
- the graph edge type
- All Known Implementing Classes:
DefaultGraphMapping
,IsomorphicGraphMapping
public interface GraphMapping<V,E>
GraphMapping represents a bidirectional mapping between two graphs (called graph1 and graph2),
which allows the caller to obtain the matching vertex or edge in either direction, from graph1 to
graph2, or from graph2 to graph1. It does not have to always be a complete bidirectional mapping
(it could return null for some lookups).
- Author:
- Assaf Lehr
-
Method Summary
Modifier and TypeMethodDescriptiongetEdgeCorrespondence
(E edge, boolean forward) Gets the mapped value where the key isedge
getVertexCorrespondence
(V vertex, boolean forward) Gets the mapped value where the key isvertex
-
Method Details
-
getVertexCorrespondence
Gets the mapped value where the key isvertex
- Parameters:
vertex
- vertex in one of the graphsforward
- if true, uses mapping from graph1 to graph2; if false, use mapping from graph2 to graph1- Returns:
- corresponding vertex in other graph, or null if none
-
getEdgeCorrespondence
Gets the mapped value where the key isedge
- Parameters:
edge
- edge in one of the graphsforward
- if true, uses mapping from graph1 to graph2; if false, use mapping from graph2 to graph1- Returns:
- corresponding edge in other graph, or null if none
-