E - the graph edge typepublic static class SpanningTreeAlgorithm.SpanningTreeImpl<E> extends java.lang.Object implements SpanningTreeAlgorithm.SpanningTree<E>, java.io.Serializable
| Constructor and Description |
|---|
SpanningTreeImpl(java.util.Set<E> edges,
double weight)
Construct a new spanning tree.
|
| Modifier and Type | Method and Description |
|---|---|
java.util.Set<E> |
getEdges()
Set of edges of the spanning tree.
|
double |
getWeight()
Returns the weight of the spanning tree.
|
java.lang.String |
toString() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waititeratorpublic SpanningTreeImpl(java.util.Set<E> edges, double weight)
edges - the edgesweight - the weightpublic double getWeight()
SpanningTreeAlgorithm.SpanningTreegetWeight in interface SpanningTreeAlgorithm.SpanningTree<E>public java.util.Set<E> getEdges()
SpanningTreeAlgorithm.SpanningTreegetEdges in interface SpanningTreeAlgorithm.SpanningTree<E>public java.lang.String toString()
toString in class java.lang.ObjectCopyright © 2019. All Rights Reserved.