Download the JDK
Search the Tutorials
Hide the TOC
Trail: Essential Classes
Lesson: Basic I/O
Basic I/O
I/O Streams
Byte Streams
Character Streams
Buffered Streams
Scanning and Formatting
Scanning
Formatting
I/O from the Command Line
Data Streams
Object Streams
File I/O
File Objects
Random Access Files
The New I/O Packages
Summary
Questions and Exercises
Home Page > Essential Classes > Basic I/O
Summary

> The `java.io` package contains many classes that your programs can use to read and write data. Most of the classes implement sequential access streams. The sequential access streams can be divided into two groups: those that read and write bytes and those that read and write Unicode characters. Each sequential access stream has a speciality, such as reading from or writing to a file, filtering data as its read or written, or serializing an object.

> One class, `RandomAccessFile`, implements random input/output access to a file. An object of this type maintains a file pointer, which indicates the current location from which data will be read or to which data will be written.

Previous page: The New I/O Packages
Next page: Questions and Exercises: Basic I/O