Skip to content
Snippets Groups Projects
Commit bae8d55b authored by Andreas Romeyke's avatar Andreas Romeyke
Browse files

- minor improvements

parent cf8fd96f
No related branches found
No related tags found
No related merge requests found
Pipeline #3628 passed
...@@ -67,7 +67,8 @@ public class SLUBXmlFormatValidationPlugin implements FormatValidationPlugin { ...@@ -67,7 +67,8 @@ public class SLUBXmlFormatValidationPlugin implements FormatValidationPlugin {
Document doc = db.parse(new File(namespaceSchemaMapFile)); Document doc = db.parse(new File(namespaceSchemaMapFile));
Element de = doc.getDocumentElement(); Element de = doc.getDocumentElement();
NodeList nodes = de.getElementsByTagName("entry"); NodeList nodes = de.getElementsByTagName("entry");
for (int i = 0; i < nodes.getLength(); i++) { var nodesize = nodes.getLength();
for (int i = 0; i < nodesize; i++) {
Node n = nodes.item(i); Node n = nodes.item(i);
NamedNodeMap attributes = n.getAttributes(); NamedNodeMap attributes = n.getAttributes();
List<String> attr_strings = List.of(new String[]{"schematype", "namespace", "schemaurl"}); List<String> attr_strings = List.of(new String[]{"schematype", "namespace", "schemaurl"});
...@@ -279,7 +280,7 @@ public class SLUBXmlFormatValidationPlugin implements FormatValidationPlugin { ...@@ -279,7 +280,7 @@ public class SLUBXmlFormatValidationPlugin implements FormatValidationPlugin {
return result; return result;
} }
private boolean checkIfWellformed(Document doc) throws ParserConfigurationException, IOException, SAXException { private boolean checkIfWellformed(Document doc) {
/* detect XML type via NS */ /* detect XML type via NS */
boolean isWellformedXml = false; boolean isWellformedXml = false;
XmlInfoRecord info = getXMLinfo(doc); XmlInfoRecord info = getXMLinfo(doc);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment