Minor fix in XmlDocumentUtils. 17/4817/2
authorLukas Sedlak <lsedlak@cisco.com>
Sun, 26 Jan 2014 18:26:39 +0000 (19:26 +0100)
committerGerrit Code Review <gerrit@opendaylight.org>
Sun, 26 Jan 2014 19:36:29 +0000 (19:36 +0000)
Fixed notificationToDomNodes - root node now constructs from NotificationDefinition in SchemaContext and has correct QName with revision.

Signed-off-by: Lukas Sedlak <lsedlak@cisco.com>
yang/yang-data-impl/src/main/java/org/opendaylight/yangtools/yang/data/impl/codec/xml/XmlDocumentUtils.java

index 354d0c1a95ad7ec64d7e16111d64dfaddf405b12..2fb4a44c8a573dcc0a95ff500a8168b9e0147e42 100644 (file)
@@ -460,7 +460,7 @@ public class XmlDocumentUtils {
                         final Set<DataSchemaNode> dataNodes = notificationDef.get().getChildNodes();
                         final List<Node<?>> domNodes = toDomNodes(childElement,
                                 Optional.<Set<DataSchemaNode>> fromNullable(dataNodes));
-                        return ImmutableCompositeNode.create(partialQName, domNodes);
+                        return ImmutableCompositeNode.create(notificationDef.get().getQName(), domNodes);
                     }
                 }
             }