Replace IOUtils with IOUtil

plsql, xml, apex, html, javascript, scala
This commit is contained in:
Andreas Dangel
2022-05-13 10:46:11 +02:00
parent abfc463ef9
commit a4ebb66769
6 changed files with 11 additions and 15 deletions

View File

@@ -10,7 +10,6 @@ import java.io.Reader;
import java.util.HashMap;
import java.util.Map;
import org.apache.commons.io.IOUtils;
import org.jsoup.nodes.Document;
import org.jsoup.parser.Parser;
@@ -18,6 +17,7 @@ import net.sourceforge.pmd.lang.ParserOptions;
import net.sourceforge.pmd.lang.TokenManager;
import net.sourceforge.pmd.lang.ast.Node;
import net.sourceforge.pmd.lang.ast.ParseException;
import net.sourceforge.pmd.util.IOUtil;
public final class HtmlParser implements net.sourceforge.pmd.lang.Parser {
@@ -29,7 +29,7 @@ public final class HtmlParser implements net.sourceforge.pmd.lang.Parser {
@Override
public Node parse(String fileName, Reader source) throws ParseException {
try {
String data = IOUtils.toString(source);
String data = IOUtil.readToString(source);
Document doc = Parser.xmlParser().parseInput(data, "");
HtmlTreeBuilder builder = new HtmlTreeBuilder();
return builder.build(doc, data);