Java Input/Output  «Prev 

Logical I/O devices[Java]

In addition to physical I/O devices, Java also supports logical I/O devices such as a block of memory or a string.
Logical devices allow you to read data from strings or write data to memory, for example, as if they are physical devices. This capability helps to unify the manner in which data is stored and retrieved and ultimately makes your job easier as a programmer.
To help underscore this point, consider the example of developing a cache program that stores commonly accessed Web information onto a hard disk.
The same I/O operations used to store the information in memory could also be used to write the information to the hard disk. Likewise, reading stored information from the hard disk would be very similar to reading it from memory.