Scripted update of if statements
[yangtools.git] / yang / yang-data-impl / src / main / java / org / opendaylight / yangtools / yang / data / impl / schema / builder / impl / ImmutableChoiceNodeSchemaAwareBuilder.java
index 09fd662004fa16759d94de72d96f32f645043636..037e406a3d1c6356634580792b3b246e13e36230 100644 (file)
@@ -26,7 +26,7 @@ public class ImmutableChoiceNodeSchemaAwareBuilder extends ImmutableChoiceNodeBu
 
     protected ImmutableChoiceNodeSchemaAwareBuilder(final ChoiceSchemaNode schema) {
         this.schema = Preconditions.checkNotNull(schema, "Schema was null");
-        super.withNodeIdentifier(new NodeIdentifier(schema.getQName()));
+        super.withNodeIdentifier(NodeIdentifier.create(schema.getQName()));
     }
 
     @Override
@@ -36,7 +36,7 @@ public class ImmutableChoiceNodeSchemaAwareBuilder extends ImmutableChoiceNodeBu
 
     @Override
     public DataContainerNodeBuilder<NodeIdentifier, ChoiceNode> withChild(final DataContainerChild<?, ?> child) {
-        if(validator == null) {
+        if (validator == null) {
             Optional<ChoiceCaseNode> detectedCaseOpt = SchemaUtils.detectCase(schema, child);
             DataValidationException.checkLegalChild(detectedCaseOpt.isPresent(), child.getIdentifier(), schema);
             validator = new DataNodeContainerValidator(detectedCaseOpt.get());