|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.savarese.algorithms.graph.Edge<V,W>
public class Edge<V,W>
An Edge represents a directed or undirected connection between two vertices with an associated weight. The vertices can be interpreted as source and destination in the case of a directed edge or simply as endpoints in the case of an undirected edge.
| Constructor Summary | |
|---|---|
Edge(V src,
V dest,
W weight)
Creates an Edge between source and destination vertices, assigning a weight to the link. |
|
| Method Summary | |
|---|---|
V |
getDestination()
Returns the destination vertex. |
V |
getSource()
Returns the source vertex. |
W |
getWeight()
Returns the edge weight. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Edge(V src,
V dest,
W weight)
src - The source vertex.dest - The destination vertex.weight - The weight associated with the edge.| Method Detail |
|---|
public V getSource()
public V getDestination()
public W getWeight()
|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||