- public void leafSetEntryNode(final QName name, final Object value) {
- checkNotSealed();
-
- NormalizedNodeBuilderWrapper parent = stack.peek();
- if (parent != null) {
- if (hasValidSchema(name, parent)) {
- parent.builder().addChild(Builders.leafSetEntryBuilder().withValue(value)
- .withNodeIdentifier(new NodeWithValue<>(parent.nodeType(), value))
- .build());
- }
- } else {
- // If there's no parent LeafSetNode then this is a stand alone
- // LeafSetEntryNode.
- if (nodePathSchemaNode != null) {
- this.normalizedNode = Builders.leafSetEntryBuilder().withValue(value).withNodeIdentifier(
- new NodeWithValue<>(name, value)).build();
- }
-
- state = State.CLOSED;
- }
+ public void startLeafSetEntryNode(final NodeWithValue<?> name) throws IOException {
+ addBuilder(Builders.leafSetEntryBuilder().withNodeIdentifier(name), name);