
se.somath.publisher.formatter.HtmlEncoder Maven / Gradle / Ivy
package se.somath.publisher.formatter;
import java.util.LinkedList;
import java.util.List;
public class HtmlEncoder {
public List encode(List sourceCode) {
List result = new LinkedList();
for (String tmp : sourceCode) {
tmp = tmp.replaceAll("&", "&");
tmp = tmp.replaceAll("<", "<");
tmp = tmp.replaceAll(">", ">");
tmp = tmp.replaceAll("'", "'");
tmp = tmp.replaceAll("\"", """);
result.add(tmp);
}
return result;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy