Input and Output Streams

This chapter explains how input and output streams can be used for writing files, similar to how they are used for writing to the display.

1. Input and Output Streams

This chapter discusses input and output (I/O) using the package I/O is done using streams. A stream is a sequence of data flowing from a source to a destination. I/O streams can be connected to a wide variety of data sources and destinations.

You have already used streams in reading data from the keyboard and in writing data to the monitor. Streams are used for much more than that.

Chapter Topics:

      • I/O Streams
      • Readers and Writers
      • InputStreams and OutputStreams
      • Character data and UTF
      • Processing Streams

Question 1:

Java can read data from the Internet. What does this data look like to a Java program?

Source: Bradley Kjell,
Creative Commons License This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 License.