X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=restconf%2Frestconf-nb-rfc8040%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Frestconf%2Fnb%2Frfc8040%2Frests%2Ftransactions%2FMdsalRestconfTransaction.java;h=e6b93d2bb5eb6f246c247e9d8de4dd28d466f3d0;hb=4f8fe6ca68115fecdb9ce43573af5a2e26c50b50;hp=8c6a18a446a6598b26792db55ef2b42278229301;hpb=69b321b4b4180b4f7f03f30590ce36c78365b04f;p=netconf.git diff --git a/restconf/restconf-nb-rfc8040/src/main/java/org/opendaylight/restconf/nb/rfc8040/rests/transactions/MdsalRestconfTransaction.java b/restconf/restconf-nb-rfc8040/src/main/java/org/opendaylight/restconf/nb/rfc8040/rests/transactions/MdsalRestconfTransaction.java index 8c6a18a446..e6b93d2bb5 100644 --- a/restconf/restconf-nb-rfc8040/src/main/java/org/opendaylight/restconf/nb/rfc8040/rests/transactions/MdsalRestconfTransaction.java +++ b/restconf/restconf-nb-rfc8040/src/main/java/org/opendaylight/restconf/nb/rfc8040/rests/transactions/MdsalRestconfTransaction.java @@ -60,26 +60,24 @@ final class MdsalRestconfTransaction extends RestconfTransaction { } @Override - public void merge(final LogicalDatastoreType store, final YangInstanceIdentifier path, - final NormalizedNode data) { + public void merge(final LogicalDatastoreType store, final YangInstanceIdentifier path, final NormalizedNode data) { verifyNotNull(rwTx).merge(store, path, data); } @Override - public void create(final LogicalDatastoreType store, final YangInstanceIdentifier path, - final NormalizedNode data, final SchemaContext schemaContext) { + public void create(final LogicalDatastoreType store, final YangInstanceIdentifier path, final NormalizedNode data, + final SchemaContext schemaContext) { if (data instanceof MapNode || data instanceof LeafSetNode) { - final NormalizedNode emptySubTree = ImmutableNodes.fromInstanceId(schemaContext, path); + final NormalizedNode emptySubTree = ImmutableNodes.fromInstanceId(schemaContext, path); merge(LogicalDatastoreType.CONFIGURATION, YangInstanceIdentifier.create(emptySubTree.getIdentifier()), emptySubTree); TransactionUtil.ensureParentsByMerge(path, schemaContext, this); - final Collection> children = - ((NormalizedNodeContainer) data).getValue(); + final Collection children = ((NormalizedNodeContainer) data).body(); final BatchedExistenceCheck check = BatchedExistenceCheck.start(verifyNotNull(rwTx), LogicalDatastoreType.CONFIGURATION, path, children); - for (final NormalizedNode child : children) { + for (final NormalizedNode child : children) { final YangInstanceIdentifier childPath = path.node(child.getIdentifier()); verifyNotNull(rwTx).put(store, childPath, child); } @@ -94,15 +92,15 @@ final class MdsalRestconfTransaction extends RestconfTransaction { } @Override - public void replace(final LogicalDatastoreType store, final YangInstanceIdentifier path, - final NormalizedNode data, final SchemaContext schemaContext) { + public void replace(final LogicalDatastoreType store, final YangInstanceIdentifier path, final NormalizedNode data, + final SchemaContext schemaContext) { if (data instanceof MapNode || data instanceof LeafSetNode) { - final NormalizedNode emptySubtree = ImmutableNodes.fromInstanceId(schemaContext, path); + final NormalizedNode emptySubtree = ImmutableNodes.fromInstanceId(schemaContext, path); merge(LogicalDatastoreType.CONFIGURATION, YangInstanceIdentifier.create(emptySubtree.getIdentifier()), emptySubtree); TransactionUtil.ensureParentsByMerge(path, schemaContext, this); - for (final NormalizedNode child : ((NormalizedNodeContainer) data).getValue()) { + for (final NormalizedNode child : ((NormalizedNodeContainer) data).body()) { final YangInstanceIdentifier childPath = path.node(child.getIdentifier()); verifyNotNull(rwTx).put(store, childPath, child); }