Package it.unimi.di.prog2.h25.digraph
Class Arc<T>
java.lang.Object
it.unimi.di.prog2.h25.digraph.Arc<T>
- Type Parameters:
T
- the type of the graph nodes.
An arc of a directed graph with nodes of type
T
.
This is an immutable value class: arcs with the same sources and destinations are equal.
-
Field Summary
-
Constructor Summary
-
Method Summary
-
Field Details
-
source
-
destination
-
-
Constructor Details
-
Arc
Creates an arc.- Parameters:
source
- the arc source.destination
- the arc destination.
-
-
Method Details
-
equals
Tells whether this arc is equal to the given object, or not.This arc is equal to
obj
iff it is anArc
with the same source and destination of this one. -
hashCode
public int hashCode() -
toString
-