O'Reilly logo

The Java® Tutorial: A Short Course on the Basics, 6th Edition by Sharon Biocca Zakhour, Joni Gordon, Sowmya Kannan, Scott Hommel, Raymond Gallardo

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 11. Basic I/O and NIO.2

This chapter covers the Java platform classes used for basic input/output (I/O). It first focuses on I/O Streams, a powerful concept that greatly simplifies I/O operations. The chapter also looks at serialization, which lets a program write whole objects out to streams and read them back again. Then the chapter looks at file I/O and file system operations, including random access files.

Most of the classes covered in the “I/O Streams” section are in the java.io package. Most of the classes covered in the “File I/O” section are in the java.nio.file package.

I/O Streams

An I/O Stream represents an input source or an output destination. A stream can represent many different kinds of sources and destinations, including ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required