Add "type" attributes to Topology elements

Add type attributes to Topology elements (ONOS-1575, ONOS-1391)
- add "type" as String attributes
- add "type" to JSON representation

Change-Id: I0ab790cfd18eba17e352780b336e5cd49c6fcb1e
diff --git a/src/main/java/net/onrc/onos/core/topology/PortImpl.java b/src/main/java/net/onrc/onos/core/topology/PortImpl.java
index 8a5e783..52dbe47 100644
--- a/src/main/java/net/onrc/onos/core/topology/PortImpl.java
+++ b/src/main/java/net/onrc/onos/core/topology/PortImpl.java
@@ -205,6 +205,6 @@
      */
     @Override
     public String getType() {
-        throw new UnsupportedOperationException("Not implemented yet");
+        return getStringAttribute(TopologyElement.TYPE, TopologyElement.TYPE_PACKET);
     }
 }