summaryrefslogtreecommitdiffstats
path: root/v3po/impl/src
diff options
context:
space:
mode:
Diffstat (limited to 'v3po/impl/src')
-rw-r--r--v3po/impl/src/main/java/io/fd/honeycomb/v3po/impl/VppIetfInterfaceListener.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/v3po/impl/src/main/java/io/fd/honeycomb/v3po/impl/VppIetfInterfaceListener.java b/v3po/impl/src/main/java/io/fd/honeycomb/v3po/impl/VppIetfInterfaceListener.java
index 9b84a00f4..481c0ef60 100644
--- a/v3po/impl/src/main/java/io/fd/honeycomb/v3po/impl/VppIetfInterfaceListener.java
+++ b/v3po/impl/src/main/java/io/fd/honeycomb/v3po/impl/VppIetfInterfaceListener.java
@@ -16,6 +16,7 @@
package io.fd.honeycomb.v3po.impl;
+import com.google.common.base.Splitter;
import java.util.Collection;
import org.opendaylight.controller.md.sal.binding.api.DataBroker;
import org.opendaylight.controller.md.sal.binding.api.DataObjectModification;
@@ -52,6 +53,7 @@ import org.slf4j.LoggerFactory;
public class VppIetfInterfaceListener implements DataTreeChangeListener<Interface>, AutoCloseable {
private static final Logger LOG = LoggerFactory.getLogger(VppIetfInterfaceListener.class);
+ private static final Splitter DOT_SPLITTER = Splitter.on('.');
private final ListenerRegistration<VppIetfInterfaceListener> registration;
private final DataBroker db;
@@ -220,7 +222,7 @@ public class VppIetfInterfaceListener implements DataTreeChangeListener<Interfac
int result = 0;
// iterate over each octet
- for (String part : address.split("\\.")) {
+ for (String part : DOT_SPLITTER.split(address)) {
// shift the previously parsed bits over by 1 byte
result = result << 8;
// set the low order bits to the current octet