Java I/O streams; what are the differences?

后端 未结 9 1263
死守一世寂寞
死守一世寂寞 2020-12-12 18:44

java.io has many different I/O streams, (FileInputStream, FileOutputStream, FileReader, FileWriter, BufferedStreams... etc.) and I am confused in determining th

9条回答
  •  鱼传尺愫
    2020-12-12 19:16

    Separate each name into words: each capital is a different word.

    • File Input Stream is to get Input from a File using a Stream.
    • File Output Stream is to write Output to a File using a Stream

    And so on and so forth

    As mmyers wrote :

    Streams: one byte at a time.

    Readers/Writers: one character at a time.

    Buffered*: many bytes/characters at a time.

提交回复
热议问题