diff options
Diffstat (limited to 'v3po/data-impl/src')
-rw-r--r-- | v3po/data-impl/src/main/java/io/fd/honeycomb/v3po/data/impl/OperationalDataTree.java | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/v3po/data-impl/src/main/java/io/fd/honeycomb/v3po/data/impl/OperationalDataTree.java b/v3po/data-impl/src/main/java/io/fd/honeycomb/v3po/data/impl/OperationalDataTree.java index 5d3b00646..175f22d34 100644 --- a/v3po/data-impl/src/main/java/io/fd/honeycomb/v3po/data/impl/OperationalDataTree.java +++ b/v3po/data-impl/src/main/java/io/fd/honeycomb/v3po/data/impl/OperationalDataTree.java @@ -34,7 +34,6 @@ import io.fd.honeycomb.v3po.translate.read.ReaderRegistry; import java.util.Collection; import java.util.Map; import javax.annotation.Nonnull; -import javax.annotation.Nullable; import org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType; import org.opendaylight.controller.md.sal.dom.api.DOMDataBroker; import org.opendaylight.controller.md.sal.dom.api.DOMDataReadOnlyTransaction; @@ -212,16 +211,13 @@ public final class OperationalDataTree implements ReadableDataTree { @SuppressWarnings("unchecked") private Function<DataObject, NormalizedNode<?, ?>> toNormalizedNodeFunction(final InstanceIdentifier path) { - return new Function<DataObject, NormalizedNode<?, ?>>() { - @Override - public NormalizedNode<?, ?> apply(@Nullable final DataObject dataObject) { - LOG.trace("OperationalDataTree.toNormalizedNode(), path={}, dataObject={}", path, dataObject); - final Map.Entry<YangInstanceIdentifier, NormalizedNode<?, ?>> entry = - serializer.toNormalizedNode(path, dataObject); - - LOG.trace("OperationalDataTree.toNormalizedNode(), normalizedNodeEntry={}", entry); - return entry.getValue(); - } + return dataObject -> { + LOG.trace("OperationalDataTree.toNormalizedNode(), path={}, dataObject={}", path, dataObject); + final Map.Entry<YangInstanceIdentifier, NormalizedNode<?, ?>> entry = + serializer.toNormalizedNode(path, dataObject); + + LOG.trace("OperationalDataTree.toNormalizedNode(), normalizedNodeEntry={}", entry); + return entry.getValue(); }; } |