N - The type of Node stored in this GraphET - The type of Edge stored in this Graphpublic interface Graph<N,ET extends Edge<N>>
| Modifier and Type | Method and Description | 
|---|---|
| boolean | addEdge(ET edge)Adds the given Edge to the Graph. | 
| void | addGraphChangeListener(GraphChangeListener<N,ET> listener)Adds a new GraphChangeListener to receive GraphChangeEvents
 (EdgeChangeEvent and NodeChangeEvent) from this Graph. | 
| boolean | addNode(N node)Adds the given Node to the Graph. | 
| void | clear()Clears this Graph, removing all Nodes and Edges from the Graph. | 
| boolean | containsEdge(Edge<?> edge)Returns true if this Graph contains the given Edge in the Graph. | 
| boolean | containsNode(java.lang.Object obj)Returns true if this Graph contains the given Object as a Node in the
 Graph. | 
| boolean | equals(java.lang.Object o)Tests to see if this Graph is equal to the provided Object. | 
| java.util.Collection<ET> | getAdjacentEdges(N node)Returns a Set of the Edges that are adjacent (connected) to the given
 Node. | 
| java.util.List<ET> | getEdgeList()Returns a List of the Edges in this Graph. | 
| GraphChangeListener<N,ET>[] | getGraphChangeListeners()Returns an Array of GraphChangeListeners receiving Graph Change Events
 from this Graph. | 
| int | getNodeCount()Returns a Count of the Nodes in this Graph. | 
| java.util.List<N> | getNodeList()Returns a List of the Nodes in this Graph. | 
| int | hashCode()Returns the hashCode for this Graph. | 
| boolean | isEmpty()Returns true if this Graph is empty (has no Nodes and no Edges); false
 otherwise. | 
| boolean | removeEdge(ET edge)Removes the given Edge from the Graph. | 
| void | removeGraphChangeListener(GraphChangeListener<N,ET> listener)Removes a GraphChangeListener so that it will no longer receive Graph
 Change Events from this Graph. | 
| boolean | removeNode(N node)Removes the given Node from the Graph. | 
boolean addNode(N node)
node - The Node to add to the Graphboolean addEdge(ET edge)
edge - The Edge to add to the Graphboolean containsNode(java.lang.Object obj)
obj - The Object to be tested to determine if it is a Node in the
            Graph.boolean containsEdge(Edge<?> edge)
edge - The Edge to be tested to determine if it is a Edge in the
            Graph.int getNodeCount()
java.util.List<N> getNodeList()
java.util.List<ET> getEdgeList()
boolean removeNode(N node)
node - The Node to remove from the Graphboolean removeEdge(ET edge)
edge - The Edge to remove from the Graphjava.util.Collection<ET> getAdjacentEdges(N node)
node - The Node for which the adjacent Edges should be returned.void addGraphChangeListener(GraphChangeListener<N,ET> listener)
listener - The GraphChangeListener to receive GraphChangeEventsGraphChangeListener<N,ET>[] getGraphChangeListeners()
void removeGraphChangeListener(GraphChangeListener<N,ET> listener)
listener - The GraphChangeListener to be removedint hashCode()
hashCode in class java.lang.Objectboolean equals(java.lang.Object o)
equals in class java.lang.Objecto - The Object to be tested for equality with this Graphboolean isEmpty()
void clear()