Network Graph Refactoring: Northbound API cleanup
* Renamed/shortened methods:
Link.getSourcePort() -> getSrcPort()
Link.getDestinationPort() -> getDstPort()
Link.getSourceSwitch() -> getSrcSwitch()
Link.getDestinationSwitch() -> getDstSwitch()
* Added Javadoc comments
* Removed deprecated and unused methods:
Link.getSourceSwitchDpid()
Link.getSorcePortNumber()
Link.getDestinationSwitchDpid()
Link.getDestinationPortNumber()
NetworkGraph.getOutgoingLinksFromSwitch()
NetworkGraph.getIncomingLinksFromSwitch()
* Moved method LinkEvent.getLink(NetworkGraph graph)
to NetworkGraph.getLink()
Change-Id: Ibedba53fc6cd04d77f508ee67d41b2cfa515d3fc
diff --git a/src/main/java/net/onrc/onos/ofcontroller/networkgraph/Device.java b/src/main/java/net/onrc/onos/ofcontroller/networkgraph/Device.java
index cd5ddf8..c6e1ec2 100644
--- a/src/main/java/net/onrc/onos/ofcontroller/networkgraph/Device.java
+++ b/src/main/java/net/onrc/onos/ofcontroller/networkgraph/Device.java
@@ -15,12 +15,35 @@
*
*/
public interface Device {
- public MACAddress getMacAddress();
+ /**
+ * Get the device MAC address.
+ *
+ * @return the device MAC address.
+ */
+ public MACAddress getMacAddress();
- public Collection<InetAddress> getIpAddress();
+ /**
+ * Get the device IP addresses.
+ *
+ * @return the device IP addresses.
+ */
+ public Collection<InetAddress> getIpAddress();
- // Add requirement for Iteration order? Latest observed port first.
- public Iterable<Port> getAttachmentPoints();
+ /**
+ * Get the device attachment points.
+ *
+ * Add requirement for Iteration order? Latest observed port first.
+ *
+ * @return the device attachment points.
+ */
+ public Iterable<Port> getAttachmentPoints();
- public long getLastSeenTime();
+ /**
+ * Get the device last seen time.
+ *
+ * TODO: what is the time definition?
+ *
+ * @return the device last seen time.
+ */
+ public long getLastSeenTime();
}