src/org/nutz/lang/Streams.java
public static int readAndClose(InputStreamReader reader, StringBuilder sb) {
        try {
            return read(reader, sb);
        }
        catch (IOException e) {
            throw Lang.wrapThrow(e);
        }
        finally {
            safeClose(reader);
        }
    }
public static int readAndClose(InputStreamReader reader, StringBuilder sb) {
        try {
            return read(reader, sb);
        }
        catch (IOException e) {
            throw Lang.wrapThrow(e);
        }
        finally {
            safeClose(reader);
        }
    }
public static int readAndClose ( InputStreamReader reader , StringBuilder sb ) { try { return read ( reader , sb ) ; } catch ( IOException e ) { throw Lang . wrapThrow ( e ) ; } finally { safeClose ( reader ) ; } }
从一个文本流中读取全部内容并写入缓冲
<p>
<b style=color:red>注意</b>，它会关闭输出流

@param reader
文本输出流
@param sb
输出的文本缓冲
@return 读取的字符数量
从一个文本流中读取全部内容并写入缓冲 <p > <b style = color : red > 注意< / b > ，它会关闭输出流