public static void write(Writer writer, CharSequence cs) throws IOException {
        if (null != cs && null != writer) {
            writer.write(cs.toString());
            writer.flush();
        }
    }
public static void write(Writer writer, CharSequence cs) throws IOException {
        if (null != cs && null != writer) {
            writer.write(cs.toString());
            writer.flush();
        }
    }
public static void write ( Writer writer , CharSequence cs ) throws IOException { if ( null != cs && null != writer ) { writer . write ( cs . toString ( ) ) ; writer . flush ( ) ; } }
将一段文本全部写入一个writer。
<p>
<b style=color:red>注意</b>，它并不会关闭输出流

@param writer

@param cs
文本
@throws IOException
将一段文本全部写入一个writer。 <p > <b style = color : red > 注意< / b > ，它并不会关闭输出流