RTEditor/src/main/java/com/onegravity/rteditor/converter/tagsoup/HTMLWriter.java
private void writeEscUTF16(String s, int start, int length, boolean isAttVal) throws SAXException {
        String subString = s.substring(start, start + length);
        write(StringEscapeUtils.escapeHtml4(subString));
    }
private void writeEscUTF16(String s, int start, int length, boolean isAttVal) throws SAXException {
        String subString = s.substring(start, start + length);
        write(StringEscapeUtils.escapeHtml4(subString));
    }
Write an array of data characters with escaping.

@param ch       The array of characters.
@param start    The starting position.
@param length   The number of characters to use.
@param isAttVal true if this is an attribute value literal.
@throws org.xml.SAXException If there is an error writing the characters, this method
will throw an IOException wrapped in a SAXException.