[CORD-458] Updates ARP handler

Changes:
- SR application uses NRM;
- Adds hooks for ND protocol;
- Updates ARP handler to better leverage on NRM;
- Reworks to take into account IPv4/IPv6 together;

Change-Id: Iab55b8c5ef7d973928d8ad47e2c2a482fb9c5c8a
diff --git a/src/main/java/org/onosproject/segmentrouting/DefaultRoutingHandler.java b/src/main/java/org/onosproject/segmentrouting/DefaultRoutingHandler.java
index a689aec..4893684 100644
--- a/src/main/java/org/onosproject/segmentrouting/DefaultRoutingHandler.java
+++ b/src/main/java/org/onosproject/segmentrouting/DefaultRoutingHandler.java
@@ -21,7 +21,6 @@
 import com.google.common.collect.Maps;
 import com.google.common.collect.Sets;
 import org.onlab.packet.Ip4Address;
-import org.onlab.packet.Ip4Prefix;
 import org.onlab.packet.Ip6Address;
 import org.onlab.packet.IpPrefix;
 import org.onosproject.net.ConnectPoint;
@@ -505,7 +504,7 @@
      */
     private boolean populateEcmpRoutingRules(DeviceId destSw,
                                              EcmpShortestPathGraph ecmpSPG,
-                                             Set<Ip4Prefix> subnets) {
+                                             Set<IpPrefix> subnets) {
 
         HashMap<Integer, HashMap<DeviceId, ArrayList<ArrayList<DeviceId>>>> switchVia = ecmpSPG
                 .getAllLearnedSwitchesAndVia();
@@ -543,7 +542,7 @@
     private boolean populateEcmpRoutingRulePartial(DeviceId targetSw,
                                                    DeviceId destSw,
                                                    Set<DeviceId> nextHops,
-                                                   Set<Ip4Prefix> subnets) {
+                                                   Set<IpPrefix> subnets) {
         boolean result;
 
         if (nextHops.isEmpty()) {
@@ -704,7 +703,7 @@
      * @param subnets subnet being added
      * @return true if succeed
      */
-    protected boolean populateSubnet(ConnectPoint cp, Set<Ip4Prefix> subnets) {
+    protected boolean populateSubnet(ConnectPoint cp, Set<IpPrefix> subnets) {
         statusLock.lock();
         try {
             EcmpShortestPathGraph ecmpSpg = currentEcmpSpgMap.get(cp.deviceId());
@@ -724,7 +723,7 @@
      * @param subnets subnet being removed
      * @return true if succeed
      */
-    protected boolean revokeSubnet(Set<Ip4Prefix> subnets) {
+    protected boolean revokeSubnet(Set<IpPrefix> subnets) {
         statusLock.lock();
         try {
             return srManager.routingRulePopulator.revokeIpRuleForSubnet(subnets);