Make ModuleEffectiveStatement.localQNameModule() mandatory 82/80582/3
authorRobert Varga <robert.varga@pantheon.tech>
Mon, 25 Feb 2019 13:41:23 +0000 (14:41 +0100)
committerRobert Varga <robert.varga@pantheon.tech>
Mon, 25 Feb 2019 14:08:23 +0000 (15:08 +0100)
This removes an API design hack, so that we require localQNameModule()
to be implemented.

Change-Id: Ic152a358d2d3b4b758a41b09901a83e4d989ed61
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
yang/yang-model-api/src/main/java/org/opendaylight/yangtools/yang/model/api/stmt/ModuleEffectiveStatement.java

index af5f42b30da10a89064832255fc6bdae413badfb..90be118c7864b3680021dea2b0dc4ebad43c692c 100644 (file)
@@ -16,7 +16,7 @@ import org.opendaylight.yangtools.yang.model.api.meta.IdentifierNamespace;
  * Effective view of a {@link ModuleStatement}.
  */
 @Beta
-// FIXME: 3.0.0: we should reshuffle the String here, as module name is in reality a YANG identifier, e.g. not just
+// FIXME: 4.0.0: we should reshuffle the String here, as module name is in reality a YANG identifier, e.g. not just
 //               an ordinary String. We really want this to be a QName, so that we do not need the localQNameModule
 //               bit, but that may be problematic with ModuleStatement, which is getting created before we even know
 //               the namespace :( A type capture of the string may just be sufficient.
@@ -57,8 +57,5 @@ public interface ModuleEffectiveStatement extends DataTreeAwareEffectiveStatemen
      *
      * @return Local QNameModule
      */
-    // FIXME: 3.0.0 make this method non-default.
-    default @NonNull QNameModule localQNameModule() {
-        throw new UnsupportedOperationException(getClass() + " is missing an implementation");
-    }
+    @NonNull QNameModule localQNameModule();
 }