经典面试题-Java中的I/O流

1. 字节流

  1. InputStream
  2. OutputStream

2. 字符流

  1. Reader
  2. Writer

区别: 字节流是对文件进行直接操作, 字符流是先加载进内存再进行操作

推荐使用字节流, 字符流容易忘记关闭占用内存

<p> <span>本课程从零开始,以通俗易懂的方式讲解Java技术,手把手教你掌握每一个知识点。</span> </p> <p> <span><span><span></span>真正做到零基础入门学习,</span><span style="color:#FF0000;">适合初学者的教程!</span></span> </p> <p> <span style="color:#FF0000;"><br /> </span> </p> <p> <span>课程内容包括:</span> </p> <p> 1.File类 </p> <p> 2.IO简介 </p> <p> <span>3.的分类</span> </p> <p> <span>    输入、输出<br /> </span> </p> <p> <span>    字节、字符<br /> </span> </p> <p> <span>    节点、包装<br /> </span> </p> <p> <span>4.字节</span> </p> <p> <span>    InputStream:</span><span>FileInputStream、</span><span>ByteArrayInputStream、</span><span>ObjectInputStream</span> </p> <p>     OutputStream:<span>FileOutputStream、</span><span>ByteArrayOutputStream、</span><span>ObjectOutputStream</span> </p> <p> <span>5.字符</span> </p> <p> <span>    Reader:</span><span>FileReader、</span><span>BufferedReader、</span><span>InputStreamReader</span> </p> <p> <span>    Writer:</span><span>FileWriter、</span><span>BufferedWriter / PrintWriter、</span><span>OutputStreamWriter</span> </p> <p> <span>6.随机读写</span> </p> <p> <span>    RandomAccessFile<br /> </span> </p> <p> <span>   </span> </p> <p> <br /> </p> <p> <span><strong><span style="color:#FF0000;">教学全程采用笔记+代码案例的形式讲解,通俗易懂</span></strong><strong><span style="color:#FF0000;">!!!</span></strong></span> </p>
相关推荐
©️2020 CSDN 皮肤主题: 成长之路 设计师:Amelia_0503 返回首页