Class AsSynchronizedGraph.CacheAccess
java.lang.Object
org.jgrapht.graph.concurrent.AsSynchronizedGraph.CacheAccess
- All Implemented Interfaces:
Serializable, AsSynchronizedGraph.CacheStrategy<V,E>
- Enclosing class:
AsSynchronizedGraph<V,E>
private class AsSynchronizedGraph.CacheAccess
extends Object
implements AsSynchronizedGraph.CacheStrategy<V,E>, Serializable
Use cache for AsSynchronizedGraph's
edgesOf, incomingEdgesOf and
outgoingEdgesOf methods.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final long -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionAdd an edge into AsSynchronizedGraph's backing graph.booleanAdd an edge into AsSynchronizedGraph's backing graph.private voidedgeModified(V sourceVertex, V targetVertex) Clear the copies which the edge to be added or removed can affect.Get all edges touching the specified vertex in AsSynchronizedGraph's backing graph.incomingEdgesOf(V vertex) Get a set of all edges in AsSynchronizedGraph's backing graph incoming into the specified vertex.booleanReturn whether the graph uses cache foredgesOf,incomingEdgesOfandoutgoingEdgesOfmethods.outgoingEdgesOf(V vertex) Get a set of all edges in AsSynchronizedGraph's backing graph outgoing from the specified vertex.booleanremoveEdge(E e) Remove the specified edge from AsSynchronizedGraph's backing graph.removeEdge(V sourceVertex, V targetVertex) Remove an edge from AsSynchronizedGraph's backing graph.booleanremoveVertex(V v) Remove the specified vertex from AsSynchronizedGraph's backing graph.
-
Field Details
-
serialVersionUID
private static final long serialVersionUID- See Also:
-
incomingEdgesMap
-
outgoingEdgesMap
-
edgesOfMap
-
-
Constructor Details
-
CacheAccess
private CacheAccess()
-
-
Method Details
-
addEdge
-
addEdge
-
edgesOf
-
incomingEdgesOf
Get a set of all edges in AsSynchronizedGraph's backing graph incoming into the specified vertex.- Specified by:
incomingEdgesOfin interfaceAsSynchronizedGraph.CacheStrategy<V,E>
-
outgoingEdgesOf
Get a set of all edges in AsSynchronizedGraph's backing graph outgoing from the specified vertex.- Specified by:
outgoingEdgesOfin interfaceAsSynchronizedGraph.CacheStrategy<V,E>
-
removeEdge
Remove the specified edge from AsSynchronizedGraph's backing graph.- Specified by:
removeEdgein interfaceAsSynchronizedGraph.CacheStrategy<V,E>
-
removeEdge
Remove an edge from AsSynchronizedGraph's backing graph.- Specified by:
removeEdgein interfaceAsSynchronizedGraph.CacheStrategy<V,E>
-
removeVertex
Remove the specified vertex from AsSynchronizedGraph's backing graph.- Specified by:
removeVertexin interfaceAsSynchronizedGraph.CacheStrategy<V,E>
-
edgeModified
-
isCacheEnabled
public boolean isCacheEnabled()Return whether the graph uses cache foredgesOf,incomingEdgesOfandoutgoingEdgesOfmethods.- Specified by:
isCacheEnabledin interfaceAsSynchronizedGraph.CacheStrategy<V,E> - Returns:
trueif cache is in use,falseif cache is not in use.
-