Skip to content

Commit

Permalink
Change SAXParserFactory to a one comaptible with java 17 and greater
Browse files Browse the repository at this point in the history
  • Loading branch information
rubencodacy committed Feb 23, 2023
1 parent fddc44e commit 3b17a3e
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
package com.codacy.parsers.util

import scala.xml.factory.XMLLoader
import javax.xml.parsers.SAXParserFactory
import scala.xml.{Elem, SAXParser}

object XMLoader extends XMLLoader[Elem] {

override def parser: SAXParser = {
val f = new com.sun.org.apache.xerces.internal.jaxp.SAXParserFactoryImpl()
val f = SAXParserFactory.newInstance()
f.setNamespaceAware(false)
f.setValidating(false)
f.setFeature("http://xml.org/sax/features/namespaces", false)
Expand Down

0 comments on commit 3b17a3e

Please sign in to comment.