CHAPTER 8

image

Java I/O Fundamentals

9781430247647_unFig08-01.jpg

In this chapter, we’ll introduce you to the fundamentals of Java I/O programming. We’ll cover two topics: how to read and write data from console, and then how to use (file) streams to read and write data.

Programming with I/O involves writing some exception-handling code as well. If you’re not familiar with the basics of exception handling, such as how to use try-catch-finally blocks or try-with-resources statements, we recommend that you to read the first three sections in the chapter on exception handling ...

Get Oracle Certified Professional Java SE 7 Programmer Exams 1Z0-804 and 1Z0-805: A Comprehensive OCPJP 7 Certification Guide 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.