Break the references between Port and Link.

This is in preparation for implementing topology versioning. Ports may have
different Links in different versions of the topology, so we don't want the
reference inside the Port object. References are now held in indexes in the
NetworkGraphImpl.

As a result of this, there was a small API change:
  NetworkGraph.getLink  ->  NetworkGraph.getOutgoingLink
  NetworkGraph.getIncomingLink was added.

Change-Id: I086d198c8040607253c8729b9d5f94ab6bc738db
diff --git a/src/main/java/net/onrc/onos/core/topology/SwitchImpl.java b/src/main/java/net/onrc/onos/core/topology/SwitchImpl.java
index 3fe053c..1e5e1e2 100644
--- a/src/main/java/net/onrc/onos/core/topology/SwitchImpl.java
+++ b/src/main/java/net/onrc/onos/core/topology/SwitchImpl.java
@@ -99,7 +99,7 @@
     @Override
     public Iterable<Link> getOutgoingLinks() {
         LinkedList<Link> links = new LinkedList<Link>();
-        for (Port port : getPorts()) {
+        for (Port port : ports.values()) {
             Link link = port.getOutgoingLink();
             if (link != null) {
                 links.add(link);
@@ -111,7 +111,7 @@
     @Override
     public Iterable<Link> getIncomingLinks() {
         LinkedList<Link> links = new LinkedList<Link>();
-        for (Port port : getPorts()) {
+        for (Port port : ports.values()) {
             Link link = port.getIncomingLink();
             if (link != null) {
                 links.add(link);