class StripHtmlSanitizer implements Sanitizer<String> {

    @Override
    public String execute(String content) {
        if (StringUtils.isBlank(content)) {
            return content;
        }
        Document document = Jsoup.parse(content);
        document.outputSettings().escapeMode(Entities.EscapeMode.xhtml);
        for (Element element : document.select("script,link,iframe,style")) {
            element.remove();
        }
        return document.text();
    }

}