edu.uci.ics.jung.graph
Interface Element

All Superinterfaces:
Cloneable, UserDataContainer
All Known Subinterfaces:
ArchetypeEdge, ArchetypeVertex, DirectedEdge, Edge, GraphCollapser.CollapsedEdge, GraphCollapser.CollapsedVertex, Hyperedge, Hypervertex, UndirectedEdge, Vertex
All Known Implementing Classes:
AbstractArchetypeEdge, AbstractArchetypeVertex, AbstractElement, AbstractHyperedge, AbstractHypervertex, AbstractSparseEdge, AbstractSparseVertex, BipartiteEdge, BipartiteGraphCollapser.CollapsedBipartiteEdge, BipartiteGraphCollapser.CollapsedBipartiteVertex, BipartiteVertex, CollectionHyperedge, CollectionHypervertex, DirectedSparseEdge, DirectedSparseVertex, GraphCollapser.CollapsedSparseVertex, GraphCollapser.DirectedCollapsedEdge, GraphCollapser.UndirectedCollapsedEdge, HyperedgeBPG, HypervertexBPG, LazySparseVertex, LeanSparseVertex, ListHyperedge, ListHypervertex, SetHyperedge, SetHypervertex, SimpleDirectedSparseVertex, SimpleSparseVertex, SimpleUndirectedSparseVertex, SparseVertex, UndirectedSparseEdge, UndirectedSparseVertex

public interface Element
extends UserDataContainer

An interface for elements (vertices and edges) of generalized graphs. Allows code to be written that applies to both vertices and edges, when their structural role in a graph is not relevant (such as decorations).

Author:
Joshua O'Madadhain

Nested Class Summary
 
Nested classes/interfaces inherited from interface edu.uci.ics.jung.utils.UserDataContainer
UserDataContainer.CopyAction
 
Method Summary
 ArchetypeGraph getGraph()
          Returns a reference to the graph that contains this element.
 Set getIncidentElements()
          Returns the set of elements that are incident to this element.
 
Methods inherited from interface edu.uci.ics.jung.utils.UserDataContainer
addUserDatum, clone, containsUserDatumKey, getUserDatum, getUserDatumCopyAction, getUserDatumKeyIterator, importUserData, removeUserDatum, setUserDatum
 

Method Detail

getGraph

ArchetypeGraph getGraph()
Returns a reference to the graph that contains this element. If this element is not contained by any graph (is an "orphaned" element), returns null.


getIncidentElements

Set getIncidentElements()
Returns the set of elements that are incident to this element. For a vertex this corresponds to returning the vertex's incident edges; for an edge this corresponds to returning the edge's incident vertices.