From: Michael Vorburger Date: Wed, 25 Jul 2018 21:47:46 +0000 (+0200) Subject: simplify a statement in NormalizedNodeInputStreamReader X-Git-Tag: release/fluorine~12 X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?p=controller.git;a=commitdiff_plain;h=ed5a75622bf00935e64fb3c177da2f6055833e3a simplify a statement in NormalizedNodeInputStreamReader and fix a JavaDoc warning in NormalizedNodeOutputStreamWriter Change-Id: I471dc3d4c8d1327fa8adaca89b8ca1d46036929d Signed-off-by: Michael Vorburger --- diff --git a/opendaylight/md-sal/sal-clustering-commons/src/main/java/org/opendaylight/controller/cluster/datastore/node/utils/stream/NormalizedNodeInputStreamReader.java b/opendaylight/md-sal/sal-clustering-commons/src/main/java/org/opendaylight/controller/cluster/datastore/node/utils/stream/NormalizedNodeInputStreamReader.java index cc744438ff..211f8b521f 100755 --- a/opendaylight/md-sal/sal-clustering-commons/src/main/java/org/opendaylight/controller/cluster/datastore/node/utils/stream/NormalizedNodeInputStreamReader.java +++ b/opendaylight/md-sal/sal-clustering-commons/src/main/java/org/opendaylight/controller/cluster/datastore/node/utils/stream/NormalizedNodeInputStreamReader.java @@ -214,12 +214,10 @@ public class NormalizedNodeInputStreamReader implements NormalizedNodeDataInput case NodeTypes.ORDERED_LEAF_SET: LOG.trace("Read ordered leaf set node {}", identifier); - ListNodeBuilder> orderedLeafSetBuilder = - Builders.orderedLeafSetBuilder().withNodeIdentifier(identifier); - orderedLeafSetBuilder = addLeafSetChildren(identifier.getNodeType(), orderedLeafSetBuilder); - return orderedLeafSetBuilder.build(); + return addLeafSetChildren(identifier.getNodeType(), + Builders.orderedLeafSetBuilder().withNodeIdentifier(identifier)).build(); - default : + default: return null; } } diff --git a/opendaylight/md-sal/sal-clustering-commons/src/main/java/org/opendaylight/controller/cluster/datastore/node/utils/stream/NormalizedNodeOutputStreamWriter.java b/opendaylight/md-sal/sal-clustering-commons/src/main/java/org/opendaylight/controller/cluster/datastore/node/utils/stream/NormalizedNodeOutputStreamWriter.java index b81de75bb5..40ca4f2e86 100644 --- a/opendaylight/md-sal/sal-clustering-commons/src/main/java/org/opendaylight/controller/cluster/datastore/node/utils/stream/NormalizedNodeOutputStreamWriter.java +++ b/opendaylight/md-sal/sal-clustering-commons/src/main/java/org/opendaylight/controller/cluster/datastore/node/utils/stream/NormalizedNodeOutputStreamWriter.java @@ -25,8 +25,8 @@ import org.opendaylight.yangtools.yang.common.Revision; * then will call * {@link #leafNode(org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier.NodeIdentifier, Object)} twice * and then, {@link #endNode()} to end container node. - *

- * Based on the each node, the node type is also written to the stream, that helps in reconstructing the object, + * + *

Based on the each node, the node type is also written to the stream, that helps in reconstructing the object, * while reading. */ final class NormalizedNodeOutputStreamWriter extends AbstractNormalizedNodeDataOutput {