BUG-865: deprecated DataNodeContainer.getDataChildByName(String) 98/29498/2
authorRobert Varga <rovarga@cisco.com>
Tue, 10 Nov 2015 13:51:08 +0000 (14:51 +0100)
committerGerrit Code Review <gerrit@opendaylight.org>
Wed, 18 Nov 2015 08:32:51 +0000 (08:32 +0000)
This method cannot be implemented in a predictable way and the caller
needs to deal with QName ambiguity. Deprecate it, scheduling it for
later removal.

Change-Id: I708dcecf80a5e735410f3bbf5cd604ebd054b51d
Signed-off-by: Robert Varga <rovarga@cisco.com>
yang/yang-model-api/src/main/java/org/opendaylight/yangtools/yang/model/api/DataNodeContainer.java

index 8b15c979a276d1b8819b342c4152abb17a5da23d..de27fece30aa5ca7499c317cbb2b802645d8aba8 100644 (file)
@@ -9,7 +9,6 @@ package org.opendaylight.yangtools.yang.model.api;
 
 import java.util.Collection;
 import java.util.Set;
-
 import org.opendaylight.yangtools.yang.common.QName;
 
 /**
@@ -53,7 +52,11 @@ public interface DataNodeContainer {
      *            name of seeked child as String
      * @return child node of this DataNodeContainer if child with given name is
      *         present, null otherwise
+     *
+     * @deprecated This method disregards the namespace and thus leads to unpredictable results
+     *             when multiple children exist with the same localname, but with different namespaces.
      */
+    @Deprecated
     DataSchemaNode getDataChildByName(String name);
 
     /**