Chapter 10. Basic I/O

THIS chapter covers the Java platform classes used for basic I/O. It focuses primarily 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 some file system operations, including random access files. Finally, it touches briefly on the advanced features of the New I/O API. Most of the classes covered are in the java.io package.

Security Consideration

Some I/O operations are subject to approval by the current security manager. The example programs contained in these chapters are standalone applications, which by default have no security manager. To work in an ...

Get The Java™ Tutorial Fourth Edition: A Short Course on the Basics now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.