Migrate users of deprecated QNameModule methods
[yangtools.git] / parser / yang-parser-reactor / src / main / java / org / opendaylight / yangtools / yang / parser / stmt / reactor / SourceSpecificContext.java
index 17944e12d5d6b262a6229cd8fbfbbd9d5569ab47..5819631828edb0a3ee520d837b9be6a4cef164f5 100644 (file)
@@ -212,7 +212,7 @@ final class SourceSpecificContext implements NamespaceStorage, Mutable {
         final var module = root.namespaceItem(ParserNamespaces.MODULECTX_TO_QNAME, root);
         if (module != null) {
             // creates SourceIdentifier for a module
-            return new SourceIdentifier(unqualified, module.getRevision().orElse(null));
+            return new SourceIdentifier(unqualified, module.revision());
         }
 
         // creates SourceIdentifier for a submodule
@@ -466,7 +466,7 @@ final class SourceSpecificContext implements NamespaceStorage, Mutable {
             return null;
         }
 
-        prefixToNamespaceMap.forEach((key, value) -> preLinkagePrefixes.put(key, QNameModule.create(value)));
+        prefixToNamespaceMap.forEach((key, value) -> preLinkagePrefixes.put(key, QNameModule.of(value)));
         return preLinkagePrefixes;
     }