From a7654ae09a1a094e796597d3ffe4aaa4a3043818 Mon Sep 17 00:00:00 2001 From: Jakub Morvay Date: Mon, 15 Aug 2016 15:25:13 +0200 Subject: [PATCH] BUG-865: remove String-based getDataChildByName() Some classes still implement String-based getDataChildByName method. Get rid of this method implementations. Change-Id: Ib8c458ec380262957b4bdc4e3b4f3e500f31d8f4 Signed-off-by: Jakub Morvay --- .../sal/connect/netconf/util/NodeContainerProxy.java | 5 ----- .../sal/restconf/impl/ContainerSchemaNodeImpl.java | 10 ---------- .../netconf/sal/restconf/impl/ModuleImpl.java | 10 ---------- .../rest/services/impl/ContainerSchemaNodeImpl.java | 10 ---------- .../restconf/rest/services/impl/ModuleImpl.java | 10 ---------- 5 files changed, 45 deletions(-) diff --git a/netconf/sal-netconf-connector/src/main/java/org/opendaylight/netconf/sal/connect/netconf/util/NodeContainerProxy.java b/netconf/sal-netconf-connector/src/main/java/org/opendaylight/netconf/sal/connect/netconf/util/NodeContainerProxy.java index 65f486cd46..829bac6847 100644 --- a/netconf/sal-netconf-connector/src/main/java/org/opendaylight/netconf/sal/connect/netconf/util/NodeContainerProxy.java +++ b/netconf/sal-netconf-connector/src/main/java/org/opendaylight/netconf/sal/connect/netconf/util/NodeContainerProxy.java @@ -80,11 +80,6 @@ public final class NodeContainerProxy implements ContainerSchemaNode { return childNodes.get(qName); } - @Override - public DataSchemaNode getDataChildByName(final String s) { - throw new UnsupportedOperationException(); - } - @Override public Set getUses() { return Collections.emptySet(); diff --git a/restconf/sal-rest-connector/src/main/java/org/opendaylight/netconf/sal/restconf/impl/ContainerSchemaNodeImpl.java b/restconf/sal-rest-connector/src/main/java/org/opendaylight/netconf/sal/restconf/impl/ContainerSchemaNodeImpl.java index d589f94d3e..3f25fb9c0b 100644 --- a/restconf/sal-rest-connector/src/main/java/org/opendaylight/netconf/sal/restconf/impl/ContainerSchemaNodeImpl.java +++ b/restconf/sal-rest-connector/src/main/java/org/opendaylight/netconf/sal/restconf/impl/ContainerSchemaNodeImpl.java @@ -59,16 +59,6 @@ class ContainerSchemaNodeImpl implements ContainerSchemaNode { throw new RestconfDocumentedException(name + " is not in child of " + this.qname); } - @Override - public DataSchemaNode getDataChildByName(final String name) { - for (final DataSchemaNode node : this.child) { - if (node.getQName().getLocalName().equals(name)) { - return node; - } - } - throw new RestconfDocumentedException(name + " is not in child of " + this.qname); - } - @Override public Set getUses() { throw new UnsupportedOperationException("Not supported."); diff --git a/restconf/sal-rest-connector/src/main/java/org/opendaylight/netconf/sal/restconf/impl/ModuleImpl.java b/restconf/sal-rest-connector/src/main/java/org/opendaylight/netconf/sal/restconf/impl/ModuleImpl.java index a88917dc9e..4f7fa52f29 100644 --- a/restconf/sal-rest-connector/src/main/java/org/opendaylight/netconf/sal/restconf/impl/ModuleImpl.java +++ b/restconf/sal-rest-connector/src/main/java/org/opendaylight/netconf/sal/restconf/impl/ModuleImpl.java @@ -95,16 +95,6 @@ class ModuleImpl implements Module { throw new RestconfDocumentedException(name + " is not in child of " + ModuleImpl.moduleQName); } - @Override - public DataSchemaNode getDataChildByName(final String name) { - for (final DataSchemaNode node : this.listChild) { - if (node.getQName().getLocalName().equals(name)) { - return node; - } - } - throw new RestconfDocumentedException(name + " is not in child of " + ModuleImpl.moduleQName); - } - @Override public Set getUses() { throw new UnsupportedOperationException("Not supported operations."); diff --git a/restconf/sal-rest-connector/src/main/java/org/opendaylight/restconf/rest/services/impl/ContainerSchemaNodeImpl.java b/restconf/sal-rest-connector/src/main/java/org/opendaylight/restconf/rest/services/impl/ContainerSchemaNodeImpl.java index cf85579121..eb44432c54 100644 --- a/restconf/sal-rest-connector/src/main/java/org/opendaylight/restconf/rest/services/impl/ContainerSchemaNodeImpl.java +++ b/restconf/sal-rest-connector/src/main/java/org/opendaylight/restconf/rest/services/impl/ContainerSchemaNodeImpl.java @@ -62,16 +62,6 @@ class ContainerSchemaNodeImpl implements ContainerSchemaNode { throw new RestconfDocumentedException(name + " is not in child of " + this.qname); } - @Override - public DataSchemaNode getDataChildByName(final String name) { - for (final DataSchemaNode node : this.child) { - if (node.getQName().getLocalName().equals(name)) { - return node; - } - } - throw new RestconfDocumentedException(name + " is not in child of " + this.qname); - } - @Override public Set getUses() { throw new UnsupportedOperationException("Not supported."); diff --git a/restconf/sal-rest-connector/src/main/java/org/opendaylight/restconf/rest/services/impl/ModuleImpl.java b/restconf/sal-rest-connector/src/main/java/org/opendaylight/restconf/rest/services/impl/ModuleImpl.java index f66b6e9c72..b8033bbace 100644 --- a/restconf/sal-rest-connector/src/main/java/org/opendaylight/restconf/rest/services/impl/ModuleImpl.java +++ b/restconf/sal-rest-connector/src/main/java/org/opendaylight/restconf/rest/services/impl/ModuleImpl.java @@ -96,16 +96,6 @@ class ModuleImpl implements Module { throw new RestconfDocumentedException(name + " is not in child of " + ModuleImpl.moduleQName); } - @Override - public DataSchemaNode getDataChildByName(final String name) { - for (final DataSchemaNode node : this.listChild) { - if (node.getQName().getLocalName().equals(name)) { - return node; - } - } - throw new RestconfDocumentedException(name + " is not in child of " + ModuleImpl.moduleQName); - } - @Override public Set getUses() { throw new UnsupportedOperationException("Not supported operations."); -- 2.36.6