Writer的基本方法

 


 

  //向输出流中写入一个字符数据,该字节数据为参数b的低16位

  void write(int c) throws IOException

  //将一个字符类型的数组中的数据写入输出流,

  void write(char[] cbuf) throws IOException

  //将一个字符类型的数组中的从指定位置(offset)开始的

  //length个字符写入到输出流

  void write(char[] cbuf,int offset, int length)

              throws IOException

  //将一个字符串中的字符写入到输出流

  void write(String string) throws IOException

  //讲一个字符串从offset开始的length个字符写入到输出流

  void write(String string, int offset, int length)

              throws IOException

  //关闭流释放内存资源

  void close() throws IOException

  //将输出流中缓冲的数据全部写出到目的地

  void flush() throws IOException

点击链接了解更多

posted on 2017-08-02 17:09  SXT  阅读(80)  评论(0编辑  收藏  举报