RTEditor/src/main/java/com/onegravity/rteditor/utils/io/IOUtils.java
public static char[] toCharArray(InputStream is, String encoding) throws IOException {
        return toCharArray(is, Charsets.toCharset(encoding));
    }
public static char[] toCharArray(InputStream is, String encoding) throws IOException {
        return toCharArray(is, Charsets.toCharset(encoding));
    }
public static char [ ] toCharArray ( InputStream is , String encoding ) throws IOException { return toCharArray ( is , Charsets . toCharset ( encoding ) ) ; }
Get the contents of an <code>InputStream</code> as a character array
using the specified character encoding.
<p/>
Character encoding names can be found at
<a href="http://www.iana.org/assignments/character-sets">IANA</a>.
<p/>
This method buffers the input internally, so there is no need to use a
<code>BufferedInputStream</code>.

@param is       the <code>InputStream</code> to read from
@param encoding the encoding to use, null means platform default
@return the requested character array
@throws NullPointerException        if the input is null
@throws IOException                 if an I/O error occurs
@throws UnsupportedCharsetException thrown instead of {@link UnsupportedEncodingException} in version 2.2 if the encoding is not
supported.
@since 1.1
Get the contents of an <code > InputStream< / code > as a character array using the specified character encoding . <p / > Character encoding names can be found at <a href = http : // www . iana . org / assignments / character - sets > IANA< / a > . <p / > This method buffers the input internally so there is no need to use a <code > BufferedInputStream< / code > .