Bump versions to 4.0.0-SNAPSHOT
[netconf.git] / restconf / restconf-nb-bierman02 / src / test / java / org / opendaylight / controller / sal / restconf / impl / test / incubate / InMemoryMdsalModule.java
index fba66a033964970afb38b4be92b34ebc40b082a4..cabdc6ce77db2c6ee815b4608f24b851b3560ed7 100644 (file)
@@ -25,7 +25,7 @@ import org.opendaylight.mdsal.dom.broker.DOMNotificationRouter;
 import org.opendaylight.mdsal.dom.broker.DOMRpcRouter;
 import org.opendaylight.mdsal.dom.spi.DOMNotificationSubscriptionListenerRegistry;
 import org.opendaylight.mdsal.dom.store.inmemory.InMemoryDOMDataStore;
-import org.opendaylight.yangtools.yang.model.api.SchemaContextProvider;
+import org.opendaylight.yangtools.yang.model.api.EffectiveModelContextProvider;
 
 /**
  * Guice Module which binds the mdsal (not controller) {@link DataBroker} & Co.
@@ -33,7 +33,8 @@ import org.opendaylight.yangtools.yang.model.api.SchemaContextProvider;
  *
  * <p>This class is here only temporarily and it can and should be removed and
  * replaced when the equivalent will be offered by the mdsal project itself; see
- * <a href="https://jira.opendaylight.org/browse/MDSAL-418">MDSAL-418</a>.
+ * <a href="https://jira.opendaylight.org/browse/MDSAL-418">MDSAL-418</a>.  It is
+ * also copy/pasted to org.opendaylight.restconf.nb.rfc8040.test.incubate.InMemoryMdsalModule.
  *
  * <p>BEWARE: Do *NOT* use this module in component tests or applications mixing
  * code requiring the old controller and the new mdsal {@link DataBroker} & Co.
@@ -84,10 +85,10 @@ public class InMemoryMdsalModule extends AbstractModule {
     }
 
     @Provides
-    @Singleton SchemaContextProvider getSchemaContextProvider() {
+    @Singleton EffectiveModelContextProvider getSchemaContextProvider() {
         DOMSchemaService schemaService = dataBrokerTest.getDataBrokerTestCustomizer().getSchemaService();
-        if (schemaService instanceof SchemaContextProvider) {
-            return (SchemaContextProvider) schemaService;
+        if (schemaService instanceof EffectiveModelContextProvider) {
+            return (EffectiveModelContextProvider) schemaService;
         }
         throw new IllegalStateException(
                 "The schema service isn't a SchemaContextProvider, it's a " + schemaService.getClass());