Enable checkstyle in yang-model-util
[yangtools.git] / yang / yang-model-util / src / main / java / org / opendaylight / yangtools / yang / model / util / DataNodeIterator.java
index b3fcbed4f0f426530542e0914bd4fe5b5408204e..1c7543cf322d7e286cd00828b635ca54180d4334 100644 (file)
@@ -28,10 +28,8 @@ import org.opendaylight.yangtools.yang.model.api.TypeDefinition;
  * DataNodeIterator is iterator, which walks down whole YANG DataNodeContainer
  * and walks all instances of {@link DataSchemaNode} present in subtree.
  *
- * Iterator instance is eagerly created, walking happens on initialization.
- *
- * Iteration is not ordered.
- *
+ * <p>
+ * Iterator instance is eagerly created, walking happens on initialization. Iteration is not ordered.
  */
 public class DataNodeIterator implements Iterator<DataSchemaNode> {
 
@@ -163,8 +161,8 @@ public class DataNodeIterator implements Iterator<DataSchemaNode> {
             if (input != null) {
                 traverse(input);
             }
-            ContainerSchemaNode output = rpcDefinition.getInput();
-            if (input != null) {
+            ContainerSchemaNode output = rpcDefinition.getOutput();
+            if (output != null) {
                 traverse(output);
             }
         }