December 1999
Intermediate to advanced
816 pages
20h 27m
English
This section shows how to perform several important tasks in Java using streams and Readers and Writers, including
Byte-oriented I/O
I/O with Java Primitives
Write and read lines of text
Write and read entire objects
FileInputStream and FileOutputStream are the basic, concrete classes for doing I/O. Despite their names, you do not need to use them for writing to or reading from files as such. You should select the stream, Reader, or Writer that you want to use based on the granularity or level of abstraction you want to work at. You choose FileInputStream and FileOutputStream to work at the byte level. Listing 12.3 shows a simple example of using these ...
Read now
Unlock full access