ONOS-2947 Improvements to HostService

- Added ability to replace IPs for existing hosts to HostProviderService
- Moved createOrUpdateHost to use compute() (rather than get/set) in HostStore

Change-Id: I8ac035d010ae65f23158d2237f9fc97c8f811dd4
diff --git a/core/api/src/main/java/org/onosproject/net/host/HostProviderService.java b/core/api/src/main/java/org/onosproject/net/host/HostProviderService.java
index 8678a29..f7b7c49 100644
--- a/core/api/src/main/java/org/onosproject/net/host/HostProviderService.java
+++ b/core/api/src/main/java/org/onosproject/net/host/HostProviderService.java
@@ -30,7 +30,20 @@
      * @param hostId          id of the host that been detected
      * @param hostDescription description of host and its location
      */
-    void hostDetected(HostId hostId, HostDescription hostDescription);
+    @Deprecated
+    default void hostDetected(HostId hostId, HostDescription hostDescription) {
+        hostDetected(hostId, hostDescription, false);
+    }
+
+    /**
+     * Notifies the core when a host has been detected on a network along with
+     * information that identifies the host location.
+     *
+     * @param hostId          id of the host that been detected
+     * @param hostDescription description of host and its location
+     * @param replaceIps      replace IP set if true, merge IP set otherwise
+     */
+    void hostDetected(HostId hostId, HostDescription hostDescription, boolean replaceIps);
 
     /**
      * Notifies the core when a host is no longer detected on a network.